/* ============================================
   HUNGRY MINDS – AI POWERED EDUCATION
   Design System & Custom Styles
   ============================================ */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@400;500;600;700;800;900&family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* ---------- CSS Variables ---------- */
:root {
  --bg-primary: #0B0F19;
  --bg-secondary: #111827;
  --bg-card: #1F2937;
  --accent: #FF8C42;
  --accent-hover: #FFA94D;
  --accent-glow: rgba(255, 140, 66, 0.3);
  --accent-glow-strong: rgba(255, 140, 66, 0.5);
  --text-primary: #FFFFFF;
  --text-secondary: #9CA3AF;
  --text-muted: #6B7280;
  --border-color: rgba(255, 255, 255, 0.06);
  --glass-bg: rgba(31, 41, 55, 0.5);
  --glass-border: rgba(255, 255, 255, 0.08);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  line-height: 1.2;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

img {
  max-width: 100%;
  height: auto;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-hover);
}

/* ---------- Utility Classes ---------- */
.font-poppins { font-family: 'Poppins', sans-serif; }
.font-grotesk { font-family: 'Space Grotesk', sans-serif; }

.text-gradient {
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: #fff;
  font-weight: 600;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  border-radius: 12px;
  border: 2px solid var(--accent);
  cursor: pointer;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.btn-outline:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px var(--accent-glow);
}

/* ---------- Glassmorphism Card ---------- */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 32px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: linear-gradient(135deg, rgba(255,140,66,0.03), transparent 50%);
  pointer-events: none;
}

.glass-card:hover {
  transform: translateY(-8px);
  border-color: rgba(255, 140, 66, 0.3);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3),
              0 0 40px rgba(255, 140, 66, 0.08);
}

/* ---------- Section Background Animations ---------- */

/* Floating Particles */
.section-animated {
  position: relative;
  overflow: hidden;
}

.particles-bg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0;
  animation: particleFloat 8s infinite ease-in-out;
}

.particle:nth-child(1)  { left: 10%; top: 20%; animation-delay: 0s; animation-duration: 7s; }
.particle:nth-child(2)  { left: 25%; top: 60%; animation-delay: 1s; animation-duration: 9s; }
.particle:nth-child(3)  { left: 45%; top: 30%; animation-delay: 2s; animation-duration: 6s; }
.particle:nth-child(4)  { left: 65%; top: 70%; animation-delay: 0.5s; animation-duration: 8s; }
.particle:nth-child(5)  { left: 80%; top: 15%; animation-delay: 3s; animation-duration: 10s; }
.particle:nth-child(6)  { left: 90%; top: 50%; animation-delay: 1.5s; animation-duration: 7.5s; }
.particle:nth-child(7)  { left: 15%; top: 80%; animation-delay: 2.5s; animation-duration: 8.5s; }
.particle:nth-child(8)  { left: 55%; top: 10%; animation-delay: 0.8s; animation-duration: 9.5s; }

@keyframes particleFloat {
  0%   { transform: translateY(0) scale(0); opacity: 0; }
  10%  { opacity: 0.6; }
  50%  { transform: translateY(-120px) scale(1.5); opacity: 0.3; }
  100% { transform: translateY(-250px) scale(0); opacity: 0; }
}

/* Animated Grid Background */
.grid-bg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-image:
    linear-gradient(rgba(255,140,66,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,140,66,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
  animation: gridPulse 4s ease-in-out infinite;
}

@keyframes gridPulse {
  0%, 100% { opacity: 0.3; }
  50%      { opacity: 0.7; }
}

/* Floating Orbs */
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  z-index: 0;
}

.orb-orange {
  background: radial-gradient(circle, rgba(255,140,66,0.15), transparent 70%);
  width: 400px; height: 400px;
  animation: orbFloat1 12s ease-in-out infinite;
}

.orb-blue {
  background: radial-gradient(circle, rgba(59,130,246,0.08), transparent 70%);
  width: 350px; height: 350px;
  animation: orbFloat2 15s ease-in-out infinite;
}

.orb-purple {
  background: radial-gradient(circle, rgba(139,92,246,0.08), transparent 70%);
  width: 300px; height: 300px;
  animation: orbFloat3 10s ease-in-out infinite;
}

@keyframes orbFloat1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(30px, -40px) scale(1.1); }
  66%      { transform: translate(-20px, 20px) scale(0.9); }
}

@keyframes orbFloat2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(-40px, 30px) scale(1.15); }
  66%      { transform: translate(25px, -25px) scale(0.95); }
}

@keyframes orbFloat3 {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(50px, -30px); }
}

/* Random Spawning Orbs — appear, drift, fade out */
.random-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 2.5s ease-in-out, transform 6s ease-in-out;
  will-change: opacity, transform;
}

.random-orb.visible {
  opacity: 1;
}

/* Moving Gradient Line */
.gradient-line {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: lineSlide 3s ease-in-out infinite;
  z-index: 1;
}

@keyframes lineSlide {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Wave Animation */
.wave-bg {
  position: absolute;
  bottom: 0; left: 0;
  width: 200%; height: 80px;
  background: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 40px,
    rgba(255,140,66,0.03) 40px,
    rgba(255,140,66,0.03) 80px
  );
  animation: waveMove 20s linear infinite;
  pointer-events: none;
  z-index: 0;
}

@keyframes waveMove {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Neural Network Dots */
.neural-dots {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

.neural-dot {
  position: absolute;
  width: 3px; height: 3px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.2;
  animation: neuralPulse 3s ease-in-out infinite;
}

.neural-dot:nth-child(odd) { animation-delay: 1.5s; }
.neural-dot::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 40px; height: 1px;
  background: linear-gradient(90deg, rgba(255,140,66,0.15), transparent);
  transform-origin: left;
  transform: rotate(var(--angle, 30deg));
}

@keyframes neuralPulse {
  0%, 100% { opacity: 0.1; transform: scale(1); }
  50%      { opacity: 0.5; transform: scale(2); }
}

/* ---------- Scroll Animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.reveal-left {
  opacity: 0;
  transform: translateX(-60px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-left.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(60px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-right.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.85);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-scale.active {
  opacity: 1;
  transform: scale(1);
}

/* Staggered children */
.stagger-children > *:nth-child(1) { transition-delay: 0.1s; }
.stagger-children > *:nth-child(2) { transition-delay: 0.2s; }
.stagger-children > *:nth-child(3) { transition-delay: 0.3s; }
.stagger-children > *:nth-child(4) { transition-delay: 0.4s; }
.stagger-children > *:nth-child(5) { transition-delay: 0.5s; }
.stagger-children > *:nth-child(6) { transition-delay: 0.6s; }
.stagger-children > *:nth-child(7) { transition-delay: 0.7s; }
.stagger-children > *:nth-child(8) { transition-delay: 0.8s; }
.stagger-children > *:nth-child(9) { transition-delay: 0.9s; }
.stagger-children > *:nth-child(10) { transition-delay: 1.0s; }
.stagger-children > *:nth-child(11) { transition-delay: 1.1s; }
.stagger-children > *:nth-child(12) { transition-delay: 1.2s; }

/* ---------- Navbar ---------- */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 16px 0;
  transition: all 0.3s ease;
  background: transparent;
}

.navbar.scrolled {
  background: rgba(11, 15, 25, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 0;
}

.nav-link {
  position: relative;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.9rem;
  transition: color 0.3s ease;
  padding: 8px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

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

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

/* Mobile Menu */
#mobile-menu {
  background: rgba(11, 15, 25, 0.97);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: 0 0 20px 20px;
  border-top: 1px solid var(--border-color);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

#mobile-menu .nav-link {
  display: block;
  padding: 10px 0;
  font-size: 1rem;
}

/* ---------- Hero Carousel ---------- */
.hero-carousel {
  position: relative;
  width: 100%;
  min-height: 320px;
}

.hero-slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  opacity: 0;
  transform: translateX(30px) scale(0.95);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  z-index: 0;
}

.hero-slide.active {
  opacity: 1;
  transform: translateX(0) scale(1);
  pointer-events: auto;
  z-index: 1;
}

.slide-mockup {
  background: rgba(17, 24, 39, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4),
              0 0 40px rgba(255, 140, 66, 0.05);
}

.slide-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.slide-label {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  padding: 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.03em;
}

.slide-input-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
}

.slide-input-field {
  flex: 1;
  background: rgba(11, 15, 25, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 11px;
  color: #fff;
  min-height: 32px;
}

/* Chat bubbles */
.chat-messages {
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.chat-bubble {
  padding: 8px 12px;
  border-radius: 12px;
  font-size: 11px;
  max-width: 85%;
  animation: fadeSlideUp 0.3s ease forwards;
  line-height: 1.5;
}

.chat-bubble.user {
  background: rgba(255, 140, 66, 0.2);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
  color: #fff;
}

.chat-bubble.ai {
  background: rgba(31, 41, 55, 0.9);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  color: #d1d5db;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

/* Typing cursor */
.chat-cursor {
  animation: cursorBlink 0.6s step-end infinite;
  color: var(--accent);
  font-weight: 300;
}

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

/* Typing dots */
.typing-dots span {
  animation: typingDot 1.4s infinite;
  font-size: 16px;
  line-height: 1;
  color: #9CA3AF;
}
.typing-dots span:nth-child(2) { animation-delay: 0.2s; }
.typing-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingDot {
  0%, 60%, 100% { opacity: 0.2; }
  30% { opacity: 1; }
}

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

/* Loading spinner (small) */
.spinner-sm {
  width: 16px; height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* YouTube transcript line */
.yt-line {
  font-size: 10px;
  color: #d1d5db;
  padding: 4px 8px;
  margin-bottom: 3px;
  background: rgba(11, 15, 25, 0.5);
  border-radius: 6px;
  border-left: 2px solid var(--accent);
  animation: fadeSlideUp 0.4s ease forwards;
}

/* Timetable */
.tt-head {
  font-size: 9px;
  font-weight: 700;
  color: var(--accent);
  padding: 4px 2px;
  text-transform: uppercase;
}

.tt-cell {
  font-size: 10px;
  padding: 6px 2px;
  background: rgba(11, 15, 25, 0.5);
  border-radius: 6px;
  color: #d1d5db;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.tt-cell.tt-highlight {
  background: rgba(255, 140, 66, 0.2);
  color: var(--accent);
  box-shadow: 0 0 12px rgba(255, 140, 66, 0.2);
  font-weight: 600;
}

.tt-cell.tt-swapping {
  animation: ttSwap 0.6s ease;
}

@keyframes ttSwap {
  0%   { transform: scale(1); }
  30%  { transform: scale(1.15) rotate(3deg); }
  70%  { transform: scale(1.15) rotate(-3deg); }
  100% { transform: scale(1) rotate(0); }
}

/* Progress bars */
.prog-bar {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  position: relative;
}

.prog-bar-fill {
  width: 100%;
  border-radius: 4px 4px 0 0;
  position: absolute;
  bottom: 20px;
  transition: height 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.prog-label {
  position: absolute;
  bottom: 2px;
  font-size: 7px;
  color: #6B7280;
  text-align: center;
  white-space: nowrap;
}

/* Quiz options */
.quiz-opt {
  font-size: 10px;
  padding: 6px 10px;
  background: rgba(11, 15, 25, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  color: #d1d5db;
  transition: all 0.3s ease;
}

.quiz-opt-correct.highlight {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.4);
  color: #10B981;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.15);
}

/* Carousel Dots */
.hero-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 16px;
}

.hero-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.hero-dot.active {
  background: var(--accent);
  width: 24px;
  border-radius: 4px;
  box-shadow: 0 0 10px rgba(255, 140, 66, 0.3);
}

.hero-dot:hover:not(.active) {
  background: rgba(255, 255, 255, 0.3);
}

/* ---------- Hero Section ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: rgba(255, 140, 66, 0.1);
  border: 1px solid rgba(255, 140, 66, 0.2);
  border-radius: 50px;
  font-size: 0.85rem;
  color: var(--accent);
  font-weight: 500;
  animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255,140,66,0.2); }
  50%      { box-shadow: 0 0 0 10px rgba(255,140,66,0); }
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.hero p {
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  color: var(--text-secondary);
  max-width: 540px;
  line-height: 1.7;
}

/* Floating shapes in hero */
.hero-shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
}

.hero-shape-1 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(255,140,66,0.12), transparent 70%);
  top: -100px; right: -100px;
  animation: orbFloat1 15s ease-in-out infinite;
}

.hero-shape-2 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(59,130,246,0.08), transparent 70%);
  bottom: -100px; left: -100px;
  animation: orbFloat2 18s ease-in-out infinite;
}

.hero-shape-3 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(139,92,246,0.06), transparent 70%);
  top: 50%; left: 40%;
  animation: orbFloat3 12s ease-in-out infinite;
}

/* Hero visual mockup */
.hero-visual {
  position: relative;
}

.hero-mockup {
  background: var(--bg-card);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 40px 80px rgba(0,0,0,0.4);
}

.hero-mockup::before {
  content: '';
  position: absolute;
  top: -50%; left: -50%;
  width: 200%; height: 200%;
  background: conic-gradient(
    from 0deg,
    transparent,
    rgba(255,140,66,0.05),
    transparent,
    rgba(59,130,246,0.03),
    transparent
  );
  animation: mockupRotate 10s linear infinite;
}

@keyframes mockupRotate {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Mockup dots */
.mockup-dots {
  display: flex; gap: 8px; margin-bottom: 16px;
  position: relative; z-index: 1;
}

.mockup-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
}

/* Mockup code lines */
.mockup-line {
  height: 10px;
  border-radius: 5px;
  margin-bottom: 10px;
  position: relative;
  z-index: 1;
  animation: codePulse 3s ease-in-out infinite;
}

.mockup-line:nth-child(odd) { animation-delay: 0.5s; }

@keyframes codePulse {
  0%, 100% { opacity: 0.6; }
  50%      { opacity: 1; }
}

/* Floating badges around hero */
.floating-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-primary);
  animation: floatBadge 6s ease-in-out infinite;
  z-index: 5;
  white-space: nowrap;
}

@keyframes floatBadge {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

/* ---------- Stats Section ---------- */
.stat-card {
  text-align: center;
  padding: 32px 20px;
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.stat-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 50%;
  width: 0; height: 3px;
  background: var(--accent);
  transition: all 0.4s ease;
  transform: translateX(-50%);
}

.stat-card:hover::after {
  width: 60%;
}

.stat-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255,140,66,0.2);
}

.stat-number {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent);
}

/* ---------- Section Titles ---------- */
.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(255, 140, 66, 0.1);
  border: 1px solid rgba(255, 140, 66, 0.2);
  border-radius: 50px;
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-top: 16px;
}

.section-subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 640px;
  margin: 12px auto 0;
  line-height: 1.7;
}

/* ---------- Feature/Service Cards ---------- */
.feature-icon {
  width: 56px; height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
  background: rgba(255,140,66,0.1);
  color: var(--accent);
  transition: all 0.3s ease;
}

.glass-card:hover .feature-icon {
  background: var(--accent);
  color: #fff;
  transform: scale(1.1);
}

/* ---------- Pricing Cards ---------- */
.pricing-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 40px 32px;
  text-align: center;
  transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
  position: relative;
  overflow: hidden;
}

.pricing-card.popular {
  border-color: var(--accent);
  box-shadow: 0 0 40px rgba(255,140,66,0.1);
}

.pricing-card.popular::before {
  content: 'Most Popular';
  position: absolute;
  top: 20px; right: -30px;
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 40px;
  transform: rotate(45deg);
}

.pricing-card:hover {
  transform: translateY(-10px);
  border-color: rgba(255,140,66,0.4);
  box-shadow: 0 25px 60px rgba(0,0,0,0.3);
}

.price {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 3rem;
  font-weight: 700;
  color: var(--accent);
}

.price-period {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 400;
}

/* ---------- CTA Section ---------- */
.cta-section {
  position: relative;
  overflow: hidden;
}

.cta-box {
  background: linear-gradient(135deg, rgba(255,140,66,0.1), rgba(255,140,66,0.03));
  border: 1px solid rgba(255,140,66,0.2);
  border-radius: 24px;
  padding: 60px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-box::before {
  content: '';
  position: absolute;
  top: -2px; left: -2px; right: -2px; bottom: -2px;
  background: linear-gradient(135deg, var(--accent), transparent, var(--accent));
  border-radius: 26px;
  z-index: -1;
  opacity: 0.3;
  animation: ctaBorder 4s ease-in-out infinite;
}

@keyframes ctaBorder {
  0%, 100% { opacity: 0.2; }
  50%      { opacity: 0.5; }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
}

.footer-link {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.footer-link:hover {
  color: var(--accent);
  padding-left: 4px;
}

.social-icon {
  width: 40px; height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  transition: all 0.3s ease;
  font-size: 1.1rem;
}

.social-icon:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  transform: translateY(-3px);
}

/* ---------- Contact Form ---------- */
.form-input {
  width: 100%;
  padding: 14px 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: 'Inter', sans-serif;
  transition: all 0.3s ease;
  outline: none;
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255,140,66,0.1);
  background: rgba(255,255,255,0.05);
}

textarea.form-input {
  resize: vertical;
  min-height: 120px;
}

/* ---------- Loader Overlay ---------- */
.page-loader {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

.page-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-spinner {
  width: 50px; height: 50px;
  border: 3px solid var(--glass-border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.2rem;
  }

  .glass-card {
    padding: 24px;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .floating-badge {
    display: none;
  }

  .hero-shape {
    opacity: 0.5;
  }

  .orb {
    opacity: 0.4;
    transform: scale(0.6);
  }
}

@media (max-width: 480px) {
  .btn-primary, .btn-outline {
    padding: 12px 24px;
    font-size: 0.9rem;
  }

  .stat-number {
    font-size: 2rem;
  }
}


/* ---------- Smart Study AI Section ---------- */
#smart-study {
  background: radial-gradient(circle at 10% 20%, rgba(255,140,66,0.05), transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(59,130,246,0.05), transparent 40%);
}

.smart-study-bg {
  position: absolute;
  inset: 0;
  background-image: 
    radial-gradient(var(--accent-glow) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.1;
  pointer-events: none;
}

.scan-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: scanMove 6s linear infinite;
  opacity: 0.3;
  z-index: 1;
}

@keyframes scanMove {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

.smart-study-visual {
  position: relative;
  width: 100%;
  max-width: 450px;
  margin: 0 auto;
}

.book-mockup {
  background: #1e293b;
  border: 4px solid #334155;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 40px 100px rgba(0,0,0,0.5);
  position: relative;
  overflow: hidden;
}

.book-page {
  background: #0f172a;
  border-radius: 4px;
  padding: 20px;
  min-height: 280px;
  position: relative;
}

.scanning-beam {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--accent-glow), transparent);
  border-bottom: 2px solid var(--accent);
  animation: beamMove 3s ease-in-out infinite;
  z-index: 2;
}

@keyframes beamMove {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(240px); }
}

.float-animation {
  animation: floatBadge 4s ease-in-out infinite;
}

@keyframes floatBadge {
  0%, 100% { transform: translateY(0) rotate(0); }
  50% { transform: translateY(-15px) rotate(2deg); }
}

.smart-study-visual::before {
  content: '';
  position: absolute;
  inset: -20px;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  opacity: 0.3;
  z-index: -1;
}
