:root {
  color-scheme: light;
  --ink: #202124;
  --body: #3f4245;
  --muted: #5e6469;
  --rule: #e2e5e8;
  font-family: "Avenir Next", Avenir, system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: #fff; color: var(--ink); }
h1, p { margin: 0; }
a { color: inherit; }
img { display: block; width: 100%; height: auto; }
:focus-visible { outline: 2px solid #06788a; outline-offset: 4px; }

.shell { width: min(68rem, calc(100% - 3rem)); margin-inline: auto; }

.hero { padding-block: clamp(2rem, 4.7vw, 4rem) clamp(1.25rem, 3vw, 2rem); text-align: center; }
.hero-copy { max-width: 52rem; margin-inline: auto; }
h1 {
  font-size: clamp(2.4rem, 5.4vw, 4rem);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -.056em;
  text-wrap: balance;
}
.subtitle {
  max-width: 43rem;
  margin: .8rem auto 0;
  color: var(--body);
  font-size: clamp(1.12rem, 2.4vw, 1.52rem);
  font-weight: 500;
  line-height: 1.45;
  text-wrap: balance;
}
.hero-authors,
.hero-affiliations {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: .25rem 1rem;
  line-height: 1.45;
}
.hero-authors { margin-top: 1rem; font-weight: 600; }
.hero-affiliations { margin: .25rem auto 0; color: var(--muted); font-size: .9rem; }
.hero-authors sup,
.hero-affiliations sup { line-height: 0; }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem; margin-top: 1.15rem; }
.button {
  min-height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .55rem 1rem;
  border: 1px solid transparent;
  border-radius: 2rem;
  font: 650 .93rem/1.2 "Avenir Next", Avenir, system-ui, sans-serif;
  text-decoration: none;
  cursor: pointer;
}
.primary { color: #fff; background: #292b2e; }
.primary:hover { background: #101113; }
.actions .button { gap: .45rem; padding-inline: .9rem; white-space: nowrap; }
.resource-icon { width: 1rem; height: 1rem; flex: none; }
.resource-placeholder { color: var(--muted); border-color: var(--rule); cursor: default; }
.resource-placeholder span[aria-hidden] { color: #777d82; }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.exploration { padding-block-start: clamp(2rem, 4.5vw, 3rem); }
.replay-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1rem, 2.5vw, 1.75rem); }
.replay-preview { display: grid; justify-items: center; gap: .7rem; }
.replay-preview img { border-radius: .5rem; }
.replay-link { transition: background-color .18s ease, transform .18s ease; }
.replay-link:active { transform: scale(.97); }
.play-mark { width: .65rem; height: .75rem; background: currentColor; clip-path: polygon(0 0, 100% 50%, 0 100%); }
.replay-archive-link { margin-top: 1.7rem; text-align: center; }
.replay-archive-link .button { color: var(--body); border-color: var(--rule); }
.replay-archive-link .button:hover { background: #f7f7f7; color: var(--ink); }
.replay-stage { margin-top: 1.5rem; scroll-margin-top: 1rem; }
.replay-surface {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--rule);
  border-radius: .5rem;
  background: #fff;
}
.replay-stage:not([hidden]) .replay-surface {
  animation: replay-enter .38s cubic-bezier(.2, .7, .25, 1) both;
}
@keyframes replay-enter {
  from { opacity: 0; transform: translateY(.65rem); }
  to { opacity: 1; transform: translateY(0); }
}
.replay-frame:not([hidden]) {
  display: block;
  width: 100%;
  height: clamp(37rem, 74vh, 49rem);
  border: 0;
  transition: opacity .26s ease;
}
.replay-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: start center;
  justify-items: center;
  gap: .75rem;
  padding-block-start: clamp(3rem, 14vh, 8rem);
  color: var(--muted);
  font-size: .93rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity .26s ease;
}
.replay-placeholder img { width: min(16rem, 60vw); opacity: .65; }
.replay-stage[data-loading] .replay-placeholder { opacity: 1; transition: none; }
.replay-stage[data-loading] .replay-frame { opacity: 0; transition: none; }

.highlights { background: #f7f7f7; padding-block: clamp(1.75rem, 4vw, 2.65rem); }
.highlights > .shell { max-width: 50rem; }
.highlights h2 {
  margin: 0 0 1.25rem;
  font-size: clamp(1.55rem, 3vw, 1.9rem);
  line-height: 1.2;
  letter-spacing: -.025em;
  text-align: center;
}
.highlights ol { margin: 0; padding-inline-start: 1.5rem; color: var(--body); line-height: 1.65; }
.highlights li + li { margin-top: .65rem; }
.highlights li::marker { color: var(--muted); }
.highlights strong { color: var(--ink); font-weight: 650; }
.highlight-accent { color: #4b7116; }

.research-section { padding-block-start: clamp(2.4rem, 5vw, 3.8rem); }
.exploration h2,
.research-section h2 {
  margin: 0 0 1rem;
  font-size: clamp(1.55rem, 3vw, 1.9rem);
  line-height: 1.2;
  letter-spacing: -.025em;
  text-align: center;
}
.method-summary {
  max-width: 49rem;
  margin: 0 auto 1.5rem;
  color: var(--body);
  line-height: 1.65;
  text-align: center;
  text-wrap: pretty;
}
.benchmark-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.125rem, 3vw, 2.25rem);
  margin-top: 1.45rem;
}
.benchmark { padding: 1.05rem 1rem; border-radius: .6rem; background: #f7f7f7; }
.benchmark h3 { margin: 0; font-size: 1.04rem; line-height: 1.25; }
.benchmark-task { margin: .35rem 0 0; color: var(--muted); font-size: .84rem; line-height: 1.35; }
.benchmark-metrics { margin: .65rem 0 0; font-size: .91rem; }
.benchmark-metrics > div { display: flex; align-items: baseline; justify-content: space-between; gap: .5rem; }
.benchmark-metrics > div + div { margin-top: .38rem; }
.benchmark-metrics dt { color: var(--body); }
.benchmark-metrics dd { margin: 0; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.benchmark-metrics > .benchmark-lead { flex-direction: column-reverse; gap: .12rem; margin-bottom: .85rem; }
.benchmark-lead dd { color: #4b7116; font-size: clamp(1.65rem, 2.9vw, 2rem); line-height: 1.1; letter-spacing: -.045em; }

.citation { padding-block-end: clamp(2.5rem, 5vw, 4rem); }
.citation-heading { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.citation h2 { margin: 0; text-align: start; }
.citation-copy { color: var(--body); border-color: var(--rule); background: #fff; }
.citation-copy[hidden] { display: none; }
.citation-copy:hover { background: #f7f7f7; }
.citation pre {
  margin: 1rem 0 0;
  padding: clamp(.9rem, 3vw, 1.5rem);
  border-radius: .6rem;
  background: #f7f7f7;
  font: .9rem/1.65 ui-monospace, SFMono-Regular, Consolas, monospace;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.citation code { font: inherit; }

@media (prefers-reduced-motion: reduce) {
  .replay-link, .replay-frame:not([hidden]), .replay-placeholder { transition: none; }
  .replay-link:active { transform: none; }
  .replay-stage:not([hidden]) .replay-surface { animation: none; }
}

@media (min-width: 821px) {
  .replay-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 920px) {
  .benchmark-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .replay-grid { grid-template-columns: 1fr; gap: 1.4rem; }
}

@media (max-width: 810px) {
  .replay-frame:not([hidden]) { height: 59rem; }
}

@media (max-width: 560px) {
  .shell { width: calc(100% - 2rem); }
}

@media (max-width: 480px) {
  .benchmark-grid { grid-template-columns: 1fr; }
}

@media (max-width: 380px) {
  .actions { gap: .4rem; }
  .actions .button { gap: .35rem; padding-inline: .6rem; }
}
