:root {
  --ink: #15151a;
  --ink-soft: #3a3a44;
  --muted: #6b6b76;
  --line: #e7e8ee;
  --band: #f5f6f9;
  --white: #ffffff;
  --brand-50: #eef1ff;
  --brand-100: #e0e5ff;
  --brand-300: #a3b1ff;
  --brand-500: #6d7cff;
  --brand-600: #5560f0;
  --brand-700: #454ccf;
  --coral: #ff8a7a;
  --coral-50: #fff1ee;
  --mint: #43b89d;
  --mint-50: #eaf7f3;
  --shadow-soft: 0 1px 2px rgba(16, 18, 40, .04), 0 8px 24px rgba(16, 18, 40, .06);
  --shadow-lift: 0 12px 40px rgba(16, 18, 40, .10);
  --radius: 18px;
  --radius-lg: 26px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::selection {
  color: var(--ink);
  background: var(--brand-100);
}

a {
  color: inherit;
}

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

button,
.button {
  font: inherit;
}

.shell {
  width: min(1140px, calc(100% - 40px));
  margin-inline: auto;
}

/* Header */

.site-header {
  position: fixed;
  z-index: 50;
  inset: 0 0 auto;
  height: 68px;
  border-bottom: 1px solid transparent;
  transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.site-header.scrolled {
  background: rgba(255, 255, 255, .9);
  border-color: var(--line);
  box-shadow: 0 4px 20px rgba(16, 18, 40, .04);
  backdrop-filter: blur(12px);
}

.nav {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.brand span {
  font-family: "Anton", "Inter", sans-serif;
  font-size: 24px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 26px;
}

.nav-links a {
  position: relative;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: color .15s ease;
}

.nav-links a::after {
  position: absolute;
  content: "";
  left: 0;
  right: 100%;
  bottom: -8px;
  height: 2px;
  background: var(--brand-500);
  transition: right .2s ease;
}

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

.nav-links a.active::after {
  right: 0;
}

.nav-cta {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
}

/* Hero */

.hero {
  position: relative;
  padding-top: 132px;
  padding-bottom: 72px;
  text-align: center;
}

.hero-glow {
  position: absolute;
  z-index: -1;
  top: 18px;
  left: 50%;
  width: min(900px, 90vw);
  height: 520px;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at 30% 30%, rgba(109, 124, 255, .14), transparent 42%),
    radial-gradient(circle at 72% 35%, rgba(255, 138, 122, .11), transparent 38%),
    radial-gradient(circle at 50% 75%, rgba(67, 184, 157, .08), transparent 40%);
  filter: blur(10px);
  pointer-events: none;
}

.hero-copy {
  width: min(900px, 100%);
  margin-inline: auto;
}

.venue-pill,
.eyebrow {
  color: var(--brand-600);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.venue-pill {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--brand-50);
}

.hero h1 {
  margin: 24px 0 12px;
  font-family: "Anton", Impact, sans-serif;
  font-size: clamp(80px, 15vw, 156px);
  font-weight: 400;
  letter-spacing: -.025em;
  line-height: .95;
}

.hero-subtitle {
  max-width: 830px;
  margin: 28px auto 0;
  color: var(--ink-soft);
  font-size: clamp(21px, 3.2vw, 31px);
  font-weight: 650;
  line-height: 1.32;
}

.acronym u {
  text-decoration-color: var(--brand-300);
  text-decoration-thickness: 3px;
  text-underline-offset: 3px;
}

.hero-lede {
  max-width: 680px;
  margin: 20px auto 0;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 48px;
  padding: 11px 19px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.button:hover {
  transform: translateY(-2px);
  border-color: var(--brand-300);
  box-shadow: var(--shadow-lift);
}

.button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.button-dark {
  border-color: var(--ink);
  color: var(--white);
  background: var(--ink);
}

.button-light {
  color: var(--ink);
  background: rgba(255, 255, 255, .92);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 64px;
}

.stat {
  min-width: 0;
  padding: 22px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  text-align: center;
  box-shadow: var(--shadow-soft);
}

.stat strong {
  display: block;
  color: var(--ink);
  font-size: clamp(26px, 3.2vw, 40px);
  letter-spacing: -.04em;
  line-height: 1.1;
}

.stat span {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
  text-transform: uppercase;
}

/* Sections */

.section {
  padding-top: 92px;
  padding-bottom: 92px;
  scroll-margin-top: 68px;
}

.band {
  width: 100%;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--band);
}

.section-heading {
  width: min(820px, 100%);
  margin-bottom: 42px;
}

.section-heading h2,
.toolbox-copy h2 {
  margin: 8px 0 14px;
  color: var(--ink);
  font-size: clamp(32px, 4.4vw, 52px);
  letter-spacing: -.035em;
  line-height: 1.1;
}

.section-heading > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

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

.feature-card,
.problem-card {
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.feature-index,
.problem-kicker {
  color: var(--brand-600);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.feature-card h3,
.problem-card h3,
.dataset-card h3,
.cite-card h3 {
  margin: 14px 0 10px;
  color: var(--ink);
  font-size: 21px;
  letter-spacing: -.02em;
  line-height: 1.25;
}

.feature-card p,
.problem-card p {
  margin: 0;
  color: var(--muted);
}

/* Why */

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

.problem-card {
  border-top: 3px solid var(--coral);
}

.problem-kicker {
  color: #d9604f;
}

.mission {
  margin: 42px 0;
  padding: 38px 42px;
  border-radius: var(--radius-lg);
  color: var(--white);
  background:
    radial-gradient(circle at 12% 20%, rgba(109, 124, 255, .45), transparent 45%),
    radial-gradient(circle at 88% 80%, rgba(255, 138, 122, .28), transparent 42%),
    var(--ink);
  box-shadow: var(--shadow-lift);
}

.mission .eyebrow {
  margin: 0;
  color: var(--brand-300);
}

.mission-statement {
  max-width: 900px;
  margin: 12px 0 0;
  font-size: clamp(22px, 2.8vw, 31px);
  font-weight: 650;
  letter-spacing: -.02em;
  line-height: 1.35;
}

.mission-statement strong {
  color: #cdd5ff;
}

/* Datasets */

.dataset-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.dataset-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--white);
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.dataset-card:hover {
  transform: translateY(-3px);
  border-color: var(--brand-100);
  box-shadow: var(--shadow-lift);
}

.dataset-head {
  display: flex;
  align-items: center;
  gap: 18px;
}

.dataset-logo {
  width: 76px;
  height: 76px;
  flex: none;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--white);
  object-fit: contain;
}

.dataset-venue {
  margin: 0;
  color: var(--brand-600);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.dataset-head h3 {
  margin: 2px 0 0;
  font-family: "Anton", "Inter", sans-serif;
  font-size: 36px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.1;
}

.dataset-kind {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.dataset-copy {
  margin: 22px 0 0;
  color: var(--ink-soft);
}

.dataset-stats {
  display: grid;
  gap: 8px;
  margin-top: 22px;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--band);
  color: var(--muted);
  font-size: 14px;
}

.dataset-stats strong {
  color: var(--ink);
  font-weight: 750;
}

.dataset-formats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.dataset-formats span {
  padding: 4px 10px;
  border: 1px solid var(--brand-100);
  border-radius: 999px;
  color: var(--brand-700);
  background: var(--brand-50);
  font-size: 12px;
  font-weight: 700;
}

.dataset-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
  padding-top: 26px;
}

.dataset-actions .button {
  min-height: 42px;
  padding: 8px 16px;
  font-size: 14px;
}

.hf-menu {
  position: relative;
}

.hf-menu summary {
  list-style: none;
}

.hf-menu summary::-webkit-details-marker {
  display: none;
}

.hf-menu summary::after {
  content: "▾";
  font-size: 11px;
}

.hf-menu-list {
  position: absolute;
  z-index: 10;
  bottom: calc(100% + 8px);
  left: 0;
  min-width: 190px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  box-shadow: var(--shadow-lift);
}

.hf-menu-list a {
  display: block;
  padding: 8px 12px;
  border-radius: 9px;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.hf-menu-list a:hover {
  color: var(--brand-700);
  background: var(--brand-50);
}

/* Toolbox */

.toolbox-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  align-items: center;
  gap: 48px;
}

.toolbox-lede {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.toolbox-list {
  display: grid;
  gap: 16px;
  margin: 28px 0 30px;
  padding: 0;
  list-style: none;
}

.toolbox-list li {
  padding-left: 18px;
  border-left: 3px solid var(--brand-300);
}

.toolbox-list strong {
  display: block;
  color: var(--ink);
}

.toolbox-list span {
  color: var(--muted);
  font-size: 15px;
}

.code-card {
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #17181f;
  box-shadow: var(--shadow-lift);
}

.code-card-head {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.code-card-head .dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #3a3c48;
}

.code-title {
  margin-left: 8px;
  color: #8d90a3;
  font-size: 12px;
  font-weight: 600;
}

.code-card pre {
  margin: 0;
  padding: 22px 24px 26px;
  overflow-x: auto;
  color: #e6e7ef;
  font: 13.5px/1.7 "SFMono-Regular", Menlo, Consolas, monospace;
}

.code-card .c {
  color: #7d8199;
}

.code-card .k {
  color: var(--brand-300);
}

.code-card .s {
  color: #ffb3a7;
}

/* Stack */

.stack-flow {
  display: grid;
  grid-template-columns: 1fr auto 1.15fr auto 1.25fr auto 1fr auto 1fr;
  align-items: center;
  gap: 12px;
}

.stack-node {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.stack-node strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.3;
}

.stack-node small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.45;
}

.stack-step {
  display: block;
  margin-bottom: 6px;
  color: var(--brand-600);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.stack-node.core {
  border-color: var(--brand-100);
  background: var(--brand-50);
}

.stack-node.tools {
  border-color: #cdeee5;
  background: var(--mint-50);
}

.stack-node.tools .stack-step {
  color: #2f8f78;
}

.stack-node.community {
  border-style: dashed;
  border-color: var(--coral);
  background: var(--coral-50);
}

.stack-node.community .stack-step {
  color: #d9604f;
}

.stack-branches {
  display: grid;
  gap: 12px;
}

.stack-node.branch {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.stack-node.branch img {
  width: 40px;
  height: 40px;
  flex: none;
  object-fit: contain;
}

.stack-arrow {
  width: 22px;
  height: 2px;
  position: relative;
  background: var(--brand-300);
}

.stack-arrow::after {
  position: absolute;
  content: "";
  top: -4px;
  right: -1px;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 7px solid var(--brand-300);
}

/* Citation */

.cite-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.cite-card {
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-soft);
}

.cite-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.cite-head h3 {
  margin: 0;
}

.copy-button {
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
  background: var(--white);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.copy-button:hover {
  border-color: var(--brand-300);
  color: var(--brand-700);
}

.cite-card pre {
  margin: 16px 0 0;
  padding: 16px 18px;
  overflow-x: auto;
  border-radius: 12px;
  color: var(--ink-soft);
  background: var(--band);
  font: 12.5px/1.6 "SFMono-Regular", Menlo, Consolas, monospace;
  white-space: pre-wrap;
  word-break: break-word;
}

.cite-placeholder {
  margin: 16px 0 0;
  color: var(--muted);
}

/* Footer and utilities */

.footer {
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: var(--white);
  font-size: 13px;
}

.footer-inner {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer a {
  color: var(--ink-soft);
}

.to-top {
  position: fixed;
  z-index: 40;
  right: 24px;
  bottom: 24px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  color: var(--white);
  background: var(--ink);
  box-shadow: var(--shadow-lift);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity .2s ease, transform .2s ease;
}

.to-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}

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

@media (max-width: 1040px) {
  .stack-flow {
    grid-template-columns: 1fr;
    justify-items: stretch;
  }

  .stack-arrow {
    width: 2px;
    height: 22px;
    justify-self: center;
  }

  .stack-arrow::after {
    top: auto;
    right: -4px;
    bottom: -1px;
    border-top: 7px solid var(--brand-300);
    border-right: 5px solid transparent;
    border-bottom: 0;
    border-left: 5px solid transparent;
  }

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

@media (max-width: 960px) {
  .nav-links {
    display: none;
  }

  .feature-grid,
  .problem-grid,
  .dataset-grid,
  .cite-grid,
  .toolbox-layout {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 720px) {
  .shell {
    width: min(100% - 28px, 1140px);
  }

  .brand-mark {
    display: none;
  }

  .hero {
    padding-top: 112px;
  }

  .section {
    padding-top: 68px;
    padding-bottom: 68px;
  }

  .mission {
    padding: 28px 24px;
  }

  .dataset-card {
    padding: 24px;
  }

  .stack-branches {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    justify-content: center;
    padding-top: 24px;
    padding-bottom: 24px;
  }
}

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

  *,
  *::before,
  *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }

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

.card-link {
  color: inherit;
  text-decoration: none;
}

.card-link::after {
  position: absolute;
  inset: 0;
  content: "";
  border-radius: inherit;
}

.dataset-card:hover .card-link {
  color: var(--brand-700);
}

.card-link:focus-visible {
  outline: none;
}

.dataset-card:has(.card-link:focus-visible) {
  outline: 3px solid var(--brand-300);
  outline-offset: 3px;
}
