:root {
  --navy: #10223f;
  --ink: #182235;
  --muted: #5c697c;
  --paper: #fbfaf5;
  --white: #ffffff;
  --line: #d5dfeb;
  --blue: #2367c9;
  --blue-soft: #eaf2ff;
  --teal: #087267;
  --teal-soft: #e4f4f1;
  --orange: #ad5612;
  --orange-soft: #fff0e1;
  --green: #1f773f;
  --green-soft: #eaf6ed;
  --red: #b83931;
  --red-soft: #fcebe8;
  --purple: #7057b5;
  --shadow-sm: 0 10px 30px rgba(16, 34, 63, 0.08);
  --shadow-lg: 0 30px 80px rgba(16, 34, 63, 0.16);
  --radius: 24px;
  --shell: min(1180px, calc(100vw - 40px));
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 86px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
}

img {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
}

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

.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;
  top: 10px;
  left: 10px;
  z-index: 1000;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--navy);
  color: white;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.cursor-comet {
  position: fixed;
  inset: 0;
  z-index: 90;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: multiply;
  contain: strict;
  will-change: opacity;
  transition: opacity 220ms ease;
}

.cursor-comet.visible {
  opacity: 1;
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  border-bottom: 1px solid transparent;
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.site-header.scrolled {
  background: rgba(251, 250, 245, 0.9);
  border-color: rgba(16, 34, 63, 0.08);
  box-shadow: 0 8px 30px rgba(16, 34, 63, 0.05);
  backdrop-filter: blur(16px);
}

.nav-shell {
  width: var(--shell);
  min-height: 72px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--navy);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  color: white;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  font-family: Georgia, serif;
  font-size: 1.25rem;
  font-style: italic;
  box-shadow: 0 8px 20px rgba(35, 103, 201, 0.24);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(12px, 1.5vw, 24px);
}

.nav-links a {
  position: relative;
  padding: 24px 0 22px;
  color: #4c5a6e;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
}

.nav-links a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 18px;
  left: 0;
  height: 2px;
  border-radius: 99px;
  background: var(--teal);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 160ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible,
.nav-links a.active {
  color: var(--navy);
}

.nav-links a:hover::after,
.nav-links a:focus-visible::after,
.nav-links a.active::after {
  transform: scaleX(1);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
}

.menu-button span:not(.sr-only) {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 99px;
  background: var(--navy);
}

.hero {
  position: relative;
  min-height: 100vh;
  padding: 126px 0 76px;
  overflow: hidden;
  background:
    radial-gradient(circle at 78% 22%, rgba(35, 103, 201, 0.12), transparent 28%),
    radial-gradient(circle at 20% 78%, rgba(13, 135, 121, 0.10), transparent 26%),
    linear-gradient(180deg, #fbfdff 0%, #f4f8fb 62%, var(--paper) 100%);
}

.hero-grid {
  position: absolute;
  inset: 0;
  opacity: 0.48;
  background-image:
    linear-gradient(rgba(16, 34, 63, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 34, 63, 0.045) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, black 0, rgba(0, 0, 0, 0.75) 65%, transparent 100%);
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(1px);
  pointer-events: none;
}

.hero-orb-one {
  top: 18%;
  right: -130px;
  width: 330px;
  height: 330px;
  border: 1px solid rgba(35, 103, 201, 0.18);
  box-shadow: inset 0 0 80px rgba(35, 103, 201, 0.06);
}

.hero-orb-two {
  bottom: 3%;
  left: -110px;
  width: 260px;
  height: 260px;
  border: 1px dashed rgba(13, 135, 121, 0.22);
}

.hero-layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.84fr) minmax(500px, 1.16fr);
  align-items: center;
  gap: clamp(48px, 6vw, 88px);
}

.eyebrow,
.section-kicker,
.mini-label,
.caption-label {
  margin: 0;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
}

.eyebrow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 7px rgba(13, 135, 121, 0.11);
}

.hero h1 {
  max-width: 650px;
  margin: 22px 0 12px;
  color: var(--navy);
  font-size: clamp(3.5rem, 6.1vw, 6.5rem);
  line-height: 0.93;
  letter-spacing: -0.065em;
}

.hero h1 span {
  color: transparent;
  background: linear-gradient(105deg, var(--blue) 5%, var(--teal) 55%, var(--green));
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-subtitle {
  margin: 0 0 22px;
  color: var(--navy);
  font-size: clamp(1.35rem, 2vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.035em;
}

.hero-thesis {
  max-width: 590px;
  margin: 0;
  color: #526075;
  font-size: clamp(1.03rem, 1.4vw, 1.18rem);
}

.hero-thesis strong {
  color: var(--navy);
}

.author-line {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.author-line span {
  margin: 0 8px;
  color: var(--line);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 13px;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button-primary {
  color: white;
  background: var(--navy);
  box-shadow: 0 12px 24px rgba(16, 34, 63, 0.18);
}

.button-primary span {
  margin-left: 8px;
}

.button-secondary {
  color: var(--teal);
  border-color: rgba(13, 135, 121, 0.25);
  background: rgba(255, 255, 255, 0.75);
}

.button-ghost {
  color: var(--muted);
  background: transparent;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 620px;
  margin-top: 34px;
  border-top: 1px solid var(--line);
}

.metric-strip div {
  padding: 18px 12px 0 0;
}

.metric-strip strong {
  display: block;
  color: var(--navy);
  font-size: 1.25rem;
  line-height: 1;
}

.metric-strip span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.68rem;
}

.hero-card,
.feature-figure {
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(16, 34, 63, 0.08);
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow-lg);
}

.hero-card {
  transform: rotate(1deg);
}

.figure-open {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.figure-open img {
  width: 100%;
  transition: transform 350ms ease;
}

.figure-open:hover img,
.figure-open:focus-visible img {
  transform: scale(1.012);
}

.hero-card figcaption,
.feature-figure figcaption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 22px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.78rem;
}

.caption-label {
  display: block;
  margin-bottom: 2px;
  color: var(--teal);
}

.section {
  position: relative;
  padding: 116px 0;
  background: white;
}

.section-ivory {
  background: var(--paper);
}

.section-teal {
  background:
    radial-gradient(circle at 90% 14%, rgba(13, 135, 121, 0.11), transparent 27%),
    #f1f8f6;
}

.section-green {
  background:
    radial-gradient(circle at 8% 82%, rgba(39, 135, 74, 0.09), transparent 26%),
    #f5f9f4;
}

.section-dark {
  color: white;
  background:
    radial-gradient(circle at 80% 12%, rgba(35, 103, 201, 0.23), transparent 30%),
    radial-gradient(circle at 8% 84%, rgba(13, 135, 121, 0.18), transparent 27%),
    var(--navy);
}

.section-cite {
  background: #eef3f8;
}

.section-heading {
  max-width: 850px;
  margin: 0 auto 52px;
  text-align: center;
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.section-kicker span {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 0.66rem;
}

.section-heading h2 {
  margin: 20px 0 14px;
  color: var(--navy);
  font-size: clamp(2.1rem, 4.2vw, 4.2rem);
  line-height: 1.04;
  letter-spacing: -0.055em;
}

.section-heading > p:last-child {
  max-width: 790px;
  margin: 0 auto;
  color: var(--muted);
  font-size: 1rem;
}

.section-dark .section-heading h2,
.section-dark .section-heading > p:last-child {
  color: white;
}

.section-dark .section-heading > p:last-child {
  color: #c7d4e7;
}

.feature-figure {
  max-width: 1080px;
  margin: 0 auto 48px;
  box-shadow: var(--shadow-sm);
}

.portrait-figure {
  max-width: 760px;
}

.portrait-figure img {
  max-height: 980px;
  margin: 0 auto;
  object-fit: contain;
}

.figure-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  white-space: nowrap;
}

.figure-actions a,
.figure-actions button {
  padding: 0;
  border: 0;
  color: var(--teal);
  background: transparent;
  font-size: 0.72rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.lens-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.lens-card {
  position: relative;
  min-height: 220px;
  padding: 28px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  box-shadow: var(--shadow-sm);
}

.lens-card::after {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  opacity: 0.1;
  background: currentColor;
}

.lens-card > span {
  color: currentColor;
  font-size: 0.74rem;
  font-weight: 900;
}

.lens-card h3 {
  margin: 42px 0 10px;
  color: var(--navy);
  font-size: 1.18rem;
  line-height: 1.2;
}

.lens-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.lens-card.blue { color: var(--blue); }
.lens-card.teal { color: var(--teal); }
.lens-card.orange { color: var(--orange); }
.lens-card.green { color: var(--green); }

.category-errors {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 28px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--line);
}

.category-errors p {
  margin: 0;
  padding: 18px 14px;
  background: white;
  color: var(--muted);
  font-size: 0.78rem;
  text-align: center;
}

.category-errors span {
  color: var(--navy);
  font-weight: 850;
}

.benchmark-ladder {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
  align-items: end;
  margin-bottom: 34px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f8fbff;
}

.benchmark-ladder article {
  position: relative;
  min-height: 130px;
  padding: 18px 14px;
  border: 1px solid rgba(35, 103, 201, 0.18);
  border-radius: 15px;
  background: white;
}

.benchmark-ladder article:nth-child(2) { transform: translateY(-8px); }
.benchmark-ladder article:nth-child(3) { transform: translateY(-16px); }
.benchmark-ladder article:nth-child(4) { transform: translateY(-24px); }
.benchmark-ladder article:nth-child(5) { transform: translateY(-32px); }
.benchmark-ladder article:nth-child(6) { transform: translateY(-40px); }

.benchmark-ladder span {
  color: var(--blue);
  font-size: 0.7rem;
  font-weight: 900;
}

.benchmark-ladder h3 {
  margin: 28px 0 2px;
  color: var(--navy);
  font-size: 0.93rem;
}

.benchmark-ladder p {
  margin: 0;
  color: var(--muted);
  font-size: 0.68rem;
}

.two-column,
.orthogonal-notes,
.cite-layout {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.statement-card,
.note-card {
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--paper);
}

.statement-card.dark {
  color: white;
  border-color: var(--navy);
  background: var(--navy);
}

.statement-card h3,
.note-card h3 {
  margin: 10px 0 16px;
  color: var(--navy);
  font-size: 1.5rem;
  line-height: 1.18;
}

.statement-card.dark h3 {
  color: white;
}

.statement-card ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 0.86rem;
}

.statement-card.dark ul {
  color: #cbd7e9;
}

.audit-callout {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  margin-top: 20px;
  padding: 28px 30px;
  border: 1px solid rgba(202, 69, 58, 0.25);
  border-radius: 20px;
  background: var(--red-soft);
}

.audit-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 15px;
  color: white;
  background: var(--red);
  font-size: 1.35rem;
  font-weight: 900;
}

.audit-callout h3 {
  margin: 4px 0 5px;
  color: var(--navy);
  font-size: 1.2rem;
}

.audit-callout p {
  margin: 0;
  color: var(--muted);
  font-size: 0.83rem;
}

.audit-callout > a {
  color: var(--red);
  font-size: 0.75rem;
  font-weight: 850;
  text-decoration: none;
}

.factory-flow {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr auto 1fr;
  align-items: center;
  gap: 10px;
  padding: 30px;
  border: 1px solid rgba(13, 135, 121, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-sm);
}

.factory-flow article {
  min-height: 132px;
  padding: 18px;
  border: 1px solid rgba(13, 135, 121, 0.22);
  border-radius: 15px;
  background: white;
}

.factory-flow article span,
.stack-number {
  color: var(--teal);
  font-size: 0.72rem;
  font-weight: 900;
}

.factory-flow h3 {
  margin: 28px 0 4px;
  color: var(--navy);
  font-size: 0.95rem;
}

.factory-flow p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
}

.factory-flow > i,
.loop-note i {
  color: var(--teal);
  font-style: normal;
  font-weight: 900;
}

.verifier-grid,
.frontier-grid,
.transform-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 24px;
}

.verifier-card,
.frontier-card,
.transform-card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
}

.verifier-card h3,
.frontier-card h3,
.transform-card h3 {
  margin: 28px 0 8px;
  color: var(--navy);
  font-size: 1.2rem;
}

.verifier-card p,
.frontier-card p,
.transform-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.loop-note {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 24px;
  padding: 18px 24px;
  border: 1px dashed rgba(13, 135, 121, 0.35);
  border-radius: 16px;
  color: var(--navy);
  background: rgba(255, 255, 255, 0.6);
  font-size: 0.78rem;
  font-weight: 800;
}

.transform-grid {
  grid-template-columns: repeat(4, 1fr);
}

.transform-card span {
  color: var(--orange);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.transform-card h3 {
  margin-top: 34px;
  font-size: 1.08rem;
}

.signal-router {
  display: grid;
  gap: 8px;
  padding: 24px;
  border: 1px solid rgba(39, 135, 74, 0.18);
  border-radius: var(--radius);
  background: white;
  box-shadow: var(--shadow-sm);
}

.router-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.8fr) 40px minmax(220px, 1fr) minmax(180px, 0.8fr);
  align-items: center;
  min-height: 66px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.router-row > span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.router-row i {
  color: var(--green);
  font-style: normal;
  text-align: center;
}

.router-row strong {
  color: var(--green);
  font-size: 0.92rem;
}

.router-row small {
  color: var(--muted);
  text-align: right;
}

.orthogonal-notes {
  margin-top: 20px;
}

.note-card {
  background: rgba(255, 255, 255, 0.84);
}

.note-card p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.light-card {
  color: var(--ink);
  background: white;
}

.frontier-grid {
  grid-template-columns: repeat(5, 1fr);
}

.frontier-card {
  min-height: 240px;
  color: white;
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.07);
}

.frontier-card span {
  color: #86d3c9;
  font-size: 0.72rem;
  font-weight: 900;
}

.frontier-card h3 {
  margin-top: 38px;
  color: white;
  font-size: 1.05rem;
}

.frontier-card p {
  color: #c6d3e4;
  font-size: 0.78rem;
}

.paper-tools {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 30px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
}

.search-box > span {
  color: var(--teal);
  font-size: 1.2rem;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-size: 0.82rem;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-chips button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 99px;
  color: var(--muted);
  background: white;
  font-size: 0.7rem;
  font-weight: 800;
  cursor: pointer;
}

.filter-chips button:hover,
.filter-chips button:focus-visible,
.filter-chips button.active {
  color: white;
  border-color: var(--navy);
  background: var(--navy);
}

.paper-count {
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
  white-space: nowrap;
}

.paper-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.paper-card {
  display: flex;
  flex-direction: column;
  min-height: 300px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.paper-card:hover {
  transform: translateY(-3px);
  border-color: rgba(13, 135, 121, 0.34);
  box-shadow: var(--shadow-sm);
}

.paper-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 750;
}

.paper-group {
  color: var(--teal);
}

.paper-card h3 {
  margin: 28px 0 10px;
  color: var(--navy);
  font-size: 1rem;
  line-height: 1.28;
}

.paper-card > p {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.paper-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
  padding-top: 20px;
}

.paper-tags span {
  padding: 4px 8px;
  border-radius: 99px;
  color: #4e5e73;
  background: #edf2f7;
  font-size: 0.61rem;
  font-weight: 750;
}

.paper-link {
  display: inline-flex;
  align-items: center;
  margin-top: 16px;
  color: var(--teal);
  font-size: 0.72rem;
  font-weight: 850;
  text-decoration: none;
}

.paper-empty {
  padding: 60px 0;
  color: var(--muted);
  text-align: center;
}

.cite-layout {
  align-items: center;
}

.cite-layout .section-heading {
  margin: 0;
  text-align: left;
}

.cite-layout .section-heading > p:last-child {
  margin: 0;
}

.cite-layout .section-kicker {
  justify-content: flex-start;
}

.bibtex-card {
  overflow: hidden;
  border-radius: 20px;
  color: #dce7f7;
  background: var(--navy);
  box-shadow: var(--shadow-lg);
}

.bibtex-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  color: #a9bad0;
  font-size: 0.72rem;
  font-weight: 800;
}

.bibtex-top button {
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  color: white;
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.66rem;
  font-weight: 800;
  cursor: pointer;
}

.bibtex-card pre {
  margin: 0;
  padding: 24px;
  overflow-x: auto;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.72rem;
  line-height: 1.65;
  white-space: pre-wrap;
}

.copy-status {
  min-height: 22px;
  margin: 0;
  padding: 0 24px 10px;
  color: #91dccf;
  font-size: 0.68rem;
}

.site-footer {
  padding: 54px 0;
  color: #aebdd1;
  background: #0a172b;
}

.footer-layout {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: start;
}

.footer-brand {
  color: white;
}

.footer-layout p {
  max-width: 520px;
  margin: 14px 0 0;
  font-size: 0.78rem;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  color: #d2deed;
  font-size: 0.72rem;
  font-weight: 750;
  text-decoration: none;
}

.footer-meta {
  grid-column: 1 / -1;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.lightbox {
  width: min(96vw, 1500px);
  max-height: 94vh;
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 18px;
  background: white;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.45);
}

.lightbox::backdrop {
  background: rgba(5, 13, 26, 0.84);
  backdrop-filter: blur(6px);
}

.lightbox img {
  width: 100%;
}

.lightbox-close {
  position: sticky;
  z-index: 2;
  top: 12px;
  float: right;
  width: 42px;
  height: 42px;
  margin: 12px 12px -54px 0;
  border: 0;
  border-radius: 50%;
  color: white;
  background: rgba(16, 34, 63, 0.88);
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.js .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

:focus-visible {
  outline: 3px solid rgba(35, 103, 201, 0.5);
  outline-offset: 3px;
}

@media (max-width: 1080px) {
  .hero-layout {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    max-width: 760px;
    text-align: center;
    margin-inline: auto;
  }

  .eyebrow,
  .hero-actions {
    justify-content: center;
  }

  .hero-thesis,
  .metric-strip {
    margin-inline: auto;
  }

  .hero-card {
    max-width: 900px;
    margin-inline: auto;
    transform: none;
  }

  .lens-grid,
  .transform-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .benchmark-ladder {
    grid-template-columns: repeat(3, 1fr);
    align-items: stretch;
  }

  .benchmark-ladder article:nth-child(n) {
    transform: none;
  }

  .factory-flow {
    grid-template-columns: repeat(5, 1fr);
  }

  .factory-flow > i {
    display: none;
  }

  .frontier-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .paper-tools {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .js .menu-button {
    display: block;
  }

  .js .nav-links {
    position: fixed;
    top: 72px;
    right: 16px;
    left: 16px;
    display: grid;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    border: 0 solid var(--line);
    border-radius: 18px;
    background: rgba(251, 250, 245, 0.98);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    visibility: hidden;
    transition: max-height 220ms ease, opacity 180ms ease, transform 180ms ease, border-width 180ms ease;
  }

  .js .nav-links.open {
    max-height: 620px;
    border-width: 1px;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    visibility: visible;
  }

  .js .nav-links a {
    padding: 14px 20px;
    border-bottom: 1px solid var(--line);
  }

  .js .nav-links a:last-child {
    border-bottom: 0;
  }

  .js .nav-links a::after {
    display: none;
  }

  html:not(.js) .nav-shell {
    flex-wrap: wrap;
    padding: 10px 0 14px;
  }

  html:not(.js) .site-header {
    position: relative;
    border-bottom-color: var(--line);
    background: var(--paper);
  }

  html:not(.js) .nav-links {
    justify-content: center;
    width: 100%;
    flex-wrap: wrap;
    gap: 4px 18px;
  }

  html:not(.js) .nav-links a {
    padding: 4px 0;
  }

  html:not(.js) .hero {
    padding-top: 60px;
  }

  .hero {
    min-height: auto;
  }

  .section {
    padding: 90px 0;
  }

  .category-errors {
    grid-template-columns: repeat(2, 1fr);
  }

  .verifier-grid,
  .paper-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .router-row {
    grid-template-columns: 1fr auto 1fr;
  }

  .router-row small {
    grid-column: 3;
    text-align: left;
  }

  .cite-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  :root {
    --shell: min(100% - 28px, 1180px);
    --radius: 18px;
  }

  .hero {
    padding-top: 106px;
  }

  .hero h1 {
    font-size: clamp(3rem, 15vw, 4.8rem);
  }

  .metric-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .metric-strip div:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
    padding-bottom: 14px;
  }

  .hero-card figcaption,
  .feature-figure figcaption {
    display: block;
  }

  .figure-actions {
    margin-top: 12px;
  }

  .lens-grid,
  .category-errors,
  .two-column,
  .orthogonal-notes,
  .verifier-grid,
  .transform-grid,
  .frontier-grid,
  .paper-grid,
  .benchmark-ladder {
    grid-template-columns: 1fr;
  }

  .factory-flow {
    grid-template-columns: 1fr;
  }

  .factory-flow article {
    min-height: 110px;
  }

  .audit-callout {
    grid-template-columns: auto 1fr;
  }

  .audit-callout > a {
    grid-column: 2;
  }

  .router-row {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .router-row i {
    display: none;
  }

  .router-row small {
    grid-column: auto;
  }

  .footer-layout {
    grid-template-columns: 1fr;
  }

  .footer-links {
    flex-wrap: wrap;
  }

  .footer-meta {
    grid-column: auto;
  }
}

@media (hover: none), (pointer: coarse) {
  .cursor-comet {
    display: none;
  }
}

@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;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }

  .cursor-comet {
    display: none;
  }
}
