/* DigiClip homepage. Same system as the app (src/app.css, src/motion.css):
   JetBrains Mono as the house face, the neutral dark room, bevelled
   panels, and the two easing voices, --ease-out for things arriving and
   --spring for things you pushed. The page stays neutral: emphasis is
   white on the dark room (--hi), never a colour.
   Anton and Archivo Black are the caption faces the engine burns in;
   here they carry the display type.

   The file runs in this order: tokens, base, primitives (label, display
   type, button, tag, panel, well, track, node), then the sections built
   from them, then responsive, then motion. A section may place and size
   a primitive; it does not restyle one. */

@font-face {
    font-family: 'JetBrains Mono';
    src: url('fonts/JetBrainsMono-Variable.ttf') format('truetype');
    font-weight: 100 800;
    font-display: swap;
}
@font-face {
    font-family: 'Anton';
    src: url('fonts/Anton-Regular.ttf') format('truetype');
    font-display: swap;
}
@font-face {
    font-family: 'Archivo Black';
    src: url('fonts/ArchivoBlack-Regular.ttf') format('truetype');
    font-display: swap;
}

/* ------------------------------ TOKENS ------------------------------ */
:root {
    color-scheme: dark;

    /* Colour */
    --background: hsl(0 0% 7%);
    --foreground: hsl(0 0% 93%);
    --card: hsl(0 0% 10%);
    --primary: hsl(0 0% 98%);
    --primary-foreground: hsl(0 0% 9%);
    --secondary: hsl(0 0% 15%);
    --secondary-hover: hsl(0 0% 19%);
    --muted-foreground: hsl(0 0% 64%);
    --border: hsl(0 0% 16%);
    --border-strong: rgb(255 255 255 / 0.45);
    --ring: hsl(0 0% 83%);
    --hi: #fff;
    --on-hi: hsl(0 0% 7%);
    --dim: hsl(0 0% 46%);
    --panel: color-mix(in srgb, var(--card) 78%, black);
    --well: hsl(0 0% 5%);
    --tint: rgb(255 255 255 / 0.1);

    /* Type: four text sizes, each a step you can see, then four display
       sizes. xs is the caps label, sm the fine print, base the body and
       the controls, lead the paragraph under a title and a card's name. */
    --t-xs: 11px;
    --t-sm: 12px;
    --t-base: 14px;
    --t-lead: clamp(16px, 1.3vw, 18px);
    --t-head: 18px;
    --d-xl: clamp(3rem, min(15.6vw, 31vh), 12.8rem);
    --d-lg: clamp(2.6rem, 7.2vw, 5.6rem);
    --d-md: clamp(2.2rem, 4.4vw, 3.4rem);
    --d-sm: 1.5rem;
    --mono: 'JetBrains Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;
    --display: 'Anton', 'Archivo Black', Impact, sans-serif;
    --caption: 'Archivo Black', 'Anton', Impact, sans-serif;

    /* Shape and space */
    --r-sm: 4px;
    --r: 6px;
    --r-lg: 12px;
    --gap: 16px;
    --pad: clamp(16px, 2.2vw, 24px);
    --gutter: clamp(16px, 4vw, 40px);
    --chrome: 42px;

    /* Motion: state changes, small moves, arrivals. */
    --fast: 150ms;
    --move: 280ms;
    --arrive: 560ms;
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ------------------------------ BASE ------------------------------ */
*,
*::before,
*::after {
    box-sizing: border-box;
}
html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--chrome) + 24px);
    -webkit-text-size-adjust: 100%;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}
body {
    margin: 0;
    background: var(--background);
    color: var(--foreground);
    font-family: var(--mono);
    font-size: var(--t-base);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
h1, h2, h3, p, ul, ol {
    margin: 0;
}
ul, ol {
    padding: 0;
    list-style: none;
}
a {
    color: inherit;
    text-decoration: none;
}
button {
    font: inherit;
    color: inherit;
}
code {
    font-family: var(--mono);
    padding: 1px 5px;
    border-radius: var(--r-sm);
    background: var(--tint);
    font-size: 0.92em;
}
:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 2px;
}
::selection {
    background: var(--hi);
    color: var(--on-hi);
}
/* `hidden` must win over any display rule on the same element. */
[hidden] {
    display: none !important;
}
.sprite {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}
.sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
}
.skip {
    position: fixed;
    top: 6px;
    left: 6px;
    z-index: 300;
    padding: 6px 12px;
    border-radius: var(--r);
    background: var(--primary);
    color: var(--primary-foreground);
    transform: translateY(-200%);
}
.skip:focus {
    transform: none;
}
.wrap {
    width: min(1180px, 100% - var(--gutter) * 2);
    margin-inline: auto;
}
.link {
    text-decoration: underline;
    text-decoration-color: rgb(255 255 255 / 0.25);
    text-underline-offset: 3px;
    transition: color var(--fast) ease-out, text-decoration-color var(--fast) ease-out;
}
.link:hover {
    color: var(--hi);
    text-decoration-color: currentColor;
}

/* ------------------------------ PRIMITIVES ------------------------------ */

/* Label: the one small-caps voice, for eyebrows and column heads. */
.label {
    font-size: var(--t-xs);
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted-foreground);
}

/* Display type. The set-up sits back, the punchline (.hi) is lit. */
.display {
    font-family: var(--display);
    font-weight: 400;
    line-height: 0.95;
    text-transform: uppercase;
    letter-spacing: 0.005em;
    color: var(--dim);
}
.hi {
    color: var(--hi);
}
.h2 {
    font-size: var(--d-lg);
    text-wrap: balance;
}
.h3 {
    font-size: var(--t-head);
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
}
.h4 {
    font-size: var(--t-base);
    font-weight: 700;
    line-height: 1.4;
}
.lede {
    max-width: 62ch;
    color: var(--muted-foreground);
    font-size: var(--t-lead);
}
.fine {
    font-size: var(--t-sm);
    color: var(--muted-foreground);
}

/* Icon: lucide outlines on a 24 grid. site.js draws each one from the
   sprite as real nodes, so its parts can move on their own (see MOTION). */
.ico {
    width: 16px;
    height: 16px;
    flex: none;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    /* Parts may swing or swell past the 24 grid while they move. */
    overflow: visible;
}
.ico * {
    transform-box: fill-box;
    transform-origin: center;
}
.solid {
    fill: currentColor;
    stroke: none;
}

/* Button: one control, three sizes, four looks. Links, toggles and the
   like button are all this. */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 36px;
    padding: 0 14px;
    border: 1px solid transparent;
    border-radius: var(--r);
    background: transparent;
    font-size: var(--t-base);
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color var(--fast) ease-out, border-color var(--fast) ease-out, color var(--fast) ease-out, scale 160ms var(--spring);
}
.btn:active {
    scale: 0.97;
}
.btn-sm {
    gap: 6px;
    height: 28px;
    padding: 0 10px;
    font-size: var(--t-sm);
}
.btn-lg {
    gap: 10px;
    height: 48px;
    padding: 0 20px;
    font-size: 16px;
    font-weight: 600;
}
.btn-lg .ico {
    width: 18px;
    height: 18px;
}
.btn-icon {
    width: 28px;
    padding: 0;
}
.btn-primary {
    background: var(--primary);
    color: var(--primary-foreground);
}
.btn-primary:hover,
a:hover > .btn-primary {
    background: hsl(0 0% 84%);
}
.btn-secondary {
    background: var(--secondary);
}
.btn-secondary:hover,
a:hover > .btn-secondary {
    background: var(--secondary-hover);
}
.btn-outline {
    border-color: var(--border);
}
.btn-outline:hover {
    background: var(--secondary);
}
.btn-ghost {
    color: var(--muted-foreground);
}
.btn-ghost:hover {
    background: var(--secondary);
    color: var(--foreground);
}
/* The section being read. */
.btn-ghost[aria-current='true'] {
    color: var(--foreground);
}
/* A toggle that is on. */
.btn[aria-pressed='true'] {
    border-color: var(--border-strong);
    background: var(--secondary);
    color: var(--foreground);
}
/* The quieter half of a button's text: a version, a size, a count. */
.btn-meta {
    font-weight: 400;
    font-variant-numeric: tabular-nums;
    opacity: 0.6;
}

/* Tag: a short fact pinned to something. */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 20px;
    padding: 0 7px;
    border-radius: var(--r-sm);
    background: var(--tint);
    font-size: var(--t-xs);
    font-weight: 500;
    line-height: 1;
    color: var(--foreground);
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}
.tag-solid {
    background: var(--hi);
    color: var(--on-hi);
    font-weight: 700;
}
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

/* Panel: the bevelled surface. The border carries the light. */
.panel {
    position: relative;
    border: 1px solid;
    border-color: rgb(255 255 255 / 0.15) rgb(255 255 255 / 0.08) rgb(0 0 0 / 0.5);
    border-radius: var(--r);
    background: var(--panel);
}

/* Well: sunk into a panel, for anything that plays or prints. */
.well {
    border: 1px solid var(--border);
    border-radius: var(--r-sm);
    background: var(--well);
}
/* Frame: a stand-in for video. */
.frame {
    position: relative;
    border-radius: var(--r-sm);
    overflow: hidden;
    background:
        radial-gradient(70% 90% at 28% 18%, rgb(255 255 255 / 0.1), transparent 70%),
        linear-gradient(#2a2a2a, #181818);
}

/* Track: a level from 0 to 100, set with --w. */
.track {
    display: block;
    height: 6px;
    border-radius: 999px;
    overflow: hidden;
    background: var(--tint);
}
.track b {
    display: block;
    height: 100%;
    background: var(--hi);
    transform-origin: 0 50%;
    transform: scaleX(calc(var(--w, 100) / 100));
}
.track b.dim {
    background: var(--dim);
}
.bars {
    display: grid;
    gap: 8px;
}
.bar {
    display: grid;
    grid-template-columns: 5.4rem 1fr 2.4rem;
    align-items: center;
    gap: 10px;
    font-size: var(--t-sm);
    color: var(--muted-foreground);
}
.bar em {
    font-style: normal;
    text-align: right;
    color: var(--foreground);
    font-variant-numeric: tabular-nums;
}

/* Node: the box an icon sits in when it stands alone. */
.node {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    flex: none;
    border: 1px solid;
    border-color: rgb(255 255 255 / 0.15) rgb(255 255 255 / 0.08) rgb(0 0 0 / 0.5);
    border-radius: var(--r);
    background: var(--panel);
    color: var(--foreground);
    transition: background-color var(--move) ease-out, color var(--move) ease-out, border-color var(--move) ease-out;
}
.node .ico {
    width: 18px;
    height: 18px;
}
.node.lit {
    border-color: var(--hi);
    background: var(--hi);
    color: var(--on-hi);
}

/* Spinner: the only thing allowed to loop without a reason. */
.spin {
    display: inline-block;
    width: 10px;
    height: 10px;
    border: 1.5px solid rgb(255 255 255 / 0.25);
    border-top-color: var(--hi);
    border-radius: 50%;
}
.spin.idle {
    border-color: var(--hi);
    background: var(--hi);
    scale: 0.6;
}
.dot {
    width: 6px;
    height: 6px;
    flex: none;
    border-radius: 50%;
    background: var(--hi);
}

/* ------------------------------ CHROME ------------------------------ */
/* The page is a timeline: a playhead line under the chrome, with a
   marker where each section starts. Markers light as they are passed. */
.pageline {
    position: fixed;
    top: var(--chrome);
    left: 0;
    right: 0;
    z-index: 200;
    height: 1px;
    pointer-events: none;
}
.pageline-bar {
    height: 100%;
    background: var(--hi);
    transform-origin: 0 50%;
    transform: scaleX(var(--p, 0));
}
.pageline-mark {
    position: absolute;
    top: 0;
    width: 2px;
    height: 10px;
    background: var(--dim);
    transform-origin: 50% 0;
    transform: scaleY(0.6);
    transition: background-color var(--fast) ease-out, transform var(--move) var(--ease-out);
}
.pageline-mark.passed {
    background: var(--hi);
}
.pageline-mark.here {
    transform: none;
}
.chrome {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 8px;
    height: var(--chrome);
    padding: 0 12px;
    background: var(--background);
    border-bottom: 1px solid var(--border);
}
.brand {
    padding: 0 8px;
    font-size: var(--t-base);
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--foreground);
}
.chrome-nav {
    display: flex;
    gap: 2px;
    margin-inline: auto;
}
.chrome-end {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}
.chrome-nav + .chrome-end {
    margin-left: 0;
}

/* ------------------------------ HERO ------------------------------ */
.hero {
    position: relative;
    padding: clamp(28px, 6vw, 72px) 0 clamp(48px, 8vw, 110px);
    overflow: hidden;
}
.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: clamp(10px, 2vw, 22px);
}
/* The headline is a burned-in caption: Anton, word by word. Section
   titles are spoken the same way when they scroll in (.w, below). */
.cap-h1 {
    font-size: var(--d-xl);
    /* Room between the lines for the slab behind the spoken word. */
    line-height: 1;
    letter-spacing: 0.002em;
    margin-left: -0.02em;
    color: var(--foreground);
}
.cap-line {
    display: block;
    white-space: nowrap;
}
.w {
    position: relative;
    display: inline-block;
    isolation: isolate;
    transform-origin: 50% 85%;
    transition: color 200ms ease-out;
}
/* The spoken word: a white slab wipes in behind it and the type inverts,
   then the slab leaves the way the sentence is going. */
.w::before {
    content: '';
    position: absolute;
    inset: 0.015em -0.05em -0.022em;
    z-index: -1;
    border-radius: 0.03em;
    background: var(--hi);
    transform: scaleX(0);
    transform-origin: 100% 50%;
    transition: transform var(--move) var(--ease-out);
}
.w.hot {
    color: var(--on-hi);
}
.w.hot::before {
    transform: scaleX(1);
    transform-origin: 0 50%;
}
/* Copy on the left, actions on the right. When both no longer fit side
   by side the actions drop under the copy, so neither is ever squeezed. */
.hero-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px 48px;
    margin-top: clamp(20px, 3vw, 38px);
}
.hero-sub {
    flex: 1 1 27rem;
    min-width: 0;
    max-width: 58ch;
    font-size: var(--t-lead);
    color: var(--muted-foreground);
}
.hero-sub em {
    font-style: normal;
    color: var(--foreground);
}
.hero-sub strong {
    display: block;
    margin-top: 8px;
    color: var(--foreground);
    font-weight: 700;
}
.hero-cta {
    flex: 0 1 auto;
    display: grid;
    gap: 10px;
    min-width: 0;
}
.hero-btns {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 14px;
}

/* The app window */
.stage-tilt {
    margin-top: clamp(32px, 5vw, 64px);
    perspective: 1600px;
}
.stage {
    transform-origin: 50% 0;
    transform: rotateX(var(--tilt, 0deg));
    border-radius: var(--r-lg);
    box-shadow: 0 40px 120px -30px rgb(0 0 0 / 0.9);
    overflow: hidden;
    will-change: transform;
}
.stage-chrome {
    display: flex;
    align-items: center;
    gap: 12px;
    height: var(--chrome);
    padding: 0 6px 0 14px;
    border-bottom: 1px solid var(--border);
    background: var(--background);
    font-size: var(--t-base);
}
.stage-brand {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}
.stage-status {
    margin-inline: auto;
    color: var(--muted-foreground);
}
.stage-status b {
    font-weight: 600;
    color: var(--foreground);
}
.stage-win {
    display: inline-flex;
    gap: 2px;
    color: var(--muted-foreground);
}
.stage-win .ico {
    box-sizing: content-box;
    width: 14px;
    height: 14px;
    padding: 8px;
}
.stage-body {
    display: grid;
    grid-template-columns: 1.04fr 1fr;
    gap: var(--gap);
    padding: var(--pad);
    background: var(--background);
}
.stage-source,
.stage-clips {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}
.stage-clips {
    justify-content: space-between;
}
.src {
    aspect-ratio: 16 / 9;
}
.src-label {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 3;
    background: rgb(0 0 0 / 0.6);
}
/* A speaker: head and shoulders. */
.person {
    position: absolute;
    bottom: 0;
    left: calc(var(--x) * 1%);
    width: 25%;
    aspect-ratio: 1 / 1.22;
    translate: -50% 0;
}
.person::before,
.tile-person::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 42%;
    aspect-ratio: 1;
    translate: -50% 0;
    border-radius: 50%;
    background: var(--skin, #7a7a7a);
}
.person::after,
.tile-person::after {
    content: '';
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 54%;
    border-radius: 48% 48% 0 0 / 78% 78% 0 0;
    background: var(--shirt, #4a4a4a);
}
.pa {
    --skin: #8a8a8a;
    --shirt: #555;
}
.pb {
    --skin: #6f6f6f;
    --shirt: #3c3c3c;
}
.voice {
    position: absolute;
    top: -16%;
    left: 50%;
    display: flex;
    gap: 2px;
    align-items: flex-end;
    height: 12%;
    translate: -50% 0;
    opacity: 0;
    transition: opacity 200ms ease-out;
}
.voice b {
    width: 3px;
    height: 100%;
    border-radius: 2px;
    background: var(--hi);
    transform-origin: 50% 100%;
    transform: scaleY(0.35);
}
.person.talk .voice {
    opacity: 1;
}
/* The 9:16 camera: bright inside, the rest of the frame dimmed. */
.crop {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    width: 31.64%;
    transform: translateX(36%);
    border: 1.5px solid var(--hi);
    border-radius: var(--r-sm);
    box-shadow: 0 0 0 100vmax rgb(0 0 0 / 0.58);
    will-change: transform;
}
.crop-tag {
    position: absolute;
    top: 6px;
    right: 6px;
}
.crop-cap {
    position: absolute;
    right: 4%;
    bottom: 14%;
    left: 4%;
    text-align: center;
    font-family: var(--caption);
    font-size: clamp(8px, 1.3vw, 16px);
    line-height: 1.08;
    text-shadow: -1px 0 0 #000, 1px 0 0 #000, 0 -1px 0 #000, 0 1px 0 #000, 0 2px 6px rgb(0 0 0 / 0.6);
    text-wrap: balance;
}
.cw {
    display: inline-block;
    opacity: 0;
}
.cw.on {
    opacity: 1;
}
/* The spoken word in a burned-in caption: inverted on a white box. The
   box grows with a shadow, not padding, so the line never reflows. */
.crop-cap .cw.hot,
.tile-cap b {
    border-radius: 1px;
    background: var(--hi);
    box-shadow: 0 0 0 0.16em var(--hi);
    color: var(--on-hi);
    text-shadow: none;
}
/* Timeline */
.tl {
    position: relative;
    height: clamp(38px, 5vw, 58px);
    padding: 6px 8px;
}
.tl-bars {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 100%;
}
.tl-bars i {
    flex: 1;
    min-width: 0;
    height: calc(var(--h) * 1%);
    border-radius: 2px;
    background: hsl(0 0% 30%);
    transition: background-color var(--move) ease-out, scale 320ms var(--spring);
}
.tl-bars i.pick {
    background: var(--hi);
    scale: 1 1.18;
}
.tl-head {
    position: absolute;
    top: 2px;
    bottom: 2px;
    left: 0;
    width: 2px;
    margin-left: 8px;
    border-radius: 2px;
    background: var(--hi);
    opacity: 0;
    transition: opacity 200ms ease-out;
}
.tl-head.live {
    opacity: 1;
}
/* Clip tiles */
.tiles {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(6px, 1vw, 12px);
}
.tile {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}
.tile-frame {
    aspect-ratio: 9 / 16;
    border: 1px solid var(--border);
}
.tile-person {
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 86%;
    aspect-ratio: 1 / 1.22;
    translate: -50% 0;
}
.tile-cap {
    position: absolute;
    right: 0;
    bottom: 22%;
    left: 0;
    text-align: center;
    font-family: var(--caption);
    font-size: clamp(7px, 1.05vw, 13px);
    line-height: 1.1;
    text-shadow: -1px 0 0 #000, 1px 0 0 #000, 0 -1px 0 #000, 0 1px 0 #000;
}
.tile-cap b {
    margin-left: 0.2em;
    font-weight: 400;
}
.tile-score {
    position: absolute;
    top: 6px;
    left: 6px;
    min-width: 26px;
    justify-content: center;
}
.tile-making {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--well);
    font-size: var(--t-xs);
    color: var(--muted-foreground);
}
.tile-name {
    font-size: var(--t-xs);
    color: var(--muted-foreground);
}
.tile.empty .tile-frame {
    border-style: dashed;
    background: transparent;
}
.tile.empty .tile-frame > * {
    display: none;
}
.tile.making .tile-making {
    display: flex;
}
.tile.making .tile-score {
    display: none;
}

/* ------------------------------ TICKER ------------------------------ */
.ticker {
    overflow: hidden;
    border-block: 1px solid var(--border);
    background: var(--panel);
}
.ticker-track {
    display: flex;
    align-items: center;
    gap: clamp(18px, 3vw, 40px);
    width: max-content;
    padding: clamp(12px, 1.6vw, 18px) 0;
    font-size: var(--d-md);
    line-height: 1;
    white-space: nowrap;
}
.ticker-track i {
    width: 0.16em;
    height: 0.16em;
    flex: none;
    border-radius: 50%;
    background: var(--dim);
}

/* ------------------------------ SECTIONS ------------------------------ */
.sec {
    position: relative;
    padding: clamp(64px, 10vw, 140px) 0 0;
}
.sec-head {
    display: grid;
    gap: 14px;
    margin-bottom: clamp(28px, 4vw, 56px);
}
.sec-head.center {
    justify-items: center;
    text-align: center;
}

/* Pipeline rail */
.rail {
    position: relative;
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: var(--gap);
}
.rail-fill {
    position: absolute;
    top: 19px;
    /* Stops at the last node: one column minus the node's width. */
    right: calc((100% - var(--gap) * 6) / 7 - 40px);
    left: 0;
    height: 2px;
    background: var(--border);
}
.rail-fill span {
    display: block;
    width: 100%;
    height: 100%;
    background: var(--hi);
    transform-origin: 0 50%;
    transform: scaleX(var(--p, 1));
    transition: transform 500ms var(--ease-out);
}
.step {
    position: relative;
    display: grid;
    gap: 6px;
    align-content: start;
}
.step .node {
    margin-bottom: 8px;
    color: var(--muted-foreground);
}
.step .node.lit {
    color: var(--on-hi);
}
.step p {
    font-size: var(--t-sm);
    line-height: 1.55;
    color: var(--muted-foreground);
}

/* Bento */
.bento {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: var(--gap);
}
.b-12 { grid-column: span 12; }
.b-7 { grid-column: span 7; }
.b-5 { grid-column: span 5; }
.b-4 { grid-column: span 4; }
.card {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: var(--pad);
    min-width: 0;
    overflow: hidden;
}
.card-text {
    display: grid;
    gap: 6px;
}
.card p {
    color: var(--muted-foreground);
    font-size: var(--t-base);
}
/* Each card's demo sits at the bottom, whatever the copy above it runs to. */
.demo {
    display: grid;
    gap: 12px;
    margin-top: auto;
}

/* Captions demo */
.capdemo-frame {
    display: grid;
    place-items: end center;
    height: clamp(150px, 20vw, 210px);
    padding-bottom: 26px;
}
.capdemo-frame .tile-person {
    width: auto;
    height: 82%;
    opacity: 0.7;
}
.capdemo-line {
    position: relative;
    padding: 2px 6px;
    font-size: clamp(22px, 3.6vw, 40px);
    line-height: 1.1;
    text-align: center;
    color: var(--cs-color, #fff);
    border-radius: var(--r-sm);
}
.capdemo-line .cw.hot {
    color: var(--cs-active, #fff);
}
/* The eight styles, in the colours the engine burns in. */
.cs-tiktok { font-family: var(--caption); text-transform: uppercase; text-shadow: -3px 0 0 #25f4ee, 3px 0 0 #fe2c55; }
.cs-karaoke { font-family: var(--caption); text-transform: uppercase; --cs-active: #ffe135; text-shadow: -2px 0 0 #000, 2px 0 0 #000, 0 -2px 0 #000, 0 2px 0 #000; }
.cs-hormozi { font-family: var(--display); text-transform: uppercase; background: #000; padding: 4px 14px; }
.cs-minimal { font-family: Inter, system-ui, sans-serif; font-weight: 500; text-shadow: 0 1px 3px rgb(0 0 0 / 0.8); }
.cs-beast { font-family: var(--caption); text-transform: uppercase; --cs-active: #ffff00; text-shadow: -3px 0 0 #000, 3px 0 0 #000, 0 -3px 0 #000, 0 3px 0 #000, -2px -2px 0 #000, 2px 2px 0 #000, -2px 2px 0 #000, 2px -2px 0 #000; }
.cs-neon { font-family: var(--display); text-transform: uppercase; --cs-active: #00ffff; text-shadow: -1px 0 0 #000, 1px 0 0 #000, 0 -1px 0 #000, 0 1px 0 #000, 0 0 14px #00ffff; }
.cs-highlight { font-family: var(--display); text-transform: uppercase; --cs-color: #000; --cs-active: #000; background: #a3e635; padding: 4px 14px; }
.cs-ghost { font-family: Inter, system-ui, sans-serif; font-weight: 500; --cs-color: rgb(255 255 255 / 0.75); --cs-active: #fff; text-shadow: 0 1px 3px rgb(0 0 0 / 0.8); }
.seg {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

/* Scores */
.card .why {
    color: var(--foreground);
}
.card .picked {
    font-size: var(--t-xs);
}

/* Aspect */
.aspect {
    grid-template-columns: auto 1fr;
    gap: 16px;
    align-items: center;
}
.aspect-box {
    display: grid;
    place-items: center;
    width: 132px;
    height: 132px;
}
.aspect-frame {
    width: 74px;
    height: 132px;
    border: 1.5px solid var(--hi);
    transition: width 520ms var(--spring), height 520ms var(--spring);
}
.aspect-frame .tile-person {
    width: auto;
    height: 74%;
}
.aspect-cap {
    position: absolute;
    bottom: 16%;
    left: 50%;
    width: 44px;
    height: 7px;
    translate: -50% 0;
    border-radius: 2px;
    background: var(--hi);
}
.aspect-list {
    display: grid;
    gap: 4px;
    font-size: var(--t-sm);
    color: var(--muted-foreground);
}
.aspect-list li {
    display: flex;
    gap: 8px;
    padding: 3px 8px;
    border-radius: var(--r-sm);
    transition: background-color 200ms ease-out, color 200ms ease-out;
}
.aspect-list b {
    min-width: 2.6rem;
    color: var(--foreground);
}
.aspect-list li.on {
    background: var(--secondary);
    color: var(--foreground);
}

/* Transcript */
.words {
    gap: 8px;
    padding: 12px;
}
.card .words-time {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--t-xs);
    color: var(--foreground);
    font-variant-numeric: tabular-nums;
}
.card .words-text {
    min-height: 5.2em;
    line-height: 1.75;
    color: var(--dim);
}
.words-text span {
    padding: 1px 2px;
    border-radius: var(--r-sm);
    transition: color var(--fast) ease-out, background-color var(--fast) ease-out;
}
.words-text span.said {
    color: var(--foreground);
}
.words-text span.now {
    background: var(--hi);
    color: var(--on-hi);
}

/* Speed */
.card .speed-num {
    font-size: var(--d-md);
    line-height: 0.9;
    text-transform: none;
    color: var(--foreground);
    font-variant-numeric: tabular-nums;
}
.speed-num small {
    font-size: 0.45em;
    color: var(--dim);
}

/* MCP terminal */
.term {
    gap: 10px;
    padding: 14px;
    font-size: var(--t-sm);
}
.card .term-prompt {
    min-height: 3.3em;
    color: var(--foreground);
    font-size: var(--t-sm);
}
.term-who {
    margin-right: 8px;
    color: var(--muted-foreground);
    vertical-align: 1px;
}
.caret {
    display: inline-block;
    width: 7px;
    height: 1.05em;
    margin-left: 2px;
    vertical-align: text-bottom;
    background: var(--hi);
}
.term-log {
    display: grid;
    gap: 4px;
    color: var(--muted-foreground);
}
.term-log li {
    display: flex;
    align-items: center;
    gap: 8px;
}
.term-log .ico {
    width: 14px;
    height: 14px;
    color: var(--hi);
}
.term-log li.off {
    opacity: 0;
}

/* Privacy */
.card-privacy {
    justify-content: flex-end;
    gap: 12px;
}
.card-privacy .node {
    margin-bottom: auto;
}
.card .privacy-big {
    font-size: var(--d-md);
    color: var(--dim);
}
.card .meter {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 10px;
    font-size: var(--t-sm);
}
.meter i {
    height: 1px;
    background: repeating-linear-gradient(90deg, var(--dim) 0 4px, transparent 4px 8px);
}
.meter b {
    color: var(--hi);
    font-variant-numeric: tabular-nums;
}

/* The rest: a spec sheet, one ruled line per feature. No boxes. */
.more {
    display: grid;
    gap: 14px;
    margin-top: clamp(24px, 4vw, 48px);
}
.feats {
    border-top: 1px solid var(--border);
}
.feat {
    display: grid;
    grid-template-columns: minmax(0, 20rem) minmax(0, 1fr);
    gap: 4px var(--gap);
    align-items: start;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
}
.feat .h4,
.feat p {
    line-height: 1.5;
}
.feat .h4 {
    display: flex;
    align-items: center;
    gap: 10px;
}
.feat .ico {
    color: var(--muted-foreground);
}
.feat p {
    color: var(--muted-foreground);
}

/* Compare */
.cmp-scroll {
    overflow-x: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}
.cmp {
    width: 100%;
    min-width: 680px;
    border-collapse: collapse;
    font-size: var(--t-base);
}
.cmp th,
.cmp td {
    padding: 16px 18px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--border);
}
.cmp tbody tr:last-child th,
.cmp tbody tr:last-child td {
    border-bottom: 0;
}
.cmp thead th {
    font-weight: inherit;
}
.cmp tbody th {
    width: 9.5rem;
    font-weight: 500;
    color: var(--muted-foreground);
}
.cmp td {
    color: var(--muted-foreground);
}
.cmp .us {
    background: rgb(255 255 255 / 0.04);
    color: var(--foreground);
}
.cmp thead .us {
    color: var(--hi);
}
.cmp td.us b {
    font-size: var(--d-sm);
    line-height: 1.1;
    color: var(--hi);
}
.cmp-src {
    margin-top: 14px;
}

/* Versions */
.rel-grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: var(--gap);
    align-items: start;
}
.rel-latest {
    position: sticky;
    top: calc(var(--chrome) + 20px);
    display: grid;
    gap: 14px;
    padding: var(--pad);
    overflow: hidden;
}
.rel-kicker {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: var(--t-sm);
    color: var(--muted-foreground);
}
.rel-tag {
    font-size: var(--d-lg);
    line-height: 0.88;
    text-transform: none;
    color: var(--foreground);
}
.rel-notes {
    display: grid;
    gap: 8px;
    font-size: var(--t-base);
    color: var(--muted-foreground);
}
.rel-notes li {
    position: relative;
    padding-left: 16px;
}
.rel-notes li::before {
    content: '';
    position: absolute;
    top: 0.72em;
    left: 0;
    width: 6px;
    height: 2px;
    background: var(--hi);
}
.rel-notes b {
    color: var(--foreground);
}
.rel-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}
.rel-status {
    margin-bottom: 10px;
}
.rel {
    border-top: 1px solid var(--border);
}
.rel:last-child {
    border-bottom: 1px solid var(--border);
}
.rel > a,
.rel > div {
    display: grid;
    grid-template-columns: 4.6rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    min-height: 48px;
    padding: 8px 4px 8px 8px;
    transition: background-color var(--fast) ease-out;
}
.rel > a:hover,
.rel > div:hover {
    background: var(--panel);
}
.rel b {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.rel-sum {
    overflow: hidden;
    font-size: var(--t-sm);
    color: var(--muted-foreground);
    text-overflow: ellipsis;
    white-space: nowrap;
}
.rel-links {
    display: flex;
    gap: 2px;
}
.rel-more {
    margin-top: 14px;
}

/* Download */
.sec-dl {
    padding-bottom: clamp(64px, 10vw, 130px);
}
.plats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--gap);
}
.plat {
    display: grid;
    grid-template-rows: auto auto auto 1fr auto;
    gap: 4px;
    padding: var(--pad);
    transition: border-color var(--move) ease-out;
}
.plat:hover,
.plat.you {
    border-color: var(--border-strong);
}
/* Every card has this row, so the names line up whichever card carries
   the "Your system" tag. */
.plat-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 20px;
    margin-bottom: 8px;
}
.plat-name {
    font-size: var(--d-md);
    line-height: 1;
    color: var(--foreground);
}
.plat-req,
.plat-file {
    font-size: var(--t-sm);
    color: var(--muted-foreground);
    overflow-wrap: anywhere;
}
.plat-go {
    justify-content: flex-start;
    margin-top: var(--gap);
}
.plat-go .btn-meta {
    margin-left: auto;
}
.notes {
    display: grid;
    gap: 6px;
    max-width: 70ch;
    margin: 24px auto 0;
    text-align: center;
}
.notes b {
    color: var(--foreground);
    font-weight: 600;
}

/* Likes */
[data-like] {
    font-variant-numeric: tabular-nums;
}
[data-like][aria-pressed='true'] .ico {
    fill: currentColor;
}
/* The ring thrown off when a like lands. */
[data-like]::after {
    content: '';
    position: absolute;
    inset: -1px;
    border: 1px solid var(--hi);
    border-radius: inherit;
    opacity: 0;
    pointer-events: none;
}
.like-row {
    display: grid;
    justify-items: center;
    gap: 12px;
    margin-top: clamp(40px, 6vw, 72px);
    padding-top: clamp(40px, 6vw, 72px);
    border-top: 1px solid var(--border);
    text-align: center;
}
.like-msg {
    min-height: 1.65em;
}

/* Footer */
.foot {
    border-top: 1px solid var(--border);
    padding: 28px 0 40px;
    font-size: var(--t-sm);
    color: var(--muted-foreground);
}
.foot-in {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 14px 32px;
    align-items: center;
}
.foot-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--foreground);
    font-weight: 600;
}
.foot-brand span {
    font-weight: 400;
    color: var(--muted-foreground);
}
.foot-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
}
.foot-credit {
    grid-column: 1 / -1;
}

/* ------------------------------ RESPONSIVE ------------------------------ */
/* Seven steps across need about 150px each. Below that the rail turns
   vertical; on mid-size screens it sits beside its heading. */
@media (min-width: 821px) and (max-width: 1239px) {
    .how-wrap {
        display: grid;
        grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
        gap: 48px;
        align-items: start;
    }
    .how-wrap .sec-head {
        position: sticky;
        top: calc(var(--chrome) + 32px);
        margin-bottom: 0;
    }
}
@media (max-width: 1239px) {
    .rail {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .rail-fill {
        top: 0;
        right: auto;
        bottom: 0;
        left: 19px;
        width: 2px;
        height: auto;
    }
    .rail-fill span {
        transform-origin: 50% 0;
        transform: scaleY(var(--p, 1));
    }
    .step {
        grid-template-columns: 40px 1fr;
        column-gap: 16px;
        padding-bottom: 22px;
    }
    /* The last step covers the rail below its node, so the line ends there. */
    .step:last-of-type {
        padding-bottom: 0;
        background: var(--background);
        box-shadow: 0 2px 0 var(--background);
    }
    .step .node {
        grid-row: span 2;
        margin: 0;
    }
    .step .h4 {
        align-self: end;
    }
}
@media (max-width: 1000px) {
    .b-7,
    .b-5 {
        grid-column: span 12;
    }
    .b-4 {
        grid-column: span 6;
    }
    #f-speed {
        grid-column: span 12;
    }
    .rel-grid {
        grid-template-columns: 1fr;
    }
    .rel-latest {
        position: static;
    }

    /* The comparison becomes one block per question. */
    .cmp {
        min-width: 0;
    }
    .cmp thead {
        display: none;
    }
    .cmp,
    .cmp tbody,
    .cmp tr,
    .cmp tbody th {
        display: block;
    }
    .cmp tr {
        padding: 16px;
        border-bottom: 1px solid var(--border);
    }
    .cmp tbody tr:last-child {
        border-bottom: 0;
    }
    .cmp tbody th {
        width: auto;
        padding: 0 0 8px;
        border: 0;
        font-size: var(--t-xs);
        letter-spacing: 0.14em;
        text-transform: uppercase;
    }
    .cmp td {
        display: grid;
        grid-template-columns: 5.2rem minmax(0, 1fr);
        gap: 10px;
        align-items: baseline;
        padding: 5px 0;
        border: 0;
    }
    .cmp td::before {
        content: attr(data-label);
        font-size: var(--t-sm);
        color: var(--muted-foreground);
    }
    .cmp td.us {
        background: none;
    }
    .cmp td.us::before {
        color: var(--hi);
    }
}
/* Three download cards need about 260px each. Below that each card is a
   row: what it is on the left, the button on the right. */
@media (max-width: 899px) {
    .plats {
        grid-template-columns: 1fr;
    }
    .plat {
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-rows: none;
        column-gap: var(--gap);
        align-items: center;
    }
    .plat > * {
        grid-column: 1;
    }
    .plat-top {
        justify-content: flex-start;
    }
    .plat-go {
        grid-column: 2;
        grid-row: 1 / span 4;
        min-width: 12.5rem;
        margin-top: 0;
    }
}
@media (max-width: 820px) {
    .chrome-nav {
        display: none;
    }
    .stage-body {
        grid-template-columns: 1fr;
    }
    .stage-brand {
        display: none;
    }
    .stage-status {
        margin-left: 0;
    }
    /* A feature's line drops under its name, in line with the name's text. */
    .feat {
        grid-template-columns: 1fr;
    }
    .feat p {
        padding-left: 26px;
    }
    .foot-in {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 600px) {
    .b-4 {
        grid-column: span 12;
    }
    .hero-cta {
        flex-basis: 100%;
    }
    .hero-btns .btn {
        flex: 1 1 auto;
    }
    .rel > a,
    .rel > div {
        grid-template-columns: 4.6rem minmax(0, 1fr);
    }
    .rel-links {
        grid-column: 1 / -1;
        margin-left: -10px;
    }
    .chrome [data-version],
    .stage-status-k {
        display: none;
    }
    .plat {
        grid-template-columns: 1fr;
    }
    .plat-go {
        grid-column: 1;
        grid-row: auto;
        margin-top: var(--gap);
    }
}
/* Fingers need more to aim at than a pointer does. */
@media (pointer: coarse) {
    .btn-sm {
        height: 36px;
        padding: 0 12px;
    }
    .btn-icon {
        width: 36px;
        padding: 0;
    }
}
@media (pointer: coarse) {
    :root {
        --chrome: 48px;
    }
}

/* ------------------------------ MOTION ------------------------------ */
@keyframes rise {
    from { transform: translateY(16px); opacity: 0; }
    to { transform: none; opacity: 1; }
}
@keyframes pop {
    from { transform: scale(0.97) translateY(3px); opacity: 0; }
    to { transform: none; opacity: 1; }
}
@keyframes shell-top {
    from { transform: translateY(-100%); opacity: 0; }
}
/* A caption word landing: big, soft, then snapped into place. */
@keyframes word-pop {
    from { opacity: 0; transform: scale(1.3) translateY(0.07em) rotate(-2.5deg); filter: blur(8px); }
    60% { filter: blur(0); }
    to { opacity: 1; transform: none; filter: blur(0); }
}
@keyframes cw-pop {
    from { opacity: 0; transform: scale(1.35) translateY(2px); }
    to { opacity: 1; transform: none; }
}
@keyframes tile-in {
    from { transform: translateY(14px) scale(0.97); opacity: 0; }
    to { transform: none; opacity: 1; }
}
@keyframes score-pop {
    0% { transform: scale(0.5); }
    60% { transform: scale(1.2); }
    100% { transform: none; }
}
@keyframes marquee {
    to { transform: translateX(-50%); }
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
@keyframes voice {
    0%, 100% { transform: scaleY(0.3); }
    50% { transform: scaleY(1); }
}
@keyframes caret {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}
@keyframes like-ring {
    from { opacity: 0.9; transform: scale(1); }
    to { opacity: 0; transform: scale(1.3, 1.8); }
}
@keyframes swap-in {
    from { opacity: 0; transform: translateY(4px) scale(0.85); }
    to { opacity: 1; transform: none; }
}
@keyframes cut-flash {
    from { box-shadow: 0 0 0 100vmax rgb(0 0 0 / 0.58), inset 0 0 0 100vmax rgb(255 255 255 / 0.28); }
    to { box-shadow: 0 0 0 100vmax rgb(0 0 0 / 0.58), inset 0 0 0 100vmax rgb(255 255 255 / 0); }
}

/* Icon choreography. Each icon acts out what it stands for, one part at
   a time; none of them just wobbles. site.js adds .go for one play: when
   the icon scrolls into view, when its step lights, and when the control
   it sits in is hovered, focused or tapped. Lengths are icon units (the
   24 grid). Every play starts and ends on the resting drawing. */

/* download: the arrow falls through the tray and a new one lands in it. */
@keyframes ic-fall {
    0% { transform: none; opacity: 1; animation-timing-function: cubic-bezier(0.5, 0, 1, 0.6); }
    28% { transform: translateY(8px); opacity: 0; }
    29% { transform: translateY(-10px); opacity: 0; animation-timing-function: cubic-bezier(0.2, 0.8, 0.3, 1); }
    70% { transform: translateY(1.5px); opacity: 1; }
    100% { transform: none; opacity: 1; }
}
@keyframes ic-catch {
    0%, 58%, 100% { transform: none; }
    72% { transform: translateY(1.5px); }
}
/* arrow-up-right: leaves through the corner, returns from the opposite one. */
@keyframes ic-fly {
    0% { transform: none; opacity: 1; animation-timing-function: cubic-bezier(0.5, 0, 1, 0.6); }
    32% { transform: translate(9px, -9px); opacity: 0; }
    33% { transform: translate(-9px, 9px); opacity: 0; animation-timing-function: cubic-bezier(0.2, 0.8, 0.3, 1); }
    100% { transform: none; opacity: 1; }
}
/* chevron: dips the way it points. */
@keyframes ic-dip {
    0%, 100% { transform: none; }
    40% { transform: translateY(3.5px); }
    72% { transform: translateY(-1px); }
}
/* A stroke drawing itself (needs pathLength="1" on the path). */
@keyframes ic-draw {
    from { stroke-dasharray: 1; stroke-dashoffset: 1; }
    to { stroke-dasharray: 1; stroke-dashoffset: 0; }
}
/* mic: the capsule picks up two syllables while the cradle is drawn. */
@keyframes ic-speak {
    0%, 100% { transform: none; }
    18% { transform: scale(1.16, 1.08); }
    38% { transform: scale(0.96); }
    58% { transform: scale(1.1, 1.05); }
    78% { transform: scale(0.98); }
}
/* scissors: two snips, each blade turning on the pivot. */
@keyframes ic-snip-a {
    0%, 44%, 100% { transform: none; }
    22%, 66% { transform: rotate(-21deg); }
}
@keyframes ic-snip-b {
    0%, 44%, 100% { transform: none; }
    22%, 66% { transform: rotate(21deg); }
}
/* folder: a file drops in and the folder takes the weight. */
@keyframes ic-file-in {
    0% { transform: none; opacity: 1; }
    14% { transform: none; opacity: 0; }
    15% { transform: translateY(-9px); opacity: 0; animation-timing-function: cubic-bezier(0.5, 0, 0.9, 0.5); }
    58% { transform: translateY(1px); opacity: 1; }
    100% { transform: none; opacity: 1; }
}
@keyframes ic-weigh {
    0%, 52%, 100% { transform: none; }
    66% { transform: scale(1.04, 0.94); }
}
/* pencil: scribbles on its tip while the line appears under it. */
@keyframes ic-scribble {
    0%, 100% { transform: none; }
    18% { transform: rotate(-7deg); }
    38% { transform: rotate(4deg) translateX(1px); }
    58% { transform: rotate(-5deg); }
    78% { transform: rotate(2deg) translateX(1px); }
}
/* globe: the meridian turns edge-on twice, one full spin. */
@keyframes ic-turn {
    0%, 50%, 100% { transform: none; }
    25%, 75% { transform: scaleX(0.04); }
}
/* lock: the shackle lifts, hangs, and is pushed home. */
@keyframes ic-shackle {
    0% { transform: none; animation-timing-function: var(--ease-out); }
    26%, 50% { transform: translateY(-3.2px); animation-timing-function: cubic-bezier(0.6, 0, 1, 0.5); }
    66% { transform: translateY(0.6px); }
    100% { transform: none; }
}
@keyframes ic-latch {
    0%, 62%, 100% { transform: none; }
    72% { transform: translateY(1.2px) scale(1, 0.95); }
}
/* bot: the antenna twitches, then it blinks twice. */
@keyframes ic-antenna {
    0%, 55%, 100% { transform: none; }
    14% { transform: rotate(-16deg); }
    30% { transform: rotate(10deg); }
    44% { transform: rotate(-4deg); }
}
@keyframes ic-blink {
    0%, 46%, 62%, 78%, 100% { transform: none; }
    54%, 70% { transform: scaleY(0.12); }
}
/* split-screen: the seam slides off centre and settles back. */
@keyframes ic-seam {
    0%, 100% { transform: none; }
    30% { transform: translateY(-4.5px); }
    62% { transform: translateY(2.5px); }
    82% { transform: translateY(-0.8px); }
}
/* music: the notes sway, each head swelling on its own beat. */
@keyframes ic-sway {
    0%, 100% { transform: none; }
    25% { transform: rotate(-9deg); }
    55% { transform: rotate(7deg); }
    80% { transform: rotate(-2deg); }
}
@keyframes ic-beat {
    0%, 60%, 100% { transform: none; }
    28% { transform: scale(1.35); }
}
/* cpu: the core fires and the pins light up clockwise. */
@keyframes ic-core {
    0%, 100% { transform: none; }
    30% { transform: scale(0.62); }
    62% { transform: scale(1.18); }
}
@keyframes ic-pin {
    0%, 100% { opacity: 1; }
    35% { opacity: 0.15; }
}
/* film: the sprocket holes advance three frames. */
@keyframes ic-reel {
    from { transform: none; }
    to { transform: translateY(4.5px); }
}
@keyframes ic-reel-in {
    from { opacity: 0; }
    35%, to { opacity: 1; }
}
/* target: a ping travels outward, ring by ring. */
@keyframes ic-ping {
    0%, 100% { transform: none; }
    45% { transform: scale(var(--ping, 1.2)); }
}
/* focus: the brackets close on the subject and the subject answers. */
@keyframes ic-close {
    0%, 100% { transform: none; }
    34%, 60% { transform: translate(var(--cx), var(--cy)); }
}
@keyframes ic-lock-on {
    0%, 30%, 100% { transform: none; }
    46% { transform: scale(0.6); }
    66% { transform: scale(1.25); }
}
/* audio: an equaliser, every bar on its own phase. */
@keyframes ic-eq {
    0%, 100% { transform: none; }
    25% { transform: scaleY(0.35); }
    50% { transform: scaleY(1.12); }
    75% { transform: scaleY(0.55); }
}
/* heart: two beats. */
@keyframes ic-heart {
    0%, 100% { transform: none; }
    22% { transform: scale(1.3); }
    44% { transform: scale(0.92); }
    66% { transform: scale(1.12); }
}
/* clapper: the arm lifts, claps shut and bounces; the board takes it. */
@keyframes ic-clap {
    0% { transform: rotate(0deg); animation-timing-function: ease-out; }
    22% { transform: rotate(-11deg); animation-timing-function: cubic-bezier(0.6, 0, 1, 0.6); }
    40% { transform: rotate(16deg); animation-timing-function: ease-out; }
    47% { transform: rotate(12.5deg); animation-timing-function: ease-in; }
    53%, 62% { transform: rotate(16deg); animation-timing-function: var(--ease-out); }
    100% { transform: rotate(0deg); }
}
@keyframes ic-thud {
    0%, 38%, 52%, 100% { transform: none; }
    42% { transform: translateY(0.6px) scaleY(0.94); }
}

/* Parts that turn on a point of the 24 grid rather than their own middle. */
[data-icon='scissors'] :is(.a, .b),
[data-icon='globe'] .a,
[data-icon='target'] circle,
[data-icon='music'] .all {
    transform-box: view-box;
    transform-origin: 12px 12px;
}
[data-icon='pencil'] .a {
    transform-box: view-box;
    transform-origin: 2px 22px;
}
[data-icon='bot'] .a {
    transform-box: view-box;
    transform-origin: 12px 8px;
}
[data-icon='folder'] .body {
    transform-origin: 50% 100%;
}
[data-icon='clapper'] .a {
    transform-box: view-box;
    transform-origin: 3px 11px;
}
[data-icon='clapper'] .b {
    transform-box: view-box;
    transform-origin: 12px 21px;
}
/* The film's spare sprocket holes: only there while the strip advances. */
.pre {
    opacity: 0;
}
[data-icon='focus'] .tl { --cx: 1.6px; --cy: 1.6px; }
[data-icon='focus'] .tr { --cx: -1.6px; --cy: 1.6px; }
[data-icon='focus'] .br { --cx: -1.6px; --cy: -1.6px; }
[data-icon='focus'] .bl { --cx: 1.6px; --cy: -1.6px; }

@media (prefers-reduced-motion: no-preference) {
    /* Page arrival: chrome drops in, the headline is spoken, the rest rises. */
    .js .chrome {
        animation: shell-top 420ms var(--ease-out) 60ms backwards;
    }
    .js .intro {
        animation: rise 700ms var(--ease-out) calc(520ms + var(--i, 0) * 110ms) backwards;
    }
    .js .w {
        opacity: 0;
    }
    .js .w.on {
        opacity: 1;
        animation: word-pop 460ms var(--spring) backwards;
    }

    /* Scroll reveals */
    .js [data-reveal] {
        opacity: 0;
        transform: translateY(16px);
    }
    .js [data-reveal].in {
        opacity: 1;
        transform: none;
        transition: opacity var(--arrive) var(--ease-out) calc(var(--i, 0) * 45ms), transform var(--arrive) var(--ease-out) calc(var(--i, 0) * 45ms);
    }

    /* Icons, one play each time .go is set */
    .go[data-icon='download'] .a { animation: ic-fall 720ms both; }
    .go[data-icon='download'] .tray { animation: ic-catch 720ms ease-out both; }
    .go[data-icon='arrow-up-right'] .a { animation: ic-fly 620ms both; }
    .go[data-icon='chevron-down'] .a { animation: ic-dip 520ms var(--ease-out) both; }
    .go[data-icon='check'] .a { animation: ic-draw 360ms var(--ease-out) both; }
    .go[data-icon='mic'] .a { animation: ic-speak 760ms ease-in-out both; }
    .go[data-icon='mic'] .b { animation: ic-draw 520ms var(--ease-out) both; }
    .go[data-icon='scissors'] .a { animation: ic-snip-a 640ms cubic-bezier(0.6, 0, 0.3, 1) both; }
    .go[data-icon='scissors'] .b { animation: ic-snip-b 640ms cubic-bezier(0.6, 0, 0.3, 1) both; }
    .go[data-icon='folder'] .a { animation: ic-file-in 760ms both; }
    .go[data-icon='folder'] .body { animation: ic-weigh 760ms var(--ease-out) both; }
    .go[data-icon='pencil'] .a { animation: ic-scribble 760ms ease-in-out both; }
    .go[data-icon='pencil'] .b { animation: ic-draw 620ms ease-in-out 80ms both; }
    .go[data-icon='globe'] .a { animation: ic-turn 900ms ease-in-out both; }
    .go[data-icon='lock'] .a { animation: ic-shackle 820ms both; }
    .go[data-icon='lock'] .b { animation: ic-latch 820ms ease-out both; }
    .go[data-icon='bot'] .a { animation: ic-antenna 900ms ease-in-out both; }
    .go[data-icon='bot'] .eye { animation: ic-blink 900ms ease-in-out both; }
    .go[data-icon='columns'] .a { animation: ic-seam 700ms ease-in-out both; }
    .go[data-icon='music'] .all { animation: ic-sway 820ms ease-in-out both; }
    .go[data-icon='music'] .n1 { animation: ic-beat 410ms ease-out both; }
    .go[data-icon='music'] .n2 { animation: ic-beat 410ms ease-out 300ms both; }
    .go[data-icon='cpu'] .a { animation: ic-core 700ms var(--ease-out) both; }
    .go[data-icon='cpu'] .pin { animation: ic-pin 420ms ease-out calc(var(--n) * 90ms) both; }
    .go[data-icon='film'] .a { animation: ic-reel 240ms ease-in-out 3; }
    .go[data-icon='film'] .pre { animation: ic-reel-in 240ms ease-in-out 3; }
    .go[data-icon='target'] circle { animation: ic-ping 520ms ease-out calc(var(--n) * 110ms) both; }
    .go[data-icon='focus'] .c { animation: ic-close 760ms var(--ease-out) both; }
    .go[data-icon='focus'] .a { animation: ic-lock-on 760ms ease-out both; }
    .go[data-icon='audio'] path { animation: ic-eq 620ms ease-in-out calc(var(--n) * -90ms) both; }
    .go[data-icon='heart'] .a { animation: ic-heart 620ms var(--ease-out) both; }
    .go[data-icon='clapper'] .a { animation: ic-clap 750ms both; }
    .go[data-icon='clapper'] .b { animation: ic-thud 750ms both; }

    /* The stage and the demos: loops that show the product working. */
    .ticker-track {
        animation: marquee 40s linear infinite;
    }
    .ticker:hover .ticker-track {
        animation-play-state: paused;
    }
    .spin:not(.idle) {
        animation: spin 800ms linear infinite;
    }
    .person.talk .voice b {
        animation: voice 520ms ease-in-out infinite;
    }
    .person.talk .voice b:nth-child(2) {
        animation-delay: -180ms;
        animation-duration: 440ms;
    }
    .person.talk .voice b:nth-child(3) {
        animation-delay: -320ms;
        animation-duration: 600ms;
    }
    .crop.cut {
        animation: cut-flash 320ms ease-out;
    }
    .cw.on {
        animation: cw-pop 240ms var(--spring) backwards;
    }
    .tile.making,
    .tile.fresh {
        animation: tile-in 320ms var(--ease-out) backwards;
    }
    .tile.fresh .tile-score {
        animation: score-pop 420ms var(--spring);
    }
    .tiles.reset .tile {
        opacity: 0;
        transition: opacity 260ms ease-in;
    }
    .caret {
        animation: caret 1s steps(1) infinite;
    }
    .track b {
        transition: transform 900ms var(--ease-out);
    }
    #speed-bars .track b {
        transition: none;
    }
    .term-log li {
        transition: opacity 240ms ease-out, transform 320ms var(--ease-out);
    }
    .term-log li.off {
        transform: translateY(6px);
    }
    .rel.new {
        animation: rise 420ms var(--ease-out) calc(var(--i, 0) * 45ms) backwards;
    }
    .rel-notes.fresh li {
        animation: rise 420ms var(--ease-out) calc(var(--i, 0) * 45ms) backwards;
    }
    .plat-you,
    [data-like],
    .like-row {
        animation: pop 360ms var(--spring) backwards;
    }
    [data-like].landed::after {
        animation: like-ring 620ms var(--ease-out);
    }
    .tick {
        display: inline-block;
        animation: swap-in 240ms var(--spring);
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .ticker-track {
        flex-wrap: wrap;
        width: auto;
        justify-content: center;
        padding-inline: var(--gutter);
        white-space: normal;
    }
    /* The second half only exists to make the loop seamless. */
    .ticker-track > :nth-child(n + 13) {
        display: none;
    }
}
