/* ReGE project page */

:root {
  color-scheme: light;
  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Source Serif 4", "Source Serif Pro", ui-serif, Georgia, Cambria, "Times New Roman", serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --bg: #fbfbfc;
  --bg-alt: #f2f4f7;
  --surface: #ffffff;
  --surface-2: #f6f7f9;
  --border: #e3e6eb;
  --border-strong: #cbd1da;
  --text: #141a24;
  --text-2: #3d4757;
  --text-3: #697386;
  --accent: #be3455;
  --accent-text: #a52a48;
  --accent-soft: #fbe9ee;
  --accent-ring: rgba(190, 52, 85, 0.3);
  --mark-ours: #be3455;
  --mark-base: #8393a8;
  --mark-ctl: #c4cbd6;
  --mark-build: #d97706;
  --mark-exec: #9aa9bd;
  --tint-blue: #3a6ea5;
  --grid: #e8ebef;
  --axis: #8f99a8;
  --shadow-sm: 0 1px 2px rgba(20, 26, 36, 0.06);
  --shadow: 0 1px 2px rgba(20, 26, 36, 0.04), 0 22px 44px -28px rgba(20, 26, 36, 0.28);
  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1120px;
  --prose: 780px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0d1016;
    --bg-alt: #11151d;
    --surface: #161b24;
    --surface-2: #1a202b;
    --border: #252c38;
    --border-strong: #323b4a;
    --text: #e8ecf2;
    --text-2: #b3bccb;
    --text-3: #8590a3;
    --accent: #d9496b;
    --accent-text: #f08aa3;
    --accent-soft: rgba(217, 73, 107, 0.15);
    --accent-ring: rgba(240, 138, 163, 0.35);
    --mark-ours: #e0607e;
    --mark-base: #7d8ca2;
    --mark-ctl: #4a5464;
    --mark-build: #f0a23b;
    --mark-exec: #5f6f86;
    --tint-blue: #7ea6d6;
    --grid: #222a36;
    --axis: #5f6b7d;
    --shadow-sm: none;
    --shadow: 0 22px 44px -28px rgba(0, 0, 0, 0.7);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1016;
  --bg-alt: #11151d;
  --surface: #161b24;
  --surface-2: #1a202b;
  --border: #252c38;
  --border-strong: #323b4a;
  --text: #e8ecf2;
  --text-2: #b3bccb;
  --text-3: #8590a3;
  --accent: #d9496b;
  --accent-text: #f08aa3;
  --accent-soft: rgba(217, 73, 107, 0.15);
  --accent-ring: rgba(240, 138, 163, 0.35);
  --mark-ours: #e0607e;
  --mark-base: #7d8ca2;
  --mark-ctl: #4a5464;
  --mark-build: #f0a23b;
  --mark-exec: #5f6f86;
  --tint-blue: #7ea6d6;
  --grid: #222a36;
  --axis: #5f6b7d;
  --shadow-sm: none;
  --shadow: 0 22px 44px -28px rgba(0, 0, 0, 0.7);
}

/* ---------- base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.7 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--accent-text); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
p { margin: 0 0 1em; }
b, strong { font-weight: 650; }
code { font-family: var(--font-mono); font-size: 0.88em; white-space: nowrap; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.prose { max-width: var(--prose); }
.muted { color: var(--text-3); }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ---------- navigation ---------- */

.nav {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner { display: flex; align-items: center; gap: 12px; height: 62px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; font-size: 17px; letter-spacing: -0.01em; }
.brand:hover { text-decoration: none; }
.brand img { width: 26px; height: 26px; }
.nav-links { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.nav-links a { color: var(--text-2); font-size: 14.5px; font-weight: 500; padding: 7px 12px; border-radius: 999px; }
.nav-links a:hover { color: var(--text); background: var(--bg-alt); text-decoration: none; }
.icon-btn {
  display: inline-grid; place-items: center; width: 38px; height: 38px; margin-left: 4px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--surface); color: var(--text-2); cursor: pointer;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-strong); }
.icon-btn svg { width: 18px; height: 18px; }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .moon { display: block; }
}
@media (max-width: 860px) { .nav-links a.optional { display: none; } }
@media (max-width: 600px) { .nav-links a { display: none; } }

/* ---------- hero ---------- */

.hero { position: relative; padding: 76px 0 36px; text-align: center; isolation: isolate; overflow-x: clip; }
.hero::before {
  content: ""; position: absolute; z-index: -1; left: 50%; top: -120px; width: min(1100px, 140vw); height: 560px;
  transform: translateX(-50%);
  background:
    radial-gradient(closest-side, var(--accent-soft), transparent 72%),
    radial-gradient(40% 50% at 78% 30%, color-mix(in srgb, var(--tint-blue) 10%, transparent), transparent 70%);
  pointer-events: none;
}
.hero::after {
  content: ""; position: absolute; z-index: -1; inset: -62px 0 auto 0; height: 520px; pointer-events: none;
  background-image: radial-gradient(var(--border) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 30%, #000 30%, transparent 75%);
  mask-image: radial-gradient(70% 60% at 50% 30%, #000 30%, transparent 75%);
  opacity: 0.7;
}
.news {
  display: inline-flex; align-items: center; gap: 10px; max-width: 100%;
  padding: 5px 14px 5px 6px; border: 1px solid var(--border); border-radius: 999px;
  background: var(--surface); color: var(--text-2); font-size: 13.5px; box-shadow: var(--shadow-sm);
}
.news:hover { text-decoration: none; border-color: var(--border-strong); color: var(--text); }
.news .tag { padding: 2px 9px; border-radius: 999px; background: var(--accent); color: #fff; font-weight: 650; font-size: 12px; letter-spacing: 0.02em; }
.news .arrow { color: var(--text-3); }
.hero h1 {
  max-width: 940px; margin: 24px auto 0;
  font-family: var(--font-serif); font-weight: 600; font-size: clamp(36px, 5.6vw, 62px);
  line-height: 1.07; letter-spacing: -0.022em; text-wrap: balance;
}
.hero h1 .name { color: var(--accent-text); }
.authors { margin: 26px auto 0; max-width: 820px; font-size: 18px; line-height: 1.8; color: var(--text); }
.authors span { white-space: nowrap; }
.authors span:not(:last-child)::after { content: "·"; display: inline-block; width: 1.5em; text-align: center; color: var(--text-3); }
.authors sup, .affil sup { margin-left: 1px; color: var(--text-3); font-size: 0.66em; font-weight: 600; }
.affil { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 22px; margin: 4px auto 0; max-width: 860px; color: var(--text-3); font-size: 15.5px; }
.affil span { white-space: nowrap; }

.links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 30px auto 0; max-width: 860px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 18px;
  border: 1px solid var(--border-strong); border-radius: 999px; background: var(--surface);
  color: var(--text); font-size: 15px; font-weight: 600; box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); border-color: var(--text-3); box-shadow: var(--shadow); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-ink { background: var(--text); border-color: var(--text); color: var(--bg); }
.btn-ink:hover { border-color: var(--text); }

/* ---------- sections ---------- */

.section { padding: 76px 0; }
.section.tight-top { padding-top: 20px; }
.section.alt { background: var(--bg-alt); border-block: 1px solid var(--border); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--accent-text); font-size: 12.5px; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase;
}
.eyebrow .num {
  display: inline-grid; place-items: center; min-width: 28px; height: 22px; padding: 0 6px;
  border-radius: 6px; background: var(--accent-soft); font-size: 12px; letter-spacing: 0.02em;
}
h2 {
  margin: 12px 0 14px; font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(28px, 3.5vw, 40px); line-height: 1.14; letter-spacing: -0.016em; text-wrap: balance;
}
h3 { margin: 0 0 8px; font-size: 19px; font-weight: 650; line-height: 1.35; letter-spacing: -0.01em; }
.lede { max-width: var(--prose); color: var(--text-2); font-size: 18px; }
.sub-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; margin: 52px 0 16px; }
.sub-head h3 { margin: 0; font-size: 21px; }
.sub-head p { margin: 0; color: var(--text-3); font-size: 14.5px; }

/* ---------- figures ---------- */

.figure { margin: 0; padding: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.figure img { width: 100%; border-radius: 10px; background: #fff; }
.figure .zoom { display: block; cursor: zoom-in; }
.figure figcaption { margin: 16px 6px 2px; color: var(--text-2); font-size: 14.5px; line-height: 1.65; }
.figure figcaption b { color: var(--text); }
@media (max-width: 640px) { .figure { padding: 10px; border-radius: var(--radius-sm); } .figure figcaption { margin: 12px 4px 2px; } }

/* ---------- teaser ---------- */

.teaser { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: center; gap: 28px 52px; }
.teaser .figure { width: 100%; max-width: 600px; justify-self: center; }
.teaser-text h2 { margin-top: 0; font-size: clamp(26px, 3vw, 34px); }
.teaser-text h2 em { font-style: normal; color: var(--accent-text); }
.teaser-text > p { color: var(--text-2); font-size: 17px; }
.teaser-text .chart-note { font-size: 13.5px; }
.kv { display: grid; gap: 12px; margin: 22px 0 6px; }
.kv > div { display: grid; grid-template-columns: 9.6em minmax(0, 1fr); gap: 16px; align-items: baseline; padding-top: 12px; border-top: 1px solid var(--border); }
.kv b { color: var(--text); font-size: 19px; font-weight: 650; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.kv span { color: var(--text-2); font-size: 14.5px; line-height: 1.55; }
@media (max-width: 900px) { .teaser { grid-template-columns: 1fr; } .teaser .figure { max-width: 560px; } }
@media (max-width: 520px) { .kv > div { grid-template-columns: 1fr; gap: 2px; } }

/* ---------- TL;DR ---------- */

.tldr { max-width: 860px; margin: 0 auto; text-align: center; font-family: var(--font-serif); font-size: clamp(21px, 2.4vw, 27px); line-height: 1.45; letter-spacing: -0.008em; text-wrap: balance; }
.tldr em { font-style: normal; color: var(--accent-text); }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.stat { padding: 22px 22px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); }
.stat::before { content: ""; display: block; width: 28px; height: 3px; margin-bottom: 16px; border-radius: 3px; background: var(--accent); }
.stat .value { font-size: 36px; font-weight: 650; line-height: 1.05; letter-spacing: -0.025em; color: var(--text); }
.stat .value small { font-size: 0.5em; font-weight: 600; letter-spacing: 0; color: var(--text-2); }
.stat .label { margin-top: 10px; color: var(--text-2); font-size: 14.5px; line-height: 1.55; }
@media (max-width: 960px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .stats { grid-template-columns: 1fr; } }

/* ---------- abstract ---------- */

.abstract { font-size: 17.5px; line-height: 1.8; color: var(--text-2); }

/* ---------- method ---------- */

.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 32px 0 28px; }
.step { position: relative; padding: 24px 22px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.step .k { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; color: var(--text-3); font: 600 12px/1 var(--font-mono); letter-spacing: 0.04em; text-transform: uppercase; }
.step .k b { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 7px; background: var(--accent-soft); color: var(--accent-text); font-size: 12.5px; }
.step p { margin: 0; color: var(--text-2); font-size: 15.5px; line-height: 1.65; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }


/* ---------- design comparison ---------- */

.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); -webkit-overflow-scrolling: touch; }
table.compare { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 14.5px; }
.compare th, .compare td { padding: 12px 14px; text-align: center; white-space: nowrap; }
.compare th:first-child, .compare td:first-child { text-align: left; }
.compare thead th { background: var(--surface-2); color: var(--text-3); font-size: 12.5px; font-weight: 600; line-height: 1.35; vertical-align: bottom; border-bottom: 1px solid var(--border); }
.compare tbody tr + tr td { border-top: 1px solid var(--border); }
.compare td:first-child { color: var(--text); font-weight: 600; }
.compare td { color: var(--text-2); }
.compare .ours { background: color-mix(in srgb, var(--accent-soft) 70%, transparent); color: var(--text); font-weight: 650; }
.compare thead th.ours { color: var(--accent-text); }
.mark { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font: 700 13px/1 var(--font-sans); }
.mark.yes { background: rgba(46, 125, 79, 0.14); color: #2c7a4c; }
.mark.no { background: rgba(190, 52, 85, 0.1); color: #b23a52; }
:root[data-theme="dark"] .mark.yes { color: #7fd3a1; }
:root[data-theme="dark"] .mark.no { color: #f08aa3; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .mark.yes { color: #7fd3a1; }
  :root:not([data-theme="light"]) .mark.no { color: #f08aa3; }
}

/* ---------- charts ---------- */

.card { padding: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
@media (max-width: 640px) { .card { padding: 16px; border-radius: var(--radius-sm); } }
.card-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 18px; margin-bottom: 18px; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--text-2); font-size: 13.5px; }
.legend .key { display: inline-flex; align-items: center; gap: 8px; }
.swatch { display: inline-block; width: 14px; height: 10px; border-radius: 3px; }
.swatch.ours { background: var(--mark-ours); }
.swatch.base { background: var(--mark-base); }
.swatch.ctl { background: var(--mark-ctl); }
.swatch.build { background: var(--mark-build); }
.swatch.exec { background: var(--mark-exec); }

.multiples { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 36px; }
@media (max-width: 780px) { .multiples { grid-template-columns: 1fr; } }
.panel-title { margin: 0 0 4px; font-size: 14.5px; font-weight: 650; color: var(--text); }
.panel-title span { color: var(--text-3); font-weight: 500; }
.chart { position: relative; min-height: 40px; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart text { font-family: var(--font-sans); }
.chart .tick { font-size: 11px; fill: var(--text-3); font-variant-numeric: tabular-nums; }
.chart .grid { stroke: var(--grid); stroke-width: 1; shape-rendering: crispEdges; }
.chart .zero { stroke: var(--axis); stroke-width: 1; shape-rendering: crispEdges; }
.chart .row-label { font-size: 12.5px; fill: var(--text-2); }
.chart .row-label.ours { fill: var(--text); font-weight: 650; }
.chart .value { font-size: 12px; fill: var(--text-2); font-variant-numeric: tabular-nums; }
.chart .value.strong { fill: var(--text); font-weight: 650; }
.chart .na { font-size: 11.5px; fill: var(--text-3); font-style: italic; }
.chart .bar.ours { fill: var(--mark-ours); }
.chart .bar.base { fill: var(--mark-base); }
.chart .bar.ctl { fill: var(--mark-ctl); }
.chart .bar.build { fill: var(--mark-build); }
.chart .bar.exec { fill: var(--mark-exec); }
.chart .row { outline: none; }
.chart .row .hover { fill: var(--accent-soft); opacity: 0; transition: opacity 0.12s ease; }
.chart .row:hover .hover, .chart .row:focus-visible .hover { opacity: 1; }
.chart .ref { stroke: var(--text-2); stroke-width: 1.5; stroke-dasharray: 3 3; }
.chart-note { margin: 18px 0 0; color: var(--text-3); font-size: 13.5px; line-height: 1.65; }

.tooltip {
  position: fixed; z-index: 100; pointer-events: none; min-width: 200px; max-width: 280px;
  padding: 11px 13px; border: 1px solid var(--border); border-radius: 11px; background: var(--surface);
  box-shadow: 0 14px 34px -14px rgba(0, 0, 0, 0.35); color: var(--text); font-size: 13px; line-height: 1.5;
}
.tooltip[hidden] { display: none; }
.tooltip .tt-title { margin-bottom: 7px; font-weight: 650; }
.tooltip .tt-sub { margin: -5px 0 7px; color: var(--text-3); font-size: 12px; }
.tooltip .tt-row { display: flex; justify-content: space-between; gap: 16px; color: var(--text-2); }
.tooltip .tt-row b { color: var(--text); font-weight: 650; font-variant-numeric: tabular-nums; }

/* ---------- results table ---------- */

.tabs { display: inline-flex; flex-wrap: wrap; gap: 4px; max-width: 100%; padding: 4px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: 13px; }
.section.alt .tabs, .card .tabs { background: var(--surface-2); }
.tab {
  appearance: none; padding: 9px 14px; border: 0; border-radius: 9px; background: transparent; cursor: pointer;
  color: var(--text-2); font: 600 14px/1.2 var(--font-sans);
}
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08), 0 0 0 1px var(--border); }
.tab code { font-size: 0.92em; }
.table-meta { margin: 14px 2px 12px; color: var(--text-3); font-size: 14px; }
table.results { width: 100%; min-width: 720px; border-collapse: collapse; font-size: 14.5px; }
.results th, .results td { padding: 11px 16px; text-align: right; white-space: nowrap; }
.results td:not(:first-child) { font-variant-numeric: tabular-nums; }
.results th:first-child, .results td:first-child { text-align: left; }
.results thead th { background: var(--surface-2); color: var(--text-3); font-size: 12.5px; font-weight: 600; line-height: 1.35; vertical-align: bottom; border-bottom: 1px solid var(--border); }
.results thead .arrow { color: var(--text-3); font-weight: 500; }
.results tbody tr + tr td { border-top: 1px solid var(--border); }
.results tbody tr.sep td { border-top: 1px solid var(--border-strong); }
.results tr.ours td { background: color-mix(in srgb, var(--accent-soft) 70%, transparent); }
.results td .who { display: inline-flex; align-items: center; gap: 9px; }
.results td .who i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; background: var(--mark-base); }
.results tr.ctl td .who i { background: var(--mark-ctl); }
.results tr.ours td .who i { background: var(--mark-ours); }
.results tr.ours td:first-child { font-weight: 650; }
.results td { color: var(--text-2); }
.results td:first-child { color: var(--text); }
.results td .acc { color: var(--text); }
.results td.best .acc { font-weight: 700; }
.results td .cost { margin-left: 8px; color: var(--text-3); font-size: 12.5px; }
.results td.avg { background: color-mix(in srgb, var(--surface-2) 70%, transparent); }
.results tr.ours td.avg { background: color-mix(in srgb, var(--accent-soft) 85%, transparent); }
.results td.second .acc { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

table.models { min-width: 900px; }
.models th, .models td { padding: 10px 12px; text-align: center; }
.models th:first-child, .models td:first-child { text-align: left; }
.models thead tr.groups th { padding: 12px 12px 6px; border-bottom: 0; color: var(--text-2); font-weight: 650; }
.models thead tr.groups th[colspan] { box-shadow: inset 0 -1px 0 var(--border-strong); }
.models .split { border-left: 1px solid var(--border-strong); }
.models th.ours { color: var(--accent-text); }
.models th.ours, .models td.ours { background: color-mix(in srgb, var(--accent-soft) 70%, transparent); }
.models td.best { color: var(--text); font-weight: 700; }
.models td.second { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.models tbody tr.avg td { border-top: 1px solid var(--border-strong); background: color-mix(in srgb, var(--surface-2) 70%, transparent); }
.models tbody tr.avg td:first-child { color: var(--text); font-weight: 650; }
.models tbody tr.avg td.ours { background: color-mix(in srgb, var(--accent-soft) 85%, transparent); }
.models .n { margin-left: 6px; color: var(--text-3); font-size: 12.5px; font-weight: 500; font-variant-numeric: tabular-nums; }
.defs { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px 26px; margin: 18px 2px 0; color: var(--text-3); font-size: 13.5px; line-height: 1.55; }
.defs b { color: var(--text-2); font-weight: 650; }

/* ---------- findings ---------- */

.findings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 32px; }
.finding { padding: 26px 26px 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.finding .kicker { color: var(--text-3); font-size: 12.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.finding .big { margin: 10px 0 10px; color: var(--text); font-size: 30px; font-weight: 650; line-height: 1.12; letter-spacing: -0.022em; }
.finding .big small { color: var(--text-3); font-size: 15px; font-weight: 500; letter-spacing: 0; }
.finding p { margin: 0; color: var(--text-2); font-size: 15.5px; line-height: 1.65; }
@media (max-width: 780px) { .findings { grid-template-columns: 1fr; } }

/* ---------- execution cases ---------- */

.cases { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 32px; }
.case { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.case-head { padding: 20px 22px 16px; border-bottom: 1px solid var(--border); }
.case-head .where { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.chip { padding: 2px 8px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); font: 600 12px/1.5 var(--font-mono); }
.case-head h3 { margin: 0; }
.stage { position: relative; padding: 16px 22px 16px 46px; }
.stage + .stage { border-top: 1px dashed var(--border); }
.stage::before {
  content: attr(data-n); position: absolute; left: 16px; top: 17px; display: grid; place-items: center; width: 20px; height: 20px;
  border-radius: 6px; background: var(--accent-soft); color: var(--accent-text); font: 700 11.5px/1 var(--font-sans);
}
.stage .label { margin-bottom: 4px; color: var(--text); font-size: 14px; font-weight: 650; }
.stage p { margin: 0; color: var(--text-2); font-size: 15px; line-height: 1.62; }
.stage.outcome { flex: 1; background: color-mix(in srgb, var(--accent-soft) 45%, transparent); }
@media (max-width: 860px) { .cases { grid-template-columns: 1fr; } }

/* ---------- bibtex ---------- */

.bib { position: relative; margin-top: 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.bib pre { margin: 0; padding: 22px 24px; overflow-x: auto; color: var(--text); font: 13.5px/1.75 var(--font-mono); }
.bib .copy {
  position: absolute; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px;
  border: 1px solid var(--border); border-radius: 8px; background: var(--surface-2);
  color: var(--text-2); font: 600 12.5px/1 var(--font-sans); cursor: pointer;
}
.bib .copy:hover { color: var(--text); border-color: var(--border-strong); }
.copy svg { width: 14px; height: 14px; }

/* ---------- footer ---------- */

.footer { padding: 36px 0 54px; border-top: 1px solid var(--border); color: var(--text-3); font-size: 14px; }
.footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; }
.footer a { color: var(--text-2); }
.footer nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }

@media (max-width: 640px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .section { padding: 56px 0; }
  .hero { padding: 48px 0 24px; }
  .authors { font-size: 16px; }
  .btn { height: 40px; padding: 0 14px; font-size: 14.5px; }
  .abstract { font-size: 16.5px; }
}
