:root {
    --paper:        #f4f1ea;
    --paper-2:      #ece8de;
    --rule:         #d9d4c5;
    --rule-2:       #c4bfae;
    --ink:          #1a1a17;
    --ink-2:        #4a4842;
    --ink-3:        #837f72;
    --clay:         oklch(58% 0.13 40);
    --clay-soft:    oklch(58% 0.13 40 / 0.10);
    --clay-rule:    oklch(58% 0.13 40 / 0.35);
    --clay-wash:    oklch(58% 0.13 40 / 0.04);
    --clay-glow:    oklch(58% 0.13 40 / 0.50);
    --clay-bg-hi:   oklch(58% 0.13 40 / 0.06);
    --ink-shadow:   rgb(26 26 23 / 0.18);
    /* RGB triple for elevation shadows + scrims used at varying alphas
     * (rgb(var(--shadow-rgb) / N)). Light = ink; flips to black in dark so
     * shadows stay visible on a dark surface (DESIGN.md §9.2.1). */
    --shadow-rgb:   26 26 23;
    --star-glow:    oklch(80% 0.15 80);

    --maxw: 1240px;
    --gutter: clamp(20px, 4vw, 56px);
    --serif: "Instrument Serif", "Times New Roman", serif;
    --sans:  "Geist", ui-sans-serif, system-ui, sans-serif;
    --mono:  "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  }

  /* Warm-dark mode (DESIGN.md §9.1) — token-only override, same names with
   * paper ↔ ink swapped. Landed in lockstep with the app + registry surfaces
   * (§9.2.5). --clay + --star-glow stay identical (OKLCH keeps them balanced).
   * The marketing site has no app-functional status tokens, so only the shared
   * palette flips.
   *
   * Two entry points (DESIGN.md §9.2 #3): the `prefers-color-scheme: dark` media
   * query is the OS-pref DEFAULT (and the no-JS fallback); a manual `.theme-dark`
   * / `.theme-light` class on <html> (set by the nav toggle, applied pre-paint by
   * the inline <head> script) is the explicit override and wins over the OS pref.
   * The media query yields to `.theme-light` so a dark-OS user can force light;
   * `.theme-dark` forces dark on a light OS. The two dark blocks carry identical
   * tokens by design. */
  @media (prefers-color-scheme: dark) {
    :root:not(.theme-light) {
      --paper:        #1a1a17;
      --paper-2:      #232220;
      --rule:         #3a3833;
      --rule-2:       #4a4842;
      --ink:          #f4f1ea;
      --ink-2:        #d9d4c5;
      --ink-3:        #a8a39a;
      --ink-shadow:   rgb(0 0 0 / 0.35);
      --shadow-rgb:   0 0 0;
    }
  }
  :root.theme-dark {
    --paper:        #1a1a17;
    --paper-2:      #232220;
    --rule:         #3a3833;
    --rule-2:       #4a4842;
    --ink:          #f4f1ea;
    --ink-2:        #d9d4c5;
    --ink-3:        #a8a39a;
    --ink-shadow:   rgb(0 0 0 / 0.35);
    --shadow-rgb:   0 0 0;
  }

  * { box-sizing: border-box; }
  /* The mobile nav drawer is `position: fixed` parked off-canvas via
   * `translateX(100%)`, so its box sits past the right edge and extends the
   * horizontal scroll area (~25px of dead scroll on phones) even while
   * closed/`visibility:hidden`. A fixed element is positioned against the
   * viewport (the initial containing block), so it ESCAPES `overflow` on
   * `body` — the clip has to live on the root `html`. `overflow-x: clip`
   * (not `hidden`) removes the dead scroll WITHOUT creating a scroll
   * container, so `position: sticky` (the spec-page ToC rail) keeps
   * working. */
  html { overflow-x: clip; }
  html, body { margin: 0; padding: 0; }

  body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    /* Faint paper texture via two layered gradients — keeps weight and warmth */
    background-image:
      radial-gradient(1200px 700px at 80% -10%, var(--clay-bg-hi), transparent 60%),
      radial-gradient(900px 600px at -10% 110%, var(--clay-wash), transparent 70%);
    background-attachment: fixed;
  }

  ::selection { background: var(--clay); color: var(--paper); }

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

  /* ─── Layout ────────────────────────────────────────────────────────── */
  .wrap {
    max-width: var(--maxw);
    margin-inline: auto;
    padding-inline: var(--gutter);
  }

  .rule {
    border: 0;
    border-top: 1px solid var(--rule);
    margin: 0;
  }

  /* ─── Mono section markers ─────────────────────────────────────────── */
  .marker {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-3);
    display: inline-flex;
    align-items: center;
    gap: 10px;
  }
  .marker .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--clay); }

  /* ─── Top bar ──────────────────────────────────────────────────────── */
  .topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(8px);
    background: color-mix(in srgb, var(--paper) 88%, transparent);
    border-bottom: 1px solid var(--rule);
  }
  .topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
  }
  /* Topbar brand mark — mirrors the registry's <h1 class="brand-mark"> and
   * the app's .app-header h1.brand-mark register: SVG icon + Instrument
   * Serif "Open<em>WOP</em>" with italic-clay "WOP" + mono uppercase
   * sub-label. Sized down (28px icon, 20px serif) to fit the 64px-tall
   * sticky topbar without crowding the nav. */
  .brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--serif);
    font-weight: 400;
    font-size: 20px;
    line-height: 1;
    letter-spacing: -0.01em;
    color: var(--ink);
  }
  .brand-mark {
    width: 28px !important;
    height: 28px !important;
    display: block;
    flex-shrink: 0;
  }
  .brand em {
    font-style: italic;
    color: var(--clay);
  }
  .brand-sub {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-style: normal;
    color: var(--ink-3);
    margin-left: 4px;
  }
  @media (max-width: 480px) {
    /* On very narrow viewports the sub-label crowds the GitHub pill;
     * drop it and keep just the icon + brand. */
    .brand-sub { display: none; }
  }

  .topnav {
    display: flex;
    align-items: center;
    gap: 28px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink-2);
  }
  .topnav a:hover { color: var(--clay); }
  .topnav .pill {
    border: 1px solid var(--ink);
    border-radius: 999px;
    padding: 6px 12px;
    color: var(--ink);
    font-family: var(--mono);
    font-size: 12px;
    transition: background .2s ease, color .2s ease;
  }
  .topnav .pill:hover { background: var(--ink); color: var(--paper); }

  @media (max-width: 760px) {
    .topnav .hide-sm { display: none; }
  }

  /* ─── Nav: dropdown menus (desktop) ───────────────────────────────── */
  .nav-dropdown { position: relative; display: inline-flex; align-items: center; }
  /* Invisible "bridge" that fills the visual gap between the trigger and
   * the menu. Without it, the cursor crossing the 10px gap leaves the
   * .nav-dropdown bounding box and `:hover` drops, dismissing the menu
   * before the user can reach it. The bridge needs `pointer-events: auto`
   * (the default) so the cursor crossing it still counts as "inside" the
   * dropdown for :hover purposes — a 14px hover-forgiveness margin below
   * each trigger is desirable UX, not noise. */
  .nav-dropdown::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: 14px;
  }
  .nav-dropdown-trigger {
    appearance: none;
    background: transparent;
    border: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
    color: inherit;
    font: inherit;
    font-size: 12.5px;
    letter-spacing: inherit;
    display: inline-flex;
    align-items: center;
    gap: 4px;
  }
  .nav-dropdown-trigger:hover,
  .nav-dropdown.active > .nav-dropdown-trigger { color: var(--clay); }
  .nav-dropdown-trigger .nav-caret {
    font-size: 9px;
    line-height: 1;
    transform: translateY(1px);
    transition: transform .15s ease;
  }
  .nav-dropdown.is-open .nav-caret { transform: translateY(1px) rotate(180deg); }
  .nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    min-width: 220px;
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 10px;
    box-shadow: 0 10px 24px var(--ink-shadow);
    padding: 8px;
    display: none;
    flex-direction: column;
    z-index: 60;
  }
  .nav-dropdown:hover > .nav-dropdown-menu,
  .nav-dropdown.is-open > .nav-dropdown-menu,
  .nav-dropdown:focus-within > .nav-dropdown-menu { display: flex; }
  .nav-dropdown-menu a {
    display: block;
    padding: 8px 12px;
    border-radius: 6px;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.35;
  }
  .nav-dropdown-menu a:hover,
  .nav-dropdown-menu a:focus-visible {
    background: var(--paper-2);
    color: var(--clay);
    outline: none;
  }

  /* ─── Nav: mobile hamburger + drawer ──────────────────────────────── */
  .nav-toggle {
    appearance: none;
    background: transparent;
    border: 1px solid var(--rule);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    padding: 0;
    margin: 0;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--ink);
  }
  .nav-toggle svg { width: 18px; height: 18px; }
  .nav-toggle .icon-close { display: none; }
  .nav-toggle[aria-expanded="true"] .icon-open { display: none; }
  .nav-toggle[aria-expanded="true"] .icon-close { display: inline-block; }

  /* Single-button light/dark toggle (DESIGN.md §9.2 #3). Same chrome as
   * .nav-toggle but always visible (desktop + mobile). The icon reflects the
   * ACTIVE theme — moon while light, sun while dark — tracking the same
   * precedence as the token blocks (OS-pref unless a manual class is set). */
  .theme-toggle {
    appearance: none;
    background: transparent;
    border: 1px solid var(--rule);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--ink-2);
    transition: color .2s ease, border-color .2s ease;
  }
  .theme-toggle:hover { color: var(--clay); border-color: var(--clay-rule); }
  .theme-toggle svg { width: 17px; height: 17px; }
  .theme-toggle .icon-sun { display: none; }
  .theme-toggle .icon-moon { display: inline-flex; }
  @media (prefers-color-scheme: dark) {
    :root:not(.theme-light) .theme-toggle .icon-sun { display: inline-flex; }
    :root:not(.theme-light) .theme-toggle .icon-moon { display: none; }
  }
  :root.theme-dark .theme-toggle .icon-sun { display: inline-flex; }
  :root.theme-dark .theme-toggle .icon-moon { display: none; }

  .nav-scrim {
    position: fixed;
    inset: 0;
    background: rgb(var(--shadow-rgb) / 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
    z-index: 70;
  }
  .nav-scrim.is-open { opacity: 1; pointer-events: auto; }

  .nav-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(320px, 85vw);
    background: var(--paper);
    border-left: 1px solid var(--rule);
    box-shadow: -16px 0 32px var(--ink-shadow);
    padding: 20px 22px 28px;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform .25s ease-out;
    z-index: 80;
  }
  .nav-drawer.is-open { transform: translateX(0); }
  .nav-drawer.no-motion { transition: none; }
  .nav-drawer[aria-hidden="true"] { visibility: hidden; }
  .nav-drawer.is-open[aria-hidden="false"] { visibility: visible; }
  .nav-drawer-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--rule);
  }
  .nav-drawer-head .brand { gap: 8px; }
  .nav-drawer-close {
    appearance: none;
    background: transparent;
    border: 0;
    padding: 4px 8px;
    margin: 0;
    cursor: pointer;
    color: var(--ink-2);
    font-size: 22px;
    line-height: 1;
  }
  .nav-drawer h3 {
    margin: 18px 0 6px;
    font-family: var(--sans);
    text-transform: uppercase;
    letter-spacing: .12em;
    font-size: 11px;
    color: var(--ink-3);
    font-weight: 500;
  }
  .nav-drawer ul {
    list-style: none;
    margin: 0 0 4px;
    padding: 0;
  }
  .nav-drawer ul li a,
  .nav-drawer > a {
    display: block;
    padding: 9px 10px;
    border-radius: 6px;
    color: var(--ink);
    font-size: 14.5px;
  }
  .nav-drawer ul li a:hover,
  .nav-drawer > a:hover,
  .nav-drawer a:focus-visible {
    background: var(--paper-2);
    color: var(--clay);
    outline: none;
  }
  .nav-drawer .nav-drawer-cta {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid var(--rule);
  }
  .nav-drawer .nav-drawer-cta a {
    font-weight: 500;
  }

  /* Collapse the horizontal nav to the hamburger + drawer below 960px.
   * The full subpage topnav (links + Protocol/Implement dropdowns + search
   * + GitHub pill + theme toggle) needs ~940px to lay out; the previous
   * 760px breakpoint left a 761–940px dead zone where the nav overflowed
   * the viewport (it widened when search + the theme toggle were added to
   * the subpage menu). The paired query below force-hides the drawer above
   * the breakpoint. */
  @media (max-width: 960px) {
    .nav-toggle { display: inline-flex; }
    .topnav .nav-dropdown,
    .topnav > a.hide-sm,
    .topnav > .pill { display: none; }
  }
  @media (min-width: 961px) {
    .nav-drawer,
    .nav-scrim,
    .nav-toggle { display: none !important; }
  }

  @media (prefers-reduced-motion: reduce) {
    .nav-drawer { transition: none; }
    .nav-scrim { transition: none; }
  }

  /* ─── Hero ─────────────────────────────────────────────────────────── */
  .hero {
    padding: clamp(56px, 9vw, 120px) 0 clamp(64px, 9vw, 110px);
    position: relative;
  }
  .hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: clamp(32px, 5vw, 80px);
    align-items: center;
  }
  @media (max-width: 920px) {
    .hero-grid { grid-template-columns: 1fr; gap: 56px; }
  }

  .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-family: var(--mono);
    font-size: 11.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-2);
    margin-bottom: 28px;
  }
  .eyebrow .v {
    color: var(--clay);
    border: 1px solid var(--clay-rule);
    border-radius: 999px;
    padding: 3px 9px;
    background: var(--clay-soft);
  }

  h1.headline {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(40px, 6vw, 80px);
    line-height: 0.98;
    letter-spacing: -0.015em;
    margin: 0 0 28px;
    color: var(--ink);
  }
  h1.headline em {
    font-style: italic;
    color: var(--clay);
  }
  h1.headline .small {
    display: block;
    font-style: italic;
    font-size: 0.42em;
    line-height: 1.2;
    letter-spacing: 0;
    color: var(--ink-2);
    margin-top: 14px;
    font-family: var(--serif);
  }

  .lede {
    font-size: 17.5px;
    line-height: 1.6;
    color: var(--ink-2);
    max-width: 46ch;
    margin: 0 0 36px;
  }

  /* Hero lede sits below the .meta-row chip rows; tighten the gap so the
   * paragraph reads as a separate beat from the chips rather than crowding
   * against them. Scoped to .hero so subpage .lede paragraphs (which have
   * no preceding meta-row) keep their existing top margin. */
  .hero .lede {
    margin-top: 32px;
  }

  .actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
  }
  .btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 13px 18px;
    font-family: var(--mono);
    font-size: 13px;
    letter-spacing: 0.01em;
    border-radius: 8px;
    transition: transform .15s ease, background .2s ease, color .2s ease, border-color .2s ease;
  }
  .btn-primary {
    background: var(--ink);
    color: var(--paper);
    border: 1px solid var(--ink);
  }
  .btn-primary:hover { background: var(--clay); border-color: var(--clay); }
  .btn-ghost {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--rule-2);
  }
  .btn-ghost:hover { border-color: var(--ink); }
  .btn .arrow { transition: transform .2s ease; }
  .btn:hover .arrow { transform: translateX(3px); }

  .meta-row {
    margin-top: 36px;
    display: flex;
    gap: 28px;
    flex-wrap: wrap;
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink-3);
  }
  .meta-row b { color: var(--ink); font-weight: 500; }
  .meta-link { color: inherit; border-bottom: 1px dotted var(--rule-2); transition: border-color .15s ease; }
  .meta-link:hover { border-bottom-color: var(--clay); }

  /* ─── Hero diagram ─────────────────────────────────────────────────── */
  .diagram-card {
    position: relative;
    aspect-ratio: 4 / 5;
    background:
      linear-gradient(180deg, var(--paper-2), var(--paper));
    border: 1px solid var(--rule);
    border-radius: 4px;
    overflow: hidden;
  }
  .diagram-card::before {
    /* plotter-paper grid */
    content: "";
    position: absolute; inset: 0;
    background-image:
      linear-gradient(to right, var(--rule) 1px, transparent 1px),
      linear-gradient(to bottom, var(--rule) 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.45;
    mask-image: radial-gradient(circle at 50% 50%, black 50%, transparent 90%);
  }
  .diagram-card .corner {
    position: absolute;
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-3);
    letter-spacing: 0.04em;
  }
  .diagram-card .tl { top: 14px; left: 16px; }
  .diagram-card .tr { top: 14px; right: 16px; }
  .diagram-card .bl { bottom: 14px; left: 16px; }
  .diagram-card .br { bottom: 14px; right: 16px; }

  .diagram-card svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
  }

  /* Mobile-only diagram summary — text fallback when SVG would be illegible */
  .diagram-mobile-summary { display: none; }
  @media (max-width: 760px) {
    .diagram-card { display: none; }
    .diagram-mobile-summary {
      display: block;
      list-style: none;
      counter-reset: step;
      margin: 0;
      padding: 0;
      border-top: 1px solid var(--rule);
    }
    .diagram-mobile-summary li {
      counter-increment: step;
      padding: 20px 0 20px 44px;
      position: relative;
      border-bottom: 1px solid var(--rule);
      font-size: 15px;
      line-height: 1.6;
      color: var(--ink-2);
    }
    .diagram-mobile-summary li::before {
      content: counter(step, decimal-leading-zero);
      position: absolute;
      left: 0;
      top: 22px;
      font-family: var(--mono);
      font-size: 11px;
      color: var(--clay);
      letter-spacing: 0.06em;
    }
    .diagram-mobile-summary strong { color: var(--ink); font-weight: 500; }
    .diagram-mobile-summary code {
      font-family: var(--mono);
      font-size: 0.9em;
      color: var(--clay);
    }
  }

  /* ─── Section frame ────────────────────────────────────────────────── */
  section.block {
    padding: clamp(64px, 8vw, 120px) 0;
    border-top: 1px solid var(--rule);
    /* Anchor links from the sticky subnav land above the topbar (64px) +
     * subnav (~44px) chrome instead of being hidden under them. */
    scroll-margin-top: 116px;
  }
  .block-head {
    display: block;
    margin-bottom: 56px;
  }
  @media (max-width: 760px) {
    .block-head { margin-bottom: 36px; }
  }
  .block-head .label { margin-bottom: 24px; }
  .block-head h2 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(34px, 4.4vw, 56px);
    line-height: 1.04;
    letter-spacing: -0.012em;
    margin: 0;
  }
  .block-head h2 em { font-style: italic; color: var(--clay); }
  .block-head .block-lede {
    color: var(--ink-2);
    font-size: 16px;
    line-height: 1.6;
    max-width: 64ch;
    margin: 14px 0 0;
  }

  /* ─── Prologue prose ───────────────────────────────────────────────── */
  /* Mobile-first: 1 column at narrow widths. At ≥760px the `columns`
     shorthand asks the browser for "up to 3 columns, each at least 19em
     wide"; the browser picks 2 or 3 based on available width and pours text
     continuously between them. Default `column-fill: balance` evens out
     column heights. Paragraphs intentionally do NOT have break-inside: avoid
     so they can split mid-graf for balancing; orphans/widows prevent
     single-line stragglers. */
  .prologue-body p {
    font-size: 17px;
    line-height: 1.7;
    margin: 0 0 14px;
  }
  .prologue-body .prologue-close {
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid var(--rule);
    font-family: var(--serif);
    font-size: clamp(20px, 1.9vw, 24px);
    line-height: 1.35;
    color: var(--ink);
    letter-spacing: -0.005em;
    column-span: all;
  }
  @media (min-width: 760px) {
    .prologue-body {
      columns: 19em 3;
      column-gap: clamp(28px, 3vw, 48px);
      column-rule: 1px solid var(--rule);
      orphans: 3;
      widows: 3;
    }
    .prologue-body p {
      font-size: 16px;
      line-height: 1.65;
      hyphens: auto;
    }
  }

  /* ─── Pillars (3-up) ───────────────────────────────────────────────── */
  .pillars {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .pillar {
    padding: 36px 32px 40px;
    border-right: 1px solid var(--rule);
    background: linear-gradient(180deg, transparent, transparent);
    transition: background .25s ease;
  }
  .pillar:last-child { border-right: none; }
  .pillar:hover { background: var(--clay-wash); }
  .pillar .num {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--ink-3);
    letter-spacing: 0.08em;
    margin-bottom: 32px;
    display: flex;
    justify-content: space-between;
  }
  .pillar h3 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 30px;
    line-height: 1.1;
    margin: 0 0 14px;
    letter-spacing: -0.01em;
  }
  .pillar p {
    margin: 0;
    color: var(--ink-2);
    font-size: 15px;
    line-height: 1.6;
  }
  .pillar .glyph {
    width: 44px;
    height: 44px;
    margin-bottom: 28px;
    color: var(--ink);
  }
  @media (max-width: 820px) {
    .pillars { grid-template-columns: 1fr; }
    .pillar { border-right: none; border-bottom: 1px solid var(--rule); }
    .pillar:last-child { border-bottom: none; }
  }

  /* ─── Anatomy ──────────────────────────────────────────────────────── */
  .anatomy {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 5vw, 72px);
    align-items: start;
  }
  @media (max-width: 920px) { .anatomy { grid-template-columns: 1fr; } }

  .ana-list {
    list-style: none;
    margin: 0;
    padding: 0;
  }
  .ana-list li {
    display: grid;
    grid-template-columns: 60px 1fr;
    gap: 18px;
    padding: 22px 0;
    border-top: 1px solid var(--rule);
  }
  .ana-list li:last-child { border-bottom: 1px solid var(--rule); }
  .ana-list .k {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--ink-3);
    padding-top: 4px;
  }
  .ana-list h3 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 22px;
    line-height: 1.2;
    margin: 0 0 6px;
  }
  .ana-list p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
    line-height: 1.55;
  }

  .ana-art {
    position: sticky;
    top: 90px;
    aspect-ratio: 4 / 5;
    background: var(--paper-2);
    border: 1px solid var(--rule);
    border-radius: 4px;
    overflow: hidden;
    padding: 36px;
  }
  .ana-art .legend {
    position: absolute;
    bottom: 18px;
    left: 18px;
    right: 18px;
    display: flex;
    justify-content: space-between;
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-3);
    letter-spacing: 0.04em;
  }

  /* ─── Anatomy — per-block expanded layout ──────────────────────── */
  .ana-block {
    padding: clamp(36px, 5vw, 64px) 0;
    border-top: 1px solid var(--rule);
  }
  .ana-block:last-child { border-bottom: 1px solid var(--rule); }
  .ana-block-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: clamp(20px, 3vw, 32px);
    flex-wrap: wrap;
  }
  .ana-block-key {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.10em;
    color: var(--clay);
    background: var(--paper-2);
    border: 1px solid var(--clay-rule);
    border-radius: 99px;
    padding: 6px 12px;
    line-height: 1;
    flex: 0 0 auto;
  }
  .ana-block-title {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: clamp(26px, 3.4vw, 36px);
    line-height: 1.15;
    margin: 0;
    flex: 1 1 auto;
  }
  .ana-block-tag {
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.04em;
    color: var(--ink-3);
    background: var(--paper-2);
    padding: 6px 12px;
    border: 1px solid var(--rule);
    border-radius: 99px;
    line-height: 1;
  }
  .ana-block-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: clamp(28px, 4vw, 56px);
    align-items: start;
  }
  .ana-block.reverse .ana-block-body {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  }
  .ana-block.reverse .ana-block-fig { order: -1; }
  .ana-block.wide .ana-block-body { grid-template-columns: 1fr; }
  .ana-block-prose p {
    margin: 0 0 14px;
    color: var(--ink-2);
    font-size: 15.5px;
    line-height: 1.65;
  }
  .ana-block-prose p:last-child { margin-bottom: 0; }
  .ana-block-prose code {
    font-family: var(--mono);
    font-size: 0.88em;
    color: var(--ink);
    background: var(--paper-2);
    padding: 1px 5px;
    border-radius: 2px;
  }
  .ana-block-prose em { font-style: italic; color: var(--ink); }
  .ana-block-fig {
    margin: 0;
    background: var(--paper-2);
    border: 1px solid var(--rule);
    border-radius: 4px;
    padding: clamp(20px, 2.4vw, 32px);
    position: relative;
  }
  .ana-block-fig svg {
    width: 100%;
    height: auto;
    display: block;
  }
  .ana-block-fig figcaption {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--rule-2);
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--ink-3);
    letter-spacing: 0.06em;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
  }
  @media (max-width: 920px) {
    .ana-block-body,
    .ana-block.reverse .ana-block-body { grid-template-columns: 1fr; }
    .ana-block.reverse .ana-block-fig { order: 0; }
    .ana-block-title { font-size: 24px; }
  }

  /* ─── Spec table ───────────────────────────────────────────────────── */
  .spec {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    border: 1px solid var(--rule);
    border-radius: 4px;
    overflow: hidden;
    background: color-mix(in srgb, var(--paper-2) 50%, var(--paper));
  }
  .spec .row {
    padding: 22px 28px;
    border-bottom: 1px solid var(--rule);
    border-right: 1px solid var(--rule);
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 16px;
    align-items: baseline;
  }
  .spec .row:nth-child(2n) { border-right: none; }
  .spec .row:nth-last-child(-n+2) { border-bottom: none; }
  .spec .key {
    font-family: var(--mono);
    font-size: 11.5px;
    color: var(--ink-3);
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }
  .spec .val {
    font-family: var(--serif);
    font-style: italic;
    font-size: 21px;
    line-height: 1.3;
    color: var(--ink);
  }
  .spec .val small {
    display: block;
    font-family: var(--sans);
    font-style: normal;
    font-size: 13.5px;
    color: var(--ink-2);
    margin-top: 4px;
    line-height: 1.5;
  }
  /* Phase 2.2: row summary + collapsible detail. Keeps each row to one
   * logical chunk for screen readers and ≤ 2× its previous height when
   * collapsed. Open state matches the legacy <small> text styling. */
  .spec .val .row-summary {
    margin: 0;
    font-family: var(--serif);
    font-style: italic;
    font-size: 21px;
    line-height: 1.3;
    color: var(--ink);
  }
  .spec .val .row-detail {
    margin-top: 6px;
  }
  .spec .val .row-detail > summary {
    cursor: pointer;
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--sans);
    font-style: normal;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: var(--ink-3);
    user-select: none;
  }
  .spec .val .row-detail > summary::-webkit-details-marker { display: none; }
  .spec .val .row-detail > summary::before {
    content: '+';
    display: inline-block;
    width: 11px;
    text-align: center;
    font-family: var(--mono);
    font-weight: 600;
    color: var(--clay);
    transition: transform .15s ease;
  }
  .spec .val .row-detail[open] > summary::before { content: '−'; }
  .spec .val .row-detail > summary:hover { color: var(--ink); }
  .spec .val .row-detail > summary:focus-visible {
    outline: 2px solid var(--clay);
    outline-offset: 2px;
    border-radius: 2px;
  }
  .spec .val .row-detail > p {
    margin: 8px 0 0;
    font-family: var(--sans);
    font-style: normal;
    font-size: 13.5px;
    color: var(--ink-2);
    line-height: 1.5;
  }
  @media (max-width: 760px) {
    .spec { grid-template-columns: 1fr; }
    .spec .row { border-right: none; }
    .spec .row:nth-last-child(2) { border-bottom: 1px solid var(--rule); }
  }

  /* ─── Implementation proof ────────────────────────────────────────── */
  .proof-stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    border: 1px solid var(--rule);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: clamp(28px, 4vw, 44px);
    background: color-mix(in srgb, var(--paper-2) 45%, var(--paper));
  }
  .proof-stats div {
    padding: 24px 22px 22px;
    border-right: 1px solid var(--rule);
    min-width: 0;
  }
  .proof-stats div:last-child { border-right: none; }
  .proof-stats span {
    display: block;
    font-family: var(--serif);
    font-size: clamp(34px, 4vw, 54px);
    line-height: 0.95;
    color: var(--clay);
    letter-spacing: 0;
  }
  .proof-stats small {
    display: block;
    margin-top: 10px;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-3);
  }
  .proof-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-right: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .proof-card {
    min-height: 242px;
    padding: 34px 30px 36px;
    border-top: 1px solid var(--rule);
    border-left: 1px solid var(--rule);
    background: var(--paper);
    transition: background .25s ease;
  }
  .proof-card:hover { background: var(--clay-wash); }
  .proof-k {
    display: block;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--clay);
    margin-bottom: 22px;
  }
  .proof-card h3 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 29px;
    line-height: 1.1;
    letter-spacing: -0.01em;
    margin: 0 0 14px;
  }
  .proof-card p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
    line-height: 1.6;
  }
  @media (max-width: 920px) {
    .proof-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .proof-stats div:nth-child(n) {
      border-right: 1px solid var(--rule);
      border-bottom: 1px solid var(--rule);
    }
    .proof-stats div:nth-child(2n) { border-right: none; }
    .proof-stats div:last-child {
      grid-column: 1 / -1;
      border-right: none;
      border-bottom: none;
    }
    .proof-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  }
  @media (max-width: 640px) {
    .proof-stats { grid-template-columns: 1fr 1fr; }
    .proof-grid { grid-template-columns: 1fr; }
    .proof-card { min-height: auto; }
  }

  /* ─── Self-host CTA band (§09) ────────────────────────────────────────
     A single, self-contained call-to-action — NOT a proof-card (those are
     top/left-bordered cells meant for a multi-up grid). Full border + radius,
     content left, action right; wraps to stacked on narrow viewports. */
  .selfhost-card {
    margin-top: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    flex-wrap: wrap;
    border: 1px solid var(--rule);
    border-radius: 12px;
    padding: 26px 32px;
    background: var(--paper);
    transition: background .25s ease, border-color .25s ease;
  }
  .selfhost-card:hover { background: var(--clay-wash); border-color: var(--clay-rule); }
  .selfhost-card .sh-body { max-width: 620px; }
  .selfhost-card .proof-k { margin-bottom: 12px; }
  .selfhost-card h3 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 27px;
    line-height: 1.12;
    letter-spacing: -0.01em;
    margin: 0 0 10px;
  }
  .selfhost-card p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
    line-height: 1.6;
  }
  .selfhost-card .actions { flex-shrink: 0; }
  @media (max-width: 640px) {
    .selfhost-card { padding: 24px; }
  }

  /* ─── Ecosystem · package cards ───────────────────────────────────── */
  .packs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .pack {
    padding: 36px 32px 36px;
    border-right: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    display: flex;
    flex-direction: column;
    transition: background .25s ease;
  }
  .pack:nth-child(2n) { border-right: none; }
  .pack:nth-last-child(-n+2) { border-bottom: none; }
  .pack:hover { background: var(--clay-wash); }
  .pack .tag {
    font-family: var(--mono);
    font-size: 10.5px;
    color: var(--clay);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 22px;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
  }
  .pack .name {
    font-family: var(--mono);
    font-weight: 500;
    font-size: 15px;
    margin: 0 0 12px;
    color: var(--ink);
    letter-spacing: -0.005em;
    word-break: break-word;
  }
  .pack p {
    margin: 0 0 20px;
    color: var(--ink-2);
    font-size: 14px;
    line-height: 1.55;
    flex-grow: 1;
  }
  .pack .install {
    background: var(--paper-2);
    border: 1px solid var(--rule);
    border-radius: 3px;
    padding: 10px 12px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink);
    overflow-x: auto;
    white-space: nowrap;
  }
  .pack .install .p {
    color: var(--ink-3);
    user-select: none;
    margin-right: 8px;
  }
  .pack .view {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--ink-2);
    letter-spacing: 0.04em;
    text-transform: uppercase;
  }
  .pack .view:hover { color: var(--clay); }

  .eco-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px 36px;
    margin-top: 36px;
    padding-top: 26px;
    border-top: 1px solid var(--rule);
    font-family: var(--mono);
    font-size: 13px;
  }
  .eco-meta a {
    color: var(--ink-2);
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
  }
  .eco-meta a:hover { color: var(--clay); border-bottom-color: var(--clay-rule); }

  @media (max-width: 640px) {
    .packs { grid-template-columns: 1fr; }
    .pack { border-right: none; border-bottom: 1px solid var(--rule); }
    .pack:nth-child(2n) { border-right: none; }
    .pack:last-child { border-bottom: none; }
  }

  /* ─── Demo · Try it live ───────────────────────────────────────────── */
  .demo-flow {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-right: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .demo-flow li {
    padding: 30px 28px 32px;
    border-top: 1px solid var(--rule);
    border-left: 1px solid var(--rule);
    background: var(--paper);
    transition: background .25s ease;
    min-height: 230px;
  }
  .demo-flow li:hover { background: var(--clay-wash); }
  .demo-k {
    display: block;
    font-family: var(--mono);
    font-size: 10.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--clay);
    margin-bottom: 20px;
  }
  .demo-flow h3 {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 24px;
    line-height: 1.15;
    letter-spacing: -0.01em;
    margin: 0 0 12px;
    color: var(--ink);
  }
  .demo-flow p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
    line-height: 1.6;
  }
  .demo-flow code {
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink);
    background: var(--clay-wash);
    padding: 1px 5px;
    border-radius: 2px;
  }
  .demo-flow a {
    color: var(--ink);
    border-bottom: 1px dotted var(--rule-2);
    transition: color .15s ease, border-color .15s ease;
  }
  .demo-flow a:hover { color: var(--clay); border-bottom-color: var(--clay); }

  .demo-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    margin-top: clamp(32px, 4vw, 48px);
  }

  /* Caveat tag pill — sits adjacent to the primary CTA so a user
   * clicking the button has read the session-scope warning in the same
   * visual chunk. */
  .caveat-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    font-family: var(--sans);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.01em;
    color: var(--ink-2);
    background: var(--paper-2);
    border: 1px solid var(--rule);
    border-radius: 999px;
    line-height: 1.4;
  }
  .caveat-pill-dot {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--clay);
    flex: 0 0 auto;
  }

  @media (max-width: 920px) { .demo-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
  @media (max-width: 640px) {
    .demo-flow { grid-template-columns: 1fr; }
    .demo-flow li { min-height: auto; }
  }

  /* ─── Star on GitHub · CTA band ────────────────────────────────────── */
  .star-cta {
    margin-top: clamp(48px, 6vw, 80px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(24px, 4vw, 56px);
    padding: clamp(28px, 3.5vw, 44px) clamp(28px, 4vw, 48px);
    border: 1px solid var(--rule);
    background: var(--clay-wash);
    border-radius: 4px;
  }
  .star-cta-text .marker { margin-bottom: 14px; }
  .star-cta-text h3 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(26px, 3.2vw, 34px);
    line-height: 1.1;
    letter-spacing: -0.015em;
    margin: 0 0 10px;
    color: var(--ink);
  }
  .star-cta-text h3 em { font-style: italic; color: var(--clay); }
  .star-cta-text p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14.5px;
    line-height: 1.6;
    max-width: 58ch;
  }

  .btn-star {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--sans);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.01em;
    color: var(--paper);
    background: var(--ink);
    border: 1px solid var(--ink);
    padding: 12px 18px;
    border-radius: 2px;
    text-decoration: none;
    white-space: nowrap;
    transition: background .15s ease, border-color .15s ease, transform .15s ease;
  }
  .btn-star:hover {
    background: var(--clay);
    border-color: var(--clay);
  }
  .btn-star .gh-mark { flex: 0 0 auto; }
  .btn-star-label { color: inherit; }
  .btn-star-sep {
    display: inline-block;
    width: 1px;
    height: 16px;
    background: currentColor;
    opacity: 0.35;
    margin: 0 4px;
  }
  .btn-star-icon {
    color: var(--star-glow);
    font-size: 14px;
    line-height: 1;
  }
  .btn-star:hover .btn-star-icon { color: var(--paper); }
  .btn-star-count {
    font-family: var(--mono);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.02em;
    min-width: 2ch;
    color: inherit;
  }
  .btn-star-count.is-empty { opacity: 0.55; }

  @media (max-width: 920px) {
    .star-cta { grid-template-columns: 1fr; }
    .btn-star { justify-self: start; }
  }

  /* ─── Hero shot — workflow canvas screenshot between hero and subnav.
   * Goals: (1) full-bleed presence so the screenshot reads as evidence
   * rather than chrome, (2) consistent paper background so the shot
   * doesn't fight the page's warm-stone palette, (3) subtle browser-
   * chrome framing (top bar + dots) so the image reads as "an app you
   * could be using." No card border-radius on the image itself — the
   * frame's radius does the visual containment.
   *
   * The frame uses a soft inner shadow + outer drop to suggest depth
   * without committing to a glassy/skeumorphic look. aspect-ratio
   * matches the source (3024:1722 ≈ 16:9.12) and CSS reserves the box
   * so the page doesn't shift while the image decodes (good for CLS).
   */
  .hero-shot {
    padding: clamp(0px, 2vw, 24px) 0 clamp(48px, 7vw, 96px);
    position: relative;
  }
  .hero-shot-figure {
    margin: 0;
    max-width: 1080px;
    margin-left: auto;
    margin-right: auto;
  }
  /* The frame is an <a> so the whole screenshot is clickable —
   * clicking opens the live builder at app.openwop.dev/builder.
   * Display-block + relative so the CTA pill can absolute-position
   * over the bottom-right corner. Hover bumps the drop-shadow and
   * lifts 2px to telegraph that the surface is interactive. */
  .hero-shot-frame {
    display: block;
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    background: var(--paper-2);
    border: 1px solid var(--rule-2);
    box-shadow:
      0 1px 0 rgb(var(--shadow-rgb) / 0.04),
      0 20px 60px -20px rgb(var(--shadow-rgb) / 0.18),
      0 8px 24px -12px rgb(var(--shadow-rgb) / 0.12);
    aspect-ratio: 3024 / 1722;
    color: inherit;
    text-decoration: none;
    transition: transform .2s ease, box-shadow .25s ease, border-color .2s ease;
  }
  .hero-shot-frame:hover,
  .hero-shot-frame:focus-visible {
    transform: translateY(-2px);
    border-color: var(--clay-rule);
    box-shadow:
      0 1px 0 rgb(var(--shadow-rgb) / 0.06),
      0 28px 80px -22px rgb(var(--shadow-rgb) / 0.24),
      0 14px 36px -16px rgb(var(--shadow-rgb) / 0.18);
  }
  .hero-shot-frame:focus-visible { outline: 2px solid var(--clay); outline-offset: 3px; }
  .hero-shot-frame img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: transform .35s ease;
  }
  .hero-shot-frame:hover img { transform: scale(1.012); }

  /* Subtle CTA pill that lives bottom-right of the screenshot frame.
   * Default state shows a translucent paper pill; hover state flips
   * to clay so the affordance reads strongly without dominating the
   * image. aria-hidden on the markup because the parent <a> already
   * carries the accessible name via aria-label. */
  .hero-shot-cta {
    position: absolute;
    right: clamp(10px, 1.6vw, 18px);
    bottom: clamp(10px, 1.6vw, 18px);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    font-family: var(--sans);
    font-size: 12.5px;
    font-weight: 500;
    letter-spacing: 0.01em;
    color: var(--ink);
    background: color-mix(in oklab, var(--paper) 88%, transparent);
    border: 1px solid var(--rule-2);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    box-shadow: 0 4px 14px -6px rgb(var(--shadow-rgb) / 0.18);
    transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
    pointer-events: none; /* the parent <a> handles the click */
  }
  .hero-shot-cta-arrow {
    font-size: 13.5px;
    line-height: 1;
    transition: transform .2s ease;
  }
  .hero-shot-frame:hover .hero-shot-cta,
  .hero-shot-frame:focus-visible .hero-shot-cta {
    background: var(--clay);
    color: var(--paper);
    border-color: var(--clay);
  }
  .hero-shot-frame:hover .hero-shot-cta-arrow {
    transform: translate(2px, -2px);
  }
  .hero-shot-caption {
    margin-top: 18px;
    color: var(--ink-3);
    font-size: 13.5px;
    line-height: 1.55;
    max-width: 56ch;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
  }
  .hero-shot-caption strong {
    color: var(--ink-2);
    font-weight: 500;
  }
  .hero-shot-caption a {
    color: var(--ink);
    border-bottom: 1px dotted var(--rule-2);
    transition: border-color .15s ease;
  }
  .hero-shot-caption a:hover { border-bottom-color: var(--clay); }

  @media (max-width: 700px) {
    .hero-shot { padding: 8px 0 56px; }
    .hero-shot-frame { border-radius: 10px; }
    .hero-shot-caption { text-align: left; }
  }

  /* ─── Hero star strip — Option A: compact row below the hero grid.
   * Reads as a continuation of .meta-row rather than a callout card.
   * Top hairline rule separates it from the grid above. No card chrome,
   * no background tint. Single body-sans sentence with italic-clay
   * accent on the brand word — same type discipline as the rest of
   * the page body. The .btn-star button (defined above) is reused
   * unchanged — only the surrounding layout differs from .star-cta. */
  .hero-star {
    margin-top: clamp(28px, 4vw, 48px);
    padding-top: clamp(20px, 3vw, 32px);
    border-top: 1px solid var(--rule);
  }
  .star-strip {
    display: flex;
    align-items: center;
    gap: clamp(20px, 3vw, 32px);
  }
  .star-strip-text {
    margin: 0;
    font-size: 14.5px;
    line-height: 1.55;
    color: var(--ink-2);
    max-width: 64ch;
  }
  .star-strip-text em {
    font-family: var(--serif);
    font-style: italic;
    color: var(--clay);
    font-size: 1.08em;
  }
  @media (max-width: 760px) {
    .star-strip { flex-direction: column; align-items: flex-start; }
  }

  /* ─── Compare ──────────────────────────────────────────────────────── */
  .compare {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(20px, 3vw, 36px);
  }
  .compare-card {
    padding: 36px 36px 40px;
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 4px;
    position: relative;
  }
  .compare-card .tag {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--ink-3);
    text-transform: uppercase;
    margin-bottom: 14px;
  }
  .compare-card h3 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: 30px;
    line-height: 1.1;
    margin: 0 0 18px;
    letter-spacing: -0.01em;
  }
  .compare-card h3 em { font-style: italic; color: var(--clay); }
  .compare-card p {
    color: var(--ink-2);
    font-size: 15px;
    line-height: 1.65;
    margin: 0 0 14px;
  }
  .compare-card .quote {
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid var(--rule);
    font-family: var(--serif);
    font-style: italic;
    font-size: 18px;
    line-height: 1.4;
    color: var(--ink);
  }
  /* Full-width "agentic stack" feature card leading the In-context section. */
  .compare-feature { grid-column: 1 / -1; }
  .compare-feature .stack-layers {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(16px, 2.5vw, 28px);
    margin: 6px 0 4px;
  }
  .compare-feature .stack-layer {
    padding-top: 18px;
    border-top: 2px solid var(--rule);
  }
  .compare-feature .stack-layer-own { border-top-color: var(--clay); }
  .compare-feature .sl-name {
    font-family: var(--mono);
    font-size: 13px;
    letter-spacing: 0.04em;
    color: var(--ink);
    margin-bottom: 4px;
  }
  .compare-feature .stack-layer-own .sl-name { color: var(--clay); }
  .compare-feature .sl-role {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin-bottom: 12px;
  }
  .compare-feature .stack-layer p {
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
  }
  .compare-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 24px;
    font-family: var(--mono);
    font-size: 13px;
    letter-spacing: 0.02em;
    color: var(--clay);
    text-decoration: none;
  }
  .compare-cta:hover { text-decoration: underline; }
  @media (max-width: 820px) {
    .compare { grid-template-columns: 1fr; }
    .compare-feature .stack-layers { grid-template-columns: 1fr; }
  }

  /* ─── Code / get started ───────────────────────────────────────────── */
  .start {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: clamp(28px, 4vw, 64px);
    align-items: center;
  }
  @media (max-width: 920px) { .start { grid-template-columns: 1fr; } }

  .start h2 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(36px, 5vw, 60px);
    line-height: 1.04;
    margin: 0 0 18px;
    letter-spacing: -0.012em;
  }
  .start h2 em { font-style: italic; color: var(--clay); }
  .start p {
    color: var(--ink-2);
    font-size: 16px;
    margin: 0 0 24px;
    max-width: 46ch;
  }

  .terminal {
    border: 1px solid var(--rule);
    border-radius: 6px;
    overflow: hidden;
    background: var(--paper);
    box-shadow:
      0 1px 0 0 var(--clay-wash),
      0 30px 60px -40px var(--ink-shadow);
  }
  .term-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: var(--paper-2);
    border-bottom: 1px solid var(--rule);
    font-family: var(--mono);
    font-size: 11px;
    color: var(--ink-3);
  }
  .term-dots { display: flex; gap: 6px; }
  .term-dots span {
    width: 9px; height: 9px; border-radius: 50%;
    background: var(--rule-2);
  }
  .term-body {
    font-family: var(--mono);
    font-size: 13px;
    line-height: 1.7;
    padding: 22px 22px 26px;
    color: var(--ink);
    overflow-x: auto;
  }
  .term-body .c { color: var(--ink-3); }
  .term-body .a { color: var(--clay); }
  .term-body .p { color: var(--ink-3); user-select: none; margin-right: 10px; }
  .term-body .k { color: var(--ink); font-weight: 500; }
  .term-cursor {
    display: inline-block;
    width: 7px; height: 14px;
    background: var(--clay);
    transform: translateY(2px);
    margin-left: 4px;
    animation: blink 1.05s steps(2) infinite;
  }
  @keyframes blink { 50% { opacity: 0; } }

  /* ─── Footer ───────────────────────────────────────────────────────── */
  footer.foot {
    border-top: 1px solid var(--rule);
    padding: 56px 0 64px;
    margin-top: 0;
  }
  .foot-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 40px;
  }
  .foot-grid > div:first-child { max-width: 36ch; }
  @media (max-width: 920px) {
    .foot-grid { grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
    .foot-grid > div:first-child { grid-column: 1 / -1; max-width: 48ch; }
  }
  @media (max-width: 640px) {
    .foot-grid { grid-template-columns: 1fr 1fr; }
  }

  .foot-grid h5 {
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin: 0 0 14px;
    font-weight: 500;
  }
  .foot-grid ul {
    list-style: none;
    margin: 0;
    padding: 0;
  }
  .foot-grid li { margin-bottom: 8px; }
  .foot-grid a { color: var(--ink-2); font-size: 14px; }
  .foot-grid a:hover { color: var(--clay); }

  .foot-mark {
    font-family: var(--serif);
    font-size: 38px;
    line-height: 1.05;
    letter-spacing: -0.01em;
  }
  .foot-mark em { font-style: italic; color: var(--clay); }
  .foot-mark img {
    width: 49px;
    height: 49px;
    display: inline-block;
    vertical-align: middle;
    margin-inline-end: 4px;
  }
  .foot-blurb {
    color: var(--ink-3);
    font-size: 13px;
    max-width: 32ch;
    margin-top: 14px;
  }

  .foot-meta {
    margin-top: 56px;
    padding-top: 22px;
    border-top: 1px solid var(--rule);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    font-family: var(--mono);
    font-size: 11.5px;
    color: var(--ink-3);
  }

  /* ─── Animation primitives ─────────────────────────────────────────── */
  .flow-path {
    fill: none;
    stroke: var(--ink);
    stroke-width: 1;
    opacity: 0.55;
  }
  .flow-path.thin { stroke-width: 0.6; opacity: 0.35; }
  .flow-path.accent { stroke: var(--clay); opacity: 0.9; stroke-width: 1.2; }

  .pulse {
    fill: var(--clay);
    r: 3.5;
    filter: drop-shadow(0 0 4px var(--clay-glow));
  }

  .node-c {
    fill: var(--paper);
    stroke: var(--ink);
    stroke-width: 1.2;
  }
  .node-c.accent { stroke: var(--clay); stroke-width: 1.6; }
  .node-fill { fill: var(--ink); }
  .node-fill.accent { fill: var(--clay); }
  .node-label {
    font-family: var(--mono);
    font-size: 9.5px;
    fill: var(--ink-3);
    letter-spacing: 0.04em;
  }

  /* fade-in on scroll */
  .reveal { opacity: 0; transform: translateY(14px); transition: opacity .8s ease, transform .8s ease; }
  .reveal.in { opacity: 1; transform: none; }

  /* ─── Accent term — used for inline branded acronyms / shibboleths ── */
  .accent-term {
    font-style: italic;
    font-family: var(--serif);
    color: var(--clay);
  }

  /* ─── External link indicator (auto ↗ after links to known external hosts) */
  a[href^="http"]:not([href*="openwop-dev.web.app"]):not(.btn):not(.btn-star):not(.brand):not(.view):not(.pill):not(.meta-link):not(.pack a)::after {
    content: " ↗";
    color: var(--ink-3);
    font-size: 0.85em;
    margin-left: 1px;
  }
  a[href^="http"]:not([href*="openwop-dev.web.app"]):not(.btn):not(.btn-star):not(.brand):not(.view):not(.pill):not(.meta-link):not(.pack a):hover::after {
    color: var(--clay);
  }

  /* ─── Skip link — visually hidden until keyboard-focused ──────────── */
  .skip-link {
    position: absolute;
    top: -100px;
    left: var(--gutter, 24px);
    z-index: 100;
    padding: 10px 16px;
    background: var(--ink);
    color: var(--paper);
    font-family: var(--mono);
    font-size: 12px;
    border-radius: 0 0 4px 4px;
  }
  .skip-link:focus {
    top: 0;
    outline: 2px solid var(--clay);
    outline-offset: 2px;
  }

  /* ─── Topbar search button + ⌘K / "/" overlay (shared chrome) ──────
   * Used by both the marketing topnav and the generated subpage topbar
   * (templates/page.html). Client logic: /assets/site-search.js; index:
   * /assets/search-index.json (written by the site generator). */
  .nav-search-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border: 1px solid var(--rule);
    border-radius: 6px;
    background: var(--paper-2);
    color: var(--ink-2);
    font-family: var(--sans);
    font-size: 13.5px;
    padding: 6px 10px;
    cursor: pointer;
  }
  .nav-search-btn:hover { border-color: var(--clay-rule); color: var(--ink); }
  .nav-search-btn svg { width: 14px; height: 14px; }
  .nav-search-btn kbd {
    font-family: var(--mono);
    font-size: 10.5px;
    border: 1px solid var(--rule-2);
    border-radius: 3px;
    padding: 0 5px;
    color: var(--ink-3);
  }
  html.search-open { overflow: hidden; }
  .site-search {
    position: fixed;
    inset: 0;
    z-index: 200;
  }
  .site-search-scrim {
    position: absolute;
    inset: 0;
    background: color-mix(in oklab, var(--ink) 35%, transparent);
  }
  .site-search-panel {
    position: relative;
    max-width: 640px;
    margin: clamp(48px, 12vh, 120px) auto 0;
    padding: 16px;
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 10px;
    box-shadow: 0 24px 64px color-mix(in oklab, var(--ink) 25%, transparent);
  }
  .site-search-input {
    width: 100%;
    box-sizing: border-box;
    font-family: var(--sans);
    font-size: 16px;
    color: var(--ink);
    background: var(--paper-2);
    border: 1px solid var(--rule);
    border-radius: 6px;
    padding: 12px 14px;
  }
  .site-search-results {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    max-height: min(420px, 55vh);
    overflow-y: auto;
  }
  .site-search-results a {
    display: grid;
    grid-template-columns: auto 1fr;
    grid-template-areas: "chip title" "chip desc";
    column-gap: 12px;
    row-gap: 2px;
    align-items: baseline;
    padding: 10px 12px;
    border-radius: 6px;
    text-decoration: none;
  }
  .site-search-results li.is-active a,
  .site-search-results a:hover { background: var(--clay-soft); }
  .site-search-chip {
    grid-area: chip;
    align-self: start;
    font-family: var(--mono);
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--ink-3);
    border: 1px solid var(--rule-2);
    border-radius: 3px;
    padding: 2px 6px;
    min-width: 44px;
    text-align: center;
  }
  .site-search-title { grid-area: title; color: var(--ink); font-weight: 500; }
  .site-search-desc {
    grid-area: desc;
    font-size: 13px;
    color: var(--ink-3);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .site-search-empty,
  .site-search-hint {
    font-family: var(--mono);
    font-size: 11.5px;
    color: var(--ink-3);
    margin: 12px 4px 2px;
  }
  .site-search-hint kbd {
    border: 1px solid var(--rule-2);
    border-radius: 3px;
    padding: 0 4px;
    margin-inline-end: 2px;
  }
  @media (max-width: 760px) {
    .nav-search-btn span, .nav-search-btn kbd { display: none; }
  }

  /* ─── Focus ring — visible only via keyboard (not mouse click) ────── */
  :focus { outline: none; }
  :focus-visible {
    outline: 2px solid var(--clay);
    outline-offset: 3px;
    border-radius: 2px;
  }
  .btn:focus-visible { outline-offset: 4px; }

  /* ─── Reduced motion — respect prefers-reduced-motion ─────────────── */
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
    .term-cursor { animation: none; opacity: 1; }
    .reveal { opacity: 1; transform: none; }
    /* Freeze SVG pulses */
    svg animateMotion, svg animate { display: none; }
  }

  /* ─── Print stylesheet ────────────────────────────────────────────── */
  @media print {
    body {
      background: white;
      color: black;
      background-image: none;
    }
    .topbar, .actions, .demo-cta, .star-cta, .term-cursor, .pulse { display: none; }
    .diagram-card::before { display: none; }
    section.block { padding: 32px 0; page-break-inside: avoid; }
    .hero-grid, .start, .compare, .anatomy { grid-template-columns: 1fr; }
    a { color: inherit; text-decoration: underline; }
    a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 0.85em; }
  }

  /* ─── Running today / Ships strip ─────────────────────────────────── */
  .ships-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .ship {
    display: block;
    padding: 32px 28px 36px;
    border-right: 1px solid var(--rule);
    color: var(--ink);
    background: linear-gradient(180deg, transparent, transparent);
    transition: background .25s ease, transform .25s ease;
    position: relative;
  }
  .ship:last-child { border-right: none; }
  .ship:hover { background: var(--clay-wash); }
  .ship-num {
    font-family: var(--serif);
    font-size: 64px;
    line-height: 1;
    font-weight: 400;
    color: var(--clay);
    letter-spacing: -0.02em;
    margin-bottom: 14px;
  }
  .ship-label {
    font-family: var(--sans);
    font-size: 15px;
    font-weight: 500;
    color: var(--ink);
    margin-bottom: 10px;
  }
  .ship-detail {
    font-family: var(--mono);
    font-size: 11.5px;
    line-height: 1.6;
    color: var(--ink-3);
    letter-spacing: 0.01em;
  }
  .ship-detail code {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--ink-2);
    background: var(--paper-2);
    padding: 1px 5px;
    border-radius: 3px;
  }
  .ship-sep { color: var(--rule-2); padding: 0 2px; }
  .ship::after {
    content: "→";
    position: absolute;
    top: 28px;
    right: 24px;
    color: var(--ink-3);
    font-size: 16px;
    opacity: 0;
    transition: opacity .25s ease, transform .25s ease;
  }
  .ship:hover::after { opacity: 1; transform: translateX(3px); }

  @media (max-width: 920px) {
    .ships-grid { grid-template-columns: repeat(2, 1fr); }
    .ship:nth-child(2) { border-right: none; }
    .ship:nth-child(1), .ship:nth-child(2) { border-bottom: 1px solid var(--rule); }
  }
  @media (max-width: 480px) {
    .ships-grid { grid-template-columns: 1fr; }
    .ship { border-right: none; border-bottom: 1px solid var(--rule); }
    .ship:last-child { border-bottom: none; }
    .ship-num { font-size: 48px; }
  }

  /* ─── CLI CTA (§ 01.5) ────────────────────────────────────────────── */
  .cli-cta-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: 32px;
    align-items: start;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    padding: 36px 0;
  }
  .cli-cta-install { min-width: 0; }
  .cli-cta-pre {
    margin: 0;
    padding: 20px 22px;
    background: var(--ink);
    color: var(--paper);
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 14px;
    line-height: 1.65;
    overflow-x: auto;
    white-space: pre;
  }
  .cli-cta-pre code {
    background: none;
    padding: 0;
    border: 0;
    color: inherit;
    font-family: inherit;
    font-size: inherit;
  }
  .cli-cta-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
    font-size: 14px;
    line-height: 1.7;
    color: var(--ink-2);
  }
  .cli-cta-list li {
    padding: 6px 0;
    border-bottom: 1px solid var(--rule);
  }
  .cli-cta-list li:last-child { border-bottom: none; }
  .cli-cta-list strong { color: var(--ink); font-weight: 500; }
  .cli-cta-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0;
  }
  @media (max-width: 760px) {
    .cli-cta-grid {
      grid-template-columns: 1fr;
      gap: 24px;
      padding: 28px 0;
    }
  }

  /* ─── Pick your path ──────────────────────────────────────────────── */
  .paths-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
  }
  .path {
    padding: 32px 28px 36px;
    border-right: 1px solid var(--rule);
    display: flex;
    flex-direction: column;
    gap: 20px;
    background: linear-gradient(180deg, transparent, transparent);
    transition: background .25s ease;
  }
  .path:last-child { border-right: none; }
  .path:hover { background: var(--clay-wash); }
  .path-num {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--ink-3);
    letter-spacing: 0.12em;
  }
  .path-head h3 {
    font-family: var(--serif);
    font-weight: 400;
    font-size: 26px;
    line-height: 1.15;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
  }
  .path-head h3 em { font-style: italic; color: var(--clay); }
  .path-head p {
    margin: 0;
    color: var(--ink-2);
    font-size: 14px;
    line-height: 1.6;
  }
  .path-links {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid var(--rule);
    display: flex;
    flex-direction: column;
  }
  .path-links li { padding: 0; }
  .path-links a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 11px 0;
    font-family: var(--sans);
    font-size: 13.5px;
    color: var(--ink);
    border-bottom: 1px solid var(--rule);
    transition: color .15s ease;
  }
  .path-links li:last-child a { border-bottom: none; }
  .path-links a:hover { color: var(--clay); }
  .path-links .arrow {
    font-family: var(--mono);
    font-size: 13px;
    color: var(--ink-3);
    flex: 0 0 auto;
  }
  .path-links a:hover .arrow { color: var(--clay); }

  @media (max-width: 920px) {
    .paths-grid { grid-template-columns: repeat(2, 1fr); }
    .path:nth-child(2) { border-right: none; }
    .path:nth-child(1), .path:nth-child(2) { border-bottom: 1px solid var(--rule); }
  }
  @media (max-width: 600px) {
    .paths-grid { grid-template-columns: 1fr; }
    .path { border-right: none; border-bottom: 1px solid var(--rule); }
    .path:last-child { border-bottom: none; }
  }

  /* ─── Comparison table ────────────────────────────────────────────── */
  .compare-table-wrap {
    margin-top: 56px;
    border-top: 1px solid var(--rule);
    padding-top: 40px;
  }
  .compare-table-h {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    font-size: 26px;
    margin: 0 0 8px;
    letter-spacing: -0.01em;
  }
  .compare-table-lede {
    color: var(--ink-2);
    font-size: 14.5px;
    max-width: 64ch;
    margin: 0 0 24px;
  }
  .compare-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--sans);
    font-size: 13.5px;
    margin-bottom: 16px;
  }
  .compare-table thead th {
    text-align: left;
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-3);
    font-weight: 500;
    padding: 12px 14px;
    border-bottom: 1px solid var(--rule-2);
    background: transparent;
    vertical-align: bottom;
  }
  .compare-table tbody th {
    text-align: left;
    font-weight: 500;
    color: var(--ink);
    padding: 14px;
    border-bottom: 1px solid var(--rule);
    background: var(--clay-wash);
    width: 28%;
  }
  .compare-table tbody td {
    padding: 14px;
    border-bottom: 1px solid var(--rule);
    color: var(--ink-2);
    vertical-align: top;
  }
  .compare-table tbody tr:last-child th,
  .compare-table tbody tr:last-child td { border-bottom: none; }
  .compare-table .ct-y { color: var(--ink); }
  .compare-table .ct-y::before { content: "●"; color: var(--clay); margin-right: 6px; font-size: 11px; }
  .compare-table .ct-p { color: var(--ink-2); }
  .compare-table .ct-p::before { content: "◐"; color: var(--ink-3); margin-right: 6px; font-size: 11px; }
  .compare-table .ct-n { color: var(--ink-3); }
  .compare-table .ct-n::before { content: "○"; color: var(--ink-3); margin-right: 6px; font-size: 11px; }
  .compare-table .ct-na { color: var(--ink-3); font-style: italic; }
  .compare-table .ct-mark-own {
    font-weight: 600;
    color: var(--clay);
  }
  .compare-table-foot {
    color: var(--ink-3);
    font-size: 12px;
    line-height: 1.6;
    margin: 8px 0 0;
  }
  .compare-table-foot a {
    color: var(--ink-2);
    text-decoration: underline;
    text-decoration-color: var(--rule-2);
    text-underline-offset: 3px;
  }
  .compare-table-foot a:hover { color: var(--clay); }

  @media (max-width: 760px) {
    .compare-table-wrap { overflow-x: auto; }
    .compare-table { min-width: 640px; }
  }

  /* ─── Anatomy tabs ────────────────────────────────────────────────── */
  .ana-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
    margin-bottom: 0;
    background: var(--paper);
    position: sticky;
    top: 56px;
    z-index: 10;
  }
  .ana-tab {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 18px;
    font-family: var(--sans);
    font-size: 13px;
    font-weight: 500;
    color: var(--ink-3);
    background: transparent;
    border: 0;
    border-right: 1px solid var(--rule);
    cursor: pointer;
    text-align: left;
    transition: background .15s ease, color .15s ease;
  }
  .ana-tab:last-child { border-right: none; }
  .ana-tab:hover { background: var(--clay-wash); color: var(--ink); }
  .ana-tab.is-active {
    color: var(--ink);
    background: var(--paper);
    box-shadow: inset 0 -2px 0 var(--clay);
  }
  .ana-tab-key {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--clay);
    flex: 0 0 auto;
    letter-spacing: 0.06em;
  }
  .ana-tab-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  /* :focus-visible is the modern target; :focus fallback ensures older
   * UA / certain assistive setups still render a focus ring. */
  .ana-tab:focus { outline: 2px solid var(--clay); outline-offset: -2px; }
  .ana-tab:focus:not(:focus-visible) { outline: none; }
  .ana-tab:focus-visible { outline: 2px solid var(--clay); outline-offset: -2px; }

  /* When tabs are active, hide the default border-bottom on each
   * ana-block since only one is visible at a time. */
  .ana-block[role="tabpanel"] {
    border-bottom: none !important;
    padding-top: 40px;
  }
  .ana-block[hidden] { display: none !important; }

  @media (max-width: 920px) {
    .ana-tabs {
      overflow-x: auto;
      flex-wrap: nowrap;
      scroll-snap-type: x mandatory;
      position: static;
    }
    .ana-tab {
      flex: 0 0 auto;
      min-width: 160px;
      scroll-snap-align: start;
    }
    .ana-tab-label {
      font-size: 12px;
    }
  }
  @media (max-width: 480px) {
    .ana-tab { padding: 14px 14px; min-width: 140px; }
  }

  /* ─── Anatomy sectional CTAs ──────────────────────────────────────── */
  .ana-block-cta {
    margin-top: 28px;
    padding-top: 18px;
    border-top: 1px solid var(--rule);
  }
  .ana-block-cta a {
    font-family: var(--sans);
    font-size: 13.5px;
    color: var(--ink);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color .15s ease;
  }
  .ana-block-cta a em {
    font-style: italic;
    color: var(--clay);
  }
  .ana-block-cta a:hover { color: var(--clay); }
  .ana-block-cta .arrow {
    font-family: var(--mono);
    color: var(--ink-3);
    transition: transform .2s ease;
  }
  .ana-block-cta a:hover .arrow {
    color: var(--clay);
    transform: translateX(2px);
  }

  /* ─── Homepage in-page sub-nav (sticky below the topbar) ──────────── */
  .subnav {
    position: sticky;
    top: 64px;
    z-index: 40;
    background: color-mix(in srgb, var(--paper) 92%, transparent);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--rule);
  }
  .subnav-inner {
    /* Fluid horizontal padding; no vertical margin since the bar itself
     * defines the row height. */
    padding-block: 0;
  }
  .subnav-scroll {
    display: flex;
    align-items: stretch;
    gap: 4px;
    overflow-x: auto;
    /* overflow-x: auto implicitly enables overflow-y: auto in browsers,
     * which means the active-tab's 2px border-bottom triggers a tiny
     * vertical scrollbar (the row content + border is just over the
     * container's box). Clip vertically so the active indicator can
     * sit at the baseline without prompting a scrollbar. */
    overflow-y: hidden;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--rule-2) transparent;
  }
  .subnav-scroll::-webkit-scrollbar { height: 4px; }
  .subnav-scroll::-webkit-scrollbar-thumb { background: var(--rule-2); border-radius: 4px; }
  .subnav-link {
    flex: 0 0 auto;
    padding: 14px 14px 12px;
    font-family: var(--sans);
    font-size: 13px;
    font-weight: 500;
    color: var(--ink-3);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;          /* overlap the .subnav border-bottom */
    transition: color .15s ease, border-color .15s ease;
    white-space: nowrap;
    scroll-snap-align: start;
  }
  .subnav-link:hover {
    color: var(--ink);
  }
  .subnav-link.is-active {
    color: var(--ink);
    border-bottom-color: var(--clay);
  }
  @media (max-width: 480px) {
    .subnav-link {
      padding: 12px 10px 10px;
      font-size: 12.5px;
    }
  }

  /* Mobile fallback: a native <select> replaces the horizontal scroller below
   * 600px so the in-page TOC fits in one row, doesn't scroll-trap, and gets
   * the OS picker UI for free. The .subnav-scroll is hidden at the same
   * breakpoint. */
  .subnav-select-wrap {
    display: none;
    width: 100%;
    padding: 8px 0;
  }
  .subnav-select {
    width: 100%;
    padding: 10px 36px 10px 12px;
    font-family: var(--sans);
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 4px;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' fill='none' stroke='%23666' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
  }
  .subnav-select:focus-visible {
    outline: 2px solid var(--clay);
    outline-offset: 2px;
  }
  @media (max-width: 600px) {
    .subnav-scroll { display: none; }
    .subnav-select-wrap { display: block; }
  }
  .visually-hidden {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0);
    white-space: nowrap; border: 0;
  }
