/* Brahma site — plain CSS, no build step. Earth palette: umber, moss, lake blue.
   Colour roles are information: the four vertex colours mean the same thing
   everywhere on the page (token / attention head / KV head / expert). */

:root {
  --paper: #f6f3ea;
  --paper-2: #ebe6d8;
  --ink: #2a2520;
  --ink-2: #5a5145;
  --rule: #d9d1bf;
  --accent: #7c4f2c;      /* actions only */
  --accent-ink: #ffffff;
  --head: #2c6482;        /* attention heads */
  --kv: #36602d;          /* KV heads */
  --expert: #a25a28;      /* routed experts */
  --token: #2a2520;       /* tokens */
  --neuron: #736b5d;      /* neuron groups; heartbeats and probes */
  --bulk: #2b6b67;        /* model sync, low-priority bulk lane */
  --receipt: #8a6a1c;     /* signed work receipts */
  --focus: #2c6482;
  --code-bg: #2a2520;
  --code-ink: #efe9da;

  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --step--1: clamp(0.84rem, 0.82rem + 0.1vw, 0.9rem);
  --step-0: clamp(1rem, 0.97rem + 0.15vw, 1.08rem);
  --step-1: clamp(1.2rem, 1.12rem + 0.35vw, 1.4rem);
  --step-2: clamp(1.5rem, 1.3rem + 0.9vw, 2.1rem);
  --step-3: clamp(2.3rem, 1.7rem + 3vw, 4.4rem);

  --gutter: clamp(16px, 4vw, 40px);
  --max: 1160px;
  --radius-s: 6px;
  --radius-m: 10px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #1b1915;
    --paper-2: #24211b;
    --ink: #ece6d7;
    --ink-2: #b6ac99;
    --rule: #3b362c;
    --accent: #c8905f;
    --accent-ink: #1b1915;
    --head: #7fb1cc;
    --kv: #8fbf72;
    --expert: #dc9a62;
    --token: #ece6d7;
    --neuron: #958c7a;
    --bulk: #72b8af;
    --receipt: #d9b867;
    --focus: #9cc6dc;
    --code-bg: #13110e;
    --code-ink: #ece6d7;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.55;
  overflow-x: hidden;
}

img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 3px; }
code { font-family: var(--mono); font-size: 0.88em; }
p code, li code, dt code { background: var(--paper-2); padding: 0.1em 0.35em; border-radius: 4px; }
.section-alt p code, .section-alt li code { background: var(--paper); }

h1, h2, h3 { margin: 0; line-height: 1.12; font-weight: 650; letter-spacing: -0.015em; }
h2 { font-size: var(--step-2); max-width: 26ch; }
h3 { font-size: var(--step-1); font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-inline: var(--gutter); }
.small { font-size: var(--step--1); color: var(--ink-2); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; left: 8px; top: -60px; background: var(--ink); color: var(--paper); padding: 8px 14px; border-radius: var(--radius-s); z-index: 30; }
.skip:focus { top: 8px; }

/* Header: stays pinned to the top while the page scrolls under it.
   --header-h keeps anchor jumps (#waitlist, white paper sections) clear of it. */
:root { --header-h: 58px; }
html { scroll-padding-top: calc(var(--header-h) + 12px); }
.site-header {
  position: sticky; top: 0; z-index: 15;
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header {
    background: color-mix(in srgb, var(--paper) 86%, transparent);
    -webkit-backdrop-filter: saturate(1.3) blur(12px); backdrop-filter: saturate(1.3) blur(12px);
  }
}
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 14px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 1.15rem; letter-spacing: -0.01em; }
/* Asyml8 animated logo: pixel art on its own dark tile, kept crisp when scaled */
picture:has(> .brand-logo) { display: block; }
.brand-logo { display: block; height: 48px; width: auto; image-rendering: pixelated; border-radius: 4px; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 20px; list-style: none; margin: 0; padding: 0; font-size: var(--step--1); }
.nav a { text-decoration: none; color: var(--ink-2); }
.nav a:hover { color: var(--ink); text-decoration: underline; }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }
/* Narrow screens: the brand on one line, the links in a single row below it that scrolls sideways,
   so the pinned header stays two lines tall instead of wrapping to three or four. */
@media (max-width: 719px) {
  :root { --header-h: 82px; }
  .header-row { padding-block: 10px 0; row-gap: 4px; }
  .site-header nav { width: 100%; overflow-x: auto; scrollbar-width: none; -webkit-mask-image: linear-gradient(to right, #000 88%, transparent); mask-image: linear-gradient(to right, #000 88%, transparent); }
  .site-header nav::-webkit-scrollbar { display: none; }
  .nav { flex-wrap: nowrap; white-space: nowrap; padding-block: 8px 10px; padding-right: 32px; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 46px; padding: 0 20px; border-radius: 999px;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  border: 1.5px solid transparent;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(0.94); }
.btn-quiet { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-quiet:hover { background: var(--ink); color: var(--paper); }

/* Sections */
.section { padding-block: clamp(64px, 9vw, 120px); }
.section-alt { background: var(--paper-2); }
.section-ink { background: var(--code-bg); color: var(--code-ink); }
.section-intro { max-width: 62ch; color: var(--ink-2); margin-top: 16px; font-size: var(--step-1); line-height: 1.45; }
.section h2 + .problem-grid,
.section h2 + .who,
.section h2 + .community-grid { margin-top: 40px; }

/* Hero */
.hero { padding-block: clamp(40px, 7vw, 96px) clamp(56px, 8vw, 110px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: center; }
@media (min-width: 920px) { .hero-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; } }
.status { display: inline-flex; align-items: center; gap: 10px; font-size: var(--step--1); color: var(--ink-2); margin-bottom: 28px; }
.status .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--kv); box-shadow: 0 0 0 4px color-mix(in srgb, var(--kv) 22%, transparent); }
.hero h1 { font-size: var(--step-3); font-weight: 700; letter-spacing: -0.035em; line-height: 1.0; max-width: 13ch; }
.lede { font-size: var(--step-1); line-height: 1.5; color: var(--ink-2); max-width: 46ch; margin-top: 28px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

.hero-mesh { margin: 0; }
#mesh { width: 100%; aspect-ratio: 1 / 1; max-height: 560px; }
.hero-mesh { position: relative; }
#mesh { aspect-ratio: 1 / 1.06; }
/* A subtitle laid over the bottom of the animation, one line on desktop. */
.zoom-caption {
  position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%);
  width: max-content; max-width: calc(100% - 12px); margin: 0;
  padding: 7px 16px; border-radius: 10px; text-align: center;
  font-size: var(--step--1); line-height: 1.4; color: var(--ink-2);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  border: 1px solid var(--rule); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.zoom-caption strong { color: var(--ink); font-weight: 650; }

/* Privacy */
.privacy-flow { list-style: none; padding: 0; margin: 36px 0 0; display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); counter-reset: pf; }
@media (min-width: 760px) { .privacy-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1080px) { .privacy-flow { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.pf-step { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius-m); padding: 20px; }
.pf-step h3 { font-size: var(--step-0); margin-top: 14px; }
.pf-step p { margin: 8px 0 0; color: var(--ink-2); font-size: var(--step--1); }
.pf-more { margin: 20px 0 0; font-size: var(--step--1); }
.pf-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 32px; padding: 0 10px;
  border-radius: 8px; font-family: var(--mono); font-size: 0.85rem; font-weight: 500; }
.pf-stays { background: var(--ink); color: var(--paper); }
.pf-vec { background: color-mix(in srgb, var(--head) 16%, transparent); color: var(--head); }
.pf-lock { border: 1.5px solid var(--ink-2); }
.pf-check { background: color-mix(in srgb, var(--kv) 18%, transparent); color: var(--kv); font-weight: 700; }
.privacy-status { width: 100%; border-collapse: collapse; margin-top: 32px; font-size: var(--step--1); }
.privacy-status caption { text-align: left; font-weight: 650; padding-bottom: 10px; color: var(--ink); }
.privacy-status th, .privacy-status td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--rule); vertical-align: top; }
.privacy-status th { color: var(--ink-2); font-weight: 550; }
.privacy-status td:last-child { white-space: nowrap; }
.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 0.8rem; font-weight: 600; }
.tag-done { background: color-mix(in srgb, var(--kv) 18%, transparent); color: var(--kv); }
.tag-plan { background: var(--paper-2); color: var(--ink-2); border: 1px solid var(--rule); }
.fine { margin-top: 16px; font-size: var(--step--1); color: var(--ink-2); max-width: 75ch; }

/* Problem */
.problem-grid, .community-grid { display: grid; gap: 32px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) { .problem-grid, .community-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; } }
.problem-grid > div, .community-grid > div { border-top: 2px solid var(--ink); padding-top: 18px; }
.problem-grid h3, .community-grid h3 { margin-bottom: 10px; }
.problem-grid p, .community-grid p { color: var(--ink-2); max-width: 40ch; }
.mission { margin-top: 56px; font-size: var(--step-2); line-height: 1.25; font-weight: 500; letter-spacing: -0.015em; max-width: 30ch; }

/* Steps (a real sequence, so numbered) */
.steps { list-style: none; counter-reset: step; margin: 48px 0 0; padding: 0; display: grid; gap: 40px 32px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.steps li { counter-increment: step; position: relative; }
.steps h3::before { content: counter(step) ". "; color: var(--ink-2); font-weight: 500; }
.steps h3 { margin: 18px 0 8px; }
.steps p { color: var(--ink-2); }
.step-art { width: 100%; height: auto; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius-m); padding: 12px; }
.a-ink-fill { fill: var(--ink); opacity: .85; }
.a-line { stroke: var(--ink-2); stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.a-head { fill: var(--head); } .a-kv { fill: var(--kv); } .a-exp { fill: var(--expert); } .a-neu { fill: var(--neuron); } .a-tok { fill: var(--token); }
.a-ring { fill: none; stroke: var(--rule); stroke-width: 2; stroke-dasharray: 4 5; }
.a-box { fill: var(--paper-2); stroke: var(--ink-2); stroke-width: 1.5; }
.a-msg { fill: none; stroke: var(--ink-2); stroke-width: 1.5; stroke-dasharray: 3 4; }
.a-grid rect { fill: var(--head); }
.a-bar { fill: var(--expert); }
.aside { margin-top: 48px; max-width: 70ch; color: var(--ink-2); font-size: var(--step--1); border-left: 2px solid var(--rule); padding-left: 16px; }

/* Numbers */
.measures { width: 100%; border-collapse: collapse; margin-top: 40px; }
.measures th, .measures td { text-align: left; padding: 18px 12px 18px 0; border-top: 1px solid var(--rule); vertical-align: baseline; }
.measures tr:last-child th, .measures tr:last-child td { border-bottom: 1px solid var(--rule); }
.measures th { font-weight: 500; width: 34%; }
.measures .fig { font-size: var(--step-2); font-weight: 700; letter-spacing: -0.02em; white-space: nowrap; width: 22%; }
.measures .fig span { font-size: var(--step--1); font-weight: 500; color: var(--ink-2); letter-spacing: 0; }
.measures td:last-child { color: var(--ink-2); }
@media (max-width: 640px) {
  .measures, .measures tbody, .measures tr, .measures th, .measures td { display: block; width: auto; }
  .measures tr { border-top: 1px solid var(--rule); padding: 14px 0; }
  .measures th, .measures td { border: 0 !important; padding: 0; }
  .measures .fig { margin: 4px 0; }
}
.privacy-status.roadmap caption { font-size: var(--step-0); }
.privacy-status.roadmap td:first-child { width: 100%; }
.footnote { margin-top: 16px; font-size: var(--step--1); color: var(--ink-2); }

/* Explorer */
.explorer-grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 960px) { .explorer-grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 56px; } }
.explorer-copy h2 { margin-bottom: 20px; }
.ticks { list-style: none; padding: 0; margin: 0 0 24px; }
.ticks li { padding: 10px 0; border-top: 1px solid var(--rule); color: var(--ink-2); }
.ticks strong { color: var(--ink); font-weight: 600; }

.explorer { margin: 0; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius-m); overflow: hidden; }
.ex-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--rule); font-size: var(--step--1); }
.ex-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--rule); }
.ex-bar b { margin-left: 10px; font-weight: 500; color: var(--ink-2); font-family: var(--mono); font-size: 0.8rem; }
.ex-tokens { display: flex; flex-wrap: wrap; gap: 6px; padding: 16px; border-bottom: 1px solid var(--rule); }
.ex-tok {
  font: inherit; font-family: var(--mono); font-size: 0.86rem;
  padding: 6px 10px; min-height: 36px; border-radius: var(--radius-s);
  border: 1px solid var(--rule); background: var(--paper-2); color: var(--ink); cursor: pointer;
}
.ex-tok:hover { border-color: var(--ink-2); }
.ex-tok[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.ex-tok { transition: background-color 250ms ease, color 250ms ease, border-color 250ms ease; }
.ex-play {
  margin-left: auto; min-height: 28px; padding: 0 12px; border-radius: 999px; cursor: pointer;
  font: inherit; font-size: 0.78rem; font-weight: 600; color: var(--ink-2);
  background: transparent; border: 1px solid var(--rule);
}
.ex-play:hover { color: var(--ink); border-color: var(--ink-2); }
@media (prefers-reduced-motion: reduce) { .ex-tok { transition: none; } }
.ex-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
@media (min-width: 520px) { .ex-body { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); } }
.ex-panel { padding: 16px; border-bottom: 1px solid var(--rule); min-width: 0; }
@media (min-width: 520px) { .ex-panel:first-child { border-right: 1px solid var(--rule); } }
.ex-wide { grid-column: 1 / -1; border-bottom: 0; }
.ex-h { font-size: var(--step--1); color: var(--ink-2); margin-bottom: 10px; }
#ex-heads, #ex-neurons { width: 100%; height: auto; }
#ex-heads { max-width: 240px; }
.ex-experts { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ex-experts li { display: grid; grid-template-columns: 4.6em minmax(0, 1fr) 2.8em; align-items: center; gap: 8px; font-size: 0.82rem; font-family: var(--mono); }
.ex-experts .bar { height: 10px; border-radius: 3px; background: var(--expert); transform-origin: left; transition: transform 300ms ease; }
.ex-experts .w { text-align: right; color: var(--ink-2); }
.ex-experts .node { grid-column: 2 / 4; margin-top: -6px; color: var(--ink-2); font-size: 0.74rem; }
.ex-heads-rect { transition: opacity 300ms ease; }
@media (prefers-reduced-motion: reduce) { .ex-experts .bar, .ex-heads-rect { transition: none; } }

/* Install */
.install-grid { display: grid; gap: 32px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 880px) { .install-grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 56px; } }
.install-grid h2 { margin-bottom: 18px; }
.install-grid p { color: var(--ink-2); max-width: 48ch; }
.code { position: relative; background: var(--code-bg); color: var(--code-ink); border-radius: var(--radius-m); }
.code pre { margin: 0; padding: 22px 20px; padding-right: 88px; overflow-x: auto; font-family: var(--mono); font-size: 0.9rem; line-height: 1.7; }
.code pre code { font-size: inherit; }
.copy {
  position: absolute; top: 12px; right: 12px; min-height: 34px; padding: 0 14px;
  font: inherit; font-size: 0.82rem; font-weight: 600; cursor: pointer;
  color: var(--code-ink); background: transparent; border: 1px solid color-mix(in srgb, var(--code-ink) 40%, transparent); border-radius: 999px;
}
.copy:hover { background: color-mix(in srgb, var(--code-ink) 12%, transparent); }
.cmds { margin: 24px 0 0; display: grid; gap: 14px; }
.cmds div { display: grid; gap: 2px; }
.cmds dt { font-weight: 500; }
.cmds dd { margin: 0; color: var(--ink-2); }
.copy-status { min-height: 1.5em; font-size: var(--step--1); margin-top: 12px; }

/* Who */
.who { display: grid; gap: 0 48px; grid-template-columns: minmax(0, 1fr); margin-bottom: 0; }
@media (min-width: 760px) { .who { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.who div { padding: 22px 0; border-top: 1px solid var(--rule); }
.who dt { font-size: var(--step-1); font-weight: 600; margin-bottom: 6px; }
.who dd { margin: 0; color: var(--ink-2); max-width: 46ch; }

/* Plans */
.plans { display: grid; grid-template-columns: minmax(0, 1fr); margin-top: 40px; border-top: 2px solid var(--ink); }
@media (min-width: 600px) { .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .plans { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.plan { padding: 24px 24px 28px 0; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; }
@media (min-width: 600px) { .plan + .plan { padding-left: 24px; border-left: 1px solid var(--rule); } .plan:nth-child(3) { border-left: 0; padding-left: 0; } }
@media (min-width: 1000px) { .plan:nth-child(3) { border-left: 1px solid var(--rule); padding-left: 24px; } }
.plan h3 { font-size: var(--step-2); }
.plan p { color: var(--ink-2); }
.plan-state { display: inline-block; align-self: flex-start; font-size: var(--step--1); font-weight: 600; color: var(--ink-2); border: 1px solid var(--rule); border-radius: 999px; padding: 2px 10px; margin: 10px 0 16px; }
.plan-state.is-live { color: var(--kv); border-color: currentColor; }
.plan-state.on-ink { color: var(--code-ink); border-color: color-mix(in srgb, var(--code-ink) 35%, transparent); }
.plan-link { margin-top: auto; font-weight: 600; }

/* Operators */
.operators-grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 880px) { .operators-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; } }
.section-ink h2 { color: var(--code-ink); }
.section-ink p { color: color-mix(in srgb, var(--code-ink) 78%, transparent); max-width: 48ch; }
.waitlist { display: grid; gap: 12px; max-width: 460px; }
.waitlist > label { font-weight: 600; }
.waitlist input[type="email"],
.waitlist input[type="text"] {
  font: inherit; min-height: 48px; padding: 0 14px; border-radius: var(--radius-s);
  border: 1.5px solid color-mix(in srgb, var(--code-ink) 40%, transparent);
  background: transparent; color: var(--code-ink); width: 100%;
}
.waitlist input::placeholder { color: color-mix(in srgb, var(--code-ink) 50%, transparent); }
.waitlist select {
  font: inherit; min-height: 48px; padding: 0 12px; border-radius: var(--radius-s);
  border: 1.5px solid color-mix(in srgb, var(--code-ink) 40%, transparent);
  background: transparent; color: var(--code-ink); width: 100%;
}
.waitlist select option { color: initial; }
.waitlist .wl-share { display: grid; gap: 8px; }
.waitlist .wl-share[hidden] { display: none; }
.waitlist .wl-share p { margin: 0; }
.waitlist .wl-share code { overflow-wrap: anywhere; }
.waitlist .wl-share-copy { border-color: color-mix(in srgb, var(--code-ink) 55%, transparent); color: var(--code-ink); background: transparent; }
.waitlist fieldset { border: 0; padding: 0; margin: 8px 0; display: grid; gap: 8px; }
.waitlist legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.check { display: flex; align-items: center; gap: 10px; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.waitlist .btn { justify-self: start; }
.form-status { min-height: 1.5em; font-size: var(--step--1); }
.section-ink a { color: var(--code-ink); }
.section-ink :focus-visible { outline-color: #9cc6dc; }

/* Footer */
.site-footer { border-top: 1px solid var(--rule); padding-block: 40px 56px; }
.footer-grid { display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: minmax(0, 1fr) auto; align-items: start; }
  .footer-grid nav { max-width: 36rem; }
  .footer-links { justify-content: flex-end; }
}
.footer-grid .brand { margin-bottom: 10px; }
.legal { margin: 28px 0 0; padding-top: 16px; border-top: 1px solid var(--rule); font-size: 0.8rem; line-height: 1.5; color: var(--ink-2); max-width: none; }
.legal a { color: inherit; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: var(--step--1); }

/* Docs page */
.docs-hero { padding-block: clamp(48px, 7vw, 88px) 24px; }
.docs-hero h1 { font-size: var(--step-3); letter-spacing: -0.03em; }
.docs-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.docs-list li { border-bottom: 1px solid var(--rule); }
.docs-list a { display: grid; gap: 4px; padding: 20px 0; text-decoration: none; }
@media (min-width: 720px) { .docs-list a { grid-template-columns: 16em minmax(0, 1fr); gap: 24px; } }
.docs-list a:hover strong { text-decoration: underline; }
.docs-list strong { font-size: var(--step-1); font-weight: 600; }
.docs-list span { color: var(--ink-2); }

/* About page */
.prose p { max-width: 66ch; color: var(--ink-2); font-size: var(--step-1); line-height: 1.5; }
.prose p:first-child { color: var(--ink); }
.prose .mission { color: var(--ink); font-size: var(--step-2); margin-top: 40px; }

/* Doc pages (generated by scripts/build_site_docs.py) */
.doc-wrap { max-width: 860px; padding-block: clamp(32px, 5vw, 64px) clamp(56px, 8vw, 96px); }
.doc-crumb { margin-bottom: 20px; }
.doc-crumb a { color: var(--ink-2); }
.doc { font-size: var(--step-0); line-height: 1.65; overflow-wrap: anywhere; }
.doc h1 { font-size: var(--step-3); letter-spacing: -0.03em; line-height: 1.05; margin-bottom: 28px; }
.doc h2 { font-size: var(--step-2); max-width: none; margin: 56px 0 16px; padding-top: 18px; border-top: 2px solid var(--ink); }
.doc h3 { font-size: var(--step-1); margin: 36px 0 12px; }
.doc h4 { font-size: var(--step-0); font-weight: 650; margin: 28px 0 8px; }
.doc p, .doc li { color: var(--ink); max-width: 72ch; }
.doc ul, .doc ol { padding-left: 1.3em; margin: 0 0 1em; }
.doc li { margin: 0.25em 0; }
.doc li > p { margin: 0.25em 0; }
.doc code { background: var(--paper-2); padding: 0.1em 0.35em; border-radius: 4px; }
.doc pre { background: var(--code-bg); color: var(--code-ink); border-radius: var(--radius-m); padding: 18px 20px; overflow-x: auto; font-family: var(--mono); font-size: 0.86rem; line-height: 1.6; margin: 0 0 1.4em; }
.doc pre code { background: none; padding: 0; font-size: inherit; color: inherit; }
.doc blockquote { margin: 0 0 1.2em; padding: 2px 0 2px 16px; border-left: 2px solid var(--rule); color: var(--ink-2); }
.doc table { width: 100%; border-collapse: collapse; margin: 8px 0 1.6em; font-size: var(--step--1); display: block; overflow-x: auto; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 9px 12px 9px 0; border-bottom: 1px solid var(--rule); }
.doc th { color: var(--ink-2); font-weight: 600; border-bottom-color: var(--ink-2); }
.doc hr { border: 0; border-top: 1px solid var(--rule); margin: 40px 0; }
.doc img { border-radius: var(--radius-m); }
.doc-pager { display: flex; justify-content: space-between; gap: 16px; margin-top: 56px; padding-top: 20px; border-top: 1px solid var(--rule); }
.doc-pager a { font-weight: 600; }


/* Hardware tiers slider ("What it does today") */
.tiers { margin-top: 36px; border: 1px solid var(--rule); border-radius: var(--radius-m); padding: 20px; background: var(--paper); }
.tiers-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.tiers-label { font-weight: 650; }
.tier-range { width: 100%; accent-color: var(--accent); height: 28px; margin: 0; cursor: pointer; }
.tier-stops { list-style: none; margin: 4px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); font-size: var(--step--1); }
.tier-stops[hidden] { display: none; }
.tier-stops li { text-align: center; }
.tier-stops li:first-child { text-align: left; } .tier-stops li:last-child { text-align: right; }
.tier-stops button { font: inherit; background: none; border: 0; padding: 4px 2px; color: var(--ink-2); cursor: pointer; border-radius: 4px; }
.tier-stops button[aria-current="true"] { color: var(--ink); font-weight: 650; }
.tier-stops span { display: block; font-size: 0.78rem; }
.tier-cards { display: grid; gap: 20px; margin-top: 18px; }
.tier { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 20px; align-items: center; }
@media (max-width: 560px) { .tier { grid-template-columns: 1fr; } .tier-art { width: 110px; } }
.tiers.js .tier-cards { display: block; }
.tiers.js .tier { display: none; }
.tiers.js .tier.is-on { display: grid; animation: tier-in 420ms ease both; }
@keyframes tier-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.tier h3 { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: var(--step-1); }
.tier-fig { font-size: var(--step-2); font-weight: 700; letter-spacing: -0.02em; margin: 6px 0 8px; }
.tier-fig span { font-size: var(--step--1); font-weight: 500; color: var(--ink-2); letter-spacing: 0; }
.tier-meter { height: 10px; border-radius: 999px; background: var(--paper-2); overflow: hidden; max-width: 420px; }
.tier-meter span { display: block; height: 100%; width: 100%; border-radius: inherit; background: var(--kv); transform-origin: left; transform: scaleX(var(--m, 0)); transition: transform 700ms cubic-bezier(.2,.7,.2,1); }
.tier-meter.is-empty { background: repeating-linear-gradient(90deg, var(--rule) 0 6px, transparent 6px 12px); }
.tier-what { margin: 10px 0 4px; font-weight: 500; }
.tier-note { margin: 0; color: var(--ink-2); font-size: var(--step--1); max-width: 62ch; }
.tag-emul { background: color-mix(in srgb, var(--head) 16%, transparent); color: var(--head); }
.tier-art { width: 120px; height: auto; }
.t-board { fill: color-mix(in srgb, var(--kv) 22%, transparent); stroke: var(--kv); stroke-width: 1.5; }
.t-chip, .t-screen { fill: var(--paper-2); stroke: var(--ink-2); stroke-width: 1.5; }
.t-pins circle { fill: var(--receipt); }
.t-port { fill: var(--paper-2); stroke: var(--ink-2); stroke-width: 1.2; }
.t-glass { fill: var(--paper); stroke: var(--rule); }
.t-base { fill: var(--ink-2); }
.t-cloud { fill: none; stroke: var(--ink-2); stroke-width: 2; stroke-dasharray: 5 5; }
.t-v1 { fill: var(--head); } .t-v2 { fill: var(--kv); } .t-v3 { fill: var(--expert); }
@media (prefers-reduced-motion: reduce) { .tiers.js .tier.is-on { animation: none; } .tier-meter span { transition: none; } }

/* How it works: cards rise in on scroll, then their diagrams animate (html.anim set by main.js) */
html.anim .steps li { opacity: 0; transform: translateY(18px); transition: opacity 600ms ease, transform 600ms cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0ms); }
html.anim .steps li.in { opacity: 1; transform: none; }
.steps li.in .step-art * { transform-box: fill-box; transform-origin: center; }
.steps li.in:nth-child(1) .step-art circle { animation: v-pop 3.2s ease-in-out infinite; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(2) { animation-delay: .25s; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(3) { animation-delay: .5s; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(4) { animation-delay: .75s; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(5) { animation-delay: 1s; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(6) { animation-delay: 1.25s; }
.steps li.in:nth-child(1) .step-art circle:nth-of-type(7) { animation-delay: 1.5s; }
.steps li.in:nth-child(2) .step-art .a-ring { animation: v-spin 16s linear infinite; }
.steps li.in:nth-child(2) .step-art .a-box { animation: v-bob 2.6s ease-in-out infinite; }
.steps li.in:nth-child(2) .step-art .a-box:nth-of-type(2) { animation-delay: .65s; }
.steps li.in:nth-child(2) .step-art .a-box:nth-of-type(3) { animation-delay: 1.3s; }
.steps li.in:nth-child(2) .step-art .a-box:nth-of-type(4) { animation-delay: 1.95s; }
.steps li.in:nth-child(3) .step-art .a-msg { animation: v-flow 900ms linear infinite; }
.steps li.in:nth-child(3) .step-art circle { animation: v-pulse 1.8s ease-in-out infinite; }
.steps li.in:nth-child(3) .step-art circle:nth-of-type(2), .steps li.in:nth-child(3) .step-art circle:nth-of-type(3) { animation-delay: .45s; }
.steps li.in:nth-child(3) .step-art circle:nth-of-type(4) { animation-delay: .9s; }
.steps li.in:nth-child(4) .step-art .a-grid rect { animation: v-flicker 2.4s ease-in-out infinite; }
.steps li.in:nth-child(4) .step-art .a-grid rect:nth-child(odd) { animation-delay: .6s; }
.steps li.in:nth-child(4) .step-art .a-grid rect:nth-child(3n) { animation-delay: 1.2s; }
.steps li.in:nth-child(4) .step-art .a-bar { transform-origin: left center; animation: v-grow 2.4s cubic-bezier(.2,.7,.2,1) infinite; }
.steps li.in:nth-child(4) .step-art .a-bar:nth-of-type(2) { animation-delay: .2s; }
.steps li.in:nth-child(4) .step-art .a-bar:nth-of-type(3) { animation-delay: .4s; }
@keyframes v-pop { 0%, 70%, 100% { transform: scale(1); } 80% { transform: scale(1.45); } }
@keyframes v-spin { to { transform: rotate(360deg); } }
@keyframes v-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes v-flow { to { stroke-dashoffset: -14; } }
@keyframes v-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.25); } }
@keyframes v-flicker { 0%, 100% { filter: none; } 50% { filter: brightness(1.35) saturate(1.2); } }
@keyframes v-grow { 0% { transform: scaleX(.15); } 45%, 100% { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) {
  html.anim .steps li { opacity: 1; transform: none; transition: none; }
  .steps li.in .step-art * { animation: none !important; }
}

/* Parallax logo watermarks on every page (watermarks.js): fixed layer behind content, above section bands */
.wm-layer { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.wm-layer img { position: absolute; left: 0; top: 0; height: auto; opacity: 0.065; will-change: transform; user-select: none; }
@media (prefers-color-scheme: dark) { .wm-layer img { opacity: 0.075; } }
body.wm-on > header .wrap, body.wm-on > footer .wrap, body.wm-on main > section > .wrap, body.wm-on main > .wrap, body.wm-on .skip { position: relative; z-index: 1; }
body.wm-on .skip { position: absolute; z-index: 30; }
@media print { .wm-layer { display: none; } }

/* Collapsible measurements table under the hardware slider */
.measures-more { margin-top: 28px; border-top: 1px solid var(--rule); }
.measures-more > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 10px; padding: 16px 0 4px; font-weight: 600; }
.measures-more > summary::-webkit-details-marker { display: none; }
.measures-more > summary::before { content: ""; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform 200ms ease; }
.measures-more[open] > summary::before { transform: rotate(45deg); }
.measures-more > summary:hover { text-decoration: underline; text-underline-offset: 0.18em; }
.measures-more .measures { margin-top: 12px; }
.measures-more .when-open, .measures-more[open] .when-closed { display: none; }
.measures-more[open] .when-open { display: inline; }
@media (prefers-reduced-motion: reduce) { .measures-more > summary::before { transition: none; } }

/* White paper (whitepaper.html) */
.wp-layout { max-width: 860px; padding-block: clamp(32px, 5vw, 64px) clamp(56px, 8vw, 96px); }
.wp-head { margin-bottom: 32px; }
.wp-kicker { font-family: var(--mono); font-size: var(--step--1); color: var(--ink-2); margin-bottom: 16px; }
.doc .wp-head h1 { margin-bottom: 20px; }
.wp-byline { color: var(--ink-2) !important; font-size: var(--step-1); line-height: 1.45; }
.wp-abstract { background: var(--paper-2); border: 1px solid var(--rule); border-radius: var(--radius-m); padding: 22px 24px 8px; margin: 0 0 32px; }
.doc .wp-abstract h2 { font-size: var(--step-0); text-transform: uppercase; letter-spacing: 0.08em; border-top: 0; padding-top: 0; margin: 0 0 10px; }
.wp-toc { border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); padding: 16px 0 12px; margin-bottom: 8px; }
.wp-toc-title { font-weight: 650; margin-bottom: 8px; }
.doc .wp-toc ol { margin: 0; padding-left: 1.6em; columns: 2 16em; column-gap: 32px; }
.wp-toc li { break-inside: avoid; }
.wp-toc a { text-decoration: none; }
.wp-toc a:hover { text-decoration: underline; }
.wp-n { display: inline-block; min-width: 1.6em; color: var(--accent); font-variant-numeric: tabular-nums; }
.wp-fig { margin: 24px 0 28px; }
.wp-fig svg { width: 100%; height: auto; }
.wp-fig figcaption { font-size: var(--step--1); color: var(--ink-2); margin-top: 8px; }
.wf-r4 { fill: var(--paper-2); stroke: var(--rule); stroke-width: 1.5; stroke-dasharray: 6 5; }
.wf-r3 { fill: color-mix(in srgb, var(--head) 9%, var(--paper)); stroke: var(--head); stroke-width: 1.5; }
.wf-r2 { fill: color-mix(in srgb, var(--kv) 12%, var(--paper)); stroke: var(--kv); stroke-width: 1.5; }
.wf-r1 { fill: var(--ink); }
.wf-h { font: 650 15px var(--font); fill: var(--ink); }
.wf-t { font: 400 13px var(--font); fill: var(--ink-2); }
.wf-in { fill: var(--paper); }
.wf-s { font: 500 12px var(--mono); fill: color-mix(in srgb, var(--paper) 75%, transparent) !important; }
.wp-dl { margin: 0; }
.wp-dl div { padding: 16px 0; border-top: 1px solid var(--rule); }
.wp-dl dt { font-weight: 650; margin-bottom: 6px; }
.wp-dl dd { margin: 0; max-width: 72ch; }
.wp-status td:last-child { width: 38%; }
.wp-status .tag { white-space: nowrap; }
.wp-table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.wp-compare { min-width: 600px; }
.wp-compare td:first-child { min-width: 8.5em; font-weight: 600; }
.wp-cta { margin-top: 56px; }
.doc pre code { white-space: pre; }
.wp pre { font-size: 0.8rem; }
@media (max-width: 640px) { .wf-t { font-size: 11px; } .wf-h { font-size: 13px; } }

/* Beta waitlist (index.html #waitlist) */
.beta-grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 880px) { .beta-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; } }
.beta-grid h2 { margin-bottom: 4px; }
.waitlist textarea {
  font: inherit; padding: 10px 14px; border-radius: var(--radius-s); resize: vertical; min-height: 84px;
  border: 1.5px solid color-mix(in srgb, var(--code-ink) 40%, transparent);
  background: transparent; color: var(--code-ink); width: 100%;
}
.waitlist textarea::placeholder { color: color-mix(in srgb, var(--code-ink) 50%, transparent); }
.waitlist .opt { font-weight: 400; color: color-mix(in srgb, var(--code-ink) 65%, transparent); }
.waitlist .btn[disabled] { opacity: 0.6; cursor: progress; }
.waitlist .wl-human { min-height: 0; }
.waitlist .wl-step { display: grid; gap: 12px; }
.waitlist .wl-step[hidden] { display: none; }
.waitlist .wl-sent { margin: 0; }
.waitlist #wl-pin { max-width: 12ch; letter-spacing: 0.3em; font-variant-numeric: tabular-nums; font-size: 1.25em; }
.waitlist .wl-code-links { margin: 0; font-size: var(--step--1); }
.waitlist .linklike { font: inherit; color: inherit; background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.waitlist .linklike:hover { color: var(--code-ink); }
.waitlist .hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-status.is-ok { color: #9fd08a; font-weight: 600; }
.form-status.is-err { color: #f0a46e; }
.form-fine { margin: 0; font-size: 0.8rem; color: color-mix(in srgb, var(--code-ink) 62%, transparent) !important; }

/* White paper diagrams and charts (inline SVG; colours follow the theme tokens) */
:root { --ch1: #a25a28; --ch2: #2a6a9a; --ch3: #4f7f2a; --ch4: #7b4f9e; }
@media (prefers-color-scheme: dark) { :root { --ch1: #c27a40; --ch2: #4a8cc4; --ch3: #7f9f45; --ch4: #9a7cc0; } }
.wp-fig { margin: 28px 0 32px; }
.wp-fig .fig-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--rule); border-radius: var(--radius-m); background: var(--paper); padding: 12px; }
.wp-fig .fig-scroll svg { min-width: 640px; width: 100%; height: auto; display: block; }
.wp-fig figcaption { font-size: var(--step--1); color: var(--ink-2); margin-top: 10px; max-width: 72ch; }
.wp-fig figcaption b { color: var(--ink); font-weight: 650; }
.dg { font-family: var(--font); }
.dg text { fill: var(--ink); }
.dg .h { font-size: 14px; font-weight: 650; }
.dg .t { font-size: 12.5px; fill: var(--ink-2); }
.dg .m { font-family: var(--mono); font-size: 11.5px; fill: var(--ink-2); }
.dg .s { font-size: 11px; fill: var(--ink-2); }
.dg .on-ink { fill: var(--paper); }
.dg .on-ink-2 { fill: color-mix(in srgb, var(--paper) 78%, transparent); }
.dg .box { fill: var(--paper); stroke: var(--rule); stroke-width: 1.5; }
.dg .box2 { fill: var(--paper-2); stroke: var(--rule); stroke-width: 1; }
.dg .box-acc { fill: var(--paper); stroke: var(--accent); stroke-width: 2; }
.dg .box-ink { fill: var(--ink); }
.dg .ln { stroke: var(--ink-2); stroke-width: 1.5; fill: none; }
.dg .ln-thin { stroke: var(--ink-2); stroke-width: 1; fill: none; opacity: .7; }
.dg .ln-acc { stroke: var(--accent); stroke-width: 1.8; fill: none; }
.dg .ln-exp { stroke: var(--expert); stroke-width: 1.6; fill: none; }
.dg .ln-kv { stroke: var(--kv); stroke-width: 1.4; fill: none; }
.dg .ln-head { stroke: var(--head); stroke-width: 1.4; fill: none; }
.dg .ln-rec { stroke: var(--receipt); stroke-width: 1.6; fill: none; }
.dg .dash { stroke-dasharray: 5 4; }
.dg .grid { stroke: var(--rule); stroke-width: 1; }
.dg .f-tok { fill: var(--token); } .dg .f-head { fill: var(--head); } .dg .f-kv { fill: var(--kv); }
.dg .f-exp { fill: var(--expert); } .dg .f-neu { fill: var(--neuron); } .dg .f-rec { fill: var(--receipt); }
.dg .f-bulk { fill: var(--bulk); } .dg .f-acc { fill: var(--accent); }
.dg .o-exp { fill: var(--paper); stroke: var(--expert); stroke-width: 1.4; opacity: .55; }
.dg .z-trust { fill: color-mix(in srgb, var(--kv) 11%, var(--paper)); stroke: var(--kv); stroke-width: 1.5; }
.dg .z-peer { fill: color-mix(in srgb, var(--head) 9%, var(--paper)); stroke: var(--head); stroke-width: 1.5; }
.dg .z-pub { fill: var(--paper-2); stroke: var(--ink-2); stroke-width: 1.2; stroke-dasharray: 6 5; }
.dg .z-bad { fill: color-mix(in srgb, var(--expert) 10%, var(--paper)); stroke: var(--expert); stroke-width: 1.5; }
.dg .ch1 { fill: var(--ch1); } .dg .ch2 { fill: var(--ch2); } .dg .ch3 { fill: var(--ch3); }
.dg .ch1-ln { stroke: var(--ch1); stroke-width: 3; } .dg .ch2-ln { stroke: var(--ch2); stroke-width: 3; } 
.dg .ch4 { fill: var(--ch4); }
.dg .ch3-ln { stroke: var(--ch3); stroke-width: 3; } .dg .ch4-ln { stroke: var(--ch4); stroke-width: 3; }
.dg .dot { stroke: var(--paper); stroke-width: 2; }  /* surface ring: legible where lines cross */
.dg [data-tip] { cursor: default; }
.dg [data-tip]:hover, .dg [data-tip]:focus { filter: brightness(1.12); outline: none; }
.dg .legend-sw { rx: 3; }
.wp-tip { position: fixed; z-index: 20; pointer-events: none; background: var(--ink); color: var(--paper); font-size: 0.8rem; line-height: 1.35; padding: 6px 10px; border-radius: 6px; max-width: 260px; box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.wp-tip[hidden] { display: none; }
.wp-arrows { position: absolute; width: 0; height: 0; overflow: hidden; }
.mk-ink { fill: var(--ink-2); } .mk-acc { fill: var(--accent); } .mk-exp { fill: var(--expert); } .mk-rec { fill: var(--receipt); } .mk-kv { fill: var(--kv); } .mk-head { fill: var(--head); }

/* Product tour on the home page (#tour): feature rows with video loops */
.cs-grid { display: grid; gap: 32px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) {
  .cs-copy { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); column-gap: 56px; align-items: start; }
  .cs-head { grid-column: 1; grid-row: 1 / span 8; }
  .cs-copy > p, .cs-copy > ul { grid-column: 2; }
  .cs-copy > p { max-width: 62ch; }
}
.cs-kicker { font-family: var(--mono); font-size: var(--step--1); color: var(--accent); margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.08em; }
.cs-copy h2 { margin-bottom: 18px; }
.cs-copy p { color: var(--ink-2); max-width: 54ch; }
.cs-points { margin: 0; padding-left: 1.2em; color: var(--ink-2); display: grid; gap: 6px; }
.cs-shot { margin: 0; }
.cs-media { position: relative; border-radius: 0 0 var(--radius-m) var(--radius-m); overflow: hidden; background: #262626; }
.cs-media video { width: 100%; height: auto; display: block; }
.loop-toggle { position: absolute; right: 10px; bottom: 10px; padding: 5px 11px; border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px; background: rgba(20, 18, 15, 0.72); color: #f1ece2; font: 500 0.75rem/1.2 var(--font); cursor: pointer; opacity: 0.75; }
.loop-toggle:hover, .loop-toggle:focus-visible { opacity: 1; }
.loop-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tour-intro { max-width: 62ch; margin-bottom: clamp(40px, 6vw, 72px); }
.tour-intro h2 { margin-bottom: 14px; }
.tour-intro p { color: var(--ink-2); }
/* Two plain sections in a row (the status table, then the problem) get a rule between them. */
.section:not(.section-alt):not(.section-ink) + .section:not(.section-alt):not(.section-ink) { border-top: 1px solid var(--rule); }
.cs-frame { display: flex; align-items: center; gap: 7px; padding: 10px 14px; background: #1d1d1d; border-radius: var(--radius-m) var(--radius-m) 0 0; }
.cs-frame span { width: 10px; height: 10px; border-radius: 50%; background: #4a4640; }
.cs-frame span:nth-child(1) { background: #c8604a; } .cs-frame span:nth-child(2) { background: #c8a04a; } .cs-frame span:nth-child(3) { background: #6a9a4a; }
.cs-frame code { margin-left: 10px; color: #a8a196; background: none; font-size: 0.78rem; }
.cs-shot { box-shadow: 0 18px 50px -20px rgba(30, 20, 10, 0.45); border-radius: var(--radius-m); }
.cs-shot figcaption { font-size: var(--step--1); color: var(--ink-2); padding: 12px 2px 0; }
.cs-cards { display: grid; gap: 0 40px; grid-template-columns: minmax(0, 1fr); margin-top: 32px; }
@media (min-width: 720px) { .cs-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .cs-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.cs-cards div { padding: 22px 0; border-top: 1px solid var(--rule); }
.cs-cards h3 { margin-bottom: 8px; }
.cs-cards p { color: var(--ink-2); margin: 0; }
/* ---------------- About: tabs and contact (about.html, about.js) ---------------- */
.about-clip { max-width: 360px; margin: 28px 0 0; }
.about-clip .cs-media { border-radius: var(--radius-m); }
.about-clip figcaption { font-size: var(--step--1); color: var(--ink-2); margin-top: 10px; }
.about-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--rule); margin-top: 8px; }
.about-tabs[hidden] { display: none; }
.about-tab { padding: 12px 18px; font-weight: 600; color: var(--ink-2); text-decoration: none; border-bottom: 3px solid transparent; margin-bottom: -1px; border-radius: var(--radius-s) var(--radius-s) 0 0; }
.about-tab:hover { color: var(--ink); background: var(--paper-2); }
.about-tab[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }
.about-tab:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.about-panel:focus { outline: none; }
.faq h2 { margin-bottom: 12px; }
.faq details { border-bottom: 1px solid var(--rule); }
.faq details:first-of-type { border-top: 1px solid var(--rule); }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; font-weight: 600; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: 0 0 auto; width: 8px; height: 8px; margin-right: 4px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform 200ms ease; }
.faq details[open] > summary::after { transform: rotate(-135deg); }
.faq summary:hover { text-decoration: underline; text-underline-offset: 0.18em; }
.faq summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: var(--radius-sm, 4px); }
.faq details p { margin: 0 0 18px; color: var(--ink-2); font-size: 1.0625rem; max-width: 64ch; }
@media (prefers-reduced-motion: reduce) { .faq summary::after { transition: none; } }
.contact { display: grid; gap: 32px 64px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 880px) { .contact { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.contact-form { display: grid; gap: 8px; max-width: 520px; }
.contact-form[hidden] { display: none; }
.contact-form label { font-weight: 600; margin-top: 6px; }
.contact-form input, .contact-form select, .contact-form textarea {
  font: inherit; color: var(--ink); background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--radius-s); padding: 10px 12px; width: 100%;
}
.contact-form textarea { resize: vertical; min-height: 120px; }
.contact-form input:focus-visible, .contact-form select:focus-visible, .contact-form textarea:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.contact-form .btn { justify-self: start; margin-top: 10px; }
.contact-form .form-status.is-ok { color: var(--kv); }
.contact-form .form-status.is-err { color: var(--expert); }
.contact-note { color: var(--ink-2); margin: 0; }
.contact .aside { margin-top: 24px; }

/* ---------- Issue log (issues.html) ---------- */
.prio { display: inline-block; min-width: 2.6em; padding: 1px 8px; border-radius: 999px; font: 600 0.78rem/1.6 "JetBrains Mono", ui-monospace, monospace; text-align: center; }
.prio-p1 { background: color-mix(in srgb, #c2410c 18%, transparent); color: #c2410c; }
.prio-p2 { background: color-mix(in srgb, #a16207 18%, transparent); color: #a16207; }
.prio-p3 { background: var(--paper-2); color: var(--ink-2); border: 1px solid var(--rule); }
@media (prefers-color-scheme: dark) {
  .prio-p1 { color: #fb923c; }
  .prio-p2 { color: #facc15; }
}
.prio-key { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 10px; max-width: 70ch; color: var(--ink-2); }
.prio-key .prio { margin-right: 10px; }
.issue-log { margin-top: 20px; overflow-x: auto; }
.issue-log table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.issue-log th, .issue-log td { text-align: left; vertical-align: baseline; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--rule); }
.issue-log th { font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.issue-log td:nth-child(2), .issue-log td:nth-child(4) { white-space: nowrap; color: var(--ink-2); }
.issue-log tr.is-resolved td:first-child { color: var(--ink-2); }
.issue-log-status { color: var(--ink-2); }
.support-bot { max-width: 560px; }
.support-bot .bot-note { color: color-mix(in srgb, var(--code-ink) 70%, transparent); margin: 0; }
.bot-reply { margin-top: 4px; padding: 14px 16px; border-radius: 10px; background: color-mix(in srgb, var(--code-ink) 8%, transparent); line-height: 1.5; }
.bot-reply dl { display: grid; grid-template-columns: max-content 1fr; gap: 4px 14px; margin: 10px 0 0; }
.bot-reply dt { font-weight: 600; }
.bot-reply dd { margin: 0; }
.release { white-space: nowrap; }
.release::before { content: "·"; margin: 0 8px 0 4px; }
@media (max-width: 640px) {
  .issue-log table, .issue-log tbody, .issue-log tr, .issue-log td { display: block; width: auto; }
  .issue-log thead { display: none; }
  .issue-log tr { padding: 12px 0; border-bottom: 1px solid var(--rule); }
  .issue-log td { border: 0; padding: 2px 0; white-space: normal !important; }
  .issue-log td:first-child { font-weight: 600; color: var(--ink); }
}

/* Home page: "Tested at scale" charts (built by scripts/build_charts.py from the AWS runs) */
.scale-intro { max-width: 72ch; color: var(--ink-2); margin-top: 8px; }
.scale-charts .wp-fig { margin: 20px 0 24px; }
.scale-more { margin-top: 4px; }

/* Benchmarks page (benchmarks.html, generated by bench/aws/benchmarks_page.py) */
.bench { padding-bottom: 64px; }
.bench h2 { font-size: var(--step-2); letter-spacing: -0.02em; margin-top: 48px; }
.bench > p { max-width: 72ch; color: var(--ink-2); }
.bench-stats { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 8px; }
.bench-stat { border: 1px solid var(--rule); border-radius: var(--radius-m); background: var(--paper); padding: 18px 20px; }
.bench-stat p { margin: 0; }
.bench-num { font-size: var(--step-3); font-weight: 700; letter-spacing: -0.03em; line-height: 1.05; color: var(--ink); }
.bench-what { font-weight: 600; color: var(--ink); margin-top: 6px !important; }
.bench-ctx { font-size: var(--step--1); color: var(--ink-2); margin-top: 4px !important; }
.bench-table { overflow-x: auto; margin: 16px 0 8px; }
.bench-table table { border-collapse: collapse; width: 100%; max-width: 880px; font-size: var(--step--1); }
.bench-table caption { text-align: left; color: var(--ink-2); padding-bottom: 8px; }
.bench-table th, .bench-table td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid var(--rule); }
.bench-table thead th { color: var(--ink-2); font-weight: 600; }
.bench-table tbody th { font-weight: 650; color: var(--ink); white-space: nowrap; }
#numbers .bench-table tbody th { white-space: normal; min-width: 9em; }
#numbers .bench-table td { min-width: 7em; }
.bench-list { max-width: 72ch; color: var(--ink-2); padding-left: 1.2em; }
.bench-list li { margin: 6px 0; }
.bench h3 { font-size: var(--step-1); margin-top: 20px; }

/* Models page (models.html, generated by scripts/models_page.py) */
.mdl-yes, .mdl-no { white-space: nowrap; font-weight: 600; }
.mdl-yes { color: var(--ink); }
.mdl-no { color: var(--ink-2); font-weight: 400; }
.bench-table td { font-variant-numeric: tabular-nums; }

/* Network shapes: three decks of cards that deal themselves ("One mesh, three shapes") */
.shapes-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.shapes-head .ex-play { align-self: center; }
.shapes { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; margin-top: 32px; }
@media (min-width: 880px) { .shapes { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; } }
.shape h3 { font-size: var(--step-1); line-height: 1.3; margin: 22px 0 8px; }
.shape h3 .tag { margin-left: 4px; vertical-align: 0.15em; }
.shape p { margin: 0; color: var(--ink-2); max-width: 46ch; }
.shape-n {
  display: inline-grid; place-items: center; width: 1.6em; height: 1.6em; border-radius: 999px; margin-right: 6px; vertical-align: 0.1em;
  border: 1px solid var(--rule); font-size: 0.8em; font-weight: 650; color: var(--ink-2);
}
.deck { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sc {
  display: grid; grid-template-columns: 52px minmax(0, 1fr); grid-template-rows: auto auto auto; column-gap: 12px;
  align-items: center; padding: 14px 16px; border: 1px solid var(--rule); border-radius: var(--radius-m);
  background: var(--paper);
}
.section-alt .sc { background: var(--paper); }
.sc-art { grid-row: 1 / span 3; width: 52px; height: auto; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sc-tag { font-size: 0.72rem; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-2); }
.sc strong { font-size: 1.02rem; line-height: 1.3; }
.sc-line { font-size: var(--step--1); color: var(--ink-2); line-height: 1.4; }

/* With JS: the list becomes a stacked deck; --i is a card's place in the stack (0 = front). */
.shapes.js .deck { position: relative; display: block; height: 196px; max-width: 340px; cursor: pointer; }
.shapes.js .sc {
  position: absolute; left: 0; top: 0; width: calc(100% - 36px); height: 150px; align-content: center;
  transform: translate(calc(var(--i, 0) * 9px), calc(var(--i, 0) * 11px)) rotate(calc(var(--i, 0) * 1.6deg));
  z-index: calc(20 - var(--i, 0));
  opacity: clamp(0, calc(1.6 - var(--i, 0) * 0.3), 1);
  transition: transform 520ms cubic-bezier(.2,.7,.2,1), opacity 520ms ease;
}
.shapes.js .sc.is-front { border-color: var(--ink-2); }
.shapes.js .sc.is-front .sc-art { stroke: var(--ink); }
.shapes.js .sc:not(.is-front) > * { opacity: 0.55; }
/* The front card lifts off to the left, then slides in at the back. */
.shapes.js .sc.is-dealt { transform: translate(-58%, -14px) rotate(-9deg); opacity: 0; transition: transform 320ms ease-in, opacity 320ms ease-in; }
.deck-nav { display: flex; align-items: center; gap: 10px; margin: 4px 0 0; font-size: 0.78rem; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.deck-nav[hidden] { display: none; }
.deck-nav .ex-play { margin-left: 0; }
@media (max-width: 420px) { .shapes.js .deck { height: 210px; } .shapes.js .sc { height: 164px; } }
@media (prefers-reduced-motion: reduce) { .shapes.js .sc, .shapes.js .sc.is-dealt { transition: none; } }

/* "Getting faster" charts (scripts/perf_history.py builds them, perf-charts.js animates them in).
   Hues after Okabe and Ito, darkened or lightened to 4.3:1 or more on the page; every series also has
   its own marker shape. */
:root { --gf1: #0b6aa8; --gf2: #c0500c; --gf3: #0a7f5a; --gf4: #a3478a; }
@media (prefers-color-scheme: dark) { :root { --gf1: #5ab4ea; --gf2: #f08c4e; --gf3: #3cc79a; --gf4: #e39acb; } }
.dg .gf1 { fill: var(--gf1); } .dg .gf2 { fill: var(--gf2); } .dg .gf3 { fill: var(--gf3); } .dg .gf4 { fill: var(--gf4); }
.dg .gf1-ln { stroke: var(--gf1); stroke-width: 3; } .dg .gf2-ln { stroke: var(--gf2); stroke-width: 3; }
.dg .gf3-ln { stroke: var(--gf3); stroke-width: 3; } .dg .gf4-ln { stroke: var(--gf4); stroke-width: 3; }
.dg .gf-mark { stroke: var(--paper); stroke-width: 2; transform-box: fill-box; transform-origin: center; }
.dg .gf-key { stroke: var(--paper); stroke-width: 1.5; }
.dg .gf-val { fill: var(--ink); }
.gf-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 22px; padding: 2px 4px 0; margin: 0 0 4px; font-size: var(--step--1); color: var(--ink-2); }
.gf-legend li { display: inline-flex; align-items: center; gap: 7px; }
.wp-fig.gf-fig .fig-scroll .gf-legend svg { flex: none; display: inline; min-width: 0; width: 16px; height: 16px; }
.wp-fig.gf-fig .fig-scroll svg.gf-narrow { display: none; }
@media (max-width: 600px) {
  .wp-fig.gf-fig .fig-scroll svg.gf-wide { display: none; }
  .wp-fig.gf-fig .fig-scroll svg.gf-narrow { display: block; min-width: 0; }
}
.gf-data { margin-top: 10px; }
.gf-data > summary { cursor: pointer; font-size: var(--step--1); font-weight: 600; color: var(--ink); width: fit-content; }
.gf-data > summary:hover { text-decoration: underline; text-underline-offset: 0.18em; }
.gf-data .bench-table { margin-top: 6px; }
.gf-teaser { margin-top: 40px; }
.gf-wait .gf-mark, .gf-wait .gf-val { opacity: 0; }
.gf-wait .gf-mark { transform: scale(0.2); }
.gf-go .gf-mark, .gf-go .gf-val { transition: opacity 0.45s ease, transform 0.5s cubic-bezier(0.2, 0.8, 0.3, 1.4);
  transition-delay: calc(var(--t, 0) * 1.4s + 100ms); }
.gf-go .gf-line { transition: stroke-dashoffset 1.5s ease-in-out; }
@media (prefers-reduced-motion: reduce) {
  .gf-wait .gf-mark, .gf-wait .gf-val { opacity: 1; transform: none; }
  .gf-go .gf-mark, .gf-go .gf-val, .gf-go .gf-line { transition: none; }
}
@media print { .gf-wait .gf-mark, .gf-wait .gf-val { opacity: 1; transform: none; } }

/* White paper sign-up (whitepaper.html) and reader (read.html) */
.wp-get { background: var(--code-bg); color: var(--code-ink); border-radius: var(--radius-m); padding: clamp(20px, 4vw, 32px); margin: 0 0 2em; }
.doc .wp-get h2 { color: var(--code-ink); border-top: 0; padding-top: 0; margin-top: 0; }
.wp-get p { color: color-mix(in srgb, var(--code-ink) 78%, transparent); }
.wp-get .waitlist .small { margin: 0; }
.wp-gate .wp-toc li { color: var(--ink-2); }
.reader-note { color: var(--ink-2); margin: 0 0 8px; }
.reader-note[hidden] { display: none; }
.reader-msg { font-size: var(--step-1); }
.reader-mark { color: var(--ink-2); margin-top: 40px; }
#paper { background-repeat: repeat; background-position: 0 0; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.reader-noprint { display: none; }
@media print {
  .reader-page main > *, .reader-page .site-header, .reader-page .site-footer, .reader-page .wm-layer { display: none !important; }
  .reader-page main > .reader-noprint { display: block !important; font-size: 14pt; margin: 2cm; }
}
.reader-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 30; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 8px; font-size: var(--step--1); box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.reader-toast[hidden] { display: none; }
.wp-get-jump { margin: 0 0 1.6em; }

/* Benchmarks: comparison with other projects */
.compare h3 { font-size: var(--step-1); letter-spacing: -0.01em; margin-top: 32px; }
.compare-table table { max-width: none; min-width: 960px; }
.compare-table tbody th { white-space: normal; min-width: 8.5em; }
.compare-table td { min-width: 9.5em; }
.compare-table tr.is-brahma th, .compare-table tr.is-brahma td { background: var(--paper-2); }
.compare-table .cmp-lic { display: block; font-family: var(--mono); font-size: 0.78rem; font-weight: 400; color: var(--ink-2); margin-top: 2px; }
.cmp-sources { margin-top: 12px; color: var(--ink-2); font-size: var(--step--1); }
.cmp-sources summary { cursor: pointer; }
.cmp-sources ul { padding-left: 1.2em; }
.fit-table tbody th { white-space: normal; max-width: 34em; }

/* Unique features (#features): each feature is a cell, and the cells of a group form a tissue.
   Without JS each cell is a soft, irregular rounded box. cells.js adds .walls and draws shared,
   wobbly walls of varying thickness over the grid (one SVG per tissue) that drift slowly like a
   cell membrane. --cell is the group's colour; it only tints walls and drawings. */
.feat-group { margin-top: 64px; display: flex; align-items: center; gap: 12px; }
.feat-group::before { content: ""; flex: none; width: 16px; height: 16px; background: var(--cell); border-radius: 46% 54% 40% 60% / 55% 45% 55% 45%; }
.tissue { --cell: var(--ink-2); position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); margin-top: 22px; }
.cell {
  grid-column: span 6; position: relative; min-width: 0; margin: 5px; padding: 30px 28px 24px;
  border: 3px solid color-mix(in srgb, var(--cell) 72%, transparent);
  border-radius: 38px 24px 44px 28px / 28px 42px 24px 36px;
  background: color-mix(in srgb, var(--cell) 7%, var(--paper));
}
.cell:nth-child(even) { border-radius: 26px 44px 30px 40px / 40px 26px 44px 28px; border-width: 4px 2px 5px 3px; }
.tissue.walls .cell { margin: 0; border-color: transparent; background: none; }
.cell > * { position: relative; z-index: 1; }
@media (min-width: 640px) {
  .cell { grid-column: span 3; }
  .cell.c6, .cell.md6 { grid-column: span 6; }
}
@media (min-width: 1000px) {
  .cell.c2 { grid-column: span 2; } .cell.c3 { grid-column: span 3; }
  .cell.c4 { grid-column: span 4; } .cell.c6 { grid-column: span 6; }
  .cell.r2 { grid-row: span 2; display: flex; flex-direction: column; justify-content: center; }
}
.tissue-walls { max-width: none; position: absolute; left: -16px; top: -16px; width: calc(100% + 32px); height: calc(100% + 32px); pointer-events: none; overflow: visible; z-index: 0; }
.tissue-walls .wall { fill: var(--cell); }
.tissue-walls .plasm { fill: color-mix(in srgb, var(--cell) 7%, var(--paper)); }
.cell h4 { margin: 16px 0 2px; font-size: var(--step-1); font-weight: 650; letter-spacing: -0.01em; line-height: 1.15; }
.cell-fig { margin: 0 0 8px; font-size: var(--step-2); font-weight: 750; letter-spacing: -0.02em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.cell-fig span { font-size: var(--step--1); font-weight: 600; color: var(--ink-2); letter-spacing: 0; }
.cell p { color: var(--ink-2); font-size: 0.97rem; margin-bottom: 0.6em; max-width: 62ch; }
.cell-list { margin: 0 0 0.6em; padding-left: 1.1em; color: var(--ink-2); font-size: 0.92rem; }
.cell-list li { margin: 3px 0; }
.cell-list li::marker { color: var(--cell); }
.cell .cell-note { font-size: var(--step--1); }
.cell code { background: var(--paper-2); padding: 0.1em 0.35em; border-radius: 4px; }

/* Line drawings inside cells */
.ill, .chart { width: 100%; height: auto; max-height: 132px; overflow: visible; }
.ill-wide { max-height: 200px; }
.r2 .ill-wide { max-height: 270px; margin-block: 8px 18px; }
.ill-short { max-height: 84px; }
.chart-form { max-height: 180px; }
.gauge { max-height: 150px; }
.ill-tall { max-height: 210px; }
.ill-s { max-width: 168px; max-height: 84px; }
.ill.map { max-height: 290px; }
.ill *, .chart * { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ill-s * { stroke-width: 1.7; }
.ill .c, .chart .c { stroke: var(--cell); }
.ill .s { fill: color-mix(in srgb, var(--cell) 16%, transparent); }
.ill .k, .chart .k { fill: var(--cell); stroke: none; }
.ill .dash { stroke: var(--ink-2); stroke-dasharray: 4 6; }
.ill .soft { stroke: var(--ink-2); stroke-width: 1.5; }
.ill .flow { stroke: var(--ink-2); stroke-width: 1.6; stroke-dasharray: 3 6; }
.ill .c.flow { stroke: var(--cell); }
.ill .t, .chart .t { fill: var(--ink-2); stroke: none; font: 500 10px var(--mono); }
.ill .tc, .chart .tc { text-anchor: middle; }
.ill .dotsgrid circle { stroke: var(--ink-2); stroke-width: 1.5; }

/* The mesh map and its numbers */
.map .land path { fill: color-mix(in srgb, var(--cell) 10%, transparent); stroke: color-mix(in srgb, var(--cell) 55%, transparent); stroke-width: 2.5; }
.map .land .far { opacity: .45; }
.map .ring { stroke: var(--cell); stroke-width: 2; }
.map .t { font-size: 11px; fill: var(--ink); }
.stats { list-style: none; margin: 14px 0 4px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: 16px 20px; }
.stats b small { font-size: .5em; font-weight: 650; letter-spacing: 0; }
.stats b span { font: inherit; color: inherit; margin: 0; display: inline; }
.stats b { display: block; font-size: clamp(2rem, 1.5rem + 1.8vw, 3.1rem); font-weight: 750; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.stats span { display: block; margin-top: 6px; font-size: var(--step--1); color: var(--ink-2); }
.stats li { border-top: 3px solid var(--cell); padding-top: 10px; }

/* Before/after bars */
.vs { display: grid; gap: 6px; margin: 6px 0 12px; font-size: 0.8rem; }
.vs-row { display: grid; grid-template-columns: 84px minmax(0, 1fr) auto; align-items: center; gap: 10px; }
.vs-row span { color: var(--ink-2); white-space: nowrap; }
.vs-row i { display: block; height: 10px; width: max(6px, calc(var(--w) * 100%)); border-radius: 999px; background: color-mix(in srgb, var(--ink-2) 28%, transparent); transform-origin: left center; }
.vs-row b { font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.vs-row.is-us i { background: var(--cell); }
.vs-row.is-us b { color: var(--ink); font-weight: 750; }

/* The distance gauge */
.gauge-track { stroke: color-mix(in srgb, var(--cell) 18%, transparent) !important; stroke-width: 16 !important; }
.gauge-fill { stroke: var(--cell) !important; stroke-width: 16 !important; stroke-dasharray: 98 100; }
.gauge-num { fill: var(--ink) !important; stroke: none !important; font: 750 34px var(--font); text-anchor: middle; }

/* Charts drawn by cells.js; empty (no JS) means hidden */
svg.chart:empty { display: none; }
.chart .mnode { fill: var(--cell); stroke: none; }
.chart .medge { stroke: color-mix(in srgb, var(--cell) 55%, transparent); stroke-width: 1.4; }
.chart .clock { stroke: var(--ink-2); }
.chart .big { fill: var(--ink); stroke: none; font: 750 26px var(--font); text-anchor: middle; }
.chart .box { stroke: var(--ink); fill: var(--paper); }
.chart .busybox { stroke: var(--cell); fill: color-mix(in srgb, var(--cell) 14%, var(--paper)); }
.chart .chat { fill: var(--cell); stroke: none; transform: translate(var(--tx), var(--ty)); }

/* Motion. Draw-on and bar growth need cells.js (html.cells-anim); none of it runs under reduced motion. */
.cells-anim .ill .draw { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.5s cubic-bezier(.45,.1,.2,1) var(--dd, 0s); }
.cells-anim .cell.in .ill .draw { stroke-dashoffset: 0; }
.cells-anim .ill .s { fill-opacity: 0; transition: fill-opacity .8s ease .9s; }
.cells-anim .ill .k, .cells-anim .ill .t { opacity: 0; transition: opacity .6s ease 1s; }
.cells-anim .cell.in .ill .s { fill-opacity: 1; }
.cells-anim .cell.in .ill .k, .cells-anim .cell.in .ill .t { opacity: 1; }
.cells-anim .vs i { transform: scaleX(0); transition: transform 1s cubic-bezier(.2,.7,.2,1) .3s; }
.cells-anim .vs-row + .vs-row i { transition-delay: .5s; }
.cells-anim .cell.in .vs i { transform: none; }
.cells-anim .gauge-fill { stroke-dashoffset: 98; transition: stroke-dashoffset 1.8s cubic-bezier(.2,.7,.2,1) .3s; }
.cells-anim .cell.in .gauge-fill { stroke-dashoffset: 0; }
.ill [class*="m-"], .ill .hop, .ill .leaver { transform-box: fill-box; transform-origin: center; }
@media (prefers-reduced-motion: no-preference) {
  .cell.in .ill .flow { animation: c-flow 1.1s linear infinite; }
  .cell.in .m-pulse { animation: v-pulse 2.2s ease-in-out infinite; }
  .cell.in .m-blink { animation: c-blink 1.6s ease-in-out infinite; }
  .cell.in .m-wave { animation: c-blink 1.5s ease-in-out infinite; }
  .cell.in .w2 { animation-delay: .25s; } .cell.in .w3 { animation-delay: .5s; }
  .cell.in .m-bob { animation: v-bob 2.8s ease-in-out infinite; }
  .cell.in .m-float { animation: c-float 3.6s ease-in-out infinite; }
  .cell.in .m-slide { animation: c-slide 2.4s ease-in-out infinite; }
  .cell.in .m-plug { animation: c-plug 3.4s ease-in-out infinite; }
  .cell.in .m-gather { animation: c-gather 5s cubic-bezier(.3,.6,.2,1) infinite; }
  .cell.in .m-spin { transform-box: view-box; transform-origin: 34px 30px; animation: v-spin 5s linear infinite; }
  .cell.in .m-swing { transform-box: view-box; transform-origin: 60px 54px; animation: c-swing 3.2s ease-in-out infinite; }
  .cell.in .m-turn { animation: c-turn 4s ease-in-out infinite; }
  .cell.in .trace { animation: c-trace 4.4s ease-in-out infinite; }
  .cell.in .heal .leaver { animation: c-leave 6s ease-in-out infinite; }
  .cell.in .heal .hop { animation: c-hopheal 6s ease-in-out infinite; }
  .cell.in .chart .chat { animation: c-hop 6.4s cubic-bezier(.35,.1,.25,1) infinite; animation-delay: var(--del); }
}
.heal .hop { opacity: 0; }
.heal .h1 { --tx: 50px; --ty: -29px; } .heal .h2 { --tx: 0px; --ty: 40px; } .heal .h3 { --tx: 100px; --ty: 0px; }
@keyframes c-flow { to { stroke-dashoffset: -18; } }
@keyframes c-blink { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
@keyframes c-float { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-7px) rotate(-4deg); } }
@keyframes c-slide { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(6px); } }
@keyframes c-plug { 0%, 15% { transform: translateX(-12px); } 45%, 85% { transform: translateX(0); } 100% { transform: translateX(-12px); } }
@keyframes c-gather { 0% { transform: translate(var(--x), var(--y)); opacity: 0; } 15% { opacity: 1; } 45%, 88% { transform: none; opacity: 1; } 100% { transform: none; opacity: 0; } }
@keyframes c-swing { 0%, 100% { transform: rotate(-62deg); } 50% { transform: rotate(18deg); } }
@keyframes c-turn { 0%, 100% { transform: scaleX(1); } 50% { transform: scaleX(.12); } }
@keyframes c-trace { 0% { stroke-dashoffset: 1; } 45%, 75% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: -1; } }
@keyframes c-leave { 0%, 18% { opacity: 1; } 28%, 72% { opacity: .12; } 85%, 100% { opacity: 1; } }
@keyframes c-hopheal { 0%, 18% { transform: none; opacity: 0; } 24% { opacity: 1; transform: none; } 55% { transform: translate(var(--tx), var(--ty)); opacity: 1; } 70%, 100% { transform: translate(var(--tx), var(--ty)); opacity: 0; } }
@keyframes c-hop {
  0% { transform: translate(var(--sx), var(--sy)); opacity: 0; }
  8% { opacity: 1; }
  32%, 44% { transform: translate(var(--mx), var(--my)); }
  72%, 92% { transform: translate(var(--tx), var(--ty)); opacity: 1; }
  100% { transform: translate(var(--tx), var(--ty)); opacity: 0; }
}
