:root {
  --bg: #071119;
  --bg-2: #0c1824;
  --panel: rgba(255, 255, 255, 0.072);
  --panel-strong: rgba(255, 255, 255, 0.115);
  --border: rgba(255, 255, 255, 0.13);
  --border-strong: rgba(255, 255, 255, 0.24);
  --text: #eef6fb;
  --muted: #a6b7c4;
  --muted-2: #7f93a2;
  --accent: #7ce4cf;
  --accent-2: #bfa7ff;
  --accent-3: #ffcf7c;
  --danger: #ff8a9a;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --radius: 24px;
  --max: 1240px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 16% 8%, rgba(124, 228, 207, 0.15), transparent 31%),
    radial-gradient(circle at 86% 2%, rgba(191, 167, 255, 0.18), transparent 27%),
    linear-gradient(140deg, var(--bg), var(--bg-2));
  line-height: 1.6;
}

a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 10px;
  color: #06201b;
  background: var(--accent);
  font-weight: 900;
}
.skip-link:focus { top: 16px; }

.site-header {
  width: min(var(--max), calc(100% - 34px));
  margin: 0 auto;
  padding: 24px 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  border: 1px solid rgba(124, 228, 207, 0.45);
  color: #06201b;
  background: linear-gradient(145deg, var(--accent), #b5f3e8);
  font-weight: 950;
  box-shadow: 0 12px 30px rgba(124, 228, 207, 0.2);
}
.brand strong, .brand small { display: block; }
.brand strong { font-size: 1rem; letter-spacing: -0.02em; }
.brand small { color: var(--muted); font-size: 0.72rem; }

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
}
nav a {
  padding: 8px 10px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 720;
}
nav a:hover, nav a:focus-visible { color: var(--text); }
nav .nav-button {
  padding: 9px 14px;
  color: #06201b;
  background: var(--accent);
  border-radius: 999px;
  font-weight: 900;
}

.section-shell {
  width: min(var(--max), calc(100% - 34px));
  margin: 0 auto;
  padding: 74px 0;
}

.hero {
  min-height: 660px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: 42px;
  align-items: center;
  padding-top: 48px;
}
.eyebrow, .mini-label {
  margin: 0 0 13px;
  color: var(--accent);
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 850;
}
h1, h2, h3, p { margin-top: 0; }
h1 {
  max-width: 790px;
  margin-bottom: 22px;
  font-size: clamp(4rem, 10vw, 8.8rem);
  line-height: 0.84;
  letter-spacing: -0.085em;
}
h2 {
  margin-bottom: 15px;
  font-size: clamp(2rem, 4.2vw, 3.65rem);
  line-height: 1.02;
  letter-spacing: -0.055em;
}
h3 {
  margin-bottom: 10px;
  font-size: 1.22rem;
  line-height: 1.25;
  letter-spacing: -0.025em;
}
.hero-lead {
  max-width: 780px;
  margin-bottom: 28px;
  color: #c8d6df;
  font-size: clamp(1.12rem, 2.1vw, 1.48rem);
  line-height: 1.55;
}
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.button {
  appearance: none;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 11px 16px;
  text-decoration: none;
  cursor: pointer;
  font-weight: 850;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}
.button:hover, .button:focus-visible { transform: translateY(-1px); }
.button.primary { color: #06201b; background: var(--accent); }
.button.secondary {
  color: var(--text);
  background: rgba(191, 167, 255, 0.18);
  border-color: rgba(191, 167, 255, 0.4);
}
.button.ghost {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.055);
  border-color: var(--border);
}
.button.ghost:hover { color: var(--text); border-color: var(--border-strong); }

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 820px;
  margin-top: 34px;
}
.hero-metrics div {
  min-height: 92px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.14);
}
.hero-metrics strong, .hero-metrics span { display: block; }
.hero-metrics strong { margin-bottom: 3px; font-size: 1.25rem; }
.hero-metrics span { color: var(--muted); font-size: 0.83rem; }

.hero-card,
.video-card,
.concept-card,
.math-card,
.scope-grid article,
.reading-card,
.honesty-card {
  border: 1px solid var(--border);
  background: linear-gradient(145deg, rgba(255,255,255,0.105), rgba(255,255,255,0.045));
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}
.hero-card {
  padding: 26px;
  border-radius: var(--radius);
}
.hero-card h2 { font-size: 2rem; }
.hero-card p { color: var(--muted); }
.hero-card .authors { color: var(--text); font-weight: 720; }
.text-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 850;
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.62fr);
  gap: 40px;
  align-items: end;
  margin-bottom: 30px;
}
.section-heading > p {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 1.02rem;
}

.video-card {
  overflow: hidden;
  border-radius: 28px;
}
video {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #02070b;
}
.video-meta {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 15px 20px 18px;
  color: var(--muted);
  font-size: 0.86rem;
}
.video-meta p { max-width: 820px; margin-bottom: 0; }
.video-meta a { color: var(--accent); white-space: nowrap; font-weight: 800; }

.chapter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}
.chapter {
  min-height: 150px;
  padding: 16px;
  text-align: left;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,0.045);
  cursor: pointer;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}
.chapter:hover, .chapter:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(124, 228, 207, 0.55);
  background: rgba(124, 228, 207, 0.07);
}
.chapter span, .chapter strong, .chapter small { display: block; }
.chapter span { margin-bottom: 9px; color: var(--accent); font-variant-numeric: tabular-nums; font-weight: 850; }
.chapter strong { margin-bottom: 6px; }
.chapter small { color: var(--muted); line-height: 1.45; }

.three-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.concept-card {
  min-height: 290px;
  padding: 24px;
  border-radius: var(--radius);
}
.concept-card p { color: var(--muted); }
.card-number, .math-index {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin-bottom: 42px;
  border: 1px solid rgba(124, 228, 207, 0.35);
  border-radius: 14px;
  color: var(--accent);
  background: rgba(124, 228, 207, 0.08);
  font-size: 0.83rem;
  font-weight: 900;
}

.flow-card {
  display: grid;
  grid-template-columns: repeat(7, auto);
  gap: 13px;
  align-items: center;
  margin-top: 16px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.16);
}
.flow-card > div { min-width: 0; }
.flow-card span {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-bottom: 10px;
  border-radius: 50%;
  color: #06201b;
  background: var(--accent);
  font-size: 0.78rem;
  font-weight: 950;
}
.flow-card strong { display: block; margin-bottom: 5px; }
.flow-card p { margin: 0; color: var(--muted); font-size: 0.83rem; }
.flow-card i { color: var(--muted-2); font-style: normal; font-size: 1.3rem; }

.honesty-card {
  display: grid;
  grid-template-columns: 0.52fr 1fr;
  gap: 34px;
  margin-top: 16px;
  padding: 25px;
  border-radius: var(--radius);
  border-color: rgba(255, 207, 124, 0.28);
}
.honesty-card p { margin-bottom: 0; color: var(--muted); }

.maths-grid { display: grid; gap: 16px; }
.math-card {
  position: relative;
  padding: 26px;
  border-radius: var(--radius);
}
.math-card p { color: var(--muted); }
.math-index { margin-bottom: 18px; }
.equation {
  margin: 20px 0;
  padding: 18px;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 17px;
  color: #d8fff7;
  background: rgba(0, 0, 0, 0.23);
  text-align: center;
  font-size: clamp(1rem, 2vw, 1.22rem);
}
.equation.compact { margin: 16px 0; }
.featured-math {
  border-color: rgba(124, 228, 207, 0.38);
  background:
    radial-gradient(circle at 85% 15%, rgba(124, 228, 207, 0.11), transparent 35%),
    linear-gradient(145deg, rgba(255,255,255,0.105), rgba(255,255,255,0.045));
}
.plain-language {
  padding: 13px 15px;
  border-left: 3px solid var(--accent);
  border-radius: 0 12px 12px 0;
  color: #cfe1e9;
  background: rgba(124, 228, 207, 0.065);
}
.formal-details {
  margin-top: 16px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255,255,255,0.042);
}
.formal-details summary {
  padding: 17px 20px;
  cursor: pointer;
  font-weight: 850;
}
.formal-details > div { padding: 0 20px 20px; color: var(--muted); }

.split-section {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 58px;
}
.large-copy {
  color: #c8d6df;
  font-size: 1.22rem;
  line-height: 1.65;
}
.benefit-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.benefit-list article {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(0,0,0,0.14);
}
.benefit-list p { margin-bottom: 0; color: var(--muted); font-size: 0.9rem; }

.scope-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.scope-grid article {
  min-height: 230px;
  padding: 22px;
  border-radius: 20px;
}
.scope-grid article > span {
  display: inline-block;
  margin-bottom: 32px;
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--accent);
  background: rgba(124, 228, 207, 0.08);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.scope-grid p { color: var(--muted); }

.reading-section {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 16px;
}
.reading-card {
  padding: 26px;
  border-radius: var(--radius);
}
.reading-card p { color: var(--muted); }
.preprint-card h2 { font-size: clamp(1.9rem, 3.6vw, 3.1rem); }
.citation {
  margin-top: 20px;
  margin-bottom: 0;
  font-size: 0.84rem;
}
.related-card ul { margin: 20px 0 0; padding: 0; list-style: none; }
.related-card li { border-top: 1px solid var(--border); }
.related-card a {
  display: block;
  padding: 14px 0;
  color: #d6e2e9;
  text-decoration: none;
  font-weight: 760;
}
.related-card a:hover { color: var(--accent); }

footer {
  width: min(var(--max), calc(100% - 34px));
  margin: 0 auto;
  padding: 34px 0 46px;
  display: flex;
  justify-content: space-between;
  gap: 28px;
  border-top: 1px solid var(--border);
}
footer p { margin: 4px 0 0; color: var(--muted); }
.footer-links { display: flex; gap: 16px; align-items: center; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--text); }

.copy-toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 20;
  max-width: min(360px, calc(100% - 44px));
  padding: 12px 15px;
  border: 1px solid rgba(124, 228, 207, 0.42);
  border-radius: 13px;
  color: var(--text);
  background: rgba(6, 18, 24, 0.94);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}
.copy-toast.show { opacity: 1; transform: translateY(0); }

:focus-visible {
  outline: 3px solid rgba(124, 228, 207, 0.85);
  outline-offset: 3px;
}

@media (max-width: 980px) {
  .site-header { align-items: flex-start; }
  nav a:not(.nav-button) { display: none; }
  .hero, .section-heading, .split-section, .reading-section, .honesty-card {
    grid-template-columns: 1fr;
  }
  .hero { min-height: auto; padding-top: 86px; }
  .three-card-grid, .scope-grid { grid-template-columns: 1fr 1fr; }
  .chapter-grid { grid-template-columns: 1fr 1fr; }
  .flow-card { grid-template-columns: 1fr; }
  .flow-card i { transform: rotate(90deg); justify-self: center; }
}

@media (max-width: 660px) {
  .site-header, .section-shell, footer { width: min(100% - 20px, var(--max)); }
  .brand small { display: none; }
  nav .nav-button { font-size: 0.78rem; padding: 8px 11px; }
  .section-shell { padding: 52px 0; }
  .hero { padding-top: 66px; }
  h1 { font-size: clamp(3.7rem, 22vw, 6rem); }
  .hero-metrics, .three-card-grid, .chapter-grid, .scope-grid, .benefit-list {
    grid-template-columns: 1fr;
  }
  .video-meta, footer { flex-direction: column; }
  .video-meta a { white-space: normal; }
  .concept-card, .scope-grid article { min-height: auto; }
}

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