:root {
  --ink: #15171a;
  --muted: #5f6670;
  --line: #d9dde2;
  --paper: #ffffff;
  --wash: #f5f7f8;
  --accent: #2458a6;
  --content: 920px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.65;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  text-decoration-thickness: 2px;
}

.site-header {
  width: min(var(--content), calc(100% - 40px));
  margin: 0 auto;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-decoration: none;
}

nav {
  display: flex;
  gap: 22px;
}

nav a {
  color: var(--muted);
  font-size: 0.86rem;
  text-decoration: none;
}

nav a:hover {
  color: var(--ink);
}

main,
footer {
  width: min(var(--content), calc(100% - 40px));
  margin-inline: auto;
}

.hero {
  padding: 86px 0 58px;
  text-align: center;
}

h1,
h2,
h3,
p {
  text-wrap: pretty;
}

h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3.5rem, 10vw, 6.7rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.95;
}

.subtitle {
  max-width: 760px;
  margin: 24px auto 10px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1.32;
}

.project-context {
  margin: 0 auto 26px;
  color: var(--muted);
  font-size: 0.98rem;
}

.authors,
.venue {
  margin: 4px auto;
}

.venue {
  color: var(--muted);
  font-size: 0.95rem;
}

.links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0 42px;
}

.links a {
  min-width: 82px;
  padding: 8px 14px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 0.92rem;
  font-weight: 650;
  text-decoration: none;
}

.links a:hover {
  background: var(--wash);
  border-color: #b8bec6;
}

.links .primary {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.links .primary:hover {
  background: #1d4a8e;
  border-color: #1d4a8e;
}

figure {
  margin: 0;
}

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

.hero-media img,
.system-figure img {
  border: 1px solid var(--line);
}

figcaption {
  margin-top: 9px;
  color: var(--muted);
  font-size: 0.82rem;
  text-align: left;
}

.section {
  padding: 64px 0;
  border-top: 1px solid var(--line);
  scroll-margin-top: 24px;
}

.prose > p,
.prose > h3 {
  max-width: 760px;
}

.section-intro {
  max-width: 760px;
  margin: -12px 0 28px;
  color: var(--muted);
}

.demo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.demo-grid img,
.demo-grid video,
.vectorized-figure img,
.vectorized-figure video {
  border: 1px solid var(--line);
}

.simulation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px 28px;
}

.simulation-card {
  min-width: 0;
}

.media-video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  background: #111;
  border: 1px solid var(--line);
}

.study-grid figcaption {
  line-height: 1.5;
}

.table-scroll {
  overflow-x: auto;
  padding-bottom: 4px;
}

.results-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  border: 1px solid var(--line);
  font-size: 0.84rem;
  line-height: 1.35;
}

.results-table caption {
  caption-side: bottom;
  padding-top: 10px;
  color: var(--muted);
  font-size: 0.78rem;
  text-align: left;
}

.results-table th,
.results-table td {
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  text-align: center;
  white-space: nowrap;
}

.results-table thead th {
  background: var(--wash);
  font-weight: 700;
}

.results-table tbody th:not([colspan]),
.results-table tfoot th {
  text-align: left;
}

.results-table .group-row th {
  padding: 8px 10px;
  color: var(--muted);
  background: #fbfcfd;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
}

.results-table tfoot {
  background: #eef3fa;
  font-weight: 700;
}

.results-table .best-model {
  color: #fff;
  background: var(--accent);
}

.results-table abbr {
  text-decoration: none;
}

.result-note {
  max-width: 760px;
  margin: 22px 0 0;
}

.vectorized-figure {
  width: 100%;
}

h2 {
  margin: 0 0 24px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.85rem, 4vw, 2.5rem);
  font-weight: 500;
  line-height: 1.2;
}

h3 {
  margin: 38px 0 12px;
  font-size: 1rem;
  line-height: 1.4;
}

.official-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.28rem;
  line-height: 1.45;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin: 42px 0 0;
  padding-left: 1.35rem;
}

.steps li {
  padding-left: 4px;
}

.citation-section pre {
  margin: 0;
  padding: 22px;
  overflow-x: auto;
  color: #20242a;
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 4px;
  font-size: 0.82rem;
  line-height: 1.55;
  white-space: pre;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 34px 0 48px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 0.82rem;
}

footer p {
  margin: 0;
}

@media (max-width: 680px) {
  body {
    font-size: 16px;
  }

  .site-header {
    min-height: 58px;
  }

  nav a:not(:last-child) {
    display: none;
  }

  .hero {
    padding-top: 58px;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .demo-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .simulation-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  footer {
    display: block;
  }

  footer p + p {
    margin-top: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
