:root {
  --bg: #07111f;
  --bg-deep: #030914;
  --panel: #0e1c30;
  --panel-soft: #10243d;
  --line: rgba(173, 205, 240, 0.18);
  --text: #edf6ff;
  --muted: #a6bad0;
  --blue: #8cd3ff;
  --blue-strong: #619cff;
  --violet: #c6adff;
  --violet-strong: #9b79ff;
  --mint: #62ddc2;
  --orange: #ffad68;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0;
  color: var(--text);
  background: radial-gradient(circle at 82% 4%, rgba(117, 128, 255, 0.36), transparent 25rem), radial-gradient(circle at 14% 31%, rgba(91, 178, 255, 0.23), transparent 27rem), var(--bg);
  font-family: "Manrope", Arial, sans-serif;
  line-height: 1.65;
}
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--mint); outline-offset: 4px; }
img, video { display: block; max-width: 100%; }
button { font: inherit; }
.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; }
.skip-link { position: fixed; z-index: 20; left: 1rem; top: -5rem; padding: .7rem 1rem; border-radius: .5rem; color: var(--bg); background: var(--text); }
.skip-link:focus { top: 1rem; }

.site-header { position: sticky; z-index: 10; top: 0; border-bottom: 1px solid rgba(173, 205, 240, 0.12); background: rgba(3, 9, 20, 0.8); backdrop-filter: blur(16px); }
.site-nav { width: min(1240px, calc(100% - 2.5rem)); min-height: 70px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .65rem; font-weight: 800; letter-spacing: -.03em; }
.brand-mark { display: inline-grid; width: 2rem; height: 2rem; place-items: center; border-radius: .58rem; color: #07111f; background: linear-gradient(135deg, var(--blue), var(--violet)); font: 700 .67rem/1 "DM Mono", monospace; letter-spacing: -.08em; }
.nav-links { display: flex; align-items: center; gap: 1.35rem; color: var(--muted); font-size: .86rem; font-weight: 700; }
.nav-links a { transition: color .2s ease; }
.nav-links a:hover { color: var(--blue); }
.nav-toggle { display: none; border: 0; padding: .5rem; color: var(--text); background: transparent; cursor: pointer; }
.nav-toggle span:not(.sr-only) { display: block; width: 22px; height: 2px; margin: 4px; background: currentColor; }

.section-shell { width: min(1180px, calc(100% - 2.5rem)); margin: 0 auto; padding: 7.5rem 0; }
.hero { width: min(1320px, calc(100% - 2.5rem)); min-height: min(800px, calc(100vh - 70px)); display: grid; grid-template-columns: minmax(0, .84fr) minmax(530px, 1.16fr); align-items: center; gap: clamp(2rem, 5vw, 5rem); padding-top: 4.5rem; padding-bottom: 4.5rem; }
.eyebrow { display: flex; align-items: center; gap: .65rem; margin: 0 0 1rem; color: var(--blue); font: 600 clamp(.96rem, 1.05vw, 1.08rem)/1.2 "DM Mono", monospace; letter-spacing: .09em; text-transform: uppercase; }
.eyebrow span { width: 1.5rem; height: 1px; background: currentColor; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.1; letter-spacing: -.052em; }
h1 { max-width: 800px; margin-bottom: 1.4rem; font-size: clamp(2.55rem, 5.1vw, 5rem); font-weight: 800; }
h1 em { color: var(--blue); font-style: normal; }
.hero-summary { max-width: 670px; margin-bottom: 1.45rem; color: #c5d7e9; font-size: clamp(1.02rem, 1.5vw, 1.22rem); line-height: 1.75; }
.authors { max-width: 710px; color: #dceafa; font-size: .94rem; line-height: 1.8; }
.authors a { color: var(--blue); text-decoration: underline; text-decoration-color: rgba(115, 167, 255, .45); text-underline-offset: 3px; }
sup { margin-left: .08rem; color: var(--blue); font-size: .67em; font-weight: 800; }
.affiliations { max-width: 740px; margin: .4rem 0 1.7rem; color: var(--muted); font-size: .81rem; line-height: 1.7; }
.button-row { display: flex; flex-wrap: wrap; gap: .7rem; }
.button { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; padding: .68rem .95rem; border: 1px solid var(--line); border-radius: .55rem; background: rgba(16, 36, 61, .58); color: #e6f2ff; font-size: .88rem; font-weight: 800; transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); border-color: var(--blue); background: var(--panel-soft); }
.button-primary { border-color: var(--blue); color: #07111f; background: var(--blue); }
.button-primary:hover { border-color: #a2c5ff; background: #a2c5ff; }
.button-disabled { cursor: default; color: #c8d5e6; border-color: rgba(198, 173, 255, .38); background: rgba(16, 36, 61, .38); }
.button-disabled:hover { transform: none; border-color: rgba(198, 173, 255, .38); background: rgba(16, 36, 61, .38); }
.hero-media { position: relative; margin: 0; overflow: hidden; border: 1px solid rgba(198, 173, 255, .75); border-radius: 1.2rem; background: #0a1728; box-shadow: 0 24px 70px rgba(0, 0, 0, .28), 0 0 42px rgba(131, 139, 255, .14); }
.hero-media::after { position: absolute; inset: 0; pointer-events: none; content: ""; background: linear-gradient(135deg, rgba(140, 211, 255, .25), transparent 32%, transparent 68%, rgba(198, 173, 255, .25)); }
.hero-media video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.hero-media figcaption { padding: .72rem 1rem; color: var(--muted); font: .76rem/1.4 "DM Mono", monospace; }

.metrics-band { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: min(1180px, calc(100% - 2.5rem)); margin: 0 auto; overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: linear-gradient(100deg, rgba(19, 45, 76, .85), rgba(8, 23, 40, .95)); box-shadow: var(--shadow); }
.metric { display: flex; align-items: center; gap: 1rem; min-height: 135px; padding: 1.5rem clamp(1rem, 2.2vw, 2.35rem); border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric-value { color: var(--blue); font-size: clamp(1.9rem, 3vw, 2.9rem); font-weight: 800; letter-spacing: -.07em; text-shadow: 0 0 20px rgba(140, 211, 255, .28); white-space: nowrap; }
.metric:nth-child(2) .metric-value { color: var(--violet); text-shadow: 0 0 20px rgba(198, 173, 255, .3); }
.metric:nth-child(3) .metric-value { color: #b9caff; }
.unit { font-size: .6em; }
.metric-label { color: #dfeaff; font-size: .95rem; font-weight: 700; line-height: 1.45; }
.metric-label small { color: var(--muted); font-size: .82rem; font-weight: 600; }

.section-heading { max-width: 730px; margin-bottom: 2.6rem; }
.section-heading h2, .settings-copy h2 { margin-bottom: 1rem; font-size: clamp(2rem, 3.5vw, 3.2rem); font-weight: 800; }
.section-heading > p:not(.eyebrow), .settings-copy > p:not(.eyebrow) { color: var(--muted); font-size: 1rem; }
.narrow-heading { max-width: 850px; }
.overview-section { padding-top: 8.5rem; }
.overview-grid { display: grid; grid-template-columns: minmax(250px, .75fr) minmax(0, 1.25fr); align-items: center; gap: clamp(2rem, 5vw, 5rem); }
.prose-card { color: #c5d7e9; font-size: 1rem; }
.prose-card p + p { margin-top: 1.4rem; }
.prose-card strong { color: var(--blue); }
.teaser-figure, .pipeline-figure, .results-figure { margin: 0; }
.teaser-figure { overflow: hidden; border: 1px solid var(--line); border-radius: .9rem; background: #eef4ff; box-shadow: var(--shadow); }
.teaser-figure img { width: 100%; }

.method-section { border-top: 1px solid var(--line); }
.pipeline-figure { overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: #f5f8ff; }
.pipeline-figure img { width: 100%; }
figcaption { color: var(--muted); font-size: .76rem; }
.pipeline-figure figcaption, .results-figure figcaption { padding: .7rem 1rem; background: rgba(10, 22, 38, .95); }
.method-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin-top: 1rem; }
.method-card { min-height: 330px; padding: clamp(1.35rem, 2.7vw, 2.2rem); border: 1px solid rgba(140, 211, 255, .28); border-radius: 1rem; background: linear-gradient(145deg, rgba(33, 77, 139, .92), rgba(8, 20, 36, .88)); }
.ppl-card { border-color: rgba(198, 173, 255, .34); background: linear-gradient(145deg, rgba(75, 51, 123, .78), rgba(13, 22, 42, .96)); }
.card-index { margin-bottom: 1.25rem; color: var(--blue); font: 500 .78rem/1.3 "DM Mono", monospace; letter-spacing: .06em; }
.ppl-card .card-index { color: var(--violet); }
.method-card h3 { margin-bottom: 1rem; font-size: clamp(1.35rem, 2vw, 1.7rem); }
.method-card > p:not(.card-index) { color: var(--muted); font-size: .98rem; }
.method-card ul { display: grid; gap: .45rem; margin: 1.2rem 0 0; padding: 0; list-style: none; color: #d9e9f9; font-size: .91rem; }
.method-card li::before { content: "↗"; margin-right: .55rem; color: var(--mint); }

.results-section { border-top: 1px solid var(--line); }
.results-figure { overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: white; box-shadow: var(--shadow); }
.results-figure img { width: 100%; }
.table-wrap { margin-top: 1.6rem; overflow-x: auto; border: 1px solid rgba(140, 211, 255, .58); border-radius: 1rem; background: linear-gradient(125deg, rgba(17, 45, 79, .96), rgba(31, 23, 69, .88)); box-shadow: 0 18px 42px rgba(0, 0, 0, .2), 0 0 35px rgba(113, 137, 255, .11); }
table { width: 100%; border-collapse: collapse; font-size: clamp(1.08rem, 1.35vw, 1.22rem); white-space: nowrap; }
th, td { padding: 1.2rem 1.12rem; border-bottom: 1px solid rgba(190, 216, 255, .18); text-align: center; }
th { color: #d8ebff; font-weight: 800; }
thead { background: linear-gradient(90deg, rgba(62, 117, 208, .72), rgba(117, 79, 198, .68)); }
thead th { color: #f7fbff; font-size: .88em; letter-spacing: .02em; text-transform: uppercase; }
tbody th { color: #eef6ff; text-align: left; font-size: 1.06em; }
tbody td { color: #cfddf0; font-weight: 600; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
tbody tr.ours { color: #07111f; background: linear-gradient(90deg, #82caff, #c5a9ff); }
tbody tr.ours th, tbody tr.ours td { color: #07111f; font-size: 1.12em; font-weight: 900; }
.table-note { margin: .9rem .2rem 0; color: var(--muted); font-size: .92rem; }

.demos-section { border-top: 1px solid var(--line); }
.task-tabs { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1.2rem; }
.task-tab { border: 1px solid var(--line); border-radius: 999px; padding: .55rem .95rem; color: var(--muted); background: transparent; cursor: pointer; font-size: .8rem; font-weight: 800; transition: all .2s ease; }
.task-tab:hover { border-color: var(--blue); color: var(--text); }
.task-tab.is-active { border-color: var(--blue); color: #07111f; background: var(--blue); }
.view-tabs { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem; margin: -.25rem 0 1rem; color: var(--muted); font-size: .9rem; font-weight: 700; }
.view-tabs > span { margin-right: .25rem; color: #d7e6f9; }
.view-tab { border: 1px solid rgba(198, 173, 255, .38); border-radius: 999px; padding: .45rem .85rem; color: #d5caff; background: rgba(69, 49, 111, .32); cursor: pointer; font-size: .82rem; font-weight: 800; transition: all .2s ease; }
.view-tab:hover { border-color: var(--violet); color: var(--text); }
.view-tab.is-active { border-color: var(--violet); color: #07111f; background: var(--violet); }
.demo-meta { display: flex; align-items: center; flex-wrap: wrap; gap: .55rem; margin-bottom: 1rem; color: var(--muted); font-size: .93rem; }
.demo-meta strong { color: var(--text); }
.live-dot { width: .55rem; height: .55rem; border-radius: 50%; background: var(--orange); box-shadow: 0 0 0 5px rgba(255, 158, 86, .12); }
.demo-pair { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; }
.demo-video-card { margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: .95rem; background: #030914; box-shadow: var(--shadow); }
.real-video-card { border-color: rgba(140, 211, 255, .88); box-shadow: var(--shadow), 0 0 28px rgba(140, 211, 255, .1); }
.synthetic-video-card { border-color: rgba(198, 173, 255, .9); box-shadow: var(--shadow), 0 0 28px rgba(198, 173, 255, .12); }
.video-label { display: flex; justify-content: space-between; gap: .6rem; padding: .75rem .95rem; color: var(--blue); font: 500 .76rem/1.2 "DM Mono", monospace; letter-spacing: .06em; }
.synthetic-video-card .video-label { color: var(--violet); }
.demo-video-card video { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #030914; }
.demo-divider { display: grid; place-items: center; min-width: 70px; color: var(--violet); text-align: center; }
.demo-divider span { font-size: 2.2rem; line-height: 1; }
.demo-divider small { color: var(--muted); font: .7rem/1.3 "DM Mono", monospace; text-transform: uppercase; }

.settings-section { display: grid; grid-template-columns: minmax(240px, .48fr) minmax(0, 1.52fr); align-items: center; gap: clamp(2rem, 5vw, 4.5rem); border-top: 1px solid var(--line); }
.settings-copy { max-width: 470px; }
.task-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; }
.task-image { position: relative; min-height: 168px; margin: 0; overflow: hidden; border: 1px solid rgba(115, 167, 255, .28); border-radius: .8rem; background: #0b192b; }
.task-image-wide { grid-column: span 2; }
.task-image img { width: 100%; height: 100%; min-height: 168px; object-fit: cover; }
.task-image figcaption { position: absolute; right: 0; bottom: 0; left: 0; padding: .65rem .75rem; color: #f2f7ff; background: linear-gradient(transparent, rgba(3, 9, 20, .94)); font-size: .84rem; font-weight: 800; }
.task-image figcaption span { display: block; color: #b9c9df; font-size: .68rem; font-weight: 600; }

.resources-section { border-top: 1px solid var(--line); }
.resource-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .9rem; }
.resource-card { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1rem; min-height: 120px; padding: 1.2rem; border: 1px solid var(--line); border-radius: .85rem; background: rgba(15, 36, 59, .7); transition: transform .2s ease, border-color .2s ease; }
.resource-card:hover { transform: translateY(-3px); border-color: var(--violet); }
.resource-card-disabled { cursor: default; opacity: .86; }
.resource-card-disabled:hover { transform: none; border-color: var(--line); }
.resource-icon { display: grid; width: 3.15rem; height: 3.15rem; place-items: center; border-radius: .65rem; color: #061426; background: var(--blue); font: 700 .76rem/1 "DM Mono", monospace; }
.resource-card:nth-child(2) .resource-icon { background: var(--violet); }
.resource-card:nth-child(3) .resource-icon { background: var(--mint); }
.resource-card strong, .resource-card small { display: block; }
.resource-card strong { font-size: 1.05rem; }
.resource-card small { color: var(--muted); font-size: .87rem; line-height: 1.5; }
.resource-card b { color: var(--blue); font-size: 1.25rem; }

.bibtex-section { border-top: 1px solid var(--line); padding-bottom: 6rem; }
pre { margin: 0; overflow-x: auto; border: 1px solid var(--line); border-radius: .85rem; padding: clamp(1rem, 3vw, 1.8rem); color: #c8e8ff; background: #030914; font: .78rem/1.7 "DM Mono", monospace; }
.site-footer { width: min(1180px, calc(100% - 2.5rem)); margin: 0 auto; padding: 2rem 0 3rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .78rem; }
.site-footer > div { display: flex; align-items: center; gap: .5rem; color: var(--text); }
.site-footer p { margin: .65rem 0 0; }
.footer-credit { font-size: .68rem; }
.footer-credit a { color: var(--blue); text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-links { position: absolute; top: 70px; left: 0; right: 0; display: none; flex-direction: column; align-items: stretch; gap: 0; padding: .5rem 1.25rem 1rem; border-bottom: 1px solid var(--line); background: rgba(3, 9, 20, .97); }
  .nav-links.is-open { display: flex; }
  .nav-links a { padding: .75rem 0; }
  .hero, .overview-grid, .settings-section { grid-template-columns: 1fr; }
  .hero { min-height: auto; padding-top: 4rem; }
  .hero-media { max-width: 760px; }
  .metrics-band { grid-template-columns: 1fr; }
  .metric { min-height: 105px; border-right: 0; border-bottom: 1px solid var(--line); }
  .metric:last-child { border-bottom: 0; }
  .method-cards { grid-template-columns: 1fr; }
  .resource-grid { grid-template-columns: 1fr; }
  .task-gallery { order: -1; }
}

@media (max-width: 620px) {
  .site-nav, .section-shell, .metrics-band, .site-footer { width: min(100% - 1.5rem, 1180px); }
  .section-shell { padding: 5rem 0; }
  h1 { font-size: clamp(2.3rem, 12vw, 3.25rem); }
  .button-row { display: grid; grid-template-columns: 1fr 1fr; }
  .button { justify-content: center; padding-inline: .55rem; font-size: .73rem; }
  .affiliations { font-size: .68rem; }
  .demo-pair { grid-template-columns: 1fr; gap: .75rem; }
  .demo-divider { grid-template-columns: auto auto; gap: .55rem; min-width: 0; }
  .demo-divider span { transform: rotate(90deg); }
  .demo-divider small { text-align: left; }
  .video-label { font-size: .57rem; }
  .task-gallery { grid-template-columns: repeat(2, 1fr); }
  .task-image-wide { grid-column: span 2; }
}

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