/* ===== RESET & TOKENS ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #6C5CE7;
  --primary-dark: #5A4BD1;
  --primary-light: #A29BFE;
  --accent: #00B894;
  --accent-dark: #00A382;
  --pink: #FD79A8;
  --yellow: #FDCB6E;
  --orange: #E17055;
  --red: #D63031;
  --green: #00B894;

  --bg: #FFFFFF;
  --bg-soft: #F8F9FC;
  --bg-muted: #F0F1F5;
  --surface: #FFFFFF;
  --text: #2D3436;
  --text-secondary: #636E72;
  --muted: #B2BEC3;
  --border: #E8ECF1;
  --border-light: #F0F1F5;

  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.04);
  --shadow: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.10);
  --shadow-xl: 0 16px 48px rgba(0,0,0,0.12);
  --transition: 0.2s ease;
}

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

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

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

.section {
  padding: 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}

::selection {
  background: rgba(108,92,231,0.15);
  color: var(--text);
}

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-soft); }
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: var(--muted); }
html { scrollbar-width: thin; scrollbar-color: var(--border) var(--bg-soft); }

/* ===== SECTION HEADERS ===== */
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary);
  background: rgba(108,92,231,0.08);
  padding: 0.4rem 1rem;
  border-radius: 50px;
  margin-bottom: 1rem;
}
.section-tag-accent {
  color: var(--pink);
  background: rgba(253,121,168,0.08);
}
.section-tag-light {
  color: #fff;
  background: rgba(255,255,255,0.2);
}
h2 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 0.75rem;
  line-height: 1.15;
}
.section-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}
.section-desc-light { color: rgba(255,255,255,0.7); }

/* ===== NAVBAR ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 64px;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
  transition: transform var(--transition);
}
.nav-brand:hover { transform: scale(1.02); }
.brand-logo {
  width: 34px;
  height: 34px;
  background: var(--primary);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 900;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(108,92,231,0.3);
}
.brand-logo-sm { width: 28px; height: 28px; font-size: 0.8rem; border-radius: 8px; }

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}
.nav-links a {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  transition: var(--transition);
}
.nav-links a:hover { color: var(--text); background: var(--bg-soft); }
.nav-links a.active { color: var(--primary); background: rgba(108,92,231,0.06); }

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.nav-icon-btn {
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: var(--transition);
}
.nav-icon-btn:hover { background: var(--bg-soft); color: var(--text); }

.nav-btn {
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.45rem 1.1rem;
  border-radius: 10px;
  transition: var(--transition);
  font-family: inherit;
}
.nav-btn-ghost { color: var(--text-secondary); }
.nav-btn-ghost:hover { background: var(--bg-soft); color: var(--text); }
.nav-btn-solid {
  background: var(--primary);
  color: white;
  box-shadow: 0 2px 8px rgba(108,92,231,0.25), 0 4px 0 var(--primary-dark);
  border-radius: 12px;
}
.nav-btn-solid:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(108,92,231,0.3), 0 4px 0 #4A3FC0;
}
.nav-btn-dash { background: var(--accent); box-shadow: 0 2px 8px rgba(0,184,148,0.25), 0 4px 0 var(--accent-dark); }
.nav-btn-dash:hover { background: var(--accent-dark); }

.nav-toggle { display: none; background: none; border: none; cursor: pointer; color: var(--text); padding: 0.4rem; }

/* ===== CLEAR HOMEPAGE FINDER ===== */
.hero {
  min-height: calc(100vh - 64px);
  padding: 3.25rem 1.5rem 2rem;
  background:
    linear-gradient(135deg, rgba(99,102,241,0.10), rgba(20,184,166,0.08) 38%, rgba(255,255,255,0.98) 76%),
    #ffffff;
}
.home-finder-wrap {
  max-width: 1180px;
  min-height: calc(100vh - 160px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(340px, 0.88fr);
  gap: 2rem;
  align-items: center;
}
.home-finder-main h1 {
  max-width: 760px;
  font-size: clamp(2.25rem, 5vw, 4.8rem);
  line-height: 1.02;
  letter-spacing: 0;
  font-weight: 900;
  color: #111827;
  margin: 0.9rem 0 1rem;
}
.home-finder-main .hero-desc {
  max-width: 680px;
  font-size: 1.1rem;
  color: #4b5563;
  line-height: 1.65;
  margin-bottom: 1.4rem;
}
.study-finder {
  max-width: 760px;
  background: rgba(255,255,255,0.92);
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  box-shadow: 0 18px 50px rgba(15,23,42,0.10);
  padding: 1rem;
}
.finder-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}
.finder-row label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}
.finder-row span {
  color: #475569;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.finder-row select {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  font: inherit;
  font-size: 0.96rem;
  font-weight: 750;
  padding: 0.8rem 0.85rem;
  min-height: 48px;
}
.finder-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.9rem;
}
.btn-secondary {
  background: #ecfeff;
  color: #0f766e;
  border: 1px solid #99f6e4;
}
.btn-secondary:hover { background: #ccfbf1; transform: translateY(-1px); }
.quick-paths {
  max-width: 760px;
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 0.75rem;
  margin-top: 1rem;
}
.quick-path {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-height: 124px;
  padding: 1rem;
  border: 1px solid #dbe3ef;
  border-radius: 8px;
  background: rgba(255,255,255,0.78);
  color: #1f2937;
  box-shadow: 0 8px 22px rgba(15,23,42,0.06);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}
.quick-path:hover {
  transform: translateY(-2px);
  border-color: #818cf8;
  box-shadow: 0 14px 32px rgba(15,23,42,0.10);
}
.quick-path.primary {
  background: #eef2ff;
  border-color: #c7d2fe;
}
.qp-kicker {
  color: #4f46e5;
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.quick-path strong {
  color: #111827;
  font-size: 0.98rem;
  line-height: 1.25;
}
.quick-path span:last-child {
  color: #64748b;
  font-size: 0.84rem;
  line-height: 1.35;
}
.home-study-preview {
  border-radius: 8px;
  background: #111827;
  color: white;
  padding: 1.15rem;
  box-shadow: 0 24px 60px rgba(15,23,42,0.22);
  position: relative;
  overflow: hidden;
}
.home-study-preview::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(20,184,166,0.22), transparent 36%),
    linear-gradient(315deg, rgba(99,102,241,0.25), transparent 42%);
  pointer-events: none;
}
.preview-top,
.preview-book { position: relative; z-index: 1; }
.preview-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
  color: #cbd5e1;
  font-size: 0.85rem;
  font-weight: 800;
}
.preview-top strong { color: #fff; font-family: "Noto Sans Devanagari", Inter, sans-serif; }
.preview-book {
  display: grid;
  gap: 0.75rem;
}
.preview-page {
  display: grid;
  grid-template-columns: 42px 1fr;
  column-gap: 0.8rem;
  align-items: center;
  padding: 0.9rem;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  background: rgba(255,255,255,0.07);
}
.preview-page span {
  grid-row: span 2;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255,255,255,0.12);
  color: #a7f3d0;
  font-weight: 900;
}
.preview-page strong { font-size: 0.98rem; }
.preview-page p {
  margin: 0.1rem 0 0;
  color: #cbd5e1;
  font-size: 0.84rem;
  line-height: 1.35;
}
.preview-page.active {
  background: rgba(20,184,166,0.18);
  border-color: rgba(94,234,212,0.45);
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.6rem;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  font-family: inherit;
  text-decoration: none;
  position: relative;
}
.btn-lg { padding: 0.9rem 2rem; font-size: 1rem; border-radius: 14px; }
.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 0 var(--primary-dark), 0 4px 12px rgba(108,92,231,0.2);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 0 var(--primary-dark), 0 8px 20px rgba(108,92,231,0.25);
}
.btn-primary:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 var(--primary-dark);
}
.btn-glass {
  background: var(--bg);
  color: var(--text);
  border: 2px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.btn-glass:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.btn-arrow { transition: transform 0.2s; }
.btn:hover .btn-arrow { transform: translateX(3px); }

.btn-sm {
  padding: 0.45rem 1rem;
  border-radius: 8px;
  background: var(--primary);
  color: white;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  font-family: inherit;
  box-shadow: 0 2px 0 var(--primary-dark);
}
.btn-sm:hover { background: var(--primary-dark); transform: translateY(-1px); }

/* ===== HERO ===== */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #F8F7FF 0%, #F0EDFF 30%, #E8F8F5 70%, #F8F9FC 100%);
  min-height: 90vh;
  display: flex;
  align-items: center;
}
.hero-bg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
}
.hero-orb-1 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(108,92,231,0.2), transparent 70%);
  top: -100px; left: -100px;
  animation: orbFloat 15s ease-in-out infinite;
}
.hero-orb-2 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(0,184,148,0.15), transparent 70%);
  bottom: -80px; right: -50px;
  animation: orbFloat 12s ease-in-out infinite reverse;
}
.hero-orb-3 {
  width: 350px; height: 350px;
  background: radial-gradient(circle, rgba(253,121,168,0.12), transparent 70%);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  animation: orbFloat 18s ease-in-out infinite 3s;
}
@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20px, -20px) scale(1.05); }
  66% { transform: translate(-15px, 15px) scale(0.97); }
}

.hero-grid-lines { display: none; }

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 5rem 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-pill {
  display: inline-flex;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--primary);
  background: rgba(108,92,231,0.08);
  border: 1px solid rgba(108,92,231,0.12);
  padding: 0.4rem 1.1rem;
  border-radius: 50px;
  margin-bottom: 1.5rem;
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -0.04em;
  color: var(--text);
  margin-bottom: 1.5rem;
}
.hero-gradient-text {
  background: linear-gradient(135deg, var(--primary), var(--pink), var(--accent));
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientShift 6s ease infinite;
  border-right: none;
  padding-right: 0;
}
@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2rem;
  max-width: 480px;
}

.hero-cta { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 2.5rem; }

.hero-proof {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-secondary);
  font-size: 0.88rem;
}
.hero-proof strong { color: var(--text); }
.hero-proof-avatars { display: flex; }
.avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem; font-weight: 700; color: white;
  border: 2px solid white;
  margin-right: -8px;
  box-shadow: var(--shadow-sm);
}

/* Hero visual */
.hero-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}
.hero-card-stack {
  position: relative;
  width: 340px;
  height: 360px;
}
.hero-lang-card {
  position: absolute;
  background: white;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  animation: cardFloat 4s ease-in-out infinite;
  transition: all 0.3s;
  box-shadow: var(--shadow-md);
}
.hero-lang-card:hover { transform: scale(1.05) !important; box-shadow: var(--shadow-lg); }
.hlc-flag {
  width: 42px; height: 42px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 900; color: white;
  flex-shrink: 0;
}
.hlc-word { color: var(--text); font-weight: 800; font-size: 1.1rem; }
.hlc-meaning { color: var(--muted); font-size: 0.8rem; font-weight: 600; margin-left: auto; }

.hlc-1 { top: 0; left: 0; animation-delay: 0s; }
.hlc-1 .hlc-flag { background: #6C5CE7; }
.hlc-2 { top: 85px; left: 40px; animation-delay: 0.8s; }
.hlc-2 .hlc-flag { background: #FD79A8; }
.hlc-3 { top: 170px; left: 10px; animation-delay: 1.6s; }
.hlc-3 .hlc-flag { background: #00B894; }
.hlc-4 { top: 255px; left: 50px; animation-delay: 2.4s; }
.hlc-4 .hlc-flag { background: #E17055; }

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

.hero-stats-row {
  display: flex;
  gap: 0.6rem;
}
.hero-stat-chip {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s;
}
.hero-stat-chip:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.hero-stat-chip strong { color: var(--primary); }

.hero-scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  animation: scrollFade 2.5s ease-in-out infinite;
  z-index: 2;
}
.scroll-arrow-wrap {
  width: 24px; height: 40px;
  border: 2px solid var(--border);
  border-radius: 12px;
  position: relative;
}
.scroll-arrow {
  width: 4px; height: 8px;
  background: var(--muted);
  border-radius: 2px;
  position: absolute; top: 6px; left: 50%;
  transform: translateX(-50%);
  animation: scrollBounce 1.5s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%, 100% { top: 6px; opacity: 1; }
  50% { top: 22px; opacity: 0.3; }
}
@keyframes scrollFade {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.8; }
}

/* ===== ANIMATED STATS BAR ===== */
.stats-bar-section {
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 3rem 2rem;
}
.stats-bar-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
}
.stat-item {
  text-align: center;
  min-width: 100px;
  transition: transform 0.3s;
}
.stat-item:hover { transform: scale(1.05); }
.stat-number {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.stat-label {
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-top: 0.25rem;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ===== TRUST BAR ===== */
.trust-section {
  padding: 2.5rem 2rem;
  overflow: hidden;
  background: var(--bg);
}
.trust-label {
  text-align: center;
  font-size: 0.78rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  margin-bottom: 1.5rem;
}
.trust-bar {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
}
.trust-bar-scroll {
  display: flex;
  gap: 3rem;
  animation: trustScroll 25s linear infinite;
  width: max-content;
}
.trust-item {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.3s;
  flex-shrink: 0;
}
.trust-item:hover { color: var(--text-secondary); }
@keyframes trustScroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ===== HOW IT WORKS ===== */
.how-it-works-section {
  background: var(--bg);
}
.hiw-steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  max-width: 1100px;
  margin: 0 auto;
}
.hiw-step {
  text-align: center;
  padding: 2rem;
  flex: 1;
  border-radius: 20px;
  transition: all 0.3s;
}
.hiw-step:hover { background: var(--bg-soft); }
.hiw-num {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-weight: 900;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  box-shadow: 0 4px 0 var(--primary-dark), 0 4px 12px rgba(108,92,231,0.2);
}
.hiw-icon {
  width: 72px; height: 72px;
  border-radius: 18px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  color: var(--primary);
  transition: all 0.3s;
}
.hiw-step:hover .hiw-icon {
  background: rgba(108,92,231,0.08);
  border-color: rgba(108,92,231,0.2);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.hiw-step h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.hiw-step p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.65;
  max-width: 280px;
  margin: 0 auto;
}
.hiw-connector {
  display: flex;
  align-items: center;
  padding-top: 4.5rem;
}
.hiw-connector-line {
  width: 60px; height: 2px;
  background: var(--border);
  position: relative;
}
.hiw-connector-line::after {
  content: '';
  position: absolute;
  right: -4px; top: -3px;
  width: 8px; height: 8px;
  border-top: 2px solid var(--muted);
  border-right: 2px solid var(--muted);
  transform: rotate(45deg);
}

/* ===== BENTO GRID (features) ===== */
.features-section { background: var(--bg-soft); padding: 6rem 0; }
.features-section .section-header,
.features-section .bento-grid { max-width: 1200px; margin-left: auto; margin-right: auto; padding: 0 2rem; }
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.bento-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.bento-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.bento-card:nth-child(1):hover { box-shadow: 0 8px 32px rgba(108,92,231,0.15); }
.bento-card:nth-child(2):hover { box-shadow: 0 8px 32px rgba(253,121,168,0.15); }
.bento-card:nth-child(3):hover { box-shadow: 0 8px 32px rgba(0,184,148,0.15); }
.bento-card:nth-child(4):hover { box-shadow: 0 8px 32px rgba(108,92,231,0.15); }
.bento-card:nth-child(5):hover { box-shadow: 0 8px 32px rgba(225,112,85,0.15); }
.bento-card:nth-child(6):hover { box-shadow: 0 8px 32px rgba(253,203,110,0.15); }
.bento-lg { grid-column: span 2; }
.bento-icon {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem;
}
.bento-card:nth-child(1) .bento-icon { background: rgba(108,92,231,0.1); color: var(--primary); }
.bento-card:nth-child(2) .bento-icon { background: rgba(253,121,168,0.1); color: var(--pink); }
.bento-card:nth-child(3) .bento-icon { background: rgba(0,184,148,0.1); color: var(--accent); }
.bento-card:nth-child(4) .bento-icon { background: rgba(108,92,231,0.1); color: var(--primary); }
.bento-card:nth-child(5) .bento-icon { background: rgba(225,112,85,0.1); color: var(--orange); }
.bento-card:nth-child(6) .bento-icon { background: rgba(253,203,110,0.15); color: #D68910; }
.bento-card:hover .bento-icon {
  transform: scale(1.1);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.bento-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text);
}
.bento-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.65;
}
.bento-cta {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary);
  opacity: 0;
  transform: translateY(5px);
  transition: all 0.3s;
}
.bento-card:hover .bento-cta {
  opacity: 1;
  transform: translateY(0);
}

/* ===== INTERACTIVE DEMO ===== */
.demo-section { background: var(--bg); }
.demo-container { max-width: 600px; margin: 0 auto; }
.demo-lang-picker {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}
.demo-lang-btn {
  padding: 0.5rem 1.25rem;
  border-radius: 50px;
  border: 2px solid var(--border);
  background: white;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
}
.demo-lang-btn:hover { border-color: var(--primary); color: var(--primary); }
.demo-lang-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 0 var(--primary-dark);
}
.demo-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  text-align: center;
  box-shadow: var(--shadow-md);
}
.demo-q-label {
  font-size: 0.75rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.demo-question {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 2rem;
}
.demo-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.demo-opt {
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border: 2px solid var(--border);
  background: white;
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.25s;
  font-family: inherit;
}
.demo-opt:hover { border-color: var(--primary); background: rgba(108,92,231,0.04); }
.demo-opt.correct {
  border-color: var(--accent);
  background: rgba(0,184,148,0.08);
  color: var(--accent-dark);
}
.demo-opt.wrong {
  border-color: var(--red);
  background: rgba(214,48,49,0.06);
  color: var(--red);
}
.demo-opt.disabled { pointer-events: none; opacity: 0.5; }
.demo-feedback {
  min-height: 1.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}
.demo-next-btn { margin: 0 auto; }
.demo-score-bar {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 600;
}
.demo-score-fill {
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  margin-top: 0.5rem;
  transition: width 0.5s ease;
  width: 0%;
}

/* ===== LANGUAGES ===== */
.languages-section { background: var(--bg); }
.lang-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.lang-card {
  background: white;
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.lang-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.lang-flag-wrap {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.lang-card:hover .lang-flag-wrap { transform: scale(1.1) rotate(-3deg); }
.lang-card:nth-child(1) .lang-flag-wrap { background: #6C5CE7; }
.lang-card:nth-child(2) .lang-flag-wrap { background: #FD79A8; }
.lang-card:nth-child(3) .lang-flag-wrap { background: #E17055; }
.lang-card:nth-child(4) .lang-flag-wrap { background: #00B894; }
.lang-card:nth-child(5) .lang-flag-wrap { background: #A29BFE; }
.lang-card:nth-child(6) .lang-flag-wrap { background: #00CEC9; }
.lang-card:nth-child(7) .lang-flag-wrap { background: #D63031; }
.lang-card:nth-child(8) .lang-flag-wrap { background: #6C5CE7; }
.lang-flag-wrap span {
  font-size: 0.8rem; font-weight: 900; color: white; letter-spacing: 0.04em;
}
.lang-card h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: var(--text);
}
.lang-card p {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.75rem;
}
.lang-badge {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--primary);
  background: rgba(108,92,231,0.08);
  padding: 0.2rem 0.65rem;
  border-radius: 50px;
  display: inline-block;
}
.lang-card-cta {
  display: block;
  margin-top: 0.75rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary);
  opacity: 0;
  transform: translateY(5px);
  transition: all 0.3s;
}
.lang-card:hover .lang-card-cta {
  opacity: 1;
  transform: translateY(0);
}

/* ===== BEFORE / AFTER COMPARISON ===== */
.comparison-section { background: var(--bg-soft); padding: 6rem 2rem; }
.comparison-grid {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 1.5rem;
  max-width: 900px;
  margin: 0 auto;
}
.comparison-card {
  flex: 1;
  border-radius: var(--radius-xl);
  padding: 2.5rem;
}
.comparison-before {
  background: white;
  border: 2px solid rgba(214,48,49,0.15);
}
.comparison-after {
  background: white;
  border: 2px solid rgba(0,184,148,0.2);
}
.comparison-label {
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  color: var(--text);
}
.comparison-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.comparison-card li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
}
.comp-x { color: var(--red); font-weight: 900; font-size: 1rem; flex-shrink: 0; }
.comp-check { color: var(--accent); font-weight: 900; font-size: 1rem; flex-shrink: 0; }
.comparison-vs {
  display: flex;
  align-items: center;
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--muted);
  flex-shrink: 0;
}

/* ===== DASHBOARD PREVIEW ===== */
.dashboard-section { background: var(--bg); }
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}
.dash-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all 0.3s ease;
}
.dash-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.xp-card { grid-column: span 2; }
.dash-icon-wrap {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(108,92,231,0.1);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 0.75rem;
}
.dash-icon-streak { background: rgba(225,112,85,0.1); color: var(--orange); }
.dash-icon-badge { background: rgba(253,203,110,0.15); color: #D68910; }
.dash-icon-quiz { background: rgba(253,121,168,0.1); color: var(--pink); }
.dash-icon-notes { background: rgba(0,184,148,0.1); color: var(--accent); }

.dash-card-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.dash-card-value {
  font-size: 2rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
  margin-bottom: 0.25rem;
  letter-spacing: -0.03em;
  transition: transform 0.3s;
}
.dash-card:hover .dash-card-value { transform: scale(1.05); }
.dash-card-sub { font-size: 0.75rem; color: var(--muted); font-weight: 500; }
.dash-level-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  background: var(--primary);
  color: white;
  padding: 0.15rem 0.6rem;
  border-radius: 50px;
  margin-bottom: 0.75rem;
}

.xp-bar-wrap { width: 100%; margin-top: 0.5rem; }
.xp-bar-track {
  height: 8px;
  background: var(--bg-muted);
  border-radius: 50px;
  overflow: hidden;
  margin-bottom: 0.35rem;
}
.xp-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--pink), var(--accent));
  border-radius: 50px;
  transition: width 0.6s ease;
  width: 0%;
}
.xp-bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
}

/* ===== GRADES ===== */
.grades-section { background: var(--bg-soft); padding: 6rem 2rem; }
.grades-row {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
}
.grade-card {
  background: white;
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 2.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  min-width: 160px;
  position: relative;
  overflow: hidden;
}
.grade-card:hover {
  color: white;
  border-color: transparent;
  transform: translateY(-6px);
}
.grade-card:nth-child(1):hover { background: #6C5CE7; box-shadow: 0 12px 32px rgba(108,92,231,0.3); }
.grade-card:nth-child(2):hover { background: #FD79A8; box-shadow: 0 12px 32px rgba(253,121,168,0.3); }
.grade-card:nth-child(3):hover { background: #00B894; box-shadow: 0 12px 32px rgba(0,184,148,0.3); }
.grade-card:nth-child(4):hover { background: #E17055; box-shadow: 0 12px 32px rgba(225,112,85,0.3); }
.grade-card:nth-child(5):hover { background: #FDCB6E; box-shadow: 0 12px 32px rgba(253,203,110,0.3); color: var(--text); }
.grade-num {
  font-size: 3rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1;
  letter-spacing: -0.04em;
  transition: all 0.3s;
}
.grade-card:hover .grade-num { color: inherit; }
.grade-label {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0.35rem 0;
  color: var(--text);
  transition: color 0.3s;
}
.grade-card:hover .grade-label { color: inherit; }
.grade-topics {
  font-size: 0.75rem;
  color: var(--muted);
  transition: color 0.3s;
}
.grade-card:hover .grade-topics { color: rgba(255,255,255,0.8); }

/* ===== CHAPTER BROWSER ===== */
.chapter-browser-section { background: var(--bg); }
.browser-lang-picker {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}
.browser-lang-btn {
  padding: 0.55rem 1.25rem;
  border-radius: 50px;
  border: 2px solid var(--border);
  background: white;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
}
.browser-lang-btn:hover { border-color: var(--primary); color: var(--primary); }
.browser-lang-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 0 var(--primary-dark);
}
.browser-class-picker {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.browser-class-btn {
  padding: 0.45rem 1.1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: white;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.3s;
  font-family: inherit;
}
.browser-class-btn:hover { border-color: var(--primary); color: var(--primary); }
.browser-class-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
.browser-textbook { max-width: 700px; margin: 0 auto 2rem; }
.browser-textbook-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: rgba(108,92,231,0.04);
  border: 1px solid rgba(108,92,231,0.12);
  border-radius: var(--radius);
}
.browser-textbook-icon { font-size: 2rem; }
.browser-textbook-name { font-weight: 700; color: var(--text); font-size: 1rem; }
.browser-textbook-pub { font-size: 0.82rem; color: var(--muted); margin-top: 0.15rem; }
.browser-chapter-list {
  max-width: 700px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.browser-chapter-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.3s;
  animation: fadeIn 0.4s ease backwards;
}
.browser-chapter-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateX(4px);
}
.browser-ch-num {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(108,92,231,0.1);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  flex-shrink: 0;
}
.browser-ch-info { flex: 1; min-width: 0; }
.browser-ch-title { font-weight: 700; color: var(--text); font-size: 0.92rem; margin-bottom: 0.2rem; }
.browser-ch-topics { font-size: 0.78rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.browser-ch-actions { display: flex; gap: 0.4rem; flex-shrink: 0; }
.browser-ch-btn {
  padding: 0.4rem 0.75rem;
  border-radius: 8px;
  border: none;
  font-weight: 600;
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
}
.browser-ch-notes { background: rgba(108,92,231,0.1); color: var(--primary); }
.browser-ch-notes:hover { background: rgba(108,92,231,0.2); }
.browser-ch-ws { background: rgba(253,121,168,0.1); color: var(--pink); }
.browser-ch-ws:hover { background: rgba(253,121,168,0.2); }
.browser-ch-pdf { background: rgba(0,184,148,0.1); color: var(--accent); }
.browser-ch-pdf:hover { background: rgba(0,184,148,0.2); }

/* ===== RESOURCES ===== */
.resources-section { background: var(--bg-soft); padding: 6rem 2rem; }
.resources-section .section-header,
.resources-section .resources-tabs,
.resources-section .tab-content { max-width: 1200px; margin-left: auto; margin-right: auto; }
.resources-tabs {
  display: flex;
  gap: 0.35rem;
  justify-content: center;
  margin-bottom: 2rem;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.3rem;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}
.tab {
  padding: 0.55rem 1.4rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  transition: var(--transition);
  font-family: inherit;
}
.tab.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 0 var(--primary-dark);
}
.tab:not(.active):hover { color: var(--text); background: var(--bg-soft); }

.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.resource-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}
.resource-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}
.resource-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.rc-color {
  width: 100%;
  height: 3px;
  border-radius: 3px;
  margin-bottom: 1rem;
}
.resource-card h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  color: var(--text);
}
.resource-card p {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

/* Vocabulary */
.vocab-topics {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 800px;
  margin: 0 auto;
}
.vocab-topic {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition);
}
.vocab-topic:hover { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.vt-header {
  padding: 1rem 1.25rem;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.vt-header span { color: var(--muted); font-size: 1.1rem; font-weight: 500; }
.vt-body { display: none; padding: 0 1.25rem 1.25rem; }
.vt-body.open { display: block; animation: fadeIn 0.25s ease; }

.vocab-header {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  padding: 0.4rem 0;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}
.vocab-table { padding-top: 0.25rem; }
.vrow {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  padding: 0.6rem 0;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border-light);
  border-radius: 6px;
  transition: background 0.15s;
}
.vrow:last-child { border-bottom: none; }
.vrow:hover { background: var(--bg-soft); }
.vrow span:first-child { font-weight: 700; color: var(--text); }
.vrow span:not(:first-child) { color: var(--text-secondary); }

.speak-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.7rem;
  padding: 0.15rem 0.3rem;
  border-radius: 4px;
  color: var(--primary);
  transition: var(--transition);
  vertical-align: middle;
  margin-left: 0.15rem;
}
.speak-btn:hover { background: rgba(108,92,231,0.08); }

/* ===== TESTIMONIALS ===== */
.testimonials-section { background: var(--bg); }
.testimonial-carousel {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 1rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}
.testimonial-carousel::-webkit-scrollbar { display: none; }
.testimonial-card {
  min-width: 340px;
  max-width: 380px;
  scroll-snap-align: center;
  background: white;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2rem;
  flex-shrink: 0;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}
.testimonial-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  border-radius: 20px 20px 0 0;
}
.testimonial-card:nth-child(1)::before { background: #6C5CE7; }
.testimonial-card:nth-child(2)::before { background: #FD79A8; }
.testimonial-card:nth-child(3)::before { background: #00B894; }
.testimonial-card:nth-child(4)::before { background: #E17055; }
.testimonial-card:nth-child(5)::before { background: #FDCB6E; }
.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.testimonial-stars {
  color: #FDCB6E;
  font-size: 1.1rem;
  letter-spacing: 2px;
  margin-bottom: 1rem;
}
.testimonial-quote {
  font-style: italic;
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}
.testimonial-author-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.testimonial-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  color: white;
  font-size: 0.9rem;
  flex-shrink: 0;
}
.testimonial-author { font-weight: 700; color: var(--text); font-size: 0.9rem; }
.testimonial-school { font-size: 0.78rem; color: var(--muted); }
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}
.carousel-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--border);
  cursor: pointer;
  transition: all 0.3s;
}
.carousel-dot.active {
  width: 24px;
  border-radius: 4px;
  background: var(--primary);
}

/* ===== FLASHCARDS ===== */
.flashcards-section { background: var(--bg-soft); padding: 6rem 2rem; }
.flashcard-filters {
  display: flex;
  gap: 0.35rem;
  justify-content: center;
  margin-bottom: 2rem;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.3rem;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}
.fc-filter {
  padding: 0.5rem 1.2rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  transition: var(--transition);
  font-family: inherit;
}
.fc-filter.active {
  background: var(--primary);
  color: white;
  box-shadow: 0 2px 0 var(--primary-dark);
}
.fc-filter:not(.active):hover { color: var(--text); background: var(--bg-soft); }

.flashcard-arena {
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}
.flashcard-wrap { width: 100%; perspective: 1000px; }
.flashcard {
  width: 100%;
  height: 240px;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border-radius: var(--radius-lg);
}
.flashcard.flipped { transform: rotateY(180deg); }

.fc-front, .fc-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.fc-front {
  background: white;
  border: 2px solid var(--border);
  box-shadow: var(--shadow-md);
}
.fc-back {
  background: linear-gradient(135deg, var(--primary), #A29BFE);
  color: white;
  transform: rotateY(180deg);
  box-shadow: var(--shadow-lg);
}
.fc-lang-tag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--primary);
  background: rgba(108,92,231,0.08);
  padding: 0.2rem 0.7rem;
  border-radius: 50px;
  margin-bottom: 1rem;
}
.fc-word {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text);
  text-align: center;
  line-height: 1.2;
}
.fc-hint { font-size: 0.75rem; color: var(--muted); margin-top: 0.75rem; }
.fc-meaning { font-size: 1.4rem; font-weight: 800; text-align: center; margin-bottom: 0.5rem; }
.fc-pronunciation { font-size: 0.95rem; opacity: 0.85; font-weight: 600; }

.fc-counter { font-size: 0.8rem; font-weight: 600; color: var(--muted); }
.fc-nav { display: flex; gap: 0.5rem; flex-wrap: wrap; justify-content: center; }
.fc-nav-btn {
  padding: 0.5rem 1rem;
  border-radius: 10px;
  background: white;
  border: 2px solid var(--border);
  font-weight: 600;
  font-size: 0.82rem;
  cursor: pointer;
  font-family: inherit;
  color: var(--text-secondary);
  transition: var(--transition);
}
.fc-nav-btn:hover { border-color: var(--primary); color: var(--primary); }

.fc-action-btn {
  padding: 0.5rem 1rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  font-family: inherit;
  border: none;
  transition: var(--transition);
  box-shadow: 0 2px 0 rgba(0,0,0,0.15);
}
.fc-action-btn.known { background: var(--accent); color: white; }
.fc-action-btn.learning { background: var(--red); color: white; }
.fc-action-btn:hover { transform: translateY(-1px); }

.fc-stats {
  display: flex;
  gap: 1.5rem;
  font-size: 0.82rem;
  font-weight: 600;
}
.fc-stat-known { color: var(--accent); }
.fc-stat-learning { color: var(--red); }

/* ===== QUIZ ===== */
.quiz-section {
  padding: 6rem 2rem;
  background: linear-gradient(135deg, #6C5CE7, #A29BFE);
  position: relative;
  overflow: hidden;
  max-width: none;
}
.quiz-section .section-header h2 { color: white; }
.quiz-section .section-header h2::after { display: none; }

.quiz-progress-wrap { max-width: 560px; margin: 0 auto 1.5rem; }
.quiz-progress-bar {
  height: 6px;
  background: rgba(255,255,255,0.2);
  border-radius: 50px;
  overflow: hidden;
}
.quiz-progress-fill {
  height: 100%;
  background: white;
  border-radius: 50px;
  transition: width 0.4s ease;
  width: 10%;
}

.quiz-box {
  max-width: 560px;
  margin: 0 auto;
  background: white;
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-xl);
}
.quiz-number {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}
.quiz-q {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--text);
}
.quiz-opts { display: flex; flex-direction: column; gap: 0.6rem; }
.quiz-opt {
  padding: 0.85rem 1.25rem;
  border-radius: 12px;
  border: 2px solid var(--border);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition);
  background: white;
  text-align: left;
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text);
  position: relative;
}
.quiz-opt::before {
  content: attr(data-letter);
  min-width: 28px; height: 28px;
  background: var(--bg-muted);
  color: var(--text-secondary);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  transition: var(--transition);
}
.quiz-opt:hover {
  border-color: var(--primary);
  background: rgba(108,92,231,0.04);
}
.quiz-opt:hover::before { background: var(--primary); color: white; }
.quiz-opt.correct { background: rgba(0,184,148,0.06); border-color: var(--accent); }
.quiz-opt.correct::before { background: var(--accent); color: white; }
.quiz-opt.wrong { background: rgba(214,48,49,0.04); border-color: var(--red); }
.quiz-opt.wrong::before { background: var(--red); color: white; }

.quiz-feedback {
  text-align: center;
  font-weight: 700;
  font-size: 0.9rem;
  margin: 1rem 0 0.5rem;
  min-height: 1.5rem;
}
.quiz-score {
  text-align: center;
  color: white;
  font-weight: 700;
  font-size: 0.95rem;
  margin-top: 1.5rem;
}
.quiz-score span { font-size: 1.4rem; color: var(--yellow); }

/* ===== FAQ ===== */
.faq-section { background: var(--bg); }
.faq-list {
  max-width: 750px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.faq-item {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s;
}
.faq-item:hover { border-color: rgba(108,92,231,0.3); box-shadow: var(--shadow-sm); }
.faq-item.open {
  border-color: var(--primary);
  box-shadow: var(--shadow);
}
.faq-q {
  padding: 1.25rem 1.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-toggle {
  font-size: 1.3rem;
  color: var(--primary);
  transition: transform 0.3s;
  flex-shrink: 0;
}
.faq-item.open .faq-toggle { transform: rotate(45deg); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s ease;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  padding: 0 1.5rem;
}
.faq-item.open .faq-a {
  max-height: 300px;
  padding: 0 1.5rem 1.25rem;
}

/* ===== PRICING PREVIEW ===== */
.pricing-preview-section { background: var(--bg-soft); padding: 6rem 2rem; }
.pricing-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  max-width: 700px;
  margin: 0 auto;
  align-items: stretch;
}
.pricing-card {
  background: white;
  border: 2px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2.5rem 2rem;
  text-align: center;
  transition: all 0.3s;
  position: relative;
}
.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.pricing-card-popular {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary), var(--shadow-md);
}
.pricing-card-popular:hover {
  transform: translateY(-6px);
}
.pricing-popular-badge {
  position: absolute;
  top: -12px; left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: white;
  padding: 0.3rem 1rem;
  border-radius: 50px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 2px 0 var(--primary-dark);
}
.pricing-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}
.pricing-price {
  font-size: 3rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1.1;
}
.pricing-period {
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}
.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.pricing-features li {
  font-size: 0.88rem;
  color: var(--text-secondary);
  padding-left: 1.5rem;
  position: relative;
}
.pricing-features li::before {
  content: '\2713';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}
.pricing-btn {
  width: 100%;
  justify-content: center;
}

/* ===== CTA ===== */
.cta-section {
  padding: 6rem 2rem;
  background: linear-gradient(135deg, #6C5CE7, #A29BFE, #00B894);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-inner { max-width: 600px; margin: 0 auto; position: relative; z-index: 1; }
.cta-inner h2 {
  color: white;
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
}
.cta-inner h2::after { display: none; }
.cta-inner p {
  color: rgba(255,255,255,0.85);
  font-size: 1.05rem;
  margin-bottom: 2rem;
}
.cta-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: rgba(255,255,255,0.9);
  background: rgba(255,255,255,0.15);
  padding: 0.35rem 1rem;
  border-radius: 50px;
  margin-bottom: 1.5rem;
}
.cta-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}
.cta-section .btn-primary {
  background: white;
  color: var(--primary);
  box-shadow: 0 4px 0 rgba(0,0,0,0.15), 0 4px 12px rgba(0,0,0,0.1);
}
.cta-section .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 0 rgba(0,0,0,0.15), 0 8px 20px rgba(0,0,0,0.15);
}
.cta-section .btn-glass {
  background: rgba(255,255,255,0.15);
  color: white;
  border-color: rgba(255,255,255,0.3);
}
.cta-section .btn-glass:hover {
  background: rgba(255,255,255,0.25);
  border-color: white;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--text);
  color: white;
  padding: 4rem 2rem 0;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}
.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 0.75rem;
}
.footer-brand p {
  color: rgba(255,255,255,0.5);
  font-size: 0.85rem;
  line-height: 1.6;
}
.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.footer-links h4 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.5);
  margin-bottom: 0.5rem;
}
.footer-links a {
  color: rgba(255,255,255,0.6);
  font-size: 0.85rem;
  transition: var(--transition);
}
.footer-links a:hover { color: white; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 0;
  text-align: center;
  color: rgba(255,255,255,0.35);
  font-size: 0.8rem;
}
.footer-social {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}
.footer-social-link {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.72rem;
  font-weight: 800;
  color: rgba(255,255,255,0.5);
  transition: all 0.3s;
}
.footer-social-link:hover {
  background: var(--primary);
  color: white;
}

/* ===== MODALS ===== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(8px);
  z-index: 200;
  align-items: center;
  justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal {
  background: white;
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  max-width: 500px;
  width: 92%;
  position: relative;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.25s ease;
  max-height: 90vh;
  overflow-y: auto;
  color: var(--text);
}
@keyframes modalIn {
  from { transform: scale(0.95) translateY(10px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}
.modal-close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: var(--bg-muted);
  border: none;
  width: 32px; height: 32px;
  border-radius: 8px;
  font-size: 1.2rem;
  cursor: pointer;
  color: var(--text-secondary);
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}
.modal-close:hover { background: rgba(214,48,49,0.1); color: var(--red); }

.modal-grade-banner {
  background: var(--primary);
  color: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
  margin-bottom: 1.5rem;
}
.modal-grade { font-size: 3rem; font-weight: 900; line-height: 1; }
.modal-grade-banner h3 { font-size: 1rem; opacity: 0.85; margin-top: 0.25rem; font-weight: 600; }
.modal-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.5rem; }
.chip {
  background: var(--bg-muted);
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.85rem;
  border-radius: 50px;
}
.modal-links-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.75rem;
}
.modal-links { display: flex; flex-direction: column; gap: 0.5rem; }
.modal-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: var(--bg-soft);
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid var(--border);
  color: var(--text);
}
.modal-link:hover { border-color: var(--primary); background: rgba(108,92,231,0.04); }
.modal-link .ml-arrow { margin-left: auto; color: var(--primary); }

/* Content Modal */
.content-modal-overlay { z-index: 300; }
.content-modal {
  background: white;
  border-radius: var(--radius-xl);
  width: min(800px, 95vw);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-xl);
  animation: modalIn 0.25s ease;
  overflow: hidden;
}
.cm-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1.25rem 1.75rem 1rem;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.cm-tag {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary);
  margin-bottom: 0.25rem;
}
.cm-title { font-size: 1.15rem; font-weight: 800; color: var(--text); }
.cm-print-btn {
  padding: 0.4rem 0.9rem;
  border-radius: 8px;
  background: var(--bg-muted);
  border: 1px solid var(--border);
  font-weight: 600;
  font-size: 0.78rem;
  cursor: pointer;
  font-family: inherit;
  color: var(--text-secondary);
  transition: var(--transition);
}
.cm-print-btn:hover { background: var(--primary); color: white; border-color: var(--primary); }
.cm-body {
  overflow-y: auto;
  padding: 1.25rem 1.75rem 1.75rem;
  flex: 1;
  line-height: 1.7;
}

/* Notes styling inside modal */
.notes-section { margin-bottom: 1.5rem; }
.notes-section h4 {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 0.6rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid var(--border);
}
.notes-rule {
  background: var(--bg-soft);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  margin-bottom: 0.5rem;
  font-size: 0.88rem;
  border-left: 3px solid var(--primary);
}
.notes-rule b { color: var(--primary); }
.notes-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  margin-bottom: 0.6rem;
  border-radius: 8px;
  overflow: hidden;
}
.notes-table th {
  background: var(--primary);
  color: white;
  font-weight: 700;
  padding: 0.5rem 0.85rem;
  text-align: left;
}
.notes-table td { padding: 0.5rem 0.85rem; border-bottom: 1px solid var(--border); }
.notes-table tr:nth-child(even) td { background: var(--bg-soft); }
.notes-table tr:last-child td { border-bottom: none; }
.notes-tip {
  background: rgba(253,203,110,0.12);
  border: 1px solid rgba(253,203,110,0.3);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #92400e;
  margin-top: 0.6rem;
}

/* Video cards inside modal */
.video-list { display: flex; flex-direction: column; gap: 0.75rem; }
.video-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  transition: var(--transition);
  text-decoration: none;
  color: var(--text);
}
.video-card:hover { border-color: var(--primary); background: rgba(108,92,231,0.04); }
.vc-thumb {
  width: 56px; height: 42px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), #A29BFE);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}
.vc-info { flex: 1; }
.vc-title { font-weight: 700; font-size: 0.88rem; margin-bottom: 0.15rem; }
.vc-meta { font-size: 0.75rem; color: var(--muted); }
.vc-platform {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 50px;
  background: rgba(108,92,231,0.08);
  color: var(--primary);
  white-space: nowrap;
}
.video-note {
  background: rgba(0,184,148,0.08);
  border: 1px solid rgba(0,184,148,0.2);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: #065f46;
  margin-bottom: 0.75rem;
}

/* Worksheet styling */
.ws-header { text-align: center; padding: 0.75rem 0 1.25rem; border-bottom: 2px solid var(--text); margin-bottom: 1.25rem; }
.ws-header h3 { font-size: 1rem; font-weight: 800; }
.ws-header p { font-size: 0.78rem; color: var(--muted); }
.ws-section { margin-bottom: 1.5rem; }
.ws-section-title {
  font-size: 0.82rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em;
  background: var(--text); color: white; padding: 0.3rem 0.75rem; border-radius: 4px;
  display: inline-block; margin-bottom: 0.85rem;
}
.ws-q { font-size: 0.88rem; margin-bottom: 0.75rem; }
.ws-q .q-num { font-weight: 800; color: var(--primary); }
.ws-blank { display: inline-block; border-bottom: 1.5px solid var(--text); min-width: 80px; }
.ws-opts { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.3rem; padding-left: 1.2rem; }
.ws-opt { font-size: 0.85rem; }
.ws-answer-box { border: 1px solid var(--border); border-radius: 6px; height: 60px; width: 100%; margin-top: 0.3rem; padding: 0.5rem; font-family: inherit; }

/* Hiragana grid */
.hiragana-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0.4rem; margin-top: 0.6rem; }
.hira-cell { background: var(--bg-soft); border-radius: 8px; padding: 0.5rem 0.35rem; text-align: center; border: 1px solid var(--border); }
.hira-char { font-size: 1.3rem; font-weight: 700; color: var(--primary); }
.hira-rom { font-size: 0.68rem; color: var(--muted); font-weight: 600; margin-top: 0.1rem; }

/* Badges Modal */
.badges-modal { max-width: 520px; }
.badges-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 0.75rem; }
.badge-item { text-align: center; padding: 0.85rem 0.4rem; border-radius: var(--radius); border: 1px solid var(--border); transition: var(--transition); }
.badge-item.unlocked { border-color: rgba(108,92,231,0.2); background: rgba(108,92,231,0.04); }
.badge-item.locked { opacity: 0.3; filter: grayscale(1); }
.badge-emoji { font-size: 1.8rem; margin-bottom: 0.3rem; display: block; }
.badge-name { font-size: 0.68rem; font-weight: 700; color: var(--text); line-height: 1.3; }
.badge-item.unlocked .badge-name { color: var(--primary); }
.badge-item.unlocked:hover { transform: scale(1.08); box-shadow: var(--shadow); }

@media print {
  .navbar, .cm-header { display: none !important; }
  .content-modal { box-shadow: none; max-height: none; border-radius: 0; width: 100%; }
  .cm-body { overflow: visible; }
}

/* ===== DAILY TIP ===== */
.daily-tip-banner {
  background: rgba(108,92,231,0.05);
  border-bottom: 1px solid var(--border);
}
.daily-tip-banner.hidden { display: none; }
.tip-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 2rem;
  font-size: 0.82rem;
  font-weight: 600;
}
.tip-dot {
  width: 6px; height: 6px;
  background: var(--primary);
  border-radius: 50%;
  flex-shrink: 0;
}
.tip-text { flex: 1; color: var(--text-secondary); }
.tip-close {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  color: var(--muted);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: var(--transition);
  flex-shrink: 0;
  line-height: 1;
}
.tip-close:hover { background: rgba(108,92,231,0.08); color: var(--primary); }

/* ===== SEARCH ===== */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  backdrop-filter: blur(8px);
  z-index: 500;
  align-items: flex-start;
  justify-content: center;
  padding-top: 10vh;
}
.search-overlay.open { display: flex; }
.search-container {
  background: white;
  border-radius: var(--radius-xl);
  width: min(620px, 94vw);
  box-shadow: var(--shadow-xl);
  padding: 1.25rem;
  animation: modalIn 0.2s ease;
  max-height: 72vh;
  overflow-y: auto;
}
.search-bar {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.75rem;
  color: var(--muted);
}
#searchInput {
  flex: 1;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  outline: none;
  color: var(--text);
}
.search-close-btn {
  background: transparent;
  border: none;
  width: 26px; height: 26px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
  color: var(--muted);
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}
.search-close-btn:hover { background: rgba(214,48,49,0.08); color: var(--red); }
.search-results { display: flex; flex-direction: column; gap: 0.4rem; }
.search-result-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: var(--transition);
  background: white;
}
.search-result-card:hover { border-color: var(--primary); background: rgba(108,92,231,0.04); transform: translateX(4px); }
.src-icon { font-size: 1.3rem; flex-shrink: 0; }
.src-title { font-weight: 700; font-size: 0.88rem; color: var(--text); }
.src-sub { font-size: 0.72rem; color: var(--muted); }
.search-empty { text-align: center; padding: 2rem; color: var(--muted); font-size: 0.88rem; }

/* ===== FLOATING WIDGET ===== */
.floating-widget {
  position: fixed;
  bottom: 1.25rem; right: 1.25rem;
  background: white;
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  padding: 0.75rem 0.85rem;
  z-index: 150;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-width: 110px;
}
.fw-row { display: flex; gap: 0.6rem; }
.fw-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  border-radius: 6px;
  transition: var(--transition);
}
.fw-item:hover { background: var(--bg-soft); }
.fw-streak { color: var(--orange); }
.fw-xp { color: var(--primary); }

.pomodoro-widget {
  border-top: 1px solid var(--border);
  padding-top: 0.6rem;
  text-align: center;
}
.pomo-label {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 0.15rem;
}
.pomo-time {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: 0.02em;
  line-height: 1;
  margin-bottom: 0.4rem;
  font-variant-numeric: tabular-nums;
}
.pomo-time.break-mode { color: var(--accent); }
.pomo-btns { display: flex; gap: 0.35rem; justify-content: center; }
.pomo-btn {
  background: var(--bg-muted);
  border: none;
  width: 28px; height: 28px;
  border-radius: 6px;
  font-size: 0.8rem;
  cursor: pointer;
  color: var(--text-secondary);
  transition: var(--transition);
  display: flex; align-items: center; justify-content: center;
}
.pomo-btn:hover { background: rgba(108,92,231,0.1); color: var(--primary); }

/* ===== SCROLL REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-left.visible { opacity: 1; transform: translateX(0); }
.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-right.visible { opacity: 1; transform: translateX(0); }
.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-scale.visible { opacity: 1; transform: scale(1); }

/* ===== DARK MODE ===== */
body.dark {
  --bg: #0F172A;
  --bg-soft: #1E293B;
  --bg-muted: #334155;
  --surface: #1E293B;
  --text: #F1F5F9;
  --text-secondary: #94A3B8;
  --muted: #64748B;
  --border: #334155;
  --border-light: #1E293B;
}
body.dark .navbar { background: rgba(15,23,42,0.92); border-bottom-color: var(--border); }
body.dark .hero { background: linear-gradient(135deg, #0F172A 0%, #1E1B4B 50%, #0F172A 100%); }
body.dark .hero-content h1 { color: white; }
body.dark .hero-lang-card { background: var(--surface); border-color: var(--border); }
body.dark .hlc-word { color: white; }
body.dark .hero-stat-chip { background: var(--surface); border-color: var(--border); color: var(--text-secondary); }
body.dark h2 { color: white; }
body.dark .bento-card,
body.dark .lang-card,
body.dark .dash-card,
body.dark .resource-card,
body.dark .testimonial-card,
body.dark .grade-card,
body.dark .pricing-card,
body.dark .faq-item,
body.dark .vocab-topic,
body.dark .demo-card,
body.dark .browser-chapter-card,
body.dark .search-result-card,
body.dark .fc-front { background: var(--surface); border-color: var(--border); }
body.dark .features-section,
body.dark .grades-section,
body.dark .resources-section,
body.dark .flashcards-section,
body.dark .pricing-preview-section,
body.dark .comparison-section { background: var(--bg-soft); }
body.dark .stats-bar-section { background: var(--bg-soft); border-color: var(--border); }
body.dark .quiz-box { background: var(--surface); }
body.dark .quiz-q { color: var(--text); }
body.dark .quiz-opt { background: var(--bg); border-color: var(--border); color: var(--text); }
body.dark .modal { background: var(--surface); color: var(--text); }
body.dark .content-modal { background: var(--surface); }
body.dark .search-container { background: var(--surface); }
body.dark #searchInput { color: var(--text); }
body.dark .fc-word { color: white; }
body.dark .floating-widget { background: var(--surface); border-color: var(--border); }
body.dark .pomo-time { color: white; }
body.dark .resources-tabs,
body.dark .flashcard-filters { background: var(--bg); border-color: var(--border); }
body.dark .comparison-before,
body.dark .comparison-after { background: var(--surface); }
body.dark .demo-opt { background: var(--bg); border-color: var(--border); color: var(--text); }
body.dark .ws-answer-box { background: var(--bg); color: var(--text); border-color: var(--border); }

/* ===== RESPONSIVE ===== */
@media (max-width: 1100px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .bento-lg { grid-column: span 1; }
  .lang-grid { grid-template-columns: repeat(3, 1fr); }
  .dashboard-grid { grid-template-columns: repeat(3, 1fr); }
  .xp-card { grid-column: span 1; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .section { padding: 4rem 1.25rem; }
  .hero-inner {
    grid-template-columns: 1fr;
    padding: 3.5rem 1.25rem;
    text-align: center;
    gap: 2.5rem;
  }
  .hero-content h1 { font-size: 2.4rem; }
  .hero-desc { margin: 0 auto 2rem; }
  .hero-cta { justify-content: center; }
  .hero-proof { justify-content: center; }
  .hero-visual { order: -1; }
  .hero-card-stack { width: 280px; height: 300px; }
  .hero-stats-row { justify-content: center; }
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .nav-inner { padding: 0 1.25rem; }
  .bento-grid { grid-template-columns: 1fr; }
  .lang-grid { grid-template-columns: repeat(2, 1fr); padding: 0 1.25rem; }
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .grades-row { flex-direction: column; align-items: stretch; }
  .grade-card { min-width: 0; }
  .footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  h2 { font-size: 1.75rem; }
  .quiz-section { padding: 4rem 1.25rem; }
  .quiz-box { padding: 1.5rem; }
  .vrow, .vocab-header { grid-template-columns: 1fr 1fr; }
  .vrow span:nth-child(4), .vocab-header span:nth-child(4) { display: none; }
  .floating-widget { bottom: 1rem; right: 0.75rem; }
  .tip-inner { padding: 0.5rem 1.25rem; font-size: 0.78rem; }
  .cta-inner h2 { font-size: 1.75rem; }
  .stats-bar-inner { gap: 1.25rem; }
  .stat-number { font-size: 2rem; }
  .stat-divider { height: 30px; }
  .hiw-steps { flex-direction: column; align-items: center; }
  .hiw-connector { transform: rotate(90deg); padding: 0; margin: -0.5rem 0; }
  .comparison-grid { flex-direction: column; }
  .comparison-vs { justify-content: center; }
  .testimonial-card { min-width: 280px; }
  .pricing-cards { grid-template-columns: 1fr; max-width: 380px; }
  .demo-options { grid-template-columns: 1fr; }
  .hero-scroll-indicator { display: none; }
  .browser-chapter-card { flex-wrap: wrap; }
  .browser-ch-actions { width: 100%; justify-content: flex-end; margin-top: 0.5rem; }
  .browser-ch-topics { white-space: normal; }
}

@media (max-width: 600px) {
  .section { padding: 3rem 1rem; }
  .hero-inner { padding: 3rem 1rem; }
  .hero-content h1 { font-size: 2rem; line-height: 1.15; }
  .hero-desc { font-size: 0.95rem; }
  .hero-card-stack { width: 240px; height: 260px; }
  .lang-grid { grid-template-columns: 1fr; padding: 0 0.75rem; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .bento-card { padding: 1.5rem; }
  h2 { font-size: 1.5rem; }
  .cta-inner h2 { font-size: 1.5rem; }
  .footer-inner { padding: 2rem 1rem; gap: 1.5rem; }
  .vrow, .vocab-header { grid-template-columns: 1fr; gap: 0.25rem; }
  .vrow span:nth-child(3), .vocab-header span:nth-child(3),
  .vrow span:nth-child(4), .vocab-header span:nth-child(4) { display: none; }
}

@media (max-width: 480px) {
  .hero-content h1 { font-size: 1.8rem; }
}

/* ===== SECTION HEADER LINE ===== */
.section-header h2::after {
  content: '';
  display: block;
  width: 48px;
  height: 4px;
  background: var(--primary);
  border-radius: 50px;
  margin: 0.75rem auto 0;
}

/* ===== LOTTIE ===== */
.lottie-hero-inline { width: 100%; max-width: 400px; }
.lottie-float { animation: cardFloat 6s ease-in-out infinite; }

/* ===== HOMEPAGE FINDER OVERRIDES ===== */
.hero {
  min-height: calc(100vh - 64px);
  padding: 3.25rem 1.5rem 2rem;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(99,102,241,0.10), rgba(20,184,166,0.08) 38%, rgba(255,255,255,0.98) 76%),
    #ffffff;
}
body.dark .hero {
  background:
    linear-gradient(135deg, rgba(99,102,241,0.22), rgba(20,184,166,0.12) 38%, rgba(15,23,42,0.98) 76%),
    #0f172a;
}
body.dark .study-finder,
body.dark .quick-path {
  background: var(--surface);
  border-color: var(--border);
}
body.dark .home-finder-main h1,
body.dark .quick-path strong { color: #fff; }
body.dark .finder-row select { background: var(--bg); color: var(--text); border-color: var(--border); }

@media (max-width: 980px) {
  .home-finder-wrap {
    grid-template-columns: 1fr;
    gap: 1.25rem;
    padding-top: 1rem;
  }
  .home-study-preview { max-width: 760px; width: 100%; }
}

@media (max-width: 720px) {
  .hero { padding: 1.5rem 1rem 1.25rem; }
  .home-finder-main h1 { font-size: 2.25rem; line-height: 1.08; }
  .home-finder-main .hero-desc { font-size: 0.98rem; }
  .finder-row { grid-template-columns: 1fr; }
  .finder-actions { flex-direction: column; }
  .finder-actions .btn { width: 100%; justify-content: center; }
  .quick-paths { grid-template-columns: 1fr; }
  .quick-path { min-height: auto; }
  .home-study-preview { padding: 0.9rem; }
  .preview-top { align-items: flex-start; flex-direction: column; }
}
