
:root {
  --ink: #1f2330;
  --body: #363a45;
  --muted: #5d6270;
  --faint: #8b90a0;
  --caption: #4a4f5c;           --band: #f5f6f8;
  --rule: #2b2f42;
  --hair: #e6e8ee;
  --accent: #6a3fd1;            --accent-2: #0f7c8c;          --accent-soft: #f1ecfd;
  --ours: #f3effd;
  --code-bg: #f6f8fa;
  --code-border: #e5e9f0;
  --max: 960px;
  --text: 760px;                --fs-text: 1.2rem;            --gap-block: 2.4rem;          --gap-caption: 1.4rem;        --sans: "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --display: "Google Sans", "Product Sans", "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; font-size: 14px; }

body {
  margin: 0;
  color: var(--body);
  background: #fff;
  font-family: var(--sans);
  font-size: 1.125rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

strong { color: var(--ink); }

img { max-width: 100%; }


.band { position: relative; padding: 3.2rem 1.5rem; }
.band::before,
.footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(var(--max), calc(100% - 3rem));
  height: 1px;
  background: #dfe2e8;
}
.band.light { background: var(--band); }
.band.light::before,
.band.light + .band::before { display: none; }

.wrap { max-width: var(--max); margin: 0 auto; }
.narrow { max-width: var(--text); margin: 0 auto; }

h1, h2, h3, h4 {
  font-family: var(--display);
  color: var(--ink);
  margin: 0;
  line-height: 1.2;
}

.section-title {
  font-size: 2rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 1.4rem;
}

.topic-title {
  max-width: var(--text);
  margin: 0 auto 1rem;
  font-size: calc(24rem / 14);   font-weight: 600;
  line-height: 1.25;
  text-align: left;
}

.part-title {
  font-size: 2.35rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 0.4rem;
}

.part-sub {
  text-align: center;
  color: var(--muted);
  font-size: 1.1rem;
  margin: 0 auto 0.6rem;
  max-width: var(--text);
}

.block-title {
  font-size: 1.4rem;
  font-weight: 600;
  text-align: center;
  margin: 0 0 0.8rem;
}

.prose p { margin: 0 0 1em; text-align: left; hyphens: manual; font-size: var(--fs-text); line-height: 1.7; }
.prose p:last-child { margin-bottom: 0; }
#abstract .prose p { color: var(--caption); } #abstract .prose b { color: var(--ink); }


.hero { padding: 4.2rem 1.5rem 2.6rem; text-align: center; }

.draft-banner {
  display: inline-block;
  margin-bottom: 1.4rem;
  padding: 0.25rem 0.8rem;
  border-radius: 999px;
  background: #fff4d6;
  color: #7a5200;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.title-main {
  font-size: 2.6rem;
  font-weight: 600;
  line-height: 1.15;
  max-width: 900px;
  margin: 0 auto;
}

.title-main .accent {
  background: linear-gradient(90deg, #440154 0%, #3b528b 33%, #21918c 66%, #2db27d 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.authors {
  margin-top: 1.4rem;
  font-family: var(--display);
  font-size: 1.4rem;
}

.authors .author { display: inline-block; margin: 0 0.45rem; }
.authors a { color: hsl(204, 86%, 45%); }

.affils {
  margin-top: 0.35rem;
  font-family: var(--display);
  font-size: 1.1rem;
  color: var(--muted);
}

.affils span { margin: 0 0.6rem; }

.venue-note {
  margin-top: 0.5rem;
  color: var(--faint);
  font-size: 0.95rem;
}

.links {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 1.15rem;
  border-radius: 999px;
  background: #363636;
  color: #fff;
  font-family: var(--display);
  font-size: 1rem;
  line-height: 1;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn:hover { background: #222; color: #fff; text-decoration: none; transform: translateY(-1px); }

.btn svg { width: 1.05em; height: 1.05em; fill: currentColor; }

.btn.soon {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn.soon:hover { transform: none; background: #363636; }

.soon-badge {
  margin-left: 0.15rem;
  padding: 2px 6px;
  border-radius: 999px;
  background: #ffd54f;
  color: #2b2b2b;
  font-size: 0.62em;
  font-weight: 800;
  letter-spacing: 0.04em;
}


.fig { margin: 0 auto; max-width: var(--text); } 
.fig img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 auto;
}

.fig.w-90 img { max-width: 90%; }
.fig.w-80 img { max-width: 80%; }
.fig.w-70 img { max-width: 70%; }
.fig.w-60 img { max-width: 60%; }

.fig-caption {
  max-width: 860px;
  margin: 0.75rem auto 0;
  color: #4a4f5c;
  font-size: 0.93rem;
  line-height: 1.5;
  text-align: center;
}


.tldr-block {
  max-width: var(--text);
  margin: 2rem auto 0;
  text-align: left;
  hyphens: manual;
}

.tldr-block p {
  margin: 0;
  font-family: "Lora", Georgia, serif;
  font-size: var(--fs-text);
  line-height: 1.75;
  color: #444;
}

.tldr-block b { color: #222; }

.caption {
  max-width: 760px;
  margin: var(--gap-caption) auto 0;
  font-family: var(--sans);
  font-size: var(--fs-text);
  line-height: 1.7;
  color: var(--caption);
  text-align: left;   hyphens: manual;
}

.caption a { color: inherit; text-decoration: underline; text-decoration-color: #c8ccd2; }

.caption em { color: inherit; }

.fig + .fig { margin-top: 1.6rem; }

.fig-narrow img { max-width: 560px; }
.fig-medium img { max-width: 760px; }
.fig-after-caption { margin-top: 2.8rem; }
.caption strong { color: inherit; font-weight: 700; }
.caption-note { margin-top: 0.6rem; } 
.fig-table {
  max-width: 760px;
  margin: 0 auto;
}

.rtable-even col.c-method { width: 24%; }
.rtable-even col.c-data { width: 19%; }
.rtable-even thead tr:nth-child(2) th { text-align: center; } .rtable-even tr.sub td:first-child { text-align: left !important; }

.fig img { mix-blend-mode: multiply; }

.section-lede {
  max-width: 760px;
  margin: 0 auto;
  text-align: left;   color: var(--ink);
  font-size: var(--fs-text);
  line-height: 1.7;
}

.why-fig,
.section-lede + .progression,
.section-lede + .fig,
.section-lede + .fig-table,
.fig + .fig-table,
.caption + .ebr-multi-pair { margin-top: var(--gap-block); }
.progression { max-width: var(--text); margin: 0 auto; }

.step {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 17.5rem;   gap: 2rem;
  align-items: baseline;   padding: 0.95rem 0 0.95rem 2.1rem;
  --dot-y: calc(0.95rem + var(--fs-text) * 0.85); }
.step::before,
.step::after { content: ""; position: absolute; }
.step::before {   left: 0;
  top: var(--dot-y);
  width: 11px;
  height: 11px;
  margin-top: -5.5px;
  border-radius: 50%;
  background: var(--step-color);
  box-shadow: 0 0 0 4px #fff;
  z-index: 1;
}
.step::after {   left: 4.5px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #dfe2e8;
}
.step:first-child::after { top: var(--dot-y); }
.step:last-child::after { bottom: auto; height: var(--dot-y); }
.step:nth-child(1) { --step-color: #440154; }
.step:nth-child(2) { --step-color: #3b528b; }
.step:nth-child(3) { --step-color: #21918c; }
.step:nth-child(4) { --step-color: #2db27d; }

.step p {
  order: 1;
  margin: 0;
  font-size: var(--fs-text);
  line-height: 1.7;
  color: var(--ink);
}
.step .katex-display { order: 2; margin: 0; }
.step .katex-display > .katex { text-align: left; } .step .katex { font-size: 1.12em; color: var(--ink); }
.step p strong { color: var(--step-color); font-weight: 700; }
.step p .katex { font-size: 1.05em; }
.nowrap { white-space: nowrap; }

.hero-fig {
  max-width: 820px;
  margin: 2.2rem auto 0;
}

.hero-fig img {
  border-radius: 12px;
}

.hero-fig.hero-anim { max-width: var(--text); margin-top: 2rem; } .hero-fig.hero-anim img { border-radius: 0; }
.hero-fig.hero-anim .fig-caption { max-width: 760px; margin-top: 1.2rem; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 2.2rem;
  align-items: center;
}

.split.flip { grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); }


.hero-lede {
  max-width: 680px;
  margin: 1.6rem auto 0;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.55;
}

.hero-lede strong { color: var(--ink); }

.takeaway-line {
  max-width: var(--text);
  margin: 1.1rem auto 0;
  padding-left: 0.9rem;
  border-left: 3px solid var(--accent);
  color: var(--body);
  line-height: 1.55;
}

.stats.stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 760px; }
.split .prose p { text-align: left; }

.result-block { margin-top: 2.8rem; }
.result-block:first-of-type { margin-top: 1.6rem; }

.result-block .prose { max-width: var(--text); margin: 0 auto 1.3rem; }

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin: 2rem auto 0;
  max-width: 900px;
}

.stat {
  background: #fff;
  border: 1px solid var(--hair);
  border-radius: 12px;
  padding: 1rem 0.9rem 0.9rem;
  text-align: center;
}

.band.light .stat { background: #fff; }

.stat .num {
  font-family: var(--display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
}

.stat .lbl {
  margin-top: 0.35rem;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}

.pillars {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1.6rem;
}

.pillar {
  border: 1px solid var(--hair);
  border-radius: 12px;
  padding: 1.05rem 1.1rem;
  background: #fff;
}

.pillar h4 {
  font-size: 1.05rem;
  margin-bottom: 0.3rem;
}

.pillar .tag {
  display: inline-block;
  margin-bottom: 0.45rem;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 6px;
  padding: 1px 7px;
}

.pillar p { margin: 0; font-size: 0.93rem; color: var(--muted); line-height: 1.5; }


.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.rtable {
  width: 100%;
  border-collapse: collapse;
  border-top: 2px solid var(--rule);
  border-bottom: 2px solid var(--rule);
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
}

.rtable th,
.rtable td {
  padding: 0.5rem 0.65rem;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.rtable th:first-child,
.rtable td:first-child { text-align: left; }

.rtable thead th {
  font-family: var(--display);
  font-weight: 700;
  color: var(--rule);
}

.rtable thead tr:last-child th { border-bottom: 2px solid var(--rule); }
.rtable thead th.group { border-bottom: 1px solid #c9cede; }

.rtable tbody tr { border-bottom: 1px solid #eef0f4; }
.rtable tbody tr:last-child { border-bottom: none; }
.rtable tbody tr:hover { background: #f8f9fb; }

.rtable tr.sub td {
  background: transparent;
  color: var(--muted);
  font-style: italic;
  text-align: center !important;
  font-size: 0.88rem;
  padding: 0.35rem;
}

.rtable tr.ours,
.rtable tr.ours:hover { background: var(--ours); }

.rtable .pm { color: var(--faint); font-size: 0.78em; margin-left: 1px; }
.rtable .n { color: var(--faint); font-size: 0.85em; margin-left: 2px; }
.rtable .dim { color: var(--faint); }

.ours-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  vertical-align: middle;
}


.takeaway {
  max-width: var(--text);
  margin: 2.4rem auto 0;
  padding: 1rem 1.25rem;
  background: var(--accent-soft);
  border: 1.5px solid var(--accent);
  border-radius: 10px;
  color: #1d1733;
  line-height: 1.55;
}

.takeaway strong { color: var(--accent); }



.bib-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.8rem;
}

.bib-head h2 { font-size: calc(24rem / 14); font-weight: 600; } 
.copy-btn {
  padding: 0.35rem 0.85rem;
  border: 0;
  border-radius: 6px;
  background: #363636;
  color: #fff;
  font: inherit;
  font-size: 0.85rem;
  cursor: pointer;
}

.copy-btn:hover { background: #222; }

.bib {
  margin: 0;
  padding: 1.1rem 1.2rem;
  background: #fff;
  border: 1px solid var(--hair);
  border-radius: 10px;
  font-family: var(--mono);
  font-size: 0.82rem;
  line-height: 1.6;
  white-space: pre;
  overflow-x: auto;
}


.footer {
  position: relative;
  padding: 2.4rem 1.5rem 3rem;
  background: #fff;
  color: var(--muted);
  font-size: 0.88rem;
  text-align: center;
}

.footer p { max-width: var(--text); margin: 0 auto 0.5rem; }


@media (max-width: 900px) {
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats.stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .split, .split.flip { grid-template-columns: 1fr; gap: 1.4rem; }
  .split.flip .fig { order: 2; }
}

@media (max-width: 720px) {
  html { font-size: 13px; }
  .tldr-block { text-align: left; }
  .tldr-block p { line-height: 1.6; }
  .fig-narrow img { max-width: 100%; }
  .band { padding: 2.5rem 1.1rem; }
  .hero { padding: 3rem 1.1rem 2rem; }
  .title-main { font-size: 1.9rem; }
  .authors { font-size: 1.1rem; }
  .section-title { font-size: 1.6rem; }
  .topic-title, .bib-head h2 { font-size: 1.5rem; }
  .part-title { font-size: 1.85rem; }
  .pillars { grid-template-columns: 1fr; }
  .step { grid-template-columns: 1fr; gap: 0.5rem; }
  .stats.stats-3 { grid-template-columns: 1fr; max-width: 320px; }
  .stat .num { font-size: 1.75rem; }
  .hero-lede { font-size: 1.02rem; }
  .fig.w-90 img, .fig.w-80 img, .fig.w-70 img, .fig.w-60 img { max-width: 100%; }
  .prose p { text-align: left; }
  .rtable { font-size: 0.85rem; }
}

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