/* ==========================================================================
   edgenote — Professional Python Package Website
   https://edgenote.github.io
   ========================================================================== */

/* ── Design Tokens ─────────────────────────────────────────────────────── */
:root {
  --bg-0:   #05070d;
  --bg-1:   #0a0d14;
  --bg-2:   #0f1219;
  --bg-3:   #141821;
  --bg-card: rgba(10, 13, 20, 0.80);

  --border-0: rgba(255,255,255,0.05);
  --border-1: rgba(255,255,255,0.10);
  --border-2: rgba(255,255,255,0.18);

  --cyan:    #38bdf8;
  --cyan-dk: #0ea5e9;
  --emerald: #10b981;
  --red:     #ef4444;
  --amber:   #f59e0b;
  --purple:  #a78bfa;

  --cyan-glow: rgba(56,189,248,0.14);
  --cyan-glow-strong: rgba(56,189,248,0.28);

  --text-0:  #f0f6fc;
  --text-1:  #94a3b8;
  --text-2:  #64748b;

  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', 'Fira Code', ui-monospace, monospace;

  --r-xs: 4px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-pill: 9999px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --t-fast: 0.15s var(--ease-in-out);
  --t-base: 0.25s var(--ease-in-out);
  --t-slow: 0.5s var(--ease-out);
}

/* ── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-family: var(--sans);
  background: var(--bg-0);
  color: var(--text-0);
  scroll-behavior: smooth;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  color-scheme: dark;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  position: relative;
}

img, svg { display: block; }
a { color: inherit; }
button { font-family: inherit; }
ul { list-style: none; }
code { font-family: var(--mono); }

/* Screen-reader only */
.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;
}

/* ── Background ─────────────────────────────────────────────────────────── */
.bg-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, black 0%, transparent 100%);
}

.bg-glow {
  position: fixed; top: -200px; left: 50%; z-index: 0; pointer-events: none;
  transform: translateX(-50%);
  width: 1000px; height: 600px;
  background: radial-gradient(circle, rgba(56,189,248,0.10) 0%, rgba(59,130,246,0.04) 50%, transparent 70%);
  filter: blur(100px);
  animation: bgPulse 10s ease-in-out infinite alternate;
}

@keyframes bgPulse {
  0%   { opacity: 0.6; transform: translateX(-50%) scale(0.93); }
  100% { opacity: 1;   transform: translateX(-50%) scale(1.08); }
}

/* ── Container ──────────────────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

/* ── Typography helpers ─────────────────────────────────────────────────── */
.gradient-text {
  background: linear-gradient(135deg, #e2e8f0 30%, var(--cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-label {
  display: inline-block;
  font-size: 0.775rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan);
  margin-bottom: 0.85rem;
}

.section-title {
  font-size: clamp(1.75rem, 3.5vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.18;
  margin-bottom: 1.1rem;
}

.section-sub {
  font-size: 1.05rem;
  color: var(--text-1);
  max-width: 720px;
  line-height: 1.7;
}

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 0.45rem;
  background: var(--cyan);
  color: #070b10;
  font-size: 0.875rem; font-weight: 700;
  padding: 0.55rem 1.2rem;
  border-radius: var(--r-sm);
  text-decoration: none;
  border: none; cursor: pointer;
  transition: all var(--t-fast);
  white-space: nowrap;
}
.btn-primary:hover { background: #5ec8fa; box-shadow: 0 0 20px var(--cyan-glow-strong); }
.btn-primary.btn-lg { padding: 0.7rem 1.6rem; font-size: 0.95rem; }

.btn-outline {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: transparent;
  color: var(--text-1);
  font-size: 0.875rem; font-weight: 600;
  padding: 0.55rem 1.2rem;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-1);
  text-decoration: none; cursor: pointer;
  transition: all var(--t-fast);
}
.btn-outline:hover { color: var(--text-0); border-color: var(--border-2); background: rgba(255,255,255,0.05); }

.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  background: transparent;
  color: var(--text-1);
  border: 1px solid var(--border-0);
  border-radius: var(--r-sm);
  text-decoration: none;
  transition: all var(--t-fast);
}
.btn-ghost:hover { color: var(--text-0); border-color: var(--border-1); background: rgba(255,255,255,0.05); }

/* Install bar */
.install-bar {
  display: inline-flex; align-items: center; gap: 1rem;
  background: var(--bg-2);
  border: 1px solid var(--border-1);
  border-radius: var(--r-md);
  padding: 0.45rem 0.45rem 0.45rem 1.15rem;
  font-family: var(--mono);
  font-size: 0.9rem;
  transition: all var(--t-fast);
}
.install-bar:hover { border-color: rgba(56,189,248,0.4); box-shadow: 0 0 20px var(--cyan-glow); }
.install-bar--dark {
  background: rgba(0,0,0,0.35);
  border-color: rgba(255,255,255,0.12);
}

.install-prefix { color: var(--text-2); user-select: none; }

.copy-btn {
  display: inline-flex; align-items: center; gap: 0.35rem;
  background: var(--bg-3);
  color: var(--text-1);
  border: 1px solid var(--border-0);
  padding: 0.4rem 0.75rem;
  border-radius: var(--r-xs);
  font-size: 0.78rem; font-family: var(--sans); font-weight: 500;
  cursor: pointer;
  transition: all var(--t-fast);
}
.copy-btn:hover { color: var(--text-0); background: rgba(255,255,255,0.08); }
.copy-btn.copied { color: var(--emerald); border-color: rgba(16,185,129,0.35); }
.copy-btn--dark { background: rgba(255,255,255,0.06); }

/* ── Navbar ─────────────────────────────────────────────────────────────── */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(5,7,13,0.88);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  border-bottom: 1px solid var(--border-0);
}

.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 66px; gap: 1.5rem;
}

.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand-logo {
  height: 44px; width: auto; max-width: 160px; object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(56,189,248,0.22));
  transition: filter var(--t-base), transform var(--t-base);
}
.brand:hover .brand-logo {
  filter: drop-shadow(0 0 18px rgba(56,189,248,0.55));
  transform: translateY(-1px);
}

.nav-links {
  display: flex; align-items: center; gap: 0.25rem;
}
.nav-links a {
  display: block; padding: 0.4rem 0.75rem;
  font-size: 0.9rem; font-weight: 500;
  color: var(--text-1); text-decoration: none;
  border-radius: var(--r-xs);
  transition: color var(--t-fast), background var(--t-fast);
}
.nav-links a:hover { color: var(--text-0); background: rgba(255,255,255,0.05); }

.nav-cta { display: flex; align-items: center; gap: 0.6rem; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero {
  padding: 6rem 0 5rem;
  text-align: center;
}

.hero-badge {
  display: inline-flex; align-items: center; gap: 0.55rem;
  padding: 0.3rem 0.9rem;
  background: rgba(56,189,248,0.07);
  border: 1px solid rgba(56,189,248,0.22);
  border-radius: var(--r-pill);
  color: var(--cyan);
  font-size: 0.8rem; font-family: var(--mono); font-weight: 500;
  margin-bottom: 2rem;
  animation: fadeUp 0.7s var(--ease-out) backwards;
}

.badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 8px var(--cyan);
  flex-shrink: 0;
  animation: pulseDot 2s ease infinite;
}

@keyframes pulseDot {
  0%, 100% { box-shadow: 0 0 8px var(--cyan); }
  50%       { box-shadow: 0 0 16px var(--cyan), 0 0 24px rgba(56,189,248,0.4); }
}

.hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 4rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 1.4rem;
  max-width: 900px;
  margin-left: auto; margin-right: auto;
  animation: fadeUp 0.75s var(--ease-out) 0.08s backwards;
}

.hero-sub {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--text-1);
  max-width: 680px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
  animation: fadeUp 0.8s var(--ease-out) 0.16s backwards;
}

.hero-actions {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 0.85rem;
  margin-bottom: 3.5rem;
  animation: fadeUp 0.85s var(--ease-out) 0.24s backwards;
}

.hero-stats {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 0;
  padding: 1.4rem 2.5rem;
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  max-width: fit-content;
  margin: 0 auto;
  animation: fadeUp 0.9s var(--ease-out) 0.32s backwards;
}

.stat { text-align: center; padding: 0 2.25rem; }
.stat-value {
  display: block;
  font-size: 1.65rem; font-weight: 800; letter-spacing: -0.03em;
  color: var(--cyan);
}
.stat-label { font-size: 0.78rem; color: var(--text-2); margin-top: 0.2rem; white-space: nowrap; }
.stat-divider {
  width: 1px; height: 38px;
  background: var(--border-0);
  flex-shrink: 0;
}

/* ── Section Commons ────────────────────────────────────────────────────── */
.section {
  padding: 6rem 0;
  border-top: 1px solid var(--border-0);
}

.section-alt { background: linear-gradient(to bottom, var(--bg-1), var(--bg-0)); }

/* ── Problem Section ────────────────────────────────────────────────────── */
.problem-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 1.25rem;
  margin-top: 3rem;
}

.problem-card {
  background: var(--bg-card);
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  padding: 2rem;
  backdrop-filter: blur(8px);
  transition: border-color var(--t-base), box-shadow var(--t-base), transform var(--t-base);
}
.problem-card:hover {
  border-color: var(--border-1);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.35);
}

.problem-icon {
  width: 44px; height: 44px;
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem;
  transition: box-shadow var(--t-base);
}
.problem-icon--red {
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.2);
  color: var(--red);
}
.problem-icon--amber {
  background: rgba(245,158,11,0.1);
  border: 1px solid rgba(245,158,11,0.2);
  color: var(--amber);
}
.problem-card:hover .problem-icon { box-shadow: 0 0 14px rgba(239,68,68,0.25); }

.problem-card h3 {
  font-size: 1.1rem; font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 0.65rem;
}
.problem-card p { font-size: 0.935rem; color: var(--text-1); line-height: 1.7; }

/* Attention curve visual */
.attention-visual {
  margin-top: 4rem;
  padding: 2.5rem 2rem 2rem;
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  overflow: hidden;
}

.attn-curve-wrap { position: relative; margin-bottom: 1.25rem; }
.attn-curve-svg { width: 100%; height: 100px; display: block; }

.attn-labels {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: 0 1rem;
  margin-top: 0.75rem;
}
.attn-label {
  font-size: 0.72rem; font-family: var(--mono); text-align: center;
  line-height: 1.4;
}
.attn-label--good { color: var(--cyan); }
.attn-label--bad  { color: var(--red); font-weight: 700; }

.attn-caption {
  font-size: 0.8rem; color: var(--text-2); text-align: center;
  font-style: italic; margin-top: 0.5rem;
}

/* ── Solution / Mechanisms ──────────────────────────────────────────────── */
.mechanism-list {
  margin-top: 3.5rem;
  display: flex; flex-direction: column; gap: 1px;
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  overflow: hidden;
}

.mechanism {
  display: flex; gap: 2.5rem; align-items: flex-start;
  padding: 2.5rem;
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  transition: background var(--t-base);
  border-bottom: 1px solid var(--border-0);
}
.mechanism:last-child { border-bottom: none; }
.mechanism:hover { background: rgba(56,189,248,0.025); }

.mechanism-num {
  font-size: 2.4rem; font-weight: 900; font-family: var(--mono);
  color: var(--border-1);
  flex-shrink: 0; line-height: 1; min-width: 48px;
  transition: color var(--t-base);
}
.mechanism:hover .mechanism-num { color: rgba(56,189,248,0.35); }

.mechanism-content h3 {
  font-size: 1.2rem; font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 0.75rem; color: var(--text-0);
}
.mechanism-content p { font-size: 0.95rem; color: var(--text-1); line-height: 1.75; margin-bottom: 1rem; }

.mechanism-tag { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag {
  font-family: var(--mono); font-size: 0.73rem;
  padding: 0.22rem 0.65rem;
  background: rgba(56,189,248,0.08);
  border: 1px solid rgba(56,189,248,0.2);
  border-radius: var(--r-pill);
  color: var(--cyan);
}

/* ── Simulator ──────────────────────────────────────────────────────────── */
.simulator-card {
  background: var(--bg-1);
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0,0,0,0.55), 0 0 48px rgba(56,189,248,0.04);
  margin-top: 3rem;
}

.sim-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.5rem;
  background: var(--bg-2);
  border-bottom: 1px solid var(--border-0);
  flex-wrap: wrap; gap: 1rem;
}

.sim-title {
  display: flex; align-items: center; gap: 0.55rem;
  font-size: 0.85rem; font-weight: 600;
}

.sim-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
}

.mode-toggle {
  display: flex; gap: 0.2rem;
  background: rgba(0,0,0,0.35);
  padding: 0.2rem;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-0);
}

.mode-btn {
  background: transparent; border: none;
  color: var(--text-2);
  font-size: 0.78rem; font-weight: 600;
  padding: 0.35rem 0.85rem;
  border-radius: var(--r-xs);
  cursor: pointer;
  transition: all var(--t-fast);
}
.mode-btn.active {
  background: var(--bg-3);
  color: var(--text-0);
  border: 1px solid var(--border-0);
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.sim-body { padding: 1.75rem; }

.sim-graph {
  position: relative; height: 140px;
  background: #07090e;
  border-radius: var(--r-md);
  border: 1px solid rgba(255,255,255,0.04);
  overflow: hidden; margin-bottom: 1.5rem;
  display: flex; align-items: center; justify-content: center;
}

.sim-curve-svg { width: 100%; height: 100%; }

.sim-baseline { fill: none; stroke: rgba(255,255,255,0.08); stroke-width: 2; stroke-dasharray: 4 4; }
.sim-curve    { fill: none; stroke-width: 3.5; transition: stroke var(--t-slow); }

.sim-scan-beam {
  position: absolute; inset-y: 0; width: 130px; pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(56,189,248,0.13), transparent);
  animation: scanBeam 3.5s linear infinite;
}
@keyframes scanBeam {
  0%   { left: -15%; opacity: 0; }
  15%  { opacity: 1; }
  85%  { opacity: 1; }
  100% { left: 108%; opacity: 0; }
}

.sim-zone-label {
  position: absolute; top: 52%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--mono); font-size: 0.67rem;
  letter-spacing: 0.07em; text-transform: uppercase;
  pointer-events: none;
}

.zone-badge {
  display: inline-block; padding: 0.12rem 0.55rem;
  border-radius: var(--r-pill); font-size: 0.65rem;
  transition: all var(--t-base);
}
.zone-safe {
  background: rgba(16,185,129,0.12); color: var(--emerald);
  border: 1px solid rgba(16,185,129,0.28);
}
.zone-danger {
  background: rgba(239,68,68,0.12); color: var(--red);
  border: 1px solid rgba(239,68,68,0.28);
}

/* Prompt slots */
.slots-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.7rem;
  margin-bottom: 1.25rem;
}

.slot {
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-md);
  padding: 0.85rem 0.75rem;
  transition: all var(--t-slow);
  overflow: hidden;
}

.slot-zone {
  font-size: 0.67rem; font-family: var(--mono);
  color: var(--text-2); margin-bottom: 0.4rem;
}
.slot-payload {
  font-size: 0.8rem; font-weight: 500;
  color: var(--text-0); line-height: 1.35;
  min-height: 46px; display: flex; flex-direction: column; justify-content: center;
}
.slot-recall {
  font-family: var(--mono); font-size: 0.68rem;
  margin-top: 0.5rem;
}

.slot.state-pinned {
  border-color: rgba(56,189,248,0.4);
  background: rgba(56,189,248,0.07);
  box-shadow: 0 0 18px rgba(56,189,248,0.1);
}
.slot.state-pinned .slot-zone   { color: var(--cyan); }
.slot.state-pinned .slot-recall { color: var(--emerald); }

.slot.state-vulnerable {
  border-color: rgba(239,68,68,0.32);
  background: rgba(239,68,68,0.05);
}
.slot.state-vulnerable .slot-zone   { color: var(--red); }
.slot.state-vulnerable .slot-recall { color: var(--red); }

.slot.state-middle-safe {
  border-color: var(--border-0);
  opacity: 0.65;
}
.slot.state-middle-safe .slot-recall { color: var(--text-2); }

/* Diagnostic bar */
.sim-diagnostic {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.85rem 1.15rem;
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-0);
  border-radius: var(--r-md);
  font-size: 0.85rem; flex-wrap: wrap; gap: 0.65rem;
  transition: all var(--t-base);
}
.diag-text { display: flex; align-items: center; gap: 0.55rem; }
.diag-badge {
  font-family: var(--mono); font-size: 0.72rem;
  padding: 0.18rem 0.6rem;
  border-radius: var(--r-pill);
}
.diag-badge--danger {
  background: rgba(239,68,68,0.14); color: var(--red);
  border: 1px solid rgba(239,68,68,0.28);
}
.diag-badge--success {
  background: rgba(16,185,129,0.14); color: var(--emerald);
  border: 1px solid rgba(16,185,129,0.28);
}

/* ── Features ───────────────────────────────────────────────────────────── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.25rem;
  margin-top: 3rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  padding: 2rem;
  backdrop-filter: blur(8px);
  transition: border-color var(--t-base), transform var(--t-base), box-shadow var(--t-base);
}
.feature-card:hover {
  border-color: rgba(56,189,248,0.25);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.35), 0 0 24px rgba(56,189,248,0.06);
}

.feature-icon {
  width: 44px; height: 44px;
  background: rgba(56,189,248,0.09);
  border: 1px solid rgba(56,189,248,0.2);
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  color: var(--cyan);
  margin-bottom: 1.25rem;
  transition: box-shadow var(--t-base), background var(--t-base);
}
.feature-card:hover .feature-icon {
  background: rgba(56,189,248,0.15);
  box-shadow: 0 0 16px rgba(56,189,248,0.25);
}

.feature-card h3 {
  font-size: 1.05rem; font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 0.65rem;
}
.feature-card p {
  font-size: 0.92rem; color: var(--text-1); line-height: 1.7;
}
.feature-card code {
  font-size: 0.85em; color: var(--cyan);
  background: rgba(56,189,248,0.07);
  padding: 0.1em 0.4em; border-radius: 3px;
}

/* ── Benchmark ──────────────────────────────────────────────────────────── */
.bench-wrap {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 1.5rem;
  margin-top: 3rem;
  align-items: start;
}

.bench-card {
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.bench-table {
  width: 100%; border-collapse: collapse; font-size: 0.9rem; text-align: left;
}
.bench-table th {
  padding: 0.8rem 1.15rem;
  color: var(--text-2); font-size: 0.75rem; font-family: var(--mono);
  text-transform: uppercase; letter-spacing: 0.06em;
  border-bottom: 1px solid var(--border-0);
  background: var(--bg-3);
}
.bench-table td {
  padding: 1rem 1.15rem;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  color: var(--text-0);
}
.bench-table tr:last-child td { border-bottom: none; }
.bench-table tr:hover td { background: rgba(255,255,255,0.015); }

.status-pass {
  color: var(--emerald); font-weight: 600; font-size: 0.85rem;
}
.status-fail {
  color: var(--red); font-weight: 600; font-size: 0.85rem;
}

.overhead-tag {
  font-family: var(--mono); font-size: 0.78rem;
  color: var(--cyan);
  background: rgba(56,189,248,0.08);
  padding: 0.18rem 0.55rem;
  border-radius: var(--r-xs);
  border: 1px solid rgba(56,189,248,0.18);
}

.bench-summary {
  display: flex; flex-direction: column; gap: 1rem;
}

.bench-stat-block {
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  padding: 1.5rem;
}
.bench-stat-block--success { border-color: rgba(16,185,129,0.25); }

.bench-big {
  display: block;
  font-size: 2.4rem; font-weight: 900; letter-spacing: -0.04em;
  color: var(--red);
  line-height: 1; margin-bottom: 0.5rem;
}
.bench-stat-block--success .bench-big { color: var(--emerald); }

.bench-label { font-size: 0.85rem; color: var(--text-1); line-height: 1.5; }
.bench-label strong { color: var(--text-0); }

.bench-note {
  font-size: 0.8rem; color: var(--text-2); line-height: 1.6;
  padding: 1rem; background: var(--bg-3);
  border: 1px solid var(--border-0); border-radius: var(--r-md);
}
.bench-note a { color: var(--cyan); text-decoration: underline; text-underline-offset: 3px; }
.bench-note a:hover { color: #5ec8fa; }

/* ── Quickstart ─────────────────────────────────────────────────────────── */
.qs-steps {
  margin-top: 3.5rem;
  display: flex; flex-direction: column; gap: 2rem;
}

.qs-step {
  display: flex; gap: 2rem; align-items: flex-start;
}

.qs-step-num {
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(56,189,248,0.1);
  border: 1px solid rgba(56,189,248,0.25);
  color: var(--cyan); font-weight: 800; font-size: 0.9rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; margin-top: 0.25rem;
}

.qs-step-content { flex: 1; }
.qs-step-content h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 0.85rem; letter-spacing: -0.02em; }

.code-block {
  background: #07090d;
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  overflow: hidden;
}

.code-block-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.7rem 1.1rem;
  background: var(--bg-3);
  border-bottom: 1px solid var(--border-0);
}

.code-dots { display: flex; gap: 5px; }
.code-dots span { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.18); }

.code-lang {
  font-family: var(--mono); font-size: 0.75rem; color: var(--text-2);
  position: absolute; left: 50%; transform: translateX(-50%);
}
.code-block-header { position: relative; }

.code-copy-btn {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.73rem; font-family: var(--sans); font-weight: 500;
  background: rgba(255,255,255,0.06); color: var(--text-1);
  border: 1px solid var(--border-0);
  padding: 0.25rem 0.65rem; border-radius: var(--r-xs);
  cursor: pointer;
  transition: all var(--t-fast);
  position: relative; z-index: 1;
}
.code-copy-btn:hover { color: var(--text-0); background: rgba(255,255,255,0.1); }
.code-copy-btn.copied { color: var(--emerald); }

.code-pre {
  padding: 1.4rem 1.5rem;
  font-family: var(--mono); font-size: 0.875rem; line-height: 1.75;
  overflow-x: auto;
  color: #dde6f0;
}

/* Token colors */
.tk-kw  { color: #f472b6; }
.tk-str { color: #38bdf8; }
.tk-fn  { color: #a78bfa; }
.tk-cmt { color: #4e6075; font-style: italic; }
.tk-num { color: #fbbf24; }

/* ── Compatibility ──────────────────────────────────────────────────────── */
.compat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1rem;
  margin-top: 3rem;
}

.compat-card {
  background: var(--bg-2);
  border: 1px solid var(--border-0);
  border-radius: var(--r-lg);
  padding: 1.5rem 1rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.75rem;
  transition: all var(--t-base);
  cursor: default;
}
.compat-card:hover {
  border-color: rgba(56,189,248,0.25);
  background: rgba(56,189,248,0.04);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}

.compat-logo { color: var(--text-1); transition: color var(--t-base); }
.compat-card:hover .compat-logo { color: var(--cyan); }
.compat-name { font-size: 0.8rem; font-weight: 600; color: var(--text-1); text-align: center; }

/* ── FAQ ────────────────────────────────────────────────────────────────── */
.faq-list {
  margin-top: 3rem;
  display: flex; flex-direction: column;
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  overflow: hidden;
  max-width: 800px;
}

.faq-item {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-0);
}
.faq-item:last-child { border-bottom: none; }
.faq-item[open] { background: rgba(56,189,248,0.025); }

.faq-q {
  padding: 1.35rem 1.75rem;
  font-size: 0.975rem; font-weight: 600;
  cursor: pointer; list-style: none;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  transition: color var(--t-fast);
}
.faq-q::-webkit-details-marker { display: none; }
.faq-q::after {
  content: "+";
  font-size: 1.3rem; font-weight: 300;
  color: var(--text-2);
  flex-shrink: 0;
  transition: transform var(--t-base), color var(--t-base);
}
.faq-item[open] .faq-q::after { transform: rotate(45deg); color: var(--cyan); }
.faq-q:hover { color: var(--cyan); }

.faq-a {
  padding: 0 1.75rem 1.35rem;
  font-size: 0.925rem; color: var(--text-1); line-height: 1.75;
}
.faq-a code {
  font-size: 0.88em; color: var(--cyan);
  background: rgba(56,189,248,0.07);
  padding: 0.1em 0.4em; border-radius: 3px;
}

/* ── CTA Banner ─────────────────────────────────────────────────────────── */
.section-cta { padding: 5rem 0; }

.cta-card {
  background: linear-gradient(135deg, rgba(56,189,248,0.08) 0%, rgba(59,130,246,0.05) 50%, rgba(56,189,248,0.04) 100%);
  border: 1px solid rgba(56,189,248,0.22);
  border-radius: var(--r-xl);
  padding: 4rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-card::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(circle at 50% -20%, rgba(56,189,248,0.14) 0%, transparent 60%);
  pointer-events: none;
}

.cta-title {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 800; letter-spacing: -0.035em;
  margin-bottom: 0.9rem;
}
.cta-sub { font-size: 1.05rem; color: var(--text-1); margin-bottom: 2.25rem; }
.cta-actions {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 0.85rem;
}

/* ── Footer ─────────────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border-0);
  background: var(--bg-1);
  padding-top: 4rem;
  color: var(--text-1);
  font-size: 0.875rem;
  margin-top: auto;
}

.footer-inner {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 3rem; padding-bottom: 3rem;
  flex-wrap: wrap;
}

.footer-brand { display: flex; align-items: flex-start; gap: 0.85rem; }
.footer-icon { border-radius: var(--r-xs); object-fit: contain; flex-shrink: 0; margin-top: 2px; }
.footer-name { font-size: 0.95rem; font-weight: 700; color: var(--text-0); margin-bottom: 0.2rem; }
.footer-tagline { font-size: 0.8rem; color: var(--text-2); }

.footer-nav { display: flex; gap: 3rem; flex-wrap: wrap; }
.footer-col h4 { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-0); margin-bottom: 0.85rem; }
.footer-col ul { display: flex; flex-direction: column; gap: 0.5rem; }
.footer-col a { color: var(--text-2); text-decoration: none; font-size: 0.875rem; transition: color var(--t-fast); }
.footer-col a:hover { color: var(--text-0); }

.footer-bottom {
  border-top: 1px solid var(--border-0);
  padding: 1.5rem 0;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 0.5rem;
  font-size: 0.8rem; color: var(--text-2);
}
.footer-bottom a { color: var(--text-1); text-decoration: none; }
.footer-bottom a:hover { color: var(--text-0); }

/* ── Animations ─────────────────────────────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.active { opacity: 1; transform: translateY(0); }

/* ── Prompt Anatomy Comparison ──────────────────────────────────────────── */
.anatomy-compare {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: start;
  margin-top: 3.5rem;
}

/* Panel */
.anatomy-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-0);
  border-radius: var(--r-xl);
  overflow: hidden;
  backdrop-filter: blur(8px);
}
.anatomy-panel--bad  { border-color: rgba(239,68,68,0.2); }
.anatomy-panel--good { border-color: rgba(56,189,248,0.22); }

/* Panel header */
.anatomy-panel-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid var(--border-0);
  flex-wrap: wrap; gap: 0.5rem;
}
.anatomy-panel--bad  .anatomy-panel-header { background: rgba(239,68,68,0.05); }
.anatomy-panel--good .anatomy-panel-header { background: rgba(56,189,248,0.05); }

.anatomy-panel-status {
  display: flex; align-items: center; gap: 0.55rem;
  font-size: 0.85rem; font-weight: 700;
}

.anatomy-status-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}
.anatomy-status-dot--bad  {
  background: var(--red);
  box-shadow: 0 0 8px var(--red);
  animation: pulseBad 2.5s ease infinite;
}
.anatomy-status-dot--good {
  background: var(--emerald);
  box-shadow: 0 0 8px var(--emerald);
}

@keyframes pulseBad {
  0%, 100% { box-shadow: 0 0 6px var(--red); }
  50%       { box-shadow: 0 0 14px var(--red), 0 0 22px rgba(239,68,68,0.4); }
}

.anatomy-panel-label { color: var(--text-0); }

.anatomy-result-tag {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-size: 0.72rem; font-weight: 700; font-family: var(--mono);
  padding: 0.22rem 0.65rem;
  border-radius: var(--r-pill);
}
.anatomy-result-tag--bad  {
  color: var(--red);
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.25);
}
.anatomy-result-tag--good {
  color: var(--emerald);
  background: rgba(16,185,129,0.1);
  border: 1px solid rgba(16,185,129,0.25);
}

/* Slots list */
.anatomy-slots {
  padding: 1rem;
  display: flex; flex-direction: column; gap: 0.5rem;
}

/* Individual slot */
.anatomy-slot {
  border-radius: var(--r-md);
  border: 1px solid var(--border-0);
  overflow: hidden;
  transition: transform var(--t-base);
}

.anatomy-slot-pos {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.4rem 0.75rem 0.2rem;
}
.anatomy-pos-label {
  font-family: var(--mono); font-size: 0.67rem; font-weight: 600;
  color: var(--text-2);
}

.anatomy-attention {
  font-size: 0.65rem; font-family: var(--mono); font-weight: 600;
}
.anatomy-attention--high   { color: var(--cyan); }
.anatomy-attention--mid    { color: var(--amber); }
.anatomy-attention--dead   { color: var(--red); }
.anatomy-attention--pinned { color: var(--emerald); }
.anatomy-attention--valley { color: var(--text-2); }

.anatomy-slot-body {
  display: flex; align-items: center; gap: 0.55rem;
  padding: 0.3rem 0.75rem 0.65rem;
  font-size: 0.82rem; font-weight: 500; color: var(--text-0);
}

.anatomy-slot-icon {
  width: 24px; height: 24px; border-radius: var(--r-xs);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.anatomy-slot-icon--neutral  { background: rgba(255,255,255,0.05); color: var(--text-2); }
.anatomy-slot-icon--critical { background: rgba(239,68,68,0.12); color: var(--red); }
.anatomy-slot-icon--pinned   { background: rgba(16,185,129,0.12); color: var(--emerald); }
.anatomy-slot-icon--near     { background: rgba(56,189,248,0.10); color: var(--cyan); }
.anatomy-slot-icon--valley   { background: rgba(255,255,255,0.03); color: var(--text-2); }

/* Slot variants */
.anatomy-slot--neutral  { background: rgba(255,255,255,0.03); }
.anatomy-slot--fade     { opacity: 0.6; }
.anatomy-slot--critical {
  background: rgba(239,68,68,0.06);
  border-color: rgba(239,68,68,0.3);
  animation: flickerBad 3s ease-in-out infinite;
}
.anatomy-slot--pinned {
  background: rgba(56,189,248,0.07);
  border-color: rgba(56,189,248,0.35);
  box-shadow: 0 0 16px rgba(56,189,248,0.08);
}
.anatomy-slot--near {
  background: rgba(56,189,248,0.04);
  border-color: rgba(56,189,248,0.18);
}
.anatomy-slot--valley {
  background: rgba(255,255,255,0.02);
  border-color: var(--border-0);
  opacity: 0.65;
}

@keyframes flickerBad {
  0%, 100% { border-color: rgba(239,68,68,0.3); box-shadow: none; }
  50%       { border-color: rgba(239,68,68,0.55); box-shadow: 0 0 14px rgba(239,68,68,0.15); }
}

/* "LOST" overlay badge */
.anatomy-slot-lost {
  margin: 0 0.75rem 0.6rem;
  padding: 0.2rem 0.55rem;
  background: rgba(239,68,68,0.14);
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: var(--r-xs);
  font-family: var(--mono); font-size: 0.65rem; font-weight: 700;
  color: var(--red); letter-spacing: 0.04em;
}

/* "Fortified" badge */
.anatomy-slot-fortified {
  margin: 0 0.75rem 0.6rem;
  padding: 0.2rem 0.55rem;
  background: rgba(16,185,129,0.12);
  border: 1px solid rgba(16,185,129,0.28);
  border-radius: var(--r-xs);
  font-family: var(--mono); font-size: 0.65rem; font-weight: 700;
  color: var(--emerald); letter-spacing: 0.04em;
}

/* Outcome bar */
.anatomy-outcome {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem 1.25rem;
  border-top: 1px solid var(--border-0);
  font-size: 0.825rem; font-weight: 600;
}
.anatomy-outcome--bad  {
  background: rgba(239,68,68,0.08);
  color: #fca5a5;
}
.anatomy-outcome--good {
  background: rgba(16,185,129,0.08);
  color: #6ee7b7;
}

/* Center arrow */
.anatomy-arrow {
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  padding: 0 1.5rem;
  position: sticky; top: 50%;
  align-self: center;
}
.anatomy-arrow-wrap {
  width: 44px; height: 44px;
  background: var(--bg-3);
  border: 1px solid var(--border-1);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--cyan);
  box-shadow: 0 0 18px var(--cyan-glow);
}
.anatomy-arrow-label {
  font-family: var(--mono); font-size: 0.68rem; font-weight: 700;
  color: var(--cyan); white-space: nowrap;
}

/* Callout box */
.anatomy-callout {
  display: flex; align-items: center; gap: 2rem;
  margin-top: 2rem;
  padding: 1.75rem 2.25rem;
  background: linear-gradient(135deg, rgba(56,189,248,0.06) 0%, rgba(56,189,248,0.02) 100%);
  border: 1px solid rgba(56,189,248,0.18);
  border-radius: var(--r-xl);
}
.anatomy-callout-stat {
  display: flex; flex-direction: column; align-items: center; flex-shrink: 0;
}
.anatomy-callout-num {
  font-size: 3rem; font-weight: 900; letter-spacing: -0.05em;
  color: var(--cyan); line-height: 1;
  font-family: var(--mono);
}
.anatomy-callout-unit {
  font-size: 0.78rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.07em; color: var(--cyan); margin-top: 0.15rem;
}
.anatomy-callout-divider {
  width: 1px; height: 56px; background: rgba(56,189,248,0.2); flex-shrink: 0;
}
.anatomy-callout-text {
  font-size: 0.95rem; color: var(--text-1); line-height: 1.7;
}
.anatomy-callout-text em { color: var(--text-0); font-style: normal; font-weight: 600; }

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .bench-wrap { grid-template-columns: 1fr; }
  .bench-summary { flex-direction: row; }
  .bench-stat-block { flex: 1; }
}

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

  .anatomy-compare {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .anatomy-arrow {
    flex-direction: row;
    padding: 0;
    justify-content: center;
    transform: rotate(90deg);
  }
  .anatomy-callout {
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem;
    text-align: center;
  }
  .anatomy-callout-divider { width: 60px; height: 1px; }

  .hero { padding: 4.5rem 0 3.5rem; }
  .hero-stats { padding: 1.2rem 1.5rem; gap: 0; }
  .stat { padding: 0 1.25rem; }

  .slots-grid { grid-template-columns: 1fr; }
  .slot-payload { min-height: auto; }

  .mechanism { flex-direction: column; gap: 1rem; }
  .mechanism-num { font-size: 1.5rem; }

  .qs-step { flex-direction: column; gap: 0.75rem; }
  .qs-step-num { width: 32px; height: 32px; font-size: 0.8rem; }

  .cta-card { padding: 2.5rem 1.5rem; }

  .footer-inner { flex-direction: column; gap: 2rem; }
  .footer-nav { gap: 2rem; }
  .footer-bottom { flex-direction: column; text-align: center; }

  .bench-summary { flex-direction: column; }
  .section { padding: 4rem 0; }

  .attn-labels { flex-direction: column; align-items: center; gap: 0.5rem; }
}

@media (max-width: 480px) {
  .stat-divider { display: none; }
  .hero-stats { gap: 1rem; flex-direction: column; }
  .stat { padding: 0; }
  .compat-grid { grid-template-columns: repeat(3, 1fr); }
}
