:root {
  --sky-top: #6fa8f0;
  --sky-bottom: #ffd9c2;
  --bg: #fef8f1;
  --bg-elevated: #ffffff;
  --border: #f0dfce;
  --text: #3a2e28;
  --text-muted: #8a7b70;

  --red: #ef4b3a;
  --orange: #ff9d3d;
  --gold: #ffc23c;
  --green: #7cb342;
  --blue: #3f8fd6;
  --purple: #9b59c9;

  --positive: #2e9b5f;
  --negative: #e0435a;
  --radius: 18px;
  /* Fredoka: rounded and cartoonish, closest Google font to the puffy
     lettering in the Lead Index logo, while staying readable. */
  --font-display: "Fredoka", "Nunito", sans-serif;
  --font-body: "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Smooth cross-page transitions in browsers that support the View Transitions API. */
@view-transition {
  navigation: auto;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, .brand span, .btn, .stat-value, .winner-symbol {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1, .winner-symbol, .brand span {
  font-weight: 700;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Desktop gets more room to breathe - 1000px is cramped on a wide screen. */
@media (min-width: 1200px) {
  .container { max-width: 1180px; padding: 0 32px; }
  .section { padding: 76px 0; }
  h2 { font-size: 2rem; }
  .docs-layout { grid-template-columns: 220px 1fr; gap: 64px; }
}

a { color: var(--blue); }
a.link-accent { color: var(--orange); font-weight: 700; }

.hero-3d {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* Decorative floating triangles, scoped to the home hero */
.tri-field {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.tri {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0.1;
  border-style: solid;
}

.tri--red { border-width: 0 20px 34px 20px; border-color: transparent transparent var(--red) transparent; top: 10%; left: 3%; }
.tri--blue { border-width: 0 15px 26px 15px; border-color: transparent transparent var(--blue) transparent; top: 68%; right: 4%; }
.tri--gold { border-width: 0 13px 22px 13px; border-color: transparent transparent var(--gold) transparent; bottom: 8%; left: 10%; }
.tri--green { border-width: 0 16px 28px 16px; border-color: transparent transparent var(--green) transparent; top: 12%; right: 8%; }

@keyframes floatA { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-18px) rotate(8deg); } }
@keyframes floatB { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(14px) rotate(-6deg); } }
@keyframes floatC { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-10px) rotate(5deg); } }

.float-a { animation: floatA 7s ease-in-out infinite; }
.float-b { animation: floatB 9s ease-in-out infinite; }
.float-c { animation: floatC 8s ease-in-out infinite; }

/* Nav */
.topnav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.topnav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.1rem;
}

.brand__mark {
  width: 32px;
  height: 32px;
  object-fit: cover;
  border-radius: 9px;
}

.topnav__links { display: flex; gap: 20px; flex-wrap: wrap; justify-content: flex-end; }
.topnav__links a { color: var(--text-muted); text-decoration: none; font-weight: 700; font-size: 0.92rem; white-space: nowrap; }
.topnav__links a:hover { color: var(--orange); }
.topnav__links a.is-active { color: var(--red); }

/* Pons button. Until the token exists this reads "Soon on Pons" and points at
   Pons itself; one constant in app.js flips it to the real token page. */
.btn-pons {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: 20px;
  padding: 9px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--orange), #ff7a2f);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(255, 122, 47, 0.32);
  transition: transform 0.25s var(--ease-smooth), box-shadow 0.25s var(--ease-smooth);
}

.btn-pons:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(255, 122, 47, 0.42);
}

.btn-pons__arrow { transition: transform 0.25s var(--ease-smooth); }
.btn-pons:hover .btn-pons__arrow { transform: translateX(3px); }

@media (max-width: 640px) {
  .topnav__inner { flex-wrap: wrap; gap: 10px; }
  .topnav__links { gap: 14px; width: 100%; order: 3; justify-content: center; }
  .btn-pons { margin-left: auto; padding: 8px 15px; font-size: 0.85rem; }
}

/* Home hero */
.hero {
  position: relative;
  background: linear-gradient(180deg, var(--sky-top), var(--sky-bottom));
  overflow: hidden;
  padding: 56px 0 64px;
  min-height: 88vh;
  display: flex;
  align-items: center;
}

.hero__grid {
  position: relative;
  z-index: 1;
  width: 100%;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: center;
}

/* Copy on the left, the rendered token occupying the right of the canvas. */
.hero__grid--split {
  /* Second column is left empty on purpose: that's where the rendered
     token sits in the canvas behind. */
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  text-align: left;
}

.hero__grid--split .hero__copy { max-width: 30rem; }

/* Below the split breakpoint the token drops behind/below the copy, so the
   text goes back to centred. */
@media (max-width: 800px) {
  .hero__grid--split { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
  .hero__grid--split .hero__copy { max-width: 34rem; }
  .hero__grid--split .hero__cta { justify-content: center; }
  .hero__grid--split .tagline { margin-left: auto; margin-right: auto; }
  .hero { min-height: 96vh; }
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
  font-weight: 700;
  color: #5a4a3d;
  margin: 0 0 14px;
}

.hero__copy h1 {
  font-size: clamp(2.1rem, 4.6vw, 3.8rem);
  line-height: 1.12;
  margin: 0 0 20px;
  color: #2c2119;
}

@media (min-width: 1200px) {
  .hero__grid--split .hero__copy { max-width: 36rem; }
  .tagline { font-size: 1.25rem; }
}

.tagline {
  font-size: 1.15rem;
  color: #3f332b;
  margin: 0 0 28px;
  max-width: 46ch;
}

.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; }

.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  font-size: 1rem;
  transition: transform 0.3s var(--ease-smooth), box-shadow 0.3s var(--ease-smooth);
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); transition-duration: 0.1s; }

.btn--primary {
  background: var(--red);
  color: #fff;
  box-shadow: 0 6px 0 #b8321f;
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  border: 2px solid rgba(0,0,0,0.08);
}

@media (max-width: 760px) {
  .hero__grid { grid-template-columns: 1fr; }
}

/* Page hero (Live Data / FAQ) */
.page-hero {
  position: relative;
  padding: 48px 0 40px;
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.page-hero h1 { margin: 0 0 10px; font-size: 2.2rem; }
.page-hero > .container { position: relative; z-index: 1; }

.chart-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.4;
  z-index: 0;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 25%, #000 75%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 25%, #000 75%, transparent 100%);
}

.page-hero--live {
  background: linear-gradient(180deg, #fff8ee, var(--bg));
}

/* Treasury hero: same rendered-sky treatment as the home hero, so the site
   reads as one piece rather than a bright site with one dark page in it. */
.page-hero--treasury {
  background: linear-gradient(180deg, var(--sky-top), var(--sky-bottom));
  min-height: 66vh;
  display: flex;
  align-items: center;
  border-bottom: none;
  padding: 64px 0;
}

.treasury-3d {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* width:100% matters: the hero is a flex row, so once the copy inside got a
   max-width the container shrank to fit and centred itself. */
.page-hero--treasury > .container { position: relative; z-index: 1; width: 100%; }

.page-hero--treasury h1 {
  color: #2c2119;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
}

/* Orange on blue sky is barely legible; matches the home hero eyebrow. */
.page-hero--treasury .section-eyebrow { color: #5a4a3d; }

.page-hero--treasury .disclaimer {
  color: #4b3c30;
}

/* The rendered chips occupy the right of the canvas, so the copy is capped
   to a left-hand column and never runs underneath them. */
.page-hero--treasury .page-hero__copy { max-width: 27rem; }

@media (min-width: 1200px) {
  .page-hero--treasury .page-hero__copy { max-width: 32rem; }
}

@media (max-width: 720px) {
  .page-hero--treasury .page-hero__copy { max-width: none; }
}

.page-hero--faq {
  background-image: linear-gradient(180deg, rgba(254, 248, 241, 0.8), rgba(254, 248, 241, 0.97)), url("img/bg-triangles.jpg");
  background-size: cover;
  background-position: center 20%;
}

/* Sections */
.section { position: relative; z-index: 1; padding: 56px 0; }


.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--orange);
  margin: 0 0 6px;
}

h2 { font-size: 1.8rem; margin: 0 0 28px; }
h3 { margin: 0 0 8px; font-size: 1.15rem; }

/* Phase cards */
.phase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 18px;
}

.phase-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  border-top: 6px solid var(--border);
  box-shadow: 0 8px 20px rgba(58, 46, 40, 0.05);
}

.phase-card--red { border-top-color: var(--red); }
.phase-card--gold { border-top-color: var(--gold); }
.phase-card--green { border-top-color: var(--green); }
.phase-card--purple { border-top-color: var(--purple); }

.phase-num {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text-muted);
  opacity: 0.35;
}

.phase-card p { color: var(--text-muted); font-size: 0.94rem; margin: 0; }

.phase-badge {
  display: inline-block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  background: #f1e9de;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.phase-badge--live { background: #dff3e6; color: var(--positive); }
.phase-badge--ready { background: #e6f0fb; color: var(--blue); }

/* CTA band */
.section--cta { padding-top: 0; }

.cta-band {
  display: flex;
  align-items: center;
  gap: 24px;
  background: linear-gradient(135deg, #fff2df, #ffe4d1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
  flex-wrap: wrap;
}

.cta-band__mark { width: 56px; height: 56px; object-fit: cover; border-radius: 14px; flex-shrink: 0; }
.cta-band h2 { margin: 0 0 6px; font-size: 1.3rem; }
.cta-band p { margin: 0; color: var(--text-muted); }
.cta-band > div { flex: 1; min-width: 200px; }

.disclaimer {
  color: #5a4a3d;
  font-size: 0.95rem;
  margin: 0;
}

/* Loading state */
.loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 60px 0;
  color: var(--text-muted);
}

.loading-orbit {
  position: relative;
  width: 56px;
  height: 56px;
  animation: orbitSpin 2.4s linear infinite;
}

.loading-tri {
  position: absolute;
  top: 0;
  left: 50%;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 7px 12px 7px;
  border-color: transparent transparent currentColor transparent;
  margin-left: -7px;
  transform-origin: 7px 28px;
  animation: orbitPulse 2.4s var(--ease-smooth) infinite;
}

.loading-tri--red { color: var(--red); transform: rotate(0deg); animation-delay: 0s; }
.loading-tri--gold { color: var(--gold); transform: rotate(120deg); animation-delay: -0.8s; }
.loading-tri--green { color: var(--green); transform: rotate(240deg); animation-delay: -1.6s; }

@keyframes orbitSpin {
  to { transform: rotate(360deg); }
}

@keyframes orbitPulse {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 1; }
}

.loading-state p {
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

/* Dashboard entrance */
.pop-in {
  animation: popIn 0.6s var(--ease-smooth) both;
  animation-delay: var(--delay, 0s);
}

@keyframes popIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stat-label { color: var(--text-muted); font-size: 0.85rem; }
.stat-value { font-size: 1.5rem; font-weight: 700; }

.winner-card {
  position: relative;
  background: linear-gradient(145deg, #fff, #fdeee0);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 24px;
  box-shadow: 0 10px 24px rgba(239, 75, 58, 0.1);
}

.winner-label {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
}

.winner-body { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.winner-symbol { font-size: 2.1rem; font-weight: 700; }
.winner-change { font-size: 1.4rem; font-weight: 700; }
.winner-change.positive { color: var(--positive); }
.winner-change.negative { color: var(--negative); }
.winner-meta { color: var(--text-muted); font-size: 0.85rem; margin: 12px 0 0; word-break: break-all; }

.winner-stats {
  display: flex;
  gap: 20px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.winner-stats span {
  background: rgba(255,255,255,0.7);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text);
}

/* Live pill: a pulsing dot and a relative timestamp that keeps ticking, so the
   page reads as something running rather than something published once. */
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 14px;
  padding: 6px 15px 6px 12px;
  border-radius: 999px;
  background: rgba(46, 155, 95, 0.1);
  border: 1px solid rgba(46, 155, 95, 0.28);
  color: #23784a;
  font-size: 0.82rem;
  font-weight: 700;
}

.live-pill__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--positive);
  box-shadow: 0 0 0 0 rgba(46, 155, 95, 0.55);
  animation: livePulse 2.2s ease-out infinite;
}

@keyframes livePulse {
  0% { box-shadow: 0 0 0 0 rgba(46, 155, 95, 0.55); }
  70% { box-shadow: 0 0 0 9px rgba(46, 155, 95, 0); }
  100% { box-shadow: 0 0 0 0 rgba(46, 155, 95, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .live-pill__dot { animation: none; }
}

.winner-links { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }

.pill-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
  transition: transform 0.2s var(--ease-smooth), filter 0.2s var(--ease-smooth);
}

.pill-link:hover { transform: translateY(-2px); filter: brightness(1.06); }
button.pill-link { border: 0; cursor: pointer; font-family: inherit; }
button.pill-link.is-copied { background: var(--positive); }

.winner-hint { margin: 12px 0 0; font-size: 0.82rem; color: var(--text-muted); }

.pill-link--ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

/* Records: three figures that only get more interesting the longer the
   tracker has been running. */
.records-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-bottom: 26px;
}

.record-card {
  position: relative;
  overflow: hidden;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* A coloured edge per record, picked from the brand palette. */
.record-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
}

.record-card--best::before { background: var(--red); }
.record-card--crown::before { background: var(--gold); }
.record-card--typical::before { background: var(--blue); }

.record-card__label {
  color: var(--text-muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
}

.record-card__value {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.1;
}

.record-card__meta { color: var(--text-muted); font-size: 0.82rem; }

/* History table: a proportional bar behind each change, so twenty rows read as
   a comparison rather than twenty similar numbers. */
.cell-change { position: relative; font-weight: 700; }

.cell-change__bar {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  height: 22px;
  border-radius: 6px;
  background: currentColor;
  opacity: 0.13;
  animation: barGrow 0.7s var(--ease-smooth) both;
}

@keyframes barGrow {
  from { transform: translateY(-50%) scaleX(0); }
  to { transform: translateY(-50%) scaleX(1); }
}

.cell-change__bar { transform-origin: left center; }
.cell-change__label { position: relative; }

a.coin-link { color: var(--text); text-decoration: none; font-weight: 700; border-bottom: 2px solid var(--border); }
a.coin-link:hover { color: var(--orange); border-bottom-color: var(--orange); }

.excluded-note {
  font-size: 0.88rem;
  color: var(--text-muted);
  background: #fff8ee;
  border: 1px dashed var(--gold);
  border-radius: 12px;
  padding: 10px 16px;
  margin: 0 0 24px;
}

.chart-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}

.chart-card__canvas {
  position: relative;
  height: 300px;
  margin-top: 16px;
}

@media (min-width: 900px) {
  .chart-card { padding: 28px 32px; }
  .chart-card__canvas { height: 360px; }
}

.history-title { font-size: 1.1rem; }

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  margin-bottom: 20px;
}

table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
th, td { text-align: left; padding: 12px 16px; white-space: nowrap; }
thead th { color: var(--text-muted); font-weight: 700; border-bottom: 1px solid var(--border); }
tbody tr { animation: rowIn 0.5s var(--ease-smooth) both; }
tbody tr:not(:last-child) td { border-bottom: 1px solid var(--border); }
.muted { color: var(--text-muted); }
.positive { color: var(--positive); }
.negative { color: var(--negative); }

@keyframes rowIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.empty-state {
  text-align: center;
  max-width: 520px;
  margin: 40px auto;
  color: var(--text-muted);
}

.empty-state__title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--text);
  margin-bottom: 10px;
}

.wallet-address {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0 0 32px;
}

.wallet-address code {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 0.82rem;
}

.methodology {
  font-size: 0.82rem;
  color: var(--text-muted);
  border-left: 3px solid var(--border);
  padding-left: 14px;
}

/* Docs */
.docs-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 48px;
  align-items: start;
}

.docs-nav {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-left: 2px solid var(--border);
  /* Enough entries now that the list can outgrow a short window; let it
     scroll on its own rather than clipping the last sections. */
  max-height: calc(100vh - 104px);
  overflow-y: auto;
}

.docs-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 7px 0 7px 16px;
  border-left: 2px solid transparent;
  margin-left: -2px;
  transition: color 0.25s var(--ease-smooth), border-color 0.25s var(--ease-smooth);
}

.docs-nav a:hover { color: var(--text); }
.docs-nav a.is-active { color: var(--red); border-left-color: var(--red); }

.docs-content { min-width: 0; }

.docs-section {
  padding-bottom: 52px;
  margin-bottom: 52px;
  border-bottom: 1px solid var(--border);
  scroll-margin-top: 80px;
}

.docs-section:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.docs-section h2 { margin-bottom: 16px; }
.docs-section p { color: var(--text-muted); line-height: 1.7; margin: 0 0 16px; }
.docs-section code {
  background: #f1e9de;
  border-radius: 6px;
  padding: 2px 6px;
  font-size: 0.85em;
}

.docs-steps, .docs-list {
  color: var(--text-muted);
  line-height: 1.7;
  padding-left: 22px;
  margin: 0 0 16px;
}

.docs-steps li, .docs-list li { margin-bottom: 10px; }
.docs-steps strong, .docs-list strong { color: var(--text); }

@media (max-width: 760px) {
  .docs-layout { grid-template-columns: 1fr; }
  .docs-nav {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    border-left: none;
    border-bottom: 1px solid var(--border);
    padding-bottom: 16px;
    gap: 4px 16px;
  }
  .docs-nav { max-height: none; overflow-y: visible; }
  .docs-nav a { border-left: none; padding: 4px 0; margin-left: 0; }
  .docs-nav a.is-active { border-left: none; text-decoration: underline; }
}

/* FAQ / Docs accordion */
.faq-list { display: flex; flex-direction: column; gap: 12px; }

.faq-item {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 22px;
}

.faq-item__trigger {
  all: unset;
  cursor: pointer;
  font-weight: 700;
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
}

.faq-item__icon {
  position: relative;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.faq-item__icon::before,
.faq-item__icon::after {
  content: "";
  position: absolute;
  background: var(--orange);
  border-radius: 2px;
  transition: transform 0.35s var(--ease-smooth);
}

.faq-item__icon::before { top: 7px; left: 0; width: 16px; height: 2px; }
.faq-item__icon::after { top: 0; left: 7px; width: 2px; height: 16px; }

.faq-item.is-open .faq-item__icon::after { transform: rotate(90deg); }
.faq-item.is-open .faq-item__icon::before { transform: rotate(180deg); }

.faq-item__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.45s var(--ease-smooth);
}

.faq-item.is-open .faq-item__panel { grid-template-rows: 1fr; }

.faq-item__panel-inner { overflow: hidden; }

.faq-item p {
  color: var(--text-muted);
  margin: 0 0 20px;
  font-size: 0.95rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 28px 0 56px;
  color: var(--text-muted);
  font-size: 0.85rem;
  position: relative;
  z-index: 1;
}

.footer__inner { display: flex; align-items: center; gap: 12px; }
.footer__mark { width: 26px; height: 26px; object-fit: cover; border-radius: 7px; }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(22px) scale(0.97);
  transition: opacity 0.7s var(--ease-smooth), transform 0.7s var(--ease-smooth);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* When GSAP is driving the animation, let it own opacity/transform outright
   instead of fighting a CSS transition on the same properties. */
.gsap-active .reveal {
  transition: none;
}

/* Hero headline word-mask reveal (see assets/animations.js) */
.word-mask {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
}

.word-mask .word {
  display: inline-block;
  will-change: transform;
}

/* Scroll progress bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--red), var(--orange), var(--gold));
  transform: scaleX(0);
  transform-origin: left;
  z-index: 100;
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .tri, .loading-tri, .pop-in, tbody tr { animation: none !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
