:root {
  --text: #1d1d1f;
  --muted: #6e6e73;
  --line: #e8e8ed;
  --soft: #f7f7f9;
  --accent: #c2410c;
  --accent-soft: #fff7f2;
  --content: 820px;
  --wide: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font: 17px/1.7 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

img { display: block; width: 100%; height: auto; }

/* Header */

.hero {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 96px 24px 40px;
  text-align: center;
}

.venue {
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  margin: 0 auto 28px;
  max-width: 820px;
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.025em;
}

.authors {
  margin: 0 auto;
  max-width: 760px;
  font-size: 17px;
  line-height: 1.9;
}

.authors span { white-space: nowrap; }
.authors span:not(:last-child)::after { content: ","; }

.tagline {
  margin: -14px auto 24px;
  max-width: 760px;
  color: var(--muted);
  font-size: 18px;
}

.affiliation {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 15px;
}

.links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}

.button:hover { border-color: var(--text); }

.button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.button.disabled { color: var(--muted); cursor: default; }
.button.disabled:hover { border-color: var(--line); }
.button small { font-size: 12px; }

/* Content */

main {
  max-width: var(--content);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding-top: 72px; }

h2 {
  margin: 0 0 24px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.015em;
}

h3 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 600;
}

p { margin: 0 0 18px; }

.lead { color: var(--muted); font-size: 15px; margin-top: 8px; }
.note { color: var(--muted); font-size: 13px; margin-top: 10px; }
.tv-pair + .note { margin-top: -24px; }

figure { margin: 36px 0; }

figure.wide {
  width: min(var(--wide), 100vw - 48px);
  margin-left: 50%;
  transform: translateX(-50%);
}

figure.narrow { max-width: 560px; margin-left: auto; margin-right: auto; }

figure.teaser { margin-top: 24px; }

figcaption {
  max-width: var(--content);
  margin: 16px auto 0;
  padding: 0 4px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.6;
}

figcaption b { color: var(--text); font-weight: 600; }

.pixelated { image-rendering: pixelated; }

.sample-label {
  margin: 18px 0 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Cards */

.cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 28px 0;
}

.card {
  padding: 20px 22px 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.card p { color: var(--muted); font-size: 14.5px; line-height: 1.6; }
.card .katex-display { margin: 14px 0 16px; overflow-x: auto; overflow-y: hidden; }

/* Tables */

.results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.results-grid p { font-size: 15px; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

th, td {
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th {
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 500;
  border-bottom-color: var(--text);
}

th:first-child, td:first-child { padding-left: 0; }
th:last-child, td:last-child { padding-right: 0; }

.num { text-align: right; }

tr.ours td { background: var(--accent-soft); font-weight: 500; }
tr.ours td:first-child { box-shadow: -8px 0 0 var(--accent-soft); }
tr.ours td:last-child { box-shadow: 8px 0 0 var(--accent-soft); }

/* BibTeX */

.bibtex {
  position: relative;
  background: var(--soft);
  border-radius: 14px;
}

.bibtex pre {
  margin: 0;
  padding: 22px 24px;
  overflow-x: auto;
  font: 13.5px/1.65 "JetBrains Mono", ui-monospace, Menlo, monospace;
}

.copy {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font: 500 12.5px "Inter", sans-serif;
  cursor: pointer;
}

.copy:hover { color: var(--text); border-color: var(--text); }

footer {
  max-width: var(--content);
  margin: 96px auto 0;
  padding: 28px 24px 48px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13.5px;
  text-align: center;
}

footer a { text-underline-offset: 2px; }

@media (max-width: 720px) {
  .hero { padding-top: 64px; }
  .cards, .results-grid { grid-template-columns: 1fr; }
  .results-grid { gap: 28px; }
  section { padding-top: 56px; }
}

/* Trajectory viewer */

h3.sub { margin-top: 48px; font-size: 20px; }

.wide-block {
  width: min(var(--wide), 100vw - 48px);
  margin-left: 50%;
  transform: translateX(-50%);
}

.tv-pair { display: grid; gap: 36px; margin-top: 28px; margin-bottom: 44px; }

.tv-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 15px;
  font-weight: 600;
}

.tv-swatch { width: 12px; height: 12px; border-radius: 3px; }

.tv {
  display: grid;
  grid-template-columns: 1fr;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

.tv.tv-detail { grid-template-columns: 1fr 330px; }

.tv-stage { position: relative; height: 520px; touch-action: none; }
.tv-stage canvas { display: block; width: 100%; height: 100%; }
/* detail view: a control bar above the 3D scene holds the step slider */
.tv.tv-detail .tv-stage { height: 584px; }
.tv.tv-detail .tv-stage canvas { margin-top: 64px; height: calc(100% - 64px); }
.tv.tv-detail .tv-panel { max-height: 584px; }

.tv-note {
  position: absolute;
  left: 16px;
  bottom: 14px;
  max-width: 360px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  pointer-events: none;
}

.tv-note b { color: var(--text); font-weight: 600; }

.tv-back {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 5px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--text);
  font: 500 13px "Inter", sans-serif;
  cursor: pointer;
}

.tv-back:hover { border-color: var(--text); }

.tv-loading {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 14px;
  background: rgba(255, 255, 255, 0.7);
}

.tv-loading[hidden], .tv-note[hidden], .tv-back[hidden], .tv-panel[hidden] { display: none; }

.tv-panel {
  padding: 20px 20px 16px;
  border-left: 1px solid var(--line);
  font-size: 14px;
  overflow-y: auto;
  max-height: 520px;
}

.tv-panel h3 { margin: 2px 0 2px; font-size: 18px; text-transform: capitalize; }

.tv-eyebrow {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tv-meta { margin: 0 0 14px; color: var(--muted); font-size: 13px; }

.tv-strip { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; margin-bottom: 16px; }
.tv-strip figure { margin: 0; cursor: pointer; }
.tv-strip img { border-radius: 4px; outline: 2px solid transparent; outline-offset: 1px; }
.tv-strip figure.active img { outline-color: var(--text); }
.tv-strip figcaption { margin-top: 2px; color: var(--muted); font-size: 11px; text-align: center; }

.tv-chart { position: relative; }
.tv-chart-title { margin-bottom: 4px; color: var(--muted); font-size: 12.5px; }
.tv-chart svg { display: block; width: 100%; height: 120px; overflow: visible; }
.tv-chart .grid { stroke: var(--line); stroke-width: 1; }
.tv-chart .tick { fill: var(--muted); font-size: 9.5px; font-family: "Inter", sans-serif; }
.tv-chart .series { fill: none; stroke-width: 2; vector-effect: non-scaling-stroke; }
.tv-chart .cursor { stroke: var(--text); stroke-width: 1; stroke-dasharray: 2 2; vector-effect: non-scaling-stroke; }
.tv-chart .cursor-dot { stroke: #fff; stroke-width: 2; }
.tv-chart .hit { cursor: crosshair; }

.tv-tip {
  position: absolute;
  top: 18px;
  transform: translateX(-50%);
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--text);
  color: #fff;
  font-size: 11.5px;
  white-space: nowrap;
  pointer-events: none;
}

.tv-tip[hidden] { display: none; }

.tv-scrub {
  position: absolute;
  top: 12px;
  right: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(480px, calc(100% - 190px));
  padding: 8px 14px 8px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.tv-scrub[hidden] { display: none; }
.tv-scrub input { flex: 1; height: 22px; accent-color: var(--text); cursor: pointer; }
.tv-readout { min-width: 112px; color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }

.tv-play {
  flex: none;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  font-size: 13px;
  cursor: pointer;
}

.tv-play:hover { border-color: var(--text); }

.tv-explain { margin: 0; color: var(--muted); font-size: 12.5px; line-height: 1.55; }

@media (max-width: 860px) {
  .tv.tv-detail { grid-template-columns: 1fr; }
  .tv-panel { border-left: 0; border-top: 1px solid var(--line); max-height: none; }
  .tv-stage { height: 420px; }
  .tv-scrub { top: 56px; left: 14px; width: auto; }
  .tv.tv-detail .tv-stage { height: 524px; }
  .tv.tv-detail .tv-stage canvas { margin-top: 104px; height: calc(100% - 104px); }
}

.tv-readout { white-space: nowrap; }

.tv-hover {
  position: absolute;
  padding: 3px 9px;
  border-radius: 6px;
  background: var(--text);
  color: #fff;
  font-size: 12px;
  text-transform: capitalize;
  pointer-events: none;
}

.tv-hover[hidden] { display: none; }

.tv-nocase { text-transform: none; letter-spacing: 0; }
.tv-panel { overflow-x: hidden; }
.tv-scrub input { min-width: 0; }
.tv-readout { min-width: 0; color: var(--text); font-size: 13px; }

.tv-legend {
  position: absolute;
  right: 14px;
  bottom: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}

.tv-legend[hidden] { display: none; }
.tv-legend-title { color: var(--text); font-weight: 500; }
.tv-legend span { display: inline-block; width: 10px; height: 10px; margin-right: 6px; border-radius: 2px; vertical-align: -1px; }
.tv-legend-note { max-width: 150px; margin-top: 2px; line-height: 1.35; }

.tv-note-overview { padding: 6px 8px; margin: -6px -8px; border-radius: 8px; background: rgba(255, 255, 255, 0.85); }

@media (max-width: 860px) {
  .tv-legend { font-size: 10.5px; padding: 6px 8px; }
  .tv-legend-note, .tv-note-detail { display: none; }
  .tv-note-overview { max-width: 260px; font-size: 12px; }
}

.tv-live { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px; }
.tv-live figure { margin: 0; }
.tv-tile { aspect-ratio: 1; border-radius: 6px; background-color: var(--soft); background-repeat: no-repeat; }
.tv-live figcaption { display: flex; align-items: center; gap: 6px; margin-top: 5px; color: var(--muted); font-size: 12px; }
.tv-live .tv-swatch { width: 10px; height: 10px; border-radius: 2px; }
.tv-legend .tv-line { width: 14px; height: 3px; border-radius: 2px; vertical-align: 3px; }
.tv-legend-gap { margin-top: 4px; }
.tv-legend .tv-t { display: block; margin: -1px 0 2px 20px; font-size: 10.5px; }

.tv-legend .tv-geo { width: auto; margin-bottom: 8px; font-size: 11px; }
.tv-legend .tv-geo th, .tv-legend .tv-geo td { padding: 2px 4px; white-space: nowrap; }
.tv-legend .tv-geo th { font-size: 10.5px; }
.tv-legend .tv-geo thead th:first-child { padding-left: 0; color: var(--text); font-weight: 500; }
.tv-legend .tv-geo td:first-child { padding-left: 0; }
.tv-legend .tv-geo .tv-swatch { display: inline-block; width: 7px; height: 7px; margin-right: 4px; border-radius: 2px; vertical-align: 0; }

.tv-geo td b { color: var(--text); font-weight: 700; }
.tv-geo thead th { vertical-align: bottom; }
.tv-geo-sub { color: var(--muted); font-size: 11px; font-weight: 400; }
