/* ============================================
   PEAKPOINT SAT PREP — SAT Preparation Platform
   Shared stylesheet
   ============================================ */

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

:root {
  --bg-primary: #05050F;
  --bg-secondary: #0A0A1A;
  --surface-1: #0F0F20;
  --surface-2: #13132A;
  --accent: #6C63FF;
  --accent-deep: #4A3FBF;
  --highlight: #A78BFF;
  --cosmic-blue: #3B82F6;
  --glow: rgba(108, 99, 255, 0.3);
  --glow-soft: rgba(108, 99, 255, 0.15);
  --text-primary: #F8F8FF;
  --text-secondary: #9090B0;
  --text-muted: #6A6A85;
  --border-default: #1E1E3A;
  --border-hover: rgba(108, 99, 255, 0.6);
  --discord: #5865F2;

  --font-display: 'Syne', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --section-padding: 160px;
  --max-width: 1240px;
  --easing: cubic-bezier(0.16, 1, 0.3, 1);
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  width: 100%;
  /* iPhone safe-area support */
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

* {
  -webkit-tap-highlight-color: transparent;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* ---------- Space Canvas ---------- */
#space-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 20% 10%, rgba(74, 63, 191, 0.08) 0%, transparent 55%),
    radial-gradient(ellipse at 80% 80%, rgba(59, 130, 246, 0.06) 0%, transparent 55%),
    var(--bg-primary);
}

/* ---------- Container ---------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

section {
  padding: var(--section-padding) 0;
  position: relative;
}

/* Subtle divider that appears between major sections */
.section-divider {
  height: 1px;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(108, 99, 255, 0.18) 50%,
    transparent 100%);
}

/* Cards-grid utility for predictable gaps */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h1 {
  font-size: clamp(2.6rem, 6vw, 5.5rem);
}

h2 {
  font-size: clamp(2rem, 4.2vw, 3.6rem);
  font-weight: 700;
}

h3 {
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  font-weight: 700;
}

p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.7;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  color: var(--highlight);
  text-transform: uppercase;
  padding: 8px 18px;
  border: 1px solid rgba(108, 99, 255, 0.3);
  border-radius: 999px;
  background: rgba(108, 99, 255, 0.06);
  margin-bottom: 24px;
}

.accent-text {
  color: var(--highlight);
  background: linear-gradient(135deg, var(--highlight) 0%, var(--cosmic-blue) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 32px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: var(--font-body);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s var(--easing);
  position: relative;
  overflow: hidden;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-deep) 100%);
  color: white;
  box-shadow: 0 0 0 0 var(--glow), 0 8px 24px rgba(74, 63, 191, 0.35);
}

.btn-primary:hover {
  filter: brightness(1.15);
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 0 30px var(--glow), 0 12px 32px rgba(74, 63, 191, 0.45);
}

.btn-secondary {
  border: 1px solid var(--accent);
  color: var(--highlight);
  background: transparent;
}

.btn-secondary:hover {
  background: rgba(108, 99, 255, 0.1);
  border-color: var(--highlight);
  transform: translateY(-2px);
}

.btn-discord {
  background: linear-gradient(135deg, var(--discord) 0%, #4752c4 100%);
  color: white;
  font-size: 1.05rem;
  padding: 18px 40px;
  box-shadow: 0 0 0 0 rgba(88, 101, 242, 0.4), 0 12px 30px rgba(88, 101, 242, 0.3);
  animation: discord-pulse 3s ease-in-out infinite;
}

.btn-discord:hover {
  filter: brightness(1.15);
  transform: translateY(-3px) scale(1.03);
}

.btn-large {
  padding: 18px 44px;
  font-size: 1.05rem;
}

@keyframes discord-pulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(108, 99, 255, 0.4), 0 12px 30px rgba(88, 101, 242, 0.3);
  }
  50% {
    box-shadow: 0 0 0 20px rgba(108, 99, 255, 0), 0 12px 30px rgba(88, 101, 242, 0.4);
  }
}

/* ---------- Navbar ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 22px 0;
  background: transparent;
  transition: all 0.4s var(--easing);
  border-bottom: 1px solid transparent;
}

.navbar.scrolled {
  background: rgba(5, 5, 15, 0.75);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(108, 99, 255, 0.15);
  padding: 16px 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--text-primary);
  letter-spacing: 0.15em;
  animation: logo-glow 3s ease-in-out infinite;
}

.logo svg,
.logo .logo-mark {
  width: 28px;
  height: 28px;
  filter: drop-shadow(0 0 8px var(--glow));
}

@keyframes logo-glow {
  0%, 100% { filter: drop-shadow(0 0 4px var(--glow-soft)); }
  50% { filter: drop-shadow(0 0 12px var(--glow)); }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  position: relative;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.3s ease;
  padding: 6px 0;
}

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

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent) 0%, var(--cosmic-blue) 100%);
  transition: width 0.35s var(--easing);
  border-radius: 2px;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links a.nav-cta {
  padding: 11px 22px;
  font-size: 0.9rem;
  margin-left: 8px;
  color: white;
  box-shadow: 0 0 0 0 var(--glow), 0 6px 20px rgba(74, 63, 191, 0.4);
}

.nav-links a.nav-cta:hover {
  filter: brightness(1.18);
  color: white;
  box-shadow: 0 0 24px var(--glow), 0 8px 24px rgba(74, 63, 191, 0.5);
}

.nav-links a.nav-cta::after {
  display: none !important;
}

.mobile-toggle {
  display: none;
  width: 28px;
  height: 28px;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}

.mobile-toggle span {
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  text-align: center;
  padding: 140px 0 100px;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 920px;
  margin: 0 auto;
  padding: 0 32px;
}

.hero h1 {
  margin-bottom: 28px;
  letter-spacing: -0.025em;
}

.hero h1 .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(50px);
  animation: word-rise 0.9s var(--easing) forwards;
  margin-right: 0.28em;
  white-space: nowrap;
}

.hero h1 .word:last-child { margin-right: 0; }

.sub-hero h1 .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(40px);
  animation: word-rise 0.85s var(--easing) forwards;
  margin-right: 0.28em;
  white-space: nowrap;
}

@keyframes word-rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-subtitle {
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 40px;
  opacity: 0;
  animation: fade-in 0.7s ease-out 1.6s forwards;
}

.hero-cta {
  display: inline-flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  transform: scale(0.85);
  animation: cta-pop 0.6s var(--easing) 2.2s forwards;
}

@keyframes fade-in {
  to { opacity: 1; }
}

@keyframes cta-pop {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Decorative cosmic orb */
.cosmic-orb {
  position: absolute;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 35%, rgba(167, 139, 255, 0.4), rgba(108, 99, 255, 0.2) 40%, transparent 65%),
    radial-gradient(circle at 70% 70%, rgba(59, 130, 246, 0.3), transparent 55%);
  filter: blur(2px);
  opacity: 0.55;
  animation: orb-rotate 60s linear infinite, orb-float 8s ease-in-out infinite;
  top: 10%;
  right: -120px;
  z-index: 0;
}

.cosmic-orb-2 {
  width: 240px;
  height: 240px;
  top: auto;
  bottom: 5%;
  left: -80px;
  right: auto;
  opacity: 0.35;
  animation-duration: 80s, 10s;
  background:
    radial-gradient(circle at 50% 40%, rgba(59, 130, 246, 0.4), transparent 60%);
}

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

@keyframes orb-float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(180deg); }
}

/* ---------- Sub-page hero (smaller) ---------- */
.sub-hero {
  min-height: 70vh;
  padding: 180px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.sub-hero h1 {
  font-size: clamp(2.4rem, 5vw, 4.5rem);
  margin-bottom: 24px;
}

.sub-hero p {
  font-size: 1.15rem;
  max-width: 700px;
  margin: 0 auto;
}

/* ---------- Universities Marquee ---------- */
.universities {
  padding: 80px 0;
  border-top: 1px solid rgba(30, 30, 58, 0.6);
  border-bottom: 1px solid rgba(30, 30, 58, 0.6);
  background: rgba(10, 10, 26, 0.4);
  overflow: hidden;
}

.universities-label {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 48px;
}

.marquee {
  width: 100%;
  overflow: hidden;
  position: relative;
  mask-image: linear-gradient(90deg, transparent, black 12%, black 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 12%, black 88%, transparent);
}

.marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: marquee 50s linear infinite;
  gap: 28px;
}

.marquee:hover .marquee-track {
  animation-play-state: paused;
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

.uni-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  height: 84px;
  min-width: 160px;
  padding: 14px 28px;
  /* Subtle frosted glass card — translucent white over the dark space bg */
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.uni-logo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.5) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.uni-logo:hover {
  border-color: rgba(108, 99, 255, 0.6);
  box-shadow:
    0 8px 30px rgba(108, 99, 255, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  transform: translateY(-3px);
}

.uni-logo:hover::before {
  opacity: 1;
}

.uni-logo img {
  height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  position: relative;
  z-index: 1;
  transition: transform 0.35s ease;
}

.uni-logo:hover img {
  transform: scale(1.04);
}

/* Text fallback if PNG fails to load — clean serif wordmark */
.uni-logo .uni-fallback {
  display: none;
  font-family: 'Syne', Georgia, serif;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(248, 248, 255, 0.55);
  transition: color 0.35s ease, transform 0.35s ease;
  white-space: nowrap;
  padding: 0 14px;
  line-height: 1;
}

.uni-logo.fallback img { display: none; }
.uni-logo.fallback .uni-fallback { display: inline-block; }
.uni-logo.fallback:hover .uni-fallback {
  color: var(--text-primary);
  transform: scale(1.04);
}

/* ---------- Stats Section ---------- */
.stats {
  text-align: center;
  position: relative;
}

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

.stat-item {
  position: relative;
  padding: 40px 20px;
}

.stat-number {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 4.5vw, 4.2rem);
  line-height: 1;
  background: linear-gradient(180deg, var(--text-primary) 0%, var(--highlight) 60%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 40px var(--glow);
  filter: drop-shadow(0 0 20px var(--glow-soft));
  margin-bottom: 16px;
  letter-spacing: -0.03em;
  word-break: keep-all;
  white-space: nowrap;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-secondary);
}

/* ---------- Section header ---------- */
.section-header {
  text-align: center;
  max-width: 720px;
  margin: 40px auto 100px;
}

.section-header h2 {
  margin-bottom: 22px;
}

.section-header p {
  font-size: 1.1rem;
}

.section-header .eyebrow {
  margin-bottom: 28px;
}

/* No divider lines between sections — clean breathing room only */

/* ---------- How It Works ---------- */
.how-it-works {
  position: relative;
}

.steps {
  position: relative;
  max-width: 920px;
  margin: 0 auto;
}

.step {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 40px;
  margin-bottom: 80px;
  position: relative;
  align-items: flex-start;
}

.step:last-child { margin-bottom: 0; }

.step-number {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--surface-1);
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--highlight);
  position: relative;
  z-index: 2;
  box-shadow: 0 0 20px var(--glow);
}

.step-number::before {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1px solid rgba(108, 99, 255, 0.4);
  animation: ring-pulse 3s ease-in-out infinite;
}

@keyframes ring-pulse {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.15); opacity: 0; }
}

.step-content {
  padding-top: 18px;
}

.step-content h3 {
  margin-bottom: 12px;
}

.step-line {
  position: absolute;
  left: 39px;
  top: 80px;
  width: 2px;
  height: calc(100% - 80px);
  background: linear-gradient(180deg, var(--accent) 0%, transparent 100%);
  opacity: 0.4;
  z-index: 1;
}

.step:last-child .step-line { display: none; }

/* ---------- Comparison ---------- */
.comparison {
  background: linear-gradient(180deg, transparent 0%, rgba(10, 10, 26, 0.5) 50%, transparent 100%);
}

.comparison + .discord-cta {
  padding-top: 80px;
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  max-width: 1080px;
  margin: 0 auto;
}

.compare-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 20px;
  padding: 48px 40px;
  transition: all 0.3s ease;
}

.compare-card.bad {
  opacity: 0.7;
}

.compare-card.good {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface-1) 100%);
  border-color: rgba(108, 99, 255, 0.4);
  box-shadow: 0 0 60px rgba(108, 99, 255, 0.15);
  position: relative;
  overflow: hidden;
}

.compare-card.good::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.compare-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 24px;
}

.compare-card.bad .compare-tag {
  background: rgba(255, 100, 120, 0.1);
  color: #FF8090;
  border: 1px solid rgba(255, 100, 120, 0.3);
}

.compare-card.good .compare-tag {
  background: rgba(108, 99, 255, 0.15);
  color: var(--highlight);
  border: 1px solid rgba(108, 99, 255, 0.4);
}

.compare-card h3 {
  margin-bottom: 28px;
  font-size: 1.6rem;
}

.compare-list {
  list-style: none;
}

.compare-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(30, 30, 58, 0.5);
  color: var(--text-secondary);
  font-size: 1rem;
}

.compare-list li:last-child { border-bottom: none; }

.compare-list .icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  margin-top: 2px;
}

.compare-card.bad .icon {
  background: rgba(255, 100, 120, 0.15);
  color: #FF8090;
}

.compare-card.good .icon {
  background: rgba(108, 99, 255, 0.2);
  color: var(--highlight);
}

.compare-card.good .compare-list li {
  color: var(--text-primary);
}

/* ---------- Discord CTA ---------- */
.discord-cta {
  text-align: center;
  position: relative;
  overflow: hidden;
}

.discord-cta-inner {
  max-width: 820px;
  margin: 0 auto;
  background:
    radial-gradient(ellipse at center, rgba(108, 99, 255, 0.15) 0%, transparent 70%),
    var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 24px;
  padding: 80px 48px;
  position: relative;
  overflow: hidden;
}

.discord-cta-inner::before,
.discord-cta-inner::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.4;
  z-index: 0;
}

.discord-cta-inner::before {
  width: 320px;
  height: 320px;
  background: var(--accent);
  top: -80px;
  left: -80px;
}

.discord-cta-inner::after {
  width: 280px;
  height: 280px;
  background: var(--cosmic-blue);
  bottom: -60px;
  right: -60px;
}

.discord-cta-content {
  position: relative;
  z-index: 1;
}

.discord-cta h2 {
  margin-bottom: 20px;
}

.discord-cta p {
  font-size: 1.1rem;
  margin-bottom: 36px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.discord-icon {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

/* ---------- FAQ ---------- */
.faq {
  position: relative;
}

.faq-list {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: rgba(108, 99, 255, 0.3);
}

.faq-item.open {
  border-color: rgba(108, 99, 255, 0.5);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.1);
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  font-family: var(--font-body);
}

.faq-chevron {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--accent);
  transition: transform 0.4s var(--easing);
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s var(--easing);
}

.faq-answer-inner {
  padding: 0 28px 24px;
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.7;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid rgba(30, 30, 58, 0.6);
  padding: 120px 0 56px;
  position: relative;
  margin-top: 80px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

/* Simpler 3-column footer when fewer link groups */
.footer-grid-simple {
  grid-template-columns: 2.4fr 1fr 1fr;
  gap: 80px;
}

.footer-brand p {
  margin: 20px 0 24px;
  max-width: 320px;
  font-size: 0.95rem;
}

.footer h4 {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  margin-bottom: 20px;
  font-weight: 500;
}

.footer ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer ul a {
  color: var(--text-secondary);
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.footer ul a:hover {
  color: var(--highlight);
}

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid rgba(30, 30, 58, 0.6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-bottom p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.social {
  display: flex;
  gap: 14px;
}

.social a {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: all 0.3s ease;
}

.social a:hover {
  color: var(--highlight);
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 0 20px var(--glow-soft);
}

.social svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* ---------- Reveal animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s var(--easing), transform 0.7s var(--easing);
  will-change: transform, opacity;
}

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

.reveal-left {
  transform: translateX(-50px);
}

.reveal-right {
  transform: translateX(50px);
}

.reveal-left.visible,
.reveal-right.visible {
  transform: translateX(0);
}

/* ---------- Competition Page ---------- */
.timeline {
  max-width: 880px;
  margin: 0 auto;
  position: relative;
  padding: 40px 0;
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--border-default);
  transform: translateX(-50%);
}

.timeline-progress {
  position: absolute;
  left: 50%;
  top: 0;
  width: 2px;
  height: 0;
  background: linear-gradient(180deg, var(--accent) 0%, var(--cosmic-blue) 100%);
  transform: translateX(-50%);
  box-shadow: 0 0 12px var(--glow);
  transition: height 0.3s ease;
}

.timeline-item {
  position: relative;
  width: 50%;
  padding: 30px 50px;
  margin-bottom: 30px;
}

.timeline-item:nth-child(odd) {
  left: 0;
  text-align: right;
}

.timeline-item:nth-child(even) {
  left: 50%;
}

.timeline-node {
  position: absolute;
  top: 40px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 2px solid var(--border-default);
  z-index: 2;
  transition: all 0.5s ease;
}

.timeline-item:nth-child(odd) .timeline-node {
  right: -11px;
}

.timeline-item:nth-child(even) .timeline-node {
  left: -11px;
}

.timeline-item.activated .timeline-node {
  border-color: var(--accent);
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(108, 99, 255, 0.2), 0 0 30px var(--glow);
  animation: node-pulse 2s ease-in-out infinite;
}

@keyframes node-pulse {
  0%, 100% { box-shadow: 0 0 0 6px rgba(108, 99, 255, 0.2), 0 0 20px var(--glow); }
  50% { box-shadow: 0 0 0 10px rgba(108, 99, 255, 0.05), 0 0 35px var(--glow); }
}

.timeline-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  padding: 28px;
  transition: all 0.3s ease;
}

.timeline-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.15);
  transform: translateY(-4px);
}

.timeline-round {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--highlight);
  margin-bottom: 10px;
}

.timeline-card h3 {
  margin-bottom: 12px;
  font-size: 1.4rem;
}

.timeline-card p {
  font-size: 0.95rem;
}

/* Prizes */
.prizes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  max-width: 1080px;
  margin: 0 auto;
}

.prize-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 20px;
  padding: 48px 32px;
  text-align: center;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.prize-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.prize-card:hover {
  transform: translateY(-8px);
  border-color: var(--border-hover);
  box-shadow: 0 0 40px rgba(108, 99, 255, 0.2);
}

.prize-card:hover::before { opacity: 1; }

.prize-card.featured {
  background: linear-gradient(180deg, var(--surface-2) 0%, var(--surface-1) 100%);
  border-color: rgba(108, 99, 255, 0.4);
  box-shadow: 0 0 40px rgba(108, 99, 255, 0.15);
}

.prize-card.featured::before { opacity: 1; }

.prize-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(108, 99, 255, 0.2), transparent 70%);
  filter: drop-shadow(0 0 20px var(--glow));
}

.prize-icon svg {
  width: 56px;
  height: 56px;
  color: var(--highlight);
}

.prize-place {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.prize-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 14px;
  background: linear-gradient(135deg, var(--text-primary), var(--highlight));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.prize-card p {
  font-size: 0.95rem;
}

/* Eligibility */
.eligibility-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 880px;
  margin: 0 auto;
}

.elig-item {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 12px;
  padding: 22px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all 0.3s ease;
}

.elig-item:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

.elig-check {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(108, 99, 255, 0.15);
  color: var(--highlight);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

/* ---------- About Page ---------- */
.values-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 60px;
}

.value-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 18px;
  padding: 36px 28px;
  text-align: center;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.value-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(108, 99, 255, 0.15), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.value-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-hover);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.15);
}

.value-card:hover::before { opacity: 1; }

.value-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(108, 99, 255, 0.15), rgba(59, 130, 246, 0.1));
  border: 1px solid rgba(108, 99, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}

.value-icon svg {
  width: 32px;
  height: 32px;
  color: var(--highlight);
}

.value-card h3 {
  font-size: 1.3rem;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
}

.value-card p {
  font-size: 0.95rem;
  position: relative;
  z-index: 1;
}

/* Story section */
.story {
  max-width: 820px;
  margin: 0 auto;
  text-align: center;
}

.story p {
  font-size: 1.15rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  margin-top: 60px;
}

.team-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 18px;
  padding: 36px 24px;
  text-align: center;
  transition: all 0.3s ease;
}

.team-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-hover);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.15);
}

.team-avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, var(--accent), var(--cosmic-blue));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: white;
  box-shadow: 0 0 30px var(--glow);
  position: relative;
}

.team-avatar::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid rgba(108, 99, 255, 0.3);
}

.team-card h3 {
  font-size: 1.2rem;
  margin-bottom: 6px;
}

.team-role {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--highlight);
  margin-bottom: 14px;
}

.team-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* Partners */
.partners {
  text-align: center;
}

.partners-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 60px;
  margin-top: 48px;
}

.partner {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  transition: color 0.3s ease;
}

.partner:hover {
  color: var(--highlight);
}

/* ---------- Join Page ---------- */
.join-steps {
  max-width: 760px;
  margin: 0 auto;
  position: relative;
}

.join-step {
  position: relative;
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 32px;
  margin-bottom: 60px;
  align-items: flex-start;
}

.join-step:last-child { margin-bottom: 0; }

.join-step-num {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--surface-1);
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--highlight);
  position: relative;
  z-index: 2;
  box-shadow: 0 0 20px var(--glow);
}

.join-step-line {
  position: absolute;
  left: 31px;
  top: 64px;
  width: 2px;
  height: calc(100% + 12px);
  background-image: linear-gradient(180deg, var(--accent) 50%, transparent 50%);
  background-size: 2px 12px;
  background-repeat: repeat-y;
  opacity: 0.5;
  z-index: 1;
}

.join-step:last-child .join-step-line { display: none; }

.join-step-content {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  padding: 28px 32px;
  transition: all 0.3s ease;
}

.join-step-content:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.12);
}

.join-step-content h3 {
  margin-bottom: 10px;
  font-size: 1.4rem;
}

.join-step-content p {
  font-size: 1rem;
  margin-bottom: 16px;
}

.join-step-content p:last-child { margin-bottom: 0; }

.tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--highlight);
  background: rgba(108, 99, 255, 0.1);
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(108, 99, 255, 0.25);
  margin-top: 12px;
}

/* Roles */
.roles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.role-card {
  background: var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 16px;
  padding: 32px 28px;
  transition: all 0.4s ease;
}

.role-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: 0 0 30px rgba(108, 99, 255, 0.15);
}

.role-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(108, 99, 255, 0.15), rgba(59, 130, 246, 0.1));
  border: 1px solid rgba(108, 99, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  color: var(--highlight);
}

.role-icon svg {
  width: 26px;
  height: 26px;
}

.role-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.role-card p {
  font-size: 0.95rem;
}

/* ---------- Mission section ---------- */
.mission-section {
  text-align: center;
}

.mission-statement {
  max-width: 880px;
  margin: 0 auto;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
  background: linear-gradient(180deg, var(--text-primary) 0%, var(--highlight) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------- Coming Soon page ---------- */
.coming-soon {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 160px 0 120px;
  position: relative;
}

.coming-soon-inner {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 2;
  text-align: center;
  box-sizing: border-box;
}

.coming-soon h1 .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(40px);
  animation: word-rise 0.85s var(--easing) forwards;
  margin-right: 0.22em;
  white-space: nowrap;
}

.coming-soon h1 .word:last-child {
  margin-right: 0;
}

.coming-soon-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.25em;
  color: var(--highlight);
  text-transform: uppercase;
  padding: 10px 22px;
  border: 1px solid rgba(108, 99, 255, 0.4);
  border-radius: 999px;
  background: rgba(108, 99, 255, 0.08);
  margin-bottom: 32px;
  box-shadow: 0 0 30px var(--glow-soft);
}

.coming-soon-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.85); }
}

.coming-soon h1 {
  font-size: clamp(2.1rem, 7vw, 5.5rem);
  margin-bottom: 24px;
  line-height: 1.08;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.coming-soon p {
  font-size: 1.15rem;
  max-width: 580px;
  margin: 0 auto 40px;
}

.coming-soon-cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .coming-soon { padding: 130px 0 90px; }
  .coming-soon p { font-size: 1.02rem; }
  .coming-soon-cta { width: 100%; flex-direction: column; }
  .coming-soon-cta .btn { width: 100%; }
}

/* ---------- Final CTA ---------- */
.final-cta {
  text-align: center;
  padding: 100px 0 140px;
}

.final-cta-inner {
  max-width: 760px;
  margin: 0 auto;
  position: relative;
}

.final-cta h2 {
  margin-bottom: 24px;
}

.final-cta p {
  font-size: 1.15rem;
  margin-bottom: 40px;
}

/* ---------- Responsive ---------- */

/* Wide tablets / small laptops — prevent stat overflow */
@media (max-width: 1100px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px 20px;
  }
  .stat-number {
    font-size: clamp(2.4rem, 7vw, 3.6rem);
  }
}

/* Tablet / small laptop */
@media (max-width: 980px) {
  :root {
    --section-padding: 110px;
  }

  /* Smaller logo cards on tablet */
  .uni-logo {
    height: 72px;
    min-width: 140px;
    padding: 12px 22px;
  }
  .marquee-track {
    gap: 22px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(5, 5, 15, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 20px 24px 28px;
    gap: 6px;
    border-bottom: 1px solid var(--border-default);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    width: 100%;
    padding: 14px 4px;
    font-size: 1rem;
  }

  .nav-links .nav-cta {
    margin-top: 10px;
    text-align: center;
    padding: 14px 22px;
  }

  .mobile-toggle {
    display: flex;
  }

  .compare-grid,
  .values-grid,
  .team-grid,
  .roles-grid,
  .prizes-grid {
    grid-template-columns: 1fr;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
  }

  .eligibility-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }

  /* Timeline mobile */
  .timeline-line,
  .timeline-progress {
    left: 20px;
  }

  .timeline-item {
    width: 100%;
    left: 0 !important;
    text-align: left !important;
    padding: 20px 0 20px 56px;
  }

  .timeline-item .timeline-node {
    left: 9px !important;
    right: auto !important;
  }

  .step {
    grid-template-columns: 60px 1fr;
    gap: 22px;
    margin-bottom: 56px;
  }

  .step-number {
    width: 60px;
    height: 60px;
    font-size: 1.3rem;
  }

  .step-line {
    left: 29px;
    top: 60px;
  }

  .join-step {
    grid-template-columns: 56px 1fr;
    gap: 18px;
    margin-bottom: 48px;
  }

  .join-step-num {
    width: 56px;
    height: 56px;
    font-size: 1.25rem;
  }

  .join-step-line {
    left: 27px;
    top: 56px;
  }

  .join-step-content {
    padding: 22px 22px;
  }

  .compare-card,
  .discord-cta-inner {
    padding: 48px 28px;
  }

  .hero {
    padding: 120px 0 80px;
  }

  .sub-hero {
    min-height: auto;
    padding: 140px 0 60px;
  }

  .cosmic-orb { display: none; }

  .section-header {
    margin-bottom: 56px;
  }
}

/* Phones */
@media (max-width: 640px) {
  :root {
    --section-padding: 88px;
  }
  .container { padding: 0 20px; }
  .nav-inner { padding: 0 20px; }
  section { padding: var(--section-padding) 0; }

  h1 { font-size: clamp(2.1rem, 9vw, 3rem); }
  h2 { font-size: clamp(1.7rem, 7vw, 2.4rem); }
  h3 { font-size: clamp(1.2rem, 5vw, 1.55rem); }

  .section-header {
    margin: 24px auto 56px;
  }

  .hero {
    padding: 110px 0 70px;
    min-height: auto;
  }

  .hero h1 .word {
    margin-right: 0.22em;
  }

  .hero-subtitle {
    font-size: 1rem;
    margin-bottom: 32px;
  }

  .hero-cta {
    flex-direction: column;
    width: 100%;
    gap: 12px;
  }

  .hero-cta .btn {
    width: 100%;
  }

  .btn-large,
  .btn {
    padding: 16px 26px;
    font-size: 0.95rem;
  }

  .btn-discord {
    padding: 16px 24px;
    font-size: 0.98rem;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px 16px;
  }

  .stat-item {
    padding: 16px 8px;
  }

  .stat-number {
    font-size: clamp(2.2rem, 11vw, 3rem);
  }

  .stat-label {
    font-size: 0.72rem;
    letter-spacing: 0.12em;
  }

  .footer {
    padding: 80px 0 40px;
    margin-top: 56px;
  }
  .footer-grid { grid-template-columns: 1fr; gap: 36px; margin-bottom: 40px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 16px; }

  .discord-cta-inner {
    padding: 56px 22px;
  }

  .compare-card {
    padding: 36px 24px;
  }

  .faq-question {
    padding: 20px 22px;
    font-size: 0.98rem;
  }

  .faq-answer-inner {
    padding: 0 22px 22px;
    font-size: 0.95rem;
  }

  /* Smaller, tighter logo cards on phone */
  .uni-logo {
    height: 60px;
    min-width: 120px;
    padding: 10px 18px;
    border-radius: 12px;
  }

  .marquee-track {
    gap: 16px;
  }

  .universities {
    padding: 64px 0;
  }
  .universities-label {
    margin-bottom: 32px;
  }

  .timeline-item {
    padding: 16px 0 16px 50px;
  }

  .timeline-card {
    padding: 22px 20px;
  }

  .eyebrow {
    font-size: 0.7rem;
    padding: 6px 14px;
  }

  .final-cta {
    padding: 70px 0 90px;
  }
}

/* Small phones (iPhone SE, mini) */
@media (max-width: 380px) {
  .container { padding: 0 16px; }
  .nav-inner { padding: 0 16px; }
  .logo span { font-size: 1.05rem; letter-spacing: 0.12em; }
  .stat-number { font-size: 2rem; }
  h1 { font-size: clamp(1.9rem, 9.5vw, 2.4rem); }
}

/* ---------- Score Gains chart ---------- */
.score-gains { position: relative; }

.sg-card {
  max-width: 1000px;
  margin: 0 auto;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(108, 99, 255, 0.10) 0%, transparent 60%),
    var(--surface-1);
  border: 1px solid var(--border-default);
  border-radius: 24px;
  padding: 48px 44px 36px;
  box-shadow: 0 0 60px rgba(108, 99, 255, 0.08);
}

.sg-chart {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 16px;
  --sg-h: 460px;
}

/* Y axis */
.sg-yaxis {
  grid-column: 1;
  grid-row: 1;
  height: var(--sg-h);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-end;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
  padding-right: 4px;
}
.sg-yaxis span { transform: translateY(-50%); }
.sg-yaxis span:first-child { transform: translateY(-50%); }
.sg-yaxis span:last-child { transform: translateY(50%); }

/* Plot area */
.sg-plot {
  grid-column: 2;
  grid-row: 1;
  position: relative;
  height: var(--sg-h);
  border-left: 1px solid var(--border-default);
  border-bottom: 1px solid var(--border-default);
}

.sg-grid { position: absolute; inset: 0; }
.sg-grid span {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 1.5px dashed rgba(108, 99, 255, 0.20);
}

.sg-bands {
  position: absolute;
  inset: 0;
  display: flex;
}

.sg-band {
  position: relative;
  flex: 1;
  height: 100%;
}

/* Track pill enclosing both dots */
.sg-track {
  position: absolute;
  left: 50%;
  width: 46px;
  transform: translateX(-50%);
  bottom: calc(var(--lo) * 1% - 26px);
  height: calc((var(--hi) - var(--lo)) * 1% + 52px);
  border-radius: 999px;
  background:
    repeating-linear-gradient(135deg, rgba(167, 139, 255, 0.10) 0 3px, transparent 3px 8px),
    rgba(108, 99, 255, 0.07);
  border: 1px solid rgba(108, 99, 255, 0.14);
  z-index: 1;
}

/* Connecting line */
.sg-line {
  position: absolute;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  bottom: calc(var(--lo) * 1%);
  height: calc((var(--hi) - var(--lo)) * 1%);
  background: linear-gradient(180deg, var(--accent) 0%, var(--highlight) 100%);
  opacity: 0.85;
  z-index: 2;
}

/* Dots */
.sg-dot {
  position: absolute;
  left: 50%;
  border-radius: 50%;
  z-index: 3;
}

.sg-dot.with {
  width: 44px;
  height: 44px;
  bottom: calc(var(--hi) * 1%);
  transform: translate(-50%, 50%);
  background:
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.16) 0 3px, transparent 3px 7px),
    linear-gradient(135deg, #7A6BFF 0%, #4A3FBF 100%);
  box-shadow: 0 8px 22px rgba(74, 63, 191, 0.5), 0 0 0 5px rgba(108, 99, 255, 0.12);
}

.sg-dot.without {
  width: 34px;
  height: 34px;
  bottom: calc(var(--lo) * 1%);
  transform: translate(-50%, 50%);
  background:
    repeating-linear-gradient(135deg, rgba(167, 139, 255, 0.22) 0 3px, transparent 3px 7px),
    rgba(108, 99, 255, 0.10);
  border: 1px solid rgba(108, 99, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
}
.sg-dot.without::after {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--highlight);
  box-shadow: 0 0 10px var(--glow);
}

/* Gain badge */
.sg-badge {
  position: absolute;
  left: 50%;
  bottom: calc(var(--hi) * 1% + 36px);
  transform: translateX(-50%);
  z-index: 4;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.82rem;
  color: #fff;
  white-space: nowrap;
  padding: 6px 13px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-deep) 100%);
  box-shadow: 0 6px 16px rgba(74, 63, 191, 0.45);
}

/* X axis */
.sg-xaxis {
  grid-column: 2;
  grid-row: 2;
  display: flex;
  padding-top: 16px;
}
.sg-xaxis span {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* Legend */
.sg-legend {
  display: flex;
  justify-content: center;
  gap: 36px;
  flex-wrap: wrap;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--border-default);
}
.sg-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-primary);
}
.sg-swatch {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  flex-shrink: 0;
}
.sg-swatch.with {
  background:
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.16) 0 3px, transparent 3px 7px),
    linear-gradient(135deg, #7A6BFF 0%, #4A3FBF 100%);
  box-shadow: 0 4px 12px rgba(74, 63, 191, 0.4);
}
.sg-swatch.without {
  background:
    repeating-linear-gradient(135deg, rgba(167, 139, 255, 0.22) 0 3px, transparent 3px 7px),
    rgba(108, 99, 255, 0.10);
  border: 1px solid rgba(108, 99, 255, 0.3);
}

@media (max-width: 640px) {
  .sg-card { padding: 28px 16px 24px; }
  .sg-chart { --sg-h: 340px; column-gap: 8px; }
  .sg-yaxis { font-size: 0.7rem; }
  .sg-dot.with { width: 32px; height: 32px; box-shadow: 0 6px 16px rgba(74, 63, 191, 0.5), 0 0 0 4px rgba(108, 99, 255, 0.12); }
  .sg-dot.without { width: 24px; height: 24px; }
  .sg-dot.without::after { width: 9px; height: 9px; }
  .sg-track { width: 32px; }
  .sg-badge { font-size: 0.68rem; padding: 4px 8px; bottom: calc(var(--hi) * 1% + 28px); }
  .sg-xaxis { padding-top: 12px; }
  .sg-xaxis span { font-size: 0.58rem; letter-spacing: -0.02em; }
  .sg-legend { gap: 20px; margin-top: 28px; }
  .sg-legend-item { font-size: 0.85rem; }
}

/* ---------- Testimonials carousel ---------- */
.testimonials {
  position: relative;
  padding: 100px 0 90px;
  margin: 40px 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% -10%, rgba(255, 255, 255, 0.18) 0%, transparent 55%),
    linear-gradient(165deg, #6C4BE6 0%, #8B7BF0 55%, #B9A9F5 100%);
}

.tst-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

.testimonials .section-header {
  margin: 0 auto 56px;
}
.testimonials .section-header h2 {
  color: #fff;
  margin-bottom: 18px;
}
.tst-accent {
  color: #fff;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
}
.testimonials .section-header p {
  color: rgba(255, 255, 255, 0.85);
}

/* Carousel viewport */
.tst-carousel {
  position: relative;
}

.tst-track {
  display: flex;
  gap: 26px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 26px max(32px, calc((100% - var(--max-width)) / 2 + 32px)) 12px;
  scroll-padding-left: max(32px, calc((100% - var(--max-width)) / 2 + 32px));
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.tst-track::-webkit-scrollbar { display: none; }

.tst-card {
  position: relative;
  flex: 0 0 360px;
  max-width: 360px;
  min-height: 400px;
  background: #F5F3FF;
  border-radius: 22px;
  padding: 48px 32px 32px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 40px rgba(60, 40, 120, 0.25);
  transition: transform 0.3s var(--easing), box-shadow 0.3s var(--easing);
}
.tst-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 54px rgba(50, 30, 110, 0.35);
}

.tst-pill {
  position: absolute;
  top: -16px;
  left: 30px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  color: #fff;
  padding: 8px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, #7C3AED 0%, #5B2BD6 100%);
  box-shadow: 0 8px 20px rgba(76, 29, 149, 0.4);
  white-space: nowrap;
}

.tst-quote {
  color: #241a3d;
  font-size: 1.08rem;
  line-height: 1.55;
  font-weight: 500;
}
.tst-quote em { font-style: italic; color: #4A3FBF; }

.tst-person {
  margin-top: auto;
  padding-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.tst-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  color: #1a1030;
}
.tst-school {
  font-size: 0.95rem;
  color: #6A6A85;
}

/* Pagination dots */
.tst-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 30px;
}
.tst-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  transition: all 0.3s ease;
  cursor: pointer;
  padding: 0;
}
.tst-dot:hover { background: rgba(255, 255, 255, 0.7); }
.tst-dot.active {
  background: #fff;
  width: 26px;
  border-radius: 999px;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.6);
}

@media (max-width: 640px) {
  .testimonials { padding: 72px 0 64px; margin: 24px 0; }
  .tst-inner { padding: 0 20px; }
  .testimonials .section-header { margin-bottom: 40px; }
  .tst-track {
    gap: 18px;
    padding: 24px 20px 12px;
    scroll-padding-left: 20px;
  }
  .tst-card {
    flex-basis: 84%;
    max-width: 84%;
    min-height: 360px;
    padding: 44px 24px 28px;
  }
  .tst-quote { font-size: 1rem; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.2s !important;
    scroll-behavior: auto !important;
  }

  .hero h1 .word,
  .hero-subtitle,
  .hero-cta {
    opacity: 1;
    transform: none;
  }

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

  .cosmic-orb,
  .marquee-track {
    animation: none;
  }
}
