:root {
  --paper: #f5f8f4;
  --paper-deep: #eaf1ec;
  --soft: #eaf1ec;
  --surface: #ffffff;
  --ink: #102d36;
  --muted: #5d7177;
  --line: #cedbd6;
  --line-strong: #9eb5ad;
  --reagent: #008f91;
  --reagent-dark: #006b70;
  --acid: #b9de4f;
  --acid-dark: #637c16;
  --amber: #e9a23b;
  --danger: #b8453f;
  --navy: #082831;
  --best: #008f91;
  --radius: 12px;
  --shadow: 0 4px 20px rgba(16, 45, 54, .08);
  --max: 1240px;
  --prose: 860px;
  --gradient: linear-gradient(135deg, #008f91, #637c16);
  --font-mono: ui-monospace, monospace;
  --fs-hero: clamp(2.75rem, 7vw, 4.5rem);
  --fs-page-h1: clamp(2.25rem, 4.6vw, 3.375rem);
  --fs-h2: clamp(1.75rem, 3.6vw, 2.625rem);
  --fs-card-h2: 1.6875rem;
  --fs-h3: 1.25rem;
  --fs-lede: clamp(1.0625rem, 2vw, 1.25rem);
  --fs-page-lede: clamp(1rem, 1.7vw, 1.125rem);
  --fs-kicker: .75rem;
  --fs-xs: .6875rem;
  --fs-2xs: .625rem;
  --fs-sm: .8125rem;
  --fs-md: .875rem;
  --fs-stat: 2.125rem;
  --fs-brand: 1.0625rem;
  --fs-score: 1.25rem;
  --fs-fallback: 2.25rem;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.62;
}
a { color: inherit; }
img, video { display: block; max-width: 100%; }
button, input, select { font: inherit; }
.site-header a:focus-visible, main a:focus-visible, footer a:focus-visible,
button:focus-visible, input:focus-visible, select:focus-visible, video:focus-visible {
  outline: 3px solid var(--acid-dark); outline-offset: 3px;
}
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 100; background: var(--acid); padding: 10px 14px; font-weight: 800; }
.skip-link:focus { top: 12px; }

.site-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 70px; padding: 10px max(20px, calc((100vw - var(--max)) / 2));
  border-bottom: 1px solid rgba(158, 181, 173, .7);
  background: rgba(245, 248, 244, .92); backdrop-filter: blur(16px);
}
.site-brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; min-width: max-content; }
.brand-logo { width: 42px; height: 42px; object-fit: contain; flex: 0 0 auto; }
.site-brand strong, .site-brand em { font-size: var(--fs-brand); letter-spacing: -.02em; }
.site-brand em { color: var(--reagent-dark); font-style: normal; }
.site-brand small { display: block; color: var(--muted); font-size: var(--fs-2xs); letter-spacing: .08em; text-transform: uppercase; }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a { padding: 8px 14px; color: var(--muted); border-radius: 999px; text-decoration: none; font-size: var(--fs-md); font-weight: 700; transition: background 160ms ease, color 160ms ease; }
.site-nav a:hover { color: var(--reagent-dark); background: #dcebe6; }
body[data-page="home"] [data-nav="home"], body[data-page="tasks"] [data-nav="tasks"], body[data-page="objects"] [data-nav="objects"], body[data-page="dataset"] [data-nav="dataset"], body[data-page="leaderboard"] [data-nav="leaderboard"], body[data-page="docs"] [data-nav="docs"] { color: var(--navy); background: var(--acid); }
.site-nav .console-link { margin-left: 7px; border: 1px solid var(--line-strong); color: var(--ink); }
.nav-toggle { display: none; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 8px 14px; font-weight: 800; color: var(--ink); }

.container, .section, .page-shell { width: min(calc(100% - 40px), var(--max)); margin-inline: auto; }
section { padding: 46px 0; }
section.soft { background: var(--soft); }
.section { padding: 46px 0; }
.section + .section, .soft + .section, .section + .soft { padding-top: 0; }
.page-shell { padding: 46px 0 84px; min-height: 70vh; }
.release-section { margin-top: 54px; padding-top: 34px; border-top: 2px solid var(--line-strong); }
.release-section > .lede { max-width: 820px; }
.release-task-card { border-top: 4px solid var(--amber); }
.release-task-card .card-media { background: linear-gradient(145deg, #fff1d7, #f8fbf8); }
.release-card-grid { margin-top: 22px; }
.release-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.release-home-grid .track-card { border-top-color: var(--amber); }
.release-protocol-score-grid { grid-template-columns: repeat(3, 1fr); }
.special-demo-section { padding: 34px 0 42px; background: var(--soft); }
.special-demo-section .section-head { margin-bottom: 12px; }
.special-demo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 20px; }
.special-demo-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: 0 6px 20px rgba(16,45,54,.05); }
.special-demo-card video { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--navy); }
.special-demo-card > div { padding: 16px 20px 19px; }
.special-demo-card h3 { margin: 11px 0 5px; }
.special-demo-card p { margin: 0; color: var(--muted); }

.section-kicker { margin: 0 0 10px; color: var(--reagent-dark); font: 800 var(--fs-kicker)/1.2 var(--font-mono); letter-spacing: .13em; text-transform: uppercase; }
h1, h2, h3 { margin-top: 0; line-height: 1.18; letter-spacing: -.02em; }
h1 { font-size: var(--fs-hero); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
.lede { max-width: 760px; color: var(--muted); font-size: var(--fs-lede); }
.detail-note { color: var(--muted); font-size: .92rem; }
.text-link { color: var(--reagent-dark); font-weight: 800; text-decoration: none; white-space: nowrap; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 26px; }
.section-head h2, .section-head p { margin-bottom: 0; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 9px 18px; border-radius: 999px; border: 1px solid var(--navy); background: var(--navy); color: #fff; text-decoration: none; font-weight: 700; font-size: 14px; transition: transform 160ms ease, opacity 160ms ease; }
.button:hover { text-decoration: none; transform: translateY(-1px); opacity: .9; }
.button.primary { color: var(--navy); background: var(--acid); border-color: var(--acid); }
.button.secondary { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.button.secondary:hover { opacity: 1; border-color: var(--reagent); }

/* ===== Hero (UniBYD-style centered) ===== */
.hero { padding: 54px 18px 22px; text-align: center; }
.hero h1 { max-width: 900px; margin: 0 auto; }
.hero h1 span { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lede { max-width: var(--prose); margin: 18px auto 0; }
.project-mark { width: 96px; height: 96px; object-fit: contain; margin: 22px auto 16px; }
.institutions-section { padding: 24px 0 40px; }
.institutions-heading { text-align: center; color: var(--muted); font-size: 14px; font-weight: 600; margin: 0 0 28px; }
.institution-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 32px 24px; max-width: 1080px; margin: 0 auto; }
.institution-logo { flex: 0 1 calc((100% - 72px) / 4); min-width: 0; margin: 0; text-align: center; }
.institution-logo-frame { height: 112px; display: flex; align-items: center; justify-content: center; padding: 6px 12px; }
.institution-logo img { width: 112px; height: 100px; object-fit: contain; }
.institution-logo-wide img { width: 220px; max-width: 100%; }
.institution-logo figcaption { margin-top: 14px; font-size: 13px; font-weight: 600; line-height: 1.6; overflow-wrap: anywhere; }
.institution-logo figcaption span { display: block; font-size: 12px; font-weight: 400; color: var(--muted); }
.institution-text { color: var(--reagent-dark); font-weight: 650; overflow-wrap: anywhere; }
#institutions { scroll-margin-top: 90px; }
@media (max-width: 980px) {
  .institution-logo { flex-basis: calc((100% - 48px) / 3); }
}
@media (max-width: 640px) {
  .institution-grid { gap: 24px 12px; }
  .institution-logo { flex-basis: calc((100% - 12px) / 2); }
  .institution-logo-frame { height: 96px; padding: 4px; }
  .institution-logo img { height: 88px; }
  .institution-logo figcaption { font-size: 12px; }
}
.hero-subtitle { margin: 14px auto 0; max-width: 850px; font-size: clamp(1.1rem, 2.5vw, 1.6rem); font-weight: 650; line-height: 1.4; }
.hero-logos { display: flex; flex-wrap: wrap; justify-content: center; align-items: start; gap: 28px 64px; margin: 30px auto; }
.hero-logo { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 0; max-width: 240px; }
.hero-logo img { width: 112px; height: 112px; object-fit: contain; border-radius: 8px; }
.hero-logo-wide img { width: 176px; }
.hero-logo figcaption { font-size: 14px; font-weight: 650; }
.hero-logo figcaption span { display: block; color: var(--muted); font-size: 12px; }
.logo-text { display: grid; place-items: center; min-height: 112px; font-size: 1.8rem; font-weight: 800; color: var(--reagent-dark); }
.project-resources { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 24px; }
.button.secondary.resource-button { background: var(--surface); }
.resource-button svg { flex-shrink: 0; }
.resource-button.unavailable { color: var(--muted); cursor: default; }
.resource-button.unavailable:hover { transform: none; border-color: var(--line-strong); }
.resource-button small { font-size: 11px; font-weight: 500; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 24px; }
.badge { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 7px 18px; border-radius: 999px; color: #fff; font-weight: 700; background: var(--gradient); box-shadow: 0 4px 10px rgba(0, 143, 145, .3); }
.hero .badge { margin-bottom: 16px; }

.home-sections { border-block: 1px solid var(--line); background: rgba(255,255,255,.72); }
.home-sections .container { display: flex; justify-content: center; gap: 4px; overflow-x: auto; padding-block: 9px; scrollbar-width: thin; }
.home-sections a { flex: 0 0 auto; padding: 7px 11px; border-radius: 999px; color: var(--muted); text-decoration: none; font-size: var(--fs-sm); font-weight: 750; }
.home-sections a:hover { color: var(--reagent-dark); background: #dcebe6; }

/* ===== Figure cards (image + caption strip) ===== */
.figure-card { margin: 22px auto 0; overflow: hidden; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.figure-card.narrow { max-width: 850px; }
.figure-card img { width: 100%; margin: 0 auto; background: var(--surface); }
.figure-caption { margin: 0; padding: 12px 18px 15px; color: var(--muted); font-size: 14px; line-height: 1.55; background: #f9fbf8; border-top: 1px solid #e7eee9; }
.figure-caption b { color: var(--ink); }

/* ===== Highlight stat cards ===== */
.highlight-cards { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; margin-top: 10px; }
.highlight-card { min-height: 140px; padding: 22px 16px; text-align: center; border-radius: var(--radius); border-top: 4px solid var(--reagent); background: var(--surface); box-shadow: var(--shadow); }
.highlight-card .number { font-size: var(--fs-stat); line-height: 1; font-weight: 850; color: var(--reagent-dark); }
.highlight-card .label { margin-top: 10px; color: var(--muted); font-size: 14px; }

/* ===== Abstract ===== */
.section-title { margin: 0 0 20px; text-align: center; font-size: clamp(1.625rem, 3.4vw, 2.125rem); line-height: 1.2; font-weight: 800; }
.content { max-width: var(--prose); margin: 0 auto; color: var(--ink); font-size: 16px; text-align: justify; }
.content p { margin: 0 0 12px; }
.content p:last-child { margin-bottom: 0; }
.tag-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.tag-item { padding: 4px 12px; border-radius: 999px; color: var(--reagent-dark); background: #dcebe6; font-size: 13px; font-weight: 700; }

/* Editorial reading layout, using the same sans-serif family as the site. */
section.paper-abstract { background: var(--paper); }
.paper-abstract .abstract-shell {
  max-width: 880px;
  padding: 0;
}
.paper-abstract .section-title {
  margin-bottom: 32px;
  font-family: inherit;
  font-size: clamp(28px, 3vw, 36px);
  font-weight: 750;
  letter-spacing: -.035em;
  line-height: 1.2;
}
.paper-abstract .abstract-copy {
  max-width: 82ch;
  font-family: inherit;
  font-size: clamp(16px, 1.5vw, 18px);
  font-weight: 400;
  line-height: 1.85;
  color: #354b52;
  text-align: left;
  text-wrap: pretty;
  overflow-wrap: break-word;
}
.paper-abstract .abstract-keywords {
  justify-content: center;
  gap: 8px;
  max-width: 760px;
  margin: 30px auto 0;
}
.paper-abstract .tag-item {
  padding: 6px 12px;
  background: #e8efeb;
  border: 1px solid #d9e4df;
  border-radius: 6px;
  color: #496369;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}
@media (max-width: 640px) {
  .paper-abstract .abstract-copy { font-size: 16px; line-height: 1.8; text-align: left; }
  .paper-abstract .section-title { margin-bottom: 24px; }
  .paper-abstract .abstract-keywords { margin-top: 24px; gap: 6px; }
  .paper-abstract .tag-item { padding: 5px 9px; font-size: 11px; }
}

/* ===== Method cards ===== */
.method-box { margin-top: 18px; padding: 22px; border-radius: var(--radius); background: linear-gradient(135deg, #e4f1ee, #f1f7ec); }
.method-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 18px; }
.method-card { position: relative; padding: 18px; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); border-top: 4px solid var(--reagent); }
.method-card:not(:last-child)::after { content: "→"; position: absolute; top: 50%; right: -22px; z-index: 2; width: 28px; color: var(--reagent-dark); text-align: center; font-weight: 900; transform: translateY(-50%); }
.method-card h3 { margin: 0 0 8px; font-size: 18px; line-height: 1.25; }
.method-card p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; }

/* ===== Tables (UniBYD-style bordered) ===== */
.table-block { margin: 28px 0; }
.table-caption { margin: 0 0 10px; color: var(--muted); text-align: left; font-size: 14px; }
.table-wrap { overflow-x: auto; border-radius: 10px; background: var(--surface); box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 9px 12px; border: 1px solid #d9e2dd; text-align: center; vertical-align: middle; }
th { background: #e8f0ea; color: var(--ink); font-weight: 800; }
td.left, th.left { text-align: left; white-space: nowrap; }
tr.alt td { background: #f6f9f6; }
tbody tr:last-child td { border-bottom: 1px solid #d9e2dd; }
.best { color: var(--best); font-weight: 800; }
.unsupported { color: #b0bcc0; }

.leader-preview, .leaderboard-table { overflow-x: auto; border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.leader-preview th:nth-child(2), .leader-preview td:nth-child(2),
.results-table th:nth-child(2), .results-table td:nth-child(2) { text-align: left; }
.data-table th, .data-table td { text-align: left; }
.inventory-table th:not(:first-child), .inventory-table td:not(:first-child) { text-align: center; }
.rank-medal { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--paper-deep); font-weight: 900; }
.score-number { font-size: var(--fs-score); font-weight: 900; }
.score-unavailable { display: inline-block; max-width: 135px; color: var(--muted); font-size: var(--fs-xs); font-weight: 700; line-height: 1.25; }
.coverage { color: var(--muted); font-size: var(--fs-kicker); }
.empty-state { padding: 50px 24px; text-align: center; color: var(--muted); }
.empty-state strong { display: block; color: var(--ink); font-size: var(--fs-score); }
.detail-toggle { padding: 0; border: 0; background: transparent; cursor: pointer; }
.leaderboard-detail-row > td { padding: 0; text-align: left !important; background: #f7faf7; }
.leaderboard-detail { display: grid; gap: 18px; padding: 22px; }
.leaderboard-detail h3 { margin: 4px 0 -8px; font-size: 1rem; }
.detail-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.detail-summary-grid div { min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.detail-summary-grid span { display: block; color: var(--muted); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; }
.detail-summary-grid strong { display: block; overflow-wrap: anywhere; }
.detail-distributions p { margin: 4px 0; }
.metric-chip { display: inline-block; margin: 2px 3px; padding: 2px 7px; border-radius: 999px; color: var(--reagent-dark); background: #e4f3f0; font-size: var(--fs-xs); white-space: nowrap; }
.nested-table { overflow-x: auto; border-radius: 8px; }
.nested-table table { min-width: 760px; background: var(--surface); font-size: var(--fs-sm); }
.nested-table th, .nested-table td { padding: 7px 9px; }

/* ===== Cards & grids ===== */
.track-grid, .card-grid, .object-grid, .track-score-grid { display: grid; gap: 18px; }
.track-grid { grid-template-columns: repeat(2, 1fr); }
.card-grid { grid-template-columns: repeat(3, 1fr); }
.object-grid { grid-template-columns: repeat(4, 1fr); }
.track-score-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 26px; }
.track-card, .task-card, .object-card, .data-card, .content-card, .video-card, .analysis-box { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255,255,255,.92); box-shadow: 0 6px 20px rgba(16,45,54,.05); }
.track-card { padding: 26px; min-height: 250px; border-top: 4px solid var(--reagent); }
.track-card::before { content: attr(data-prefix); position: absolute; right: -4px; bottom: -35px; color: var(--paper-deep); font: 900 170px/1 var(--font-mono); }
.track-card > * { position: relative; }
.track-code { display: inline-grid; place-items: center; width: 42px; height: 42px; border: 1px solid var(--ink); border-radius: 50%; background: var(--acid); font: 900 16px/1 var(--font-mono); }
.track-card p { color: var(--muted); min-height: 66px; }
.track-count { display: flex; gap: 15px; color: var(--muted); font-size: var(--fs-sm); }
.track-count strong { color: var(--ink); }

.task-card, .object-card { transition: transform .18s, box-shadow .18s; }
.task-card:hover, .object-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card-media { position: relative; aspect-ratio: 16 / 10; overflow: hidden; display: grid; place-items: center; background: linear-gradient(145deg, #dceae5, #f8fbf8); border-bottom: 1px solid var(--line); }
.card-media img, .card-media video { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; }
.task-video-hover-hint { margin: 0; padding: 8px 14px 0; color: var(--reagent-dark); font-size: var(--fs-xs); font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.task-detail-hint { margin: 0; padding: 5px 8px; border-radius: 6px; color: #fff; background: rgba(11,44,53,.78); font-size: var(--fs-2xs); letter-spacing: .04em; }
.task-detail-overlay { position: absolute; left: 12px; bottom: 10px; z-index: 3; pointer-events: none; opacity: 0; transition: opacity .18s; }
.task-card:hover .task-detail-overlay { opacity: .9; }
.media-fallback { position: absolute; z-index: 0; inset: 0; display: grid; place-items: center; color: var(--reagent-dark); font: 900 var(--fs-fallback)/1 var(--font-mono); background: radial-gradient(circle, rgba(0,143,145,.16) 0 18%, transparent 19%), linear-gradient(120deg, transparent 48%, rgba(16,45,54,.08) 49% 51%, transparent 52%); background-size: 100% 100%, 26px 26px; }
.card-body { padding: 20px; }
.card-body h3 { margin-bottom: 7px; }
.card-body p { color: var(--muted); font-size: var(--fs-md); }
.card-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; font: 800 var(--fs-xs)/1.2 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 5px 8px; border-radius: 999px; background: #e3f4e7; color: #286238; font: 800 var(--fs-2xs)/1 var(--font-mono); text-transform: uppercase; letter-spacing: .07em; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #4c9a5c; }
.status.planned { color: #7d611f; background: #fff1cf; }
.status.planned::before { background: var(--amber); }
.card-link { position: absolute; inset: 0; z-index: 2; font-size: 0; }
.chip-row { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 14px; }
.chip { padding: 5px 8px; color: var(--reagent-dark); background: #e4f3f0; border-radius: 6px; font-size: var(--fs-xs); font-weight: 750; text-decoration: none; }

.data-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 18px; }
.data-card { padding: 26px; }
.contract-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; overflow: hidden; border: 1px solid #547077; border-radius: 14px; background: #547077; }
.contract-list div { padding: 17px; color: #d8e7e3; background: #123741; }
.contract-list strong { display: block; color: var(--acid); font: 800 var(--fs-kicker)/1.3 var(--font-mono); text-transform: uppercase; }

/* ===== Demo tabs & video cards ===== */
.demo-tabs { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin: 0 0 20px; }
.demo-tab { border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--muted); padding: 8px 16px; font: inherit; font-weight: 750; cursor: pointer; transition: color 160ms ease, background 160ms ease, border-color 160ms ease; }
.demo-tab:hover { border-color: var(--reagent); color: var(--reagent-dark); }
.demo-tab.active { color: #fff; border-color: var(--reagent); background: var(--gradient); }
.video-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.video-card video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--navy); }
.video-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--navy); }
.video-card h3 { margin: 0; padding: 12px 14px 3px; font-size: 16px; line-height: 1.25; }
.video-card p { margin: 0; padding: 0 14px 14px; color: var(--muted); font-size: 13px; }
.video-card[hidden] { display: none; }

/* ===== BibTeX ===== */
.bibtex-box { position: relative; overflow-x: auto; padding: 22px; border-radius: 10px; background: var(--navy); color: #bfdccd; box-shadow: var(--shadow); }
.copy-btn { position: absolute; top: 12px; right: 12px; border: 0; border-radius: 6px; padding: 6px 12px; background: #1d444c; color: #fff; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.copy-btn:hover { background: #28555e; }
.copy-status { margin: 10px 0 0; color: var(--muted); text-align: center; font-size: var(--fs-sm); }
pre { margin: 0; white-space: pre-wrap; font-family: var(--font-mono); font-size: 13px; line-height: 1.55; }

/* ===== Scroll to top ===== */
.scroll-to-top { position: fixed; right: 22px; bottom: 22px; z-index: 5; width: 44px; height: 44px; display: none; align-items: center; justify-content: center; border: 0; border-radius: 50%; color: #fff; background: var(--reagent); box-shadow: 0 4px 12px rgba(0,143,145,.4); cursor: pointer; font-size: 14px; font-weight: 800; }
.scroll-to-top.visible { display: flex; }

/* ===== Page hero (sub-pages, centered) ===== */
.page-hero { padding: 42px 18px 34px; text-align: center; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.6); }
.page-hero > div { width: min(calc(100% - 40px), var(--max)); margin: auto; }
.page-hero h1 { max-width: 820px; margin: 0 auto 12px; font-size: var(--fs-page-h1); line-height: 1.08; text-wrap: balance; }
.page-hero .lede { max-width: 720px; margin: 0 auto; font-size: var(--fs-page-lede); line-height: 1.5; }
.page-back { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; margin-bottom: 22px; padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: var(--surface); text-decoration: none; font-size: var(--fs-sm); font-weight: 800; box-shadow: 0 4px 14px rgba(16,45,54,.05); }
.page-back span { font-size: 18px; line-height: 1; transition: transform .18s ease; }
.page-back:hover { border-color: var(--reagent); }
.page-back:hover span { transform: translateX(-2px); }
.filter-bar { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 28px; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.filter-bar input, .filter-bar select { min-height: 40px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: var(--paper); }
.filter-bar input { flex: 1 1 250px; }
.filter-bar select { flex: 0 1 190px; }
.result-count { margin-left: auto; align-self: center; color: var(--muted); font-size: var(--fs-sm); }

/* ===== Detail pages ===== */
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 26px; }
.detail-main, .detail-side { display: grid; gap: 18px; align-content: start; }
.detail-media { aspect-ratio: 16 / 8; border-radius: var(--radius); }
.task-demos { display: grid; gap: 24px; }
.demo-variant { display: grid; gap: 14px; padding-top: 20px; border-top: 1px solid var(--line); }
.demo-variant:first-of-type { padding-top: 0; border-top: 0; }
.demo-copy p { margin: 4px 0 0; color: var(--muted); }
.demo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.demo-view { margin: 0; }
.demo-video-shell { position: relative; overflow: hidden; aspect-ratio: 4 / 3; border: 1px solid var(--line); border-radius: 12px; background: #dceae5; }
.demo-video-shell video { width: 100%; height: 100%; object-fit: cover; cursor: pointer; }
.media-kind { position: absolute; z-index: 2; right: 10px; bottom: 10px; padding: 6px 9px; border-radius: 999px; color: #fff; background: rgba(7,31,39,.76); font: 800 var(--fs-2xs)/1 var(--font-mono); text-transform: uppercase; letter-spacing: .06em; pointer-events: none; }
.demo-view figcaption { margin-top: 7px; color: var(--muted); font: 800 var(--fs-xs)/1.3 var(--font-mono); text-transform: uppercase; letter-spacing: .07em; }
.content-card { padding: 26px; }
.page-shell > .content-card + .content-card { margin-top: 26px; }
.page-shell > .content-card + .track-grid { margin-top: 26px; }
.page-shell > .leaderboard-panel + .content-card { margin-top: 30px; }
.content-card h2 { font-size: var(--fs-card-h2); }
.download-callout { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 28px; margin-bottom: 26px; padding: 28px; border: 2px solid var(--reagent); border-radius: var(--radius); background: linear-gradient(135deg, #f4ffe0, #e0f4ee); box-shadow: 0 10px 30px rgba(0, 143, 145, .14); }
.download-callout h2 { margin-bottom: 8px; font-size: var(--fs-card-h2); }
.download-callout p:not(.section-kicker) { margin: 0 0 12px; color: var(--muted); }
.download-url { display: block; color: var(--reagent-dark); font: 700 var(--fs-sm)/1.5 var(--font-mono); overflow-wrap: anywhere; }
.download-actions { display: grid; justify-items: center; gap: 12px; min-width: 260px; }
.download-actions .button { width: 100%; min-height: 50px; font-size: 15px; }
.definition-list { display: grid; gap: 14px; margin: 0; }
.definition-list div { display: grid; gap: 4px; padding-bottom: 13px; border-bottom: 1px solid var(--line); }
.definition-list div:last-child { border-bottom: 0; }
.definition-list dt { color: var(--muted); font: 800 var(--fs-2xs)/1.2 var(--font-mono); text-transform: uppercase; letter-spacing: .08em; }
.definition-list dd { margin: 0; }
.score-bar { display: grid; grid-template-columns: var(--weight) 1fr; align-items: center; gap: 10px; margin: 11px 0; }
.score-bar span { height: 9px; border-radius: 99px; background: var(--reagent); }
.score-bar small { color: var(--muted); }

.object-card .card-media { aspect-ratio: 1.15; }

.split-control { display: inline-flex; gap: 4px; margin-bottom: 24px; padding: 5px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.split-control button { padding: 8px 14px; border: 0; border-radius: 999px; color: var(--muted); background: transparent; cursor: pointer; font-weight: 800; }
.split-control button.active { color: #fff; background: var(--gradient); }
.leaderboard-panel[hidden] { display: none; }
.leaderboard-panel { padding: 0; }
.leaderboard-table td:first-child, .leaderboard-table th:first-child { position: sticky; left: 0; z-index: 1; background: inherit; }
.dataset-task-id { display: inline-block; margin-right: 6px; padding: 2px 7px; border-radius: 6px; color: var(--navy); background: var(--acid); font: 800 var(--fs-2xs)/1.4 var(--font-mono); letter-spacing: .05em; text-transform: uppercase; vertical-align: middle; }

/* ===== Docs ===== */
.docs-layout { display: grid; grid-template-columns: 220px 1fr; gap: 34px; }
.docs-nav { position: sticky; top: 96px; align-self: start; display: grid; gap: 5px; }
.docs-nav a { padding: 8px 10px; color: var(--muted); text-decoration: none; border-left: 2px solid var(--line); }
.docs-nav a:hover { color: var(--reagent-dark); border-color: var(--reagent); }
.docs-nav a.active { color: var(--ink); border-color: var(--reagent); font-weight: 700; }
.docs-content section { padding: 0; scroll-margin-top: 100px; margin-bottom: 46px; }
.code-block { overflow-x: auto; padding: 18px; border-radius: 12px; color: #d8ebe6; background: var(--navy); font: var(--fs-sm)/1.7 var(--font-mono); }

/* ===== Footer ===== */
.site-footer { padding: 44px max(20px, calc((100vw - var(--max)) / 2)) 34px; color: #bfd0cc; text-align: center; background: var(--navy); }
.site-footer p { max-width: 620px; margin: 12px auto 0; }
.footer-brand { display: inline-flex; align-items: center; gap: 11px; color: #fff; text-decoration: none; }
.footer-brand em { color: var(--acid); font-style: normal; }
.footer-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px 18px; margin-top: 16px; }
.footer-links a { color: #d7e4e1; text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }
.footer-note { color: #829c98; font: var(--fs-xs)/1.5 var(--font-mono); text-transform: uppercase; letter-spacing: .08em; }

@media (max-width: 980px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; top: 66px; left: 20px; right: 20px; flex-direction: column; align-items: stretch; padding: 10px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }
  .site-nav.open { display: flex; }
  .site-nav .console-link { margin-left: 0; }
  .hero-grid, .data-grid, .detail-grid { grid-template-columns: 1fr; }
  .highlight-cards { grid-template-columns: repeat(3, 1fr); }
  .method-grid, .video-grid { grid-template-columns: repeat(2, 1fr); }
  .method-card::after { display: none; }
  .track-grid, .card-grid { grid-template-columns: repeat(2, 1fr); }
  .release-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .special-demo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .release-protocol-score-grid { grid-template-columns: repeat(2, 1fr); }
  .object-grid { grid-template-columns: repeat(3, 1fr); }
  .demo-grid { grid-template-columns: 1fr; }
  .download-callout { grid-template-columns: 1fr; }
  .download-actions { justify-items: start; min-width: 0; }
  .download-actions .button { width: auto; }
  .docs-layout { grid-template-columns: 1fr; }
  .docs-nav { position: static; grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 640px) {
  .site-header { min-height: 64px; padding-inline: 16px; }
  .site-brand small { display: none; }
  .brand-logo { width: 38px; height: 38px; }
  .container, .section, .page-shell, .page-hero > div { width: min(calc(100% - 28px), var(--max)); }
  .section { padding: 34px 0; }
  :root { --fs-hero: 2.25rem; --fs-page-h1: 2rem; }
  .hero { padding: 40px 16px 14px; }
  .home-sections .container { justify-content: flex-start; }
  .page-hero h1 { line-height: 1.1; }
  .highlight-cards, .method-grid, .video-grid, .track-grid, .card-grid, .object-grid, .track-score-grid { grid-template-columns: 1fr; }
  .release-card-grid, .special-demo-grid { grid-template-columns: 1fr; }
  .release-protocol-score-grid { grid-template-columns: 1fr; }
  .filter-bar { align-items: stretch; flex-direction: column; }
  .result-count { margin-left: 0; }
  .contract-list { grid-template-columns: 1fr; }
  .docs-nav { grid-template-columns: 1fr 1fr; }
  .content { text-align: left; }
  .text-link { white-space: normal; }
  .download-actions, .download-actions .button { width: 100%; }
  .bibtex-box { padding: 56px 16px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
.special-family-grid,.evaluation-group-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}
.special-family-card{border:1px solid var(--line,#dce5e9);border-radius:20px;overflow:hidden;background:var(--surface,#fff);display:flex;flex-direction:column}
.special-family-media{aspect-ratio:16/9;background:#edf3f5;overflow:hidden}
.special-family-media video{width:100%;height:100%;object-fit:contain;display:block;background:#102b36}
.special-family-media img{width:100%;height:100%;object-fit:contain;display:block;background:#102b36}
.special-family-placeholder{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;background:linear-gradient(135deg,#e9f2f4,#f6f8fa);color:#52717a}
.special-family-placeholder span{font-size:.75rem;letter-spacing:.18em}.special-family-placeholder p{font-size:1.2rem;margin:12px}
.special-family-body{padding:24px;display:flex;flex-direction:column;align-items:flex-start;flex:1}.special-family-body h3{margin:14px 0 8px}.special-family-body p{line-height:1.7}.special-family-body .text-link{margin-top:auto;padding-top:14px}
.section-intro{max-width:780px;line-height:1.8;color:#52646e;margin-bottom:28px}.special-task-section{padding:0 0 56px}
.evaluation-group-nav{display:flex;gap:16px;flex-wrap:wrap;margin-bottom:32px}.evaluation-group-nav a{padding:12px 20px;border:1px solid #dce5e9;border-radius:99px}.family-result-heading th{text-align:left;background:#eef5f6}
#ordinary-tasks,#ordinary-leaderboard,#release-leaderboard{scroll-margin-top:90px}
@media(max-width:720px){.special-family-grid,.evaluation-group-grid{grid-template-columns:1fr}.special-family-body{padding:20px}.section-head{gap:16px;flex-wrap:wrap}.evaluation-group-grid table{font-size:.85rem}}
