/* Emerging Trends in AI Agent Evaluation: project page.
   Palette follows the paper (accent #1F4E79); chart series colors are
   validated for color-vision deficiency in both themes. */

:root {
  --bg: #fbfbfa;
  --bg-alt: #f4f5f4;
  --surface: #ffffff;
  --surface-2: #f3f4f5;
  --surface-3: #e8ebee;
  --ink: #1b1d20;
  --ink-2: #444a52;
  --muted: #69707a;
  --line: #d6dade;
  --hair: #e6e8eb;
  --accent: #1f4e79;
  --accent-ink: #1f4e79;
  --accent-strong: #163a5b;
  --accent-wash: #edf2f8;
  --accent-wash-2: #d9e5f1;
  --on-accent: #ffffff;
  --s1: #2f6fae;
  --s2: #c9661a;
  --risk: #b3261e;
  --risk-wash: #fbecea;
  --ok: #2f6fae;
  --shadow: 0 1px 2px rgba(20, 30, 40, .05), 0 6px 24px rgba(20, 30, 40, .06);
  --shadow-pop: 0 4px 10px rgba(20, 30, 40, .10), 0 18px 40px rgba(20, 30, 40, .12);

  --serif: "Charter", "Bitstream Charter", "Sitka Text", Cambria, "Iowan Old Style", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --radius: 12px;
  --radius-sm: 8px;
  --topbar-h: 56px;
  --sec-space: clamp(44px, 4vw + 28px, 64px); /* padding above and below each full-width section */
  --maxw: 1480px;
  --gutter: clamp(20px, 3.2vw, 48px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121417;
    --bg-alt: #16191d;
    --surface: #1a1d22;
    --surface-2: #20242a;
    --surface-3: #2a2f37;
    --ink: #e7e9ec;
    --ink-2: #bcc2ca;
    --muted: #8e96a0;
    --line: #353b44;
    --hair: #272c33;
    --accent: #8fb9e6;
    --accent-ink: #9cc3ec;
    --accent-strong: #b9d4f1;
    --accent-wash: #1b2633;
    --accent-wash-2: #233649;
    --on-accent: #0d1824;
    --s1: #4c8ed8;
    --s2: #d4782a;
    --risk: #ef7d73;
    --risk-wash: #36201e;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 24px rgba(0, 0, 0, .25);
    --shadow-pop: 0 4px 10px rgba(0, 0, 0, .35), 0 18px 40px rgba(0, 0, 0, .4);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #121417;
  --bg-alt: #16191d;
  --surface: #1a1d22;
  --surface-2: #20242a;
  --surface-3: #2a2f37;
  --ink: #e7e9ec;
  --ink-2: #bcc2ca;
  --muted: #8e96a0;
  --line: #353b44;
  --hair: #272c33;
  --accent: #8fb9e6;
  --accent-ink: #9cc3ec;
  --accent-strong: #b9d4f1;
  --accent-wash: #1b2633;
  --accent-wash-2: #233649;
  --on-accent: #0d1824;
  --s1: #4c8ed8;
  --s2: #d4782a;
  --risk: #ef7d73;
  --risk-wash: #36201e;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 24px rgba(0, 0, 0, .25);
  --shadow-pop: 0 4px 10px rgba(0, 0, 0, .35), 0 18px 40px rgba(0, 0, 0, .4);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--topbar-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
a { color: var(--accent-ink); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 700; line-height: 1.2; margin: 0; letter-spacing: -0.005em; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }

.skip { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--accent); color: var(--on-accent); padding: 8px 14px; border-radius: 6px; font-family: var(--sans); font-size: 14px; }
.skip:focus { top: 12px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: max(var(--gutter), env(safe-area-inset-left, 0px)); }
.wrap.narrow { max-width: 1100px; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  padding-top: env(safe-area-inset-top, 0px);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.topbar.scrolled { border-bottom-color: var(--hair); }
.topbar-inner {
  max-width: var(--maxw); margin: 0 auto; height: var(--topbar-h);
  padding-inline: max(var(--gutter), env(safe-area-inset-left, 0px));
  display: flex; align-items: center; gap: 20px;
  font-family: var(--sans); font-size: 14px;
}
.brand {
  color: var(--ink); text-decoration: none; font-family: var(--serif); font-weight: 700; font-size: 16px; min-width: 0; flex: 0 1 auto;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0; transform: translateY(4px); transition: opacity .25s, transform .25s;
}
.topbar.scrolled .brand { opacity: 1; transform: none; }
/* The SAgE group, linking to its home page: in the top bar, or above the title on phones */
.lab { display: inline-flex; align-items: center; gap: 8px; flex: none; color: var(--ink); text-decoration: none; font-family: var(--sans); font-size: 15px; }
/* "SAgE Science of Agent Evaluation"; once the page scrolls, the full name slides away and "SAgE" stays */
.lab-acr { font-weight: 700; }
.lab-full { color: var(--ink-2); white-space: nowrap; overflow: hidden; max-width: 16em; transition: max-width .4s ease, opacity .25s ease, margin .4s ease; }
.topbar.scrolled .lab-full { max-width: 0; opacity: 0; margin-left: -8px; }
@media (max-width: 939px) { .topbar .lab-full { display: none; } } /* too narrow for the full name next to the links */
.lab img { width: 26px; height: 26px; }
.lab:hover { color: var(--accent-ink); }
.lab + .brand { padding-left: 18px; border-left: 1px solid var(--line); }
.hero-lab { display: none; }
.toc { display: flex; gap: 2px; margin-left: auto; overflow-x: auto; scrollbar-width: none; flex-shrink: 0; } /* the title beside the logo gives way first */
.toc::-webkit-scrollbar { display: none; }
.toc a { color: var(--ink-2); text-decoration: none; padding: 6px 10px; border-radius: 999px; white-space: nowrap; transition: background .15s, color .15s; }
.toc a:hover { background: var(--surface-2); color: var(--ink); }
.toc a.active { color: var(--accent-ink); background: var(--accent-wash); }
.toc.more-right { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent); }
.toc.more-left { -webkit-mask-image: linear-gradient(to left, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(to left, #000 calc(100% - 36px), transparent); }
.toc.more-left.more-right {
  -webkit-mask-image: linear-gradient(to right, transparent, #000 36px, #000 calc(100% - 36px), transparent);
  mask-image: linear-gradient(to right, transparent, #000 36px, #000 calc(100% - 36px), transparent);
}
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px; flex: none;
  border: 1px solid var(--line); background: var(--surface); border-radius: 999px; color: var(--ink-2);
  font-family: var(--sans); font-size: 18px; line-height: 1;
}
.icon-btn:hover { border-color: var(--muted); color: var(--ink); }
.icon-btn:disabled { opacity: .4; cursor: default; }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.theme-toggle .i-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .i-sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .i-moon { display: block; }
}
@media (max-width: 760px) {
  .brand, .topbar .lab { display: none; }
  .hero-lab { display: inline-flex; margin-bottom: 18px; color: var(--ink-2); }
  .hero-lab img { width: 28px; height: 28px; }
  .toc { margin-left: 0; flex: 1; }
  .toc a { padding: 6px 6px; }
}

/* ---------- Hero ---------- */
.hero { padding-block: calc(var(--sec-space) - 8px) var(--sec-space); text-align: center; }
.hero h1 { font-size: clamp(2.2rem, 5.2vw, 3.6rem); line-height: 1.08; letter-spacing: -0.015em; max-width: 15em; margin: 0 auto 22px; text-wrap: balance; }
.authors { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 22px; max-width: 64rem; margin: 0 auto 10px; font-size: 1.12rem; }
.affil { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 18px; max-width: 46rem; margin: 0 auto 30px; color: var(--muted); font-size: .95rem; }
.authors sup, .affil sup { font-size: .62em; line-height: 0; margin-left: 1px; }
.affil sup { margin: 0 2px 0 0; }
.affil:has(+ .contact) { margin-bottom: 16px; }
.contact { max-width: 46rem; margin: 0 auto 30px; color: var(--muted); font-size: .95rem; text-align: center; }
.contact sup { font-size: .62em; line-height: 0; margin-right: 2px; }
.contact .emails { font-family: var(--mono); font-size: .86em; }
.contact a { color: var(--ink-2); text-decoration-color: var(--line); text-underline-offset: 2px; }
.contact a:hover { color: var(--accent-ink); text-decoration-color: currentColor; }
.row-break { flex-basis: 100%; height: 0; margin-top: -4px; }
@media (max-width: 640px) { .row-break { display: none; } }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: clamp(32px, 2vw + 24px, 44px); }
.hero-actions:last-child { margin-bottom: 0; } /* nothing follows the buttons while the summary is hidden */
.abstract { max-width: 1000px; margin: 0 auto; text-align: left; }
.abstract .label { font-family: var(--sans); font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; text-align: center; margin-bottom: 12px; }
.abstract p { font-size: 1.04rem; color: var(--ink-2); hyphens: auto; }

/* ---------- Buttons & controls ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--sans); font-size: 15px; font-weight: 550; line-height: 1;
  padding: 11px 18px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  text-decoration: none; transition: background .15s, border-color .15s, transform .1s, box-shadow .15s;
}
.btn:hover { border-color: var(--muted); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.btn-small { font-size: 13.5px; padding: 8px 13px; gap: 6px; }
.btn-small svg { width: 14px; height: 14px; }
.btn-quiet { background: transparent; }
#agent-run svg { fill: currentColor; stroke: none; }

.ctl-label { font-family: var(--sans); font-size: 12.5px; font-weight: 600; letter-spacing: .02em; color: var(--muted); }
.seg { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 3px; background: var(--surface-2); border-radius: 999px; border: 1px solid var(--hair); }
.seg button {
  border: 0; background: transparent; color: var(--ink-2); font-family: var(--sans); font-size: 14px; font-weight: 550;
  padding: 7px 14px; border-radius: 999px; transition: background .15s, color .15s, box-shadow .15s;
}
.seg button:hover { color: var(--ink); }
.seg button[aria-checked="true"], .seg button[aria-pressed="true"] { background: var(--surface); color: var(--accent-ink); box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 0 0 1px var(--line); }
.seg-sm button { font-size: 13px; padding: 6px 11px; }
/* Phones: a pill that wraps looks broken, so the options form an even grid instead */
@media (max-width: 640px) {
  .seg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; box-sizing: border-box; border-radius: 14px; }
  .seg button { border-radius: 10px; text-align: center; line-height: 1.3; }
  .seg > button:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .seg:has(> button:nth-child(3):last-child) { grid-template-columns: minmax(0, 1fr); }
}
.stepper { display: inline-flex; align-items: center; gap: 8px; }
.stepper .icon-btn { width: 30px; height: 30px; font-size: 17px; }
.stepper output { font-family: var(--sans); font-weight: 650; font-size: 15px; min-width: 1.4em; text-align: center; font-variant-numeric: tabular-nums; }
.slider { display: inline-flex; flex-direction: column; gap: 4px; min-width: 200px; }
.slider output { color: var(--ink); font-variant-numeric: tabular-nums; }
input[type="range"] { accent-color: var(--accent); width: 100%; margin: 0; height: 22px; }

/* ---------- Sections ---------- */
.section { padding-block: var(--sec-space); scroll-margin-top: -16px; } /* full-width bands land flush under the top bar */
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--hair); }
/* Phones: the reference sections (terms, references, citation) and the links to them are left out */
@media (max-width: 720px) {
  #terms, #references, #cite, .toc a[href="#terms"], .toc a[href="#cite"], .hero-actions a[href="#cite"], .pop-all { display: none; }
}
.sec-head, .part-head { margin-bottom: clamp(28px, 1.5vw + 22px, 36px); }
.eyebrow { font-family: var(--sans); font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-ink); font-weight: 650; margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.part-num { background: var(--accent); color: var(--on-accent); padding: 3px 9px; border-radius: 999px; letter-spacing: .06em; font-size: 12px; }
.sec-head h2, .part-head h2 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); margin-bottom: 16px; }
.lede { font-size: 1.08rem; color: var(--ink-2); margin: 0; }
.chip {
  display: inline-flex; align-items: baseline; gap: 6px; font-family: var(--sans); font-size: 13px; line-height: 1.2;
  padding: 6px 11px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-2); text-decoration: none; transition: border-color .15s, color .15s, background .15s;
}
.chip b { color: var(--accent-ink); font-weight: 700; }
.chip:hover { border-color: var(--accent); color: var(--ink); text-decoration: none; }

/* ---------- Overview cards ---------- */
.dims { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-bottom: 40px; }
@media (max-width: 860px) { .dims { grid-template-columns: minmax(0, 1fr); } }
.dim {
  display: flex; flex-direction: column; gap: 10px; padding: 24px 24px 20px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none;
  box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s, border-color .18s;
}
.dim:hover { transform: translateY(-2px); box-shadow: var(--shadow-pop); border-color: var(--accent); text-decoration: none; }
.dim-q { font-size: 2.1rem; font-weight: 700; color: var(--accent-ink); line-height: 1; }
.dim-title { font-weight: 700; font-size: 1.15rem; }
.dim-text { color: var(--ink-2); font-size: .98rem; flex: 1; }
.dim-meta { font-family: var(--sans); font-size: 13px; color: var(--muted); border-top: 1px solid var(--hair); padding-top: 12px; }
.dim-meta b { color: var(--ink); }

/* ---------- Figures ---------- */
.figure {
  margin: 0 0 28px; padding: 28px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
}
@media (max-width: 640px) { .figure { padding: 20px 16px; } }
.fig-head { margin-bottom: 18px; }
.tag { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); background: var(--accent-wash); border-radius: 4px; padding: 3px 7px; }
.fig-title { font-size: 1.3rem; margin-bottom: 8px; }
.tag-quiet { color: var(--muted); background: var(--surface-2); }
.fig-lede { color: var(--ink-2); font-size: 1rem; margin: 0; }
.fig-controls { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 26px; margin-bottom: 18px; }
.figure figcaption { font-family: var(--sans); font-size: 13px; color: var(--muted); margin-top: 16px; line-height: 1.5; }
.fig-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; position: relative; }
.diagram svg { display: block; width: 100%; height: auto; min-width: 640px; }
.diagram-wide svg { max-width: 1100px; margin: 0 auto; }
.callout {
  margin-top: 18px; padding: 14px 18px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--accent-wash); border-left: 3px solid var(--accent);
  font-size: 1rem; color: var(--ink);
}
.callout:empty { display: none; }
.callout b { color: var(--accent-ink); }
.split { display: grid; gap: 28px; align-items: start; }
.split-passk { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.split-pareto { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.split-factorial { grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 36px; }
.split-cost { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.split-scope { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; }
.split-security { grid-template-columns: minmax(0, 1fr); gap: 18px; }
@media (max-width: 920px) { .split { grid-template-columns: minmax(0, 1fr) !important; } }
.fig-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 24px; }
@media (max-width: 920px) { .fig-pair { grid-template-columns: minmax(0, 1fr); } }

/* SVG text & shapes shared by all diagrams */
.svg-fig text { font-family: var(--sans); fill: var(--ink); font-size: 13px; }
.svg-fig .t-muted { fill: var(--muted); font-size: 11.5px; }
.svg-fig .t-bold { font-weight: 650; }
.svg-fig .t-accent { fill: var(--accent-ink); font-weight: 650; }
.svg-fig .box { fill: var(--surface); stroke: var(--line); stroke-width: 1.2; }
.svg-fig .box-key { fill: var(--accent-wash); stroke: var(--accent); stroke-width: 1.4; }
.svg-fig .box-sys { fill: var(--accent-wash); stroke: var(--accent); stroke-width: 1.4; fill-opacity: .55; }
.svg-fig .zone { fill: none; stroke: var(--line); stroke-width: 1.2; stroke-dasharray: 5 4; }
.svg-fig .flow { stroke: var(--muted); stroke-width: 1.4; fill: none; }
.svg-fig .flow-head { fill: var(--muted); }
.svg-fig .flow.dashed { stroke-dasharray: 5 4; }
.svg-fig .hi .flow, .svg-fig .flow.hi { stroke: var(--accent); stroke-width: 2.4; }
.svg-fig .hi .flow-head, .svg-fig .flow-head.hi { fill: var(--accent); }
.svg-fig .dim-g { opacity: .28; transition: opacity .2s; }
.svg-fig g { transition: opacity .2s; }

/* Model vs agent diagram */
.diagram .agent-dot { fill: var(--s2); stroke: var(--surface); stroke-width: 2; }
.diagram .traj-tick { fill: var(--s1); }
.diagram .grader-on { fill: var(--accent-wash-2); stroke: var(--accent); }
.diagram .human-pulse { stroke: var(--s2) !important; stroke-width: 2.4 !important; }
.diagram .step-label { font-weight: 650; fill: var(--accent-ink); }
.mode-layer { transition: opacity .35s ease; }

/* ---------- Trend reader: sticky index + trends ---------- */
.trends { padding-bottom: calc(var(--sec-space) + 16px); }
.tr-layout { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; }
.tr-main { min-width: 0; container-type: inline-size; }

/* Index panel */
.rail {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px 0 12px; font-family: var(--sans); margin-bottom: 28px;
  display: flex; flex-direction: column;
}
.rail-tools { padding: 0 16px; display: flex; flex-direction: column; gap: 14px; }
.rail-label { font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 0 7px; }
.search { position: relative; display: flex; align-items: center; }
.search svg { position: absolute; left: 12px; width: 16px; height: 16px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.search input {
  width: 100%; font-family: var(--sans); font-size: 14px; padding: 8px 12px 8px 35px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--bg); outline: none; transition: border-color .15s, box-shadow .15s;
}
.search input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-wash-2); }
.ex-goals { display: flex; flex-wrap: wrap; gap: 5px; }
.goal {
  font-family: var(--sans); font-size: 12.5px; font-weight: 550; padding: 5px 10px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); transition: background .15s, border-color .15s, color .15s;
}
.goal:hover { border-color: var(--accent); color: var(--ink); }
.goal[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.ex-status { font-size: 13px; color: var(--ink-2); line-height: 1.45; background: var(--accent-wash); border-radius: var(--radius-sm); padding: 10px 12px; }
.ex-status a { font-weight: 600; }
.st-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.st-actions .btn { white-space: nowrap; }
.st-actions .btn { padding: 6px 11px; font-size: 12.5px; }
.rail-progress { display: flex; align-items: center; gap: 10px; padding: 12px 16px 6px; margin-top: 14px; border-top: 1px solid var(--hair); font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.rp-bar { flex: 1; height: 4px; background: var(--surface-3); border-radius: 2px; overflow: hidden; }
.rp-bar i, .nb-bar i { display: block; height: 100%; width: 0; background: var(--accent); border-radius: 2px; transition: width .3s ease; }
.rail-list { padding: 4px 0; overscroll-behavior: contain; scrollbar-width: thin; }
.rl-part { padding-bottom: 6px; }
.rl-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 8px; padding: 8px 16px 5px; text-decoration: none; color: var(--ink); border-radius: 6px; }
.rl-head b { font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.rl-head span { font-size: 12.5px; color: var(--muted); grid-column: 1; }
.rl-head .gdot { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.rl-head:hover span { color: var(--ink); }
.rl-head.is-active b { text-decoration: underline; text-underline-offset: 3px; }
.rl-item {
  display: grid; grid-template-columns: 1.9em minmax(0, 1fr) auto; gap: 7px; align-items: center;
  margin-left: 18px; padding: 3.5px 16px 3.5px 10px; border-left: 2px solid var(--hair);
  font-size: 13.5px; line-height: 1.3; color: var(--ink-2); text-decoration: none; transition: background .12s, color .12s, opacity .2s, border-color .25s;
}
.rl-item .code { font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.rl-item .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* The goal-dot column only takes space once a goal is picked */
.rl-item > .gdot { display: none; }
.has-goal .rl-item { grid-template-columns: 1.9em minmax(0, 1fr) auto 8px; }
.has-goal .rl-item > .gdot { display: block; }
.rl-item:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.rl-item.is-past { border-left-color: var(--accent); }
.rl-item.is-past .code { color: var(--accent-ink); }
.rl-item.is-active { border-left-color: var(--accent); background: var(--accent-wash); color: var(--ink); font-weight: 650; }
.rl-item.is-active .code { color: var(--accent-ink); }
.rl-item.is-dim { opacity: .36; }
.rl-item.is-dim:hover { opacity: .8; }
.gdot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.is-start > .gdot, .gdot.g-start { background: var(--accent); }
.is-also > .gdot, .gdot.g-also { box-shadow: inset 0 0 0 1.6px var(--accent); }
.rail-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 6px 0 0; padding: 10px 16px 0; border-top: 1px solid var(--hair); font-size: 12px; color: var(--muted); }
.rail-legend span { display: inline-flex; align-items: center; gap: 6px; }

/* Wide screens: the index stays put while the trends scroll by */
@media (min-width: 1100px) {
  .tr-layout { grid-template-columns: 290px minmax(0, 1fr); column-gap: clamp(36px, 4vw, 64px); }
  .rail {
    position: sticky; top: calc(var(--topbar-h) + 18px); margin-bottom: 0;
    max-height: calc(100vh - var(--topbar-h) - 36px); max-height: calc(100dvh - var(--topbar-h) - 36px);
  }
  .rail-list { flex: 1 1 auto; min-height: 120px; overflow-y: auto; }
  .now-bar { display: none !important; }
}
/* Narrower screens: the index sits above the trends, and a slim bar keeps your place */
@media (max-width: 1099px) {
  .rail-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 12px; padding: 8px 4px 0; }
  .rail-progress { display: none; }
  .rl-item { margin-left: 12px; }
}
/* Phones: the index keeps only search and goals; each trend card carries its own status and goal tag */
@media (max-width: 720px) {
  .rail-list, .rail .rail-legend, .rail .switch { display: none; }
  .rail { padding-bottom: 16px; }
}
.now-bar {
  position: sticky; top: var(--topbar-h); z-index: 20; display: flex; align-items: center; gap: 10px;
  margin: 0 calc(-1 * var(--gutter)) 8px; padding: 8px var(--gutter);
  background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hair); font-family: var(--sans); font-size: 13.5px;
  opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s;
}
.now-bar.on { opacity: 1; visibility: visible; }
.nb-code { font-weight: 800; color: var(--on-accent); background: var(--accent); border-radius: 5px; padding: 1px 7px; font-size: 12.5px; white-space: nowrap; }
.nb-name { flex: 1 1 auto; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
/* fixed sizes, so the fill does not shift as trend names change length */
.nb-bar { flex: none; width: clamp(80px, 20vw, 200px); height: 4px; background: var(--surface-3); border-radius: 2px; overflow: hidden; }
.nb-ring { display: none; width: 22px; height: 22px; flex: none; transform: rotate(-90deg); fill: none; stroke-width: 3; }
.nb-ring circle { stroke: var(--surface-3); }
.nb-ring .nb-fill { stroke: var(--accent); stroke-dasharray: 0 51; transition: stroke-dasharray .3s ease; }
@media (max-width: 720px) { .nb-bar { display: none; } .nb-ring { display: block; } }
.nb-narrow { display: none; }
@media (max-width: 720px) { .nb-wide { display: none; } .nb-narrow { display: inline; } }
.nb-index { font-weight: 600; text-decoration: none; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-2); }

/* Parts inside the reader */
.part + .part { margin-top: clamp(72px, 4vw + 56px, 96px); }
.part-head { max-width: none; margin-bottom: 32px; }
.part-head .lede + .lede { margin-top: 14px; }
.part-head h2 { font-size: clamp(1.8rem, 3.2vw, 2.4rem); margin-bottom: 16px; }
.group-head { margin-top: 64px; padding-top: 40px; border-top: 1px solid var(--line); }
.group-head .eyebrow { margin-bottom: 8px; }
.group-head h3 { font-size: clamp(1.4rem, 2.4vw, 1.75rem); margin-bottom: 12px; }
.group-head .lede { margin-bottom: 24px; }

/* One trend */
.tcard { position: relative; margin-top: 56px; padding-top: 44px; border-top: 1px solid var(--line); scroll-margin-top: calc(var(--topbar-h) + 16px); }
.tc-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; font-family: var(--sans); font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.tc-code { font-weight: 800; font-size: 14px; color: var(--on-accent); background: var(--accent); border-radius: 6px; padding: 2px 9px; text-decoration: none; }
.tc-code:hover { background: var(--accent-strong); text-decoration: none; }
.tc-goal { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; color: var(--accent-ink); background: var(--accent-wash); border-radius: 999px; padding: 3px 10px; }
.tcard h3 { font-size: clamp(1.45rem, 2.3vw, 1.85rem); line-height: 1.22; margin-bottom: 24px; }
.tc-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
@container (min-width: 760px) { .tc-grid { grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 40px; align-items: start; } }
.tc-label { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.tc-shift, .tc-first { font-size: 1.05rem; margin-bottom: 14px; }
.tc-text > :last-child { margin-bottom: 0; }
.tcard .figure { margin: 32px 0 0; }
.tc-extra { margin-top: 28px; font-family: var(--sans); font-size: 14px; }
.tc-events { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.tc-marks { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 32px; } /* side by side, wrapping only when there is no room */
.tc-marks li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 10px; align-items: start; color: var(--ink-2); }
.tc-marks .mk { width: 18px; height: 18px; margin-top: 1px; }
.tc-marks .mk-h::after { width: 7px; height: 4px; border-width: 1.8px; }
.tc-marks .mk-r::after { font-size: 12px; }
.tc-events button {
  display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: 10px; width: 100%; text-align: left;
  border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius-sm); padding: 8px 12px; color: var(--ink-2); transition: border-color .15s;
}
.tc-events button:hover { border-color: var(--accent); color: var(--ink); }
.tc-events .d { font-weight: 700; color: var(--accent-ink); }
.tc-toggle {
  position: absolute; right: 0; top: 40px; font-family: var(--sans); font-size: 13px; font-weight: 550;
  border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 4px 12px; color: var(--ink-2);
}
.tc-toggle:hover { border-color: var(--accent); color: var(--ink); }
.tcard.is-collapsed { margin-top: 10px; padding-top: 10px; border-top-color: var(--hair); }
.tcard.is-collapsed .tc-body { display: none; }
.tcard.is-collapsed .tc-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; cursor: pointer; }
.tcard.is-collapsed .tc-meta { margin: 0; }
.tcard.is-collapsed .tc-meta > :not(.tc-code) { display: none; }
.tcard.is-collapsed .tc-code { background: var(--surface-3); color: var(--ink-2); }
.tcard.is-collapsed h3 { font-size: 1rem; font-weight: 600; color: var(--muted); margin: 0; max-width: none; text-wrap: wrap; }
.tcard.is-collapsed .tc-toggle { position: static; }
.tcard.is-collapsed + .tcard:not(.is-collapsed) { margin-top: 40px; }
.tref { font-family: var(--sans); font-size: .86em; font-weight: 700; text-decoration: none; color: var(--accent-ink); background: var(--accent-wash); padding: 1px 6px; border-radius: 4px; white-space: nowrap; }
.tref:hover { background: var(--accent-wash-2); text-decoration: none; }
mark.hl { background: color-mix(in srgb, var(--s2) 30%, transparent); color: inherit; border-radius: 2px; padding: 0 1px; }
.tc-head h3 { scroll-margin-top: calc(var(--topbar-h) + 16px); }
@media (max-width: 640px) { .tcard { margin-top: 40px; padding-top: 32px; } .tc-toggle { top: 28px; } }

/* Practice box (mirrors the paper's call-outs) */
.practice { background: color-mix(in srgb, var(--accent) 5%, var(--surface)); border-left: 3px solid var(--accent); padding: 12px 14px 12px 16px; border-radius: 0 6px 6px 0; }
.practice-label { display: flex; align-items: center; gap: 9px; font-family: var(--sans); font-weight: 700; font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-ink); margin-bottom: 8px; }
.pico { width: 18px; height: 18px; flex: none; }
.pico circle { fill: var(--accent); }
.pico path { stroke: var(--on-accent); stroke-width: 2; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.pico .dot { fill: var(--on-accent); stroke: none; }
.practice ul { margin: 0; padding-left: 1.15em; font-size: .97rem; }
.shift-box { background: var(--bg-alt); border-left: 3px solid var(--muted); padding: 12px 14px 12px 16px; border-radius: 0 6px 6px 0; }
.shift-box .practice-label { color: var(--ink-2); }
.shift-box .pico circle { fill: var(--muted); }
.shift-box .pico path { stroke: var(--surface); }
.shift-box .pico .dot { fill: var(--surface); }
.shift-box .tc-shift { margin: 0; font-size: 1rem; }
.group-head .shift-box { margin-bottom: 24px; }
.practice li { margin: 0 0 .45em; }
.practice li::marker { color: var(--accent); }
.practice li:last-child { margin-bottom: 0; }

/* ---------- Toolkit matrix ---------- */
.matrix { border-collapse: separate; border-spacing: 0; width: 100%; min-width: 760px; font-family: var(--sans); font-size: 14px; }
.matrix th, .matrix td { padding: 8px 6px; text-align: center; border-bottom: 1px solid var(--hair); transition: background .12s; }
.matrix thead th { font-size: 12.5px; font-weight: 650; color: var(--ink-2); vertical-align: bottom; line-height: 1.25; border-bottom: 1.5px solid var(--line); width: 11%; }
.matrix thead th:first-child { width: auto; }
.matrix .row-head { text-align: left; white-space: nowrap; }
.matrix .row-head button { border: 0; background: none; padding: 2px 4px; border-radius: 4px; font-size: 14px; color: var(--ink); text-align: left; }
.matrix .row-head button:hover { color: var(--accent-ink); text-decoration: underline; }
.matrix .row-head .code { display: inline-block; width: 2.2em; font-weight: 700; color: var(--accent-ink); }
.matrix .group-row th { text-align: left; font-size: 12.5px; font-style: italic; color: var(--muted); font-weight: 500; padding-top: 14px; border-bottom: 0; }
.matrix .col-hl, .matrix .row-hl > * { background: var(--accent-wash); }
.matrix .cell-btn { border: 0; background: none; padding: 4px; border-radius: 50%; display: inline-grid; place-items: center; }
.mk { width: 20px; height: 20px; border-radius: 50%; display: inline-grid; place-items: center; position: relative; }
.mk-h { background: var(--s1); }
.mk-r { background: var(--risk); }
.mk-h::after { content: ""; width: 8px; height: 4.5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.mk-r::after { content: "!"; color: #fff; font: 800 13px/1 var(--sans); }
.matrix-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; margin-top: 14px; font-family: var(--sans); font-size: 13px; color: var(--ink-2); }
.mk-legend { display: inline-flex; align-items: center; gap: 8px; }
.mk-legend .mk { width: 16px; height: 16px; }
.mk-legend .mk-h::after { width: 6px; height: 3.5px; border-width: 1.6px; }
.mk-legend .mk-r::after { font-size: 11px; }
.matrix-note { flex-basis: 100%; margin: 4px 0 0; color: var(--ink); font-size: 14px; min-height: 1.5em; }

/* ---------- pass@k ---------- */
.runs { border-collapse: collapse; font-family: var(--sans); font-size: 14px; width: 100%; }
.runs th { font-size: 12px; font-weight: 600; color: var(--muted); padding: 4px 4px 8px; text-align: center; white-space: nowrap; }
.runs td { padding: 4px; text-align: center; border-top: 1px solid var(--hair); }
.runs .task-name { text-align: left; font-weight: 600; white-space: nowrap; padding-right: 10px; }
.runs .num { font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; }
.runs .num.strong { color: var(--ink); font-weight: 650; }
.runs tfoot td { font-weight: 650; border-top: 1.5px solid var(--line); padding-top: 8px; }
.run {
  width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--line); background: var(--surface);
  display: inline-grid; place-items: center; padding: 0; transition: transform .12s, background .15s, border-color .15s;
}
.run:hover { transform: scale(1.08); border-color: var(--s1); }
.run svg { width: 14px; height: 14px; fill: none; stroke: var(--muted); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.run[aria-pressed="true"] { background: var(--s1); border-color: var(--s1); }
.run[aria-pressed="true"] svg { stroke: #fff; }
@media (max-width: 480px) {
  .runs td { padding: 3px 1px; }
  .runs th { padding: 4px 1px 8px; }
  .runs .task-name { padding-right: 4px; }
  .run { width: 26px; height: 26px; }
  .run svg { width: 12px; height: 12px; }
}
.mini-ok, .mini-no { display: inline-grid; place-items: center; width: 22px; height: 22px; }
.mini-ok svg, .mini-no svg { width: 16px; height: 16px; fill: none; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.mini-ok svg { stroke: var(--s1); }
.mini-no svg { stroke: var(--muted); }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.stat { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; background: var(--surface); }
.stat .s-label { font-family: var(--sans); font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 7px; }
.stat .s-key { width: 14px; height: 0; border-top: 2px solid; display: inline-block; }
.stat .s-value { font-family: var(--sans); font-size: 1.85rem; font-weight: 650; line-height: 1.15; margin-top: 4px; }
.stat .s-sub { font-family: var(--sans); font-size: 12px; color: var(--muted); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-family: var(--sans); font-size: 13px; color: var(--ink-2); margin-bottom: 6px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend .lk { width: 16px; height: 0; border-top: 2px solid; display: inline-block; }
.legend .dk { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart text { font-family: var(--sans); fill: var(--muted); font-size: 12px; }
.chart .tick text { font-variant-numeric: tabular-nums; }
.chart .grid line { stroke: var(--hair); stroke-width: 1; }
.chart .axis line, .chart .axis path { stroke: var(--line); stroke-width: 1; }
.chart .axis-title { fill: var(--ink-2); font-size: 12.5px; font-weight: 550; }
.chart .series { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .end-label { fill: var(--ink); font-size: 12.5px; font-weight: 600; }
.chart .cross { stroke: var(--muted); stroke-width: 1; }
.chart .k-line { stroke: var(--accent); stroke-width: 1; opacity: .5; }
.chart .marker { stroke: var(--surface); stroke-width: 2; }
.chart .guide { stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 4 4; fill: none; }

/* ---------- Pareto ---------- */
.chart-pareto svg { touch-action: none; cursor: crosshair; }
.chart-pareto .pt { cursor: grab; }
.chart-pareto .pt.dragging { cursor: grabbing; }
.chart-pareto .pt-mark { stroke-width: 2; transition: r .12s; }
.chart-pareto .pt-front .pt-mark { fill: var(--s1); stroke: var(--surface); }
.chart-pareto .pt-dom .pt-mark { fill: var(--surface); stroke: var(--muted); }
.chart-pareto .pt:hover .pt-mark, .chart-pareto .pt.hl .pt-mark, .chart-pareto .pt:focus-visible .pt-mark { r: 8; }
.chart-pareto .pt:focus { outline: none; }
.chart-pareto .pt:focus-visible .pt-ring { stroke: var(--accent); stroke-width: 2; fill: none; }
.chart-pareto .pt-label { fill: var(--ink-2); font-size: 12px; font-weight: 600; pointer-events: none; }
.chart-pareto .frontier { stroke: var(--s1); stroke-width: 2; fill: none; }
.chart-pareto .frontier-fill { fill: var(--s1); opacity: .07; }
.chart-pareto .dom-link { stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 3 3; }
.pa-side { display: flex; flex-direction: column; gap: 8px; }
.pa-table-head { display: flex; align-items: center; justify-content: space-between; }
.data-table { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 13.5px; }
.data-table th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 6px 8px; border-bottom: 1.5px solid var(--line); }
.data-table td { padding: 6px 8px; border-bottom: 1px solid var(--hair); font-variant-numeric: tabular-nums; }
.data-table td.r, .data-table th.r { text-align: right; }
.data-table tr.hl td { background: var(--accent-wash); }
.status-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; }
.status-pill i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.status-pill.front i { background: var(--s1); }
.status-pill.dom i { border: 1.6px solid var(--muted); }

/* ---------- Factorial ---------- */
.fx-grid { display: grid; grid-template-columns: auto repeat(3, minmax(0, 1fr)); gap: 6px; font-family: var(--sans); font-size: 13px; max-width: 420px; }
.fx-grid .fx-h { color: var(--ink-2); font-weight: 600; text-align: center; padding: 2px 0; align-self: end; }
.fx-grid .fx-rh { color: var(--ink-2); font-weight: 600; align-self: center; padding-right: 6px; white-space: nowrap; }
.fx-cell {
  aspect-ratio: 1.6; border-radius: 8px; border: 1.5px dashed var(--line); background: var(--surface);
  display: grid; place-items: center; transition: background .15s, border-color .15s, transform .1s;
}
.fx-cell:hover { border-color: var(--accent); }
.fx-cell svg { width: 18px; height: 18px; fill: none; stroke: var(--on-accent); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; opacity: 0; transition: opacity .15s; }
.fx-cell[aria-pressed="true"] { background: var(--accent); border: 1.5px solid var(--accent); }
.fx-cell[aria-pressed="true"] svg { opacity: 1; }
.fx-cell.pulse { animation: pulse .5s ease; }
@keyframes pulse { 40% { transform: scale(1.06); } }
.fx-status { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; font-family: var(--sans); font-size: 14px; }
.fx-status li { display: grid; grid-template-columns: 22px 1fr; gap: 8px; align-items: start; }
.fx-status .st-ic { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; margin-top: 1px; }
.fx-status .st-ok { background: var(--s1); }
.fx-status .st-no { border: 1.6px solid var(--line); }
.fx-status .st-warn { background: var(--risk); }
.fx-status .st-ok::after { content: ""; width: 8px; height: 4.5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.fx-status .st-warn::after { content: "!"; color: #fff; font: 800 12px/1 var(--sans); }
.fx-status b { display: block; font-weight: 650; }
.fx-status span { color: var(--ink-2); }
.fx-cost { background: var(--surface-2); border-radius: var(--radius-sm); padding: 18px; border: 1px solid var(--hair); }
.fx-inputs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 10px 0 16px; }
@media (max-width: 480px) { .fx-inputs { grid-template-columns: minmax(0, 1fr); } }
.fx-inputs label { display: flex; flex-direction: column; gap: 4px; font-family: var(--sans); font-size: 12.5px; color: var(--muted); font-weight: 600; }
.fx-inputs input { font-family: var(--sans); font-size: 15px; padding: 8px 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); width: 100%; font-variant-numeric: tabular-nums; }
.fx-inputs input:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px var(--accent-wash-2); }
.fx-total { font-family: var(--sans); font-size: 2.2rem; font-weight: 650; margin: 0; line-height: 1.1; }
.fx-formula { font-family: var(--sans); font-size: 13.5px; color: var(--ink-2); margin: 6px 0 14px; }
.fx-bars { display: flex; flex-direction: column; gap: 8px; font-family: var(--sans); font-size: 12.5px; margin-bottom: 12px; }
.fx-bar { display: grid; grid-template-columns: 9.5em 1fr auto; align-items: center; gap: 10px; color: var(--ink-2); }
.fx-bar .track, .fx-bar .fill { display: block; }
.fx-bar .track { height: 10px; background: var(--surface-3); border-radius: 0 4px 4px 0; overflow: hidden; }
.fx-bar .fill { height: 100%; background: var(--s1); border-radius: 0 4px 4px 0; transition: width .35s ease; }
.fx-bar .fill.ref { background: var(--muted); }
.fx-bar .v { font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 600; min-width: 5.5em; text-align: right; }
.fx-note { font-family: var(--sans); font-size: 12.5px; color: var(--muted); margin: 0; }
.fx-hint { font-family: var(--sans); font-size: 13.5px; color: var(--ink-2); margin: 18px 0 0; padding-top: 14px; border-top: 1px solid var(--hair); }
.fx-hint b { color: var(--ink); }
.fx-design { font-family: var(--sans); font-size: 13.5px; color: var(--ink-2); margin: 0 0 4px; }
.fx-design b { color: var(--ink); }

/* ---------- Log ---------- */
.log-wrap { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.5fr); gap: 22px; align-items: start; }
@media (max-width: 860px) { .log-wrap { grid-template-columns: minmax(0, 1fr); } }
.log-outcome { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.log-outcome .ctl-label { margin: 6px 0 0; }
.log-task { font-size: 1.02rem; margin: 0 0 6px; }
.log-score { display: flex; align-items: center; gap: 10px; font-family: var(--sans); font-weight: 650; font-size: 1.25rem; margin: 2px 0 16px; transition: color .3s; }
.ok-badge { width: 28px; height: 28px; border-radius: 50%; background: var(--s1); display: grid; place-items: center; flex: none; transition: background .3s; }
.ok-badge::after { content: ""; width: 11px; height: 6px; border-left: 2.6px solid #fff; border-bottom: 2.6px solid #fff; transform: translateY(-1px) rotate(-45deg); }
.log-score.flagged span:last-child { text-decoration: line-through; text-decoration-color: var(--risk); text-decoration-thickness: 2px; color: var(--muted); }
.log-score.flagged .ok-badge { background: var(--muted); }
.log-panel { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); overflow: hidden; min-height: 280px; display: flex; flex-direction: column; }
.log-head { font-family: var(--sans); font-size: 12.5px; color: var(--muted); padding: 8px 14px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; }
.log-lines { list-style: none; margin: 0; padding: 8px 0; font-family: var(--mono); font-size: 13px; counter-reset: ln; flex: 1; }
.log-lines li { display: grid; grid-template-columns: 2.2em 4.8em 1fr; gap: 8px; padding: 4px 14px; opacity: 0; transform: translateY(4px); transition: opacity .3s, transform .3s, background .3s; }
.log-lines li.show { opacity: 1; transform: none; }
.log-lines li.log-placeholder { display: block; }
.log-lines li .ln { color: var(--muted); text-align: right; }
.log-lines li .kind { font-weight: 700; color: var(--ink-2); }
.log-lines li .txt { word-break: break-word; }
.log-lines li.flag.lit { background: color-mix(in srgb, var(--risk) 12%, transparent); box-shadow: inset 3px 0 0 var(--risk); }
.log-lines li.flag.lit .kind { color: var(--risk); }
.log-lines li.outcome-line { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 8px; }
.log-placeholder { font-family: var(--sans); font-size: 14px; color: var(--muted); padding: 40px 20px; text-align: center; }
.log-verdict { margin: 0 12px 12px; padding: 12px 14px; border-radius: 0 8px 8px 0; background: var(--risk-wash); border-left: 3px solid var(--risk); font-size: .97rem; }
.log-verdict strong { color: var(--risk); }

/* ---------- Time horizon ---------- */
.stats-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 640px) { .stats, .stats-row { grid-template-columns: minmax(0, 1fr); } }
.chart .curve-fill { fill: var(--s1); opacity: .08; }
.chart .pt-50 { fill: var(--s1); stroke: var(--surface); stroke-width: 2; }
.chart .pt-r { fill: var(--s2); stroke: var(--surface); stroke-width: 2; }
.chart .pt-label { fill: var(--ink); font-size: 12.5px; font-weight: 600; }

/* ---------- Scope layers ---------- */
.scope-svg svg { display: block; width: 100%; max-width: 520px; height: auto; margin: 0 auto; }
.scope-svg .band { cursor: pointer; transition: fill .2s; fill: transparent; }
.scope-svg .band:hover { fill: color-mix(in srgb, var(--accent) 10%, transparent); }
.scope-svg .band.sel { fill: color-mix(in srgb, var(--accent) 20%, transparent); }
.scope-svg .band:focus { outline: none; }
.scope-svg .band:focus-visible { stroke: var(--accent); stroke-width: 2.5; }
.scope-svg .tri { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.scope-svg .band-label { font-family: var(--serif); font-weight: 700; font-size: 17px; fill: var(--ink); pointer-events: none; }
.scope-svg .axis-label { font-family: var(--sans); font-weight: 650; font-size: 13px; fill: var(--ink-2); }
.scope-detail h4 { font-size: 1.3rem; margin-bottom: 8px; }
.scope-detail .q { color: var(--ink-2); margin-bottom: 14px; }
.scope-detail .chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.scope-detail .framing { font-size: .97rem; background: var(--surface-2); border-radius: var(--radius-sm); padding: 12px 14px; }
.scope-detail .framing b { font-family: var(--sans); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 4px; }

/* ---------- Settings spectrum ---------- */
.settings { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; position: relative; padding-top: 30px; }
@media (max-width: 760px) { .settings { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-top: 0; } .rct-bracket { display: none; } }
.rct-bracket { position: absolute; top: 0; left: calc(25% + 5px); width: calc(50% - 10px); height: 22px; border: 1.5px solid var(--muted); border-bottom: 0; border-radius: 6px 6px 0 0; text-align: center; }
.rct-bracket span { position: relative; top: -12px; background: var(--surface); padding: 0 8px; font-family: var(--sans); font-size: 12px; color: var(--muted); }
.setting {
  text-align: left; border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--radius-sm);
  padding: 14px; display: flex; flex-direction: column; gap: 4px; transition: border-color .15s, background .15s, transform .15s;
}
.setting:hover { border-color: var(--accent); }
.setting[aria-checked="true"] { border-color: var(--accent); background: var(--accent-wash); }
.setting .code { font-family: var(--sans); font-weight: 700; font-size: 13px; color: var(--accent-ink); }
.setting .name { font-family: var(--serif); font-weight: 700; font-size: 1.05rem; }
.setting .desc { font-family: var(--sans); font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.tradeoff { margin-top: 16px; display: grid; gap: 8px; font-family: var(--sans); font-size: 13px; color: var(--ink-2); }
.tradeoff .row { display: grid; grid-template-columns: 15em 1fr; gap: 12px; align-items: center; }
@media (max-width: 640px) { .tradeoff .row { grid-template-columns: minmax(0, 1fr); gap: 4px; } }
.wedge { height: 14px; position: relative; }
.wedge svg { width: 100%; height: 14px; display: block; }
.wedge .w-control { fill: color-mix(in srgb, var(--ink) 22%, transparent); }
.wedge .w-real { fill: color-mix(in srgb, var(--accent) 45%, transparent); }
.wedge .w-mark { fill: var(--ink); }
.settings-detail { margin-top: 18px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 22px; }
@media (max-width: 860px) { .settings-detail { grid-template-columns: minmax(0, 1fr); } }
.settings-detail h4 { font-size: 1.2rem; margin-bottom: 8px; }
.settings-detail ul { margin: 0; padding-left: 1.1em; font-size: .97rem; }
.settings-detail li { margin-bottom: .4em; }
.caveat { background: var(--surface-2); border-radius: var(--radius-sm); padding: 14px 16px; font-size: .97rem; }
.caveat b { font-family: var(--sans); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); display: block; margin-bottom: 4px; }

/* ---------- Economic layers & behavior ---------- */
.econ { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: minmax(0, 1fr); font-family: var(--sans); }
.econ li { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; background: var(--surface); text-align: center; }
.econ li b { font-family: var(--serif); font-size: 1.05rem; }
.econ li span { font-family: var(--serif); font-size: .97rem; color: var(--ink-2); }
.econ li em { font-style: normal; font-size: 12.5px; color: var(--muted); margin-top: auto; }
/* the dashed "?" link between layers: vertical when stacked, horizontal side by side */
.econ .econ-gap { border: 0; background: none; padding: 0; min-height: 40px; position: relative; justify-content: center; align-items: center; font-weight: 800; color: var(--accent-ink); }
.econ .econ-gap::before { content: ""; position: absolute; left: 50%; top: 0; bottom: 0; border-left: 1.5px dashed var(--muted); }
.econ .econ-gap { z-index: 1; }
#fig-economic > figcaption { text-align: center; }
.econ .econ-gap { background: linear-gradient(var(--surface), var(--surface)) center / 1.4em 1.3em no-repeat; }
@media (min-width: 700px) {
  .econ { grid-template-columns: minmax(0, 1fr) 64px minmax(0, 1fr) 64px minmax(0, 1fr); align-items: stretch; }
  .econ .econ-gap { min-height: 0; background: none; padding-bottom: 22px; }
  .econ .econ-gap::before { left: 8px; right: 12px; top: 50%; bottom: auto; border-left: 0; border-top: 1.5px dashed var(--muted); }
  .econ .econ-gap::after { content: ""; position: absolute; right: 6px; top: calc(50% - 4.5px); border: 4.5px solid transparent; border-left: 7px solid var(--muted); border-right: 0; }
}
.behav { display: grid; gap: 14px; }
.behav-fam { border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.behav-title { margin: 0; padding: 10px 14px 0; font-weight: 700; font-size: 1.05rem; background: var(--accent-wash); }
.behav-cond { margin: 0; padding: 2px 14px 10px; font-family: var(--sans); font-size: 12.5px; color: var(--muted); background: var(--accent-wash); border-bottom: 1px solid var(--line); }
.behav dl { margin: 0; padding: 10px 14px 12px; }
.behav dt { font-weight: 700; font-size: .98rem; }
.behav dd { margin: 0 0 8px; color: var(--ink-2); font-size: .95rem; }
.behav dd:last-child { margin-bottom: 0; }

/* ---------- Security ---------- */
.attacks { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 980px) { .attacks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .attacks { grid-template-columns: minmax(0, 1fr); } }
.attacks li { display: flex; }
.attack {
  width: 100%; text-align: left; display: grid; grid-template-columns: 26px 1fr; gap: 10px; align-items: start;
  border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--radius-sm); padding: 10px 12px; transition: border-color .15s, background .15s;
}
.attack:hover { border-color: var(--risk); }
.attack[aria-pressed="true"] { border-color: var(--risk); background: var(--risk-wash); }
.attack .num { width: 22px; height: 22px; border-radius: 50%; background: var(--risk); color: #fff; display: grid; place-items: center; font: 700 12px/1 var(--sans); margin-top: 1px; }
.attack b { font-family: var(--sans); font-size: 14px; display: block; }
.attack span { font-size: .93rem; color: var(--ink-2); }
.svg-fig .attack-path { stroke: var(--risk); stroke-width: 2; fill: none; stroke-dasharray: 6 4; }
.svg-fig .attack-head { fill: var(--risk); }
.svg-fig .attack-num circle { fill: var(--risk); }
.svg-fig .attack-num text { fill: #fff; font-weight: 700; font-size: 12px; }
.svg-fig .attack-g { transition: opacity .2s; }
.svg-fig .attack-g.on .attack-path { stroke-width: 3; animation: dash 1s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -20; } }
@media (prefers-reduced-motion: reduce) { .svg-fig .attack-g.on .attack-path { animation: none; } }
.svg-fig .zone-label { font-weight: 700; fill: var(--ink-2); font-size: 13px; }

/* ---------- Timeline ---------- */
.tl { position: relative; height: var(--tl-h, 330px); width: 1000px; margin: 0 auto; }
.tl-axis { position: absolute; left: 0; right: 0; top: var(--axis-y, 160px); height: 2px; background: var(--muted); }
.tl-axis::after { content: ""; position: absolute; right: -2px; top: -5px; border: 6px solid transparent; border-left: 9px solid var(--muted); border-right: 0; }
.tl-year { position: absolute; top: calc(var(--axis-y, 160px) + 6px); transform: translateX(-50%); font-family: var(--sans); font-size: 12px; color: var(--muted); }
.tl-year::before { content: ""; position: absolute; left: 50%; top: -9px; height: 8px; border-left: 1.5px solid var(--muted); }
.tl-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tl-svg path { stroke: var(--line); stroke-width: 1.2; fill: none; transition: stroke .15s; }
.tl-svg path.on { stroke: var(--accent); stroke-width: 1.8; }
.tl-svg circle { fill: var(--accent); transition: r .15s; }
.tl-svg .dimmed { opacity: .25; }
.tl-ev {
  position: absolute; width: var(--ev-w, 150px); transform: translateX(-50%); border: 1px solid transparent; background: transparent;
  text-align: center; padding: 6px 6px; border-radius: 8px; transition: background .15s, border-color .15s, opacity .2s; line-height: 1.3;
}
.tl-ev.above { bottom: calc(var(--tl-h, 330px) - var(--axis-y, 160px) + 52px); }
.tl-ev.below { top: calc(var(--axis-y, 160px) + 74px); }
.tl-ev:hover { background: var(--surface-2); }
.tl-ev[aria-pressed="true"] { background: var(--accent-wash); border-color: var(--accent); }
.tl-ev .d { display: block; font-family: var(--sans); font-weight: 700; font-size: 13px; color: var(--accent-ink); }
.tl-ev .x { display: block; font-family: var(--sans); font-size: 12.5px; color: var(--ink-2); }
.tl-ev.dimmed { opacity: .3; }
.tl-detail { margin-top: 14px; padding: 16px 18px; border-radius: var(--radius-sm); background: var(--surface-2); display: grid; grid-template-columns: 7em 1fr; gap: 6px 18px; }
@media (max-width: 640px) { .tl-detail { grid-template-columns: minmax(0, 1fr); } }
.tl-detail .d { font-family: var(--sans); font-weight: 700; color: var(--accent-ink); }
.tl-detail h4 { font-size: 1.1rem; margin-bottom: 6px; }
.tl-detail p { margin: 0 0 8px; color: var(--ink-2); font-size: .98rem; }
.tl-detail .meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-family: var(--sans); font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) {
  .tl-scroll { overflow: visible; }
  .tl { height: auto; width: auto !important; display: flex; flex-direction: column; gap: 4px; border-left: 2px solid var(--line); margin-left: 6px; padding-left: 14px; }
  .tl-axis, .tl-year, .tl-svg { display: none; }
  .tl-ev { position: relative; width: auto; transform: none; text-align: left; inset: auto !important; display: grid; grid-template-columns: 6.5em 1fr; gap: 8px; }
  .tl-ev::before { content: ""; position: absolute; left: -21px; top: 12px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
}

/* ---------- Influence ---------- */
.influence { display: grid; grid-template-columns: 9.5em 1fr 9.5em; gap: 14px; align-items: stretch; font-family: var(--sans); }
@media (max-width: 760px) { .influence { grid-template-columns: minmax(0, 1fr); } .inf-node { min-height: 0 !important; padding: 12px !important; } }
.inf-node { border-radius: var(--radius-sm); display: grid; place-items: center; text-align: center; font-weight: 700; font-family: var(--serif); font-size: 1.1rem; padding: 16px; min-height: 220px; }
.inf-lab { background: var(--accent-wash); border: 1.5px solid var(--accent); }
.inf-eval { background: var(--surface); border: 1.5px solid var(--line); }
.inf-channels { display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.channel { position: relative; border: 0; background: none; padding: 8px 4px 14px; text-align: center; font-size: 14px; color: var(--ink-2); border-radius: 8px; transition: background .15s; }
.channel:hover { background: var(--surface-2); }
.channel b { color: var(--ink); }
.channel .arrow { position: absolute; left: 6px; right: 6px; bottom: 6px; height: 2px; background: var(--muted); }
.channel .arrow::after { content: ""; position: absolute; top: -5px; border: 6px solid transparent; }
.channel.fwd .arrow::after { right: -2px; border-left: 9px solid var(--muted); border-right: 0; }
.channel.back .arrow { background: repeating-linear-gradient(90deg, var(--muted) 0 6px, transparent 6px 10px); }
.channel.back .arrow::after { left: -2px; border-right: 9px solid var(--muted); border-left: 0; }
.channel[aria-checked="true"] { background: var(--accent-wash); }
.channel[aria-checked="true"] .arrow { background: var(--accent); }
.channel.back[aria-checked="true"] .arrow { background: repeating-linear-gradient(90deg, var(--accent) 0 6px, transparent 6px 10px); }
.channel.fwd[aria-checked="true"] .arrow::after { border-left-color: var(--accent); }
.channel.back[aria-checked="true"] .arrow::after { border-right-color: var(--accent); }
.channel .note { display: block; font-size: 12px; color: var(--muted); }

/* ---------- Disciplines ---------- */
.disc { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 900px) { .disc { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .disc { grid-template-columns: minmax(0, 1fr); } }
.disc-card { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 10px; transition: border-color .15s, box-shadow .15s; }
.disc-card:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.disc-card h4 { font-size: 1.08rem; }
.disc-card p { margin: 0; font-size: .95rem; color: var(--ink-2); }
.disc-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-family: var(--sans); font-size: 13.5px; }
.disc-card li { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; border-top: 1px solid var(--hair); padding-top: 6px; }
.disc-card li .refs { display: flex; gap: 4px; flex: none; }

/* ---------- Conclusion ---------- */
.section-quote { padding-block: calc(var(--sec-space) + 12px); border-top: 1px solid var(--hair); }
.pull { margin: 0 0 28px; padding: 0; border: 0; text-align: center; }
.pull p { font-size: clamp(1.5rem, 3.2vw, 2.2rem); line-height: 1.3; font-weight: 700; margin: 0; text-wrap: balance; }
.pull p::before { content: "“"; color: var(--accent-ink); }
.pull p::after { content: "”"; color: var(--accent-ink); }
.pull em { color: var(--accent-ink); }
.concl { color: var(--ink-2); font-size: 1.05rem; }
.concl p:last-child { margin-bottom: 0; }
.eyebrow-center { justify-content: center; }

/* ---------- Takeaways (static) ---------- */
.tk-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 32px; }
.tk-tab {
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; padding: 14px 18px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); transition: border-color .15s, background .15s;
}
.tk-tab:hover { border-color: var(--accent); }
.tk-tab[aria-selected="true"] { border-color: var(--accent); background: var(--accent-wash); box-shadow: inset 0 0 0 1px var(--accent); }
.tk-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tk-q { font-family: var(--serif); font-size: 1.6rem; font-weight: 700; line-height: 1.1; color: var(--accent-ink); }
.tk-l { display: inline-flex; align-items: center; gap: 8px; font-family: var(--sans); font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.tk-l .pico { width: 16px; height: 16px; }
.tk-n { font-family: var(--sans); font-size: 13px; color: var(--muted); }
@media (max-width: 640px) {
  .tk-tabs { gap: 8px; }
  .tk-tab { padding: 10px 12px; }
  .tk-q { font-size: 1.25rem; }
  .tk-l { font-size: 12px; font-weight: 600; letter-spacing: 0; text-transform: none; }
  .tk-l .pico, .tk-n { display: none; }
}
@media print { .tk-tabs { display: none; } .tk-panel[hidden] { display: block !important; margin-bottom: 32px; } }
.tk-cols { columns: 3 320px; column-gap: 44px; }
.tk-group { break-inside: avoid; margin-bottom: 24px; }
.tk-group h4 { font-size: 1.02rem; margin-bottom: 6px; }
.tk-group h4 .code { font-family: var(--sans); font-weight: 800; color: var(--accent-ink); text-decoration: none; margin-right: 2px; }
.tk-group h4 .code:hover { text-decoration: underline; }
.tk-group ul { margin: 0; padding-left: 1.1em; font-size: .94rem; color: var(--ink-2); line-height: 1.5; }
.tk-group li { margin-bottom: .4em; }
.tk-group li::marker { color: var(--accent); }

/* ---------- Cite ---------- */
.bib { position: relative; }
.bib pre { margin: 0; padding: 22px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); overflow-x: auto; font-family: var(--mono); font-size: 13.5px; line-height: 1.6; color: var(--ink); }
.bib-copy { position: absolute; top: 12px; right: 12px; }
/* About: the SAgE group, the citation and the acknowledgments, side by side on wide screens */
.about { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
@media (min-width: 1100px) { .about { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; } }
.about-panel { display: flex; flex-direction: column; gap: 12px; padding: 22px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); font-size: .98rem; color: var(--ink-2); }
.about-panel p { margin: 0; }
.about-panel h3 { font-size: 1.2rem; color: var(--ink); }
.about-panel > h3, .about-head { display: flex; align-items: center; min-height: 40px; } /* headings line up across the panels */
.about-head { justify-content: space-between; gap: 12px; }
.about-panel > h3 { justify-content: center; text-align: center; } /* the SAgE and Acknowledgements headings; Citation shares its row with the copy button */
.about .bib-copy { position: static; }
.about .bib pre { padding: 14px 16px; font-size: 12.5px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; background: var(--bg-alt); }
.bx-line { display: block; }
.bx-type { color: var(--s2); font-weight: 650; }
.bx-key { color: var(--ink); font-weight: 650; }
.bx-name { color: var(--accent-ink); }
.bx-val { color: var(--ink); }
.bx-p { color: var(--muted); }
/* the logo and name scale together with the panel, so they stay on one line on phones */
.about-panel:has(.about-lab) { container-type: inline-size; }
.about-lab { display: inline-flex; align-items: center; gap: .75em; color: var(--ink); text-decoration: none; font-size: min(16px, 5cqi); }
.about-lab img { width: 2.5em; height: 2.5em; flex: none; }
.about-lab span { font-family: var(--sans); font-size: 1em; font-weight: 400; color: var(--ink-2); white-space: nowrap; }
.about-lab b { font-size: 1.15em; font-weight: 700; color: var(--ink); margin-right: .25em; }
.about-lab:hover span, .about-lab:hover b { color: var(--accent-ink); }
.about-label { font-family: var(--sans); font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-top: 4px !important; }
.about-contacts { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: .95rem; }
.about-contacts li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0 12px; }
.about-contacts span { color: var(--ink); }
.about-contacts a { font-family: var(--mono); font-size: .86em; color: var(--ink-2); text-decoration-color: var(--line); text-underline-offset: 2px; }
.about-contacts a:hover { color: var(--accent-ink); text-decoration-color: currentColor; }
@media (max-width: 480px) { .about-contacts { gap: 8px; } .about-contacts li { flex-direction: column; } }
.about-more { margin-top: auto !important; padding-top: 6px; text-align: center; }
.about-pending { color: var(--muted); font-style: italic; }
.about-ack { display: grid; gap: 10px; }

/* ---------- Footer, tooltip, toast ---------- */
.tooltip {
  position: fixed; z-index: 80; pointer-events: none; max-width: 300px;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow-pop);
  padding: 8px 11px; font-family: var(--sans); font-size: 13px; line-height: 1.4;
}
.tooltip .tt-title { font-weight: 650; margin-bottom: 4px; }
.tooltip .tt-row { display: flex; align-items: center; gap: 8px; }
.tooltip .tt-row .lk { width: 14px; border-top: 2px solid; display: inline-block; }
.tooltip .tt-row b { font-weight: 700; font-variant-numeric: tabular-nums; }
.tooltip .tt-sub { color: var(--muted); }
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 90;
  background: var(--ink); color: var(--bg); font-family: var(--sans); font-size: 14px; padding: 10px 16px; border-radius: 999px; box-shadow: var(--shadow-pop);
}

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; transition: none; } }

@media print {
  .topbar, .fig-controls, .hero-actions, .rail, .now-bar, .bib-copy { display: none !important; }
  .tr-layout { display: block; }
  .figure { box-shadow: none; break-inside: avoid; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- The paper's text inside the trends ---------- */
.tc-paper { margin-top: 30px; }
.tc-paper > .pp { font-size: 1.02rem; }
.tc-paper > ul.pp { padding-left: 1.2em; }
.tc-paper > ul.pp li { margin-bottom: .5em; }
.tc-paper > .figure + .pp { margin-top: 28px; }
.tc-paper:not(.is-full) > .pp:not(.teaser) { display: none; }
.tc-paper:not(.is-full) > .teaser {
  max-height: 5.2em; overflow: hidden; margin-bottom: 0;
  -webkit-mask-image: linear-gradient(#000 35%, transparent); mask-image: linear-gradient(#000 35%, transparent);
}
.tc-paper.is-full .tc-more, .tc-paper:not(.is-full) .tc-less { display: none; }
.part-intro:not(.is-full) > .pp { display: none; }
.part-intro.is-full .tc-more, .part-intro:not(.is-full) .tc-less { display: none; }
.part-intro .pp { color: var(--ink-2); margin: 14px 0 0; }
.tr-main.full .tc-paper > .pp, .tr-main.q-on .tcard:not(.is-collapsed) .tc-paper > .pp, .tr-main.full .part-intro > .pp {
  display: block; max-height: none; -webkit-mask-image: none; mask-image: none; margin-bottom: 1em;
}
.tr-main.full .tc-more, .tr-main.full .tc-less, .tr-main.q-on .tc-more, .tr-main.q-on .tc-less { display: none !important; }
.tc-more, .tc-less {
  display: inline-flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; border: 0; background: none; padding: 6px 0; margin: 2px 0 6px;
  font-family: var(--sans); font-size: 14px; font-weight: 650; color: var(--accent-ink); cursor: pointer;
}
.tc-more::after { content: ""; width: 7px; height: 7px; border: solid currentColor; border-width: 0 1.8px 1.8px 0; transform: translateY(-2px) rotate(45deg); order: 1; }
.tc-more .tm-meta { order: 2; }
.tc-less { color: var(--muted); font-weight: 600; font-size: 13px; }
.tc-more:hover, .tc-less:hover { text-decoration: underline; text-underline-offset: 3px; }
.tm-meta { font-weight: 500; font-size: 12.5px; color: var(--muted); }
.tc-notes { font-size: .92rem; color: var(--ink-2); border-top: 1px solid var(--hair); padding-top: 12px; }
.tc-notes ol { margin: 0; padding-left: 1.4em; }

/* Citations, notes and defined terms */
.cite {
  font: inherit; font-family: var(--sans); font-size: .8em; font-weight: 600; color: var(--accent-ink);
  background: none; border: 0; padding: 0 1px; margin: 0; cursor: pointer; border-radius: 3px; line-height: 1;
}
.cite:hover, .cite[aria-expanded="true"] { background: var(--accent-wash); }
.fn { line-height: 0; }
.fnref {
  font-family: var(--sans); font-size: .72em; font-weight: 700; color: var(--accent-ink); background: none; border: 0;
  padding: 0 2px; margin: 0; cursor: pointer; vertical-align: super; line-height: 1;
}
.term {
  text-decoration: underline dotted; text-decoration-color: color-mix(in srgb, var(--accent) 70%, transparent);
  text-decoration-thickness: 1.5px; text-underline-offset: 3px; cursor: help; border-radius: 2px;
}
.term:hover, .term[aria-expanded="true"] { background: var(--accent-wash); text-decoration-style: solid; }
.cite:focus-visible, .fnref:focus-visible, .term:focus-visible, .tc-status:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.pop {
  position: absolute; z-index: 70; width: max-content; max-width: min(460px, calc(100vw - 24px)); max-height: min(60vh, 460px); overflow: auto;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow-pop);
  padding: 12px 14px; font-family: var(--sans); font-size: 13.5px; line-height: 1.45;
}
.pop-k { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 0 6px; }
.pop-text { font-family: var(--serif); font-size: 15px; margin: 0; }
.pop-term .pop-k { color: var(--accent-ink); font-size: 12px; }
.pop-from { margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.pop .tref { font-size: 12px; }
.pop .ref-list { gap: 8px; }

/* Lists of sources */
.ref-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; font-family: var(--sans); font-size: 13px; line-height: 1.45; color: var(--ink-2); }
.ref { display: grid; grid-template-columns: 3.1em minmax(0, 1fr); gap: 6px; }
.ref[hidden] { display: none; }
.ref-n { color: var(--muted); font-variant-numeric: tabular-nums; text-align: right; }
.ref-t { color: var(--ink); font-weight: 550; }
.ref-u { white-space: nowrap; font-weight: 600; text-decoration: none; }
.ref-u:hover { text-decoration: underline; }
.tc-sources { margin-top: 30px; border-top: 1px solid var(--hair); padding-top: 12px; font-family: var(--sans); }
.tc-sources summary {
  cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 650; color: var(--ink-2); padding: 4px 0;
}
.tc-sources summary:hover { color: var(--ink); }
.tc-sources summary .n { font-size: 12px; font-weight: 700; color: var(--accent-ink); background: var(--accent-wash); border-radius: 999px; padding: 1px 8px; }
.tc-sources > .ref-list { margin-top: 14px; }
.tc-sources .ref-list, .refs .ref-list { columns: 2 420px; column-gap: 40px; display: block; }
.tc-sources .ref, .refs .ref { break-inside: avoid; margin-bottom: 7px; }
.src-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* Status and revision marks */
.tc-status {
  font-family: var(--sans); font-size: 12px; font-weight: 650; border-radius: 999px; padding: 2px 10px; cursor: pointer;
  background: var(--surface); color: var(--ink-2); border: 1px dashed var(--muted);
}
.tc-status.st-growing { border-style: solid; border-color: var(--accent); color: var(--accent-ink); }
.tc-status:hover, .tc-status[aria-expanded="true"] { background: var(--surface-2); }
.rl-open { width: 12px; height: 12px; flex: none; }
.rl-open circle { fill: none; stroke: var(--ink-2); stroke-width: 1.5; }
.rl-open path { fill: var(--ink-2); }
.rl-item.is-active .rl-open circle { stroke: var(--accent-ink); }
.rl-item.is-active .rl-open path { fill: var(--accent-ink); }
.rl-grow { width: 12px; height: 12px; flex: none; }
.rl-grow circle { fill: var(--accent); }
.rl-grow path { fill: none; stroke: var(--on-accent); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.tc-status { display: inline-flex; align-items: center; gap: 6px; }
.rail-status { margin: 0 0 6px; padding: 0 16px 10px; border-top: 0; border-bottom: 1px solid var(--hair); color: var(--ink-2); }
.refs-status { font-family: var(--sans); font-size: 13px; color: var(--muted); margin: -6px 0 14px; }
.refs-status:empty { display: none; }
.goal-own { border-style: dashed; }
.goal-own[aria-pressed="true"] { border-style: solid; }

/* Full-text switch in the index */
.switch { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-2); cursor: pointer; user-select: none; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch .sw { width: 30px; height: 18px; border-radius: 999px; background: var(--surface-3); position: relative; flex: none; transition: background .15s; }
.switch .sw::after { content: ""; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgba(0,0,0,.25); transition: transform .15s; }
.switch input:checked + .sw { background: var(--accent); }
.switch input:checked + .sw::after { transform: translateX(12px); }
.switch input:focus-visible + .sw { outline: 2px solid var(--accent); outline-offset: 2px; }

/* "Your own work" */
.tailor { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 18px 22px; margin-bottom: 64px; font-family: var(--sans); scroll-margin-top: calc(var(--topbar-h) + 16px); }
.tailor-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.tailor-head > div { flex: 1 1 420px; }
.tailor-head h3 { font-family: var(--serif); font-size: 1.25rem; margin: 0 0 4px; }
.tailor-head p { font-size: 14px; color: var(--ink-2); margin: 0; }
.tailor-qs { display: none; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 18px 32px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--hair); }
.tailor.is-open .tailor-qs { display: grid; }
.tq { border: 0; margin: 0; padding: 0; min-width: 0; }
.tq legend { font-size: 13.5px; font-weight: 650; color: var(--ink); padding: 0; margin-bottom: 8px; }
.tq-hint { display: block; font-weight: 450; color: var(--muted); font-size: 12.5px; margin-top: 1px; }
.tq-opts { display: flex; flex-wrap: wrap; gap: 5px; }
.tq-opts .goal { text-align: left; }
.tailor-sum { font-size: 13.5px; color: var(--ink-2); margin: 14px 0 0; }
.tailor:not(.is-open) .tailor-sum:not(:has(button)) { display: none; }
.tailor-sum .st-actions { display: inline-flex; margin: 0 0 0 6px; vertical-align: middle; }

/* Sources for a reading path */
.reading {
  width: min(780px, calc(100% - 32px)); max-height: 86vh; padding: 0; border: 1px solid var(--line); border-radius: 14px;
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow-pop);
}
.reading::backdrop { background: rgba(10, 15, 22, .5); }
.reading-body { padding: 26px 28px 30px; max-height: 86vh; overflow: auto; }
.reading-body h2 { font-size: 1.5rem; margin: 0 0 8px; padding-right: 40px; }
.reading-close { position: absolute; top: 14px; right: 14px; z-index: 1; background: var(--surface); }
.rd-sub { color: var(--ink-2); margin: 0 0 8px; }
.rd-note { font-size: .95rem; color: var(--muted); font-style: italic; margin: 0 0 14px; }
.rd-actions { margin-bottom: 18px; }
.rd-trend { border-top: 1px solid var(--hair); padding-top: 14px; margin-top: 14px; }
.rd-trend h3 { font-family: var(--sans); font-size: 14px; display: flex; align-items: center; gap: 8px; margin: 0 0 10px; }
.rd-trend .tc-code { font-size: 12.5px; }

/* Terms and references */
.gl { columns: 2 440px; column-gap: 56px; margin: 0; }
.gl-item { break-inside: avoid; margin: 0 0 18px; }
.gl dt { font-weight: 700; font-size: 1.04rem; }
.gl dd { margin: 3px 0 0; color: var(--ink-2); }
.gl-from { font-family: var(--sans); font-size: 12.5px; white-space: nowrap; }
.gl-from .tref { font-size: 12px; }
.refs-tools { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 18px; }
.refs-filter { font-family: var(--sans); font-size: 14px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); min-width: min(360px, 100%); }

/* Figure numbers and the paper's captions */
.paper-cap { font-family: var(--sans); font-size: 13.5px; line-height: 1.5; color: var(--ink-2); margin: 16px 0 0; }

/* Static versions of three of the paper's schematics */
.split-sat { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: center; }
.sat-plot { width: 100%; max-width: 520px; height: auto; display: block; overflow: visible; }
.sat-axis { stroke: var(--ink-2); stroke-width: 1.4; }
.sat-ceil { stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 5 4; }
.sat-old path { stroke: var(--muted); stroke-width: 1.4; }
.sat-old circle { fill: var(--muted); }
.sat-top path { stroke: var(--accent); stroke-width: 1.6; fill: none; }
.sat-top circle { fill: var(--accent); }
.sat-note { font-family: var(--sans); font-size: 11.5px; fill: var(--muted); }
.sat-accent { fill: var(--accent-ink); font-weight: 600; }
.sat-label { font-family: var(--sans); font-size: 12.5px; fill: var(--ink-2); }
.sat-resp ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: r; font-family: var(--sans); font-size: 14px; }
.sat-resp li { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 9px 12px; background: var(--surface); color: var(--ink-2); }
.sat-resp a { color: var(--ink); font-weight: 600; text-decoration-color: color-mix(in srgb, var(--accent) 50%, transparent); text-underline-offset: 3px; }
.sat-resp a:hover { color: var(--accent-ink); }
.contam { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-areas: "bm ba ba" "c1 c2 c3"; gap: 10px 16px; font-family: var(--sans); }
.contam-band { margin: 0; font-size: 12.5px; text-align: center; padding-top: 8px; border-top: 1.5px solid; border-radius: 6px 6px 0 0; position: relative; }
.band-model { grid-area: bm; color: var(--muted); border-color: var(--muted); }
.band-agent { grid-area: ba; color: var(--accent-ink); border-color: var(--accent); font-weight: 700; }
.contam-band::before, .contam-band::after { content: ""; position: absolute; top: -1.5px; width: 1.5px; height: 8px; background: currentColor; }
.band-model::before, .band-model::after { background: var(--muted); }
.band-agent::before, .band-agent::after { background: var(--accent); }
.contam-band::before { left: 0; } .contam-band::after { right: 0; }
.contam-card { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.contam-card b { font-family: var(--serif); font-size: 1.05rem; }
.contam-card span { font-size: 14px; color: var(--ink-2); }
.c1 { grid-area: c1; } .c2 { grid-area: c2; } .c3 { grid-area: c3; }
.c2, .c3 { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
@media (max-width: 720px) {
  .contam { grid-template-columns: minmax(0, 1fr); grid-template-areas: none; }
  .contam > * { grid-area: auto; }
}
.equate {
  /* tiles stretch with the width: 4 anchor tasks, 7 refreshed tasks, then the shared scale */
  display: grid; grid-template-columns: auto minmax(0, 4fr) minmax(0, 7fr) minmax(48px, 1.1fr) minmax(170px, 2.6fr); grid-template-rows: auto repeat(3, 30px);
  gap: 10px 22px; align-items: center; font-family: var(--sans); font-size: 13px; color: var(--ink-2); min-width: 640px; padding: 4px 8px 8px 0; position: relative;
}
.eq-h { grid-row: 1; font-size: 12px; }
.eq-h-a { grid-column: 2; color: var(--accent-ink); font-weight: 700; text-align: center; }
.eq-h-f { grid-column: 3; color: var(--muted); text-align: center; }
.eq-v { grid-column: 1; font-weight: 600; color: var(--ink); white-space: nowrap; }
.eq-a, .eq-f { display: flex; gap: 6px; height: 100%; }
.eq-a { grid-column: 2; position: relative; z-index: 1; }
.eq-f { grid-column: 3; }
.eq-a i, .eq-f i { flex: 1; min-width: 14px; border-radius: 4px; border: 1.3px solid var(--line); background: var(--surface); }
.eq-a i { border-color: var(--accent); background: var(--accent-wash-2); }
.eq-f.f2 i { background: color-mix(in srgb, var(--ink) 10%, var(--surface)); }
.eq-f.f3 i { background: color-mix(in srgb, var(--ink) 22%, var(--surface)); }
.eq-frame { grid-column: 2; grid-row: 2 / span 3; align-self: stretch; margin: -7px -9px; border: 1.5px dashed var(--accent); border-radius: 6px; }
.eq-arrow { grid-column: 4; grid-row: 2 / span 3; height: 1.5px; background: var(--ink-2); position: relative; }
.eq-arrow::after { content: ""; position: absolute; right: -1px; top: -4px; border: 5px solid transparent; border-left: 7px solid var(--ink-2); border-right: 0; }
.eq-out { grid-column: 5; grid-row: 2 / span 3; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); padding: 14px 16px; font-size: 14px; color: var(--ink); text-align: center; font-weight: 550; }

@media print {
  .tc-paper > .pp, .part-intro > .pp { display: block !important; max-height: none !important; -webkit-mask-image: none !important; mask-image: none !important; }
  .tc-more, .tc-less, .tailor, .switch, .pop, .tc-sources { display: none !important; }
}

/* Cross-references inside the paper's text */
.xref { font-family: var(--sans); font-size: .88em; font-weight: 700; color: var(--accent-ink); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 35%, transparent); text-underline-offset: 3px; }
.xref:hover { text-decoration-color: currentColor; }
.cw { white-space: nowrap; }
.cw .cite { white-space: normal; }

/* Model evaluation and agent evaluation */
.diagram .ae { min-width: 860px; }
.svg-fig .ae-col { font-size: 11px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; fill: var(--muted); }
.svg-fig .ae-rule { stroke: var(--hair); stroke-width: 1.2; }
.svg-fig .ae-row { font-size: 14px; font-weight: 700; fill: var(--ink); }
.svg-fig .ae-note { font-size: 13px; fill: var(--ink-2); }
.svg-fig .ae-note.risk { fill: var(--risk); font-weight: 600; }
.svg-fig .nd rect { transition: fill .18s, stroke .18s, stroke-width .18s; }
.svg-fig .nd.busy rect { fill: var(--accent-wash-2); stroke: var(--accent); stroke-width: 2.2; }
.svg-fig .nd.pass rect { stroke: var(--accent); stroke-width: 1.8; }
.svg-fig .nd.pass .nd-sub { fill: var(--accent-ink); font-weight: 650; }
.svg-fig .nd.fail rect { stroke: var(--risk); stroke-width: 1.8; }
.svg-fig .nd.fail .nd-sub { fill: var(--risk); font-weight: 650; }
.diagram .dot-ref { fill: var(--muted); }
.diagram .dot-rec { fill: var(--s1); }
.diagram .dot-human { fill: var(--s2); }
.diagram .traj-tick.t-human { fill: var(--surface); stroke: var(--s2); stroke-width: 1.6; }
.diagram .traj-tick.t-flag { fill: var(--risk); }
.svg-fig .on .flow { stroke: var(--s2); stroke-width: 2.4; }
.svg-fig .on .flow-head { fill: var(--s2); }
.ae-tally { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 18px; font-family: var(--sans); }
@media (max-width: 720px) { .ae-tally { grid-template-columns: minmax(0, 1fr); } }
.ae-card { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; background: var(--surface); }
.ae-card h4 { font-family: var(--serif); font-size: 1.02rem; margin: 0 0 10px; }
.ae-card dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 5px 16px; margin: 0; font-size: 13.5px; }
.ae-card dt { color: var(--muted); }
.ae-card dd { margin: 0; color: var(--ink); font-variant-numeric: tabular-nums; }
.ae-runs-label { font-size: 12px; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 12px 0 6px; }
.ae-runs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12.5px; }
.ae-none { color: var(--muted); }
.ae-run { border-radius: 999px; padding: 2px 10px; font-weight: 650; }
.ae-run.ok { background: var(--accent-wash); color: var(--accent-ink); }
.ae-run.no { background: var(--risk-wash); color: var(--risk); }
.ae-run small { font-weight: 500; margin-left: 6px; font-size: 11.5px; }
.scroll-hint { display: none; font-family: var(--sans); font-size: 12.5px; color: var(--muted); margin: 0 0 8px; }
@media (max-width: 900px) { .scroll-hint { display: block; } }
#fig-agent .fig-controls { gap: 10px; }
