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

:root {
  --navy: #0a1628;
  --navy-mid: #0f2040;
  --blue: #1e6bff;
  --blue-light: #e8f0ff;
  --amber: #f59e0b;
  --orange: #ea580c;
  --red: #dc2626;
  --red-dark: #991b1b;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-400: #94a3b8;
  --gray-500: #64748b;
  --gray-700: #334155;
  --gray-900: #0f172a;
  --white: #ffffff;
  --font-ui: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

html { font-family: var(--font-ui); font-size: 16px; }
body { background: var(--gray-100); color: var(--gray-900); min-height: 100vh; }

/* ── Screens ── */
.screen { display: none; min-height: 100vh; flex-direction: column; }
.screen.active { display: flex; }
.screen-dark { background: var(--navy); color: var(--white); }

/* ── Nav ── */
.nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 2rem; background: var(--navy); color: var(--white);
  position: sticky; top: 0; z-index: 10;
}
.nav-light { background: var(--white); border-bottom: 1px solid var(--gray-200); color: var(--gray-900); }
.nav-logo { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em; }
.nav-logo-ai {
  display: inline-block; background: var(--blue); color: var(--white);
  font-size: 0.65rem; font-weight: 700; padding: 0.1rem 0.35rem;
  border-radius: 3px; margin-left: 4px; vertical-align: middle; letter-spacing: 0.05em;
}
.nav-tagline { font-size: 0.8rem; color: var(--gray-400); font-style: italic; }
.nav-tag { font-size: 0.8rem; font-weight: 600; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.08em; }

/* ── Buttons ── */
.btn-primary {
  background: var(--blue); color: var(--white); border: none;
  padding: 0.85rem 2rem; border-radius: 8px; font-size: 1rem; font-weight: 700;
  cursor: pointer; transition: transform 0.15s, box-shadow 0.15s;
  font-family: var(--font-ui);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(30,107,255,0.35); }
.btn-primary:active { transform: translateY(0); }
.btn-xl { padding: 1.1rem 2.8rem; font-size: 1.15rem; }
.btn-secondary {
  background: transparent; color: var(--white); border: 1px solid rgba(255,255,255,0.3);
  padding: 0.85rem 2rem; border-radius: 8px; font-size: 1rem; font-weight: 600;
  cursor: pointer; transition: background 0.15s, border-color 0.15s; font-family: var(--font-ui);
}
.btn-secondary:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.5); }

/* ── Landing ── */
.landing-hero {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; text-align: center; padding: 4rem 2rem;
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-mid) 60%, #0d1f3c 100%);
  color: var(--white);
}
.hero-badge {
  font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em;
  color: var(--blue); background: rgba(30,107,255,0.12); border: 1px solid rgba(30,107,255,0.3);
  padding: 0.4rem 1rem; border-radius: 100px; margin-bottom: 2rem;
}
.hero-title {
  font-size: clamp(2.5rem, 7vw, 5rem); font-weight: 900; line-height: 1.05;
  letter-spacing: -0.03em; margin-bottom: 1.5rem;
}
.hero-title em { font-style: italic; color: var(--blue); }
.hero-sub {
  font-size: clamp(1rem, 2vw, 1.2rem); color: #94a3b8; max-width: 600px;
  line-height: 1.7; margin-bottom: 2.5rem;
}
.hero-stats {
  display: flex; align-items: center; gap: 2rem; margin-bottom: 2.5rem;
  flex-wrap: wrap; justify-content: center;
}
.stat { display: flex; flex-direction: column; align-items: center; gap: 0.2rem; }
.stat-num { font-size: 2rem; font-weight: 800; color: var(--white); }
.stat-label { font-size: 0.75rem; color: var(--gray-400); text-transform: uppercase; letter-spacing: 0.06em; }
.stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.12); }
.hero-disclaimer { font-size: 0.72rem; color: #4a5568; margin-top: 1.5rem; max-width: 480px; line-height: 1.5; }

.landing-logos {
  background: var(--white); padding: 1rem 2rem; display: flex;
  align-items: center; justify-content: center; gap: 2rem; flex-wrap: wrap;
  border-top: 1px solid var(--gray-200);
}
.landing-logos span:first-child { font-size: 0.75rem; color: var(--gray-400); }
.logo-fake { font-weight: 700; font-size: 0.85rem; color: var(--gray-400); letter-spacing: -0.01em; }

/* ── Quiz ── */
.quiz-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; padding: 2rem 1rem 5rem; }
.quiz-progress-label { font-size: 0.85rem; font-weight: 600; color: var(--gray-500); }
.progress-bar-track { width: 100%; max-width: 640px; height: 4px; background: var(--gray-200); border-radius: 4px; margin-bottom: 2.5rem; }
.progress-bar-fill { height: 100%; background: var(--blue); border-radius: 4px; transition: width 0.4s ease; width: 0%; }
.quiz-card {
  background: var(--white); border-radius: 16px; padding: 2.5rem;
  width: 100%; max-width: 640px; box-shadow: 0 4px 24px rgba(0,0,0,0.07);
}
.quiz-category { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.12em; color: var(--blue); font-weight: 600; margin-bottom: 1rem; }
.quiz-question { font-size: clamp(1.2rem, 3vw, 1.6rem); font-weight: 700; line-height: 1.3; margin-bottom: 2rem; color: var(--gray-900); }
.quiz-options { display: flex; flex-direction: column; gap: 0.75rem; }
.quiz-option {
  border: 2px solid var(--gray-200); border-radius: 10px; padding: 1rem 1.25rem;
  cursor: pointer; font-size: 0.95rem; font-weight: 500; color: var(--gray-700);
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
  text-align: left; background: var(--white); font-family: var(--font-ui); width: 100%;
}
.quiz-option:hover { border-color: var(--blue); background: var(--blue-light); color: var(--blue); transform: translateX(4px); }

/* ── Between spinner ── */
.between-wrap, .analysis-wrap, .confirm-wrap {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 3rem 2rem; text-align: center;
}
.spinner-ring {
  width: 56px; height: 56px; border: 4px solid rgba(255,255,255,0.12);
  border-top-color: var(--blue); border-radius: 50%;
  animation: spin 0.8s linear infinite; margin-bottom: 1.5rem;
}
.spinner-lg { width: 72px; height: 72px; border-width: 5px; }
@keyframes spin { to { transform: rotate(360deg); } }
.between-label {
  font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.14em;
  color: var(--blue); margin-bottom: 0.75rem; font-weight: 600;
}
.between-sub { font-family: var(--font-mono); font-size: 0.85rem; color: var(--gray-400); }

/* ── Final analysis ── */
.analysis-header { display: flex; flex-direction: column; align-items: center; margin-bottom: 2.5rem; }
.analysis-title { font-size: 1.5rem; font-weight: 700; }
.analysis-steps { width: 100%; max-width: 480px; margin-bottom: 2rem; min-height: 180px; }
.analysis-step {
  font-family: var(--font-mono); font-size: 0.82rem; color: var(--gray-400);
  padding: 0.5rem 0; border-bottom: 1px solid rgba(255,255,255,0.05);
  display: flex; align-items: center; gap: 0.75rem; opacity: 0;
  animation: fadeIn 0.4s ease forwards;
}
.analysis-step.done { color: #4ade80; }
.analysis-step-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gray-400); flex-shrink: 0; }
.analysis-step.done .analysis-step-dot { background: #4ade80; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
.analysis-bar-track { width: 100%; max-width: 480px; height: 6px; background: rgba(255,255,255,0.1); border-radius: 6px; }
.analysis-bar-fill { height: 100%; background: var(--blue); border-radius: 6px; transition: width 0.6s ease; width: 0%; }
.analysis-pct { font-family: var(--font-mono); font-size: 0.85rem; color: var(--gray-400); margin-top: 0.75rem; }

/* ── Score ── */
.score-wrap {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 3rem 2rem 8rem; text-align: center;
}
.score-eyebrow { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.14em; color: var(--gray-400); margin-bottom: 2rem; }
.gauge-wrap { position: relative; width: 220px; height: 220px; margin-bottom: 1.5rem; }
.gauge-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.gauge-track { fill: none; stroke: var(--gray-200); stroke-width: 14; }
.gauge-fill {
  fill: none; stroke: var(--blue); stroke-width: 14;
  stroke-linecap: round; stroke-dasharray: 502; stroke-dashoffset: 502;
  transition: stroke-dashoffset 1.5s cubic-bezier(0.34, 1.56, 0.64, 1), stroke 0.5s ease;
}
.gauge-center {
  position: absolute; inset: 0; display: flex; align-items: center;
  justify-content: center; flex-direction: column;
}
.gauge-number { font-size: 3.5rem; font-weight: 900; line-height: 1; color: var(--gray-900); }
.gauge-outof { font-size: 0.9rem; color: var(--gray-400); font-weight: 600; }

.tier-badge {
  display: inline-block; padding: 0.5rem 1.5rem; border-radius: 100px;
  font-weight: 800; font-size: 1rem; letter-spacing: 0.04em; margin-bottom: 1rem;
}
.tier-basic    { background: #dbeafe; color: #1d4ed8; }
.tier-standard { background: #fef3c7; color: #92400e; }
.tier-premium  { background: #ffedd5; color: #9a3412; }
.tier-god      { background: var(--red); color: var(--white); animation: pulse-red 1.5s ease-in-out infinite; }
@keyframes pulse-red { 0%, 100% { box-shadow: 0 0 0 0 rgba(220,38,38,0.4); } 50% { box-shadow: 0 0 0 12px rgba(220,38,38,0); } }

.tier-desc { max-width: 480px; color: var(--gray-500); font-size: 1rem; line-height: 1.6; margin-bottom: 2rem; }
.risk-factors { background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 12px; padding: 1.5rem; width: 100%; max-width: 480px; margin-bottom: 2rem; text-align: left; }
.risk-title { font-size: 0.8rem; font-weight: 700; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 1rem; }
.risk-list { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.risk-list li { font-size: 0.92rem; color: var(--gray-700); display: flex; align-items: flex-start; gap: 0.5rem; line-height: 1.5; }
.risk-list li::before { content: "⚠"; font-size: 0.8rem; color: var(--amber); flex-shrink: 0; margin-top: 0.1rem; }

/* ── Plans ── */
.plans-wrap { flex: 1; padding: 2.5rem 2rem 7rem; max-width: 1100px; margin: 0 auto; width: 100%; }
.plans-eyebrow { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.14em; color: var(--gray-400); margin-bottom: 0.75rem; }
.plans-title { font-size: 1.75rem; font-weight: 800; margin-bottom: 0.75rem; }
.plans-sub { color: var(--gray-500); font-size: 0.95rem; line-height: 1.6; margin-bottom: 2.5rem; max-width: 560px; }
.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.25rem; }

.plan-card {
  border: 2px solid var(--gray-200); border-radius: 14px; padding: 1.75rem;
  background: var(--white); cursor: pointer; position: relative; overflow: hidden;
  transition: border-color 0.2s, transform 0.15s, box-shadow 0.2s;
}
.plan-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,0.1); }
.plan-card.selected { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(30,107,255,0.12); }
.plan-card.god-tier { border-color: var(--red); }
.plan-card.god-tier.selected { box-shadow: 0 0 0 4px rgba(220,38,38,0.15); animation: pulse-border 1.5s ease-in-out infinite; }
@keyframes pulse-border { 0%, 100% { box-shadow: 0 0 0 4px rgba(220,38,38,0.15); } 50% { box-shadow: 0 0 0 8px rgba(220,38,38,0.05); } }

.plan-badge {
  position: absolute; top: 0; right: 0; background: var(--blue); color: var(--white);
  font-size: 0.65rem; font-weight: 700; padding: 0.3rem 0.75rem; letter-spacing: 0.06em;
  border-bottom-left-radius: 8px; text-transform: uppercase;
}
.plan-badge.god-badge { background: var(--red); }
.plan-name { font-size: 1.1rem; font-weight: 800; margin-bottom: 0.25rem; }
.plan-tagline { font-size: 0.8rem; color: var(--gray-400); margin-bottom: 1.25rem; font-style: italic; }
.plan-price { font-size: 2rem; font-weight: 900; letter-spacing: -0.03em; margin-bottom: 0.25rem; }
.plan-period { font-size: 0.8rem; color: var(--gray-400); margin-bottom: 1.5rem; }
.plan-features { list-style: none; display: flex; flex-direction: column; gap: 0.5rem; }
.plan-features li { font-size: 0.82rem; color: var(--gray-600, #475569); display: flex; gap: 0.5rem; line-height: 1.4; }
.plan-features li::before { content: "✓"; color: #22c55e; font-weight: 700; flex-shrink: 0; }
.god-tier .plan-name { color: var(--red); }
.god-tier .plan-price { color: var(--red-dark); }

/* ── Sticky bar ── */
.sticky-bar {
  position: fixed; bottom: 0; left: 0; right: 0; background: var(--navy);
  padding: 1rem 2rem; display: flex; align-items: center; justify-content: space-between;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.2); z-index: 20;
}
.sticky-info { display: flex; flex-direction: column; }
.sticky-plan-name { font-weight: 700; color: var(--white); font-size: 1rem; }
.sticky-price { font-size: 0.85rem; color: var(--gray-400); }
.btn-enroll {
  background: var(--blue); color: var(--white); border: none; padding: 0.85rem 2rem;
  border-radius: 8px; font-size: 0.95rem; font-weight: 700; cursor: pointer;
  transition: background 0.15s, transform 0.1s; font-family: var(--font-ui); white-space: nowrap;
}
.btn-enroll:hover { background: #1a5ce0; transform: translateY(-1px); }
.btn-enroll.urgent { background: var(--red); animation: pulse-btn 1.5s ease-in-out infinite; }
.btn-enroll.urgent:hover { background: var(--red-dark); }
@keyframes pulse-btn { 0%, 100% { box-shadow: 0 0 0 0 rgba(220,38,38,0.5); } 50% { box-shadow: 0 0 0 10px rgba(220,38,38,0); } }

/* ── Confirm ── */
.confirm-wrap { max-width: 520px; width: 100%; margin: 0 auto; }
.confirm-steps { margin-top: 2rem; text-align: left; width: 100%; max-width: 380px; }
.confirm-check {
  width: 72px; height: 72px; border-radius: 50%; background: #22c55e;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem; color: var(--white); margin: 0 auto 1.5rem; font-weight: 700;
  animation: popIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes popIn { from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.confirm-title { font-size: 2rem; font-weight: 800; margin-bottom: 0.5rem; }
.confirm-policy-label { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.14em; color: var(--gray-400); margin-top: 1.5rem; margin-bottom: 0.4rem; }
.confirm-policy-num { font-family: var(--font-mono); font-size: 1.4rem; font-weight: 600; color: var(--blue); letter-spacing: 0.08em; margin-bottom: 1.5rem; }
.confirm-summary {
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 1.25rem; width: 100%; text-align: left; margin-bottom: 1.5rem;
}
.confirm-summary p { font-size: 0.88rem; color: var(--gray-400); line-height: 1.7; }
.confirm-summary strong { color: var(--white); }
.confirm-fine-print { font-size: 0.72rem; color: var(--gray-500); max-width: 380px; line-height: 1.6; margin-bottom: 2rem; font-style: italic; }

@media (max-width: 600px) {
  .hero-stats { gap: 1rem; }
  .stat-divider { display: none; }
  .quiz-card { padding: 1.75rem 1.25rem; }
  .plans-grid { grid-template-columns: 1fr; }
}
