/* ═══════════════════════════════════════════════════════════════
   BEBEN DESIGN — index.css  (v3)

   v3 changes from v2:
     - Back to the original brand palette (white smoke / onyx /
       punch red / banana yellow) — more contrast than the
       Redoubt-borrowed navy, per Luis.
     - The square grid moves to `body` as the one sitewide primary
       background (like Redoubt), at a faint opacity of its own
       (--grid-line), separate from regular borders so it doesn't
       fight for attention or look like a layout aid.
     - Sections are full-bleed; an inner .container holds the
       1140px content column. Soft (secondary-surface) sections
       alternate strictly down the page, each spanning 100vw.
     - Demo console restyled as a markdown TUI in brand colours.
     - Logo is icon-only again, fixed banana-yellow fill.
   ═══════════════════════════════════════════════════════════════ */

/* ── 1. DESIGN TOKENS ─────────────────────────────────────────── */
:root[data-theme="light"] {
    /* So native controls (select popups, scrollbars, form widgets) follow the
       site theme rather than the OS setting the meta tag reports. */
    color-scheme: light;
    --bg:            #f5f5f5;
    --bg-soft:       #efefef;
    --headers:       #141414;
    /* Brand pink (#FF2D6A): 3.30:1 on --bg, 3.13:1 on --bg-soft. That
       clears the 3:1 bar for large display text, fills and focus rings,
       not the 4.5:1 bar for normal-size text. */
    --highlight:     #FF2D6A;
    /* Same value as --highlight by request. On light surfaces 3.30:1 sits
       below 4.5:1, so normal-size text in this colour is a known
       compromise; the dark theme reads 5.12:1. */
    --highlight-text: #FF2D6A;
    --yellow:        #FFC710;
    /* Accessible variant, for --yellow applied to normal-size TEXT.
       5.26:1 on --bg, 4.98:1 on --bg-soft. Banana yellow is 1.43 / 1.36. */
    --yellow-text:   #806200;
    --text:          #141414;

    --text-muted:    rgba(20, 20, 20, 0.62);
    --border:        rgba(20, 20, 20, 0.18);
    --border-strong: rgba(20, 20, 20, 0.34);
    --grid-line:     rgba(20, 20, 20, 0.032);

    --whatsapp:      #25D366;
    --nav-bg:        rgba(245, 245, 245, 0.7);
    --overlay:       #F5F5F5;
}

:root[data-theme="dark"] {
    color-scheme: dark;
    --bg:            #141414;
    --bg-soft:       #1C1C1C;
    --headers:       #F7F4F3;
    /* Brand pink (#FF2D6A): 5.12:1 on --bg, 4.74:1 on --bg-soft, so it
       clears both the 3:1 non-text bar and 4.5:1 for normal-size text. */
    --highlight:     #FF2D6A;
    --highlight-text: #FF2D6A;
    --yellow:        #FFC710;
    /* 11.78:1 on --bg, 10.90:1 on --bg-soft. On a dark surface the brand
       yellow is already past AAA, so it needs no separate text variant. */
    --yellow-text:   #FFC710;
    --text:          #F7F4F3;

    --text-muted:    rgba(247, 244, 243, 0.62);
    --border:        rgba(247, 244, 243, 0.16);
    --border-strong: rgba(247, 244, 243, 0.32);
    --grid-line:     rgba(247, 244, 243, 0.032);

    --whatsapp:      #25D366;
    --nav-bg:        rgba(20, 20, 20, 0.7);
    --overlay:       #141414;
}

:root {
    --font-title:  'Old Standard TT', Georgia, 'Times New Roman', serif;
    --font-mono:   'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;
    --font-body:   'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    --nav-height: 55px;
    /* The move ticker sits above the fixed nav, so every offset that used to
       clear the nav now clears both bars. --nav-height stays the nav's own
       height; --chrome-height is the sum the layout should use. */
    --ticker-height: 34px;
    --chrome-height: calc(var(--nav-height) + var(--ticker-height));
    --ease-snap:  cubic-bezier(0.22, 0.9, 0.32, 1);
    --dur-fast:   180ms;
    --dur-base:   600ms;

    /* Hero photo panel. Not themed — the hero is a dark surface in
       both modes, so one value each. --hero-grid-line is far stronger
       than the body's --grid-line, which is invisible over a photo.
       --hero-scrim is the tuning knob for the whole effect: a
       left-weighted ramp, heaviest where the copy sits, lightest on
       the right so the tree and the sunset keep their colour. */
    --hero-grid-line: rgba(255, 255, 255, 0.048);
    --hero-focus:     50% 50%;
    --hero-scrim:     linear-gradient(95deg,
                          rgba(9, 11, 14, 0.88) 0%,
                          rgba(9, 11, 14, 0.72) 48%,
                          rgba(9, 11, 14, 0.38) 100%);
}

/* ── 2. RESET & BASE ──────────────────────────────────────────── */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

/* The square grid lives here — the one sitewide, primary
   background, exactly like Redoubt. It's deliberately faint
   (--grid-line) since it's a texture, not a layout guide; it
   won't line up with every section edge at every viewport size,
   and isn't meant to. */
body {
    font-family: var(--font-body);
    background-color: var(--bg);
    background-image:
        linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
        linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
    background-size: 48px 48px;
    color: var(--text);
    line-height: 1.6;
    font-size: 1.7em;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

/* Deep links land on section anchors and on the three services offers,
   which are <article id> elements inside a plain section. Both need to
   clear the fixed ticker plus nav. */
section[id],
article[id] { scroll-margin-top: var(--chrome-height); }

:focus-visible {
    outline: 2px solid var(--highlight);
    outline-offset: 2px;
}

/* ── 3a. MOVE TICKER ──────────────────────────────────────────── */
/* A one-line yellow strip above the fixed nav, announcing the move to
   bebendesign.com. Four copies of the line sit in each of two identical
   groups, and each group carries a trailing 1.1rem gutter, so the track
   is exactly two equal halves and translate -50% loops with no seam. The
   four copies are what keep the strip full: one copy per group left long
   blank stretches on wide screens between passes. The pause control is
   JS-only (.js gate below), because a button that does nothing is worse
   than no button. Hover and focus pause as well, so keyboard users can
   stop it by tabbing to it. */
.move-ticker {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--ticker-height);
    z-index: 202;
    background: var(--yellow);
    color: #141414;
    overflow: hidden;
    border-bottom: 1px solid rgba(20, 20, 20, 0.28);
}

.move-ticker__link {
    position: absolute;
    inset: 0;
    display: block;
    overflow: hidden;
    color: #141414;
}

/* The pause control needs room, but only when JS can make it work. */
.js .move-ticker__link { right: 48px; }

.move-ticker__track {
    display: flex;
    width: max-content;
    height: 100%;
    animation: ticker-scroll 55s linear infinite;
    will-change: transform;
}

.move-ticker__group {
    display: flex;
    align-items: center;
    /* At every normal window width the four copies are wider than the
       viewport, so this is inert. On ultrawide screens it stretches the
       group to one viewport and space-around shares the spare room
       evenly, which keeps the seam gap identical to the inner ones and
       stops the strip ever running out of text. */
    justify-content: space-around;
    min-width: 100vw;
    gap: 1.1rem;
    height: 100%;
    padding-right: 1.1rem;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    white-space: nowrap;
}

.move-ticker__item {
    display: inline-flex;
    align-items: center;
    gap: 1.1rem;
}

.move-ticker__short { display: none; }
.move-ticker__sep { font-size: 0.62rem; opacity: 0.55; }

@keyframes ticker-scroll {
    to { transform: translate3d(-50%, 0, 0); }
}

.move-ticker:hover .move-ticker__track,
.move-ticker:focus-within .move-ticker__track,
.move-ticker[data-paused="true"] .move-ticker__track { animation-play-state: paused; }

.move-ticker__pause {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 1;
    display: none;
    place-items: center;
    width: 48px;
    height: 100%;
    padding: 0;
    border: 0;
    border-left: 1px solid rgba(20, 20, 20, 0.28);
    background: linear-gradient(to right,
                rgba(255, 199, 16, 0) 0%,
                var(--yellow) 45%);
    color: #141414;
    cursor: pointer;
}

.js .move-ticker__pause { display: grid; }
.move-ticker__pause:hover { background: #141414; color: var(--yellow); }
.move-ticker__pause svg { width: 12px; height: 12px; display: block; }
.move-ticker__pause .ticker-icon--play { display: none; }
.move-ticker[data-paused="true"] .move-ticker__pause .ticker-icon--pause { display: none; }
.move-ticker[data-paused="true"] .move-ticker__pause .ticker-icon--play { display: block; }

/* Pink is invisible on the yellow strip (about 2.2:1), so the shared focus
   outline is re-pointed at the ink colour here, inset so it stays on the
   strip rather than bleeding into the nav. */
.move-ticker :focus-visible {
    outline: 2px solid #141414;
    outline-offset: -3px;
}

@media (max-width: 640px) {
    .move-ticker__group { font-size: 0.64rem; letter-spacing: 0.1em; }
    .move-ticker__long { display: none; }
    .move-ticker__short { display: inline; }
    /* The short line is about a third of the width of the long one, so
       the same duration would read much faster. */
    .move-ticker__track { animation-duration: 28s; }
}

@media (prefers-reduced-motion: reduce) {
    .move-ticker__track {
        width: 100%;
        animation: none;
        transform: none;
        will-change: auto;
    }
    .move-ticker__group {
        width: 100%;
        justify-content: center;
        padding-right: 0;
    }
    .move-ticker__group + .move-ticker__group,
    .move-ticker__item + .move-ticker__item { display: none; }
    .js .move-ticker__link { right: 0; }
    .js .move-ticker__pause { display: none; }
}

/* ── 3b. NAVBAR ───────────────────────────────────────────────── */
/* Navbar sits above the mobile overlay so the logo, theme toggle
   and hamburger (morphing into the close control) stay clickable
   while the menu is open. */
nav {
    position: fixed;
    top: var(--ticker-height);
    left: 0;
    right: 0;
    z-index: 201;
    height: var(--nav-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    background: var(--nav-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    transition: background 0.3s ease, border-color 0.3s ease;
}

.logo {
    display: inline-flex;
    align-items: center;
    transition: transform var(--dur-fast) var(--ease-snap);
}

.logo:hover { transform: scale(1.06) translateY(-1px); }

.logo__mark {
    width: 92px;
    height: auto;
    display: block;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* ── Theme toggle — LIGHT/DARK travel pill ────────────────────
   A single pill control. The icon mover travels the pill width and
   rolls while the sun/moon crossfade at the midpoint; the labels
   crossfade with a small translateX. End positions are driven by
   :root[data-theme], so the pre-paint theme applies instantly with
   no animation on load. The sun/moon SVGs are the Figma exports (the
   moon's gradient starts a shade darker than the original export);
   geometry is untouched, the .theme-toggle__mover parent owns
   translate/rotate and each icon only fades/scales. */
.theme-toggle {
    --toggle-travel: 68px;
    position: relative;
    width: 104px;
    height: 32px;
    flex: none;
    border: 1px solid #3F3F3F;
    border-radius: 999px;
    /* Light theme: white pill. Dark theme (below) blends into the nav. */
    background: #FFFFFF;
    color: #141414;
    cursor: pointer;
    padding: 0;
    overflow: hidden;
    /* Without this the label inherits body's 1.6 and its line box
       sets the pill height instead of the fixed height below. */
    line-height: 1;
    transition: border-color var(--dur-fast) ease, background-color var(--dur-fast) ease,
                transform var(--dur-fast) var(--ease-snap);
}

/* Dark theme: same background as the navbar so the pill sits in it. */
:root[data-theme="dark"] .theme-toggle {
    background: var(--nav-bg);
    color: #FFFFFF;
}

/* Light theme: white pill on the light nav. The ring is deliberately
   faint (#dedede) — the fill carries the shape, not the border. */
:root[data-theme="light"] .theme-toggle {
    border-color: #dedede;
}

.theme-toggle:hover { border-color: currentColor; }
.theme-toggle:active { transform: scale(0.98); }

.theme-toggle__label {
    position: absolute;
    top: 50%;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: currentColor;
    white-space: nowrap;
    transition: opacity 220ms ease, transform 220ms ease;
}

.theme-toggle__label--light {
    left: 14px;
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

.theme-toggle__label--dark {
    right: 14px;
    opacity: 0;
    transform: translateY(-50%) translateX(6px);
}

/* Text begins its swap slightly before the icon settles: the
   incoming label is delayed, the outgoing leaves immediately. */
:root[data-theme="dark"] .theme-toggle__label--light {
    opacity: 0;
    transform: translateY(-50%) translateX(-6px);
}
:root[data-theme="dark"] .theme-toggle__label--dark {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
    transition-delay: 90ms;
}
:root[data-theme="light"] .theme-toggle__label--light { transition-delay: 90ms; }

.theme-toggle__mover {
    position: absolute;
    top: 50%;
    left: 7px;
    width: 20px;
    height: 20px;
    transform: translateY(-50%) translateX(var(--toggle-travel)) rotate(0deg);
    transition: transform 380ms cubic-bezier(0.33, 1.28, 0.42, 1);
    will-change: transform;
}

:root[data-theme="dark"] .theme-toggle__mover {
    transform: translateY(-50%) translateX(0) rotate(-205deg);
}

.theme-toggle__icon {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    transition: opacity 180ms ease, transform 180ms ease;
}

.theme-toggle__icon--sun { opacity: 1; transform: scale(1); }
/* Mirrored on both axes (≡ 180°): the Figma crescent ships
   upside-down and facing the wrong way, so both axes are negated
   here rather than touching the artwork. */
.theme-toggle__icon--moon { opacity: 0; transform: scale(-0.6, -0.6) rotate(45deg); }

/* Midpoint crossfade: the outgoing icon fades fast while the
   incoming one waits until the mover crosses the middle. The
   delay lives on the state being entered, which is the delay the
   transition actually uses. */
:root[data-theme="dark"] .theme-toggle__icon--sun { opacity: 0; transform: scale(0.6); }
:root[data-theme="dark"] .theme-toggle__icon--moon { opacity: 1; transform: scale(-1, -1) rotate(45deg); transition-delay: 140ms; }
:root[data-theme="light"] .theme-toggle__icon--sun { transition-delay: 140ms; }

@media (prefers-reduced-motion: reduce) {
    .theme-toggle,
    .theme-toggle__mover,
    .theme-toggle__icon,
    .theme-toggle__label { transition: none !important; }
}

.menu {
    list-style: none;
    display: flex;
    gap: 2rem;
}

/* The <li> inherits body's 27.2px font-size, so its line box is 43.5px
   while the link inside is only 23px — the text rides low on that
   oversized baseline and stops sharing a centre line with the theme
   toggle. Letting the <li> hug its link fixes it at the source. */
.menu li {
    display: flex;
    align-items: center;
}

.menu li a {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text);
    border-bottom: 2px solid transparent;
    /* the 2px bottom border and the 3px/5px padding together keep the
       text centred in its own box; centring the boxes centres the text */
    padding-top: 5px;
    padding-bottom: 3px;
    transition: color var(--dur-fast) ease, border-color var(--dur-fast) ease;
}

.menu li a:hover {
    color: var(--highlight-text);
}

/* The current page carries the ticker yellow. On the dark nav it reads
   11.8:1; on the light nav #FFC710 is only about 1.4:1, so light mode
   swaps to --yellow-text (5.26:1) rather than dropping the label. The
   underline stays --highlight. */
.menu li a.active {
    color: #FFC710;
    border-bottom-color: transparent;
}

:root[data-theme="light"] .menu li a.active {
    color: var(--yellow-text);
}

/* Brackets on the current page, e.g. [ SERVICES ]. Done as generated
   content rather than markup, so all 32 pages get it without an edit. */
.menu li a.active::before { content: "[ "; }
.menu li a.active::after  { content: " ]"; }

/* Hamburger button */
#hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    width: 30px;
    height: 30px;
}

#hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--headers);
    transition: transform var(--dur-fast) ease, opacity var(--dur-fast) ease, background var(--dur-fast) ease;
    transform-origin: center;
}

body.menu-open #hamburger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.menu-open #hamburger span:nth-child(2) { opacity: 0; transform: scaleX(0); }
body.menu-open #hamburger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── 4. MOBILE MENU OVERLAY ───────────────────────────────────── */
#mobile-menu-overlay {
    padding-top: var(--chrome-height);
    position: fixed;
    inset: 0;
    /* Full-viewport menu: 100dvh preferred for mobile browser chrome,
       100vh fallback. The nav (z-index 201) stays above this overlay
       so its hamburger-turned-close control remains reachable; the
       pair together is the topmost layer over all page content. */
    height: 100vh;
    height: 100dvh;
    z-index: 200;
    /* Translucent glass over the page: material stays faintly visible
       underneath, matching the nav/pill blur treatment. Slightly more
       solid than --nav-bg so the links stay highly readable. */
    background: rgba(245, 245, 245, 0.82);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    overflow-y: auto;
    overscroll-behavior: contain;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, visibility 0.35s ease, background 0.3s ease;
}
:root[data-theme="dark"] #mobile-menu-overlay {
    background: rgba(20, 20, 20, 0.82);
}

#mobile-menu-overlay.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* Editorial left alignment: the menu keeps the site's container
   rhythm (same inline padding) rather than centering like a modal. */
.mobile-menu {
    list-style: none;
    text-align: left;
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 2.5rem clamp(1.2rem, 5vw, 2rem) 3rem;
}

.mobile-menu li {
    margin-bottom: 1.4rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 250ms ease, transform 280ms var(--ease-snap);
}

#mobile-menu-overlay.is-active .mobile-menu li { opacity: 1; transform: translateY(0); }

#mobile-menu-overlay.is-active .mobile-menu li:nth-child(1) { transition-delay: 0.05s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(2) { transition-delay: 0.10s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(3) { transition-delay: 0.15s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(4) { transition-delay: 0.20s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(5) { transition-delay: 0.25s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(6) { transition-delay: 0.30s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(7) { transition-delay: 0.35s; }
#mobile-menu-overlay.is-active .mobile-menu li:nth-child(8) { transition-delay: 0.40s; }
@media (prefers-reduced-motion: reduce) {
    .mobile-menu li { transition: none; transform: none; }
    #mobile-menu-overlay.is-active .mobile-menu li { transition-delay: 0s; }
}

.mobile-menu li a {
    font-family: var(--font-body);
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--headers);
    transition: color var(--dur-fast) ease;
}

.mobile-menu li a:hover,
.mobile-menu li a.active { color: var(--highlight-text); }

/* ── 5. LAYOUT — full-bleed sections, contained content ───────── */
/* Sections span 100% of the viewport so their background (plain,
   or the soft secondary fill) reads edge to edge. .container is
   the actual 1140px content column inside each one. */
main {
    padding-top: var(--chrome-height);
}

section {
    width: 100%;
    padding: clamp(64px, 9vw, 110px) 0;
    border-bottom: 1px solid var(--border);
}

section:last-of-type { border-bottom: none; }

.container {
    max-width: 1140px;
    margin: 0 auto;
    padding-inline: clamp(1.2rem, 5vw, 2rem);
}

/* Secondary surface — alternates strictly section by section.
   A flat fill that sits on top of the body grid, so the grid only
   shows through the sections left plain. */
.section--soft { background: var(--bg-soft); }

.eyebrow {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.9rem;
}

h1, h2 {
    font-family: var(--font-title);
    font-weight: 400;
    color: var(--headers);
    letter-spacing: -0.01em;
}

h2 {
    font-size: clamp(1.5rem, 3.2vw, 2.1rem);
    line-height: 1.2;
}

/* ── 6. STAGGERED REVEAL ──────────────────────────────────────── */
.js [data-reveal] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity var(--dur-base) ease, transform var(--dur-base) ease;
    transition-delay: calc(var(--i, 0) * 80ms);
}

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

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
    .cta-link.cta-pill { transition: none !important; }
}

/* ── 7. HERO ──────────────────────────────────────────────────── */
/* A photographic panel: the skyline at the bottom, a black scrim
   over it for legibility, then the same 48px grid the rest of the
   site uses, then the copy. All of it rides on .hero's own
   background — in a multi-layer background the FIRST layer listed
   paints topmost, and element content always paints above every
   background layer, so the stack falls out for free. No
   pseudo-elements, no z-index, nothing to tangle with the fixed nav.

   The grid layers are shifted up by --chrome-height so their 48px tiles
   stay in step with the body grid above and below: main's padding-top
   puts this box at exactly --chrome-height from the document top, and
   everything above <main> is out of flow. */
.hero {
    /* A dark surface in both themes: re-point the tokens locally and
       every inherited rule follows — h1 (--headers), .eyebrow and
       .hero p (--text-muted), the CTA tooltip (--headers on --bg). */
    --headers:    #F7F4F3;
    --text:       #F7F4F3;
    --text-muted: rgba(247, 244, 243, 0.88);
    --bg:         #141414;
    /* The hero remaps the accent to brand yellow. Measured against the
       actual photo pixels under the scrim, the yellow reads 8.4:1 on the
       CTA and 6.5:1 on the italic "logic", and it matches the hero's
       yellow frame. */
    --highlight:  var(--yellow);
    /* Same remap for the text variant, or the CTA drops back to pink on the
       photo. */
    --highlight-text: var(--yellow);

    padding-top: clamp(110px, 14vw, 150px);
    padding-bottom: 80px;

    /* Full-viewport hero: the fixed nav overlays the top edge, so the
       panel runs edge to edge behind it. 100dvh preferred for mobile
       browser chrome, 100vh fallback. Flex centers the copy vertically
       on tall viewports; content can still grow past 100vh. */
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    max-width: 100%;
    overflow-x: clip;

    background-color: #141414;   /* holds the panel while the photo loads */
    background-image:
        linear-gradient(to right,  var(--hero-grid-line) 1px, transparent 1px),
        linear-gradient(to bottom, var(--hero-grid-line) 1px, transparent 1px),
        var(--hero-scrim),
        url("../images/nrb%20skyline%20hero%20image.webp");
    background-size:     48px 48px, 48px 48px, 100% 100%, cover;
    background-position: 0 calc(-1 * var(--chrome-height)),
                         0 calc(-1 * var(--chrome-height)),
                         0 0,
                         var(--hero-focus);
    background-repeat:   repeat, repeat, no-repeat, no-repeat;
}

.hero h1 {
    font-size: clamp(2.4rem, 6vw, 4.2rem);
    line-height: 1.08;
    margin-bottom: 1.5rem;
}
.highlight-box {
    color: var(--highlight);
    font-style: italic;
}

.hero p {
    font-family: var(--font-body);
    font-size: clamp(1rem, 1.4vw, 1.1rem);
    max-width: 46ch;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

/* Insurance over the brighter cloud areas of the photo. */
.hero .container { width: 100%; }
.hero .eyebrow,
.hero h1,
.hero p { text-shadow: 0 1px 2px rgba(9, 11, 14, 0.5); }

/* Subpage hero — every inner page (work, contact, legal, shop,
   tools, services, …) opens with this so the whole site shares one
   rhythm: eyebrow, serif h1, muted intro. */
.page-hero {
    padding-top: clamp(130px, 16vw, 180px);
    padding-bottom: 60px;
}

.page-hero h1 {
    font-size: clamp(2.2rem, 5.5vw, 3.8rem);
    line-height: 1.08;
    margin-bottom: 1.2rem;
}

.page-hero p {
    font-size: clamp(1rem, 1.4vw, 1.1rem);
    max-width: 52ch;
    line-height: 1.7;
    color: var(--text-muted);
}

/* ── 8. CTA LINK + TOOLTIP ────────────────────────────────────── */
.cta-wrapper { display: block; padding-top: 1rem; }

.cta-link {
    display: inline;
    position: relative;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--highlight-text);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    white-space: nowrap;
}

/* Touch target. The link stays display:inline so the underline geometry and
   every surrounding layout are untouched; this invisible overlay gives the
   anchor a 44px hit area, which 13.6px text alone cannot reach. */
.cta-link::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 44px;
}

.cta-link::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--highlight-text);
    transition: width var(--dur-fast) var(--ease-snap);
}

.cta-link:hover::after { width: 100%; }

/* Pill variant — currently the homepage hero CTA only. White ink on a
   translucent dark fill over the hero photo. The hover fill sweeps in
   from the left on a ::before layer; the arrow rides in its own span
   so the text–arrow gap is explicit. */
.cta-link.cta-pill {
    display: inline-block;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.35);
    color: #FFFFFF;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    padding: 0.7rem 1.5rem;
}
.cta-link.cta-pill::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: #000;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 350ms var(--ease-snap);
    z-index: 0;
}
.cta-link.cta-pill::after { content: none; }
.cta-link.cta-pill:hover::before,
.cta-link.cta-pill:focus-visible::before { transform: scaleX(1); }
.cta-link.cta-pill > span { position: relative; z-index: 1; }
@media (prefers-reduced-motion: reduce) {
    .cta-link.cta-pill::before { transition: none; }
}
.cta-pill__arrow {
    display: inline-block;
    /* 8px of inter-word space left with the old literal space, so 28px
       lands the pill exactly 20px longer than before, all of it here. */
    margin-left: 28px;
}

/* ── 9. SERVICE / CARD GRID ───────────────────────────────────── */
/* These only ever sit inside .section--soft sections in the
   current rotation, so cards use the primary --bg to read as
   distinct "windows" against the soft surface around them. */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1px;
    border: 1px solid var(--border);
    margin-top: 1rem;
}

.service-card {
    background: var(--bg);
    padding: 2rem;
    border-right: 1px solid var(--border);
    transition: background var(--dur-fast) ease, color var(--dur-fast) ease,
                transform var(--dur-fast) var(--ease-snap);
}

.service-card:last-child { border-right: none; }

.service-card:hover {
    background: var(--headers);
    color: var(--bg);
    transform: translateY(-3px);
}

.service-card h3 {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
}

.service-card p {
    font-size: 0.86rem;
    line-height: 1.65;
}

/* ── 10. WORK — case study: the Sprite preview ────────────────── */
#work p { font-size: 0.95rem; line-height: 1.7; color: var(--text-muted); max-width: 60ch; }

.sprite-preview { margin-top: 2rem; }

.sprite-preview__pill {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    max-width: 100%;
    /* Fixed, not theme-driven — Sprite keeps its own look regardless
       of light/dark mode, the way a mascot or logo would. Slightly
       lighter than true onyx so it still reads as a distinct object
       when the page itself goes dark, not black-on-black. */
    background: #262626;
    color: #F7F4F3;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    padding: 10px 24px 10px 10px;
    transition: transform var(--dur-fast) var(--ease-snap);
}

.sprite-preview__pill:hover { transform: translateY(-2px); }

.sprite-preview__figure {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
}

/* The Sprite's eyes and mouth are sized in absolute px, so scale the
   whole character — resizing the box alone would leave a 34px face
   floating inside a 44px circle. */
.sprite-preview__figure .sprite-character { transform: scale(1.29); }

.sprite-preview__text {
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.3;
}

.sprite-preview__tag {
    display: block;
    margin-top: 0.9rem;
    font-family: var(--font-mono);
    font-size: 0.74rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.sprite-preview__tag::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--highlight);
    margin-right: 7px;
    vertical-align: middle;
}

/* ── 11. PROCESS LIST ──────────────────────────────────────────── */
#process h2 { margin-bottom: 2.5rem; }

.process-list {
    display: flex;
    flex-direction: column;
    margin-top: 0.5rem;
}

.process-step {
    display: grid;
    grid-template-columns: 60px 1fr;
    gap: 1.5rem;
    align-items: start;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border);
    transition: padding-left var(--dur-fast) var(--ease-snap);
}

.process-step:last-child { border-bottom: none; }
.process-step:hover { padding-left: 10px; }

.process-step span.step-num {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0.06em;
    padding-top: 2px;
}

.process-step .step-title {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.98rem;
    color: var(--headers);
    display: block;
    margin-bottom: 0.3rem;
}

.process-step p {
    font-size: 0.88rem;
    line-height: 1.7;
}

/* ── 12. DEMO — markdown TUI console ───────────────────────────── */
.demo__intro {
    font-size: 0.95rem;
    color: var(--text-muted);
    max-width: 58ch;
    margin-top: 0.6rem;
    line-height: 1.7;
}

.tui {
    margin-top: 2rem;
    background: var(--bg-soft);
    border: 1px solid var(--border-strong);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    overflow: hidden;
}

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

.tui__dots { display: inline-flex; gap: 6px; }
.tui__dots span {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--border-strong);
}

.tui__filename {
    font-size: 0.76rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

/* Was .tui__live, a green dot pulsing over numbers that were generated in
   JavaScript. The panel is now measured at build time, so the slot carries
   the date it was measured on and holds still. */
.tui__stamp {
    margin-left: auto;
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.tui__body { padding: 18px 20px 6px; }

.tui__h1, .tui__h2 {
    color: var(--highlight-text);
    font-weight: 500;
}

.tui__h1 { font-size: 0.92rem; margin-bottom: 14px; }
.tui__h2 { font-size: 0.85rem; margin: 18px 0 8px; }
.tui__h2:first-child { margin-top: 0; }

.tui__metrics { display: flex; flex-direction: column; gap: 3px; margin-bottom: 4px; }
.tui__metric { display: flex; gap: 10px; color: var(--text); }
.tui__metric-key { color: var(--text-muted); min-width: 20ch; }
.tui__metric-key::before { content: '  '; white-space: pre; }

.tui__log {
    display: flex;
    flex-direction: column;
    list-style: none;
    margin: 0;
    padding: 0 0 14px;
}

.tui__line {
    padding: 2px 0;
    color: var(--text);
    white-space: pre-wrap;
}

.tui__check { color: var(--yellow-text); }

.tui__prompt {
    padding: 8px 0 16px;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
}

.demo__source {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text-muted);
    max-width: 68ch;
    margin-top: 1rem;
    line-height: 1.8;
}

.demo__source a { color: var(--text); text-underline-offset: 3px; }

.tui__cursor {
    display: inline-block;
    width: 7px;
    height: 1em;
    background: var(--highlight-text);
    vertical-align: -2px;
    margin-left: 2px;
    animation: blink 1s step-end infinite;
}

@keyframes blink { 50% { opacity: 0; } }

/* ── 13. FRAMEWORKS ───────────────────────────────────────────── */
#frameworks p.note { font-family: var(--font-mono); font-size: 0.82rem; color: var(--text-muted); margin-top: 1.25rem; }

/* ── 14. INDUSTRIES ───────────────────────────────────────────── */
#industries .five-column-grid {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 0.5rem;
}

#industries span {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    transition: color var(--dur-fast) ease;
}

#industries span:hover { color: var(--highlight-text); }

/* ── 15. FAQ ACCORDION ────────────────────────────────────────── */
#faq h2 { margin-bottom: 2rem; }

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

.faq-trigger {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    color: var(--headers);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 1.2rem 0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transition: color var(--dur-fast) ease;
}

.faq-trigger:hover { color: var(--highlight-text); }

.faq-trigger::after {
    content: "+";
    font-family: var(--font-body);
    font-size: 1.3rem;
    font-weight: 300;
    flex-shrink: 0;
    color: var(--text-muted);
    transition: transform var(--dur-fast) var(--ease-snap);
    line-height: 1;
}

.faq-trigger[aria-expanded="true"]::after { transform: rotate(45deg); }

.faq-answer {
    overflow: hidden;
    max-height: 0;
    transition: max-height var(--dur-base) ease, padding var(--dur-base) ease;
}

.faq-answer.open { max-height: 300px; padding: 0 0 1.25rem 0; }

.faq-answer p {
    font-family: var(--font-body);
    font-size: 0.88rem;
    line-height: 1.8;
    color: var(--text-muted);
    padding-left: 1.1rem;
    border-left: 2px solid var(--border-strong);
}

/* ── 16. CONTACT SECTION ──────────────────────────────────────── */
#contact p { font-size: 0.9rem; line-height: 1.7; margin-bottom: 0.5rem; color: var(--text-muted); }

#contact a {
    font-family: var(--font-mono);
    font-weight: 500;
    color: var(--headers);
    transition: color var(--dur-fast) ease;
}

#contact a:hover { color: var(--highlight-text); }

/* ── 17. FOOTER ───────────────────────────────────────────────── */
footer {
    border-top: 1px solid var(--border);
    padding: 3rem 2rem;
    transition: border-color 0.3s ease;
}

.footer-container {
    max-width: 1140px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer-brand p { font-size: 0.85rem; line-height: 1.8; color: var(--text); }
.footer-brand strong { font-family: var(--font-body); font-weight: 600; color: var(--headers); }

.footer-brand a { color: var(--text); transition: color var(--dur-fast) ease; }
.footer-brand a:hover { color: var(--highlight-text); }

.copyright { color: var(--text-muted) !important; margin-top: 0.5rem; font-family: var(--font-mono); font-size: 0.7rem !important; }

/* The two link lists read as one block, so they sit tight to each other.
   The button keeps the 1.5rem it always had, moved onto the button itself. */
.footer-links { display: flex; flex-direction: column; align-items: flex-end; gap: 0.25rem; }
.footer-links .back-to-top { margin-top: 1.25rem; }

/* line-height:1 for the same reason as .theme-toggle: without it the list
   items inherit body's and each 11.2px link sits in a 43.5px line box. The
   row looked right only because that accidental strut happened to be about
   the height a tap target should be. The link itself was 14.4px tall, which
   is what a thumb actually had to hit. It is now the box, at 44px, and the
   row height is deliberate rather than a leftover. */
.footer-nav {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0 1rem;
    justify-content: flex-end;
    line-height: 1;
}

.footer-nav li a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text);
    transition: color var(--dur-fast) ease;
}

.footer-nav li a:hover { color: var(--highlight-text); }

.back-to-top {
    background: none;
    border: 1px solid var(--headers);
    border-radius: 999px;
    color: var(--headers);
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    padding: 0.45rem 1.1rem;
    cursor: pointer;
    transition: background var(--dur-fast) ease, color var(--dur-fast) ease;
}

.back-to-top:hover { background: var(--headers); color: var(--bg); }

.footer-meta {
    max-width: 1140px;
    margin: 1.75rem auto 0;
    padding-top: 1.1rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

/* ── 18. SHARED PAGE PRIMITIVES ───────────────────────────────── */
/* Promoted out of per-page <style> blocks once each pattern appeared on
   three or more pages. Page-scoped blocks are parsed AFTER this file, so a
   page that genuinely needs a different value still overrides at equal
   specificity with one line. Census at promotion: .cta-row 13 copies,
   .content-block 6, .tech-list 4, .decision / .metric / .honesty 3 each. */

.content-block { max-width: 640px; }
.content-block h2 { margin-bottom: 1rem; }
.content-block p {
    font-size: clamp(0.95rem, 1.3vw, 1.05rem);
    line-height: 1.75;
    color: var(--text-muted);
    margin-bottom: 1.4rem;
}
.content-block p:last-child { margin-bottom: 0; }

.cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem;
    margin-top: 2rem;
}

/* The closing "Next step" band. Was a copy-pasted eyebrow + h2 + .cta-row
   trio on 10 pages, wrapped in three different section variants, so the
   rhythm had already started to drift. The section still chooses its own
   surface (plain or .section--soft); this only fixes the internal spacing
   and the supporting paragraph, which is what was inconsistent. */
.next-step h2 { margin-bottom: 0; }
.next-step p {
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-muted);
    max-width: 52ch;
    margin-top: 0.8rem;
}
.next-step .cta-row { margin-top: 2.2rem; }

/* ── Contact CTA backdrop ─────────────────────────────────────
   Every band whose CTA leads to the contact page shares one
   photographic backdrop: the Skybound wind farm, dimmed so copy
   stays legible. That is .next-step site-wide plus the homepage
   #contact section (marked .contact-cta-bg). Text is forced light
   in both themes because the overlay darkens the surface; the pink
   headline accent follows the hero precedent and goes yellow. */
.next-step,
#contact.contact-cta-bg {
    background:
        linear-gradient(rgba(10, 14, 20, 0.58), rgba(10, 14, 20, 0.58)),
        url("../images/skybound-wind-farm-haven.webp") center / cover no-repeat;
}
.next-step .eyebrow,
#contact.contact-cta-bg .eyebrow { color: rgba(255, 255, 255, 0.75); }
.next-step h2,
#contact.contact-cta-bg h2 {
    color: #FFFFFF;
    text-shadow: 0 1px 2px rgba(9, 11, 14, 0.5);
}
.next-step h2 .highlight-box,
#contact.contact-cta-bg h2 .highlight-box { color: var(--yellow); }
.next-step p,
#contact.contact-cta-bg p {
    color: rgba(255, 255, 255, 0.85);
    text-shadow: 0 1px 2px rgba(9, 11, 14, 0.5);
}
.next-step .cta-link { color: #FFFFFF; }
.next-step .cta-link::after { background: #FFFFFF; }

.tech-list { list-style: none; margin-top: 1.2rem; }
.tech-list li {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--text);
    letter-spacing: 0.02em;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}
.tech-list li:last-child { border-bottom: none; }
.tech-list .tech-desc { color: var(--text-muted); text-align: right; }

/* Case-study patterns. Open rows with top-border separators, per the house
   rule that those beat nested boxes. */
.decisions { margin-top: 2.6rem; }
.decision { border-top: 1px solid var(--border); padding: 1.8rem 0; }
.decision:last-child { border-bottom: 1px solid var(--border); }
.decision h3 {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 1.02rem;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    max-width: 56ch;
}
.decision h3::before {
    content: 'Rejected';
    display: block;
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.55rem;
}
.decision p {
    font-size: 0.9rem;
    line-height: 1.8;
    color: var(--text-muted);
    max-width: 68ch;
    margin: 0;
}

.metrics { margin-top: 2.4rem; }
.metric {
    display: grid;
    grid-template-columns: 8.5rem 1fr;
    gap: 0.4rem 2rem;
    align-items: baseline;
    border-top: 1px solid var(--border);
    padding: 1.15rem 0;
}
.metric:last-child { border-bottom: 1px solid var(--border); }
.metric-value {
    font-family: var(--font-mono);
    font-size: 1.02rem;
    font-weight: 500;
    color: var(--headers);
    font-variant-numeric: tabular-nums;
}
.metric-body { min-width: 0; }
.metric-label {
    font-family: var(--font-mono);
    font-size: 0.66rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    display: block;
    margin-bottom: 0.3rem;
}
.metric-note {
    font-size: 0.88rem;
    line-height: 1.75;
    color: var(--text-muted);
    margin: 0;
    max-width: 64ch;
}

/* What could not be measured. Yellow, not pink: pink has four jobs and this
   is none of them. */
.honesty {
    margin-top: 2.6rem;
    border-left: 2px solid var(--yellow);
    padding: 1.1rem 0 1.1rem 1.4rem;
    max-width: 68ch;
}
.honesty .honesty-label {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-muted);
    display: block;
    margin-bottom: 0.6rem;
}
.honesty p {
    font-size: 0.9rem;
    line-height: 1.8;
    color: var(--text-muted);
    margin: 0;
    max-width: 66ch;
}

/* Service detail patterns. Shared because the services index and its four
   detail pages all use them. */
.service-goal {
    font-family: var(--font-mono);
    font-size: 0.74rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--headers);
}
.service-goal::before { content: "Goal // "; color: var(--text-muted); }

.deliverables-label {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}
/* Support tier price, sitting on the same line as the tier name. Sentence
   case on purpose: the label above it is already tracked-out uppercase, and
   two tracked-out runs on one line read as a templated price table. */
.tier-price {
    float: right;
    text-transform: none;
    letter-spacing: 0.02em;
    color: var(--headers);
}

.deliverables-list { list-style: none; max-width: 46ch; }
.deliverables-list li {
    display: flex;
    align-items: baseline;
    gap: 0.6rem;
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--text);
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border);
}
.deliverables-list li:last-child { border-bottom: none; }
.deliverables-list li::before {
    content: "//";
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-muted);
    flex-shrink: 0;
}

.faq-header {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

/* 68ch rather than the old 720px: at the 0.88rem answer size that pixel cap
   worked out near 100 characters, well past a comfortable measure. */
.service-faq { max-width: 68ch; margin-top: 2.5rem; }
.service-faq .faq-trigger { font-size: 0.9rem; padding: 1rem 0; }
.service-faq .faq-answer p { max-width: 72ch; }
/* The shared .faq-answer cap is 300px with overflow hidden and no scrollbar,
   and the longest service answer sits right on that threshold at 360px. Raise
   it here only, never the shared value. */
.service-faq .faq-answer.open { max-height: 520px; }

@media (max-width: 640px) {
    .metric { grid-template-columns: 1fr; gap: 0.35rem; }
}

/* ── 19. RESPONSIVE ───────────────────────────────────────────── */
.desktop-only { display: flex; }

@media (max-width: 1024px) {
    .process-step { grid-template-columns: 50px 1fr; }
}

@media (max-width: 900px) {
    .grid { grid-template-columns: repeat(2, 1fr); }
    .service-card { border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
    .hero p { max-width: 100%; }
}

@media (max-width: 768px) {
    .desktop-only { display: none; }
    #hamburger { display: flex; }

    nav { padding: 0 1.2rem; }

    .hero {
        padding-top: clamp(96px, 18vw, 130px);
        /* Copy runs full width down here (see the 900px rule), so the
           left-weighted ramp would leave the line ends under-scrimmed.
           Go vertical and flatten it out instead. Swapping the token is
           the whole override — the four-layer background is written once. */
        --hero-scrim: linear-gradient(180deg,
                          rgba(9, 11, 14, 0.84) 0%,
                          rgba(9, 11, 14, 0.76) 55%,
                          rgba(9, 11, 14, 0.88) 100%);
    }

    .grid { grid-template-columns: 1fr; }
    .service-card { border-right: none; border-bottom: 1px solid var(--border); }
    .service-card:last-child { border-bottom: none; }

    .process-step { grid-template-columns: 40px 1fr; }

    .footer-links { align-items: flex-start; }
    .footer-nav { justify-content: flex-start; }
    .footer-container { flex-direction: column; }

    /* Mobile keeps an icon-only circle: labels off, mover centred,
       travel disabled, only the roll + sun/moon crossfade remains. */
    .theme-toggle { width: 30px; height: 30px; }
    :root[data-theme="light"] .theme-toggle { border-color: #dedede; }
    .theme-toggle__label { display: none; }
    .theme-toggle__mover {
        left: 50%;
        width: 18px;
        height: 18px;
        transform: translate(-50%, -50%) rotate(0deg);
    }
    /* Mobile moon sits 30° counter-clockwise from the desktop tilt. */
    .theme-toggle__icon--moon { transform: scale(-0.6, -0.6) rotate(15deg); }
    :root[data-theme="dark"] .theme-toggle__icon--moon { transform: scale(-1, -1) rotate(15deg); }
    :root[data-theme="dark"] .theme-toggle__mover {
        transform: translate(-50%, -50%) rotate(-180deg);
    }

    .sprite-preview__pill { padding: 8px 18px 8px 8px; gap: 12px; }
    .sprite-preview__text { font-size: 0.86rem; }
}

@media (max-width: 480px) {
    .hero h1 { letter-spacing: -0.01em; }
    footer { padding: 2rem 1.2rem; }
    .footer-meta { padding: 0 1.2rem; }
    .sprite-preview__pill { display: flex; }
    .sprite-preview__text { font-size: 0.82rem; }
}

/* ── 20. COPY REWORK PRIMITIVES ───────────────────────────────────
   Nav lockup, the new home/service blocks, the blog lane filter and the
   text-led About page. Shared because each appears on more than one page
   or in more than one generated template. */

.logo { gap: 0.85rem; }
.logo__tagline {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    line-height: 1.3;
    letter-spacing: 0.02em;
    color: var(--text-muted);
    max-width: 150px;
    text-transform: none;
}
.logo:hover .logo__tagline { color: var(--text); }

.nav-cta {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0.45rem 1rem;
    border: 1px solid var(--headers);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--headers);
    white-space: nowrap;
    transition: background var(--dur-fast) ease, color var(--dur-fast) ease;
}
.nav-cta:hover { background: var(--headers); color: var(--bg); }

.mobile-menu li a.mobile-menu__cta {
    display: inline-flex;
    margin-top: 0.6rem;
    padding: 0.7rem 1.3rem;
    border: 1px solid var(--headers);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.mobile-menu li a.mobile-menu__cta:hover { color: var(--bg); background: var(--headers); }

/* Hero: one primary pill, one quiet second route. */
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem 2rem;
    margin-top: 1.7rem;
}
.hero-secondary {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-strong);
    padding-bottom: 2px;
    transition: color var(--dur-fast) ease, border-color var(--dur-fast) ease;
}
.hero-secondary:hover { color: var(--highlight-text); border-color: var(--highlight-text); }

/* What you get: four open cells, no cards. */
.get-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    margin-top: 1.8rem;
    border-top: 1px solid var(--border);
}
.get-item {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 1rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border);
}
.get-item:nth-child(odd) { padding-right: 2rem; border-right: 1px solid var(--border); }
.get-item:nth-child(even) { padding-left: 2rem; }
.get-num {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    color: var(--text-muted);
}
.get-item h3 {
    font-family: var(--font-body);
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--headers);
    margin-bottom: 0.35rem;
}
.get-item p { font-size: 0.88rem; line-height: 1.7; color: var(--text-muted); max-width: 54ch; }

/* Services price table. */
.price-table, .terms-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1.6rem;
}
.price-table th, .terms-table th {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: left;
    color: var(--text-muted);
    padding: 0 0 0.7rem;
    border-bottom: 1px solid var(--border-strong);
}
.price-table td, .terms-table td {
    padding: 1.35rem 0;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}
.price-table td:first-child { font-family: var(--font-body); font-weight: 600; color: var(--headers); width: 24%; }
.price-table td:nth-child(2) { font-family: var(--font-mono); font-size: 0.8rem; color: var(--highlight-text); width: 16%; white-space: nowrap; }
.price-table td:last-child { font-size: 0.88rem; line-height: 1.7; color: var(--text-muted); }
.terms-table td:first-child { font-family: var(--font-body); font-weight: 600; color: var(--headers); width: 18%; }
.terms-table td:last-child { font-size: 0.88rem; line-height: 1.7; color: var(--text-muted); }

/* Proof bullets above the measured block. */
.proof-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem 2.5rem;
    margin: 1.8rem 0 1.6rem;
    list-style: none;
}
.proof-list li {
    border-top: 1px solid var(--border);
    padding-top: 0.9rem;
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-muted);
}
.proof-list strong { color: var(--headers); font-weight: 600; }
.measure-link { margin-top: 0.4rem; }

/* Fit / not a fit. */
.fit-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; margin-top: 1.8rem; }
.fit-card { border-top: 2px solid var(--headers); padding-top: 1.1rem; }
.fit-card--no { border-top-color: var(--border-strong); }
.fit-card h3 { font-family: var(--font-body); font-size: 1rem; font-weight: 600; margin-bottom: 0.8rem; }
.fit-list { list-style: none; }
.fit-list li {
    position: relative;
    padding: 0.7rem 0 0.7rem 1.4rem;
    border-bottom: 1px solid var(--border);
    font-size: 0.88rem;
    line-height: 1.65;
    color: var(--text-muted);
}
.fit-list li::before { position: absolute; left: 0; top: 0.7rem; font-family: var(--font-mono); color: var(--highlight-text); }
.fit-card:not(.fit-card--no) .fit-list li::before { content: "\2192"; }
.fit-card--no .fit-list li::before { content: "\00D7"; color: var(--text-muted); }

/* Ways to work. */
.ways-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin-top: 1.8rem;
    border-top: 1px solid var(--border);
}
.way-card { padding: 1.5rem 1.5rem 1.5rem 0; border-bottom: 1px solid var(--border); }
.way-card + .way-card { padding-left: 1.5rem; border-left: 1px solid var(--border); }
.way-num { font-family: var(--font-mono); font-size: 0.7rem; color: var(--text-muted); letter-spacing: 0.08em; }
.way-card h3 { font-family: var(--font-body); font-size: 1rem; font-weight: 600; margin: 0.5rem 0 0.45rem; }
.way-card p { font-size: 0.88rem; line-height: 1.7; color: var(--text-muted); }

/* About teaser on Home. */
.about-teaser { display: grid; grid-template-columns: 1.5fr 0.5fr; gap: 2rem; align-items: end; margin-top: 1.4rem; }
.about-teaser p { font-size: 0.95rem; line-height: 1.8; color: var(--text-muted); max-width: 64ch; margin-bottom: 0.9rem; }
.about-teaser .cta-link { font-size: 0.8rem; }

/* Services page offers. */
.offer { border-top: 1px solid var(--border); padding: 2rem 0; display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 2.5rem; }
.offer:last-of-type { border-bottom: 1px solid var(--border); }
.offer h3 { font-family: var(--font-title); font-weight: 400; font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.15; margin-bottom: 0.5rem; }
.offer__price { font-family: var(--font-mono); font-size: 0.8rem; color: var(--highlight-text); letter-spacing: 0.02em; }
.offer__lead { font-size: 0.9rem; line-height: 1.7; color: var(--text-muted); margin-top: 0.9rem; max-width: 48ch; }
.offer__body p { font-size: 0.9rem; line-height: 1.7; color: var(--text-muted); margin-bottom: 0.9rem; }
.offer__label { font-family: var(--font-mono); font-size: 0.68rem; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin: 1.2rem 0 0.5rem; }
.included-list { list-style: none; }
.included-list li { position: relative; padding: 0.45rem 0 0.45rem 1.2rem; font-size: 0.88rem; line-height: 1.65; color: var(--text-muted); border-bottom: 1px solid var(--border); }
.included-list li::before { content: "\2013"; position: absolute; left: 0; color: var(--text-muted); }
.offer__meta { font-family: var(--font-mono); font-size: 0.72rem; line-height: 1.7; color: var(--text-muted); margin-top: 1rem; }
.promise-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; margin-top: 1.6rem; }
.promise-card { border-top: 1px solid var(--border); padding-top: 1rem; }
.promise-card h3 { font-family: var(--font-body); font-size: 0.98rem; font-weight: 600; margin-bottom: 0.8rem; }
.promise-card ul { list-style: none; }
.promise-card li { padding: 0.5rem 0; border-bottom: 1px solid var(--border); font-size: 0.88rem; color: var(--text-muted); }
.promise-card p { font-size: 0.9rem; line-height: 1.7; color: var(--text-muted); }

/* About page. */
.about-body { max-width: 66ch; }
.about-body p { font-size: 1rem; line-height: 1.85; color: var(--text); margin-bottom: 1.4rem; }
.about-body p:last-child { margin-bottom: 0; }
.about-body .about-lead { font-size: clamp(1.1rem, 2vw, 1.35rem); line-height: 1.6; color: var(--headers); }

/* Blog lane filter. */
.lane-filter { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1.8rem; }
.lane-btn {
    border: 1px solid var(--border-strong);
    background: none;
    border-radius: 999px;
    padding: 0.5rem 0.95rem;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text);
    cursor: pointer;
    transition: background var(--dur-fast) ease, color var(--dur-fast) ease, border-color var(--dur-fast) ease;
}
.lane-btn:hover { border-color: var(--headers); }
.lane-btn[aria-pressed="true"] { background: var(--headers); color: var(--bg); border-color: var(--headers); }
.post-lane { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted); }
.article-row[hidden] { display: none; }

@media (max-width: 1280px) {
    .logo__tagline { display: none; }
}
@media (max-width: 1180px) {
    .nav-cta { display: none; }
}
@media (max-width: 900px) {
    .get-grid, .proof-list, .fit-grid, .promise-grid, .about-teaser { grid-template-columns: 1fr; }
    .get-item:nth-child(odd), .get-item:nth-child(even) { padding-left: 0; padding-right: 0; border-right: none; }
    .ways-grid { grid-template-columns: 1fr; }
    .way-card, .way-card + .way-card { padding-left: 0; border-left: none; }
    .offer { grid-template-columns: 1fr; gap: 1.2rem; }
}
@media (max-width: 700px) {
    .price-table thead, .terms-table thead { display: none; }
    .price-table tr, .terms-table tr { display: block; padding: 1.1rem 0; border-bottom: 1px solid var(--border); }
    .price-table td, .terms-table td { display: block; padding: 0; border: none; }
    .price-table td:first-child, .terms-table td:first-child { width: auto; margin-bottom: 0.2rem; }
    .price-table td:nth-child(2) { width: auto; margin-bottom: 0.5rem; }
    .price-table td:last-child, .terms-table td:last-child { margin-top: 0.4rem; }
}

/* Project card titles are shared by Home and Work; the Work page uses h2
   for the section hierarchy, Home uses h3. Keep both on the card voice. */
.proj-card__title {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: clamp(1.1rem, 2vw, 1.35rem);
    line-height: 1.25;
    color: #FFFFFF;
    margin-bottom: 0.6rem;
}
