@layer sections {
    /* ===================== home hero ===================== */
    .hero { position: relative; isolation: isolate; padding: 64px 0 96px; overflow-x: clip; }
    .hero::before {   /* a cool light from above, behind the title */
        content: ''; position: absolute; inset: calc(var(--header-h) * -1) 0 auto; z-index: -2; height: 900px;
        background: radial-gradient(60% 55% at 50% 0%, rgb(61 220 255 / .14), transparent 70%), radial-gradient(40% 40% at 80% 30%, rgb(156 140 255 / .07), transparent 70%);
        pointer-events: none;
    }
    .hero__flow { position: absolute; inset: 0 0 auto; z-index: -1; height: min(1200px, 100%); pointer-events: none; mask: linear-gradient(180deg, transparent 0%, #000 22%, #000 80%, transparent 100%); }
    .flowlines { width: 100%; height: 100%; }
    .flowlines path { fill: none; vector-effect: non-scaling-stroke; }
    .flowlines__base { stroke: rgb(61 220 255 / .10); stroke-width: 1; }
    .flowlines__pulse {
        stroke: url(#flow-fade); stroke-width: 1.6; stroke-linecap: round;
        stroke-dasharray: 9 91; stroke-dashoffset: 100;
        animation: flow-run calc(6s + var(--i) * .37s) linear infinite;
        animation-delay: calc(var(--i) * -0.9s);
        filter: drop-shadow(0 0 4px rgb(61 220 255 / .8));
    }
    @keyframes flow-run { to { stroke-dashoffset: 0; } }

    .hero__inner { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
    .hero__inner > * { min-width: 0; max-width: 100%; }
    .hero__pill { margin-bottom: 30px; max-width: 100%; }
    .hero__pill > span:nth-child(2) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .hero__title { max-width: 15ch; }
    .hero__title .hl { margin-top: .08em; }
    .hero__lead { max-width: 760px; margin-top: 28px; color: var(--text-2); }
    .hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 38px; }
    .hero__note { display: block; margin-top: 20px; color: var(--text-3); font-size: 14.5px; font-weight: 600; text-align: center; }
    .hero__note .i { width: 16px; height: 16px; margin-right: 6px; vertical-align: -3px; color: var(--cyan-400); }

    /* the stage: the video, framed like LimeFlow's VSL (radius 28, edge light, heavy shadow) */
    .hero__stage-wrap { position: relative; width: min(1160px, 100% - 2 * var(--gutter)); margin: 72px auto 0; }
    .stage {
        --edge: linear-gradient(170deg, var(--white-a30), var(--white-a6) 40%, var(--cyan-a45) 100%);
        position: relative; z-index: 2;
        padding: 10px; border-radius: calc(var(--r-stage) + 10px);
        background: linear-gradient(180deg, var(--white-a6), var(--white-a2));
        box-shadow: var(--shadow-stage), 0 0 120px -40px rgb(61 220 255 / .45);
    }
    .stage__screen { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r-stage); background: var(--surface-film); container-type: inline-size; }
    .stage__media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
    .stage__media--still { animation: kenburns 20s ease-in-out infinite alternate; transform-origin: 60% 40%; }
    @keyframes kenburns { from { transform: scale(1.02); } to { transform: scale(1.12) translate(-1.5%, 1%); } }
    .stage__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgb(0 0 0 / .45) 0%, transparent 22%, transparent 62%, rgb(0 0 0 / .65) 100%); pointer-events: none; transition: opacity .4s; }
    .stage__top { position: absolute; left: 3.2cqi; right: 3.2cqi; top: 3cqi; display: flex; align-items: center; gap: 1.2cqi; }
    .stage__avatar { display: grid; place-items: center; width: max(30px, 4cqi); height: max(30px, 4cqi); border-radius: 50%; background: var(--grad-cyan); color: var(--cyan-ink); font-weight: 900; font-size: max(13px, 1.6cqi); }
    .stage__titles { display: grid; line-height: 1.2; text-align: left; }
    .stage__titles b { font-size: max(14px, 1.8cqi); font-weight: 800; color: var(--white); text-shadow: 0 1px 10px rgb(0 0 0 / .5); }
    .stage__titles small { font-size: max(12px, 1.3cqi); color: var(--white-a70); }
    .stage__badge { margin-left: auto; padding: .5cqi 1.4cqi; border-radius: 999px; background: rgb(0 0 0 / .45); border: 1px solid var(--white-a16); color: var(--white-a90); font-size: max(11px, 1.15cqi); font-weight: 700; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
    .stage__bar { position: absolute; left: 3cqi; right: 3cqi; bottom: 2.6cqi; gap: 1.4cqi; }
    .stage__bar .playbar__time { font-size: max(11px, 1.25cqi); }
    .stage__state { display: grid; place-items: center; color: var(--white); }
    .stage__state .i, .stage__icons .i { width: max(16px, 2cqi); height: max(16px, 2cqi); }
    .stage__icons { display: flex; gap: 1.6cqi; color: var(--white-a90); }
    .stage .unmute { font-size: max(14px, 1.7cqi); }
    .stage .unmute__circle { width: max(32px, 4.2cqi); height: max(32px, 4.2cqi); }

    /* full film: our chrome steps aside for the native controls */
    .stage.is-live .unmute { opacity: 0; scale: .8; pointer-events: none; }
    .stage.is-live .stage__badge { background: var(--rose-900); border-color: rgb(255 90 110 / .35); }
    .stage.has-native .stage__top, .stage.has-native .stage__bar, .stage.has-native .karaoke, .stage.has-native .stage__shade { opacity: 0; pointer-events: none; }

    /* karaoke captions (bold style, newest word in cyan) — js/features/karaoke.js */
    .karaoke { position: absolute; left: 6cqi; right: 6cqi; bottom: 9cqi; display: grid; justify-items: center; pointer-events: none; }
    .karaoke__line { grid-area: 1 / 1; max-width: 80%; margin: 0; text-align: center; font-family: var(--font-caption); font-size: max(15px, 2.6cqi); font-weight: 900; line-height: 1.25; letter-spacing: -0.01em; color: var(--white); text-shadow: 0 2px 0 rgb(0 0 0 / .55), 0 0 24px rgb(0 0 0 / .6); opacity: 0; transform: translateY(6px); transition: opacity .25s, transform .25s var(--ease); }
    .karaoke__line.is-on { opacity: 1; transform: none; }
    .karaoke__line span { display: inline-block; opacity: .35; transition: opacity .15s, color .15s, transform .2s var(--ease); }
    .karaoke__line span.is-said { opacity: 1; }
    .karaoke__line span.is-now { color: var(--cyan-300); transform: translateY(-2px) scale(1.06); }
    html:not(.js) .karaoke__line:first-child { opacity: 1; transform: none; }
    html:not(.js) .karaoke__line span { opacity: 1; }

    /* the segment strip: the flow lines resolve into the video's HLS segments, the playhead runs through them */
    .segstrip { position: relative; z-index: 1; width: calc(100% - 60px); margin: -6px auto 0; padding: 22px 16px 14px; border-radius: 0 0 22px 22px; background: linear-gradient(180deg, var(--surface-film), rgb(5 6 7 / .6)); border: 1px solid var(--line); border-top: 0; box-shadow: 0 30px 60px -30px var(--black-a80); }
    .segstrip::before, .segstrip::after {   /* sprocket holes */
        content: ''; position: absolute; left: 16px; right: 16px; height: 5px;
        background: radial-gradient(circle, var(--white-a12) 2px, transparent 2.5px) 0 0 / 18px 5px repeat-x;
    }
    .segstrip::before { top: 8px; }
    .segstrip::after { bottom: 4px; }
    .segstrip__track { display: grid; grid-template-columns: repeat(var(--segs), 1fr); gap: 6px; }
    /* each frame is a button: a click plays the film from its time (js/features/hero-player.js) */
    .segstrip__seg { position: relative; display: grid; gap: 4px; padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; opacity: .8; transition: opacity .3s, transform .2s var(--ease); }
    .segstrip__seg.is-played { opacity: 1; }
    .segstrip__seg:hover, .segstrip__seg:focus-visible { opacity: 1; transform: translateY(-2px); }
    .segstrip__seg:focus-visible { outline: none; }
    .segstrip__seg:focus-visible .segstrip__frame { box-shadow: 0 0 0 2px var(--cyan-400); }
    .segstrip__frame { display: block; aspect-ratio: 16 / 9; width: 100%; height: auto; border-radius: 6px; object-fit: cover; background: var(--surface-film); transition: box-shadow .2s; }
    .segstrip__seg:hover .segstrip__frame { box-shadow: 0 0 0 1.5px var(--cyan-a40, rgb(61 220 255 / .4)), 0 6px 18px -6px rgb(61 220 255 / .45); }
    .segstrip__seg i { color: var(--text-4); font-size: 10.5px; font-style: normal; font-family: var(--font-mono); text-align: center; }
    .segstrip__seg.is-played i, .segstrip__seg:hover i { color: var(--cyan-300); }
    .segstrip.has-hint { padding-bottom: 38px; }
    .segstrip.has-hint .segstrip__head { bottom: 50px; }
    .segstrip__hint { position: absolute; left: 50%; bottom: 14px; translate: -50% 0; display: inline-flex; align-items: center; gap: 6px; color: var(--cyan-200); font-size: 11px; font-weight: 800; letter-spacing: .04em; white-space: nowrap; transition: opacity .3s; }
    .segstrip__hint .i { width: 10px; height: 10px; }
    .segstrip.is-live .segstrip__hint { opacity: .55; }
    .segstrip__head { position: absolute; top: 14px; bottom: 26px; left: calc(16px + (100% - 32px) * var(--p, 0)); width: 2px; border-radius: 2px; background: var(--white); box-shadow: 0 0 12px var(--cyan-400), 0 0 2px var(--white); pointer-events: none; opacity: 0; transition: opacity .3s; }
    .segstrip.is-live .segstrip__head { opacity: 1; }
    .segstrip__head::before { content: ''; position: absolute; top: -4px; left: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--white); }

    /* proof pills under the stage (LimeFlow's hero pills) */
    .hero__proof { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 44px; }
    .hero__proof-item { display: flex; align-items: center; gap: 12px; padding: 8px 20px 8px 8px; border-radius: 18px; text-align: left; }
    .hero__proof-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--cyan-a10); border: 1px solid var(--cyan-a16); color: var(--cyan-300); }
    .hero__proof-icon .i { width: 20px; height: 20px; }
    .hero__proof-item b { display: block; font-size: 15px; font-weight: 800; color: var(--text); }
    .hero__proof-item small { color: var(--text-3); font-size: 13px; font-weight: 500; }

    @media (max-width: 900px) {
        .segstrip__seg:nth-child(3n) { display: none; }   /* 8 of 12, still spread over the whole film */
        .segstrip { --segs: 8 !important; }
    }
    @media (max-width: 720px) {
        .hero { padding: 36px 0 64px; }
        .hero__pill { font-size: 12.5px; }
        .hero__lead { margin-top: 20px; font-size: 17px; }
        .hero__actions { flex-direction: column; align-items: stretch; width: 100%; margin-top: 28px; }
        .hero__note { font-size: 13px; }
        .hero__stage-wrap { width: 100%; margin-top: 44px; padding-inline: 10px; }
        .stage { padding: 6px; border-radius: 26px; }
        .stage__screen { border-radius: 20px; }
        .stage__titles small, .stage__icons { display: none; }
        .segstrip { width: calc(100% - 28px); padding-inline: 10px; }
        .segstrip__seg:nth-child(2n) { display: none; }   /* with the 3n rule above: 4 frames */
        .segstrip { --segs: 4 !important; }
        .segstrip__seg i { font-size: 9px; }
        .hero__proof { flex-direction: column; align-items: stretch; }
    }
    @media (prefers-reduced-motion: reduce) {
        .stage__media--still { animation: none; }
        .flowlines__pulse { animation: none; stroke-dasharray: none; opacity: .4; }
    }

    /* ===================== inner page heroes (pricing, plans, lifetime, thank-you, 404) ===================== */
    .page-hero { position: relative; isolation: isolate; padding: 72px 0 64px; text-align: center; overflow-x: clip; }
    .page-hero::before {
        content: ''; position: absolute; inset: calc(var(--header-h) * -1) 0 auto; z-index: -1; height: 700px;
        background: radial-gradient(55% 60% at 50% 0%, rgb(61 220 255 / .13), transparent 70%);
        pointer-events: none;
    }
    .page-hero__inner { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 22px; }
    .page-hero__inner > * { min-width: 0; max-width: 100%; }
    .page-hero .lead { margin-inline: auto; color: var(--text-2); }
    .page-hero__pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 6px; }
    .hero__bg, .hero__grid { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
    .glow { position: absolute; z-index: -1; pointer-events: none; width: 900px; height: 600px; border-radius: 50%; background: radial-gradient(closest-side, rgb(61 220 255 / .12), transparent 70%); }
    .hero__glow-a { left: 50%; top: -300px; translate: -50% 0; }
    .page-hero .hero__actions { margin-top: 10px; }

    .thanks__icon { display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%; background: var(--grad-cyan); color: var(--cyan-ink); box-shadow: var(--shadow-btn), 0 0 0 10px var(--cyan-a6); }
    .thanks__icon .i { width: 40px; height: 40px; stroke-width: 2.6; }
    .thanks__order { font-size: 14px; }
    .notfound { padding: 110px 0 120px; }
    .notfound__code { font-family: var(--font-display); font-size: clamp(110px, 20vw, 220px); font-weight: 900; line-height: .9; letter-spacing: -0.05em; background: linear-gradient(180deg, var(--white) 20%, var(--white-a10)); -webkit-background-clip: text; background-clip: text; color: transparent; }
}
