/* Kudzu landing page. No build step; tokens on :root, dark + light themes. */

:root {
  --bg: #f7faf6;
  --bg-2: #eff5ee;
  --surface: #ffffff;
  --surface-2: #f3f7f2;
  --surface-3: #e7efe6;
  --border: #dde7db;
  --border-strong: #c5d4c2;
  --text: #0b1a11;
  --text-2: #3b4d42;
  --text-3: #55685c;
  --accent: #12733a;          /* text-safe green */
  --accent-fill: #16a34a;     /* marks */
  --accent-soft: rgba(22, 163, 74, .12);
  --accent-line: rgba(22, 163, 74, .38);
  --btn-bg: #15803d;
  --btn-ink: #ffffff;
  --btn-bg-hover: #166534;
  --blossom: #7c3aed;
  --blossom-fill: #8b5cf6;
  --blossom-soft: rgba(124, 58, 237, .12);
  --blossom-badge: #7c3aed;
  --blossom-ink: #ffffff;
  --neutral-ink: #0b1a11;
  --danger: #c2410c;
  --danger-soft: rgba(194, 65, 12, .12);
  --neutral-fill: #8a9a90;
  --vine: #3d8f58;
  --vine-2: #59ad73;
  --leaf: #4ea86a;
  --leaf-2: #78c08f;
  --grid-line: rgba(11, 26, 17, .06);
  --glow: rgba(34, 197, 94, .18);
  --shadow: 0 1px 2px rgba(11, 26, 17, .05), 0 8px 24px -12px rgba(11, 26, 17, .12);
  --shadow-lg: 0 2px 4px rgba(11, 26, 17, .04), 0 24px 60px -24px rgba(11, 26, 17, .25);
  --code-bg: #0c1611;
  --code-border: #1d2b23;
  --code-text: #dfeae2;
  --code-dim: #7d9285;
  --code-green: #6ee79a;
  --code-purple: #c4a5ff;
  --code-amber: #f4c27a;
  --focus: #12733a;

  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --font-serif: "Instrument Serif", ui-serif, Georgia, serif;
  --radius: 14px;
  --radius-lg: 20px;
  --gutter: 24px;
  --maxw: 1180px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #07100b;
    --bg-2: #09140d;
    --surface: #0d1711;
    --surface-2: #111e16;
    --surface-3: #18281e;
    --border: #1b2a21;
    --border-strong: #2a3e31;
    --text: #e9f2ec;
    --text-2: #a8b9ad;
    --text-3: #8a9c90;
    --accent: #4ade80;
    --accent-fill: #4ade80;
    --accent-soft: rgba(74, 222, 128, .1);
    --accent-line: rgba(74, 222, 128, .35);
    --btn-bg: #4ade80;
    --btn-ink: #03210e;
    --btn-bg-hover: #6ee79a;
    --blossom: #c4a5ff;
    --blossom-fill: #a78bfa;
    --blossom-soft: rgba(167, 139, 250, .14);
    --blossom-badge: #c4a5ff;
    --blossom-ink: #1b0b3f;
    --neutral-ink: #ffffff;
    --danger: #ff9b7a;
    --danger-soft: rgba(255, 155, 122, .12);
    --neutral-fill: #5f7366;
    --vine: #1d6b3c;
    --vine-2: #2b8a4f;
    --leaf: #227a45;
    --leaf-2: #35a35f;
    --grid-line: rgba(233, 242, 236, .045);
    --glow: rgba(74, 222, 128, .16);
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .5);
    --shadow-lg: 0 2px 4px rgba(0, 0, 0, .25), 0 30px 80px -30px rgba(0, 0, 0, .7);
    --code-bg: #08110c;
    --code-border: #1b2a21;
    --focus: #4ade80;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #07100b;
  --bg-2: #09140d;
  --surface: #0d1711;
  --surface-2: #111e16;
  --surface-3: #18281e;
  --border: #1b2a21;
  --border-strong: #2a3e31;
  --text: #e9f2ec;
  --text-2: #a8b9ad;
  --text-3: #8a9c90;
  --accent: #4ade80;
  --accent-fill: #4ade80;
  --accent-soft: rgba(74, 222, 128, .1);
  --accent-line: rgba(74, 222, 128, .35);
  --btn-bg: #4ade80;
  --btn-ink: #03210e;
  --btn-bg-hover: #6ee79a;
  --blossom: #c4a5ff;
  --blossom-fill: #a78bfa;
  --blossom-soft: rgba(167, 139, 250, .14);
  --blossom-badge: #c4a5ff;
  --blossom-ink: #1b0b3f;
  --neutral-ink: #ffffff;
  --danger: #ff9b7a;
  --danger-soft: rgba(255, 155, 122, .12);
  --neutral-fill: #5f7366;
  --vine: #1d6b3c;
  --vine-2: #2b8a4f;
  --leaf: #227a45;
  --leaf-2: #35a35f;
  --grid-line: rgba(233, 242, 236, .045);
  --glow: rgba(74, 222, 128, .16);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -12px rgba(0, 0, 0, .5);
  --shadow-lg: 0 2px 4px rgba(0, 0, 0, .25), 0 30px 80px -30px rgba(0, 0, 0, .7);
  --code-bg: #08110c;
  --code-border: #1b2a21;
  --focus: #4ade80;
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
@supports (overflow-x: clip) { body { overflow-x: clip; } }
img, svg, video { display: block; max-width: 100%; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
code, pre { font-family: var(--font-mono); }
:not(pre) > code {
  font-size: .86em;
  padding: .12em .38em;
  border-radius: 6px;
  background: var(--surface-3);
  color: var(--text);
  white-space: nowrap;
}
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -.02em; line-height: 1.15; }
p { margin: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--accent-soft); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--btn-bg); color: var(--btn-ink); padding: 10px 14px; border-radius: 10px; font-weight: 600; text-decoration: none; }
.skip-link:focus { top: 12px; }
.muted { color: var(--text-3); }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
@media (max-width: 640px) { :root { --gutter: 16px; } }
.i { width: 16px; height: 16px; flex: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 18px;
  border-radius: 12px; border: 1px solid transparent;
  font-size: 15px; font-weight: 550; letter-spacing: -.005em;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s, transform .15s, box-shadow .15s;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-sm { height: 34px; padding: 0 12px; font-size: 13.5px; border-radius: 10px; gap: 6px; }
.btn-primary { background: var(--btn-bg); color: var(--btn-ink); box-shadow: 0 0 0 1px rgba(0,0,0,.04), 0 8px 24px -10px var(--accent-line); }
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover { border-color: var(--accent-line); background: var(--surface-2); }
.btn-ghost { background: transparent; color: var(--text-2); border-color: transparent; }
.btn-ghost:hover { color: var(--text); background: var(--surface-3); }
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px;
  border-radius: 10px; border: 1px solid var(--border); background: transparent; color: var(--text-2); cursor: pointer;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-strong); }
.icon-btn svg { width: 16px; height: 16px; }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: saturate(1.6) blur(14px);
  -webkit-backdrop-filter: saturate(1.6) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); height: 64px; display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--text); text-decoration: none; font-weight: 650; font-size: 19px; letter-spacing: -.04em; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 26px; height: 26px; color: var(--accent-fill); }
.nav-links { display: flex; gap: 4px; margin-left: 12px; }
.nav-links a { color: var(--text-2); text-decoration: none; font-size: 14px; padding: 6px 10px; border-radius: 8px; }
.nav-links a:hover { color: var(--text); background: var(--surface-3); }
.nav-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
#theme-toggle .i-sun { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) #theme-toggle .i-sun { display: block; } :root:not([data-theme="light"]) #theme-toggle .i-moon { display: none; } }
:root[data-theme="dark"] #theme-toggle .i-sun { display: block; }
:root[data-theme="dark"] #theme-toggle .i-moon { display: none; }
@media (max-width: 860px) { .nav-links { display: none; } }

/* ---------- hero ---------- */
.hero { position: relative; padding: 96px 0 72px; overflow: hidden; isolation: isolate; }
.hero-bg {
  position: absolute; inset: -64px 0 0; z-index: -2;
  background:
    radial-gradient(60% 50% at 50% 0%, var(--glow), transparent 70%),
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 56px 56px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 56px 56px;
  -webkit-mask-image: radial-gradient(80% 70% at 50% 20%, #000 40%, transparent 100%);
  mask-image: radial-gradient(80% 70% at 50% 20%, #000 40%, transparent 100%);
}
.vine { position: absolute; z-index: -1; pointer-events: none; overflow: visible; }
.vine-left { left: -40px; top: 430px; width: 420px; height: 760px; }
.vine-right { right: -50px; top: -10px; width: 420px; height: 640px; }
.vine-stem { fill: none; stroke: var(--vine); stroke-width: 5; stroke-linecap: round; }
.vine-stem.thin { stroke-width: 3; stroke: var(--vine-2); }
.vine .tendril { fill: none; stroke: var(--vine-2); stroke-width: 1.6; stroke-linecap: round; }
.vine .leaf { color: var(--leaf); }
.vine .leaf.alt { color: var(--leaf-2); }
.vine .node { fill: var(--accent-fill); }
.vine .node-ring { fill: none; stroke: var(--accent-fill); stroke-width: 1.5; opacity: .5; }
.vine .bloom { fill: var(--blossom-fill); }
html.js .vine.grow .vine-stem { stroke-dasharray: var(--len) var(--len); stroke-dashoffset: var(--len); animation: vine-grow var(--dur, 3.2s) cubic-bezier(.45, .05, .3, 1) var(--delay, 0s) forwards; }
html.js .vine.grow .pop { transform-box: fill-box; transform-origin: var(--ox, 50%) var(--oy, 100%); transform: scale(0); animation: pop .7s cubic-bezier(.2, 1.4, .4, 1) var(--delay, 0s) forwards; }
html.js .vine.grow .tendril { stroke-dasharray: 80; stroke-dashoffset: 80; animation: vine-grow 1.2s ease-out var(--delay, 0s) forwards; }
@keyframes vine-grow { to { stroke-dashoffset: 0; } }
@keyframes pop { to { transform: scale(var(--s, 1)); } }
@media (max-width: 1100px) { .vine { opacity: .55; } .vine-left { left: -150px; } .vine-right { right: -190px; } }
@media (max-width: 640px) { .vine { opacity: .4; } .vine-left { left: -230px; top: 520px; } .vine-right { right: -250px; top: -20px; } }

.hero-inner { text-align: center; display: flex; flex-direction: column; align-items: center; }
.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 12px 6px 10px; border-radius: 999px;
  border: 1px solid var(--border-strong); background: color-mix(in srgb, var(--surface) 80%, transparent);
  color: var(--text-2); font-size: 13.5px; text-decoration: none; margin-bottom: 28px;
}
.pill:hover { color: var(--text); border-color: var(--accent-line); text-decoration: none; }
.pill-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent-fill); box-shadow: 0 0 0 4px var(--accent-soft); }
.pill .i { width: 14px; height: 14px; opacity: .7; }
h1 {
  font-size: clamp(2.5rem, 1.1rem + 5.4vw, 5.4rem);
  line-height: 1.02; letter-spacing: -.045em; font-weight: 640;
  max-width: 15ch; text-wrap: balance;
}
h1 em {
  font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -.01em;
  color: var(--accent); padding-right: .04em;
}
.h1-sub { display: block; color: var(--text-3); margin-top: .1em; font-size: .62em; letter-spacing: -.035em; line-height: 1.1; max-width: none; }
.hero-lead { margin-top: 28px; max-width: 640px; font-size: clamp(1.05rem, .95rem + .4vw, 1.25rem); line-height: 1.55; color: var(--text-2); text-wrap: pretty; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 36px; }
.hero-note { margin-top: 22px; font-size: 13.5px; color: var(--text-3); max-width: 600px; text-wrap: balance; }
.hero-note a { color: var(--text-2); }
.h1-pre { display: block; color: var(--text-3); font-size: .5em; letter-spacing: -.035em; line-height: 1.1; margin-bottom: .18em; }
.hero-kicker {
  margin-top: 22px; font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  letter-spacing: .14em; text-transform: uppercase; color: var(--accent);
}
.hero-kicker::before, .hero-kicker::after { content: ""; display: inline-block; width: 22px; height: 1px; background: var(--accent-line); vertical-align: middle; margin: 0 12px; }

.breaks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 56px; }
.break { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px 24px 22px; }
.break h3 { display: flex; align-items: center; gap: 10px; font-size: 1.2rem; letter-spacing: -.025em; margin-bottom: 16px; }
.break-ico { font-size: 1.25rem; line-height: 1; }
.break p { font-size: 14.5px; line-height: 1.55; padding-left: 14px; }
.break p b { display: block; font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 2px; }
.break-git { color: var(--text-2); border-left: 2px solid var(--danger); }
.break-git b { color: var(--danger); }
.break-kz { margin-top: 12px; color: var(--text); border-left: 2px solid var(--accent-fill); }
.break-kz b { color: var(--accent); }
@media (max-width: 760px) { .breaks { grid-template-columns: 1fr; } .break { padding: 20px; } }
@media (max-width: 560px) {
  .hero-kicker { font-size: 11.5px; letter-spacing: .1em; }
  .hero-kicker::before, .hero-kicker::after { display: none; }
  .pill { font-size: 12.5px; gap: 8px; }
}
.final-cta p.final-cta-title { font-size: clamp(1.4rem, 1.1rem + 1.2vw, 2rem); font-weight: 640; letter-spacing: -.035em; color: var(--text); margin-bottom: 8px; }

/* terminal */
.terminal {
  margin: 64px auto 0; max-width: 860px;
  background: var(--code-bg); border: 1px solid var(--code-border); border-radius: 16px;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.02) inset;
  overflow: hidden; text-align: left;
}
.terminal-bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; height: 40px; padding: 0 14px; border-bottom: 1px solid var(--code-border); background: rgba(255,255,255,.02); }
.dots { display: flex; gap: 7px; }
.dots i { width: 11px; height: 11px; border-radius: 50%; background: #2a3a30; }
.dots i:nth-child(1) { background: #3a4a40; }
.terminal-title { font-family: var(--font-mono); font-size: 12px; color: var(--code-dim); }
.terminal-body { margin: 0; padding: 20px 22px 24px; font-size: 13.5px; line-height: 1.75; color: var(--code-text); overflow-x: auto; white-space: normal; }
.terminal-body code { font-size: inherit; }
.t-line { display: block; white-space: pre; }
.t-com { color: var(--code-dim); }
.t-line.t-com:not(:first-child) { margin-top: 10px; }
.t-ps { color: var(--code-green); margin-right: .6ch; user-select: none; }
.t-out { color: #b9c9be; }
.t-ok { color: var(--code-green); }
.t-caret { display: inline-block; width: .6ch; height: 1.15em; vertical-align: -.2em; background: var(--code-green); margin-left: 2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
html.js .terminal.typing .t-line { visibility: hidden; }
html.js .terminal.typing .t-line.shown { visibility: visible; }
@media (max-width: 640px) {
  .hero { padding: 64px 0 56px; }
  .terminal { margin-top: 44px; border-radius: 12px; }
  .terminal-body { font-size: 12px; padding: 16px; }
  .t-line { white-space: pre-wrap; word-break: break-word; }
  .cta .btn { flex: 1 1 auto; }
}

/* ---------- sections ---------- */
.section { padding: 120px 0; position: relative; }
.section + .section { border-top: 1px solid var(--border); }
@media (max-width: 640px) { .section { padding: 76px 0; } }
.section-head { max-width: 760px; margin-bottom: 56px; }
.section-head-center { margin-left: auto; margin-right: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 18px;
}
.eyebrow span { color: var(--text-3); }
.eyebrow span::after { content: ""; display: inline-block; width: 18px; height: 1px; background: var(--border-strong); vertical-align: middle; margin-left: 10px; }
h2 { font-size: clamp(2rem, 1.2rem + 2.9vw, 3.3rem); letter-spacing: -.04em; line-height: 1.06; text-wrap: balance; }
.lead { margin-top: 20px; font-size: clamp(1.02rem, .95rem + .3vw, 1.18rem); color: var(--text-2); line-height: 1.6; text-wrap: pretty; }
h3 { font-size: 1.15rem; letter-spacing: -.02em; }

/* reveal */
html.js [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
html.js [data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { html.js [data-reveal] { opacity: 1; transform: none; transition: none; } }

/* ---------- problem ---------- */
.scale {
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--surface); box-shadow: var(--shadow);
  padding: 32px; display: grid; gap: 28px;
}
.scale-head { display: flex; justify-content: space-between; gap: 24px; align-items: baseline; flex-wrap: wrap; }
.scale-head h3 { font-size: 1.05rem; }
.source { font-size: 13px; color: var(--text-3); max-width: 560px; }
.source a { color: var(--text-2); }
.scale-grid { display: grid; grid-template-columns: 1.6fr repeat(2, 1fr); grid-template-rows: auto auto; gap: 12px; }
.tile { border: 1px solid var(--border); background: var(--surface-2); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; min-height: 120px; }
.tile-value { font-size: clamp(1.7rem, 1.3rem + 1.2vw, 2.3rem); font-weight: 600; letter-spacing: -.04em; line-height: 1.1; }
.tile-label { color: var(--text-2); font-size: 14px; }
.tile-feature { grid-row: span 2; justify-content: space-between; gap: 16px; }
.tile-feature .tile-label { font-weight: 550; color: var(--text); }
.tile-foot { font-size: 14px; color: var(--text-2); }
.tile-foot b { color: var(--text); font-weight: 600; }
.merge-bars { display: flex; align-items: flex-end; justify-content: center; gap: 28px; height: 190px; padding-top: 8px; border-bottom: 1px solid var(--border-strong); }
.mbar { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; position: relative; max-width: 150px; }
.mbar-fill { display: block; height: calc(var(--v) * 78%); min-height: 4px; background: var(--neutral-fill); border-radius: 4px 4px 0 0; transform-origin: bottom; }
.mbar-accent .mbar-fill { background: var(--accent-fill); }
.mbar-val { font-weight: 600; font-size: 15px; letter-spacing: -.02em; margin-bottom: 6px; text-align: center; }
.mbar-lab { position: absolute; bottom: -24px; left: 0; right: 0; text-align: center; font-size: 12.5px; color: var(--text-3); }
.tile-feature .merge-bars { margin-bottom: 22px; }
html.js .scale:not(.in) .mbar-fill { transform: scaleY(0); }
.scale .mbar-fill { transition: transform 1.1s cubic-bezier(.2, .8, .2, 1) .2s; }
.scale .mbar-accent .mbar-fill { transition-delay: .45s; }
.after { border-top: 1px dashed var(--border-strong); padding-top: 24px; display: grid; grid-template-columns: auto 1fr; gap: 24px; align-items: center; }
.after-label { font-size: 13px; color: var(--text-3); font-family: var(--font-mono); text-transform: uppercase; letter-spacing: .06em; max-width: 220px; }
.after-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.after-list li { display: flex; flex-direction: column; gap: 2px; padding: 4px 0 4px 16px; border-left: 2px solid var(--accent-line); }
.after-list b { font-size: 1.5rem; letter-spacing: -.03em; font-weight: 600; }
.after-list span { font-size: 14px; color: var(--text-2); }
@media (max-width: 900px) {
  .scale { padding: 22px; }
  .scale-grid { grid-template-columns: 1fr 1fr; }
  .tile-feature { grid-column: span 2; grid-row: auto; }
  .after { grid-template-columns: 1fr; gap: 14px; }
}
@media (max-width: 560px) {
  .scale { padding: 16px; border-radius: 16px; }
  .tile { padding: 16px; min-height: 96px; }
  .after-list { grid-template-columns: 1fr; }
}

.principles { margin-top: 80px; }
.principles-title { font-size: 1.4rem; letter-spacing: -.03em; margin-bottom: 22px; }
.principles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.pcard { background: var(--surface); padding: 26px 26px 28px; position: relative; }
.pcard-n { font-family: var(--font-mono); font-size: 12px; color: var(--accent); display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: var(--accent-soft); margin-bottom: 16px; }
.pcard h4 { font-size: 1.05rem; letter-spacing: -.02em; margin-bottom: 8px; }
.pcard p { color: var(--text-2); font-size: 14.5px; line-height: 1.55; }
.pcard code { white-space: nowrap; }
@media (max-width: 900px) { .principles-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .principles-grid { grid-template-columns: 1fr; } .pcard { padding: 20px; } }

/* ---------- flow ---------- */
.section-flow { background: var(--bg-2); }
.flow { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.flow-main { min-width: 0; }
.flow-stage {
  position: relative; display: flex; flex-direction: column; gap: 64px;
  padding: 30px 24px 28px; border-radius: var(--radius-lg);
  border: 1px solid var(--border); background: var(--surface);
  box-shadow: var(--shadow);
  background-image:
    radial-gradient(circle at 1px 1px, var(--grid-line) 1px, transparent 0);
  background-size: 18px 18px;
}
.flow-wires, .flow-packets { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.flow-wires { z-index: 0; }
.flow-packets { z-index: 3; }
.wire { fill: none; stroke: var(--border-strong); stroke-width: 1.5; }
.wire.active { stroke: var(--accent-line); }
.tier {
  position: relative; z-index: 1;
  width: 100%; max-width: 440px; margin: 0 auto;
  background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 12px;
  padding: 11px 13px 11px;
  transition: border-color .25s, box-shadow .25s, background-color .25s;
}
.tier-head { display: flex; align-items: center; gap: 8px; justify-content: space-between; }
.tier-name { font-family: var(--font-mono); font-size: 13px; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; }
.tier-tag { font-size: 11.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tier-sub { font-size: 12px; color: var(--text-3); margin-top: 2px; }
.tier-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 9px; }
.tier-stat { font-family: var(--font-mono); font-size: 11.5px; color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.tier-stat b { color: var(--text); font-weight: 600; }
.tier-stat b.bump { color: var(--accent); }
.slots { display: flex; flex-wrap: wrap; gap: 3px; min-width: 0; }
.slot { width: 10px; height: 10px; border: 1px dashed var(--border-strong); border-radius: 2px; transition: background-color .3s, border-color .3s, transform .3s; }
.slot.blob { border-radius: 50%; }
.slot.full { background: var(--accent-fill); border: 1px solid var(--accent-fill); }
.slot.full.blob { background: var(--leaf-2); border-color: var(--leaf-2); }
.slot.full.new { background: var(--blossom-fill); border-color: var(--blossom-fill); }
.slot.skip { border: 1px dotted var(--text-3); opacity: .55; }
.slot.full.skip { background: transparent; border: 1px solid var(--neutral-fill); opacity: .8; }
.slot.flash { transform: scale(1.5); }
.tier-daemon .slots { gap: 2px; }
.tier-daemon .slot { width: 8px; height: 8px; }
.tier.hit { border-color: var(--accent-fill); box-shadow: 0 0 0 3px var(--accent-soft); }
.tier.miss { border-color: var(--border-strong); }
.tier.coalesce { border-color: var(--blossom-fill); box-shadow: 0 0 0 3px var(--blossom-soft); }
.tier-server { max-width: 480px; }
.badge {
  position: absolute; top: -10px; right: 10px; z-index: 2;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600; letter-spacing: .04em;
  padding: 2px 7px; border-radius: 999px; border: 1px solid transparent;
  opacity: 0; transform: translateY(4px) scale(.9); transition: opacity .2s, transform .2s;
  white-space: nowrap; pointer-events: none;
}
.badge.show { opacity: 1; transform: none; }
.badge.b-hit { background: var(--btn-bg); color: var(--btn-ink); }
.badge.b-miss { background: var(--surface); color: var(--text-2); border-color: var(--border-strong); }
.badge.b-co, .badge.b-new { background: var(--blossom-badge); color: var(--blossom-ink); }
.flow-nodes { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.flow-node { display: flex; flex-direction: column; gap: 60px; min-width: 0; }
.tier-daemon { max-width: none; }
.agents { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; position: relative; z-index: 1; }
.agent {
  display: flex; flex-direction: column; align-items: center; gap: 0;
  padding: 7px 2px 6px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface);
  transition: border-color .25s, box-shadow .25s;
}
.agent b { font-family: var(--font-mono); font-size: 12.5px; font-weight: 600; }
.agent span { font-size: 10.5px; color: var(--text-3); line-height: 1.3; }
.agent.active { border-color: var(--accent-fill); box-shadow: 0 0 0 3px var(--accent-soft); }
.agent.done b::after { content: " ✓"; color: var(--accent); }
.pk-want { fill: var(--surface); stroke: var(--text-2); stroke-width: 1.6; }
.pk-tree { fill: var(--accent-fill); }
.pk-blob { fill: var(--leaf-2); }
.pk-new { fill: var(--blossom-fill); }
.pk-glow { opacity: .35; }
.flow-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 14px; font-size: 12.5px; color: var(--text-3); }
.flow-legend span { display: inline-flex; align-items: center; gap: 6px; }
.lg { display: inline-block; width: 10px; height: 10px; }
.lg-want { border-radius: 50%; border: 1.6px solid var(--text-2); }
.lg-tree { background: var(--accent-fill); border-radius: 2px; }
.lg-blob { background: var(--leaf-2); border-radius: 50%; }
.lg-new { background: var(--blossom-fill); border-radius: 50%; }
.lg-skip { border: 1px dotted var(--text-3); border-radius: 2px; }
.flow-caption { display: none; }

.flow-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.flow-controls { display: flex; gap: 8px; }
#flow-toggle .i-play { display: none; }
#flow-toggle[aria-pressed="true"] .i-play { display: block; }
#flow-toggle[aria-pressed="true"] .i-pause { display: none; }
.flow-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.flow-steps li { border-radius: 12px; border: 1px solid transparent; transition: background-color .25s, border-color .25s; }
.flow-steps button {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  background: none; border: 0; padding: 8px 10px; cursor: pointer; border-radius: 12px;
  font-size: 14.5px; font-weight: 550; color: var(--text-2);
}
.flow-steps button:hover { color: var(--text); }
.fs-n { flex: none; display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--border-strong); font-family: var(--font-mono); font-size: 11px; color: var(--text-3); transition: all .25s; }
.flow-steps p { display: none; padding: 0 12px 12px 42px; font-size: 14px; line-height: 1.55; color: var(--text-2); }
.flow-steps li.done .fs-n { background: var(--accent-soft); border-color: var(--accent-line); color: var(--accent); }
.flow-steps li.active { background: var(--surface); border-color: var(--border-strong); box-shadow: var(--shadow); }
.flow-steps li.active button { color: var(--text); }
.flow-steps li.active .fs-n { background: var(--btn-bg); border-color: var(--btn-bg); color: var(--btn-ink); }
.flow-steps li.active p { display: block; }
.flow.static .flow-steps p { display: block; }
.flow.static .flow-controls { display: none; }

.wc { border: 1px solid var(--border); border-radius: var(--radius); background: var(--code-bg); color: var(--code-text); overflow: hidden; }
.wc-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid var(--code-border); font-size: 12px; color: var(--code-dim); }
.wc-head code { background: none !important; color: var(--code-green) !important; padding: 0 !important; font-size: 11.5px !important; }
.wc-tree { list-style: none; margin: 0; padding: 8px 0 10px; font-family: var(--font-mono); font-size: 12.5px; line-height: 1.85; }
.wc-tree li { display: flex; justify-content: space-between; gap: 10px; padding: 0 12px 0 calc(12px + var(--d) * 16px); color: #6f8577; transition: color .3s, background-color .3s; }
.wc-tree li .wc-st { font-size: 11px; color: #6f8577; white-space: nowrap; }
.wc-tree li.want { color: var(--code-text); background: rgba(255,255,255,.035); }
.wc-tree li.want .wc-st::before { content: "wanted…"; color: var(--code-amber); }
.wc-tree li.got { color: var(--code-text); }
.wc-tree li.got .wc-st::before { content: "✓ fetched"; color: var(--code-green); }
.wc-tree li.skip .wc-name { text-decoration: line-through; text-decoration-color: rgba(255,255,255,.3); color: #7a8f82; }
.wc-tree li.skip .wc-st::before { content: "never requested"; color: #7f9488; }

@media (max-width: 980px) {
  .flow { grid-template-columns: 1fr; }
  .flow-side { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
  .flow-controls { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .flow-side { display: flex; }
  .flow-stage { padding: 18px 10px 16px; gap: 36px; border-radius: 16px; }
  .flow-node { gap: 32px; }
  .flow-nodes { gap: 8px; }
  .tier { padding: 8px 9px; }
  .tier-sub { display: none; }
  .tier-name { font-size: 11.5px; }
  .tier-tag { font-size: 10.5px; }
  .tier-daemon .tier-name { font-size: 0; }
  .tier-daemon .tier-name::before { content: "daemon"; font-size: 11.5px; }
  .tier-foot { flex-direction: column; align-items: flex-start; gap: 5px; }
  .slot { width: 7px; height: 7px; }
  .agents { gap: 4px; }
  .agent span { display: none; }
  .agent { padding: 6px 0; }
  .agent b { font-size: 11.5px; }
  .agent.done b::after { content: ""; }
  .flow-caption { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; min-height: 44px; font-weight: 550; font-size: 15px; }
  .flow-caption-n { flex: none; display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--btn-bg); color: var(--btn-ink); font-family: var(--font-mono); font-size: 12px; margin-top: 1px; }
  .flow-steps li:not(.active) { display: none; }
  .flow.static .flow-steps li { display: block; }
  .flow-steps li.active { background: transparent; border-color: transparent; box-shadow: none; }
  .flow-steps li.active button { display: none; }
  .flow-steps li.active p { padding: 0; }
  .flow-legend { font-size: 11.5px; gap: 6px 12px; }
}

/* ---------- vs git ---------- */
.vs-table-wrap { border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); box-shadow: var(--shadow); }
.vs-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.vs-table th, .vs-table td { text-align: left; vertical-align: top; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.vs-table tbody tr:last-child > * { border-bottom: 0; }
.vs-table thead th { font-family: var(--font-mono); font-size: 12.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); font-weight: 500; padding-top: 14px; padding-bottom: 14px; background: var(--surface-2); }
.vs-table thead .col-kudzu { color: var(--accent); }
.vs-table thead .col-kudzu .i { display: inline-block; width: 14px; height: 16px; vertical-align: -3px; margin-right: 6px; color: var(--accent-fill); }
.vs-table tbody th { width: 20%; font-weight: 600; font-size: 15px; color: var(--text); }
.vs-table td { color: var(--text-2); width: 40%; line-height: 1.55; }
.vs-table td:last-child { color: var(--text); background: linear-gradient(90deg, var(--accent-soft), transparent 70%); border-left: 1px solid var(--accent-line); }
@media (max-width: 760px) {
  .vs-table thead { display: none; }
  .vs-table, .vs-table tbody, .vs-table tr, .vs-table th, .vs-table td { display: block; width: auto; }
  .vs-table tr { border-bottom: 1px solid var(--border); padding: 16px 16px 18px; }
  .vs-table tbody tr:last-child { border-bottom: 0; }
  .vs-table th, .vs-table td { padding: 0; border: 0; }
  .vs-table tbody th { margin-bottom: 10px; font-size: 16px; width: auto; }
  .vs-table td { padding: 10px 12px 10px 12px; border-radius: 10px; font-size: 14.5px; width: auto; }
  .vs-table td::before { content: attr(data-label); display: block; font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); margin-bottom: 4px; }
  .vs-table td:first-of-type { background: var(--surface-2); margin-bottom: 8px; }
  .vs-table td:last-child { border-left: 0; background: var(--accent-soft); box-shadow: inset 2px 0 0 var(--accent-fill); }
  .vs-table td:last-child::before { color: var(--accent); }
}

.vs-demos { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 28px; }
.demo-card { margin: 0; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow); padding: 24px; }
.demo-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 18px; }
.demo-card-head h3 { font-size: 1.1rem; }
.demo-card-head p { font-size: 14px; color: var(--text-3); margin-top: 4px; }
.demo-panes { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pane { border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; background: var(--surface-2); min-width: 0; display: flex; flex-direction: column; }
.pane-kudzu { border-color: var(--accent-line); background: linear-gradient(180deg, var(--accent-soft), transparent 60%), var(--surface-2); }
.pane-cmd { font-size: 13px; font-weight: 600; margin-bottom: 12px; color: var(--text); }
.pane-cmd code { font-size: 12.5px !important; }
.pane-note { font-size: 13px; color: var(--text-2); margin-top: 10px; }
.demo-foot { font-size: 13.5px; color: var(--text-3); margin-top: 16px; }
@media (max-width: 760px) { .demo-panes { grid-template-columns: 1fr; } .demo-card { padding: 16px; } }
@media (max-width: 560px) { .land-svg .land-label { font-size: 13px; } .land-svg .cs text { font-size: 11px; } .land-svg .mover text { font-size: 14px; } .land-svg .ref text { font-size: 11.5px; } }

/* clone grid */
.cgrid { display: grid; grid-template-columns: repeat(24, 1fr); gap: 3px; }
.cell { aspect-ratio: 1; border-radius: 2px; border: 1px dashed var(--border-strong); transition: background-color .25s, border-color .25s, opacity .25s; }
.cell.on { background: var(--neutral-fill); border: 1px solid var(--neutral-fill); }
.pane-kudzu .cell.on { background: var(--accent-fill); border-color: var(--accent-fill); }
.pane-kudzu .cell.on.blob { background: var(--leaf-2); border-color: var(--leaf-2); }
.cbar { height: 6px; border-radius: 99px; background: var(--surface-3); margin-top: 12px; overflow: hidden; }
.cbar-fill { display: block; height: 100%; width: 0; background: var(--neutral-fill); border-radius: inherit; }
.pane-kudzu .cbar-fill { background: var(--accent-fill); }

/* land demo */
.land-svg { width: 100%; max-width: 420px; height: auto; overflow: visible; margin: 0 auto; }
.land-svg .lg-main { stroke: var(--border-strong); stroke-width: 2; }
.land-svg .cs circle { fill: var(--surface); stroke: var(--text-3); stroke-width: 1.5; }
.land-svg .cs text { font-family: var(--font-mono); font-size: 10px; text-anchor: middle; fill: var(--text-2); }
.land-svg .cs.base circle { fill: var(--surface-3); stroke: var(--border-strong); }
.land-svg .mover circle { fill: var(--surface); stroke: var(--blossom-fill); stroke-width: 2; stroke-dasharray: 3 2.5; }
.land-svg .mover text { font-size: 13px; font-weight: 600; fill: var(--text); }
.land-svg .mover.landed circle { fill: var(--btn-bg); stroke: var(--btn-bg); stroke-dasharray: none; }
.land-svg .mover.landed text { fill: var(--btn-ink); }
.land-svg[data-land="queue"] .mover.landed circle { fill: var(--neutral-fill); stroke: var(--neutral-fill); }
.land-svg[data-land="queue"] .mover.landed text { fill: var(--neutral-ink); }
.land-svg .mover.fail circle { stroke: var(--danger); stroke-dasharray: none; }
.land-svg .mover.wait circle { animation: waitpulse 1s ease-in-out infinite; }
@keyframes waitpulse { 50% { opacity: .45; } }
.land-svg .mover, .land-svg .ref { transition: transform .7s cubic-bezier(.3, .7, .2, 1); }
.land-svg .ref rect { fill: var(--surface); stroke: var(--accent-fill); stroke-width: 1.5; }
.land-svg[data-land="queue"] .ref rect { stroke: var(--neutral-fill); }
.land-svg .ref text { font-family: var(--font-mono); font-size: 10.5px; font-weight: 600; text-anchor: middle; fill: var(--text); }
.land-svg .lock rect { fill: var(--surface); stroke: var(--text-3); stroke-width: 1.6; }
.land-svg .lock-shackle { fill: none; stroke: var(--text-3); stroke-width: 1.8; transition: transform .3s; }
.land-svg .lock.held rect { stroke: var(--danger); fill: var(--danger-soft); }
.land-svg .lock.held .lock-shackle { stroke: var(--danger); }
.land-svg .lock.open .lock-shackle { transform: translateY(-4px); }
.land-svg .land-label { font-family: var(--font-mono); font-size: 11px; text-anchor: middle; fill: var(--text-3); opacity: 0; transition: opacity .25s; }
.land-svg .lock-label { text-anchor: start; }
.land-svg .lock-label.held { fill: var(--danger); }
.land-svg .land-label.bad { fill: var(--danger); font-weight: 600; }
.land-svg .land-label.show { opacity: 1; }
.land-svg .edge { fill: none; stroke: var(--border-strong); stroke-width: 1.4; stroke-dasharray: 3 3; }
.land-log { list-style: none; margin: 12px 0 0; padding: 10px 12px; min-height: 118px; border-radius: 10px; background: var(--code-bg); border: 1px solid var(--code-border); font-family: var(--font-mono); font-size: 11.5px; line-height: 1.75; color: var(--code-text); }
.land-log li { display: flex; gap: 8px; animation: logIn .3s ease both; }
.land-log li .who { color: var(--code-purple); width: 1.2em; flex: none; }
.land-log li .ok { color: var(--code-green); }
.land-log li .bad { color: #ff9b7a; }
.land-log li .dim { color: var(--code-dim); }
@keyframes logIn { from { opacity: 0; transform: translateY(3px); } }
@media (prefers-reduced-motion: reduce) { .land-log li { animation: none; } .land-svg .mover.wait circle { animation: none; } }

/* ---------- video ---------- */
.video-frame {
  position: relative; max-width: 1000px; margin: 0 auto; aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg); overflow: hidden;
  border: 1px solid var(--border-strong);
  background:
    radial-gradient(60% 60% at 50% 40%, var(--glow), transparent 70%),
    var(--code-bg);
  box-shadow: var(--shadow-lg), 0 0 0 6px var(--accent-soft);
}
.video-frame video { width: 100%; height: 100%; object-fit: contain; background: transparent; }
.video-fallback {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  padding: 24px; text-align: center; color: #c9d8ce; font-size: 15px;
  background:
    radial-gradient(50% 60% at 50% 35%, rgba(74, 222, 128, .14), transparent 70%),
    linear-gradient(rgba(233, 242, 236, .04) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(90deg, rgba(233, 242, 236, .04) 1px, transparent 1px) 0 0 / 28px 28px,
    #08110c;
}
.video-fallback[hidden] { display: none; }
.video-fallback-leaf { width: 48px; height: 54px; color: #4ade80; margin-bottom: 6px; }
.video-fallback-title { font-size: clamp(1.1rem, 1rem + .6vw, 1.5rem); font-weight: 600; color: #e9f2ec; letter-spacing: -.02em; }
.video-fallback .code { margin-top: 10px; max-width: 100%; text-align: left; }
.video-note { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-3); }
@media (max-width: 560px) { .video-fallback .code pre code { white-space: pre-wrap; word-break: break-word; } .video-frame { aspect-ratio: auto; min-height: 220px; } .video-frame video { height: auto; aspect-ratio: 16 / 9; } .video-fallback { position: relative; min-height: 300px; font-size: 14px; } .video-frame.no-video video { display: none; } }

/* ---------- code blocks ---------- */
.code { position: relative; background: var(--code-bg); border: 1px solid var(--code-border); border-radius: 12px; min-width: 0; }
.code pre { margin: 0; padding: 14px 52px 14px 16px; overflow-x: auto; font-size: 13px; line-height: 1.7; color: var(--code-text); }
.code pre code { font-size: inherit; background: none; padding: 0; color: inherit; white-space: pre; }
.copy-btn {
  position: absolute; top: 8px; right: 8px; width: 32px; height: 32px; display: grid; place-items: center;
  border-radius: 8px; border: 1px solid var(--code-border); background: #0f1c15; color: #9fb3a6; cursor: pointer;
  transition: color .15s, border-color .15s, background-color .15s;
}
.copy-btn:hover { color: #e9f2ec; border-color: #2e4537; }
.copy-btn svg { width: 15px; height: 15px; }
.copy-btn .i-check { display: none; }
.copy-btn.copied { color: var(--code-green); border-color: rgba(74, 222, 128, .4); }
.copy-btn.copied .i-copy { display: none; }
.copy-btn.copied .i-check { display: block; }
.code-inline pre { padding-right: 48px; font-size: 12.5px; }
.c-k { color: #9ed8b1; } .c-s { color: var(--code-amber); } .c-n { color: var(--code-purple); } .c-p { color: var(--code-dim); }

/* ---------- under the hood ---------- */
.hood { display: grid; grid-template-columns: minmax(0, 1.05fr) 120px minmax(0, 1fr); gap: 0; align-items: center; }
.hood-log { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.hood-label { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); }
.log-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.log-list li {
  display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center;
  padding: 9px 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface);
  font-size: 13.5px;
}
.log-list li.fresh { animation: logAppend .6s cubic-bezier(.2, .8, .2, 1) both; border-color: var(--accent-line); }
@keyframes logAppend { from { opacity: 0; transform: translateY(10px); } }
.log-seq { font-family: var(--font-mono); font-size: 12px; color: var(--accent); background: var(--accent-soft); padding: 1px 7px; border-radius: 6px; font-variant-numeric: tabular-nums; }
.log-msg { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.log-files { font-size: 12px; color: var(--text-3); white-space: nowrap; }
.code-json pre { font-size: 12.5px; padding-right: 16px; }
.hood-note { font-size: 14px; color: var(--text-2); }
.hood-engine { display: flex; flex-direction: column; align-items: center; gap: 0; height: 100%; justify-content: center; position: relative; }
.engine-wire { width: 2px; flex: 1; background: linear-gradient(var(--accent-line), var(--accent-line)) center / 2px 100% no-repeat; min-height: 30px; position: relative; overflow: hidden; }
.engine-wire::after { content: ""; position: absolute; left: -2px; width: 6px; height: 18px; border-radius: 4px; background: var(--accent-fill); top: -20px; animation: wirePulse 2.4s linear infinite; }
@keyframes wirePulse { to { top: 110%; } }
.engine-core {
  writing-mode: vertical-rl; transform: rotate(180deg);
  display: flex; align-items: center; gap: 10px;
  padding: 16px 10px; border-radius: 12px; background: var(--surface); border: 1px solid var(--accent-line);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.engine-title { font-family: var(--font-mono); font-size: 12px; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: .08em; }
.engine-core code { font-size: 11.5px !important; white-space: nowrap; background: none !important; padding: 0 !important; color: var(--text-2) !important; }
.hood-derived { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.dd { border: 1px solid var(--border); border-radius: 12px; background: var(--surface); padding: 14px 16px; transition: border-color .3s, box-shadow .3s; }
.dd-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 4px; }
.dd-top b { font-family: var(--font-mono); font-size: 13.5px; font-weight: 600; }
.dd-tag { font-family: var(--font-mono); font-size: 11px; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.dd.eager .dd-tag { background: var(--accent-soft); color: var(--accent); }
.dd.lazy .dd-tag { background: var(--blossom-soft); color: var(--blossom); }
.dd p { font-size: 13.5px; color: var(--text-2); line-height: 1.5; }
.dd.tick { border-color: var(--accent-fill); box-shadow: 0 0 0 3px var(--accent-soft); }
.hood-foot { margin-top: 36px; font-size: 14.5px; color: var(--text-2); max-width: 820px; }
@media (max-width: 900px) {
  .hood { grid-template-columns: 1fr; }
  .hood-engine { flex-direction: column; height: auto; padding: 8px 0; }
  .engine-wire { width: 2px; flex: none; height: 28px; }
  .engine-core { writing-mode: horizontal-tb; transform: none; flex-direction: column; gap: 4px; padding: 12px 16px; text-align: center; }
  .engine-core code { white-space: normal; }
}
@media (prefers-reduced-motion: reduce) { .engine-wire::after { display: none; } .log-list li.fresh { animation: none; } }

/* ---------- numbers ---------- */
.caveat { margin-top: 16px; display: inline-block; font-size: 13.5px; color: var(--text-2); padding: 8px 12px; border-radius: 10px; background: var(--surface-3); border: 1px solid var(--border); }
.caveat b { color: var(--text); font-weight: 600; }
.numbers { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 16px; }
.chart-card, .tradeoff { margin: 0; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow); padding: 26px; }
.chart-card figcaption h3, .tradeoff h3 { font-size: 1.1rem; }
.chart-card figcaption p { font-size: 13.5px; color: var(--text-3); margin-top: 2px; }
.hbars { display: flex; flex-direction: column; gap: 18px; margin-top: 24px; }
.hbar { display: grid; grid-template-columns: minmax(170px, 34%) 1fr; gap: 16px; align-items: center; border-radius: 8px; outline-offset: 4px; }
.hbar-label { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.hbar-label code { font-size: 12.5px !important; align-self: flex-start; white-space: nowrap; }
.hbar-label span { font-size: 12.5px; color: var(--text-3); }
.hbar-track { position: relative; display: flex; align-items: center; gap: 10px; height: 24px; border-left: 1px solid var(--border-strong); }
.hbar-fill { display: block; height: 20px; width: calc(var(--v) * (100% - 64px)); min-width: 4px; background: var(--accent-fill); border-radius: 0 4px 4px 0; transform-origin: left; transition: transform 1s cubic-bezier(.2, .8, .2, 1); }
.hbar-git .hbar-fill { background: var(--neutral-fill); }
.hbar-val { font-weight: 600; font-size: 14px; white-space: nowrap; letter-spacing: -.01em; }
.hbar:hover .hbar-fill, .hbar:focus-visible .hbar-fill { filter: brightness(1.1); }
html.js .chart-card:not(.in) .hbar-fill { transform: scaleX(0); }
.hbar:nth-child(2) .hbar-fill { transition-delay: .1s; } .hbar:nth-child(3) .hbar-fill { transition-delay: .2s; } .hbar:nth-child(4) .hbar-fill { transition-delay: .3s; }
.num-tiles { display: grid; gap: 16px; grid-template-rows: repeat(3, 1fr); }
.ntile { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 18px 20px; display: flex; flex-direction: column; justify-content: center; gap: 4px; }
.ntile-value { font-size: 1.9rem; font-weight: 600; letter-spacing: -.04em; line-height: 1.1; }
.ntile-label { font-size: 14px; color: var(--text-2); }
.ntile .src { color: var(--text-3); font-size: 12.5px; }
.tradeoff { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: center; }
.tradeoff figcaption p { font-size: 14.5px; color: var(--text-2); margin-top: 8px; }
.sbars { display: flex; flex-direction: column; gap: 14px; }
.sbar { display: grid; grid-template-columns: 140px 1fr; gap: 14px; align-items: center; }
.sbar-label { font-size: 13.5px; color: var(--text-2); }
.sbar-track { display: flex; align-items: center; gap: 10px; height: 24px; border-left: 1px solid var(--border-strong); }
.sbar-fill { display: block; height: 20px; width: calc(var(--v) * (100% - 64px)); background: var(--accent-fill); border-radius: 0 4px 4px 0; transform-origin: left; transition: transform 1s cubic-bezier(.2, .8, .2, 1) .15s; }
.sbar-git .sbar-fill { background: var(--neutral-fill); }
.sbar-val { font-weight: 600; font-size: 14px; white-space: nowrap; }
html.js .tradeoff:not(.in) .sbar-fill { transform: scaleX(0); }
@media (max-width: 900px) {
  .numbers { grid-template-columns: 1fr; }
  .num-tiles { grid-template-rows: none; grid-template-columns: repeat(3, 1fr); }
  .tradeoff { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 640px) {
  .chart-card, .tradeoff { padding: 18px; }
  .num-tiles { grid-template-columns: 1fr; }
  .hbar { grid-template-columns: 1fr; gap: 6px; }
  .sbar { grid-template-columns: 1fr; gap: 6px; }
}

/* ---------- quick start ---------- */
.qs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0; counter-reset: qs; }
.qs-step { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 32px; align-items: start; padding: 26px 0; border-top: 1px solid var(--border); }
.qs-step:last-child { border-bottom: 1px solid var(--border); }
.qs-text { display: grid; grid-template-columns: 32px 1fr; column-gap: 14px; row-gap: 6px; }
.qs-n { grid-row: span 2; display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); font-family: var(--font-mono); font-size: 13px; font-weight: 600; }
.qs-text h3 { font-size: 1.05rem; align-self: center; }
.qs-text p { color: var(--text-2); font-size: 14.5px; }
@media (max-width: 820px) { .qs-step { grid-template-columns: 1fr; gap: 14px; padding: 22px 0; } }

/* ---------- agents ---------- */
.section-agents { background: var(--bg-2); }
.agents-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.agents-grid .section-head { margin-bottom: 0; }
.agents-links { margin-top: 16px; font-size: 14.5px; color: var(--text-3); }
.agents-code { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-3); align-self: flex-start; max-width: 100%; }
.tabs button { border: 0; background: transparent; padding: 7px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 550; color: var(--text-2); cursor: pointer; white-space: nowrap; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.agent-points { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.agent-points li { padding: 14px 16px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); font-size: 14.5px; color: var(--text-2); line-height: 1.55; }
.agent-points b { color: var(--text); font-weight: 600; }
@media (max-width: 900px) { .agents-grid { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- roadmap ---------- */
.roadmap { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; position: relative; }
.roadmap li { position: relative; padding: 18px 18px 20px; border-radius: var(--radius); border: 1px dashed var(--border-strong); background: var(--surface); }
.rm-dot { display: block; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--blossom-fill); margin-bottom: 14px; }
.roadmap h3 { font-size: 15px; margin-bottom: 6px; letter-spacing: -.01em; }
.roadmap p { font-size: 13.5px; color: var(--text-2); line-height: 1.5; }
@media (max-width: 1000px) { .roadmap { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .roadmap { grid-template-columns: 1fr; } }
.final-cta { margin-top: 64px; padding: 40px 28px; border-radius: var(--radius-lg); text-align: center; border: 1px solid var(--accent-line); background: radial-gradient(70% 120% at 50% 0%, var(--accent-soft), transparent 70%), var(--surface); }
.final-cta p { font-size: 1.15rem; color: var(--text-2); font-weight: 500; letter-spacing: -.01em; }
.final-cta .cta { margin-top: 22px; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--border); padding: 48px 0 56px; background: var(--bg-2); }
.footer-inner { display: grid; grid-template-columns: 1fr auto; gap: 24px 40px; align-items: start; }
.footer-brand p { color: var(--text-3); font-size: 14px; margin-top: 8px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.footer-links a { color: var(--text-2); text-decoration: none; font-size: 14px; }
.footer-links a:hover { color: var(--text); text-decoration: underline; }
.disclaimer { grid-column: 1 / -1; font-size: 13px; color: var(--text-3); max-width: 860px; padding-top: 20px; border-top: 1px solid var(--border); line-height: 1.6; }
.disclaimer a { color: var(--text-2); }
@media (max-width: 700px) { .footer-inner { grid-template-columns: 1fr; } }

@media (forced-colors: active) {
  .slot.full, .cell.on, .hbar-fill, .sbar-fill, .mbar-fill { background: CanvasText; }
}

/* ---------- star count, agent chips and example asks ---------- */
.star-count {
  margin-left: .45em;
  padding: .05em .5em;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font: 600 .82em/1.5 var(--font-mono);
}
.btn-primary .star-count { background: rgba(255, 255, 255, .2); color: inherit; }
.agent-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: 1rem 0 0; }
.agent-chips span {
  padding: .2rem .65rem;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font: 500 .8rem/1.4 var(--font-mono);
}
.agent-asks {
  margin: 1.1rem 0 .4rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.agent-asks-title {
  margin: 0 0 .5rem;
  color: var(--text-2);
  font: 600 .72rem/1.4 var(--font-mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}
.agent-asks blockquote {
  margin: .45rem 0 0;
  padding: .1rem 0 .1rem .8rem;
  border-left: 3px solid var(--blossom-fill);
  color: var(--text);
  font-size: .98rem;
  line-height: 1.5;
}
.agent-asks blockquote span { color: var(--text-2); font-size: .88em; }
.agent-asks code { font-size: .88em; }
