/* DASH project page. Plain CSS, no build step.
   Identity colours: --cond (conditional branch), --uncond (unconditional branch),
   --gap (guidance gap). They are identical across every figure, chart and control. */

/* Self-hosted subsets of Source Serif 4, Inter and JetBrains Mono (SIL Open Font License 1.1), from Google Fonts. */
@font-face {
  font-family: 'Source Serif 4'; font-style: normal; font-weight: 500; font-display: block;
  src: url(../fonts/SourceSerif4-500-normal-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Source Serif 4'; font-style: italic; font-weight: 500; font-display: block;
  src: url(../fonts/SourceSerif4-500-italic-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Inter'; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(../fonts/Inter-normal-greek.woff2) format('woff2');
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: 'Inter'; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(../fonts/Inter-normal-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono'; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url(../fonts/JetBrainsMono-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face { font-family: 'Source Serif Fallback'; src: local('Georgia'); font-style: normal; font-weight: 500; size-adjust: 105.92%; }
@font-face { font-family: 'Source Serif Fallback'; src: local('Georgia Italic'), local('Georgia-Italic'); font-style: italic; font-weight: 500; size-adjust: 98.66%; }
@font-face { font-family: 'Inter Fallback'; src: local('Arial'), local('Helvetica Neue'), local('Helvetica'); size-adjust: 107.12%; ascent-override: 90.44%; descent-override: 22.52%; line-gap-override: 0%; }

:root {
  --bg: #eef1f6;
  --surface: #ffffff;
  --tint: #e5e9f0;
  --ink: #12151b;
  --ink-2: #3a3f4a;
  --muted: #565e6b;
  --line: #d9dee7;
  --line-2: #c4cbd7;
  --grid: #e8ecf2;
  --cond: #234fa8;
  --uncond: #c96a1e;
  --gap: #6d4fc2;
  --accent: #1b3f8f;
  --good: #1d7a45;
  --link: #1b3f8f;
  --focus: #234fa8;
  --hl: rgba(27, 63, 143, 0.05);
  --hl-2: rgba(27, 63, 143, 0.11);
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px -12px rgba(16, 24, 40, .14);
  --sig: linear-gradient(90deg, var(--cond), var(--gap), var(--uncond));

  --f-display: "Source Serif 4", "Source Serif Fallback", Georgia, serif;
  --f-body: "Inter", "Inter Fallback", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;

  --step--1: clamp(.82rem, .79rem + .12vw, .9rem);
  --step-0: clamp(1rem, .96rem + .2vw, 1.0625rem);
  --step-1: clamp(1.1rem, 1.04rem + .3vw, 1.25rem);
  --step-2: clamp(1.9rem, 1.4rem + 1.9vw, 3rem);

  --wrap: 1120px;
  --gutter: 16px;
  --r: 14px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d1016; --surface: #141821; --tint: #10131a; --ink: #e8eaef; --ink-2: #c3c8d2; --muted: #98a0ad;
    --line: #252a35; --line-2: #343a47; --grid: #1d222c;
    --cond: #5584e0; --uncond: #d27a35; --gap: #9478e0; --accent: #7fa3ee; --good: #4cc27f; --link: #7fa3ee; --focus: #7fa3ee;
    --hl: rgba(127, 163, 238, 0.07); --hl-2: rgba(127, 163, 238, 0.14);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 32px -12px rgba(0, 0, 0, .55);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0d1016; --surface: #141821; --tint: #10131a; --ink: #e8eaef; --ink-2: #c3c8d2; --muted: #98a0ad;
    --line: #252a35; --line-2: #343a47; --grid: #1d222c;
    --cond: #5584e0; --uncond: #d27a35; --gap: #9478e0; --accent: #7fa3ee; --good: #4cc27f; --link: #7fa3ee; --focus: #7fa3ee;
    --hl: rgba(127, 163, 238, 0.07); --hl-2: rgba(127, 163, 238, 0.14);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 32px -12px rgba(0, 0, 0, .55);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 var(--step-0)/1.65 var(--f-body);
  font-feature-settings: "cv11", "ss01";
  overflow-x: hidden; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--link); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2.5px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
sub, sup { line-height: 0; }
button { font: inherit; color: inherit; }
strong { font-weight: 650; }
::selection { background: color-mix(in srgb, var(--gap) 28%, transparent); }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; }
.skip:focus { top: 12px; }
.muted { color: var(--muted); }
.small { font-size: var(--step--1); }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.wrap--narrow { max-width: 820px; }
@media (min-width: 720px) { :root { --gutter: 32px; } }

/* KaTeX inline */
.tm .katex { font-size: 1.06em; }
.tm { white-space: nowrap; }

/* ---------------- nav ---------------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav__progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; }
.nav__progress span { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }
.nav__inner { max-width: var(--wrap); margin-inline: auto; padding: 0 var(--gutter); height: 58px; display: flex; align-items: center; gap: 12px; }
.nav__brand { display: inline-flex; align-items: center; gap: 9px; font: 500 1.12rem/1 var(--f-display); letter-spacing: .01em; color: var(--ink); text-decoration: none; margin-right: auto; }
.nav__links { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; }
.nav__links a { display: block; padding: 6px 11px; border-radius: 8px; color: var(--ink-2); text-decoration: none; font-size: .88rem; font-weight: 500; }
.nav__links a:hover, .nav__links a[aria-current="true"] { color: var(--accent); background: var(--hl); }
.nav__toggle, .theme-btn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; color: var(--ink); }
.nav__toggle { display: none; }
.theme-btn .i-moon { display: none; }
:root[data-theme="dark"] .theme-btn .i-sun { display: none; }
:root[data-theme="dark"] .theme-btn .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .i-sun { display: none; }
  :root:not([data-theme="light"]) .theme-btn .i-moon { display: block; }
}
@media (max-width: 880px) {
  .nav__toggle { display: inline-grid; order: 3; }
  .theme-btn { order: 2; }
  .nav nav { order: 4; }
  .nav__links { display: none; position: absolute; left: 0; right: 0; top: 58px; flex-direction: column; padding: 8px var(--gutter) 14px; background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .nav__links.is-open { display: flex; }
  .nav__links a { padding: 11px 8px; font-size: 1rem; }
}

/* ---------------- hero ---------------- */
.hero { position: relative; overflow: hidden; padding: clamp(40px, 6vw, 76px) 0 clamp(40px, 5vw, 64px); text-align: center; border-bottom: 1px solid var(--line); }
.hero__bg { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, var(--tint), var(--bg) 70%); }
.hero__bg::after { content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(color-mix(in srgb, var(--ink) 7%, transparent) 1px, transparent 1.2px);
  background-size: 22px 22px; mask-image: linear-gradient(to bottom, #000, transparent 45%); -webkit-mask-image: linear-gradient(to bottom, #000, transparent 45%); }
.hero__inner { position: relative; }
.venue { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: .76rem; font-weight: 600; letter-spacing: .02em; color: var(--ink-2); }
.venue__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.hero__title { margin: 0 auto; max-width: 1040px; font: 500 clamp(1.5rem, 1.05rem + 1.75vw, 2.45rem)/1.2 var(--f-display); letter-spacing: -.012em; color: var(--ink); text-wrap: balance; }
.brand-word { color: var(--accent); font-style: italic; padding-right: .04em; }
.authors { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 22px; margin: 22px 0 6px; padding: 0; font-weight: 500; font-size: 1rem; }
.authors a, .authors span { color: var(--ink); }
.authors a { color: var(--accent); text-decoration: none; }
.authors a:hover { text-decoration: underline; }
.authors sup { color: var(--muted); font-weight: 500; margin-left: 1px; font-size: .68em; }
.affils { list-style: none; margin: 0; padding: 0; font-size: .86rem; color: var(--muted); display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 20px; }
.affils sup { margin-right: 3px; }
.pills { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 22px 0 0; padding: 0; }
.pill { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 5px 13px 5px 11px; border-radius: 8px; background: var(--ink); color: var(--bg); font-weight: 600; font-size: .82rem; text-decoration: none; border: 1px solid var(--ink); transition: background .15s, color .15s, border-color .15s; }
.pill svg { width: 14px; height: 14px; }
.pill:hover { background: var(--accent); border-color: var(--accent); color: #fff; text-decoration: none; }
.pill--ghost { background: var(--surface); color: var(--ink); border-color: var(--line-2); }
.pill--ghost:hover { background: var(--hl); color: var(--accent); border-color: var(--accent); }

.teaser { margin: clamp(30px, 4vw, 44px) auto 0; max-width: 1000px; text-align: left; }
.teaser__classes { list-style: none; margin: 0 0 6px; padding: 0; display: grid; grid-template-columns: repeat(10, 1fr); font-size: clamp(.55rem, .4rem + .45vw, .76rem); font-weight: 600; letter-spacing: .02em; color: var(--muted); text-align: center; }
.teaser__classes li { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.teaser__row { position: relative; }
.teaser__row + .teaser__row { margin-top: 10px; }
.teaser__row picture, .teaser__row img { display: block; width: 100%; border-radius: 8px; overflow: hidden; }
.teaser__row img { box-shadow: var(--shadow); background: #fff; }

.teaser__lbl { margin: 8px 0 0; font-size: .86rem; color: var(--muted); }
.teaser__lbl b { margin-right: 6px; }
.teaser__lbl b { color: var(--ink); font-weight: 650; }
.teaser__row--ours .teaser__lbl b { color: var(--accent); }
.teaser figcaption { margin-top: 14px; font-size: var(--step--1); color: var(--muted); text-align: center; }

.hero__lede { margin: clamp(30px, 4vw, 40px) auto 0; max-width: 68ch; font-size: 1.08rem; line-height: 1.65; color: var(--ink-2); }
.hero__lede strong { color: var(--ink); }

.stats { display: grid; grid-template-columns: repeat(5, 1fr); margin: 30px auto 0; padding: 0; max-width: 1060px; border: 1px solid var(--line); border-radius: var(--r); background: color-mix(in srgb, var(--surface) 82%, transparent); overflow: hidden; text-align: left; box-shadow: var(--shadow-sm); }
.stat { padding: 18px 18px 16px; border-left: 1px solid var(--line); position: relative; }
.stat:first-child { border-left: 0; }
.stat::before { content: none; }
.stat dt { font-size: .8rem; font-weight: 600; color: var(--muted); }
.stat dd { margin: 0; }
.stat__num { display: block; font: 500 clamp(1.6rem, 1.3rem + 1vw, 2.1rem)/1.1 var(--f-display); color: var(--ink); height: 1.1em; margin-top: 4px; font-variant-numeric: tabular-nums; contain: strict; white-space: nowrap; }
.stat__note { font-size: .8rem; color: var(--ink-2); line-height: 1.45; margin-top: 4px !important; }
@media (max-width: 980px) { .stats { grid-template-columns: repeat(2, 1fr); } .stat { border-left: 0; border-top: 1px solid var(--line); } .stat:nth-child(-n+2) { border-top: 0; } .stat:nth-child(2n) { border-left: 1px solid var(--line); } .stat:last-child { grid-column: 1 / -1; border-left: 0; } }

/* ---------------- sections ---------------- */
.section { padding: clamp(56px, 7.5vw, 96px) 0; }
.section--tint { background: var(--tint); border-block: 1px solid var(--line); }
.band--video { padding: 40px 0 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 12px; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.eyebrow::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--accent); }
.h2 { font: italic 500 clamp(1.55rem, 1.25rem + 1.2vw, 2.15rem)/1.2 var(--f-display); margin: 0 0 20px; max-width: 36ch; text-wrap: balance; letter-spacing: -.01em; }
.h2--sm { font-size: clamp(1.4rem, 1.2rem + .9vw, 1.85rem); }
.h3 { font-size: 1.06rem; font-weight: 650; margin: 0 0 10px; letter-spacing: -.01em; }
.prose { max-width: 70ch; color: var(--ink-2); }
.prose p { margin: 0 0 14px; }
.cap { font-size: var(--step--1); color: var(--muted); line-height: 1.6; margin: 12px 0 0; max-width: 84ch; }
.cap b { color: var(--ink-2); }

.video { border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: #000; box-shadow: var(--shadow); }
.video video { width: 100%; aspect-ratio: 16 / 9; }

/* cards */
.cards3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 880px) { .cards3 { grid-template-columns: minmax(0, 1fr); } }
.card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 24px 24px 22px; box-shadow: var(--shadow); overflow: hidden; }
.card::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--k); opacity: .9; }
.card h3 { font: italic 500 1.22rem/1.3 var(--f-display); margin: 6px 0 10px; }
.card p { margin: 0; color: var(--ink-2); font-size: .96rem; }
.card__k { font-size: .72rem !important; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted) !important; }
.defn { margin: 24px 0 0; padding: 16px 20px; border: 1px solid var(--line); border-left: 3px solid var(--accent); background: var(--hl); border-radius: var(--r); color: var(--ink-2); max-width: none; }
.defn strong { color: var(--ink); }

/* abstract */
.abstract p { margin: 0; font-size: 1.06rem; line-height: 1.8; color: var(--ink-2); }
.linkbtn { display: none; margin-top: 10px; background: none; border: 0; padding: 4px 0; color: var(--link); font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: .2em; }
@media (max-width: 720px) {
  .abstract.is-clamped p { display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
  .linkbtn { display: inline-block; }
}

/* ---------------- panels (shared surface for charts and widgets) ---------------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(10px, 2vw, 18px); box-shadow: var(--shadow-sm); }

/* ---------------- explorer ---------------- */
.explorer { margin: 36px 0 0; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); border: 1px solid var(--line); border-radius: calc(var(--r) + 4px); background: var(--surface); box-shadow: var(--shadow); overflow: hidden; }
.explorer__plot { padding: 14px 12px 6px; border-right: 1px solid var(--line); min-width: 0; }
.explorer__panel { padding: 22px 22px 18px; display: flex; flex-direction: column; gap: 18px; background: color-mix(in srgb, var(--tint) 55%, var(--surface)); }
.explorer .cap { grid-column: 1 / -1; margin: 0; padding: 14px 22px 18px; border-top: 1px solid var(--line); max-width: none; }
@media (max-width: 880px) { .explorer { grid-template-columns: minmax(0, 1fr); } .explorer__plot { border-right: 0; border-bottom: 1px solid var(--line); } }
.ctl label { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-weight: 600; font-size: .94rem; }
.ctl output { font: 500 .95rem var(--f-mono); color: var(--ink); background: var(--tint); border: 1px solid var(--line); padding: 1px 8px; border-radius: 6px; }
.ctl__help { margin: 4px 0 0; font-size: .8rem; color: var(--muted); }
input[type="range"] { width: 100%; margin: 10px 0 2px; accent-color: var(--gap); height: 28px; cursor: pointer; }
.fstrip { position: relative; height: 34px; margin: 2px 7px 0; }
.fstrip__tick { position: absolute; top: 0; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; font-size: .68rem; color: var(--muted); white-space: nowrap; line-height: 1.2; }
.fstrip__tick::before { content: ""; width: 2px; height: 8px; background: var(--uncond); border-radius: 1px; margin-bottom: 2px; }
.fstrip__tick--dash::before { background: var(--cond); }
.fstrip__grp::before { display: none; }
.fstrip__grp { color: var(--ink-2); font-weight: 600; }
.readouts { margin: 0; display: grid; gap: 10px; }
.readouts > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; border-bottom: 1px dashed var(--line-2); padding-bottom: 8px; }
.readouts dt { font-size: .88rem; color: var(--ink-2); }
.readouts dd { margin: 0; font: 500 .98rem var(--f-mono); text-align: right; }
.readouts .gapbars { display: block; border: 0; }
.readouts .gapbars dd { text-align: left; font: inherit; margin-top: 8px; display: grid; gap: 6px; }
.gapbar { display: grid; grid-template-columns: 92px 1fr; align-items: center; gap: 10px; font-size: .84rem; color: var(--ink-2); }
.gapbar__track { height: 12px; border-radius: 6px; background: var(--grid); overflow: hidden; }
.gapbar__fill { display: block; height: 100%; border-radius: 6px; background: var(--gap); transition: width .12s linear; }
.gapbar__fill--t { background: color-mix(in srgb, var(--gap) 40%, var(--grid)); }

/* svg chart text */
.chart { width: 100%; position: relative; }
.chart svg, #ex-svg { width: 100%; height: auto; overflow: visible; font-family: var(--f-body); }
.ax text, .lbl { fill: var(--muted); font-size: 12px; }
.lbl--ink { fill: var(--ink); font-weight: 600; }
.lbl--ink2 { fill: var(--ink-2); }
.ax line, .ax path { stroke: var(--line-2); }
.gridline { stroke: var(--grid); stroke-width: 1; }
.axis-title { fill: var(--ink-2); font-size: 12px; font-weight: 600; }

/* ---------------- method ---------------- */
.fig { margin: 0; }
.fig--paper picture { display: block; background: #fff; border-radius: var(--r); border: 1px solid var(--line); padding: clamp(8px, 2vw, 22px); box-shadow: var(--shadow-sm); }
.fig--paper img { width: 100%; height: auto; }
@media (max-width: 720px) {
  .fig--wide .fig__scroll { overflow-x: auto; border-radius: var(--r); -webkit-overflow-scrolling: touch; }
  .fig--wide picture { min-width: 760px; }
  .fig--wide .fig__scroll::after { content: "Scroll sideways to see the full figure →"; display: block; font-size: .76rem; color: var(--muted); padding: 6px 2px 0; position: sticky; left: 0; }
}
:root[data-theme="dark"] .fig--paper picture { background: #f3f2ee; border-color: transparent; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .fig--paper picture { background: #f3f2ee; border-color: transparent; } }
.method-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 36px; margin-top: 52px; align-items: start; }
@media (max-width: 920px) { .method-grid { grid-template-columns: minmax(0, 1fr); } }
.eqs p { color: var(--ink-2); }
.eq { position: relative; margin: 10px 0; padding: 10px 46px 10px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; min-height: 50px; font-size: 1.04rem; }
.eq::after { content: "(" attr(data-tag) ")"; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-size: .8rem; color: var(--muted); font-family: var(--f-mono); }
.eq--main { border: 1px solid var(--line); border-left: 3px solid var(--accent); }
.eq--plain { padding: 10px 14px; margin: 18px 0; background: var(--tint); font-size: 1.1rem; }
.eq--plain::after { content: none; }
.eq:not(.is-rendered) { font-size: .78rem; color: var(--muted); }
.note { margin-top: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.note summary { cursor: pointer; padding: 12px 14px; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.note summary::-webkit-details-marker { display: none; }
.note summary::after { content: "+"; font: 500 1.1rem/1 var(--f-mono); color: var(--accent); }
.note[open] summary::after { content: "−"; }
.note > *:not(summary) { margin: 0 14px 12px; }
.note p { font-size: .95rem; }
.tag-plot { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px 16px 14px; position: sticky; top: 82px; box-shadow: var(--shadow-sm); }
.geom { margin-top: 56px; }
.geom__pair { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; max-width: 900px; }
@media (max-width: 640px) { .geom__pair { grid-template-columns: minmax(0, 1fr); } }

/* ---------------- results ---------------- */
.block { margin-top: 48px; }
.block__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.block__head .h3 { margin: 0; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; }
@media (max-width: 920px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }
.seg { display: inline-flex; padding: 3px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.seg__btn { border: 0; background: none; padding: 6px 12px; border-radius: 7px; cursor: pointer; font-size: .84rem; font-weight: 600; color: var(--ink-2); min-height: 34px; }
.seg__btn[aria-pressed="true"] { background: var(--ink); color: var(--bg); }

.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow-sm); }
.dtable { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .9rem; font-variant-numeric: tabular-nums; min-width: 640px; }
.dtable--compact { min-width: 420px; }
.dtable th, .dtable td { padding: 10px 12px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.dtable tbody tr:last-child > * { border-bottom: 0; }
.dtable th:first-child, .dtable td:first-child { text-align: left; white-space: normal; min-width: 170px; }
.dtable thead th { font-size: .76rem; font-weight: 700; letter-spacing: .03em; color: var(--muted); background: var(--tint); }
.dtable thead th button { all: unset; cursor: pointer; display: inline-flex; gap: 4px; align-items: center; padding: 2px 4px; border-radius: 4px; }
.dtable thead th button:focus-visible { outline: 2px solid var(--focus); }
.dtable thead th button::after { content: "↕"; opacity: .35; font-size: .9em; }
.dtable thead th[aria-sort="ascending"] button::after { content: "↑"; opacity: 1; color: var(--gap); }
.dtable thead th[aria-sort="descending"] button::after { content: "↓"; opacity: 1; color: var(--gap); }
.dtable tbody tr:hover > * { background: color-mix(in srgb, var(--hl) 70%, var(--surface)); }
.dtable tr.grp td { background: var(--tint); font-size: .7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding-top: 7px; padding-bottom: 7px; text-align: left; }
.dtable tr.is-ours > * { background: color-mix(in srgb, var(--gap) 7%, var(--surface)); font-weight: 650; color: var(--ink); }
.dtable tr.is-ours > *:first-child { box-shadow: inset 3px 0 0 var(--gap); }
.dtable tr.is-sel > * { background: color-mix(in srgb, var(--gap) 18%, var(--surface)); }
.dtable td.best { font-weight: 700; }
.dtable td.best::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--gap); margin-right: 6px; vertical-align: 2px; }
.dtable .fn { color: var(--gap); font-weight: 700; margin-left: 2px; }
.dtable .na { color: var(--muted); }
.dtable .ck { color: var(--good); font-weight: 700; }
.dtable .x { color: var(--muted); }
.dtable .dim { color: var(--muted); font-weight: 500; font-size: .8em; }
/* first column stays visible while a wide table scrolls on small screens */
@media (max-width: 720px) {
  .dtable th:first-child, .dtable td:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); min-width: 136px; max-width: 150px; box-shadow: 1px 0 0 var(--line); }
  .dtable thead th:first-child { background: var(--tint); }
  .dtable tr.grp td:first-child { background: var(--tint); }
  .dtable tr.grp td { position: static; }
}
.footnotes { margin: 12px 0 0; padding: 0; list-style: none; font-size: .8rem; color: var(--muted); display: grid; gap: 2px; }
.footnotes .fn { color: var(--gap); font-weight: 700; margin-right: 6px; }
.pending { font-size: .8rem; color: var(--muted); margin: 6px 0 0; }

/* tooltip */
.tip { position: fixed; z-index: 80; pointer-events: none; background: var(--ink); color: var(--bg); font-size: .8rem; line-height: 1.45; padding: 8px 10px; border-radius: 8px; max-width: 260px; box-shadow: var(--shadow); }
.tip b { font-weight: 650; }

/* ---------------- compare ---------------- */
.compare { margin: 20px 0 0; }
.compare__labels { list-style: none; margin: 0 0 6px; padding: 0; display: grid; grid-template-columns: repeat(10, 1fr); font-size: clamp(.55rem, .4rem + .45vw, .78rem); color: var(--muted); text-align: center; font-weight: 600; }
.compare__labels li { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 1px; }
.compare__stage { position: relative; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #fff; aspect-ratio: 2 / 1; user-select: none; touch-action: pan-y; box-shadow: var(--shadow); }
.compare__img { position: absolute; inset: 0; }
.compare__img img { width: 100%; height: 100%; object-fit: cover; }
.compare__img--b { clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); }
.compare__handle { position: absolute; top: 0; bottom: 0; left: var(--pos, 50%); width: 0; pointer-events: none; }
.compare__handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: -1px; width: 2px; background: #fff; box-shadow: 0 0 0 1px rgba(255,255,255,.6); }
.compare__handle span { position: absolute; top: 50%; left: 0; width: 40px; height: 40px; transform: translate(-50%, -50%); border-radius: 50%; background: var(--surface); border: 2px solid var(--accent); box-shadow: var(--shadow); }
.compare__handle span::before { content: "‹ ›"; position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; color: var(--ink); letter-spacing: 2px; font-size: 15px; }
.compare__range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; z-index: 3; }
.compare__stage:focus-within .compare__handle span { outline: 3px solid var(--focus); outline-offset: 2px; }
.compare__tag { position: absolute; bottom: 10px; z-index: 2; padding: 3px 10px; border-radius: 999px; background: rgba(14,15,20,.78); color: #fff; font-size: .76rem; font-weight: 600; pointer-events: none; backdrop-filter: blur(4px); }
.compare__tag--b { left: 10px; }
.compare__tag--a { right: 10px; }
.compare__open { position: absolute; top: 10px; right: 10px; z-index: 4; width: 36px; height: 36px; border-radius: 9px; border: 0; background: rgba(14,15,20,.78); cursor: zoom-in; }
.compare__open::before { content: ""; position: absolute; inset: 10px; border: 2px solid #fff; border-radius: 2px; }

.lightbox { width: min(1400px, 96vw); max-height: 94vh; border: 1px solid var(--line); border-radius: var(--r); padding: 0; background: var(--surface); color: var(--ink); }
.lightbox::backdrop { background: rgba(8, 8, 12, .8); }
.lightbox__head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface); }
.lightbox__head .h3 { margin: 0; }
.lightbox__close { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-size: 1.5rem; cursor: pointer; }
.lightbox__body { padding: 16px; display: grid; gap: 18px; }
.lightbox__body figure { margin: 0; }
.lightbox__body img { width: 100%; height: auto; border-radius: 6px; }

/* ---------------- ablation ---------------- */
.abl { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); border: 1px solid var(--line); border-radius: calc(var(--r) + 4px); background: var(--surface); box-shadow: var(--shadow); margin: 24px 0 24px; overflow: hidden; }
@media (max-width: 880px) { .abl { grid-template-columns: minmax(0, 1fr); } }
.abl__controls { padding: 22px; border-right: 1px solid var(--line); display: grid; gap: 20px; align-content: start; background: color-mix(in srgb, var(--tint) 55%, var(--surface)); }
@media (max-width: 880px) { .abl__controls { border-right: 0; border-bottom: 1px solid var(--line); } }
.abl__result { padding: 22px; }
.chips { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips legend { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; padding: 0; }
.chip { --c: var(--cond); display: inline-flex; align-items: baseline; gap: 8px; min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line-2); background: var(--surface); cursor: pointer; font-weight: 650; transition: background .15s, border-color .15s; }
.chip--uncond { --c: var(--uncond); }
.chip--anchor { --c: var(--muted); }
.chip__d { font-weight: 500; font-size: .8rem; color: var(--muted); }
.chip[aria-pressed="true"] { border-color: var(--c); background: color-mix(in srgb, var(--c) 12%, var(--surface)); }
.chip[aria-pressed="false"] { text-decoration: line-through; text-decoration-color: var(--muted); color: var(--muted); }
.radio { display: flex; align-items: center; gap: 10px; width: 100%; font-size: .93rem; padding: 4px 0; cursor: pointer; }
.radio input { accent-color: var(--accent); width: 18px; height: 18px; }
.abl__name { font: italic 500 1.4rem/1.25 var(--f-display); margin: 0 0 14px; }
.abl__bars { display: grid; gap: 14px; }
.bar { display: grid; grid-template-columns: 112px 1fr 58px; align-items: center; gap: 10px; font-size: .86rem; }
.bar__lbl { color: var(--ink-2); }
.bar__track { position: relative; height: 14px; background: var(--grid); border-radius: 7px; }
.bar__fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 7px; transition: width .5s cubic-bezier(.2,.8,.2,1); }
.bar__ref { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--ink); border-radius: 1px; }
.bar__val { font: 500 .92rem var(--f-mono); text-align: right; }
.bar__group { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 6px 0 0; }

/* ---------------- efficiency ---------------- */
.effgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 980px) { .effgrid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .effgrid { grid-template-columns: minmax(0, 1fr); } }
.eff { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow-sm); }
.eff__k { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0; }
.eff__v { font: 500 1.7rem/1.15 var(--f-display); margin: 6px 0 14px; }
.eff__rows { display: grid; gap: 8px; }
.eff__row { display: grid; grid-template-columns: 96px 1fr; gap: 8px; align-items: center; font-size: .8rem; color: var(--ink-2); }
.eff__bar { display: block; height: 8px; border-radius: 4px; background: var(--grid); position: relative; }
.eff__bar span { position: absolute; inset: 0 auto 0 0; border-radius: 4px; background: var(--gap); }
.eff__bar span.t { background: var(--line-2); }
.eff__bar span.s { background: color-mix(in srgb, var(--gap) 40%, var(--line-2)); }
.eff__num { font-family: var(--f-mono); font-size: .74rem; color: var(--muted); display: block; margin-top: 2px; }
.eff-note { margin-top: 18px; padding: 14px 18px; border-radius: 12px; border: 1px dashed var(--line-2); font-size: .88rem; color: var(--ink-2); }

/* ---------------- limitations / bib / footer ---------------- */
.lims { list-style: none; counter-reset: lim; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (max-width: 760px) { .lims { grid-template-columns: minmax(0, 1fr); } }
.lims li { counter-increment: lim; position: relative; padding: 18px 20px 18px 58px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); color: var(--ink-2); font-size: .95rem; }
.lims li::before { content: counter(lim, decimal-leading-zero); position: absolute; left: 20px; top: 18px; font: 600 1rem/1.4 var(--f-mono); color: var(--accent); }
.bib { position: relative; }
.bib pre { margin: 0; padding: 22px; padding-top: 52px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow-x: auto; font: .82rem/1.7 var(--f-mono); color: var(--ink); box-shadow: var(--shadow-sm); }
.bib__copy { position: absolute; top: 12px; right: 12px; min-height: 34px; padding: 4px 14px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--tint); cursor: pointer; font-weight: 600; font-size: .84rem; }
.bib__copy:hover { border-color: var(--ink-2); }
.footer { padding: 48px 0 56px; font-size: .86rem; color: var(--muted); border-top: 1px solid var(--line); }
.footer__inner { display: grid; grid-template-columns: 1fr auto; gap: 18px 32px; align-items: start; }
@media (max-width: 760px) { .footer__inner { grid-template-columns: minmax(0, 1fr); } }
.footer__brand { display: flex; gap: 14px; align-items: flex-start; }
.footer__brand p { margin: 0; max-width: 52ch; }
.footer__title { font: 500 1.15rem/1 var(--f-display) !important; color: var(--ink); margin-bottom: 6px !important; }
.footer__links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer__links a { color: var(--ink-2); text-decoration: none; font-weight: 500; }
.footer__links a:hover { color: var(--ink); text-decoration: underline; }
.footer__meta { grid-column: 1 / -1; margin: 6px 0 0; padding-top: 18px; border-top: 1px solid var(--line); font-size: .8rem; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-weight: 600; font-size: .9rem; transition: opacity .2s, transform .2s; pointer-events: none; z-index: 90; }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- motion ---------------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
@media (forced-colors: active) {
  .brand-word { color: LinkText; }
}

/* Skip rendering work for sections far below the fold until they approach the viewport.
   `auto` remembers each section's real size once rendered, so scroll positions stay stable. */
#abstract, #problem, #method, #results, #samples, #ablation, #supp, #efficiency, #limitations, #bibtex, #author, .footer { content-visibility: auto; contain-intrinsic-size: auto 1600px; }
.cv-off #abstract, .cv-off #problem, .cv-off #method, .cv-off #results, .cv-off #samples, .cv-off #ablation, .cv-off #supp, .cv-off #efficiency, .cv-off #limitations, .cv-off #bibtex, .cv-off #author, .cv-off .footer { content-visibility: visible; }

/* ---------------- author card ---------------- */
.section--author { padding: clamp(44px, 6vw, 72px) 0; }
.author-card { display: grid; grid-template-columns: 112px 1fr; gap: 24px; align-items: start; padding: 24px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow-sm); }
@media (max-width: 560px) { .author-card { grid-template-columns: minmax(0, 1fr); } }
.author-card__photo img { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line); }
.author-card__name { font: italic 500 1.4rem/1.2 var(--f-display); margin: 0; }
.author-card__role { margin: 4px 0 0; font-size: .9rem; color: var(--ink-2); }
.author-card__note { margin: 10px 0 0; font-size: .9rem; color: var(--muted); max-width: 70ch; }
.author-card .eyebrow { margin-bottom: 6px; }
.social { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.social a { display: inline-flex; align-items: center; gap: 7px; min-height: 32px; padding: 4px 11px 4px 9px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); font-size: .82rem; font-weight: 500; text-decoration: none; transition: border-color .15s, color .15s, background .15s; }
.social a:hover { border-color: var(--accent); color: var(--accent); background: var(--hl); }
.social svg { width: 15px; height: 15px; flex: none; }

/* ---------------- justified text ---------------- */
/* Justify only where columns are wide enough; narrow phone columns stay ragged-right to avoid gaps. */
@media (min-width: 720px) {
  .prose p, .abstract p, .card p, .defn, .note p, .eqs > p, .lims li, .author-card__note, .eff-note {
    text-align: justify; text-justify: inter-word; hyphens: auto; -webkit-hyphens: auto;
  }
}
/* teaser class labels: too narrow on phones, so they move into the caption there */
.teaser__classes-inline { display: none; }
@media (max-width: 600px) {
  .teaser__classes { display: none; }
  .teaser__classes-inline { display: inline; }
}

/* ---------------- native diagrams (Fig. 1 pipeline, Fig. 2 geometry) ---------------- */
.diagram { margin: 0; padding: clamp(12px, 2vw, 20px); border: 1px solid var(--line); border-radius: calc(var(--r) + 4px); background: var(--surface); box-shadow: var(--shadow); }
.diagram__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.diagram__hint { margin: 0; }
.diagram__scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 10px; }
.diagram__canvas svg { display: block; width: 100%; height: auto; min-width: 760px; font-family: var(--f-body); }
@media (min-width: 761px) { .diagram__canvas svg { min-width: 0; } }
.diagram .cap { max-width: none; }
.paperfig { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.paperfig summary { cursor: pointer; font-size: .86rem; font-weight: 600; color: var(--accent); }
.paperfig .fig { margin-top: 12px; }

.pipe text { fill: var(--ink); }
.pbox__t { font: italic 500 17px var(--f-display); }
.pbox__s { font-size: 12px; fill: var(--muted) !important; }
.pbox__u { font-size: 11px; fill: var(--muted) !important; letter-spacing: .06em; }
.pnode__t { font: italic 500 16px var(--f-display); }
.pnode__t--sm { font-size: 13.5px; }
.plbl { font-size: 11.5px; fill: var(--muted) !important; }
.plbl--m { font: italic 500 13px var(--f-display); fill: var(--ink-2) !important; }
.plbl--gold { fill: #a87f0f !important; font-weight: 600; }
:root[data-theme="dark"] .plbl--gold { fill: #e0b84a !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .plbl--gold { fill: #e0b84a !important; } }
.plbl--stop, .plbl--bwd { font-weight: 600; }
.plbl--bwd { fill: var(--gap) !important; }
.pnode--loss { cursor: pointer; outline: none; }
.pnode--loss:focus-visible rect { stroke-width: 3; }
.pedge { transition: opacity .2s; }
.pedge--dash { stroke-dasharray: 5 5; }
/* animated flow: forward edges in forward mode, the gradient path in training-signal mode */
.pipe .flow-fwd, .pipe .flow-bwd { stroke-dasharray: 7 7; }
.pipe.mode-fwd .flow-fwd { animation: flow 1.1s linear infinite; }
.pipe.mode-bwd .flow-bwd { animation: flow 1.1s linear infinite; stroke-width: 3; }
.pipe.mode-fwd .flow-bwd, .pipe.mode-fwd .plbl--bwd { opacity: .18; }
.pipe.mode-bwd .flow-fwd { opacity: .22; animation: none; }
.pipe.mode-bwd .pbox--teacher, .pipe.mode-bwd .plock { opacity: .55; }
.pipe .plbl--stop { opacity: 0; transition: opacity .2s; }
.pipe.mode-bwd .plbl--stop { opacity: 1; }
.pipe.is-focus .pedge:not(.is-hot) { opacity: .12; }
.pipe.is-focus .pnode--out:not(.is-hot), .pipe.is-focus .pnode--loss:not(.is-hot), .pipe.is-focus .pnode--noise:not(.is-hot) { opacity: .35; }
@keyframes flow { to { stroke-dashoffset: -28; } }

.geom__fig { margin: 0; }
.geom__canvas svg { display: block; width: 100%; height: auto; font-family: var(--f-body); }
.geo__title { font: italic 500 17px var(--f-display); fill: var(--ink); }
@media (prefers-reduced-motion: reduce) { .pipe .flow-fwd, .pipe .flow-bwd { animation: none !important; } }
@media (max-width: 760px) {
  .diagram__scroll::after { content: "Scroll sideways to see the whole diagram →"; display: block; position: sticky; left: 0; padding: 8px 2px 2px; font-size: .76rem; color: var(--muted); }
}

/* ---------------- colour gradients (branch colours: conditional → gap → unconditional) ---------------- */
:root { --sig-soft: linear-gradient(90deg, color-mix(in srgb, var(--cond) 85%, transparent), color-mix(in srgb, var(--gap) 85%, transparent), color-mix(in srgb, var(--uncond) 85%, transparent)); }
.hero__bg {
  background:
    radial-gradient(42rem 22rem at 10% -8%, color-mix(in srgb, var(--cond) 18%, transparent), transparent 70%),
    radial-gradient(40rem 22rem at 92% -4%, color-mix(in srgb, var(--uncond) 15%, transparent), transparent 70%),
    radial-gradient(52rem 24rem at 50% 38%, color-mix(in srgb, var(--gap) 11%, transparent), transparent 72%),
    linear-gradient(180deg, var(--tint), var(--bg) 75%);
}
.brand-word { background: linear-gradient(100deg, var(--cond), var(--gap)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav__progress span { background: var(--sig); }
.eyebrow::before { background: var(--sig); width: 22px; }
.venue__dot { background: var(--sig); }
.pill:hover { background: linear-gradient(100deg, var(--cond), var(--gap)); border-color: transparent; }
.pill--ghost:hover { background: var(--hl); border-color: var(--accent); }
.stat::before { content: ""; position: absolute; left: 18px; width: 30px; top: 0; height: 3px; border-radius: 0 0 3px 3px; background: var(--sig); }
.card::after { background: linear-gradient(90deg, var(--k), color-mix(in srgb, var(--k) 25%, var(--gap))); }
/* gradient hairline on top of the main panels */
.explorer, .abl, .diagram, .author-card, .tag-plot { position: relative; }
.explorer::before, .abl::before, .diagram::before, .author-card::before, .panel::before, .tag-plot::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--sig-soft); border-radius: var(--r) var(--r) 0 0; pointer-events: none; z-index: 1;
}
.panel { position: relative; overflow: hidden; }
.dtable tr.is-ours > *:first-child { box-shadow: inset 3px 0 0 var(--gap); }
.footer { border-top: 0; position: relative; }
.footer::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--sig-soft); opacity: .7; }
.author-card__photo img { border: 2px solid transparent; background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--sig) border-box; }
@media (forced-colors: active) { .brand-word { color: LinkText; background: none; } }

/* ---------------- supplementary section ---------------- */
.supp-steps { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 920px) { .supp-steps { grid-template-columns: minmax(0, 1fr); } }
.steps-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.steps-grid figure { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 8px; box-shadow: var(--shadow-sm); }
.steps-grid img { width: 100%; height: auto; border-radius: 6px; image-rendering: auto; }
.steps-grid figcaption { margin-top: 6px; font-size: .8rem; color: var(--muted); text-align: center; }
.steps-grid figcaption b { color: var(--ink); font-weight: 650; }
.switch { display: inline-flex; align-items: center; gap: 8px; font-size: .84rem; color: var(--ink-2); cursor: pointer; margin-left: auto; margin-right: 12px; }
.switch input { accent-color: var(--accent); width: 16px; height: 16px; }
.switch--right { display: flex; justify-content: flex-end; margin: 0 0 8px; }
.dtable .std { display: inline-block; margin-left: 4px; font-size: .78em; color: var(--muted); font-weight: 500; }
