/* ============================================================
   Typegate landing - light theme, full-width scrolling page.
   Headings/body: PP Neue Montreal (500). Labels: IBM Plex Mono.
   ============================================================ */

/* woff2 must come first: browsers take the first supported source, so with
   woff first the preloaded woff2 was ignored and downloaded twice. */
@font-face {
  font-family: "PP Neue Montreal";
  src:
    url("PPNeueMontreal-Medium.woff2") format("woff2"),
    url("PPNeueMontreal-Medium.woff") format("woff");
  font-weight: 500;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Mono";
  src:
    url("IBMPlexMono-Medium.woff2") format("woff2"),
    url("IBMPlexMono-Medium.woff") format("woff");
  font-weight: 500;
  font-display: swap;
}

:root {
    --ink: #1c1a19;              /* warm brand black - now the text colour */
    --ink-soft: #55504c;         /* secondary text on light */
    --ink-faint: #8c8681;        /* tertiary text on light */
    --bg: #ffffff;
    --surface: #f6f5f3;          /* warm off-white panels */
    --border: #e7e4e0;           /* hairlines on light */
    --dark: #16130f;             /* dark bands (problem / CTA) */
    --dark-soft: rgba(255, 255, 255, 0.62);   /* secondary text on dark */
    --dark-border: rgba(255, 255, 255, 0.12);

    --font: "PP Neue Montreal", -apple-system, "Helvetica Neue", "Arial", sans-serif;
    --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;

    --container: 1200px;
    --gutter: 32px;
    --header-h: 72px;

    --ease-out: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    /* Anchored sections land below the sticky header */
    scroll-padding-top: calc(var(--header-h) + 16px);
}

html, body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--font);
    font-weight: 500;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-text-size-adjust: 100%;
}

/* Plain selector (not a:link/a:visited) so single-class colour rules like
   .btn--primary can win without extra specificity games. */
a {
    text-decoration: none;
    color: inherit;
}

.nooutline { outline: none; }

.noselect {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Safari disables a link's "Open Link in New Tab" / "Copy Link" context-menu
   items when user-select: none sits on the <a> itself - so anchors opt back
   into normal selection behaviour even though they carry .noselect for the
   flip-hover effect. */
a.noselect {
    -webkit-user-select: auto;
    -moz-user-select: auto;
    -ms-user-select: auto;
    user-select: auto;
}

ul { margin: 0; padding: 0; }
li { list-style: none; }

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding-left: var(--gutter);
    padding-right: var(--gutter);
}

/* Uppercase section label, set in the brand sans */
.eyebrow {
    font-family: var(--font);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-faint);
    margin: 0;
}

.eyebrow--ondark { color: var(--dark-soft); }

/* ============================================================
   Buttons
   ============================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 15px 30px;
    border-radius: 10px;
    font-family: var(--font);
    font-weight: 500;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background 0.18s ease, color 0.18s ease,
                border-color 0.18s ease, transform 0.18s var(--ease-out);
}

.btn:active { transform: scale(0.98); }

.btn--primary {
    background: var(--ink);
    color: var(--bg);
}
.btn--primary:hover { background: #35312e; }

.btn--ghost {
    background: transparent;
    color: var(--ink);
    border-color: var(--border);
}
.btn--ghost:hover { background: var(--surface); border-color: #d9d5d0; }

/* On dark bands */
.btn--light {
    background: var(--bg);
    color: var(--ink);
}
.btn--light:hover { background: #dcd9d5; }

.btn--ghost-light {
    background: transparent;
    color: var(--bg);
    border-color: var(--dark-border);
}
.btn--ghost-light:hover { background: rgba(255, 255, 255, 0.08); }

/* ============================================================
   Sticky header
   ============================================================ */

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: none;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.site-header.is-scrolled {
    background: var(--bg);
}

.site-header__inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
    height: var(--header-h);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    font-size: 15px;
    color: var(--ink);
}

.site-header .logo { justify-self: start; display: inline-flex; color: var(--ink); }
.site-nav { justify-self: center; }

.site-nav ul {
    display: flex;
    flex-direction: row;
    gap: 36px;
}

.site-nav a { color: var(--ink-soft); transition: color 0.18s ease; }
.site-nav a:hover { color: var(--ink); }

.header-actions {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 24px;
}

.loginbutton {
    display: inline-flex;
    align-items: center;
    line-height: 1;
    font-size: 15px;
    color: var(--ink-soft);
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.18s ease;
}
.loginbutton:hover { color: var(--ink); }

.getintouch {
    background: var(--ink);
    color: var(--bg);
    font-size: 15px;
    gap: 8px;
    border: none;
    padding: 10px 18px;
    border-radius: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.18s ease;
    cursor: pointer;
}
.getintouch:hover { background: #35312e; }
.getintouch svg path { stroke: currentColor; }

.menu-btn { display: none; }

/* ============================================================
   Hero
   ============================================================ */

.hero {
    position: relative;
    margin-top: calc(-1 * var(--header-h));
    padding: calc(96px + var(--header-h)) 0 40px;
    overflow: hidden;
}

/* Faint grid behind the hero copy, fading out toward the edges */
.hero__grid {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
        linear-gradient(to right, rgba(28, 26, 25, 0.055) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(28, 26, 25, 0.055) 1px, transparent 1px);
    background-size: 244px 184px;
    background-position: center top;
    -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 30%, rgba(0,0,0,0.4) 65%, transparent 95%);
    mask-image: radial-gradient(120% 90% at 50% 0%, #000 30%, rgba(0,0,0,0.4) 65%, transparent 95%);
}

.hero__inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid var(--border);
    border-radius: 2rem;
    background: rgba(255, 255, 255, 0.7);
    color: var(--ink-soft);
    margin-bottom: 28px;
}

.hero__title {
    font-size: clamp(44px, 6.2vw, 76px);
    line-height: 1.02;
    letter-spacing: -0.03em;
    margin: 0 0 26px;
    font-weight: 500;
    font-family: var(--font);
}

.hero__sub {
    font-size: 19px;
    line-height: 1.25;
    color: var(--ink-soft);
    max-width: 640px;
    margin: 0 0 36px;
}

.hero__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

/* Two media frames under the hero copy, like the reference layout */
.hero__media {
    position: relative;
    z-index: 1;
    margin-top: 84px;
    display: grid;
    grid-template-columns: 1.7fr 1fr;
    gap: 20px;
}

/* ============================================================
   Media placeholder slots - swap for real video/images later
   ============================================================ */

.media-slot {
    position: relative;
    width: 100%;
    min-width: 0;
    display: grid;
    place-items: center;
    background:
        radial-gradient(120% 120% at 30% 20%, #fbfaf9 0%, var(--surface) 60%, #efedea 100%);
    color: #b4aea8;
    min-height: 240px;
    overflow: hidden;
    transition: border-color 0.25s ease, color 0.25s ease;
}

.media-slot:hover { border-color: #b9b3ad; color: #8c8681; }

.media-slot svg {
    width: 44px;
    height: 44px;
}

.media-slot::after {
    content: attr(data-label);
    position: absolute;
    left: 18px;
    bottom: 14px;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: inherit;
}

.media-slot--main { aspect-ratio: 16 / 10; }
.media-slot--side { aspect-ratio: auto; }

/* ============================================================
   Workflow card - animated "product demo" mockup for the hero
   main media slot. Pure CSS: one 8s loop that reveals each step,
   fills the progress bar, then fades out and starts again.
   ============================================================ */

.media-slot--live {
    border-color: var(--border);
    padding: 28px;
    cursor: default;
    height: 390px;
}
.media-slot--live:hover { border-color: var(--border); color: inherit; }
.media-slot--live::after { display: none; }

.workflow-card {
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px 20px 20px;
    font-family: var(--font);
    color: var(--ink);
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
    opacity: 1;
}

.workflow-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.workflow-card__kicker {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink);
}

.workflow-card__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--ink-soft);
}

.workflow-card__pill i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--ink);
    flex: none;
}

.workflow-card__steps {
    list-style: none;
    margin: 0 0 0px;
    padding: 0;
}

.workflow-card__step {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 18px;
}
.workflow-card__step:last-child { padding-bottom: 0; }

.workflow-card__dot {
    position: relative;
    display: grid;
    place-items: center;
    flex: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1.5px solid var(--border);
    background: #fff;
    color: #fff;
    transition: background 0.2s var(--ease-out), border-color 0.2s var(--ease-out);
}

.workflow-card__step:not(:last-child) .workflow-card__dot::after {
    content: "";
    position: absolute;
    /* Fixed px, not top:100% - the dot's border-box is 22px but percentage
       offsets on an absolutely-positioned child resolve against its
       containing block's padding-box, landing ~1.5px short and letting
       the line creep into the next circle. */
    top: 22px;
    left: 50%;
    width: 1px;
    height: 18px;
    background: var(--border);
    transform: translateX(-50%);
}

.workflow-card__dot svg {
    width: 11px;
    height: 11px;
}

.workflow-card__label {
    font-size: 13.5px;
    color: var(--ink-faint);
    transition: color 0.2s var(--ease-out);
}

.workflow-card__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.workflow-card__foot-label {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink-faint);
}

.workflow-card__foot-pct {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink);
    opacity: 0;
}

.workflow-card__bar {
    height: 4px;
    border-radius: 2px;
    background: var(--surface);
    overflow: hidden;
}

.workflow-card__bar-fill {
    display: block;
    height: 100%;
    width: 0%;
    border-radius: inherit;
    background: var(--ink);
}

html.js .workflow-card__pill i { animation: wfPulse 1.6s ease-in-out infinite; }

html.js .workflow-card__step[style*="--i:0"] .workflow-card__dot { animation: wfDot1 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:0"] .workflow-card__label { animation: wfLabel1 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:1"] .workflow-card__dot { animation: wfDot2 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:1"] .workflow-card__label { animation: wfLabel2 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:2"] .workflow-card__dot { animation: wfDot3 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:2"] .workflow-card__label { animation: wfLabel3 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:3"] .workflow-card__dot { animation: wfDot4 8s var(--ease-out) infinite; }
html.js .workflow-card__step[style*="--i:3"] .workflow-card__label { animation: wfLabel4 8s var(--ease-out) infinite; }
html.js .workflow-card__bar-fill { animation: wfBar 8s var(--ease-out) infinite; }
html.js .workflow-card__foot-pct { animation: wfPct 8s var(--ease-out) infinite; }

@keyframes wfPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.75); }
}

/* Each step's dot/label pair checks in at its own point along the
   shared 8s timeline, holds until 84%, then eases back to pending
   in plain view - the card itself never hides, so the release
   reads as the next run being queued up. The checkmark itself
   never changes - it's always white (--dot's base "color"), so
   it's invisible against a white dot and appears once the dot's
   background flips to ink. */
@keyframes wfDot1 {
    0%, 10% { background: #fff; border-color: var(--border); }
    14%, 84% { background: var(--ink); border-color: var(--ink); }
    92%, 100% { background: #fff; border-color: var(--border); }
}
@keyframes wfDot2 {
    0%, 24% { background: #fff; border-color: var(--border); }
    28%, 84% { background: var(--ink); border-color: var(--ink); }
    92%, 100% { background: #fff; border-color: var(--border); }
}
@keyframes wfDot3 {
    0%, 38% { background: #fff; border-color: var(--border); }
    42%, 84% { background: var(--ink); border-color: var(--ink); }
    92%, 100% { background: #fff; border-color: var(--border); }
}
@keyframes wfDot4 {
    0%, 52% { background: #fff; border-color: var(--border); }
    56%, 84% { background: var(--ink); border-color: var(--ink); }
    92%, 100% { background: #fff; border-color: var(--border); }
}

@keyframes wfLabel1 {
    0%, 10% { color: var(--ink-faint); }
    14%, 84% { color: var(--ink); }
    92%, 100% { color: var(--ink-faint); }
}
@keyframes wfLabel2 {
    0%, 24% { color: var(--ink-faint); }
    28%, 84% { color: var(--ink); }
    92%, 100% { color: var(--ink-faint); }
}
@keyframes wfLabel3 {
    0%, 38% { color: var(--ink-faint); }
    42%, 84% { color: var(--ink); }
    92%, 100% { color: var(--ink-faint); }
}
@keyframes wfLabel4 {
    0%, 52% { color: var(--ink-faint); }
    56%, 84% { color: var(--ink); }
    92%, 100% { color: var(--ink-faint); }
}

/* The full bar fades out in place, then the (invisible) fill snaps
   back to 0 so the next cycle grows from empty - no width rewind,
   no card blink. */
@keyframes wfBar {
    0%, 5% { width: 0%; opacity: 1; }
    56%, 84% { width: 100%; opacity: 1; }
    90% { width: 100%; opacity: 0; }
    91% { width: 0%; opacity: 0; }
    94%, 100% { width: 0%; opacity: 1; }
}

@keyframes wfPct {
    0%, 56% { opacity: 0; }
    60%, 84% { opacity: 1; }
    90%, 100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    html.js .workflow-card__pill i,
    html.js .workflow-card__bar-fill,
    html.js .workflow-card__foot-pct,
    html.js .workflow-card__step .workflow-card__dot,
    html.js .workflow-card__step .workflow-card__label {
        animation: none !important;
    }
    html.js .workflow-card__step .workflow-card__dot { background: var(--ink); border-color: var(--ink); }
    html.js .workflow-card__step .workflow-card__label { color: var(--ink); }
    html.js .workflow-card__bar-fill { width: 100%; }
    html.js .workflow-card__foot-pct { opacity: 1; }
}

@media (max-width: 900px) {
    .workflow-card { max-width: 280px; }
}

/* ============================================================
   Notification panel - dark mockup for the hero side slot: the
   foundry's live notification inbox. Sits in its slot the same way
   .workflow-card sits in .media-slot--live - a rounded, shadowed
   card floating on the slot's backdrop - instead of items appearing
   one by one it rolls like a real inbox - each new event slides in
   at the TOP and pushes the stack down, with the feed dissolving
   into darkness toward the bottom. Six events arrive per 8s loop;
   the list is duplicated once so the roll wraps seamlessly (the 0%
   and 100% frames are pixel-identical), meaning this loop needs no
   reset at all.
   ============================================================ */

.media-slot--feed { place-items: stretch; }

.notif-panel {
    --row-h: 44px;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background: var(--dark);
    border-radius: 16px;
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
    overflow: hidden;
    font-family: var(--font);
    color: rgba(255, 255, 255, 0.85);
}

.notif-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: none;
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.notif-panel__kicker {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #fff;
}

.notif-panel__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.7);
}
.notif-panel__pill i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #fff;
    flex: none;
}

/* The feed is a clipped window; the list inside translates down one
   row per beat. The gradient dissolves old entries into the dark
   near the foot (and hides the wrap seam and partial rows). */
.notif-panel__feed {
    position: relative;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

.notif-panel__feed::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 62%;
    background: linear-gradient(to bottom, rgba(28, 26, 25, 0) 0%, var(--dark) 58%);
    pointer-events: none;
}

/* Absolute so the (tall) list doesn't set the slot's height - the
   slot stretches to the hero grid row and the window clips the rest. */
.notif-panel__list {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    list-style: none;
    margin: 0;
    padding: 0;
}

.notif-panel__row {
    display: flex;
    align-items: center;
    gap: 9px;
    height: var(--row-h);
    padding: 0 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-family: var(--mono);
    font-size: 10.5px;
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.75);
}

.notif-panel__row svg {
    width: 12px;
    height: 12px;
    flex: none;
    color: rgba(255, 255, 255, 0.5);
}

.notif-panel__row em {
    margin-left: auto;
    font-style: normal;
    font-size: 9px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
}

/* License inquiries are the events the foundry is here for -
   brighter row and a bordered tag. */
.notif-panel__row--hot { color: #fff; }
.notif-panel__row--hot svg { color: #fff; }
.notif-panel__row--hot em {
    padding: 2px 7px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    color: #fff;
}

.notif-panel__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: none;
    padding: 14px 24px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.notif-panel__foot-label {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
}

.notif-panel__foot-stat {
    font-family: var(--mono);
    font-size: 11px;
    color: #fff;
}

/* Six beats per loop. The list starts pulled up by six rows (the
   duplicate set fills the window) and steps down one row height per
   beat; at 100% it sits at 0, which shows the same pixels as 0%, so
   the loop wraps with no visible reset. Each live row fades in as
   its beat slides it into the window. */
html.js .notif-panel__pill i { animation: wfPulse 1.6s ease-in-out infinite; }
html.js .notif-panel__list { animation: notifRoll 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:1"] { animation: notifIn1 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:2"] { animation: notifIn2 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:3"] { animation: notifIn3 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:4"] { animation: notifIn4 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:5"] { animation: notifIn5 8s var(--ease-out) infinite; }
html.js .notif-panel__row[style*="--i:6"] { animation: notifIn6 8s var(--ease-out) infinite; }

@keyframes notifRoll {
    0%, 10% { transform: translateY(calc(var(--row-h) * -6)); }
    14%, 24% { transform: translateY(calc(var(--row-h) * -5)); }
    28%, 38% { transform: translateY(calc(var(--row-h) * -4)); }
    42%, 52% { transform: translateY(calc(var(--row-h) * -3)); }
    56%, 66% { transform: translateY(calc(var(--row-h) * -2)); }
    70%, 80% { transform: translateY(calc(var(--row-h) * -1)); }
    84%, 100% { transform: translateY(0); }
}

/* Row 6 (oldest) enters on the first beat, row 1 (the license
   inquiry) lands on the last - newest always on top. */
@keyframes notifIn6 {
    0%, 10% { opacity: 0; }
    14%, 100% { opacity: 1; }
}
@keyframes notifIn5 {
    0%, 24% { opacity: 0; }
    28%, 100% { opacity: 1; }
}
@keyframes notifIn4 {
    0%, 38% { opacity: 0; }
    42%, 100% { opacity: 1; }
}
@keyframes notifIn3 {
    0%, 52% { opacity: 0; }
    56%, 100% { opacity: 1; }
}
@keyframes notifIn2 {
    0%, 66% { opacity: 0; }
    70%, 100% { opacity: 1; }
}
@keyframes notifIn1 {
    0%, 80% { opacity: 0; }
    84%, 100% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    html.js .notif-panel__pill i,
    html.js .notif-panel__list,
    html.js .notif-panel__row {
        animation: none !important;
    }
}

@media (max-width: 900px) {
    /* Full-bleed feed keeps a fixed frame on mobile (the auto-height
       rule for live slots would collapse it around the clipped list). */
    .media-slot--feed { aspect-ratio: auto; height: 340px; }
    .notif-panel { --row-h: 42px; }
    .notif-panel__row { font-size: 10px; }
}

/* ============================================================
   Upload card - animated media mockup for step 1 (upload flow).
   Same tokens/card shell as .workflow-card but a different device:
   a progress ring fills inside a dropzone, then detected weights
   light up as chips. Pure CSS, 8s loop; the card stays visible
   and the pieces ease back to their start state between cycles.
   ============================================================ */

.upload-card {
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px 20px 20px;
    font-family: var(--font);
    color: var(--ink);
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
}

.upload-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.upload-card__kicker {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink);
}

.upload-card__file {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--mono);
    font-size: 11.5px;
    color: var(--ink-faint);
}
.upload-card__file svg { width: 12px; height: 12px; flex: none; }

.upload-card__zone {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 22px 16px 18px;
    margin-bottom: 16px;
    border: 1px dashed var(--border);
    border-radius: 12px;
    background: radial-gradient(120% 120% at 30% 20%, #fbfaf9 0%, var(--surface) 60%, #efedea 100%);
}

.upload-card__ring {
    position: relative;
    width: 72px;
    height: 72px;
}
.upload-card__ring svg:not(.upload-card__ring-icon) { width: 100%; height: 100%; transform: rotate(-90deg); }
.upload-card__ring-track { fill: none; stroke: var(--border); stroke-width: 4; }
.upload-card__ring-fill {
    fill: none;
    stroke: var(--ink);
    stroke-width: 4;
    stroke-linecap: round;
    stroke-dasharray: 201;
    stroke-dashoffset: 201;
}
.upload-card__ring-icon {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 20px;
    height: 20px;
    color: var(--ink-faint);
}

.upload-card__status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.04em;
    color: var(--ink-faint);
    opacity: 0;
}
.upload-card__status svg { width: 10px; height: 10px; flex: none; }

.upload-card__weights {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.upload-card__chip {
    padding: 5px 11px;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ink-faint);
    background: transparent;
}

/* Gated on .reveal.is-visible so the loop only starts once the card
   has scrolled into view, instead of ticking away offscreen. */
html.js .reveal.is-visible .upload-card__ring-fill { animation: upRing 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__status { animation: upStatus 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__chip[style*="--i:0"] { animation: upChip1 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__chip[style*="--i:1"] { animation: upChip2 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__chip[style*="--i:2"] { animation: upChip3 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__chip[style*="--i:3"] { animation: upChip4 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .upload-card__chip[style*="--i:4"] { animation: upChip5 8s var(--ease-out) infinite; }

/* The completed ring fades out in place, then the (invisible)
   stroke rewinds so the next upload fills from empty - the card
   itself never hides. */
@keyframes upRing {
    0%, 5% { stroke-dashoffset: 201; opacity: 1; }
    54%, 84% { stroke-dashoffset: 0; opacity: 1; }
    90% { stroke-dashoffset: 0; opacity: 0; }
    91% { stroke-dashoffset: 201; opacity: 0; }
    94%, 100% { stroke-dashoffset: 201; opacity: 1; }
}

@keyframes upStatus {
    0%, 54% { opacity: 0; }
    58%, 84% { opacity: 1; }
    90%, 100% { opacity: 0; }
}

/* Weight chips detected one at a time once the ring finishes, then
   all ease back to their outline state together while the card stays
   visible - same release beat as the workflow card's checkmarks. */
@keyframes upChip1 {
    0%, 56% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
    60%, 84% { background: var(--ink); border-color: var(--ink); color: #fff; }
    92%, 100% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
}
@keyframes upChip2 {
    0%, 60% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
    64%, 84% { background: var(--ink); border-color: var(--ink); color: #fff; }
    92%, 100% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
}
@keyframes upChip3 {
    0%, 64% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
    68%, 84% { background: var(--ink); border-color: var(--ink); color: #fff; }
    92%, 100% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
}
@keyframes upChip4 {
    0%, 68% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
    72%, 84% { background: var(--ink); border-color: var(--ink); color: #fff; }
    92%, 100% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
}
@keyframes upChip5 {
    0%, 72% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
    76%, 84% { background: var(--ink); border-color: var(--ink); color: #fff; }
    92%, 100% { background: transparent; border-color: var(--border); color: var(--ink-faint); }
}

@media (prefers-reduced-motion: reduce) {
    html.js .upload-card__ring-fill,
    html.js .upload-card__status,
    html.js .upload-card__chip {
        animation: none !important;
    }
    html.js .upload-card__ring-fill { stroke-dashoffset: 0; }
    html.js .upload-card__status { opacity: 1; }
    html.js .upload-card__chip { background: var(--ink); border-color: var(--ink); color: #fff; }
}

@media (max-width: 900px) {
    .upload-card { max-width: 280px; }
}

/* ============================================================
   Embed browser - animated media mockup for step 2 (embed flow).
   A mini browser window loads specimen.html and the Typegate
   trial button pops in once, then gets a small press each cycle.
   Pure CSS; the window itself never fades out.

   Embed stack (below) reuses the terminal piece for step 3: a
   terminal window types the trial link, then the browser window
   underneath (the trial-card) swaps its header into the loaded
   typeface once typing finishes.
   ============================================================ */

.embed-stack {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    width: 100%;
    max-width: 320px;
    font-family: var(--font);
    color: var(--ink);
}

.embed-terminal {
    background: var(--dark);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
}

.embed-terminal__bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.embed-terminal__dots {
    display: inline-flex;
    gap: 4px;
    flex: none;
}
.embed-terminal__dots i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
}

.embed-terminal__file {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 70px;
    font-family: var(--mono);
    font-size: 10.5px;
    color: rgba(255, 255, 255, 0.45);
}
.embed-terminal__file svg { width: 12px; height: 12px; flex: none; }

.embed-terminal__body {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 13px 14px;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
    overflow: hidden;
}

.embed-terminal__prompt {
    flex: none;
    color: rgba(255, 255, 255, 0.4);
}

/* The snippet is 31 characters; width in ch + steps(31) = typing */
.embed-terminal__type {
    display: inline-block;
    width: 31ch;
    overflow: hidden;
    white-space: nowrap;
    vertical-align: bottom;
}

.embed-terminal__caret {
    flex: none;
    width: 6px;
    height: 12px;
    background: rgba(255, 255, 255, 0.85);
}

.embed-browser {
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
}

.embed-browser__bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid var(--border);
}

.embed-browser__winbtns {
    display: inline-flex;
    gap: 4px;
    flex: none;
}
.embed-browser__winbtns i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--border);
}

.embed-browser__url {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0px 53px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--surface);
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-soft);
    white-space: nowrap;
    overflow: hidden;
}
.embed-browser__url svg { width: 9px; height: 9px; flex: none; }

.embed-browser__page {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 18px 16px 18px;
    background: radial-gradient(120% 120% at 30% 20%, #fbfaf9 0%, var(--surface) 60%, #efedea 100%);
}

.embed-browser__glyph {
    font-size: 26px;
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--ink);
}

.embed-browser__lines {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
}
.embed-browser__lines i {
    height: 5px;
    border-radius: 3px;
    background: #e2ded9;
}
.embed-browser__lines i:nth-child(1) { width: 92%; }
.embed-browser__lines i:nth-child(2) { width: 64%; }

.embed-browser__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 2px;
    padding: 7px 13px;
    border-radius: 999px;
    background: var(--ink);
    color: #fff;
    font-size: 11.5px;
    line-height: 1;
    opacity: 0;
    transform: translateY(6px) scale(0.92);
}
.embed-browser__btn svg { width: 10px; height: 10px; flex: none; }

/* Gated on .reveal.is-visible so the loop only starts once the card
   has scrolled into view, instead of ticking away offscreen. */
html.js .reveal.is-visible .embed-terminal__type { animation: embedType 8s steps(31) infinite; }
html.js .reveal.is-visible .embed-terminal__caret { animation: embedCaret 1.1s step-end infinite; }

/* Button enters once when the card scrolls in (fill: both holds it
   hidden through the delay), then only the press pulse repeats - the
   button never disappears between cycles. The press animation starts
   1s later so it doesn't own `transform` while the entrance rises. */
html.js .reveal.is-visible .embed-browser__btn {
    animation:
        embedBtnIn 0.5s var(--ease-out) 0.5s both,
        embedBtnPress 8s var(--ease-out) 1s infinite;
}

/* Types until 48%, holds while the trial-card header swaps font in
   step 3 (see trialFallback/trialLoaded below), then visibly
   backspaces - steps(31) makes the delete read as real keystrokes -
   so the loop restarts without the card ever hiding. */
@keyframes embedType {
    0%, 6% { width: 0ch; }
    48%, 84% { width: 31ch; }
    94%, 100% { width: 0ch; }
}

@keyframes embedCaret {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

@keyframes embedBtnIn {
    from { opacity: 0; transform: translateY(6px) scale(0.92); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes embedBtnPress {
    0%, 8% { transform: translateY(0) scale(1); }
    12% { transform: translateY(0) scale(0.94); }
    16%, 100% { transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
    html.js .embed-terminal__type,
    html.js .embed-terminal__caret,
    html.js .embed-browser__btn {
        animation: none !important;
    }
    html.js .embed-browser__btn { opacity: 1; transform: none; }
}

@media (max-width: 900px) {
    .embed-stack { max-width: 280px; }
    .embed-terminal__body { font-size: 10px; }
    .embed-browser { max-width: 280px; }
}

/* ============================================================
   Trial card - animated media mockup for step 3 (trial flow).
   Sits below the terminal window in .embed-stack: the headline
   sits in a fallback serif while the trial link is typed, then
   the real typeface "loads" in right as typing finishes, and a
   trial-countdown chip appears in the toolbar. Pure CSS, same 8s
   loop as the terminal above it; the stack stays visible and the
   headline crossfades back to the fallback between cycles.
   ============================================================ */

.trial-card {
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    font-family: var(--font);
    color: var(--ink);
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
}

.trial-card__bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
}

.trial-card__winbtns {
    display: inline-flex;
    gap: 4px;
    flex: none;
}
.trial-card__winbtns i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--border);
}

.trial-card__url {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--surface);
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-soft);
    white-space: nowrap;
    overflow: hidden;
}
.trial-card__url svg { width: 9px; height: 9px; flex: none; }

.trial-card__timer {
    flex: none;
    margin-left: auto;
    padding: 4px 9px;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.02em;
    color: var(--ink);
    white-space: nowrap;
    opacity: 0;
    transform: scale(0.9);
}

.trial-card__page {
    padding: 20px 20px 22px;
}

/* Two stacked copies of the headline; crossfading them reads as
   the fallback font being swapped out when the typeface loads. */
.trial-card__headline {
    position: relative;
    display: block;
    height: 34px;
    margin-bottom: 14px;
}
.trial-card__headline > span {
    position: absolute;
    left: 0;
    bottom: 0;
    white-space: nowrap;
    line-height: 1;
}

.trial-card__headline-fallback {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 22px;
    color: var(--ink-faint);
}

.trial-card__headline-loaded {
    font-size: 26px;
    letter-spacing: -0.02em;
    color: var(--ink);
    opacity: 0;
}

.trial-card__lines {
    display: flex;
    flex-direction: column;
    gap: 7px;
}
.trial-card__lines i {
    height: 5px;
    border-radius: 3px;
    background: #e2ded9;
}
.trial-card__lines i:nth-child(1) { width: 100%; }
.trial-card__lines i:nth-child(2) { width: 84%; }
.trial-card__lines i:nth-child(3) { width: 56%; }

/* Gated on .reveal.is-visible so the loop only starts once the card
   has scrolled into view, instead of ticking away offscreen. */
html.js .reveal.is-visible .trial-card__headline-fallback { animation: trialFallback 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .trial-card__headline-loaded { animation: trialLoaded 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .trial-card__timer { animation: trialTimer 8s var(--ease-out) infinite; }

/* Typing finishes at 48%; font swap starts at 52%. The two headline
   copies are stacked, so they hand off sequentially rather than
   crossfading - the fallback is fully gone before the loaded face
   rises in (a beat of empty space, like a real font swap). At the
   end of the loop the handoff runs in reverse while the terminal
   backspaces, returning the page to its unloaded state without the
   card ever hiding. */
@keyframes trialFallback {
    0%, 52% { opacity: 1; visibility: visible; }
    58%, 89% { opacity: 0; visibility: hidden; }
    94%, 100% { opacity: 1; visibility: visible; }
}

@keyframes trialLoaded {
    0%, 58% { opacity: 0; transform: translateY(5px) scale(0.97); }
    64%, 84% { opacity: 1; transform: translateY(0) scale(1); }
    89%, 100% { opacity: 0; transform: translateY(5px) scale(0.97); }
}

@keyframes trialTimer {
    0%, 64% { opacity: 0; transform: scale(0.9); }
    70%, 84% { opacity: 1; transform: scale(1); }
    92%, 100% { opacity: 0; transform: scale(0.9); }
}

@media (prefers-reduced-motion: reduce) {
    html.js .trial-card__headline-fallback,
    html.js .trial-card__headline-loaded,
    html.js .trial-card__timer {
        animation: none !important;
    }
    html.js .trial-card__headline-fallback { opacity: 0; visibility: hidden; }
    html.js .trial-card__headline-loaded { opacity: 1; transform: none; }
    html.js .trial-card__timer { opacity: 1; transform: none; }
}

@media (max-width: 900px) {
    .trial-card { max-width: 280px; }
    .trial-card__timer { display: none; }
}

/* ============================================================
   Usage card - animated media mockup for step 4 (dashboard).
   Bars grow into a mini chart, then domain rows check in with
   request counts. Pure CSS, same 8s loop.
   ============================================================ */

.usage-card {
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 18px 20px 12px;
    font-family: var(--font);
    color: var(--ink);
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
}

.usage-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.usage-card__kicker {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink);
}

.usage-card__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--ink-soft);
}
.usage-card__pill i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--ink);
    flex: none;
}

.usage-card__chart {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    height: 64px;
    margin-bottom: 14px;
    padding-bottom: 2px;
    border-bottom: 1px solid var(--border);
}

.usage-card__chart i {
    flex: 1;
    height: var(--h);
    border-radius: 3px 3px 0 0;
    background: var(--ink);
    transform: scaleY(0);
    transform-origin: bottom;
}

.usage-card__domain {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 0;
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-soft);
    opacity: 0;
}
.usage-card__domain + .usage-card__domain { border-top: 1px solid var(--border); }

.usage-card__domain i {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--ink);
    flex: none;
}

.usage-card__domain em {
    margin-left: auto;
    font-style: normal;
    color: var(--ink);
}

/* Gated on .reveal.is-visible so the loop only starts once the card
   has scrolled into view, instead of ticking away offscreen. */
html.js .reveal.is-visible .usage-card__pill i { animation: wfPulse 1.6s ease-in-out infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:0"] { animation: usageBar1 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:1"] { animation: usageBar2 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:2"] { animation: usageBar3 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:3"] { animation: usageBar4 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:4"] { animation: usageBar5 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__chart i[style*="--i:5"] { animation: usageBar6 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__domain[style*="--i:0"] { animation: usageRow1 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__domain[style*="--i:1"] { animation: usageRow2 8s var(--ease-out) infinite; }
html.js .reveal.is-visible .usage-card__domain[style*="--i:2"] { animation: usageRow3 8s var(--ease-out) infinite; }

/* Bars grow left to right and hold; at the end of the loop they fade
   out at full height, rewind to zero while invisible, and fade back
   in empty - the chart clears for the next cycle without the card
   ever hiding. */
@keyframes usageBar1 {
    0%, 8% { transform: scaleY(0); opacity: 1; }
    18%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}
@keyframes usageBar2 {
    0%, 12% { transform: scaleY(0); opacity: 1; }
    22%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}
@keyframes usageBar3 {
    0%, 16% { transform: scaleY(0); opacity: 1; }
    26%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}
@keyframes usageBar4 {
    0%, 20% { transform: scaleY(0); opacity: 1; }
    30%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}
@keyframes usageBar5 {
    0%, 24% { transform: scaleY(0); opacity: 1; }
    34%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}
@keyframes usageBar6 {
    0%, 28% { transform: scaleY(0); opacity: 1; }
    38%, 84% { transform: scaleY(1); opacity: 1; }
    90% { transform: scaleY(1); opacity: 0; }
    91% { transform: scaleY(0); opacity: 0; }
    94%, 100% { transform: scaleY(0); opacity: 1; }
}

@keyframes usageRow1 {
    0%, 44% { opacity: 0; transform: translateY(5px); }
    50%, 84% { opacity: 1; transform: translateY(0); }
    92%, 100% { opacity: 0; transform: translateY(5px); }
}
@keyframes usageRow2 {
    0%, 50% { opacity: 0; transform: translateY(5px); }
    56%, 84% { opacity: 1; transform: translateY(0); }
    92%, 100% { opacity: 0; transform: translateY(5px); }
}
@keyframes usageRow3 {
    0%, 56% { opacity: 0; transform: translateY(5px); }
    62%, 84% { opacity: 1; transform: translateY(0); }
    92%, 100% { opacity: 0; transform: translateY(5px); }
}

@media (prefers-reduced-motion: reduce) {
    html.js .usage-card__pill i,
    html.js .usage-card__chart i,
    html.js .usage-card__domain {
        animation: none !important;
    }
    html.js .usage-card__chart i { transform: scaleY(1); }
    html.js .usage-card__domain { opacity: 1; transform: none; }
}

@media (max-width: 900px) {
    .usage-card { max-width: 280px; }
}

/* ============================================================
   Problem - dark contrast band
   ============================================================ */

.problem {
    background: #12100d;
    color: var(--bg);
    padding: 120px 0 128px;
    margin-top: 72px;
}

.problem__title {
    font-size: clamp(34px, 4.4vw, 56px);
    line-height: 1.08;
    letter-spacing: -0.015em;
    text-align: center;
    margin: 20px auto 72px;
    max-width: 820px;
    font-weight: 500;
    font-family: var(--font);
   
}

.problem .eyebrow { text-align: center; }

.problem__cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid var(--dark-border);
    overflow: hidden;
}

.problem-card {
    /* padding: 40px 36px 44px; */
    padding: 36px 36px 38px;
    border-left: 1px solid var(--dark-border);
    background: none;
    transition: background 0.3s ease;
}

.problem-card:first-child {
    border-left: none;
}

.problem-card:hover {
    background: rgba(255, 255, 255, 0.05);
}

.problem-card__icon {
    width: 24px;
    height: 24px;
    display: flex;
    color: var(--bg);
    margin-bottom: 20px;
}

.problem-card__icon svg { width: 24px; height: 24px; }

.problem-card h3 {
    font-size: 22px;
    font-weight: 500;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}

.problem-card p {
    font-size: 15.5px;
    line-height: 1.6;
    color: var(--dark-soft);
    margin: 0;
}

/* ============================================================
   Solution - light statement + three numbered points
   ============================================================ */

.solution {
    padding: 128px 0 40px;
}

.solution__title {
    font-size: clamp(32px, 4vw, 52px);
    line-height: 1.12;
    letter-spacing: -0.015em;
    max-width: 900px;
    margin: 20px 0 28px;
    font-weight: 500;
    font-family: var(--font);
}

.solution__sub {
    font-size: 18px;
    line-height: 1.6;
    color: var(--ink-soft);
    max-width: 700px;
    margin: 0 0 72px;
}

.solution__points {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.solution__points li {
    border-top: 1px solid var(--border);
    padding: 28px 24px 8px 0;
}

.solution__point-num {
    font-family: var(--mono);
    font-size: 13px;
    letter-spacing: 0.1em;
    color: var(--ink-faint);
}

.solution__points h3 {
    font-size: 21px;
    font-weight: 500;
    margin: 14px 0 10px;
    letter-spacing: -0.01em;
}

.solution__points p {
    font-size: 15.5px;
    line-height: 1.6;
    color: var(--ink-soft);
    margin: 0;
}

/* ============================================================
   How it works - alternating text/media rows
   ============================================================ */

.how {
    padding: 120px 0 40px;
}

.how__title {
    font-size: clamp(32px, 4vw, 52px);
    line-height: 1.08;
    letter-spacing: -0.015em;
    margin: 20px 0 80px;
    font-weight: 500;
    font-family: var(--font);
}

.how__steps {
    display: flex;
    flex-direction: column;
    gap: 96px;
}

.step {
    display: grid;
    grid-template-columns: 1fr 1.25fr;
    gap: 72px;
    align-items: center;
}

/* Even steps put the media on the left */
.step--flip .step__text { order: 2; }
.step--flip .step__media { order: 1; }

.step__num { margin-bottom: 18px; }

.step__text h3 {
    font-size: clamp(26px, 2.6vw, 34px);
    font-weight: 500;
    line-height: 1.15;
    letter-spacing: -0.015em;
    margin: 0 0 16px;
}

.step__text p {
    font-size: 16.5px;
    line-height: 1.5;
    color: var(--ink-soft);
    margin: 0;
    max-width: 460px;
}

/* Auto height so the box hugs each mockup card with the same fixed
   padding (see .media-slot--live) instead of a fixed aspect ratio
   leaving a different amount of slack per card's content height. */
.step__media { aspect-ratio: auto; }

/* ============================================================
   FAQ - heading column + accordion
   ============================================================ */

.faq {
    padding: 128px 0;
}

.faq__inner {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 80px;
    align-items: start;
}

.faq__title {
    font-size: clamp(32px, 4vw, 52px);
    line-height: 1.05;
    letter-spacing: -0.015em;
    margin: 20px 0 28px;
    font-weight: 500;
    font-family: var(--font);
}

.faq__contact {
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink-soft);
    margin: 0;
}

.faq__contact-link {
    color: var(--ink);
    border-bottom: 1px solid var(--border);
    transition: border-color 0.18s ease;
}
.faq__contact-link:hover { border-bottom-color: var(--ink); }

.faq__list {
    border-top: 1px solid var(--border);
}

.faq-item {
    border-bottom: 1px solid var(--border);
}

.faq-item__heading { margin: 0; }

.faq-item__btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 4px;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    font-family: var(--font);
    font-weight: 500;
    font-size: 19px;
    letter-spacing: -0.01em;
    color: var(--ink);
    transition: color 0.18s ease;
}

.faq-item__btn:hover { color: #55504c; }

/* Plus icon that rotates into a "minus-ish" cross when open */
.faq-item__icon {
    position: relative;
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    transition: transform 0.35s var(--ease-out);
}
.faq-item__icon::before,
.faq-item__icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 1.8px;
    background: currentColor;
    border-radius: 2px;
    transform: translate(-50%, -50%);
}
.faq-item__icon::after { transform: translate(-50%, -50%) rotate(90deg); }

.faq-item.is-open .faq-item__icon { transform: rotate(45deg); }

/* Body collapses/expands (grid-rows trick) */
.faq-item__bodywrap {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    transition: grid-template-rows 0.4s var(--ease-out), opacity 0.3s ease;
}

.faq-item.is-open .faq-item__bodywrap {
    grid-template-rows: 1fr;
    opacity: 1;
}

.faq-item__bodyinner {
    overflow: hidden;
    min-height: 0;
}

.faq-item__bodywrap p {
    font-size: 16px;
    line-height: 1.62;
    color: var(--ink-soft);
    margin: 0 40px 26px 4px;
    max-width: 640px;
}

/* ============================================================
   CTA band
   ============================================================ */

.cta {
    background: #12100d;
    color: var(--bg);
    padding: 128px 0;
}

.cta__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.cta__title {
    font-size: clamp(34px, 4.4vw, 56px);
    line-height: 1.08;
    letter-spacing: -0.015em;
    margin: 20px 0 22px;
    font-weight: 500;
    font-family: var(--font);
}

.cta__sub {
    font-size: 17px;
    line-height: 1.6;
    color: var(--dark-soft);
    max-width: 540px;
    margin: 0 0 40px;
}

.cta__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

/* ============================================================
   Footer
   ============================================================ */

.site-footer {
    background: var(--bg);
    padding: 72px 0 40px;
    font-size: 15px;
    color: var(--ink-faint);
}

.site-footer__inner {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr;
    gap: 48px;
    align-items: start;
    padding-bottom: 56px;
}

.footer__brand { display: flex; flex-direction: column; gap: 18px; }

.footer__logo {
    display: inline-flex;
    align-items: center;
    color: var(--ink);
    width: fit-content;
}

.footer__tagline {
    margin: 0;
    color: var(--ink-soft);
    max-width: 260px;
    line-height: 1.5;
}

.footer__links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer__links-title {
    margin-bottom: 6px;
    font-size: 12px;
}

.footer__links a {
    color: var(--ink-soft);
    width: fit-content;
    transition: color 0.18s ease;
}
.footer__links a:hover { color: var(--ink); }

.footer__copy {
    border-top: 1px solid var(--border);
    padding-top: 28px;
}

.footer__copy p { margin: 0; }

/* Footer "Cookie preferences" control shares the link look but is a
   <button> (it reopens the banner instead of navigating). */
.footer__linkbtn {
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    text-align: left;
    cursor: pointer;
    color: var(--ink-soft);
    width: fit-content;
    transition: color 0.18s ease;
}
.footer__linkbtn:hover { color: var(--ink); }

/* ============================================================
   Cookie consent banner
   ============================================================ */

.cookie-banner {
    position: fixed;
    left: 24px;
    bottom: 24px;
    z-index: 60;
    max-width: 410px;
    margin: 0 auto;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 24px 48px -28px rgba(28, 26, 25, 0.28), 0 2px 10px rgba(28, 26, 25, 0.05);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.32s var(--ease-out), transform 0.32s var(--ease-out);
}

.cookie-banner.is-open {
    opacity: 1;
    transform: translateY(0);
}

.cookie-banner__inner {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cookie-banner__title {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 500;
    color: var(--ink);
}

.cookie-banner__text {
    margin: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--ink-soft);
}

.cookie-banner__actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cookie-banner__actions-row {
    display: flex;
    gap: 10px;
}

.cookie-banner__btn.btn {
    padding: 11px 20px;
    font-size: 14px;
}

.cookie-banner__btn--accept.btn { width: 100%; }

.cookie-banner__actions-row .btn { flex: 1; }

/* ============================================================
   Load cascade (hero) + reveal-on-scroll
   Hidden states only apply with JS present; without it the page
   is a plain, fully visible document.
   ============================================================ */

html.js .load-item { opacity: 0; }

body.is-loaded .load-item {
    animation: riseIn 0.8s var(--ease-out) both;
}
body.is-loaded .load-item:nth-child(1) { animation-delay: 0.05s; }
body.is-loaded .load-item:nth-child(2) { animation-delay: 0.15s; }
body.is-loaded .load-item:nth-child(3) { animation-delay: 0.25s; }
body.is-loaded .load-item:nth-child(4) { animation-delay: 0.35s; }
/* The media grid is a sibling section, so it gets its own beat */
body.is-loaded .hero__media.load-item { animation-delay: 0.5s; }

@keyframes riseIn {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}

html.js .reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.75s var(--ease-out), transform 0.75s var(--ease-out);
    transition-delay: var(--reveal-delay, 0s);
}

html.js .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger siblings inside card/point grids */
.problem__cards .reveal:nth-child(2),
.solution__points .reveal:nth-child(2) { --reveal-delay: 0.12s; }
.problem__cards .reveal:nth-child(3),
.solution__points .reveal:nth-child(3) { --reveal-delay: 0.24s; }
.faq__list .reveal:nth-child(2) { --reveal-delay: 0.08s; }
.faq__list .reveal:nth-child(3) { --reveal-delay: 0.16s; }
.faq__list .reveal:nth-child(4) { --reveal-delay: 0.24s; }

/* ============================================================
   Per-letter roll on hover (nav links + buttons)
   Two stacked copies of the label in a one-line clip window; on
   hover each letter slides up one line, staggered left-to-right.
   ============================================================ */

.flipeffect {
    --roll-duration: 0.3s;
    --roll-ease: cubic-bezier(0.76, 0, 0.24, 1);
}

.rolling-text {
    display: inline-flex;
    flex-direction: column;
    overflow: hidden;
    height: 1.15em;
    line-height: 1.15;
    vertical-align: bottom;
}

.rolling-text .block {
    display: flex;
    flex: 0 0 auto;
    height: 1.15em;
    white-space: pre;
}

.rolling-text .letter {
    display: inline-block;
    transition: transform var(--roll-duration) var(--roll-ease);
}

.flipeffect:hover .letter,
.flipeffect:focus-visible .letter {
    transform: translateY(-100%);
}

/* Readable label for assistive tech (the rolling letters are decorative) */
.rolling-text__sr {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* ============================================================
   Mobile menu overlay - light theme
   ============================================================ */

.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.32s ease, visibility 0s linear 0.32s;
    overscroll-behavior: contain;
    touch-action: none;
}

.mobile-menu.is-open {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.32s ease;
}

.mobile-menu__close {
    position: absolute;
    top: max(20px, env(safe-area-inset-top));
    right: 22px;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    background: none;
    outline: none;
    color: var(--ink);
    cursor: pointer;
    opacity: 0;
}
.mobile-menu.is-open .mobile-menu__close {
    animation: riseIn 0.45s ease 0.04s both;
}
.mobile-menu__close svg { width: 26px; height: 26px; display: block; }

.mobile-menu__nav {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
    padding: 13vh 26px 0;
    gap: 14px;
}

.mobile-menu .mobile-menu__link {
    font-family: var(--font);
    font-weight: 500;
    font-size: clamp(38px, 12.5vw, 56px);
    line-height: 1.04;
    color: var(--ink);
    text-decoration: none;
    display: block;
    opacity: 0;
    transform: translateY(22px);
}

.mobile-menu__link--cta { margin-top: 0.72em; }
.mobile-menu .mobile-menu__link--muted { color: var(--ink-faint); }

.mobile-menu.is-open .mobile-menu__link {
    animation: riseIn 0.6s var(--ease-out) both;
}
.mobile-menu.is-open .mobile-menu__link:nth-child(1) { animation-delay: 0.07s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(2) { animation-delay: 0.14s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(3) { animation-delay: 0.21s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(4) { animation-delay: 0.28s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(5) { animation-delay: 0.38s; }
.mobile-menu.is-open .mobile-menu__link:nth-child(6) { animation-delay: 0.45s; }

/* Hamburger (hidden on desktop) */
.menu-btn {
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    background: none;
    outline: none;
    cursor: pointer;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
}
.menu-btn span {
    display: block;
    width: 22px;
    height: 2px;
    border-radius: 2px;
    background: var(--ink);
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 1024px) {
    .step { gap: 48px; }
    .faq__inner { gap: 48px; }
}

@media (max-width: 900px) {
    :root { --gutter: 22px; }

    /* Header: logo left, CTA + hamburger right */
    .site-header__inner {
        display: flex;
        align-items: center;
        gap: 12px;
    }
    .site-header .logo { margin-right: auto; }
    .site-nav { display: none; }
    .loginbutton { display: none; }
    .menu-btn { display: inline-flex; }

    .getintouch {
        padding: 9px 15px;
        font-size: 14px;
    }

    .hero { padding-top: calc(64px + var(--header-h)); }
    .hero__sub { font-size: 16.5px; }
    .hero__media {
        margin-top: 56px;
        grid-template-columns: 1fr;
    }
    .media-slot--side { aspect-ratio: 16 / 10; }
    /* Live mockup slots hug their card (same trick as .step__media) -
       a fixed 16/10 box clips the cards at narrow widths. */
    .media-slot--live { aspect-ratio: auto; }

    .hero__grid {
        background-size: 120px 132px;
    }

    .problem { padding: 84px 0 92px; margin-top: 48px; }
    .problem__title { margin-bottom: 48px; }
    .problem__cards { grid-template-columns: 1fr; }
    .problem-card { padding: 28px 24px 30px; border-left: none; border-top: 1px solid var(--dark-border); }
    .problem-card:first-child { border-top: none; }
    .problem-card__icon { margin-bottom: 30px; }

    .solution { padding: 92px 0 24px; }
    .solution__sub { margin-bottom: 48px; }
    .solution__points { grid-template-columns: 1fr; gap: 8px; }
    .solution__points li { padding-right: 0; }

    .how { padding: 92px 0 24px; }
    .how__title { margin-bottom: 56px; }
    .how__steps { gap: 64px; }
    .step {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    /* Text always above media when stacked */
    .step--flip .step__text { order: 1; }
    .step--flip .step__media { order: 2; }
    .step__text p { max-width: none; }

    .faq { padding: 92px 0; }
    .faq__inner { grid-template-columns: 1fr; gap: 40px; }
    .faq-item__btn { font-size: 17px; padding: 22px 2px; }

    .cta { padding: 92px 0; }

    .site-footer { padding-top: 56px; }
    .site-footer__inner {
        grid-template-columns: 1fr;
        gap: 40px;
        padding-bottom: 40px;
    }

    .cookie-banner { left: 16px; right: 16px; bottom: 16px; }
}

@media (max-width: 420px) {
    .hero__title { font-size: clamp(34px, 10vw, 42px); }
    .btn { padding: 14px 22px; font-size: 15px; }
    .problem__title, .cta__title { font-size: 30px; }
}

/* ============================================================
   Reduced motion - everything visible, nothing animates
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }

    html.js .load-item,
    html.js .reveal {
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
        transition: none !important;
    }

    .rolling-text .letter { transition: none; }
    .flipeffect:hover .letter,
    .flipeffect:focus-visible .letter { transform: none; }

    .faq-item__bodywrap,
    .faq-item__icon { transition: none; }

    .mobile-menu,
    .mobile-menu.is-open .mobile-menu__close,
    .mobile-menu.is-open .mobile-menu__link {
        transition: opacity 0.2s ease, visibility 0s;
        animation: none !important;
    }
    .mobile-menu .mobile-menu__link { opacity: 1; transform: none; }

    .cookie-banner { transition: opacity 0.2s ease; transform: none; }
    .cookie-banner.is-open { transform: none; }
}
