:root {
  color-scheme: light;
  --canvas: #f8f7f2;
  --paper: #fff;
  --ink: #20302e;
  --muted: #64706b;
  --accent: #286b63;
  --accent-dark: #194c46;
  --line: #d9ded5;
  --soft: #eef2ed;
  --serif: Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-padding-top: 32px; }
body { margin: 0; background: var(--canvas); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.8; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-underline-offset: 4px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-dark); }
a:focus-visible, button:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
button { font: inherit; }
sup { font-size: .65em; line-height: 0; vertical-align: super; }
sub { font-size: .7em; line-height: 0; }
p { margin: 0 0 1em; }
h1, h2, h3 { text-wrap: balance; }
h2 { margin: 0; font-family: var(--serif); font-size: 44px; line-height: 1.2; font-weight: 400; letter-spacing: -.035em; }
h3 { margin: 0 0 16px; font-family: var(--serif); font-size: 27px; line-height: 1.25; font-weight: 400; letter-spacing: -.02em; }
img { display: block; width: 100%; height: auto; }
[hidden] { display: none !important; }
.page { width: min(1120px, calc(100% - 80px)); margin: 0 auto; }
.skip-link { position: absolute; top: 12px; left: 16px; z-index: 2; transform: translateY(-160%); padding: 8px 14px; background: var(--paper); }
.skip-link:focus { transform: translateY(0); }
.section-nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 25px 0 22px; border-bottom: 1px solid var(--line); }
.masthead-brand { font-family: var(--serif); font-size: 23px; letter-spacing: -.04em; text-decoration: none; }
.nav-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 27px; }
.nav-links a { color: var(--muted); font-size: 12px; font-weight: 500; text-decoration: none; }
.nav-links a:hover { color: var(--accent); text-decoration: underline; }
.hero { padding: 61px 0 52px; text-align: center; }
.brand { margin: 0 0 14px; color: var(--accent); font-family: var(--serif); font-size: 31px; line-height: 1.2; letter-spacing: -.045em; }
.hero-eyebrow { margin: 0 0 25px; color: var(--muted); font-size: 10px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
h1 { margin: 0 auto 27px; max-width: 1040px; font-family: var(--serif); font-size: clamp(42px, 5.9vw, 70px); font-weight: 400; line-height: 1.08; letter-spacing: -.045em; }
h1 > span { display: block; }
h1 em { color: var(--accent); font-weight: 400; }
h1 .title-tail { margin-top: 13px; font-size: .6em; line-height: 1.3; letter-spacing: -.03em; }
.subtitle { max-width: 690px; margin: 0 auto; color: var(--muted); font-size: 17px; line-height: 1.7; text-wrap: balance; }
.authors { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px 22px; max-width: 1040px; margin: 31px auto 16px; padding: 0; list-style: none; font-size: 15px; }
.authors li { white-space: nowrap; }
.authors a { text-decoration: none; }
.authors a:hover { text-decoration: underline; }
.authors sup { margin-left: 2px; color: var(--accent); }
.affiliations { color: var(--muted); font-size: 12px; line-height: 1.8; }
.affiliations p { margin: 0; }
.affiliations sup { color: var(--accent); }
.correspondence { margin: 10px 0 0; color: var(--muted); font-size: 11px; }
.correspondence a { text-decoration: none; }
.resource-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 27px; }
.resource-link { display: inline-flex; justify-content: center; align-items: center; gap: 9px; min-height: 42px; padding: 9px 21px; border: 1px solid #becbc2; border-radius: 4px; background: transparent; color: var(--ink); font-size: 12px; font-weight: 600; line-height: 1.4; text-decoration: none; }
.resource-link:hover { border-color: var(--accent); background: var(--soft); color: var(--accent-dark); }
.resource-link.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.resource-link.primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.resource-link svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.paper-figure { margin: 40px 0 0; }
.overview { margin: 0; padding: 22px 26px 23px; border: 1px solid var(--line); background: var(--paper); }
.figure-label { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 24px; padding-bottom: 14px; border-bottom: 1px solid #e8ece7; color: var(--muted); font-size: 10px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; }
.figure-label span:last-child { color: var(--accent); }
.figure-link { display: block; }
figcaption { margin: 20px auto 0; color: var(--muted); font-size: 12px; line-height: 1.8; }
figcaption strong { color: var(--ink); font-weight: 600; }
figcaption a { white-space: nowrap; font-size: 11px; }
section { margin-top: 85px; padding-top: 28px; border-top: 1px solid var(--line); }
.text-section { max-width: 1120px; margin-left: auto; margin-right: auto; }
.section-heading { margin-bottom: 27px; }
.section-kicker { margin: 0 0 13px; color: var(--accent); font-family: var(--sans); font-size: 10px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; }
#abstract { display: grid; grid-template-columns: 225px minmax(0, 1fr); gap: 66px; }
.abstract-copy { max-width: 755px; color: #3c4944; font-size: 16px; line-height: 1.85; }
.abstract-copy > p:first-child { font-family: var(--serif); font-size: 23px; line-height: 1.6; letter-spacing: -.015em; }
.abstract-copy p:last-child { margin-bottom: 0; }
.section-intro { max-width: 740px; margin-bottom: 0; color: var(--muted); font-size: 16px; }
.contribution-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 36px 0 0; padding: 0; list-style: none; counter-reset: contribution; }
.contribution-list li { min-width: 0; padding: 0 28px; border-left: 1px solid var(--line); counter-increment: contribution; }
.contribution-list li:first-child { border-left: 0; padding-left: 0; }
.contribution-list li:last-child { padding-right: 0; }
.contribution-list li::before { display: block; content: "0" counter(contribution); margin-bottom: 24px; color: #a8b9ae; font-family: var(--serif); font-size: 55px; line-height: 1; letter-spacing: -.07em; }
.contribution-list h3 { font-size: 26px; }
.contribution-list p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.85; }
.usage-section { max-width: 920px; }
.usage-section > p { max-width: 780px; color: var(--muted); font-size: 15px; }
.usage-section code, .usage-code code, .citation-code code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace; }
.usage-section p code { color: var(--ink); font-size: .9em; overflow-wrap: anywhere; }
.usage-code { margin: 20px 0 27px; padding: 23px 27px; overflow-x: auto; border: 1px solid var(--line); background: #f1f3ed; font-size: 13px; line-height: 1.9; tab-size: 2; }
.usage-section .usage-note { font-size: 13px; }
.citation-section { max-width: 920px; margin-left: auto; margin-right: auto; }
.citation-heading { display: flex; justify-content: space-between; align-items: center; gap: 25px; }
.citation-heading h3 { margin-bottom: 10px; font-size: 31px; }
.citation-heading p:not(.section-kicker) { margin: 0; color: var(--muted); font-size: 13px; }
.citation-actions { display: flex; flex-shrink: 0; align-items: center; gap: 18px; font-size: 12px; }
.copy-button { padding: 9px 14px; border: 1px solid #becbc2; border-radius: 3px; background: transparent; color: var(--ink); font-size: 12px; font-weight: 500; cursor: pointer; }
.copy-button:hover { background: var(--soft); border-color: var(--accent); color: var(--accent-dark); }
.copy-button:disabled { cursor: wait; opacity: .7; }
.citation-code { margin: 23px 0 0; padding: 23px 27px; overflow-x: auto; border: 1px solid var(--line); background: #f1f3ed; font-size: 12px; line-height: 1.9; tab-size: 2; }
.copy-status { min-height: 24px; margin: 7px 0 0; color: var(--accent-dark); font-size: 12px; }
footer { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 25px; margin-top: 65px; padding: 25px 0 32px; border-top: 1px solid var(--line); font-size: 11px; }
.footer-brand { font-family: var(--serif); font-size: 22px; letter-spacing: -.04em; text-decoration: none; }
footer p { margin: 0; color: var(--muted); }
footer nav { display: flex; gap: 23px; margin-left: auto; }
footer nav a { text-decoration: none; }
footer nav a:hover { text-decoration: underline; }

@media (max-width: 900px) {
  .page { width: calc(100% - 56px); }
  h1 { font-size: 57px; }
  #abstract { grid-template-columns: 180px minmax(0, 1fr); gap: 35px; }
  .contribution-list li { padding: 0 20px; }
  .contribution-list h3 { font-size: 24px; }
}

@media (max-width: 700px) {
  .page { width: calc(100% - 40px); }
  .section-nav { gap: 17px; padding: 19px 0; }
  .nav-links { gap: 17px; }
  .nav-links a { font-size: 11px; }
  .hero { padding: 45px 0 37px; }
  h1 { font-size: 47px; }
  .subtitle { font-size: 15px; max-width: 510px; }
  .authors { gap: 4px 18px; font-size: 14px; }
  .overview { padding: 17px; }
  .figure-label { margin-bottom: 18px; font-size: 9px; }
  section { margin-top: 60px; padding-top: 24px; }
  h2 { font-size: 38px; }
  #abstract { display: block; }
  .abstract-copy > p:first-child { font-size: 22px; }
  .contribution-list { display: block; margin-top: 28px; }
  .contribution-list li { position: relative; border-left: 0; border-top: 1px solid var(--line); padding: 25px 0 25px 69px; }
  .contribution-list li:first-child, .contribution-list li:last-child { padding-left: 69px; padding-right: 0; }
  .contribution-list li::before { position: absolute; left: 0; top: 28px; font-size: 43px; }
  .contribution-list h3 { font-size: 27px; margin-bottom: 13px; }
  .citation-heading { display: block; }
  .citation-actions { margin-top: 20px; }
  footer p { flex-basis: calc(100% - 110px); }
  footer nav { margin-left: 0; }
}

@media (max-width: 440px) {
  .page { width: calc(100% - 36px); }
  .section-nav { display: block; }
  .masthead-brand { display: inline-block; font-size: 22px; margin-bottom: 11px; }
  .nav-links { justify-content: space-between; gap: 12px; }
  .hero { padding-top: 36px; }
  .brand { font-size: 27px; }
  .hero-eyebrow { font-size: 9px; margin-bottom: 22px; }
  h1 { font-size: 36px; line-height: 1.12; letter-spacing: -.045em; }
  h1 .title-tail { margin-top: 14px; font-size: .68em; line-height: 1.25; }
  .authors { margin-top: 25px; font-size: 13px; gap: 4px 16px; }
  .affiliations { font-size: 11px; }
  .correspondence { font-size: 10px; }
  .resource-link { padding: 9px 17px; }
  .overview { padding: 14px 12px; }
  .figure-label { gap: 10px; font-size: 8px; letter-spacing: .09em; padding-bottom: 11px; }
  figcaption { font-size: 11px; }
  .section-heading { margin-bottom: 23px; }
  .abstract-copy { font-size: 15px; }
  .abstract-copy > p:first-child { font-size: 21px; }
  .section-intro { font-size: 15px; }
  .contribution-list li, .contribution-list li:first-child, .contribution-list li:last-child { padding-left: 53px; }
  .contribution-list li::before { font-size: 35px; }
  .contribution-list h3 { font-size: 25px; }
  .usage-code, .citation-code { padding: 17px; font-size: 11px; }
  .citation-actions { gap: 17px; }
}

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

@media print {
  body { background: #fff; }
  .section-nav, .resource-links, .copy-button, .copy-status, footer nav, .skip-link { display: none; }
  .page { width: 100%; }
  .hero { padding-top: 10px; }
  h1 { font-size: 38px; }
  section { margin-top: 35px; }
  .paper-figure { break-inside: avoid; }
  .citation-code, .usage-code { white-space: pre-wrap; overflow-wrap: anywhere; }
}

/* Experimental results */
.results-section .paper-figure { padding: 22px; border: 1px solid var(--line); background: var(--paper); }
.results-block { margin-top: 44px; }
.results-block h3 { margin-bottom: 10px; }
.results-description, .table-note { color: var(--muted); font-size: 13px; }
.results-table-wrap { margin-top: 20px; overflow-x: auto; border-top: 2px solid var(--accent); border-bottom: 1px solid var(--line); background: var(--paper); }
.results-table { width: 100%; border-collapse: collapse; font-size: 13px; font-variant-numeric: tabular-nums; line-height: 1.6; }
.results-table th, .results-table td { padding: 13px 16px; text-align: right; white-space: nowrap; border-bottom: 1px solid #e8ece7; }
.results-table thead th { color: var(--muted); font-weight: 500; background: #f1f3ed; }
.results-table thead tr:first-child th { text-align: center; color: var(--ink); }
.results-table th:first-child { text-align: left !important; }
.results-table tbody th { font-weight: 500; }
.results-table tbody tr:last-child > * { border-bottom: 0; }
.results-table .ours > * { background: #eaf0ea; color: var(--accent-dark); font-weight: 650; }
.results-table .group-divider { border-left: 1px solid var(--line); }
.table-note { margin-top: 12px; font-size: 12px; }
@media (max-width: 700px) {
  .results-section .paper-figure { padding: 12px; }
  .results-table th, .results-table td { padding: 11px 13px; }
  .results-block { margin-top: 32px; }
}

/* Method workflow: preserve legible labels instead of shrinking the diagram on mobile. */
.method-diagram { margin: 30px 0 0; }
.method-diagram-scroll { overflow-x: auto; border: 1px solid var(--line); background: var(--paper); }
.method-diagram-scroll img { display: block; width: 100%; min-width: 1050px; max-width: none; height: auto; }
.method-diagram-guide { margin-top: 10px; font-size: 11px; }
.method-diagram-guide a { margin-left: 5px; }
.method-caption-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin: 27px 0 0; font-family: "Times New Roman", Times, serif; }
.method-caption-list > div { min-width: 0; padding-top: 16px; border-top: 1px solid var(--line); }
.method-caption-list dt { margin-bottom: 9px; color: var(--ink); font-size: 23px; line-height: 1.3; }
.method-caption-list dd { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
@media (max-width: 700px) {
  .method-caption-list { grid-template-columns: 1fr; gap: 18px; }
  .method-caption-list dt { font-size: 22px; }
  .method-diagram-guide { font-size: 11px; }
}
@media print {
  .method-diagram-scroll { overflow: visible; }
  .method-diagram-scroll img { min-width: 0; }
}
.results-table .setting-row th { padding: 10px 16px; background: #f8f7f2; color: var(--accent); font-size: 13px; font-weight: 600; border-top: 1px solid var(--line); }
.results-table .ours > * { font-weight: 400; }
.results-table strong { font-weight: 700; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
/* Paper body typography */
.text-section, .citation-section { font-family: "Times New Roman", Times, serif; }
.text-section p:not(.section-kicker):not(.module-label):not(.table-note), .abstract-copy { font-family: "Times New Roman", Times, serif; font-size: 18px; }
.text-section .abstract-copy > p:first-child { font-size: 23px; }
.text-section h2, .text-section h3, .citation-section h3 { font-family: "Times New Roman", Times, serif; }
.results-table { font-family: "Times New Roman", Times, serif; font-size: 16px; }
.text-section figcaption, .table-note { font-family: "Times New Roman", Times, serif; font-size: 15px; }
.section-kicker, .copy-button, .citation-actions { font-family: var(--sans); }
@media (max-width: 440px) {
  .nav-links { gap: 10px; }
  .nav-links a { font-size: 10px; }
  .text-section p:not(.section-kicker):not(.module-label):not(.table-note), .abstract-copy { font-size: 17px; }
}
@media (max-width: 700px) {
  .results-description::after { content: "Swipe the table to view all metrics →"; display: block; margin-top: 10px; color: var(--accent); font-family: var(--sans); font-size: 11px; }
}
