*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  background: #F5F5F0;
  color: #1a1a2e;
  overflow-x: hidden;
}

:root {
  --navy: #0A1628;
  --navy2: #122040;
  --crimson: #C0392B;
  --crimson2: #a93226;
  --gold: #E8C84A;
  --gold2: #d4a82a;
  --offwhite: #F5F5F0;
  --slate: #2C3E50;
  --light: #eef0f5;
  --border: #dde1ea;
  --text-muted: #6b7280;
}

/* ── HEADER ── */
header {
  background: var(--navy);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 20px rgba(0,0,0,0.4);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.logo-icon {
  width: 40px; height: 40px;
  background: var(--crimson);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: 18px;
  color: #fff;
  letter-spacing: -1px;
}
.logo-text {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: #fff;
  line-height: 1.1;
}
.logo-sub {
  font-size: 0.65rem;
  font-weight: 400;
  color: var(--gold);
  letter-spacing: 2px;
  text-transform: uppercase;
  display: block;
}

nav { display: flex; align-items: center; gap: 6px; }
.nav-item { position: relative; }
.nav-link {
  display: flex; align-items: center; gap: 4px;
  padding: 8px 14px;
  color: #cbd5e1;
  font-family: 'Poppins', sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 6px;
  transition: color .2s, background .2s;
  cursor: pointer;
  border: none; background: transparent;
  white-space: nowrap;
}
.nav-link:hover, .nav-link.active { color: #fff; background: rgba(255,255,255,0.08); }
.nav-link svg { width: 12px; height: 12px; transition: transform .2s; }
.nav-item:hover .nav-link svg { transform: rotate(180deg); }

.dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(10,22,40,0.18);
  min-width: 180px;
  padding: 8px;
  opacity: 0; pointer-events: none;
  transition: opacity .2s, transform .2s;
  border: 1px solid var(--border);
}
.nav-item:hover .dropdown {
  opacity: 1; pointer-events: all;
  transform: translateX(-50%) translateY(0);
}
.dropdown a {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  text-decoration: none;
  color: var(--slate);
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 8px;
  transition: background .15s, color .15s;
}
.dropdown a:hover { background: var(--light); color: var(--crimson); }
.dropdown a .subject-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}

.nav-right { display: flex; align-items: center; gap: 8px; }
.about-link {
  padding: 8px 14px;
  color: #cbd5e1;
  font-family: 'Poppins', sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 6px;
  transition: color .2s, background .2s;
}
.about-link:hover { color: #fff; background: rgba(255,255,255,0.08); }
.tiktok-btn {
  display: flex; align-items: center; justify-content: center;
  width: 38px; height: 38px;
  background: rgba(255,255,255,0.08);
  border-radius: 8px;
  transition: background .2s, transform .2s;
  text-decoration: none;
}
.tiktok-btn:hover { background: var(--crimson); transform: scale(1.08); }
.tiktok-btn svg { width: 20px; height: 20px; fill: #fff; }

/* ── HERO (home) ── */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy2) 55%, #1a2a4a 100%);
  padding: 80px 24px 64px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 38px,
    rgba(232,200,74,0.04) 38px, rgba(232,200,74,0.04) 39px
  );
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  right: -80px; top: -80px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(192,57,43,0.12) 0%, transparent 70%);
  pointer-events: none;
}
.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  position: relative; z-index: 1;
  text-align: center;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(232,200,74,0.12);
  border: 1px solid rgba(232,200,74,0.3);
  color: var(--gold);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 24px;
}
.hero h1 {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 20px;
}
.hero h1 span { color: var(--gold); }
.hero-desc {
  max-width: 680px;
  margin: 0 auto 20px;
  color: #94a3b8;
  font-size: 1rem;
  line-height: 1.7;
}
.hero-highlight {
  display: inline-block;
  background: rgba(192,57,43,0.15);
  border-left: 3px solid var(--crimson);
  padding: 12px 20px;
  border-radius: 0 8px 8px 0;
  color: #e2e8f0;
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 48px;
  text-align: left;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}
.stat { text-align: center; }
.stat-num {
  font-family: 'Poppins', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: var(--gold);
  line-height: 1;
}
.stat-label {
  font-size: 0.78rem;
  color: #64748b;
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.grade-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 760px;
  margin: 0 auto;
}
.grade-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 32px 28px;
  text-align: left;
  transition: transform .25s, border-color .25s, background .25s;
  cursor: pointer;
  text-decoration: none;
  display: block;
}
.grade-card:hover {
  transform: translateY(-6px);
  border-color: var(--gold);
  background: rgba(255,255,255,0.08);
}
.grade-card-num {
  font-family: 'Poppins', sans-serif;
  font-size: 3rem;
  font-weight: 800;
  color: var(--crimson);
  line-height: 1;
  margin-bottom: 4px;
}
.grade-card-label {
  font-size: 0.75rem;
  color: var(--gold);
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.grade-card-title {
  font-family: 'Poppins', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 10px;
}
.grade-card-desc {
  font-size: 0.84rem;
  color: #94a3b8;
  line-height: 1.6;
  margin-bottom: 20px;
}
.subject-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
}
.chip-physics { background: rgba(59,130,246,0.18); color: #93c5fd; }
.chip-chem    { background: rgba(16,185,129,0.18); color: #6ee7b7; }
.chip-maths   { background: rgba(232,200,74,0.18); color: #fde68a; }

/* ── ABOUT ── */
#about {
  background: #fff;
  padding: 80px 24px;
}
.section-inner { max-width: 1100px; margin: 0 auto; }
.section-eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--crimson);
  margin-bottom: 10px;
}
.section-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 16px;
  line-height: 1.2;
}
.section-lead {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 640px;
  line-height: 1.7;
  margin-bottom: 48px;
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}
.feature-card {
  background: var(--offwhite);
  border-radius: 14px;
  padding: 28px 24px;
  border: 1px solid var(--border);
  transition: box-shadow .2s, transform .2s;
}
.feature-card:hover { box-shadow: 0 8px 30px rgba(10,22,40,0.08); transform: translateY(-3px); }
.feature-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 16px;
}
.feature-icon.red   { background: rgba(192,57,43,0.1); }
.feature-icon.blue  { background: rgba(59,130,246,0.1); }
.feature-icon.green { background: rgba(16,185,129,0.1); }
.feature-icon.gold  { background: rgba(232,200,74,0.15); }
.feature-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy);
  margin-bottom: 8px;
}
.feature-desc {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ── SUBJECT PAGE HERO ── */
.subject-hero {
  padding: 56px 24px 40px;
  position: relative;
}
.subject-hero.physics   { background: linear-gradient(135deg, #0f1c3a 0%, #1a3a6b 100%); }
.subject-hero.chemistry { background: linear-gradient(135deg, #0d2b1a 0%, #1a5c35 100%); }
.subject-hero.maths     { background: linear-gradient(135deg, #1a1200 0%, #4a3200 100%); }

.back-btn {
  display: inline-flex; align-items: center; gap: 8px;
  color: rgba(255,255,255,0.65);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  margin-bottom: 24px;
  transition: color .2s;
  background: none; border: none;
  text-decoration: none;
}
.back-btn:hover { color: #fff; }
.subject-hero-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #fff;
  margin-bottom: 8px;
}
.subject-hero-sub {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.55);
}

.grade-tabs {
  display: flex;
  gap: 8px;
  margin-top: 28px;
}
.grade-tab {
  padding: 8px 22px;
  border-radius: 8px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.6);
  background: transparent;
  transition: all .2s;
  text-decoration: none;
}
.grade-tab.active, .grade-tab:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border-color: rgba(255,255,255,0.5);
}

/* ── SYLLABUS ── */
.syllabus-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 24px 60px;
}
.syllabus-intro {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.syllabus-intro-icon { font-size: 1.6rem; flex-shrink: 0; }
.syllabus-intro-text { font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }
.syllabus-intro-text strong { color: var(--navy); }

.pdf-zone {
  background: #fff;
  border: 2px dashed var(--border);
  border-radius: 14px;
  padding: 36px 24px;
  text-align: center;
  margin-bottom: 32px;
  transition: border-color .2s;
}
.pdf-zone:hover { border-color: var(--crimson); }
.pdf-zone-icon { font-size: 2rem; margin-bottom: 10px; }
.pdf-zone-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  color: var(--navy);
  margin-bottom: 6px;
}
.pdf-zone-desc { font-size: 0.84rem; color: var(--text-muted); margin-bottom: 16px; }

/* PDF link list inside pdf-zone */
.pdf-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 12px;
}
.pdf-link {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--navy);
  color: #fff;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  transition: background .2s;
}
.pdf-link:hover { background: var(--crimson); }
.pdf-link svg { width: 14px; height: 14px; fill: currentColor; flex-shrink: 0; }

.chapter-group { margin-bottom: 32px; }
.chapter-group-label {
  font-family: 'Poppins', sans-serif;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border);
}
.chapter-list { display: flex; flex-direction: column; gap: 8px; }

/* Chapter items — PDF available ones are clickable links, coming-soon ones are plain */
.chapter-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: border-color .2s, box-shadow .2s;
  text-decoration: none;
  color: inherit;
}
.chapter-item.has-pdf {
  cursor: pointer;
}
.chapter-item.has-pdf:hover {
  border-color: var(--crimson);
  box-shadow: 0 2px 12px rgba(192,57,43,0.08);
}
.chapter-item.coming-soon {
  opacity: 0.75;
  cursor: default;
}

.chapter-num {
  width: 30px; height: 30px; flex-shrink: 0;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Poppins', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
}
.chapter-name {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--slate);
  flex: 1;
}
.chapter-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 4px;
  letter-spacing: .5px;
  white-space: nowrap;
}
.badge-soon { background: #f1f5f9; color: #94a3b8; }
.badge-pdf  { background: rgba(16,185,129,0.1); color: #059669; }

/* ── FOOTER ── */
footer {
  background: var(--navy);
  color: #94a3b8;
  padding: 56px 24px 0;
}
.footer-inner { max-width: 1100px; margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand .logo-text { color: #fff; }
.footer-tagline {
  font-size: 0.84rem;
  line-height: 1.65;
  margin-top: 16px;
  color: #64748b;
}
.footer-social { display: flex; gap: 10px; margin-top: 20px; }
.footer-social a {
  width: 36px; height: 36px;
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
  text-decoration: none;
}
.footer-social a:hover { background: var(--crimson); }
.footer-social a svg { width: 17px; height: 17px; fill: #fff; }
.footer-col-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.88rem;
  color: #fff;
  margin-bottom: 18px;
  letter-spacing: .5px;
}
.footer-col ul { list-style: none; }
.footer-col ul li + li { margin-top: 10px; }
.footer-col ul a {
  font-size: 0.84rem;
  color: #64748b;
  text-decoration: none;
  transition: color .15s;
}
.footer-col ul a:hover { color: var(--gold); }
.footer-address {
  font-size: 0.84rem;
  line-height: 1.7;
  color: #64748b;
}
.footer-address strong { color: #94a3b8; display: block; margin-bottom: 2px; }
.footer-bottom {
  padding: 18px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.footer-bottom p { font-size: 0.8rem; color: #374151; }
.footer-bottom a { color: #4b5563; text-decoration: none; }
.footer-bottom a:hover { color: var(--gold); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .header-inner { padding: 0 16px; }
  .grade-cards { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-stats { gap: 24px; }
  nav { gap: 2px; }
  .nav-link { padding: 7px 9px; font-size: 0.82rem; }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
  .grade-tabs { flex-wrap: wrap; }
}
.chip {
  display: inline-block;
  text-decoration: none;
  cursor: pointer;
}