/* ==========================================================================
   AI Evolution Tracker — "Field guide" design system
   Ink + highlighter lime, Bricolage Grotesque display, Geist text, Geist Mono data.
   ========================================================================== */

:root {
  --font-display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
  --font-sans: 'Geist', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  --r-xs: 6px;
  --r-s: 10px;
  --r: 14px;
  --r-l: 20px;
  --ease: cubic-bezier(.2, .75, .25, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --sidebar-w: 264px;
  --topbar-h: 64px;
  --gutter: 48px;

  color-scheme: light;
  --bg: #f2f3ef;
  --bg-2: #ebece6;
  --surface: #ffffff;
  --surface-2: #f8f8f5;
  --surface-3: #eff0eb;
  --line: #e1e3dc;
  --line-2: #cfd2c8;
  --ink: #0d0f0c;
  --ink-2: #464b43;
  --ink-3: #666c62;
  --ink-4: #a5aa9f;
  --accent: #c8f04f;
  --accent-strong: #b5e02c;
  --accent-ink: #0d0f0c;
  --accent-text: #477300;
  --accent-soft: rgba(170, 220, 30, .14);
  --accent-line: rgba(110, 160, 0, .45);
  --verified: #11744b;
  --verified-bg: rgba(25, 135, 90, .1);
  --promising: #855408;
  --promising-bg: rgba(214, 150, 40, .14);
  --unverified: #a63f2b;
  --unverified-bg: rgba(200, 80, 55, .1);
  --neutral: #5f665a;
  --neutral-bg: rgba(105, 112, 100, .1);
  --shadow-s: 0 1px 2px rgba(16, 20, 12, .05);
  --shadow: 0 1px 2px rgba(16, 20, 12, .04), 0 10px 30px -12px rgba(16, 20, 12, .12);
  --shadow-l: 0 30px 90px -24px rgba(16, 20, 12, .35);
  --grid-line: rgba(13, 15, 12, .05);
  --grain-opacity: .035;
  --tile-l: 91%;
  --tile-s: 42%;
  --tile-ink-l: 28%;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0c0b;
  --bg-2: #0e100e;
  --surface: #121412;
  --surface-2: #161916;
  --surface-3: #1d201c;
  --line: rgba(236, 240, 230, .08);
  --line-2: rgba(236, 240, 230, .15);
  --ink: #eef0ea;
  --ink-2: #b2b7ad;
  --ink-3: #7e8479;
  --ink-4: #545a51;
  --accent: #c8f04f;
  --accent-strong: #d6f777;
  --accent-ink: #0b0c0b;
  --accent-text: #c8f04f;
  --accent-soft: rgba(200, 240, 79, .09);
  --accent-line: rgba(200, 240, 79, .38);
  --verified: #72e0a3;
  --verified-bg: rgba(114, 224, 163, .1);
  --promising: #f1c36a;
  --promising-bg: rgba(241, 195, 106, .1);
  --unverified: #f2937f;
  --unverified-bg: rgba(242, 147, 127, .1);
  --neutral: #9ba196;
  --neutral-bg: rgba(155, 161, 150, .1);
  --shadow-s: 0 1px 0 rgba(255, 255, 255, .02) inset;
  --shadow: 0 1px 0 rgba(255, 255, 255, .03) inset, 0 16px 40px -16px rgba(0, 0, 0, .7);
  --shadow-l: 0 40px 120px -20px rgba(0, 0, 0, .85);
  --grid-line: rgba(238, 240, 234, .04);
  --grain-opacity: .05;
  --tile-l: 17%;
  --tile-s: 26%;
  --tile-ink-l: 78%;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--topbar-h) + 16px); }
body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color .35s var(--ease), color .35s var(--ease);
}
body::before {
  /* Film grain: gives flat surfaces a printed, archival feel. */
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
::selection { background: var(--accent); color: var(--accent-ink); }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { display: block; flex-shrink: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 6px; }
[data-theme="dark"] :focus-visible { outline-color: var(--accent); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link {
  position: fixed; left: 16px; top: 12px; z-index: 200;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 14px; border-radius: var(--r-s); font-weight: 600; font-size: 13px;
  transform: translateY(-160%); transition: transform .2s var(--ease);
}
.skip-link:focus { transform: none; }
.mono { font-family: var(--font-mono); }

/* ---------- Shell ---------- */
.app-shell { min-height: 100vh; min-height: 100dvh; display: flex; }

.sidebar {
  width: var(--sidebar-w);
  flex: none;
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-right: 1px solid var(--line);
  z-index: 30;
  transition: background-color .35s var(--ease), transform .35s var(--ease-out);
}
.brand { display: flex; align-items: center; gap: 12px; padding: 22px 22px 30px; }
.brand-mark {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 11px;
  background: var(--ink);
  color: var(--accent);
  box-shadow: 0 0 0 1px var(--line), var(--shadow-s);
  transition: transform .4s var(--ease-out);
}
[data-theme="dark"] .brand-mark { background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 24px -4px rgba(200, 240, 79, .45); }
.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.05); }
.brand-type { display: flex; flex-direction: column; line-height: 1.15; }
.brand-type strong { font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: -.02em; font-variation-settings: 'opsz' 24; }
.brand-type span { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin-top: 3px; }

.sidebar-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding: 0 24px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.sidebar-label::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.sidebar-nav { display: flex; flex-direction: column; gap: 2px; padding: 0 12px; }
.nav-item {
  position: relative;
  display: grid;
  grid-template-columns: 26px 18px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--r-s);
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 500;
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.nav-item svg { width: 17px; height: 17px; color: var(--ink-3); transition: color .2s var(--ease); }
.nav-num { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-3); letter-spacing: .04em; }
.nav-count {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-2);
  min-width: 22px;
  text-align: center;
  padding: 1px 6px;
  border-radius: 99px;
  background: var(--surface-3);
}
.nav-item:hover { background: var(--surface-3); color: var(--ink); }
.nav-item:hover svg { color: var(--ink); }
.nav-item.active { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), var(--shadow-s); }
.nav-item.active::before {
  content: '';
  position: absolute;
  left: -12px;
  top: 9px;
  bottom: 9px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--accent-strong);
}
.nav-item.active svg, .nav-item.active .nav-num { color: var(--accent-text); }
.nav-item.active .nav-count { background: var(--accent); color: var(--accent-ink); }

.sidebar-bottom { margin-top: auto; padding: 24px 16px 16px; }
.archive-status {
  position: relative;
  overflow: hidden;
  padding: 16px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-s);
}
.archive-status::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 14px 14px;
  mask-image: linear-gradient(135deg, transparent 30%, #000);
  -webkit-mask-image: linear-gradient(135deg, transparent 30%, #000);
  pointer-events: none;
}
.status-kicker { position: relative; font-family: var(--font-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.status-day { position: relative; font-family: var(--font-display); font-weight: 700; font-size: 30px; letter-spacing: -.04em; line-height: 1.05; margin: 6px 0 2px; font-variation-settings: 'opsz' 48; }
.status-day span { color: var(--ink-4); }
.status-line { position: relative; font-size: 12px; color: var(--ink-3); line-height: 1.5; }
.status-tagline { position: relative; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line-2); font-size: 12.5px; color: var(--ink-2); line-height: 1.45; }
.status-tagline strong { color: var(--ink); font-weight: 600; }
.sidebar-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 6px 0;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.version { margin-left: auto; color: var(--ink-3); }
.pulse-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--verified);
  flex: none;
}
.pulse-dot::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--verified);
  opacity: .5;
  animation: ping 2.4s var(--ease) infinite;
}

.main-shell { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 var(--gutter);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.top-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.crumbs { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 13.5px; }
.crumb-root { font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); transition: color .2s; }
.crumb-root:hover { color: var(--ink); }
.crumb-sep { color: var(--ink-4); }
.top-current { font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-actions { display: flex; align-items: center; gap: 8px; }

.search-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 260px;
  padding: 8px 8px 8px 12px;
  border-radius: var(--r-s);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-3);
  font-size: 13px;
  text-align: left;
  box-shadow: var(--shadow-s);
  transition: border-color .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}
.search-trigger:hover { border-color: var(--line-2); color: var(--ink-2); box-shadow: var(--shadow); }
.search-trigger svg { width: 16px; height: 16px; }
.search-trigger kbd, .kbd {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
  padding: 2px 7px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  box-shadow: 0 1px 0 var(--line);
}
.icon-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: var(--r-s);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
  box-shadow: var(--shadow-s);
  transition: color .2s var(--ease), border-color .2s var(--ease), transform .3s var(--ease-out);
}
.icon-button:hover { color: var(--ink); border-color: var(--line-2); }
.icon-button svg { width: 18px; height: 18px; }
.theme-toggle:active svg { transform: rotate(40deg); }
.theme-toggle svg { transition: transform .5s var(--ease-out); }
.read-only-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--r-s);
  border: 1px dashed var(--line-2);
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  white-space: nowrap;
}
.mobile-menu { display: none; }
.mobile-overlay { display: none; }

/* ---------- Footer ---------- */
.page-footer { margin-top: auto; border-top: 1px solid var(--line); padding: 40px var(--gutter) 28px; }
.footer-grid { max-width: 1280px; margin: 0 auto; display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 32px; }
.footer-brand p { color: var(--ink-3); font-size: 13.5px; max-width: 34ch; margin: 12px 0 0; }
.footer-brand .brand-type strong { font-size: 18px; }
.footer-col h4 { font-family: var(--font-mono); font-weight: 500; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin: 4px 0 14px; }
.footer-col a { display: block; font-size: 13.5px; color: var(--ink-2); padding: 4px 0; transition: color .2s; }
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
  max-width: 1280px;
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px dashed var(--line);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .04em;
  color: var(--ink-3);
}
.to-top { border: 0; background: none; padding: 0; color: var(--ink-3); font: inherit; letter-spacing: inherit; }
.to-top:hover { color: var(--ink); }

/* ---------- Page scaffolding ---------- */
#content { outline: none; }
.page { width: 100%; max-width: 1280px; margin: 0 auto; padding: 40px var(--gutter) 88px; }
.page > * { animation: rise .7s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 70ms); }
.page > :nth-child(2) { --i: 1; }
.page > :nth-child(3) { --i: 2; }
.page > :nth-child(4) { --i: 3; }
.page > :nth-child(5) { --i: 4; }
.page > :nth-child(6) { --i: 5; }
.page > :nth-child(n+7) { --i: 6; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.eyebrow .tick { width: 8px; height: 8px; border-radius: 2px; background: var(--accent-strong); box-shadow: 0 0 0 3px var(--accent-soft); }
.eyebrow .sep { color: var(--ink-4); }

.page-head { padding: 12px 0 36px; border-bottom: 1px solid var(--line); margin-bottom: 36px; display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; }
.page-head h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(38px, 4.6vw, 64px);
  line-height: .98;
  letter-spacing: -.045em;
  font-variation-settings: 'opsz' 96;
  margin: 16px 0 14px;
}
.page-head p { color: var(--ink-2); font-size: 16.5px; max-width: 56ch; margin: 0; }
.page-head-aside { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); text-align: right; white-space: nowrap; }
.page-head-aside strong { display: block; text-transform: none; font-family: var(--font-display); font-size: 44px; line-height: 1; letter-spacing: -.04em; color: var(--ink); font-weight: 700; margin-bottom: 6px; }
.page-head-aside strong .lead { color: var(--ink-3); }

.section { margin-top: 72px; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 22px; }
.section-head h2 {
  font-family: var(--font-display);
  font-weight: 650;
  font-size: 26px;
  letter-spacing: -.03em;
  line-height: 1.1;
  margin: 10px 0 6px;
  font-variation-settings: 'opsz' 48;
}
.section-head p { margin: 0; color: var(--ink-3); font-size: 14px; max-width: 60ch; }
.section-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-2);
  white-space: nowrap;
  padding: 8px 0;
  transition: color .2s, gap .25s var(--ease-out);
}
.section-link:hover { color: var(--ink); gap: 12px; }
.section-link svg { width: 14px; height: 14px; }

.footnote {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px dashed var(--line-2);
  font-size: 12.5px;
  color: var(--ink-3);
  line-height: 1.6;
}
.footnote svg { width: 15px; height: 15px; margin-top: 2px; color: var(--ink-4); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 46px;
  padding: 0 20px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -.005em;
  white-space: nowrap;
  transition: transform .25s var(--ease-out), background-color .2s var(--ease), border-color .2s var(--ease), box-shadow .25s var(--ease);
}
.btn svg { width: 16px; height: 16px; transition: transform .3s var(--ease-out); }
.btn:hover svg.arrow { transform: translateX(3px); }
.btn:active { transform: translateY(1px) scale(.99); }
.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 0 0 1px rgba(80, 120, 0, .25), 0 8px 24px -10px rgba(140, 200, 0, .7);
}
.btn-primary:hover { background: var(--accent-strong); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 0 0 1px rgba(80, 120, 0, .3), 0 14px 32px -10px rgba(140, 200, 0, .8); }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow-s); }
.btn-ghost:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.btn-sm { height: 36px; padding: 0 14px; font-size: 13px; border-radius: 10px; }

/* ---------- Card primitives ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-l);
  box-shadow: var(--shadow-s);
  transition: background-color .35s var(--ease), border-color .25s var(--ease), box-shadow .3s var(--ease), transform .35s var(--ease-out);
}
.glow { position: relative; isolation: isolate; }
.glow::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  z-index: -1;
  pointer-events: none;
  opacity: 0;
  transition: opacity .35s var(--ease);
  background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), var(--accent-soft), transparent 45%);
}
.glow:hover::after { opacity: 1; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  padding: 28px 0 60px;
  isolation: isolate;
}
.hero-bg {
  position: absolute;
  inset: -40px calc(var(--gutter) * -1) 0;
  z-index: -1;
  pointer-events: none;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 32px 32px;
  background-position: -1px -1px;
  mask-image: radial-gradient(ellipse 70% 80% at 70% 40%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 70% 40%, #000 20%, transparent 75%);
}
.hero-bg::after {
  content: '';
  position: absolute;
  width: 520px;
  height: 520px;
  right: 6%;
  top: 0;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-soft), transparent 65%);
  filter: blur(10px);
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(44px, 5.3vw, 82px);
  line-height: .94;
  letter-spacing: -.05em;
  font-variation-settings: 'opsz' 96;
  margin: 22px 0 26px;
}
.hl { position: relative; display: inline-block; padding: 0 .08em; margin: 0 -.08em; }
.hl::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  padding: 0 .08em;
  border-radius: .12em .22em .14em .26em;
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 .05em 0 var(--accent), 0 -.03em 0 var(--accent);
  clip-path: inset(-.1em 100% -.1em 0);
  animation: marker 1s .45s var(--ease-out) forwards;
}
.br-wide { display: inline; }
.hero-lede { font-size: 18px; line-height: 1.6; color: var(--ink-2); max-width: 36ch; margin: 0; }
.hero-lede strong { color: var(--ink); font-weight: 600; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.hero-readonly { display: flex; align-items: center; gap: 8px; margin-top: 22px; font-size: 13px; color: var(--ink-3); }
.hero-readonly svg { width: 15px; height: 15px; color: var(--verified); }

.plate {
  position: relative;
  padding: 18px 18px 14px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) -1px -1px / 24px 24px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) -1px -1px / 24px 24px,
    var(--surface);
  box-shadow: var(--shadow);
}
.crop { position: absolute; width: 14px; height: 14px; border-color: var(--ink-3); border-style: solid; border-width: 0; }
.crop.tl { left: -6px; top: -6px; border-left-width: 1px; border-top-width: 1px; }
.crop.tr { right: -6px; top: -6px; border-right-width: 1px; border-top-width: 1px; }
.crop.bl { left: -6px; bottom: -6px; border-left-width: 1px; border-bottom-width: 1px; }
.crop.br { right: -6px; bottom: -6px; border-right-width: 1px; border-bottom-width: 1px; }
.plate-head, .plate-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.plate-head strong { color: var(--ink); font-weight: 500; }
.plate-foot { flex-wrap: wrap; row-gap: 6px; border-top: 1px dashed var(--line-2); padding-top: 12px; margin-top: 6px; letter-spacing: .06em; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.legend .l-rated { background: var(--accent-strong); box-shadow: 0 0 0 1.5px var(--ink); }
.legend .l-unrated { background: var(--surface); box-shadow: 0 0 0 1.5px var(--ink); }
.legend .l-ghost { border: 1.5px dashed var(--ink-4); }
.legend .l-root { background: var(--accent); box-shadow: 0 0 0 1.5px var(--ink), 0 0 0 4px var(--accent-soft); }

/* Cladogram */
.clado { width: 100%; height: auto; margin: 6px 0 2px; overflow: visible; }
.clado .grow { animation: grow 1.8s .2s var(--ease-out) both; }
.clado .edge { fill: none; stroke: var(--ink-2); stroke-width: 1.4; stroke-linecap: round; }
.clado .edge.ghost { stroke: var(--ink-4); stroke-width: 1.2; opacity: .85; }
.clado text { paint-order: stroke; stroke: var(--surface); stroke-width: 5px; stroke-linejoin: round; }
.clado .axis { stroke: var(--line-2); stroke-width: 1; stroke-dasharray: 1 4; }
.clado .axis-label { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .1em; fill: var(--ink-3); text-transform: uppercase; }
.clado .node { fill: var(--surface); stroke: var(--ink); stroke-width: 1.5; transform-box: fill-box; transform-origin: center; animation: pop .5s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 1ms + 700ms); }
.clado .node.rated { fill: var(--accent-strong); }
.clado .node.branch { fill: var(--ink); }
.clado .node.ghost { stroke: var(--ink-4); stroke-dasharray: 2 2.4; fill: var(--surface); animation: pop .5s var(--ease-out) both, breathe 3.2s ease-in-out infinite; animation-delay: calc(var(--d, 0) * 1ms + 700ms), calc(var(--d, 0) * 3ms + 1600ms); }
.clado .node.branch.ghost { fill: var(--surface-3); stroke-dasharray: none; }
.clado .root { fill: var(--accent); stroke: var(--ink); stroke-width: 1.6; }
.clado .root-ring { fill: none; stroke: var(--accent-line); stroke-width: 1.2; transform-box: fill-box; transform-origin: center; animation: ring 2.6s var(--ease) infinite; }
[data-theme="dark"] .clado .root { filter: drop-shadow(0 0 8px rgba(200, 240, 79, .7)); }
.clado .branch-label { font-family: var(--font-mono); font-size: 10.5px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; fill: var(--ink-2); }
.clado .branch-label.ghost { fill: var(--ink-3); }
.clado .branch-count { fill: var(--ink-3); }
.clado .leaf-label { font-family: var(--font-sans); font-size: 12.5px; font-weight: 500; fill: var(--ink-2); }
.clado .leaf-label.more { fill: var(--ink-3); font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; }
.clado a .leaf-label { transition: fill .2s; }
.clado a:hover .leaf-label, .clado a:focus-visible .leaf-label { fill: var(--accent-text); text-decoration: underline; }
.clado .fade-in { animation: fadein .6s var(--ease) both; animation-delay: calc(var(--d, 0) * 1ms + 900ms); }

/* ---------- Stats strip ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: var(--r-l);
  background: var(--surface);
  box-shadow: var(--shadow-s);
  overflow: hidden;
}
.stat { position: relative; padding: 22px 24px 20px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat-top { display: flex; justify-content: space-between; align-items: center; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.stat-top svg { width: 15px; height: 15px; color: var(--ink-4); }
.stat-num {
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: clamp(34px, 3.2vw, 46px);
  letter-spacing: -.05em;
  line-height: 1;
  margin-top: 20px;
  font-variant-numeric: tabular-nums slashed-zero;
}
.stat-num .lead { color: var(--ink-3); }
.stat-note { margin-top: 10px; font-size: 12.5px; color: var(--ink-3); }
.stat.accent .stat-num { color: var(--ink); }
.stat.accent::before {
  content: '';
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--accent-strong);
}

/* ---------- Category cards ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cat-card { padding: 20px 20px 16px; display: flex; flex-direction: column; }
.cat-card:hover { border-color: var(--line-2); box-shadow: var(--shadow); transform: translateY(-2px); }
.cat-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.cat-name { font-family: var(--font-display); font-weight: 650; font-size: 20px; letter-spacing: -.025em; line-height: 1.15; font-variation-settings: 'opsz' 32; }
.cat-name a:hover { text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.cat-meta { font-family: var(--font-mono); font-size: 11px; letter-spacing: .04em; color: var(--ink-3); margin-top: 6px; }
.top-badge { font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); border: 1px solid var(--line); border-radius: 99px; padding: 3px 9px; white-space: nowrap; }
.rank-list { list-style: none; margin: 18px 0 16px; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.rank-row {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 54px 34px;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--r-s);
  background: var(--surface-2);
  border: 1px solid transparent;
  transition: border-color .2s var(--ease), background-color .2s var(--ease);
}
a.rank-row:hover { border-color: var(--line-2); background: var(--surface); }
.rank-num { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); text-align: center; border-radius: 6px; padding: 2px 0; }
.rank-list > li:first-child .rank-row:not(.is-vacant) .rank-num { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.rank-name { font-size: 14px; font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-score { font-family: var(--font-mono); font-size: 12.5px; font-weight: 500; text-align: right; font-variant-numeric: tabular-nums; }
.bar { height: 5px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: inherit; background: var(--ink); transform-origin: left; animation: fill 1s .3s var(--ease-out) both; }
.rank-list > li:first-child .bar > i, .board-row:first-child .bar > i { background: var(--accent-strong); }
[data-theme="dark"] .bar > i { background: var(--ink-2); }
[data-theme="dark"] .rank-list > li:first-child .bar > i, [data-theme="dark"] .board-row:first-child .bar > i { background: var(--accent); }
.rank-row.is-vacant { background: transparent; border: 1px dashed var(--line-2); color: var(--ink-3); font-size: 13px; }
.rank-row.is-vacant .rank-num { background: transparent; color: var(--ink-3); font-weight: 400; }
.cat-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; padding-top: 12px; border-top: 1px dashed var(--line); }

/* ---------- Empty states ---------- */
.empty {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 48px 28px 52px;
  border-radius: var(--r-l);
  border: 1px solid var(--line);
  background:
    radial-gradient(ellipse 60% 70% at 50% 0%, var(--accent-soft), transparent 70%),
    var(--surface);
}
.empty::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: radial-gradient(ellipse 50% 60% at 50% 30%, #000, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 50% 60% at 50% 30%, #000, transparent 75%);
  pointer-events: none;
}
.empty > * { position: relative; }
.empty-art { color: var(--ink-3); margin-bottom: 24px; }
.empty-art svg { width: auto; max-width: 100%; }
.empty-art .a-line { stroke: var(--ink-4); }
.empty-art .a-strong { stroke: var(--ink-2); }
.empty-art .a-fill { fill: var(--surface-2); }
.empty-art .a-accent { fill: var(--accent); stroke: var(--ink); }
.empty-art .a-text { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; fill: var(--ink-3); }
.empty-art .a-breathe { animation: breathe 3.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.empty-kicker { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 10px; }
.empty h3 { font-family: var(--font-display); font-weight: 650; font-size: 24px; letter-spacing: -.03em; line-height: 1.15; margin: 0 0 10px; font-variation-settings: 'opsz' 40; }
.empty p { margin: 0 auto; max-width: 46ch; color: var(--ink-3); font-size: 14.5px; line-height: 1.6; }
.empty .btn { margin-top: 22px; }
.empty.compact { padding: 32px 24px 36px; }
.empty.compact .empty-art { margin-bottom: 16px; }
.empty.compact h3 { font-size: 19px; }
.empty.compact p { font-size: 13.5px; }
.empty.bare { border: 0; background: none; }
.empty.bare::before { display: none; }

/* ---------- Process ---------- */
.process { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.process::before {
  content: '';
  position: absolute;
  top: 37px;
  left: 40px;
  right: 40px;
  height: 1px;
  background: repeating-linear-gradient(90deg, var(--line-2) 0 4px, transparent 4px 9px);
}
.step { position: relative; padding: 20px 22px 24px; border-radius: var(--r-l); }
.step:hover { background: var(--surface); box-shadow: 0 0 0 1px var(--line), var(--shadow-s); }
.step-node {
  position: relative;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: var(--bg);
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-2);
  margin-bottom: 22px;
  transition: background-color .25s, color .25s, border-color .25s;
}
.step:first-child .step-node { background: var(--accent); color: var(--accent-ink); border-color: transparent; box-shadow: 0 0 0 5px var(--accent-soft); }
.step:hover .step-node { border-color: var(--ink); color: var(--ink); }
.step:first-child:hover .step-node { color: var(--accent-ink); }
.step-title { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 650; font-size: 21px; letter-spacing: -.025em; margin: 0 0 8px; font-variation-settings: 'opsz' 32; }
.step-title svg { width: 18px; height: 18px; color: var(--ink-3); }
.step p { margin: 0; color: var(--ink-3); font-size: 14px; line-height: 1.65; }

/* ---------- Notes / origin ---------- */
.notes { padding: 6px 24px; }
.note-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: baseline;
  padding: 18px 0;
  border-bottom: 1px dashed var(--line);
}
.note-row:last-child { border-bottom: 0; }
.note-date { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); letter-spacing: .02em; }
.note-title { font-weight: 600; font-size: 15px; }
.note-body { color: var(--ink-3); font-size: 13.5px; margin-top: 3px; }
.note-link { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); display: inline-flex; gap: 6px; align-items: center; }
.note-link:hover { color: var(--ink); }
.note-link svg { width: 13px; height: 13px; }
.origin-row { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 20px; align-items: center; padding: 18px 0; }
.origin-mark { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); }
.origin-mark i { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 1.5px var(--ink), 0 0 0 5px var(--accent-soft); }
.origin-copy { color: var(--ink-3); font-size: 13.5px; }
.origin-copy strong { color: var(--ink); font-weight: 600; }
.awaiting-row { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 20px; align-items: center; padding: 18px 0; border-bottom: 1px dashed var(--line); color: var(--ink-3); font-size: 13.5px; }
.awaiting-row .note-date { color: var(--ink-3); }
.skeleton-line { height: 9px; border-radius: 99px; background: linear-gradient(90deg, var(--surface-3), var(--surface-2), var(--surface-3)); background-size: 200% 100%; animation: shimmer 2.4s linear infinite; }

/* ---------- Toolbar & filters ---------- */
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.search-field { position: relative; flex: 1 1 300px; max-width: 420px; }
.search-field svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--ink-3); pointer-events: none; }
.field-input {
  width: 100%;
  height: 44px;
  padding: 0 14px 0 40px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 14px;
  box-shadow: var(--shadow-s);
  transition: border-color .2s, box-shadow .2s;
}
.field-input::placeholder { color: var(--ink-3); }
.field-input:focus { outline: none; border-color: var(--ink-3); box-shadow: 0 0 0 4px var(--accent-soft); }
.toolbar-right { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; min-width: 0; max-width: 100%; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); }
.seg-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px;
  border-radius: 9px;
  border: 0;
  background: transparent;
  color: var(--ink-3);
  font-size: 13px;
  font-weight: 500;
  transition: background-color .2s, color .2s, box-shadow .2s;
}
.seg-btn:hover { color: var(--ink); }
.seg-btn .dot { width: 7px; height: 7px; border-radius: 50%; }
.seg-btn .count { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-3); }
.seg-btn.active { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), var(--shadow-s); }
.seg-btn.active .count { color: var(--ink-2); }
.select-wrap { position: relative; }
.select-wrap svg { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--ink-3); pointer-events: none; }
.field-select {
  appearance: none;
  -webkit-appearance: none;
  height: 44px;
  padding: 0 36px 0 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 13.5px;
  box-shadow: var(--shadow-s);
}
.results-hint { display: flex; justify-content: space-between; gap: 12px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .04em; color: var(--ink-3); margin: 18px 0 12px; }
.results-hint strong { color: var(--ink); font-weight: 500; }

/* ---------- Tool rows ---------- */
.tool-list { display: flex; flex-direction: column; gap: 8px; }
.tool-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 16px 18px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-s);
  transition: border-color .2s var(--ease), box-shadow .3s var(--ease), transform .35s var(--ease-out);
  animation: rise .5s var(--ease-out) both;
  animation-delay: calc(var(--i, 0) * 35ms);
}
.tool-row:hover { border-color: var(--line-2); box-shadow: var(--shadow); transform: translateY(-1px); }
.tool-row:hover .chev { transform: translateX(3px); color: var(--ink); }
.tile {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: hsl(var(--h, 90) var(--tile-s) var(--tile-l));
  color: hsl(var(--h, 90) 45% var(--tile-ink-l));
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -.03em;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .04);
  flex: none;
}
.tool-main { min-width: 0; }
.tool-title { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.tool-name { font-family: var(--font-display); font-weight: 650; font-size: 18px; letter-spacing: -.02em; font-variation-settings: 'opsz' 24; }
.tool-title .tool-name { flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tool-title .tool-maker { flex: 0 100 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tool-maker { font-size: 13px; color: var(--ink-3); }
.tool-summary { display: block; margin-top: 3px; color: var(--ink-2); font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.pill { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .03em; color: var(--ink-3); padding: 2px 8px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; }
.tool-side { display: flex; align-items: center; gap: 18px; }
.score { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; min-width: 76px; }
.score-num { font-family: var(--font-mono); font-size: 20px; font-weight: 500; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.score-num small { font-size: 11px; color: var(--ink-3); letter-spacing: 0; margin-left: 2px; }
.score .bar { width: 76px; }
.score-none { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .04em; text-transform: uppercase; }
.chev { color: var(--ink-4); transition: transform .3s var(--ease-out), color .2s; }
.chev svg { width: 18px; height: 18px; }

/* Evidence badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 26px;
  padding: 0 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 550;
  white-space: nowrap;
  color: var(--neutral);
  background: var(--neutral-bg);
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.verified { color: var(--verified); background: var(--verified-bg); }
.badge.promising { color: var(--promising); background: var(--promising-bg); }
.badge.unverified { color: var(--unverified); background: var(--unverified-bg); }
.badge.unevaluated { background: transparent; box-shadow: inset 0 0 0 1px var(--line-2); }
.badge.unevaluated::before { background: transparent; box-shadow: inset 0 0 0 1.5px currentColor; }
.dot.verified { background: var(--verified); }
.dot.promising { background: var(--promising); }
.dot.unverified { background: var(--unverified); }
.dot.unevaluated { box-shadow: inset 0 0 0 1.5px var(--neutral); }
.dot.all { background: var(--ink); }

/* ---------- Detail page ---------- */
.back-link { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 26px; transition: color .2s, gap .25s var(--ease-out); }
.back-link:hover { color: var(--ink); gap: 12px; }
.back-link svg { width: 14px; height: 14px; transform: rotate(180deg); }
.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: end;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 28px;
}
.detail-id { display: flex; gap: 22px; align-items: flex-start; }
.detail-id .tile { width: 76px; height: 76px; border-radius: 22px; font-size: 28px; }
.detail-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(38px, 4.4vw, 60px); letter-spacing: -.045em; line-height: .98; margin: 12px 0 12px; font-variation-settings: 'opsz' 96; }
.detail-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; color: var(--ink-3); font-size: 14px; }
.detail-meta span { display: inline-flex; align-items: center; gap: 7px; }
.detail-meta svg { width: 15px; height: 15px; }
.detail-side { display: flex; align-items: center; gap: 20px; }
.dial { position: relative; width: 112px; height: 112px; flex: none; }
.dial svg { width: 112px; height: 112px; transform: rotate(-90deg); }
.dial .track { fill: none; stroke: var(--surface-3); stroke-width: 8; }
.dial .value { fill: none; stroke: var(--accent-strong); stroke-width: 8; stroke-linecap: round; animation: dial 1.4s .3s var(--ease-out) both; }
.dial .track.none { stroke: var(--line-2); stroke-dasharray: 2 6; stroke-width: 2; }
.dial-text { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; align-content: center; }
.dial-text strong { font-family: var(--font-mono); font-weight: 500; font-size: 28px; letter-spacing: -.05em; line-height: 1; }
.dial-text span { font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em; color: var(--ink-3); text-transform: uppercase; margin-top: 5px; }
.dial-text.none strong { font-size: 13px; letter-spacing: .04em; color: var(--ink-3); }
.detail-actions { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(300px, 1fr); gap: 20px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.panel { padding: 26px; }
.panel-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 16px; }
.panel-title h2 { font-family: var(--font-display); font-weight: 650; font-size: 20px; letter-spacing: -.025em; margin: 0; font-variation-settings: 'opsz' 32; }
.panel-title .mono-label { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.panel p { color: var(--ink-2); font-size: 15px; line-height: 1.75; margin: 0; }
.panel p + p { margin-top: 12px; }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin-top: 22px; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: var(--line); }
.fact { padding: 14px 16px; background: var(--surface-2); }
.fact > span:first-child { display: block; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 7px; }
.fact strong { font-size: 14.5px; font-weight: 550; }
.verdict { position: relative; margin-top: 20px; padding: 18px 20px 18px 22px; border-radius: var(--r); background: var(--accent-soft); border: 1px solid var(--accent-line); color: var(--ink); font-size: 14.5px; line-height: 1.65; }
.verdict b { display: block; font-family: var(--font-mono); font-size: 10.5px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 6px; }
.pro-con { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.check-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.check-list li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; font-size: 14.5px; color: var(--ink-2); line-height: 1.55; }
.check-list .ic { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; margin-top: 1px; }
.check-list .ic svg { width: 13px; height: 13px; }
.check-list.pros .ic { background: var(--verified-bg); color: var(--verified); }
.check-list.cons .ic { background: var(--promising-bg); color: var(--promising); }
.muted { color: var(--ink-3); font-size: 14px; }
.metric { display: grid; grid-template-columns: minmax(90px, 120px) 1fr 40px; align-items: center; gap: 14px; padding: 9px 0; }
.metric-name { font-size: 13.5px; color: var(--ink-2); }
.metric .bar { height: 7px; }
.metric-val { font-family: var(--font-mono); font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; }
.metric-val.none { color: var(--ink-4); }
.panel-note { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line-2); font-size: 12.5px; color: var(--ink-3); line-height: 1.6; }

/* Receipts — sources styled as torn evidence slips */
.receipts { display: flex; flex-direction: column; gap: 10px; }
.receipt {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  transition: border-color .2s, background-color .2s;
}
.receipt:hover { border-color: var(--line-2); background: var(--surface); }
.receipt-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); }
.receipt-ic svg { width: 15px; height: 15px; }
.receipt a.receipt-title { font-weight: 600; font-size: 14.5px; line-height: 1.4; text-decoration: underline; text-decoration-color: var(--line-2); text-decoration-thickness: 1px; text-underline-offset: 3px; transition: text-decoration-color .2s; }
.receipt a.receipt-title:hover { text-decoration-color: var(--accent-strong); text-decoration-thickness: 2px; }
.receipt-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 5px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .02em; }
.receipt-meta .host { color: var(--ink-2); }
.receipt-note { margin-top: 6px; font-size: 13px; color: var(--ink-3); line-height: 1.55; }
.receipt-date { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); white-space: nowrap; }
.receipt-tool { font-family: var(--font-mono); font-size: 11px; color: var(--accent-text); }
.receipt-tool:hover { text-decoration: underline; }

.history { position: relative; padding-left: 22px; }
.history::before { content: ''; position: absolute; left: 5px; top: 8px; bottom: 8px; width: 1px; background: var(--line-2); }
.history-item { position: relative; padding: 4px 0 14px; }
.history-item::before { content: ''; position: absolute; left: -22px; top: 10px; width: 11px; height: 11px; border-radius: 50%; background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--ink-2); }
.history-item:first-child::before { background: var(--accent); box-shadow: inset 0 0 0 1.5px var(--ink); }
.history-item time { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); }
.history-item p { font-size: 14px; margin: 3px 0 0; }

/* ---------- Category page ---------- */
.cat-banner {
  position: relative;
  overflow: hidden;
  padding: 36px 36px 32px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) -1px -1px / 28px 28px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) -1px -1px / 28px 28px,
    radial-gradient(ellipse 50% 90% at 100% 0%, var(--accent-soft), transparent 70%),
    var(--surface);
  margin-bottom: 40px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
}
.cat-banner h1 { font-family: var(--font-display); font-weight: 700; font-size: clamp(36px, 4.4vw, 60px); letter-spacing: -.045em; line-height: .98; margin: 14px 0 12px; font-variation-settings: 'opsz' 96; }
.cat-banner p { color: var(--ink-2); margin: 0; max-width: 52ch; }
.banner-stats { display: flex; gap: 28px; }
.banner-stat { text-align: right; }
.banner-stat strong { display: block; font-family: var(--font-mono); font-weight: 500; font-size: 36px; letter-spacing: -.05em; line-height: 1; }
.banner-stat > span { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }

.podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: end; margin-bottom: 8px; }
.pedestal { display: flex; flex-direction: column; }
.pedestal-card { padding: 18px 18px 16px; border-radius: 18px 18px 0 0; border: 1px solid var(--line); border-bottom: 0; background: var(--surface); min-height: 128px; display: flex; flex-direction: column; gap: 10px; }
.pedestal-card .tool-name { font-size: 19px; }
.pedestal-card .tool-maker { font-size: 12.5px; }
.pedestal-card.vacant { background: transparent; border-style: dashed; border-color: var(--line-2); align-items: center; justify-content: center; color: var(--ink-3); font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.pedestal-base {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 14px;
  border-radius: 0 0 14px 14px;
  border: 1px solid var(--line);
  background: linear-gradient(var(--surface-3), var(--surface-2));
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 34px;
  letter-spacing: -.04em;
  color: var(--ink-3);
  font-variation-settings: 'opsz' 48;
}
.pedestal.p1 .pedestal-base { height: 130px; background: linear-gradient(var(--accent), var(--accent-strong)); color: var(--accent-ink); border-color: transparent; }
.pedestal.p2 .pedestal-base { height: 96px; }
.pedestal.p3 .pedestal-base { height: 70px; }
.pedestal-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.pedestal-score { font-family: var(--font-mono); font-size: 22px; font-weight: 500; letter-spacing: -.04em; }

/* ---------- Rankings ---------- */
.boards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.board { padding: 22px 22px 14px; }
.board-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.board-head h3 { font-family: var(--font-display); font-weight: 650; font-size: 21px; letter-spacing: -.025em; margin: 0; }
.board-row { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto 90px 40px; align-items: center; gap: 12px; padding: 11px 6px; border-radius: 10px; border-bottom: 1px dashed var(--line); transition: background-color .2s; }
.board-row:last-child { border-bottom: 0; }
.board-row:hover { background: var(--surface-2); }
.board-rank { font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.board-row:first-child .board-rank { color: var(--accent-ink); background: var(--accent); border-radius: 6px; text-align: center; padding: 2px 0; }
.board-name { font-weight: 600; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.board-row .badge { height: 22px; font-size: 11px; padding: 0 8px; }

/* ---------- Timeline ---------- */
.timeline { position: relative; max-width: 860px; }
.timeline::before { content: ''; position: absolute; left: 131px; top: 6px; bottom: 6px; width: 1px; background: linear-gradient(var(--line-2), var(--line-2) 85%, transparent); }
.tl-month { font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); padding: 6px 0 14px 160px; }
.tl-item { position: relative; display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 40px; padding-bottom: 22px; }
.tl-item::before { content: ''; position: absolute; left: 126px; top: 22px; width: 11px; height: 11px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 1.5px var(--ink-2); }
.tl-date { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3); text-align: right; padding-top: 18px; }
.tl-card { padding: 18px 20px; }
.tl-card h3 { font-family: var(--font-display); font-weight: 650; font-size: 19px; letter-spacing: -.02em; margin: 0 0 6px; }
.tl-card p { color: var(--ink-2); font-size: 14px; margin: 0 0 6px; }
.tl-item.origin::before { background: var(--accent); box-shadow: inset 0 0 0 1.5px var(--ink), 0 0 0 6px var(--accent-soft); }
.tl-item.origin .tl-card { background: transparent; border-style: dashed; box-shadow: none; }
.tl-item.origin h3 { display: flex; align-items: center; gap: 10px; }
.tl-item.pending::before { box-shadow: inset 0 0 0 1.5px var(--ink-4); border: 0; }
.tl-item.pending .tl-card { background: transparent; border-style: dashed; box-shadow: none; }
.tl-item.pending .tl-date { color: var(--ink-3); }

/* ---------- Methodology ---------- */
.method-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 56px; align-items: start; }
.toc { position: sticky; top: calc(var(--topbar-h) + 28px); display: flex; flex-direction: column; gap: 2px; }
.toc-label { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 10px; }
.toc a { display: grid; grid-template-columns: 26px 1fr; gap: 6px; padding: 7px 10px; border-radius: 8px; font-size: 13.5px; color: var(--ink-3); transition: color .2s, background-color .2s; }
.toc a span { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-3); padding-top: 2px; }
.toc a:hover { color: var(--ink); background: var(--surface-3); }
.toc a.active { color: var(--ink); background: var(--surface); box-shadow: 0 0 0 1px var(--line); }
.toc a.active span { color: var(--accent-text); }
.article { max-width: 760px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.article section { padding: 30px 0; border-bottom: 1px dashed var(--line); }
.article section:first-of-type { padding-top: 10px; }
.article h2 { display: flex; align-items: baseline; gap: 14px; font-family: var(--font-display); font-weight: 650; font-size: 28px; letter-spacing: -.03em; line-height: 1.15; margin: 0 0 14px; font-variation-settings: 'opsz' 48; }
.article h2 span { font-family: var(--font-mono); font-size: 12px; font-weight: 400; color: var(--accent-text); letter-spacing: .04em; }
.article p { color: var(--ink-2); font-size: 16px; line-height: 1.8; margin: 0 0 14px; }
.article p:last-child { margin-bottom: 0; }
.article strong { color: var(--ink); font-weight: 600; }
.evidence-scale { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 22px; }
.scale-step { padding: 16px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); }
.scale-meter { display: flex; gap: 3px; margin-bottom: 14px; }
.scale-meter i { flex: 1; height: 4px; border-radius: 4px; background: var(--surface-3); }
.scale-step.verified .scale-meter i { background: var(--verified); }
.scale-step.promising .scale-meter i:nth-child(-n+2) { background: var(--promising); }
.scale-step.unverified .scale-meter i:nth-child(1) { background: var(--unverified); }
.scale-step p { font-size: 13.5px; line-height: 1.6; color: var(--ink-3); margin: 12px 0 0; }
.rating-scale { margin-top: 22px; padding: 20px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); }
.rating-track { position: relative; height: 10px; border-radius: 99px; background: linear-gradient(90deg, var(--surface-3), var(--accent-strong)); }
.rating-ticks { display: flex; justify-content: space-between; margin-top: 10px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); }
.rating-caption { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13px; color: var(--ink-3); }
.notice { display: flex; gap: 14px; margin-top: 32px; padding: 20px 22px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--surface-2); font-size: 14.5px; color: var(--ink-2); line-height: 1.7; }
.notice svg { width: 20px; height: 20px; color: var(--ink); margin-top: 2px; }

/* ---------- Command palette ---------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 12vh 16px 16px;
  background: color-mix(in srgb, var(--bg) 55%, rgba(0, 0, 0, .45));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: fadein .2s var(--ease) both;
}
.palette {
  width: min(100%, 640px);
  max-height: min(70vh, 620px);
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  border: 1px solid var(--line-2);
  background: var(--surface);
  box-shadow: var(--shadow-l);
  overflow: hidden;
  animation: pop-in .28s var(--ease-out) both;
}
.palette-input { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.palette-input svg { width: 20px; height: 20px; color: var(--ink-3); }
.palette-input input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 17px; color: var(--ink); }
.palette-input input::placeholder { color: var(--ink-3); }
.palette-results { overflow-y: auto; padding: 8px; flex: 1; }
.palette-group { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); padding: 12px 12px 6px; }
.palette-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  padding: 9px 12px;
  border-radius: 12px;
  border: 0;
  background: transparent;
  text-align: left;
  color: var(--ink);
}
.palette-item .p-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-2); font-family: var(--font-display); font-weight: 700; font-size: 13px; }
.palette-item .p-ic svg { width: 16px; height: 16px; }
.palette-item .tile { width: 34px; height: 34px; border-radius: 10px; font-size: 13px; }
.palette-item strong { display: block; font-size: 14px; font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-item small { display: block; font-size: 12px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-item mark { background: var(--accent); color: var(--accent-ink); border-radius: 3px; padding: 0 1px; }
.palette-item .p-go { opacity: 0; color: var(--ink-3); font-family: var(--font-mono); font-size: 11px; display: flex; align-items: center; gap: 6px; }
.palette-item.active { background: var(--surface-3); }
.palette-item.active .p-go { opacity: 1; }
.palette-item.active .p-ic { background: var(--ink); color: var(--bg); }
.palette-empty { padding: 36px 20px 40px; text-align: center; color: var(--ink-3); font-size: 14px; }
.palette-empty strong { display: block; color: var(--ink); font-family: var(--font-display); font-size: 18px; font-weight: 650; letter-spacing: -.02em; margin-bottom: 6px; }
.palette-foot { display: flex; gap: 16px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); background: var(--surface-2); font-size: 12px; color: var(--ink-3); }
.palette-foot span { display: inline-flex; align-items: center; gap: 6px; }
.palette-foot .kbd { margin: 0; }
.palette-foot .right { margin-left: auto; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; }
.modal-close { display: grid; width: 32px; height: 32px; border-radius: var(--r-s); border: 1px solid var(--line); background: var(--surface-2); color: var(--ink-2); place-items: center; font-size: 18px; line-height: 1; }

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 90;
  max-width: min(420px, calc(100vw - 32px));
  padding: 12px 18px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--bg);
  font-size: 13.5px;
  line-height: 1.5;
  box-shadow: var(--shadow-l);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition: opacity .25s var(--ease), transform .35s var(--ease-out);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Not found ---------- */
.lost { padding: 80px 0 40px; text-align: center; }
.lost-code { font-family: var(--font-display); font-weight: 800; font-size: clamp(110px, 18vw, 220px); line-height: .85; letter-spacing: -.07em; font-variation-settings: 'opsz' 96; color: var(--ink); }
.lost-code span { color: transparent; -webkit-text-stroke: 1.5px var(--ink-3); }
.lost h1 { font-family: var(--font-display); font-weight: 650; font-size: 28px; letter-spacing: -.03em; margin: 24px 0 10px; }
.lost p { color: var(--ink-3); margin: 0 auto 26px; max-width: 44ch; }
.lost-actions { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }

/* ---------- Motion ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop { from { opacity: 0; transform: scale(.3); } to { opacity: 1; transform: none; } }
@keyframes pop-in { from { opacity: 0; transform: translateY(-8px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes grow { from { clip-path: inset(-10% 100% -10% 0); } to { clip-path: inset(-10% -10% -10% 0); } }
@keyframes marker { to { clip-path: inset(-.1em -.1em -.1em 0); } }
@keyframes ping { 0% { transform: scale(.6); opacity: .7; } 80%, 100% { transform: scale(1.8); opacity: 0; } }
@keyframes ring { 0% { transform: scale(.7); opacity: .9; } 80%, 100% { transform: scale(2.2); opacity: 0; } }
@keyframes breathe { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
@keyframes fill { from { transform: scaleX(0); } to { transform: none; } }
@keyframes dial { from { stroke-dashoffset: var(--circ); } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .hl::after { clip-path: none; }
  .pulse-dot::after, .clado .root-ring { display: none; }
}

/* ---------- Responsive ---------- */
/* v3 research surfaces inherit the field-guide tokens and geometry. */
.model-context { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 26px; }
.toolbar, .toolbar-right, .search-field, .select-wrap { min-width: 0; max-width: 100%; }
.model-context p { max-width: 65ch; margin: 0; color: var(--ink-2); }
.model-context strong { color: var(--ink); }
.domain-controls { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 18px; margin-bottom: 32px; }
.model-select { display: flex; flex-direction: column; gap: 5px; min-width: 130px; font-size: 12px; color: var(--ink-2); }
.model-select .field-select { width: 100%; min-height: 42px; border: 1px solid var(--line-2); background: var(--surface); border-radius: var(--r-s); padding: 9px 30px 9px 12px; color: var(--ink); }
.model-filters { display: flex; flex-wrap: wrap; align-items: end; gap: 16px; margin: 0 0 20px; }
.model-filters .search-field { flex: 1 1 260px; min-height: 42px; }
.model-leaders .section-head { margin-bottom: 20px; }
.model-podium { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-2); }
.model-podium li { border-bottom: 1px solid var(--line); }
.model-podium a { display: flex; gap: 24px; align-items: center; padding: 22px 6px; }
.model-podium a:hover { background: var(--accent-soft); }
.model-podium strong { font-family: var(--font-display); font-size: 21px; }
.model-podium small { display: block; color: var(--ink-3); font-size: 12px; }
.model-podium .consensus-number { margin-left: auto; }
.consensus-number { font-family: var(--font-mono); font-size: 24px; font-weight: 500; font-variant-numeric: tabular-nums; line-height: 1.4; white-space: nowrap; }
.consensus-number small { display: inline; font-size: 12px; margin-left: 3px; color: var(--ink-3); }
.consensus-summary { font-family: var(--font-display); font-size: clamp(21px, 3vw, 34px); line-height: 1.3; margin: 18px 0 8px; }
.table-scroll { width: 100%; overflow-x: auto; margin: 20px 0; scrollbar-color: var(--line-2) var(--surface-2); scrollbar-width: thin; }
.research-table { width: 100%; border-collapse: collapse; font-size: 13px; text-align: left; }
.research-table caption { text-align: left; color: var(--ink-2); padding: 0 0 16px; font-size: 13px; }
.research-table th, .research-table td { padding: 20px 14px; border-bottom: 1px solid var(--line); vertical-align: top; min-width: 150px; }
.research-table thead th { padding-top: 12px; padding-bottom: 12px; background: var(--surface-2); color: var(--ink-2); font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; border-top: 1px solid var(--line-2); }
.research-table th[scope="row"] { min-width: 220px; font-size: 15px; }
.research-table th[scope="row"] > a { display: inline-flex; align-items: center; gap: 8px; }
.research-table th[scope="row"] > a:hover { color: var(--accent-text); }
.research-table small { display: block; font-size: 11px; font-weight: 400; color: var(--ink-3); margin: 6px 0; line-height: 1.65; }
.research-table .consensus-number small { display: inline; }
.research-table .badge { margin-top: 6px; margin-right: 5px; }
.coverage-missing { font-size: 12px; color: var(--ink-2); display: block; max-width: 19ch; }
.calculation { border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); margin: 30px 0; }
.calculation > summary { display: flex; gap: 12px; align-items: center; padding: 20px 0; cursor: pointer; font-weight: 600; list-style: none; }
.calculation > summary::before { content: '+'; font-family: var(--font-mono); width: 16px; color: var(--accent-text); }
.calculation[open] > summary::before { content: '−'; }
.calculation > summary > svg:last-child { margin-left: auto; }
.calculation > div { padding: 0 0 24px; max-width: 75ch; color: var(--ink-2); }
.calculation p { margin: 0 0 16px; }
.calculation li { margin-bottom: 10px; }
.calculation-facts, .identity-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 30px; padding: 20px 0; margin: 0; }
.calculation-facts dt, .identity-facts dt, .mutation dt { font-size: 11px; color: var(--ink-3); margin-bottom: 5px; }
.calculation-facts dd, .identity-facts dd, .mutation dd { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.research-links { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: 18px; font-size: 12px; }
.research-links a { display: inline-flex; align-items: center; gap: 5px; text-decoration: underline; text-underline-offset: 3px; color: var(--accent-text); }
.research-links a:hover { color: var(--ink); }
.evidence-notes { padding: 34px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 36px; }
.evidence-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 40px; }
.evidence-notes > h2 { margin-bottom: 28px; }
.evidence-notes h2, .model-identity h2, .test-record h2 { font-family: var(--font-display); letter-spacing: -.025em; font-size: 25px; }
.evidence-columns h3 { font-size: 15px; margin: 0 0 12px; }
.evidence-columns p, .evidence-columns li { color: var(--ink-2); margin-top: 10px; }
.evidence-columns ul { padding-left: 20px; margin: 0; }
.evidence-columns .research-links { margin-top: 6px; }
.evidence-columns .badge { white-space: normal; }
.profile-status { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; margin-bottom: 30px; font-size: 12px; color: var(--ink-2); }
.model-identity { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 24px 0; }
.model-identity > h2 { margin: 0; }
.model-identity details { margin-top: 12px; }
.domain-evidence { display: flex; flex-wrap: wrap; gap: 24px 36px; margin-bottom: 24px; }
.domain-evidence > div { display: flex; flex-direction: column; font-size: 13px; gap: 5px; }
.domain-evidence span { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.domain-evidence small { color: var(--ink-3); }
.mutation { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin: 20px 0; }
.lineage { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.lineage > span { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--ink-3); }
.lineage > a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; }
.tl-card > .badge { margin-bottom: 12px; }
.test-suite { max-width: 360px; margin: 28px 0; }
.test-record { padding: 32px 0; border-top: 1px solid var(--line-2); }
.test-record-head { display: flex; justify-content: space-between; align-items: start; flex-wrap: wrap; gap: 18px; }
.test-record-head h2 { margin: 0; }
.test-record-head p { font-size: 12px; color: var(--ink-3); }
.test-record p, .test-record li { color: var(--ink-2); max-width: 75ch; }
.test-record h3 { font-size: 15px; margin-top: 24px; }
details summary { cursor: pointer; }
pre { max-width: 100%; overflow: auto; background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r-s); padding: 18px; font: 12px/1.7 var(--font-mono); scrollbar-width: thin; }
.original-output { white-space: pre-wrap; overflow-wrap: anywhere; }
.measurement-value, .measurement-detail { display: block; }
.measurement-detail { margin-top: 8px; color: var(--ink-3); font-size: 12px; line-height: 1.65; }
.measurement-detail a { display: inline-flex; align-items: center; gap: 5px; }
.source-policies > div { margin: 24px 0; }
.source-policies h3 { margin-bottom: 8px; }
.data-error { margin: 24px var(--gutter) 0; padding: 20px; border: 1px solid var(--unverified); background: var(--unverified-bg); color: var(--ink); }
.tool-side .freshness { font-size: 9px; }
.sidebar { overflow-y: auto; scrollbar-width: thin; }
input { caret-color: var(--accent-text); }
@media (max-width: 700px) {
  .model-context { display: block; }
  .model-context > .badge { margin-top: 12px; }
  .model-filters { gap: 14px; }
  .model-filters .model-select { flex: 1 1 140px; }
  .domain-controls { gap: 18px; }
  .domain-controls > .model-select { width: 100%; }
  .evidence-columns { grid-template-columns: 1fr; gap: 24px; }
  .identity-facts, .calculation-facts { gap: 18px; }
  .mutation { grid-template-columns: 1fr; gap: 14px; }
  .model-podium a { gap: 12px; }
  .model-podium strong { font-size: 16px; }
  .model-podium .consensus-number { font-size: 19px; }
  .profile-status { gap: 10px; }
}

@media (max-width: 1280px) {
  :root { --gutter: 36px; --sidebar-w: 240px; }
  .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stat:nth-child(4) { border-left: 0; }
  .stat:nth-child(n+4) { border-top: 1px solid var(--line); }
  .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1120px) {
  .hero { grid-template-columns: 1fr; gap: 40px; padding-bottom: 44px; }
  .br-wide { display: none; }
  .hero-lede { max-width: 52ch; }
  .boards { grid-template-columns: 1fr; }
  .detail-grid { grid-template-columns: 1fr; }
  .method-layout { grid-template-columns: 1fr; gap: 8px; }
  .toc { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
  .toc-label { width: 100%; margin-bottom: 2px; }
  .toc a { grid-template-columns: auto auto; border: 1px solid var(--line); background: var(--surface); }
}
@media (max-width: 960px) {
  :root { --gutter: 24px; --topbar-h: 60px; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; transform: translateX(-104%); width: 284px; background: var(--bg); visibility: hidden; transition: transform .35s var(--ease-out), visibility 0s .35s; }
  .sidebar.open { transform: none; visibility: visible; box-shadow: var(--shadow-l); transition: transform .35s var(--ease-out); }
  .mobile-overlay.active { display: block; position: fixed; inset: 0; z-index: 25; background: rgba(0, 0, 0, .4); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: fadein .2s both; }
  .mobile-menu { display: grid; }
  .crumb-root, .crumb-sep { display: none; }
  .search-trigger { min-width: 0; }
  .search-trigger-text, .search-trigger kbd { display: none; }
  .search-trigger { width: 38px; height: 38px; padding: 0; justify-content: center; }
  .process { grid-template-columns: 1fr; gap: 4px; }
  .process::before { top: 40px; bottom: 40px; left: 40px; right: auto; width: 1px; height: auto; background: repeating-linear-gradient(180deg, var(--line-2) 0 4px, transparent 4px 9px); }
  .step { display: grid; grid-template-columns: 36px 1fr; gap: 0 18px; }
  .step-node { margin-bottom: 0; grid-row: span 2; }
  .page-head { flex-direction: column; align-items: flex-start; gap: 20px; }
  .page-head-aside { text-align: left; }
  .detail-hero { grid-template-columns: 1fr; align-items: start; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .cat-banner { flex-direction: column; align-items: flex-start; }
  .banner-stat { text-align: left; }
}
@media (max-width: 640px) {
  :root { --gutter: 16px; }
  body { font-size: 14.5px; }
  .page { padding-top: 24px; padding-bottom: 64px; }
  .read-only-label { width: 38px; padding: 0; justify-content: center; font-size: 0; gap: 0; letter-spacing: 0; }
  .hero { padding-top: 8px; }
  .hero-title { font-size: clamp(42px, 12.5vw, 56px); margin: 18px 0 18px; }
  .hero-lede { font-size: 16px; }
  .hero-actions .btn { flex: 1 1 auto; }
  .plate { padding: 14px 12px 12px; }
  .plate-head span:last-child { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); border-radius: 16px; }
  .stat { padding: 18px 16px 16px; border-left: 1px solid var(--line); border-top: 1px solid var(--line); }
  .stat:nth-child(1), .stat:nth-child(2) { border-top: 0; }
  .stat:nth-child(odd) { border-left: 0; }
  .stat:nth-child(4) { border-left: 1px solid var(--line); }
  .stat:last-child { grid-column: 1 / -1; border-left: 0; }
  .stat-num { margin-top: 14px; }
  .section { margin-top: 56px; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .section-head h2 { font-size: 23px; }
  .cat-grid { grid-template-columns: 1fr; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .search-field { max-width: none; flex: none; }
  .toolbar-right { flex-direction: column; align-items: stretch; }
  .seg { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .seg::-webkit-scrollbar { display: none; }
  .seg-btn { flex: none; }
  .field-select { width: 100%; }
  .tool-row { grid-template-columns: 42px minmax(0, 1fr); gap: 14px; padding: 14px; }
  .tool-row .tile { width: 42px; height: 42px; border-radius: 12px; font-size: 15px; }
  .tool-side { grid-column: 2; justify-content: space-between; }
  .tool-side .chev { display: none; }
  .score { flex-direction: row-reverse; align-items: center; gap: 10px; min-width: 0; }
  .score .bar { width: 60px; }
  .tool-summary { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .note-row, .origin-row, .awaiting-row { grid-template-columns: 1fr; gap: 6px; }
  .note-row { grid-template-columns: 1fr auto; }
  .note-row .note-date { grid-column: 1 / -1; }
  .detail-id { flex-direction: column; gap: 14px; }
  .detail-side { flex-wrap: wrap; }
  .pro-con { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .panel { padding: 20px; }
  .podium { grid-template-columns: 1fr; gap: 12px; }
  .pedestal { display: grid; grid-template-columns: 56px 1fr; }
  .pedestal.p1 { order: -1; }
  .pedestal-card { border-radius: 0 16px 16px 0; border-bottom: 1px solid var(--line); border-left: 0; min-height: 0; }
  .pedestal-card.vacant { border-left: 1px dashed var(--line-2); border-bottom: 1px dashed var(--line-2); min-height: 64px; }
  .pedestal-base, .pedestal.p1 .pedestal-base, .pedestal.p2 .pedestal-base, .pedestal.p3 .pedestal-base { height: auto; order: -1; border-radius: 16px 0 0 16px; align-items: center; padding-top: 0; font-size: 24px; }
  .board-row { grid-template-columns: 30px minmax(0, 1fr) 70px 36px; }
  .board-row .badge { display: none; }
  .timeline::before { left: 5px; }
  .tl-month { padding-left: 28px; }
  .tl-item { grid-template-columns: 1fr; gap: 6px; padding-left: 28px; }
  .tl-item::before { left: 0; top: 4px; }
  .tl-date { text-align: left; padding-top: 0; }
  .evidence-scale { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article h2 { font-size: 24px; }
  .article p { font-size: 15px; }
  .cat-banner { padding: 24px 20px; }
  .banner-stats { gap: 20px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
  .palette-foot .right { display: none; }
  .modal-backdrop { padding-top: 8vh; }
  .modal-close { display: grid; width: 32px; height: 32px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink-2); place-items: center; font-size: 18px; line-height: 1; }
}

/* v4 — clarity-first editorial layout */
.v4-home .v4-hero{padding:60px 0 52px;border-bottom:1px solid var(--line-2)}
.v4-kicker{font:600 11px/1.4 var(--font-mono);letter-spacing:.11em;color:var(--ink-3)}
.v4-hero h1{font:750 clamp(50px,7.2vw,94px)/1.02 var(--font-display);letter-spacing:-.065em;margin:28px 0 23px;max-width:18ch}
.v4-hero h1 em{color:var(--accent-text);font-style:normal}
.v4-hero>p{font-size:clamp(17px,1.6vw,21px);max-width:690px;color:var(--ink-2);line-height:1.55;margin:0 0 32px}
.v4-hero-links{display:flex;flex-wrap:wrap;align-items:center;gap:18px}
.v4-search-btn{display:flex;align-items:center;gap:14px;text-align:left;min-height:58px;width:min(520px,100%);padding:15px 18px;border:1px solid var(--line-2);border-radius:13px;background:var(--surface);color:var(--ink-2);box-shadow:var(--shadow-s)}
.v4-search-btn:hover,.v4-search-btn:focus-visible{border-color:var(--accent-text);box-shadow:0 0 0 3px var(--accent-soft)}
.v4-search-btn kbd{margin-left:auto;border:1px solid var(--line-2);border-radius:5px;padding:2px 7px;font:11px var(--font-mono)}
.v4-link{display:inline-flex;align-items:center;gap:9px;font-size:13px;font-weight:650;color:var(--ink)}
.v4-link:hover{color:var(--accent-text)}
.v4-summary{display:flex;flex-wrap:wrap;gap:11px 22px;margin-top:25px;color:var(--ink-3);font:11px var(--font-mono)}
.v4-summary span+span:before{content:'·';margin-right:22px;color:var(--ink-4)}
.v4-section{margin-top:75px}
.v4-section-head{display:flex;align-items:end;justify-content:space-between;gap:24px;margin-bottom:26px}
.v4-section h2{font:700 clamp(26px,3.5vw,40px)/1.15 var(--font-display);letter-spacing:-.045em;margin:13px 0}
.v4-section p{color:var(--ink-2);font-size:14px;max-width:600px;margin:0}
.v4-tiles{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.v4-tile{display:flex;flex-direction:column;min-height:211px;min-width:0;padding:23px;border:1px solid var(--line);background:var(--surface);border-radius:16px;transition:transform .16s,border-color .16s}
.v4-tile:hover{transform:translateY(-3px);border-color:var(--ink-3)}
.v4-tile-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:25px}
.v4-tile-top>span{width:40px;height:40px;display:grid;place-items:center;border-radius:11px;background:var(--accent-soft);color:var(--accent-text)}
.v4-tile-top small{font:11px var(--font-mono);color:var(--ink-3)}
.v4-tile h3{margin:0 0 7px;font:700 21px/1.15 var(--font-display);letter-spacing:-.025em}
.v4-tile p{font-size:13px;line-height:1.5;margin:0}
.v4-tile-bottom{display:flex;align-items:center;justify-content:space-between;margin-top:auto;padding-top:24px;color:var(--ink-3);font:11px var(--font-mono)}
.v4-tile-bottom svg{color:var(--ink)}
.v4-split{display:grid;grid-template-columns:1fr 1fr;gap:34px;align-items:center}
.v4-split>.v4-flow{padding:25px;background:var(--surface-2);border:1px solid var(--line);border-radius:16px}
.v4-split>div:first-child p{margin:0 0 25px}
.v4-flow>span{font:11px var(--font-mono);color:var(--ink-3)}
.v4-flow>a{display:flex;align-items:center;justify-content:space-between;padding:19px;border:1px solid var(--line-2);border-radius:10px;background:var(--surface);margin-top:20px;font-weight:650}
.v4-flow>div{display:grid;grid-template-columns:1fr 1fr;gap:11px;margin-top:23px}
.v4-flow>div>a{border:1px solid var(--line-2);border-radius:10px;background:var(--surface);padding:17px 10px;text-align:center;font-size:13px;font-weight:600}
.v4-flow>p{margin-top:18px;font-size:12px;color:var(--ink-3)}
.v4-feed{border:1px solid var(--line);border-radius:14px;overflow:hidden}
.v4-feed>a{display:grid;grid-template-columns:135px 1fr 18px;align-items:center;gap:20px;padding:18px 21px;border-bottom:1px solid var(--line);background:var(--surface)}
.v4-feed>a:last-child{border-bottom:0}.v4-feed>a:hover{background:var(--surface-2)}
.v4-feed time{font:11px var(--font-mono);color:var(--ink-3)}
.v4-feed strong,.v4-feed small{display:block}
.v4-feed strong{font-size:14px}.v4-feed small{font-size:11px;color:var(--ink-3);margin-top:5px;text-transform:capitalize}
.v4-clarity{display:flex;align-items:start;gap:16px;padding:23px;margin-top:72px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2);font-size:13px;color:var(--ink-2)}
.v4-clarity svg{flex:none;color:var(--accent-text)}.v4-clarity p{margin:0}.v4-clarity a{color:var(--ink);text-decoration:underline;text-underline-offset:3px}
.v4-index .v4-tiles{margin-top:28px}.v4-more-links{display:flex;flex-wrap:wrap;gap:22px;margin-top:28px;font-size:13px;font-weight:600}.v4-more-links a{display:flex;gap:8px;align-items:center}
.v4-explainer{padding:20px;margin:14px 0 24px;border:1px solid var(--line);border-radius:12px;background:var(--surface-2);color:var(--ink-2);font-size:13px}
.v4-makers{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:28px}
.v4-makers>a{display:flex;align-items:center;gap:15px;min-width:0;background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:18px}.v4-makers>a:hover,.v4-version-list>a:hover{border-color:var(--ink-3);background:var(--surface-2)}
.v4-avatar{flex:none;display:grid;place-items:center;width:43px;height:43px;border-radius:11px;background:var(--surface-3);font:700 13px var(--font-mono)}
.v4-makers>a>span:nth-child(2){flex:1;min-width:0}.v4-makers strong,.v4-makers small{display:block}.v4-makers strong{font-size:14px}.v4-makers small{font-size:11px;color:var(--ink-3);margin-top:5px;line-height:1.4}
.v4-version-list{border:1px solid var(--line);border-radius:12px;overflow:hidden}.v4-version-list>a{display:grid;grid-template-columns:1fr 1fr 17px;align-items:center;gap:15px;background:var(--surface);padding:19px;border-bottom:1px solid var(--line)}.v4-version-list>a:last-child{border-bottom:0}
.v4-version-list strong{font-size:14px}.v4-version-list span{font-size:12px;color:var(--ink-2)}
.v4-subnote{display:block;color:var(--accent-text);font-size:11px;margin-top:8px}.v4-source-note{font:11px var(--font-mono);color:var(--ink-3)}
.tool-row .pills,.tool-row .badge.unevaluated,.tool-side .freshness{display:none}.tool-side{gap:14px}
.detail-hero .detail-side .dial:empty{display:none}.detail-grid .pro-con:has(>section:only-child){grid-template-columns:1fr}
@media(max-width:1100px){.v4-tiles{grid-template-columns:repeat(2,minmax(0,1fr))}.v4-split{grid-template-columns:1fr}}
@media(max-width:650px){.v4-tiles,.v4-makers{grid-template-columns:1fr}.v4-tile{min-height:177px}.v4-tile-top{margin-bottom:15px}.v4-hero h1{font-size:clamp(44px,11vw,65px)}.v4-home .v4-hero{padding:26px 0 40px}.v4-section{margin-top:53px}.v4-section-head{flex-direction:column;align-items:flex-start;gap:10px}.v4-feed>a{grid-template-columns:1fr 16px;gap:8px;padding:17px}.v4-feed time{grid-column:1/-1}.v4-version-list>a{grid-template-columns:1fr 16px}.v4-version-list>a span{grid-row:2;grid-column:1}.v4-version-list>a svg{grid-column:2;grid-row:1}.v4-summary span+span:before{content:none}.v4-search-btn{width:100%}.v4-search-btn kbd{display:none}.v4-clarity{padding:17px;margin-top:45px}}
