:root {
  --white: #ffffff;
  --ink: #172027;
  --muted: #637079;
  --line: #d9e0e3;
  --soft: #f2f7fb;
  --navy: #163f67;
  --accent: #2f77b5;
  --accent-soft: #edf5fb;
  --green: #17725c;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 70px; }
body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background: #f4f9fd;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, select, pre, code { color: inherit; font: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { text-wrap: pretty; }
main { background: linear-gradient(180deg, #fafdff 0%, #f2f8fd 30%, #f8fbfe 67%, #f1f7fc 100%); }

.page-width { width: min(1060px, calc(100% - 64px)); margin-inline: auto; }
.wide-width { width: min(1200px, calc(100% - 64px)); margin-inline: auto; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  padding: 9px 13px;
  transform: translateY(-150%);
  background: var(--ink);
  color: white;
}
.skip-link:focus { transform: translateY(0); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

.site-header {
  position: sticky;
  z-index: 50;
  top: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 64px;
  padding: 0 max(24px, calc((100vw - 1120px) / 2));
  border-bottom: 1px solid var(--line);
  background: rgba(249,252,255,.96);
  backdrop-filter: blur(12px);
}
.brand { display: inline-flex; width: fit-content; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; }
.brand-mark { width: 18px; height: 18px; border: 3px solid var(--navy); border-right-color: var(--accent); border-radius: 50%; }
.site-header nav { display: flex; gap: 30px; }
.site-header nav a, .github-link { color: var(--muted); font-size: 13px; }
.site-header nav a:hover, .github-link:hover { color: var(--accent); }
.github-link { justify-self: end; color: var(--ink); font-weight: 700; }

.hero { padding: 80px 0 70px; text-align: center; }
.kicker {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  margin: 0;
  color: var(--navy);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .055em;
}
.kicker-rule { width: 28px; height: 1px; background: var(--accent); }
.kicker-text b { color: var(--accent); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
h1 { margin: 17px 0 0; font-size: clamp(52px, 6vw, 72px); line-height: 1; letter-spacing: -.05em; }
h1 span { color: var(--accent); }
.hero-question { margin: 22px 0 0; font-size: clamp(20px, 2vw, 25px); font-weight: 700; letter-spacing: -.02em; }
.hero-summary { max-width: 680px; margin: 12px auto 0; color: var(--muted); font-size: 17px; }
.hero-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 27px; }
.button {
  display: inline-flex;
  min-width: 124px;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: white;
  font-size: 13px;
  font-weight: 700;
}
.button:hover { border-color: var(--navy); color: var(--navy); }
.button.primary { border-color: var(--ink); background: var(--ink); color: white; }
.button.primary:hover { border-color: var(--navy); background: var(--navy); }
.benchmark-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 760px;
  margin: 52px auto 0;
  padding-top: 23px;
  border-top: 1px solid var(--line);
}
.benchmark-stats div { border-right: 1px solid var(--line); }
.benchmark-stats div:last-child { border: 0; }
.benchmark-stats dt { font-size: 25px; font-weight: 700; }
.benchmark-stats dd { margin: 2px 0 0; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }

.section { padding: 86px 0 100px; border-top: 1px solid var(--line); }
.leaderboard-section { background: linear-gradient(180deg, rgba(255,255,255,.66), rgba(237,246,253,.72)); }
.benchmark-section { background: rgba(255,255,255,.9); }
.findings-section { background: linear-gradient(180deg, #f7fbfe, #edf6fc); }
.tasks-section { background: rgba(255,255,255,.9); }
.section-header { max-width: 720px; margin: 0 auto 48px; text-align: center; }
.section-kicker { margin: 0 0 8px; color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.section-header h2 { margin: 0; font-size: clamp(28px, 3vw, 35px); line-height: 1.15; letter-spacing: -.035em; }
.section-header > p:last-child { max-width: 650px; margin: 13px auto 0; color: var(--muted); font-size: 15px; }

.result-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.result-summary article { display: grid; min-height: 118px; align-content: center; padding: 18px 22px; border: 1px solid var(--line); border-top: 3px solid var(--navy); }
.result-summary strong { font-size: 27px; letter-spacing: -.03em; }
.result-summary span { margin-top: 1px; font-size: 13px; font-weight: 700; }
.result-summary small { margin-top: 7px; color: var(--muted); font-size: 11px; }

.leaderboard-card { overflow: hidden; border: 1px solid var(--line); border-radius: 6px; }
.leaderboard-toolbar { display: flex; align-items: center; justify-content: space-between; padding: 13px 16px; border-bottom: 1px solid var(--line); background: var(--soft); }
.metric-switch { display: flex; }
.metric-switch button { padding: 7px 13px; border: 1px solid var(--line); background: white; color: var(--muted); font-size: 12px; font-weight: 700; }
.metric-switch button + button { margin-left: -1px; }
.metric-switch button.is-active { position: relative; border-color: var(--ink); background: var(--ink); color: white; }
.leaderboard-toolbar label { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.leaderboard-toolbar select { padding: 7px 29px 7px 9px; border: 1px solid var(--line); background: white; font-size: 12px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 15px 17px; border-bottom: 1px solid var(--line); text-align: left; }
th { color: var(--muted); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }
td { font-size: 13px; }
td:first-child { width: 62px; color: var(--muted); font-size: 11px; }
td:nth-child(2) { width: 28%; font-weight: 700; }
td:nth-child(3) { color: var(--muted); font-size: 12px; }
td.metric-value { width: 100px; font-size: 14px; font-weight: 700; }
tbody tr:first-child { background: #f7fafb; }
tbody tr:first-child td:first-child, tbody tr:first-child .metric-value { color: var(--accent); }
.bar-column { width: 25%; }
.score-bar { position: relative; width: 100%; min-width: 80px; height: 4px; background: #e7ebed; }
.score-bar i { position: absolute; inset: 0 auto 0 0; width: var(--score); background: var(--navy); }
tbody tr:first-child .score-bar i { background: var(--accent); }
.table-note { margin: 0; padding: 12px 16px; color: var(--muted); background: var(--soft); font-size: 11px; text-align: center; }

.efficiency-section { margin-top: 64px; }
.efficiency-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 15px; }
.efficiency-heading h3 { margin: 4px 0 0; font-size: 20px; letter-spacing: -.025em; }
.efficiency-heading > p { margin: 0; color: var(--muted); font-size: 11px; }
.efficiency-card { display: grid; grid-template-columns: 1.35fr .65fr; overflow: hidden; border: 1px solid var(--line); border-radius: 6px; background: white; }
.efficiency-table td:first-child { width: auto; color: var(--ink); font-size: 13px; font-weight: 700; }
.efficiency-table { min-width: 580px; }
.efficiency-table td:nth-child(2) { width: 24%; color: var(--muted); font-size: 12px; font-weight: 400; }
.efficiency-table th:nth-child(n+3), .efficiency-table td:nth-child(n+3) { width: 12%; text-align: right; }
.efficiency-table td:nth-child(n+3) { color: var(--ink); font-weight: 700; }
.efficiency-table tr:last-child td { border-bottom: 0; }
.efficiency-table .efficiency-best { background: var(--accent-soft); }
.efficiency-table .efficiency-best td:first-child, .efficiency-table .efficiency-best td:nth-child(n+3) { color: var(--accent); }
.efficiency-conclusion { display: flex; justify-content: center; flex-direction: column; padding: 30px; border-left: 1px solid var(--line); background: linear-gradient(145deg, #eef6fc, #f8fbfe); }
.efficiency-conclusion strong { color: var(--navy); font-size: 16px; line-height: 1.25; }
.efficiency-conclusion p { margin: 12px 0 0; color: var(--muted); font-size: 12px; }

.protocol-points { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.protocol-points article { display: grid; min-height: 120px; align-content: start; padding: 18px; border: 1px solid var(--line); }
.protocol-points b { color: var(--accent); font-size: 11px; }
.protocol-points strong { margin-top: 20px; font-size: 15px; }
.protocol-points span { margin-top: 4px; color: var(--muted); font-size: 12px; }
.demo-block { width: min(900px, 100%); margin: 70px auto 0; }
.demo-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 12px; }
.demo-heading div { display: flex; align-items: baseline; gap: 10px; }
.demo-heading span { color: var(--accent); font-size: 11px; font-weight: 700; }
.demo-heading strong { font-size: 17px; }
.demo-heading p { margin: 0; color: var(--muted); font-size: 12px; }
.adaptation-demo { overflow: hidden; border: 1px solid var(--line); border-radius: 5px; }
.demo-viewport { position: relative; overflow: hidden; aspect-ratio: 16 / 8.4; background: white; }
.demo-viewport > img { width: 100%; height: 100%; object-fit: cover; transition: opacity 150ms ease, filter 150ms ease; }
.demo-viewport.is-evolving > img { opacity: .17; filter: grayscale(.6); }
.demo-result { position: absolute; right: 18px; bottom: 18px; padding: 6px 10px; border: 1px solid currentColor; background: rgba(255,255,255,.94); color: var(--green); font-size: 10px; font-weight: 700; letter-spacing: .08em; }
.demo-result.fail { color: var(--accent); }
.demo-result.evolving { color: var(--navy); }
.code-evolution { position: absolute; z-index: 2; top: 50%; left: 50%; width: min(75%, 470px); padding: 23px 27px; transform: translate(-50%,-50%); border: 1px solid var(--line); opacity: 0; background: rgba(255,255,255,.98); pointer-events: none; }
.code-evolution.is-visible { opacity: 1; }
.code-evolution p { margin: 0 0 13px; font-size: 13px; font-weight: 700; }
.code-evolution pre { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.code-evolution em, .code-evolution strong { font-style: normal; font-weight: 700; }
.code-evolution em { color: var(--accent); }
.code-evolution strong { color: var(--green); }
.demo-progress { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.demo-progress button { position: relative; display: flex; min-height: 63px; align-items: center; gap: 10px; padding: 13px 16px; border: 0; border-right: 1px solid var(--line); background: white; text-align: left; }
.demo-progress button:last-child { border-right: 0; }
.demo-progress button::before { position: absolute; top: -2px; right: 100%; left: 0; height: 2px; content: ""; background: var(--accent); transition: right 2.15s linear; }
.demo-progress button.is-active::before { right: 0; }
.demo-progress span { color: var(--accent); font-size: 10px; font-weight: 700; }
.demo-progress b { font-size: 12px; }

.task-filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; margin-bottom: 34px; }
.task-filters button { padding: 7px 12px; border: 1px solid var(--line); border-radius: 4px; background: white; color: var(--muted); font-size: 11px; font-weight: 700; }
.task-filters button.is-active, .task-filters button:hover { border-color: var(--navy); background: var(--navy); color: white; }
.task-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); column-gap: 24px; row-gap: 42px; }
.task-card { min-width: 0; padding: 0; border: 0; background: white; text-align: left; }
.task-card.is-hidden { display: none; }
.task-media { position: relative; display: block; overflow: hidden; aspect-ratio: 4 / 3; border: 1px solid var(--line); background: white; }
.task-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 250ms ease; }
.task-card:hover .task-media img, .task-card:focus-visible .task-media img { transform: scale(1.02); }
.task-meta { display: block; padding-top: 10px; }
.task-meta span { color: var(--accent); font-size: 9px; font-weight: 700; }
.task-meta h3 { margin: 2px 0 0; font-size: 13px; line-height: 1.3; }

.finding { border-top: 2px solid var(--ink); padding-top: 22px; }
.finding-main { display: grid; grid-template-columns: 300px 1fr; gap: 55px; }
.finding-copy > span { color: var(--accent); font-size: 10px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.finding-copy h3 { margin: 20px 0 12px; font-size: 24px; line-height: 1.15; letter-spacing: -.03em; }
.finding-copy p { margin: 0; color: var(--muted); font-size: 14px; }
.finding-copy blockquote { margin: 24px 0 0; padding: 13px 15px; border-left: 3px solid var(--accent); background: var(--accent-soft); color: var(--navy); font-size: 12px; font-weight: 700; line-height: 1.5; }
.finding figure { margin: 0; }
.finding figure img { width: 100%; border: 1px solid var(--line); }
.finding figcaption { margin-top: 7px; color: var(--muted); font-size: 10px; }
.finding-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 55px; margin-top: 80px; }
.finding-grid figure { margin-top: 32px; }
.finding-grid .finding-copy { min-height: 225px; }

.knowledge-gap { display: grid; grid-template-columns: .75fr 1.25fr; gap: 60px; margin-top: 90px; padding: 44px 48px; background: linear-gradient(135deg, #123a61, #1d5b8d); color: white; }
.knowledge-gap > div > span { color: #9fc9e9; font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.knowledge-gap h3 { max-width: 600px; margin: 18px 0 13px; font-size: 29px; line-height: 1.12; letter-spacing: -.035em; }
.knowledge-gap p { margin: 0; color: rgba(255,255,255,.78); font-size: 13px; }
.knowledge-gap small { display: block; margin-top: 17px; color: rgba(255,255,255,.52); font-size: 10px; }
.information-results { border-top: 1px solid rgba(255,255,255,.28); }
.capability-pair { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; gap: 10px; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.28); }
.capability-pair span { padding: 11px 13px; background: rgba(255,255,255,.08); color: rgba(255,255,255,.68); font-size: 10px; }
.capability-pair span b { display: block; margin-bottom: 2px; color: white; font-size: 11px; }
.capability-pair i { align-self: center; color: #acd2ee; font-size: 15px; font-style: normal; }
.information-results article { padding: 17px 0; border-bottom: 1px solid rgba(255,255,255,.28); }
.information-results b { color: #acd2ee; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.information-results p { margin: 6px 0 3px; color: white; font-size: 13px; }
.information-results strong { font-size: 15px; }
.information-results span { display: block; color: rgba(255,255,255,.62); font-size: 10px; line-height: 1.45; }
.information-results .capability-pair span { padding: 11px 13px; background: rgba(255,255,255,.08); color: rgba(255,255,255,.68); }
.information-results .capability-pair span b { display: block; margin-bottom: 2px; color: white; }

.research-agenda { margin-top: 72px; padding-top: 26px; border-top: 1px solid var(--line); }
.research-agenda > p { margin: 0 0 22px; color: var(--navy); font-size: 14px; font-weight: 700; text-align: center; }
.research-agenda > div { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; }
.research-agenda article { display: grid; min-height: 105px; align-content: center; padding: 17px 20px; border: 1px solid #c9ddec; background: #f8fbfe; }
.research-agenda b { color: var(--accent); font-size: 13px; }
.research-agenda span { margin-top: 4px; color: var(--muted); font-size: 12px; }

.closing { padding: 100px 0; border-top: 1px solid var(--line); text-align: center; }
.closing h2 { margin: 0 0 27px; font-size: 31px; line-height: 1.2; letter-spacing: -.035em; }
.citation-section { padding: 76px 0 88px; border-top: 1px solid var(--line); }
.citation-section .section-header { margin-bottom: 25px; }
.citation-box { overflow-x: auto; margin: 0; padding: 21px 24px; border: 1px solid var(--line); background: #f7fbfe; color: var(--navy); font-size: 12px; line-height: 1.7; }
.site-footer { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: 95px; padding: 20px max(24px,calc((100vw - 1120px)/2)); border-top: 1px solid var(--line); }
.site-footer p, .site-footer > a:last-child { color: var(--muted); font-size: 11px; }
.site-footer > a:last-child { justify-self: end; }

.task-dialog { width: min(850px,calc(100% - 36px)); padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 6px; color: var(--ink); background: white; }
.task-dialog[open] { display: grid; grid-template-columns: 1.25fr .75fr; }
.task-dialog::backdrop { background: rgba(23,32,39,.48); }
.dialog-close { position: absolute; z-index: 3; top: 12px; right: 12px; width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 50%; background: white; font-size: 20px; }
.dialog-media { min-height: 430px; border-right: 1px solid var(--line); }
.dialog-media img { width: 100%; height: 100%; object-fit: cover; }
.dialog-copy { display: flex; justify-content: center; flex-direction: column; padding: 34px; }
.dialog-copy h2 { margin: 16px 0 0; font-size: 27px; line-height: 1.1; }
.dialog-copy > p:not(.section-kicker) { color: var(--muted); font-size: 13px; }
.dialog-copy dl { margin: 22px 0 0; border-top: 1px solid var(--line); }
.dialog-copy dl div { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 11px; }
.dialog-copy dd { margin: 0; color: var(--muted); }

@media (max-width: 900px) {
  .site-header { grid-template-columns: 1fr auto; }
  .site-header nav { display: none; }
  .protocol-points { grid-template-columns: repeat(2,1fr); }
  .task-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .finding-main { grid-template-columns: 250px 1fr; gap: 35px; }
}

@media (max-width: 680px) {
  .page-width, .wide-width { width: min(100% - 30px,1060px); }
  .hero { padding: 62px 0 55px; }
  h1 { font-size: 51px; }
  .hero-question { font-size: 19px; }
  .hero-summary { font-size: 15px; }
  .benchmark-stats { grid-template-columns: repeat(2,1fr); row-gap: 18px; }
  .benchmark-stats div:nth-child(2) { border: 0; }
  .benchmark-stats div:nth-child(n+3) { padding-top: 18px; border-top: 1px solid var(--line); }
  .section { padding: 68px 0 78px; }
  .section-header { margin-bottom: 38px; }
  .result-summary { grid-template-columns: 1fr; }
  .result-summary article { min-height: 95px; }
  .leaderboard-toolbar { align-items: flex-start; flex-direction: column; gap: 11px; }
  .efficiency-heading { align-items: flex-start; flex-direction: column; gap: 5px; }
  .efficiency-card { grid-template-columns: 1fr; }
  .efficiency-conclusion { border-top: 1px solid var(--line); border-left: 0; }
  .efficiency-table { min-width: 0; }
  .efficiency-table th:nth-child(3), .efficiency-table td:nth-child(3),
  .efficiency-table th:nth-child(4), .efficiency-table td:nth-child(4) { display: none; }
  .efficiency-table th:first-child, .efficiency-table td:first-child { width: 42%; }
  .efficiency-table th:nth-child(2), .efficiency-table td:nth-child(2) { width: 33%; }
  .efficiency-table th:nth-child(5), .efficiency-table td:nth-child(5) { width: 25%; }
  .leaderboard-card td:nth-child(3), .leaderboard-card th:nth-child(3), .leaderboard-card .bar-column { display: none; }
  th, td { padding: 13px 11px; }
  .protocol-points { grid-template-columns: 1fr 1fr; gap: 8px; }
  .protocol-points article { min-height: 125px; padding: 14px; }
  .demo-heading { align-items: flex-start; flex-direction: column; gap: 3px; }
  .demo-viewport { aspect-ratio: 4 / 3; }
  .demo-progress { grid-template-columns: repeat(2,1fr); }
  .demo-progress button { border-bottom: 1px solid var(--line); }
  .demo-progress button:nth-child(2) { border-right: 0; }
  .task-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 32px 14px; }
  .task-meta h3 { font-size: 12px; }
  .finding-main, .finding-grid { grid-template-columns: 1fr; }
  .finding-main figure { margin-top: 25px; }
  .finding-grid { gap: 70px; }
  .finding-grid .finding-copy { min-height: 0; }
  .knowledge-gap { grid-template-columns: 1fr; gap: 35px; padding: 34px 25px; }
  .research-agenda > div { grid-template-columns: 1fr; }
  .task-dialog[open] { grid-template-columns: 1fr; }
  .dialog-media { min-height: 280px; border-right: 0; border-bottom: 1px solid var(--line); }
  .site-footer { grid-template-columns: 1fr auto; }
  .site-footer p { display: none; }
}

@media (max-width: 420px) {
  .kicker-rule { display: none; }
  .kicker { font-size: 13px; letter-spacing: .03em; }
  .protocol-points { grid-template-columns: 1fr; }
  .task-grid { grid-template-columns: 1fr; row-gap: 38px; }
  .task-meta h3 { font-size: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
