:root {
  --bg: #06060f;
  --bg2: #0c0c1e;
  --bg3: #111128;
  --card: #13132d;
  --card2: #1a1a38;
  --border: rgba(255,255,255,0.07);
  --border2: rgba(124,58,237,0.35);

  --purple: #7c3aed;
  --purple-l: #a78bfa;
  --purple-d: #4c1d95;
  --cyan: #06b6d4;
  --cyan-l: #67e8f9;
  --green: #10b981;
  --green-l: #6ee7b7;
  --gold: #f59e0b;
  --gold-l: #fcd34d;
  --red: #ef4444;
  --orange: #f97316;

  --t1: #f1f5f9;
  --t2: #94a3b8;
  --t3: #475569;

  --grad: linear-gradient(135deg, #7c3aed 0%, #06b6d4 100%);
  --grad-gold: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  --grad-green: linear-gradient(135deg, #10b981 0%, #06b6d4 100%);

  --r: 12px;
  --r2: 20px;
  --shadow: 0 8px 32px rgba(0,0,0,0.5);
  --glow: 0 0 60px rgba(124,58,237,0.15);
}

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

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--t1);
  line-height: 1.6;
  overflow-x: hidden;
}

/* NAV */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 40px;
  height: 64px;
  background: rgba(6,6,15,0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav-logo {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none;
  font-size: 1.3rem; font-weight: 800; letter-spacing: -0.5px;
}
.nav-logo .logo-icon {
  width: 34px; height: 34px;
  background: var(--grad);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.nav-logo span { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { color: var(--t2); text-decoration: none; font-size: 0.9rem; transition: color 0.2s; }
.nav-links a:hover { color: var(--t1); }
.nav-actions { display: flex; gap: 12px; align-items: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 22px; border-radius: var(--r); font-size: 0.9rem; font-weight: 600; cursor: pointer; border: none; transition: all 0.2s; text-decoration: none; white-space: nowrap; }
.btn-ghost { background: transparent; color: var(--t2); border: 1px solid var(--border); }
.btn-ghost:hover { color: var(--t1); border-color: var(--border2); }
.btn-primary { background: var(--grad); color: #fff; box-shadow: 0 4px 20px rgba(124,58,237,0.4); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 28px rgba(124,58,237,0.55); }
.btn-lg { padding: 14px 32px; font-size: 1rem; border-radius: 14px; }
.btn-outline { background: transparent; color: var(--t1); border: 1px solid rgba(255,255,255,0.2); }
.btn-outline:hover { background: rgba(255,255,255,0.05); }

/* HERO */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 120px 40px 80px;
  position: relative;
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(124,58,237,0.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 60%, rgba(6,182,212,0.1) 0%, transparent 50%),
    radial-gradient(ellipse 40% 30% at 20% 80%, rgba(16,185,129,0.08) 0%, transparent 50%);
}
.hero-orbs { position: absolute; inset: 0; overflow: hidden; z-index: 0; }
.orb {
  position: absolute; border-radius: 50%;
  filter: blur(60px); opacity: 0.15;
  animation: float 8s ease-in-out infinite;
}
.orb1 { width: 500px; height: 500px; background: var(--purple); top: -150px; left: -100px; animation-delay: 0s; }
.orb2 { width: 400px; height: 400px; background: var(--cyan); bottom: -100px; right: -100px; animation-delay: 3s; }
.orb3 { width: 300px; height: 300px; background: var(--green); top: 40%; left: 40%; animation-delay: 6s; }

@keyframes float {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-30px) scale(1.05); }
}

.grid-overlay {
  position: absolute; inset: 0; z-index: 0;
  background-image:
    linear-gradient(rgba(124,58,237,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,58,237,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
}

.hero-content { position: relative; z-index: 1; max-width: 900px; }

.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px;
  background: rgba(124,58,237,0.15);
  border: 1px solid rgba(124,58,237,0.3);
  border-radius: 100px;
  font-size: 0.82rem; color: var(--purple-l); font-weight: 600;
  margin-bottom: 32px;
}
.live-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--green);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(0.8)} }

.hero h1 {
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -2px;
  margin-bottom: 24px;
}
.grad-text { background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-sub {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--t2); max-width: 620px; margin: 0 auto 48px;
}
.hero-ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 64px; }

.hero-stats {
  display: flex; gap: 48px; justify-content: center; flex-wrap: wrap;
  padding-top: 48px;
  border-top: 1px solid var(--border);
}
.stat { text-align: center; }
.stat-num { font-size: 2rem; font-weight: 800; background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.stat-label { font-size: 0.82rem; color: var(--t3); margin-top: 2px; }

/* SECTION */
section { padding: 100px 40px; }
.section-center { text-align: center; }
.section-tag {
  display: inline-block;
  font-size: 0.75rem; font-weight: 700; letter-spacing: 2px; text-transform: uppercase;
  color: var(--purple-l);
  margin-bottom: 16px;
}
h1, h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800; letter-spacing: -1px; line-height: 1.15;
  margin-bottom: 16px;
}
.section-sub { font-size: 1.05rem; color: var(--t2); max-width: 560px; margin: 0 auto; }

/* HOW IT WORKS */
.how-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px; max-width: 1100px; margin: 64px auto 0;
}
.how-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--r2);
  padding: 36px 32px;
  position: relative;
  transition: border-color 0.3s, transform 0.3s;
}
.how-card:hover { border-color: var(--border2); transform: translateY(-4px); }
.how-num {
  font-size: 4rem; font-weight: 900; line-height: 1;
  background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  opacity: 0.3; margin-bottom: 24px;
}
.how-icon {
  font-size: 2rem; margin-bottom: 16px; display: block;
}
.how-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 8px; }
.how-card p { color: var(--t2); font-size: 0.9rem; }

/* GAME MODES */
.modes-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px; max-width: 1200px; margin: 64px auto 0;
}
.mode-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); padding: 32px;
  cursor: pointer; transition: all 0.3s;
  position: relative; overflow: hidden;
}
.mode-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--grad); opacity: 0; transition: opacity 0.3s;
  border-radius: var(--r2);
}
.mode-card:hover { border-color: var(--border2); transform: translateY(-4px); box-shadow: var(--glow); }
.mode-card:hover::before { opacity: 0.05; }
.mode-icon { font-size: 2.5rem; margin-bottom: 20px; }
.mode-badge {
  display: inline-block; padding: 3px 10px;
  font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  border-radius: 100px; margin-bottom: 12px;
}
.badge-purple { background: rgba(124,58,237,0.2); color: var(--purple-l); }
.badge-cyan { background: rgba(6,182,212,0.2); color: var(--cyan-l); }
.badge-gold { background: rgba(245,158,11,0.2); color: var(--gold-l); }
.badge-green { background: rgba(16,185,129,0.2); color: var(--green-l); }
.mode-card h3 { font-size: 1.2rem; font-weight: 700; margin-bottom: 8px; }
.mode-card p { color: var(--t2); font-size: 0.88rem; margin-bottom: 20px; }
.mode-features { display: flex; flex-direction: column; gap: 6px; }
.mode-feat { display: flex; align-items: center; gap: 8px; font-size: 0.83rem; color: var(--t2); }
.mode-feat svg { flex-shrink: 0; }

/* CATEGORIES */
.cats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px; max-width: 1200px; margin: 64px auto 0;
}
.cat-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); overflow: hidden;
  transition: all 0.3s;
}
.cat-card:hover { border-color: var(--border2); transform: translateY(-4px); }
.cat-header { padding: 32px; }
.cat-icon { font-size: 2.5rem; margin-bottom: 16px; }
.cat-card h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 8px; }
.cat-card .cat-desc { color: var(--t2); font-size: 0.88rem; margin-bottom: 20px; }
.cat-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  padding: 4px 12px; border-radius: 100px;
  font-size: 0.75rem; font-weight: 600;
  background: var(--card2); border: 1px solid var(--border); color: var(--t2);
}
.cat-divider { height: 1px; background: var(--border); }
.cat-sample { padding: 24px 32px; }
.cat-sample-label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--t3); margin-bottom: 12px; }
.sample-q {
  background: var(--card2); border-radius: var(--r);
  padding: 16px; font-size: 0.85rem; color: var(--t1); font-family: inherit;
}
.sample-diff {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 12px;
}
.diff-label { font-size: 0.78rem; font-weight: 600; }
.diff-easy { color: var(--green); }
.diff-med { color: var(--gold); }
.diff-hard { color: var(--red); }
.diff-time { font-size: 0.75rem; color: var(--t3); }

/* LEADERBOARD */
.lb-container { max-width: 800px; margin: 64px auto 0; }
.lb-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 0 24px;
}
.lb-tabs { display: flex; gap: 8px; }
.lb-tab {
  padding: 8px 18px; border-radius: 8px;
  font-size: 0.85rem; font-weight: 600; cursor: pointer;
  border: 1px solid var(--border); color: var(--t2);
  background: transparent; transition: all 0.2s;
}
.lb-tab.active { background: var(--grad); border-color: transparent; color: #fff; }
.lb-table { background: var(--card); border: 1px solid var(--border); border-radius: var(--r2); overflow: hidden; }
.lb-row {
  display: grid; grid-template-columns: 48px 1fr auto auto;
  align-items: center; gap: 16px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  transition: background 0.2s;
}
.lb-row:last-child { border-bottom: none; }
.lb-row:hover { background: var(--card2); }
.lb-rank { font-size: 0.85rem; font-weight: 700; color: var(--t3); text-align: center; }
.rank-1 { color: var(--gold); }
.rank-2 { color: #c0c0c0; }
.rank-3 { color: #cd7f32; }
.lb-player { display: flex; align-items: center; gap: 12px; }
.lb-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; font-weight: 700;
  flex-shrink: 0;
}
.lb-name { font-weight: 600; font-size: 0.95rem; }
.lb-handle { font-size: 0.78rem; color: var(--t3); }
.lb-rating { font-size: 1rem; font-weight: 800; }
.lb-wins { font-size: 0.78rem; color: var(--t3); text-align: right; }
.lb-change { font-size: 0.78rem; font-weight: 600; }
.change-up { color: var(--green); }
.change-down { color: var(--red); }

/* PRICING */
.pricing-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px; max-width: 1100px; margin: 64px auto 0;
}
.price-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); padding: 36px;
  transition: all 0.3s;
  position: relative;
}
.price-card:hover { transform: translateY(-4px); }
.price-card.featured {
  border-color: var(--purple);
  background: linear-gradient(180deg, rgba(124,58,237,0.08) 0%, var(--card) 50%);
  box-shadow: 0 0 60px rgba(124,58,237,0.2);
}
.price-badge-top {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: var(--grad); color: #fff;
  padding: 4px 18px; border-radius: 100px;
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
  white-space: nowrap;
}
.price-tier { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 2px; color: var(--t3); margin-bottom: 12px; }
.price-card h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 8px; }
.price-row { display: flex; align-items: baseline; gap: 6px; margin-bottom: 8px; }
.price-num { font-size: 3rem; font-weight: 900; line-height: 1; }
.price-period { font-size: 0.88rem; color: var(--t3); }
.price-desc { font-size: 0.85rem; color: var(--t2); margin-bottom: 32px; min-height: 40px; }
.price-features { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.price-feat { display: flex; align-items: flex-start; gap: 10px; font-size: 0.88rem; }
.feat-check { width: 18px; height: 18px; border-radius: 50%; background: rgba(16,185,129,0.2); flex-shrink: 0; margin-top: 1px; display: flex; align-items: center; justify-content: center; font-size: 10px; color: var(--green); }
.feat-x { background: rgba(100,116,139,0.2); color: var(--t3); }

/* TESTIMONIALS */
.testimonials-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px; max-width: 1100px; margin: 64px auto 0;
}
.testimonial {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); padding: 28px;
}
.testimonial-stars { color: var(--gold); font-size: 0.9rem; margin-bottom: 16px; }
.testimonial-text { font-size: 0.92rem; color: var(--t2); line-height: 1.7; margin-bottom: 20px; font-style: italic; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.test-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700;
}
.test-name { font-weight: 600; font-size: 0.9rem; }
.test-role { font-size: 0.78rem; color: var(--t3); }

/* CTA BANNER */
.cta-banner {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); padding: 64px 48px;
  text-align: center; max-width: 800px; margin: 0 auto;
  position: relative; overflow: hidden;
}
.cta-banner::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(124,58,237,0.12) 0%, transparent 70%);
}
.cta-banner h2 { position: relative; }
.cta-banner p { position: relative; color: var(--t2); margin: 16px auto 36px; max-width: 480px; }
.cta-banner .hero-ctas { position: relative; }

/* FOOTER */
footer {
  background: var(--bg2); border-top: 1px solid var(--border);
  padding: 60px 40px 32px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px; max-width: 1100px; margin: 0 auto 48px;
}
.footer-brand p { color: var(--t3); font-size: 0.88rem; margin: 16px 0 24px; max-width: 280px; }
.footer-col h4 { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: var(--t3); margin-bottom: 16px; }
.footer-col a { display: block; color: var(--t2); text-decoration: none; font-size: 0.88rem; margin-bottom: 10px; transition: color 0.2s; }
.footer-col a:hover { color: var(--t1); }
.footer-bottom {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 32px; border-top: 1px solid var(--border);
  max-width: 1100px; margin: 0 auto;
  font-size: 0.82rem; color: var(--t3);
}
.footer-socials { display: flex; gap: 16px; }
.footer-social {
  width: 36px; height: 36px; border-radius: 8px;
  border: 1px solid var(--border); color: var(--t3);
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; font-size: 0.9rem; transition: all 0.2s;
}
.footer-social:hover { border-color: var(--border2); color: var(--t1); }

/* LIVE MATCH TICKER */
.live-ticker {
  background: rgba(16,185,129,0.08); border: 1px solid rgba(16,185,129,0.2);
  border-radius: 100px; padding: 8px 20px;
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 0.82rem; color: var(--green-l);
  margin-bottom: 40px; animation: glow-green 3s ease-in-out infinite;
}
@keyframes glow-green { 0%,100%{box-shadow:0 0 0 rgba(16,185,129,0)} 50%{box-shadow:0 0 20px rgba(16,185,129,0.15)} }

/* MATCH PREVIEW */
.match-preview {
  max-width: 900px; margin: 64px auto 0;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--r2); overflow: hidden;
  box-shadow: var(--shadow), var(--glow);
}
.match-bar {
  background: var(--card2); padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--border);
}
.match-players { display: flex; align-items: center; gap: 16px; font-size: 0.88rem; font-weight: 600; }
.vs-badge {
  padding: 2px 10px; background: var(--grad); border-radius: 100px;
  font-size: 0.7rem; font-weight: 800; letter-spacing: 1px;
}
.match-timer {
  font-size: 1.2rem; font-weight: 800; font-variant-numeric: tabular-nums;
  color: var(--gold);
}
.match-body { display: grid; grid-template-columns: 1fr 1fr; }
.match-panel { padding: 28px; }
.match-panel:first-child { border-right: 1px solid var(--border); }
.panel-label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--t3); margin-bottom: 16px; }
.match-question { font-size: 0.9rem; color: var(--t1); margin-bottom: 20px; line-height: 1.7; }
pre.code-block {
  background: rgba(0,0,0,0.4); border: 1px solid var(--border);
  border-radius: 8px; padding: 16px; font-size: 0.78rem;
  color: #a78bfa; overflow-x: auto; font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  line-height: 1.6;
}
.progress-section { margin-top: 16px; }
.progress-player { display: flex; justify-content: space-between; font-size: 0.8rem; margin-bottom: 6px; }
.prog-bar { height: 6px; background: var(--card2); border-radius: 100px; overflow: hidden; }
.prog-fill { height: 100%; border-radius: 100px; transition: width 0.5s ease; }
.prog-you { background: var(--grad); }
.prog-opp { background: var(--grad-gold); }

/* RESPONSIVE */
@media (max-width: 768px) {
  nav { padding: 0 20px; }
  .nav-links { display: none; }
  section { padding: 70px 20px; }
  hero { padding: 100px 20px 60px; }
  .hero-stats { gap: 32px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .match-body { grid-template-columns: 1fr; }
  .match-panel:first-child { border-right: none; border-bottom: 1px solid var(--border); }
}

/* ANIMATIONS */
.fade-up { opacity: 0; transform: translateY(30px); transition: all 0.6s ease; }
.fade-up.visible { opacity: 1; transform: translateY(0); }

.cat-code { border-top: 3px solid var(--green); }
.cat-quant { border-top: 3px solid var(--cyan); }
.cat-finance { border-top: 3px solid var(--gold); }
