/* ============================================================
   TeachMe Now — Landing Page Styles
   ============================================================ */

/* ── Landing layout ───────────────────────────────────────── */
#landing-screen {
  min-height: 100vh; min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
}

/* Topbar */
.landing-topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: 64px;
  display: flex; align-items: center; gap: var(--sp-4);
  padding: 0 var(--sp-6);
  background: rgba(7,11,20,.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--glass-border);
  transition: background var(--dur-mid);
}
[data-theme="light"] .landing-topbar { background: rgba(238,242,249,.92); }
.landing-logo { height: 36px; width: auto; }
.landing-topbar-actions { display: flex; align-items: center; gap: var(--sp-3); margin-inline-start: auto; }

/* ── Hero section ─────────────────────────────────────────── */
.hero {
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 100px var(--sp-5) 60px;
  text-align: center;
  position: relative;
}

.hero-eyebrow {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  background: rgba(56,182,255,.10);
  border: 1px solid rgba(56,182,255,.25);
  border-radius: var(--r-full);
  padding: var(--sp-2) var(--sp-5);
  font-size: .78rem; font-weight: 700; color: var(--clr-accent-blue);
  margin-bottom: var(--sp-6);
  animation: fadeUp .6s var(--ease-out) .2s both;
}
.hero-eyebrow-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--clr-accent-blue);
  animation: blink 2s ease-in-out infinite;
}
@keyframes blink { 50% { opacity: .2; } }

.hero-title {
  font-size: clamp(2rem, 8vw, 3.4rem);
  font-weight: 900; line-height: 1.15;
  color: var(--txt-primary);
  margin-bottom: var(--sp-5);
  animation: fadeUp .6s var(--ease-out) .3s both;
}
.hero-title .accent-blue { color: var(--clr-accent-blue); }
.hero-title .accent-gold { color: var(--clr-accent-gold); }

.hero-desc {
  font-size: 1rem; color: var(--txt-secondary); line-height: 1.8;
  max-width: 520px; margin: 0 auto var(--sp-8);
  animation: fadeUp .6s var(--ease-out) .4s both;
}

.hero-cta {
  display: flex; flex-wrap: wrap; gap: var(--sp-3);
  justify-content: center;
  animation: fadeUp .6s var(--ease-out) .5s both;
}

/* Hero icon tiles (decorative, transform-only animation) */
.hero-floats { position: absolute; top: 0; right: 0; bottom: 0; left: 0; pointer-events: none; overflow: hidden; }
.hero-tile {
  position: absolute; width: 64px; height: 64px; border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-sm);
  animation: tileDrift var(--dur, 7s) ease-in-out infinite alternate;
  will-change: transform;
}
.hero-tile svg { width: 30px; height: 30px; }
@keyframes tileDrift { from { transform: translateY(0); } to { transform: translateY(-14px); } }
@media (max-width: 700px) { .hero-tile { width: 46px; height: 46px; opacity: .85; } .hero-tile svg { width: 22px; height: 22px; } }

/* ── Stats strip ──────────────────────────────────────────── */
.stats-strip {
  display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-5) var(--sp-9);
  padding: var(--sp-7) var(--sp-5);
  border-top: 1px solid var(--glass-border);
  border-bottom: 1px solid var(--glass-border);
  background: rgba(255,255,255,.018);
}
.stat-pill { text-align: center; }
.stat-pill-num { font-size: 1.8rem; font-weight: 900; color: var(--txt-primary); }
.stat-pill-label { font-size: .78rem; color: var(--txt-muted); margin-top: 2px; }

/* ── Grade levels section ─────────────────────────────────── */
.grades-section {
  padding: var(--sp-10) var(--sp-5);
  max-width: 900px; margin: 0 auto; width: 100%;
}
.section-eyebrow {
  font-size: .78rem; font-weight: 700; color: var(--clr-accent-blue);
  letter-spacing: .08em; text-transform: uppercase;
  margin-bottom: var(--sp-3);
  display: flex; align-items: center; gap: var(--sp-2);
}
.section-eyebrow::before {
  content: '';
  width: 20px; height: 2px; background: var(--clr-accent-blue);
  border-radius: 1px;
}
.section-big-title {
  font-size: clamp(1.4rem, 4vw, 2rem); font-weight: 900;
  color: var(--txt-primary); margin-bottom: var(--sp-3);
}
.section-big-desc { font-size: .95rem; color: var(--txt-secondary); margin-bottom: var(--sp-8); }

.grade-tabs {
  display: flex; gap: var(--sp-2); flex-wrap: wrap; margin-bottom: var(--sp-6);
}
.grade-tab-btn {
  padding: var(--sp-2) var(--sp-5); border-radius: var(--r-full);
  font-size: .84rem; font-weight: 700; cursor: pointer;
  background: var(--glass-bg); border: 1.5px solid var(--glass-border);
  color: var(--txt-secondary); transition: all var(--dur-mid);
}
.grade-tab-btn.active {
  background: rgba(56,182,255,.12);
  border-color: var(--clr-accent-blue); color: var(--clr-accent-blue);
}

.grade-cards-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(130px,1fr));
  gap: var(--sp-4);
}
.grade-level-card {
  background: var(--glass-bg); border: 1.5px solid var(--glass-border);
  border-radius: var(--r-xl); padding: var(--sp-5) var(--sp-3);
  text-align: center; cursor: pointer; transition: all var(--dur-mid);
  display: flex; flex-direction: column; align-items: center; gap: var(--sp-3);
}
.grade-level-card:hover {
  border-color: rgba(56,182,255,.35);
  transform: translateY(-4px); box-shadow: var(--shadow-glow);
}
.grade-level-icon {
  width: 48px; height: 48px; border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
}
.grade-level-name { font-size: .82rem; font-weight: 700; color: var(--txt-primary); }
.grade-level-count { font-size: .72rem; color: var(--txt-muted); }

/* ── Features section ─────────────────────────────────────── */
.features-section {
  padding: var(--sp-10) var(--sp-5);
  max-width: 900px; margin: 0 auto; width: 100%;
}
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr));
  gap: var(--sp-5);
}
.feature-card {
  background: var(--glass-bg); border: 1px solid var(--glass-border);
  border-radius: var(--r-xl); padding: var(--sp-6);
  transition: all var(--dur-mid); position: relative; overflow: hidden;
}
.feature-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--fc-gradient, linear-gradient(to right, #38b6ff, #00d4aa));
}
.feature-card:hover { transform: translateY(-4px); border-color: rgba(56,182,255,.25); }
.feature-icon {
  width: 50px; height: 50px; border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: var(--sp-4);
}
.feature-title { font-size: .95rem; font-weight: 800; color: var(--txt-primary); margin-bottom: var(--sp-2); }
.feature-desc { font-size: .84rem; color: var(--txt-secondary); line-height: 1.65; }

/* ── CTA section ──────────────────────────────────────────── */
.cta-section {
  padding: var(--sp-10) var(--sp-5);
  display: flex; flex-direction: column; align-items: center; text-align: center;
  position: relative; overflow: hidden;
}
.cta-glow {
  position: absolute; top: 0; right: 0; bottom: 0; left: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(56,182,255,.08) 0%, transparent 70%);
}
.cta-title { font-size: clamp(1.5rem,4vw,2.2rem); font-weight: 900; margin-bottom: var(--sp-4); }
.cta-desc { font-size: .95rem; color: var(--txt-secondary); max-width: 460px; margin-bottom: var(--sp-7); }

/* ── Page transition overlay ──────────────────────────────── */
#page-transition {
  position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 10000;
  pointer-events: none;
  display: flex; align-items: center; justify-content: center;
}
.pt-bar {
  position: absolute; top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(to right, var(--clr-accent-blue), var(--clr-accent-teal), var(--clr-accent-gold));
  transform: scaleX(0); transform-origin: left;
  transition: transform .4s var(--ease-out);
}
.pt-bar.loading { transform: scaleX(.7); }
.pt-bar.done    { transform: scaleX(1); opacity: 0; transition: transform .2s, opacity .2s .2s; }

/* ── Footer ───────────────────────────────────────────────── */
.landing-footer {
  border-top: 1px solid var(--glass-border);
  padding: var(--sp-7) var(--sp-5);
  text-align: center; color: var(--txt-muted); font-size: .82rem;
}
.landing-footer a { color: var(--clr-accent-blue); }

/* Skip rendering work for sections below the fold */
.stats-strip, .grades-section, .features-section, .cta-section, .landing-footer {
  content-visibility: auto; contain-intrinsic-size: 1px 520px;
}
.stats-strip[hidden] { display: none; }
.grade-level-icon svg { width: 26px; height: 26px; }
.grade-level-count.empty { color: var(--txt-muted); }
