/* ============================================================
   ChakriPath design system v3
   "প্রস্তুতি থেকে সাফল্যের পথে"
   8px spacing scale · 12-col grid · max-width 1200px
   Bengali: Hind Siliguri · English: Inter
   ============================================================ */

:root {
  /* Brand tokens */
  --primary: #087F6A;
  --primary-dark: #066A58;
  --primary-ink: #055C4C;
  --heading: #132E2A;
  --page: #F6F8F7;
  --card: #FFFFFF;
  --soft-green: #DCECE5;
  --gold: #F5C75E;
  --gold-soft: #FDF3DC;
  --text: #24332E;
  --text-2: #64756E;
  --border: #E2EAE5;
  --error: #DC2626;
  --error-soft: #FDECEC;
  --success: #15803D;
  --success-soft: #EAF6EE;
  --warning: #B45309;
  --warning-soft: #FEF6E7;
  --info: #2563EB;
  --info-soft: #EFF4FE;

  /* Shape & elevation */
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 18px;
  --max-width: 1200px;
  --shadow-sm: 0 1px 2px rgba(19, 46, 42, 0.05);
  --shadow: 0 1px 2px rgba(19, 46, 42, 0.04), 0 8px 20px rgba(19, 46, 42, 0.06);
  --shadow-lg: 0 2px 6px rgba(19, 46, 42, 0.06), 0 16px 40px rgba(19, 46, 42, 0.10);

  /* Type */
  --font: "Hind Siliguri", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Legacy aliases (ExamCompass → ChakriPath) */
  --accent: var(--primary);
  --accent-ink: var(--primary-ink);
  --accent-soft: var(--soft-green);
  --ink: var(--text);
  --muted: var(--text-2);
  --surface: var(--card);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4 { color: var(--heading); line-height: 1.28; letter-spacing: -0.015em; margin: 0 0 12px; font-weight: 700; }
h1 { font-size: 2.5rem; font-weight: 800; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.15rem; }
p { margin: 0 0 16px; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }

/* Visible focus for keyboard users (WCAG 2.2 AA) */
:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
  border-radius: 6px;
}

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--text-2); }
.small { font-size: 0.875rem; }
.lead { font-size: 1.12rem; color: var(--text-2); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.2rem; color: var(--heading); }
.brand:hover { text-decoration: none; }
.brand svg { display: block; flex-shrink: 0; }
.nav { display: flex; align-items: center; gap: 2px; margin-left: 8px; }
.nav a {
  color: var(--text-2); font-weight: 600; font-size: 0.93rem;
  padding: 9px 13px; border-radius: var(--radius-sm); white-space: nowrap;
}
.nav a:hover { color: var(--heading); background: var(--page); text-decoration: none; }
.nav a.active { color: var(--primary-ink); background: var(--soft-green); }
.nav-cta { margin-left: 10px; }
.header-spacer { flex: 1; }
.hamburger { display: none; background: none; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 9px 10px; cursor: pointer; color: var(--text); }
.hamburger svg { display: block; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-weight: 700; font-size: 0.95rem; line-height: 1.2;
  padding: 13px 24px; border-radius: 12px; border: 1px solid transparent;
  cursor: pointer; transition: background 0.15s, border-color 0.15s, box-shadow 0.15s, transform 0.05s;
  min-height: 48px;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-secondary { background: var(--card); color: var(--text); border-color: var(--border); }
.btn-secondary:hover { border-color: var(--primary); color: var(--primary-ink); }
.btn-gold { background: var(--gold); color: var(--heading); }
.btn-gold:hover { background: #EDB93F; color: var(--heading); }
.btn-ghost { background: transparent; color: var(--primary-ink); border-color: transparent; }
.btn-ghost:hover { background: var(--soft-green); }
.btn-sm { padding: 9px 16px; font-size: 0.86rem; border-radius: 10px; min-height: 40px; }
.btn-lg { padding: 15px 30px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn-danger-outline { background: var(--card); color: var(--error); border-color: var(--border); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 96px 0 80px; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; aria-hidden: true; }
.hero-bg .orb {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: 0.5;
  animation: drift 22s ease-in-out infinite alternate;
}
.hero-bg .orb-1 { width: 420px; height: 420px; background: #CDE8DD; top: -120px; right: -80px; }
.hero-bg .orb-2 { width: 320px; height: 320px; background: #E9F3EE; bottom: -140px; left: -60px; animation-delay: -8s; }
.hero-bg .orb-3 { width: 200px; height: 200px; background: var(--gold-soft); top: 30%; left: 38%; opacity: 0.35; animation-delay: -14s; }
.hero-bg .dots {
  position: absolute; inset: 0; opacity: 0.5;
  background-image: radial-gradient(var(--border) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 20%, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 20%, black 30%, transparent 75%);
}
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(36px, 28px, 0) scale(1.06); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg .orb { animation: none; }
  html { scroll-behavior: auto; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
.hero-inner { position: relative; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--primary-ink); background: var(--soft-green);
  padding: 7px 15px; border-radius: 999px; margin-bottom: 22px;
}
.hero-eyebrow .pulse-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }
.hero h1 { max-width: 760px; margin-bottom: 16px; font-size: 3rem; }
.hero h1 .hl { color: var(--primary); }
.hero .lead { max-width: 620px; margin-bottom: 30px; }
.hero-search {
  display: flex; gap: 0; max-width: 600px; margin-bottom: 22px;
  background: var(--card); border: 1.5px solid var(--border); border-radius: 14px;
  box-shadow: var(--shadow); overflow: hidden;
}
.hero-search:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(8, 127, 106, 0.12); }
.hero-search svg { flex-shrink: 0; align-self: center; margin-left: 18px; }
.hero-search input {
  flex: 1; border: 0; outline: 0; font-family: var(--font); font-size: 1rem;
  padding: 16px 12px; background: transparent; color: var(--text); min-width: 0;
}
.hero-search button { border-radius: 0; min-height: 56px; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 26px; }
.hero-quick { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.hero-quick span { font-size: 0.85rem; color: var(--text-2); font-weight: 600; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center; }

/* Mission progress visual in hero */
.mission-visual {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); padding: 26px; position: relative;
}
.mission-visual h4 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-2); margin-bottom: 18px; }
.mv-path { display: flex; flex-direction: column; gap: 0; }
.mv-node { display: flex; gap: 14px; align-items: flex-start; position: relative; padding-bottom: 22px; }
.mv-node:last-child { padding-bottom: 0; }
.mv-node::before {
  content: ""; position: absolute; left: 17px; top: 38px; bottom: 0; width: 2px; background: var(--border);
}
.mv-node:last-child::before { display: none; }
.mv-node.done::before { background: var(--primary); }
.mv-dot {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  background: var(--page); border: 2px solid var(--border); color: var(--text-2);
}
.mv-node.done .mv-dot { background: var(--primary); border-color: var(--primary); color: #fff; }
.mv-node.current .mv-dot { background: var(--gold); border-color: var(--gold); color: var(--heading); box-shadow: 0 0 0 5px var(--gold-soft); }
.mv-body { flex: 1; min-width: 0; }
.mv-body strong { display: block; font-size: 0.95rem; color: var(--heading); }
.mv-body small { color: var(--text-2); font-size: 0.82rem; }
.mv-xp {
  margin-left: auto; flex-shrink: 0; font-size: 0.78rem; font-weight: 800; color: var(--primary-ink);
  background: var(--soft-green); padding: 4px 10px; border-radius: 999px; align-self: center;
}

/* ---------- Sections & cards ---------- */
.section { padding: 64px 0; }
.section-alt { background: var(--card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 680px; margin-bottom: 36px; }
.section-head h2 { margin-bottom: 8px; }
.section-head p { color: var(--text-2); margin-bottom: 0; }
.section-head-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 32px; flex-wrap: wrap; }
.section-head-row h2 { margin-bottom: 6px; }
.section-head-row p { color: var(--text-2); margin: 0; max-width: 560px; }

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

.card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow-sm);
  transition: box-shadow 0.18s, transform 0.18s, border-color 0.18s;
}
.card.hoverable:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: var(--soft-green); }
.card-icon {
  width: 48px; height: 48px; border-radius: 14px; background: var(--soft-green);
  display: flex; align-items: center; justify-content: center; margin-bottom: 18px;
}
.card-icon svg { width: 24px; height: 24px; stroke: var(--primary-ink); }
.card-icon.gold { background: var(--gold-soft); }
.card-icon.gold svg { stroke: #9A7418; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-2); font-size: 0.95rem; margin-bottom: 0; }
.card-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 0.92rem; margin-top: 14px; }

/* ---------- Badges, chips, status ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.76rem; font-weight: 700; padding: 5px 12px; border-radius: 999px;
  background: var(--page); border: 1px solid var(--border); color: var(--text-2);
  white-space: nowrap;
}
.badge-sample { background: var(--warning-soft); border-color: #F0DFB8; color: var(--warning); }
.badge-days { background: var(--soft-green); border-color: #C4E2D6; color: var(--primary-ink); }
.badge-urgent { background: var(--error-soft); border-color: #F5C6C6; color: var(--error); }
.badge-easy { background: var(--success-soft); color: var(--success); border-color: #CBE6D4; }
.badge-medium { background: var(--warning-soft); color: var(--warning); border-color: #F0DFB8; }
.badge-hard { background: var(--error-soft); color: var(--error); border-color: #F5C6C6; }
.badge-new { background: var(--info-soft); color: var(--info); border-color: #CBDCF7; }
.badge-xp { background: var(--gold-soft); border-color: #EFD9A0; color: #8A6A14; }
.badge-locked { background: var(--page); color: var(--text-2); }

.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.chip {
  font-family: var(--font); font-size: 0.88rem; font-weight: 600;
  padding: 9px 17px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--card); color: var(--text-2); cursor: pointer;
  min-height: 40px;
}
.chip:hover { border-color: var(--primary); color: var(--primary-ink); }
.chip.active { background: var(--heading); color: #fff; border-color: var(--heading); }
.chip[aria-pressed="true"] { background: var(--heading); color: #fff; border-color: var(--heading); }

/* ---------- Circular cards ---------- */
.circular-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.circular-card { display: flex; flex-direction: column; gap: 12px; }
.circular-card .org { font-size: 0.8rem; font-weight: 700; color: var(--primary-ink); text-transform: uppercase; letter-spacing: 0.05em; }
.circular-card h3 { margin: 0; font-size: 1.08rem; }
.circular-meta { display: flex; gap: 16px; flex-wrap: wrap; font-size: 0.88rem; color: var(--text-2); }
.circular-meta strong { color: var(--text); }
.circular-actions { display: flex; gap: 10px; margin-top: auto; padding-top: 10px; flex-wrap: wrap; }
.circular-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }

/* ---------- Mission cards & map ---------- */
.mission-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.mission-card { display: flex; flex-direction: column; gap: 0; overflow: hidden; padding: 0; }
.mission-card-top { padding: 24px 24px 0; }
.mission-card-body { padding: 0 24px; flex: 1; }
.mission-card-foot { padding: 18px 24px 24px; margin-top: auto; }
.mission-subject { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--primary-ink); margin-bottom: 8px; }
.mission-card h3 { margin-bottom: 10px; font-size: 1.12rem; }
.mission-meta { display: flex; gap: 14px; flex-wrap: wrap; font-size: 0.85rem; color: var(--text-2); margin-bottom: 14px; }
.mission-meta span { display: inline-flex; align-items: center; gap: 6px; }
.mission-meta svg { width: 15px; height: 15px; }
.mission-progress { margin-bottom: 6px; }
.progress-track { height: 8px; background: var(--page); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #0AA583); border-radius: 999px; transition: width 0.5s ease; }
.mission-status-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mission-card.locked { opacity: 0.75; background: var(--page); }
.mission-card.completed { border-color: #BFE3D2; }
.mission-card.completed .mission-card-top { background: linear-gradient(180deg, var(--success-soft), transparent 90%); }

/* Mission map (path) */
.mission-map { max-width: 720px; margin: 0 auto; }
.map-subject { margin-bottom: 36px; }
.map-subject > h3 { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.map-subject > p { color: var(--text-2); font-size: 0.92rem; margin-bottom: 20px; }
.map-node {
  display: flex; gap: 18px; align-items: stretch; position: relative; padding-bottom: 8px;
}
.map-node::before {
  content: ""; position: absolute; left: 27px; top: 58px; bottom: -2px; width: 3px;
  background: var(--border); border-radius: 3px;
}
.map-node:last-child::before { display: none; }
.map-node.done::before { background: var(--primary); }
.map-badge {
  width: 58px; height: 58px; border-radius: 18px; flex-shrink: 0; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  background: var(--card); border: 2px solid var(--border); color: var(--text-2);
  box-shadow: var(--shadow-sm);
}
.map-badge svg { width: 26px; height: 26px; }
.map-node.done .map-badge { background: var(--primary); border-color: var(--primary); color: #fff; }
.map-node.current .map-badge { background: var(--gold); border-color: var(--gold); color: var(--heading); box-shadow: 0 0 0 6px var(--gold-soft); }
.map-node.locked .map-badge { background: var(--page); }
.map-card { flex: 1; margin-bottom: 26px; }
.map-card h4 { margin: 0 0 6px; font-size: 1.05rem; }

/* ---------- Gamification: XP, streak, level ---------- */
.xp-widget {
  display: flex; align-items: center; gap: 14px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 20px; box-shadow: var(--shadow-sm);
}
.level-badge {
  width: 52px; height: 52px; border-radius: 16px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center;
  font-weight: 800; line-height: 1.1;
}
.level-badge small { font-size: 0.6rem; font-weight: 700; opacity: 0.85; letter-spacing: 0.05em; }
.level-badge .lvl { font-size: 1.3rem; }
.xp-info { flex: 1; min-width: 0; }
.xp-info .xp-label { display: flex; justify-content: space-between; font-size: 0.85rem; font-weight: 700; margin-bottom: 6px; }
.xp-info .xp-label span:last-child { color: var(--text-2); font-weight: 600; }
.streak-chip {
  display: inline-flex; align-items: center; gap: 7px; flex-shrink: 0;
  background: var(--gold-soft); border: 1px solid #EFD9A0; color: #8A6A14;
  font-weight: 800; font-size: 0.92rem; padding: 9px 15px; border-radius: 999px;
}
.streak-chip svg { width: 18px; height: 18px; }
.streak-chip.zero { background: var(--page); border-color: var(--border); color: var(--text-2); }

/* Achievement badges */
.achievement-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.achievement {
  text-align: center; padding: 22px 14px; background: var(--card);
  border: 1px solid var(--border); border-radius: var(--radius);
}
.achievement .ach-icon {
  width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--gold-soft); border: 2px solid var(--gold);
}
.achievement .ach-icon svg { width: 26px; height: 26px; stroke: #8A6A14; }
.achievement.locked { opacity: 0.55; }
.achievement.locked .ach-icon { background: var(--page); border-color: var(--border); }
.achievement.locked .ach-icon svg { stroke: var(--text-2); }
.achievement strong { display: block; font-size: 0.92rem; color: var(--heading); }
.achievement small { color: var(--text-2); font-size: 0.8rem; }

/* XP toast */
.xp-toast {
  position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--heading); color: #fff; font-weight: 700; font-size: 0.95rem;
  padding: 14px 24px; border-radius: 999px; box-shadow: var(--shadow-lg);
  opacity: 0; pointer-events: none; transition: opacity 0.3s, transform 0.3s; z-index: 200;
  display: flex; align-items: center; gap: 10px;
}
.xp-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.xp-toast .xp-coin {
  width: 28px; height: 28px; border-radius: 50%; background: var(--gold);
  color: var(--heading); display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 800;
}

/* ---------- Reading page ---------- */
.reading-wrap { max-width: 780px; margin: 0 auto; }
.breadcrumb { display: flex; gap: 8px; align-items: center; font-size: 0.86rem; color: var(--text-2); margin-bottom: 20px; flex-wrap: wrap; }
.breadcrumb a { color: var(--text-2); }
.breadcrumb a:hover { color: var(--primary-ink); }
.breadcrumb .sep { opacity: 0.5; }
.reading-progress { position: sticky; top: 68px; z-index: 40; background: var(--page); padding: 10px 0; margin-bottom: 8px; }
.reading-progress .progress-track { height: 6px; }
.reading-head { margin-bottom: 28px; }
.reading-head h1 { font-size: 2rem; margin-bottom: 10px; }
.reading-tools { display: flex; gap: 8px; flex-wrap: wrap; margin: 18px 0 6px; }
.tool-btn {
  font-family: var(--font); font-size: 0.84rem; font-weight: 600;
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--card); border: 1px solid var(--border); border-radius: 999px;
  padding: 8px 15px; cursor: pointer; color: var(--text-2); min-height: 38px;
}
.tool-btn:hover { border-color: var(--primary); color: var(--primary-ink); }
.tool-btn.active { background: var(--heading); color: #fff; border-color: var(--heading); }
.tool-btn svg { width: 15px; height: 15px; }

.prose { font-size: 1.06rem; line-height: 1.85; color: var(--text); }
.prose h2 { font-size: 1.4rem; margin: 36px 0 14px; padding-top: 8px; }
.prose h3 { font-size: 1.12rem; margin: 28px 0 10px; }
.prose p { margin-bottom: 18px; }
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 24px; }
.prose li { margin-bottom: 8px; }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 20px; font-size: 0.95rem; }
.prose th, .prose td { border: 1px solid var(--border); padding: 10px 14px; text-align: left; }
.prose th { background: var(--soft-green); color: var(--heading); font-weight: 700; }

.fact-box {
  background: var(--soft-green); border: 1px solid #BFE0D2; border-radius: var(--radius);
  padding: 20px 22px; margin: 24px 0;
}
.fact-box h4 { margin: 0 0 10px; color: var(--primary-ink); font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.05em; }
.fact-box ul { margin: 0; padding-left: 20px; }
.fact-box li { margin-bottom: 6px; font-size: 0.97rem; }
.exam-note {
  background: var(--gold-soft); border: 1px solid #EFD9A0; border-left: 4px solid var(--gold);
  border-radius: 10px; padding: 16px 20px; margin: 24px 0; font-size: 0.96rem;
}
.exam-note strong { color: var(--heading); }
.memory-aid {
  background: var(--info-soft); border: 1px solid #CBDCF7; border-radius: var(--radius);
  padding: 18px 22px; margin: 24px 0; font-size: 0.96rem;
}
.memory-aid strong { color: var(--heading); }

/* Focus mode */
body.focus-mode .site-header,
body.focus-mode .site-footer,
body.focus-mode .reading-tools .tool-btn:not(#focusToggle),
body.focus-mode .breadcrumb,
body.focus-mode .mission-objectives { display: none; }
body.focus-mode { background: #fff; }
body.focus-mode .reading-wrap { max-width: 680px; }
body.focus-mode .prose { font-size: 1.14rem; line-height: 2; }

.mission-objectives {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px 24px; margin-bottom: 28px; box-shadow: var(--shadow-sm);
}
.mission-objectives h4 { margin: 0 0 12px; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-2); }
.objective { display: flex; gap: 10px; align-items: flex-start; padding: 7px 0; font-size: 0.95rem; }
.objective .obj-check {
  width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--border);
  flex-shrink: 0; margin-top: 2px; display: flex; align-items: center; justify-content: center; color: #fff;
}
.objective.done .obj-check { background: var(--success); border-color: var(--success); }
.objective.done { color: var(--text-2); }

.reading-nav { display: flex; justify-content: space-between; gap: 12px; margin: 40px 0 0; flex-wrap: wrap; }
.quiz-embed { margin-top: 40px; }

/* ---------- Practice (existing, kept) ---------- */
.practice-layout { display: grid; grid-template-columns: 270px 1fr; gap: 24px; align-items: start; }
.sidebar {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; position: sticky; top: 92px;
}
.sidebar h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-2); margin: 0 0 12px; }
.sidebar .topic-list { list-style: none; margin: 0 0 24px; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.sidebar .topic-list button {
  width: 100%; text-align: left; font-family: var(--font); font-size: 0.92rem; font-weight: 600;
  padding: 10px 12px; border: 0; border-radius: var(--radius-sm); background: none; color: var(--text-2); cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; min-height: 44px;
}
.sidebar .topic-list button:hover { background: var(--page); color: var(--heading); }
.sidebar .topic-list button.active { background: var(--soft-green); color: var(--primary-ink); }
.sidebar .topic-list .count { font-size: 0.76rem; background: var(--page); border: 1px solid var(--border); padding: 2px 9px; border-radius: 999px; }
.sidebar .topic-list button.active .count { background: #fff; }

.question-card { margin-bottom: 20px; }
.question-card .q-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; align-items: center; }
.question-card .q-text { font-size: 1.06rem; font-weight: 600; margin-bottom: 16px; color: var(--heading); }
.options { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.option {
  display: flex; gap: 12px; align-items: flex-start; text-align: left;
  font-family: var(--font); font-size: 0.96rem;
  background: var(--card); border: 1.5px solid var(--border); border-radius: 12px;
  padding: 13px 16px; cursor: pointer; width: 100%; color: var(--text); min-height: 52px;
}
.option:hover:not(:disabled) { border-color: var(--primary); }
.option .opt-letter {
  flex-shrink: 0; width: 28px; height: 28px; border-radius: 8px; background: var(--page);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.85rem; color: var(--text-2);
}
.option:disabled { cursor: default; opacity: 0.97; }
.option.correct { border-color: var(--success); background: var(--success-soft); }
.option.correct .opt-letter { background: var(--success); border-color: var(--success); color: #fff; }
.option.wrong { border-color: var(--error); background: var(--error-soft); }
.option.wrong .opt-letter { background: var(--error); border-color: var(--error); color: #fff; }
.explanation {
  margin-top: 12px; padding: 15px 17px; background: var(--page);
  border: 1px solid var(--border); border-left: 4px solid var(--primary);
  border-radius: 10px; font-size: 0.93rem; color: var(--text-2);
}
.explanation strong { color: var(--heading); }
.review-btn {
  margin-top: 12px; font-family: var(--font); font-size: 0.86rem; font-weight: 600;
  background: none; border: 0; color: var(--text-2); cursor: pointer; padding: 6px 0;
  display: inline-flex; align-items: center; gap: 6px; min-height: 36px;
}
.review-btn:hover { color: var(--primary-ink); }
.review-btn.flagged { color: var(--warning); }
.review-btn svg { width: 16px; height: 16px; }

/* ---------- Mock test (existing, kept) ---------- */
.mock-setup { max-width: 580px; margin: 0 auto; }
.setup-list { list-style: none; padding: 0; margin: 0 0 24px; }
.setup-list li { display: flex; gap: 12px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: 0.95rem; }
.setup-list li:last-child { border-bottom: 0; }
.setup-list svg { width: 20px; height: 20px; stroke: var(--primary); flex-shrink: 0; }
.mock-layout { display: grid; grid-template-columns: 1fr 250px; gap: 24px; align-items: start; }
.timer-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 15px 22px; margin-bottom: 20px; box-shadow: var(--shadow-sm);
}
.timer { font-size: 1.45rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--heading); }
.timer.low { color: var(--error); }
.palette { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; position: sticky; top: 92px; }
.palette h4 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-2); margin: 0 0 12px; }
.palette-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.palette-grid button {
  font-family: var(--font); font-weight: 700; font-size: 0.85rem;
  aspect-ratio: 1; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--card); color: var(--text-2); cursor: pointer; min-height: 40px;
}
.palette-grid button.answered { background: var(--soft-green); border-color: var(--primary); color: var(--primary-ink); }
.palette-grid button.current { background: var(--heading); border-color: var(--heading); color: #fff; }
.mock-nav { display: flex; justify-content: space-between; margin-top: 20px; gap: 12px; flex-wrap: wrap; }
.result-score { text-align: center; padding: 16px 0 8px; }
.result-score .score-num { font-size: 3.5rem; font-weight: 800; letter-spacing: -0.03em; color: var(--heading); }
.result-score .score-sub { color: var(--text-2); }
.topic-bar-row { display: grid; grid-template-columns: 170px 1fr 64px; gap: 12px; align-items: center; margin-bottom: 12px; font-size: 0.9rem; }
.topic-bar-track { height: 10px; background: var(--page); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.topic-bar-fill { height: 100%; background: var(--primary); border-radius: 999px; transition: width 0.4s; }
.topic-bar-row .pct { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ---------- Progress (existing, kept) ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 32px; }
.stat-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm); }
.stat-card .stat-num { font-size: 2.2rem; font-weight: 800; letter-spacing: -0.02em; color: var(--heading); }
.stat-card .stat-label { color: var(--text-2); font-size: 0.88rem; font-weight: 600; }
.history-list { list-style: none; margin: 0; padding: 0; }
.history-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--border); font-size: 0.95rem; }
.history-list li:last-child { border-bottom: 0; }
.empty-state {
  text-align: center; padding: 60px 24px; background: var(--card);
  border: 1.5px dashed var(--border); border-radius: var(--radius); color: var(--text-2);
}
.empty-state svg { width: 48px; height: 48px; stroke: var(--border); margin-bottom: 16px; }
.empty-state h3 { color: var(--heading); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--card); margin-top: 72px; padding: 56px 0 32px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 36px; }
.footer-grid h4 { font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-2); margin-bottom: 15px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.footer-grid a { color: var(--text-2); font-size: 0.92rem; }
.footer-grid a:hover { color: var(--primary-ink); }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 26px; border-top: 1px solid var(--border); font-size: 0.84rem; color: var(--text-2); }

/* ---------- Reminder banner / checklist / readiness (v2, kept) ---------- */
.reminder-banner { background: var(--warning-soft); border-bottom: 2px solid #F59E0B; padding: 12px 0; }
.reminder-banner strong:first-child { color: #92400E; }
.reminder-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid #FDE68A; font-size: 0.95rem; }
.reminder-row:first-of-type { border-top: none; }
.reminder-actions { display: flex; align-items: center; gap: 12px; padding-top: 8px; flex-wrap: wrap; }
.checklist { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 10px; }
.checklist summary { cursor: pointer; font-weight: 700; color: var(--primary-ink); }
.checklist summary:hover { text-decoration: underline; }
.checklist-count { font-weight: 600; color: var(--text-2); font-size: 0.85rem; margin-left: 6px; }
.checklist-items { padding: 8px 0 4px; }
.checklist-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; cursor: pointer; font-size: 0.95rem; min-height: 40px; }
.checklist-item input[type="checkbox"] { width: 19px; height: 19px; accent-color: var(--primary); cursor: pointer; flex-shrink: 0; }
.readiness-card { margin-bottom: 24px; }
.readiness-top { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.score-ring-wrap { position: relative; width: 132px; height: 132px; flex-shrink: 0; }
.score-ring { width: 132px; height: 132px; }
.ring-bg { fill: none; stroke: var(--border); stroke-width: 11; }
.ring-fg { fill: none; stroke-width: 11; stroke-linecap: round; transition: stroke-dashoffset 0.5s; }
.score-num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 2rem; font-weight: 800; color: var(--heading); }
.readiness-info { flex: 1 1 220px; }
.readiness-info h3 { margin-bottom: 4px; }
.verdict { font-size: 1.25rem; font-weight: 800; margin: 0 0 8px; }

/* ---------- Google auth (kept) ---------- */
.auth-area { display: flex; align-items: center; margin-left: 0; }
.auth-area:empty { display: none; }
.google-btn { display: inline-flex; align-items: center; gap: 8px; background: #fff; color: var(--text); border: 1px solid var(--border); }
.google-btn:hover { background: #f8fafc; }
.user-chip { display: inline-flex; align-items: center; gap: 8px; font-size: 0.85rem; font-weight: 600; }
.user-chip img { border-radius: 50%; }
.user-chip button { background: none; border: none; color: var(--text-2); font-size: 0.8rem; cursor: pointer; text-decoration: underline; padding: 6px; min-height: 36px; }
.auth-error { color: #b91c1c; font-size: 0.8rem; margin-top: 6px; max-width: 240px; }

/* ---------- Note boxes / about (kept) ---------- */
.note-box { background: var(--warning-soft); border: 1px solid #F0DFB8; border-radius: 12px; padding: 18px 20px; font-size: 0.92rem; color: #7A5A1E; }
.note-box strong { color: var(--heading); }
.note-box.blue { background: var(--info-soft); border-color: #CBDFF5; color: #2B4E7E; }
.note-box.green { background: var(--success-soft); border-color: #BFE3D2; color: #14532D; }
.pipeline-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 28px 0; }
.pipeline-step { background: var(--card); border: 1px solid var(--border); border-radius: 12px; padding: 20px; }
.pipeline-step .step-tag { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.07em; color: var(--primary-ink); margin-bottom: 8px; }
.pipeline-step h4 { margin: 0 0 6px; font-size: 1rem; }
.pipeline-step p { font-size: 0.88rem; color: var(--text-2); margin: 0; }
.about-section { max-width: 780px; }
.about-section p, .about-section li { color: var(--text-2); }
.about-section h2 { margin-top: 40px; }
.about-section ul { padding-left: 20px; }
.roadmap { list-style: none; padding: 0; margin: 0; }
.roadmap li { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--border); align-items: flex-start; }
.roadmap li:last-child { border-bottom: 0; }
.roadmap .status { flex-shrink: 0; font-size: 0.76rem; font-weight: 700; padding: 5px 12px; border-radius: 999px; height: fit-content; }
.status.done { background: var(--success-soft); color: var(--success); }
.status.next { background: var(--soft-green); color: var(--primary-ink); }
.status.later { background: var(--page); border: 1px solid var(--border); color: var(--text-2); }
.step-num { width: 40px; height: 40px; border-radius: 50%; background: var(--heading); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 800; margin-bottom: 16px; }

/* ---------- Page head ---------- */
.page-head { padding: 48px 0 8px; }
.page-head h1 { margin-bottom: 8px; }
.page-head p { color: var(--text-2); max-width: 640px; margin-bottom: 0; }

/* ---------- Saved / profile ---------- */
.saved-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.profile-card { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.avatar-lg { width: 72px; height: 72px; border-radius: 50%; background: var(--soft-green); display: flex; align-items: center; justify-content: center; font-size: 1.8rem; font-weight: 800; color: var(--primary-ink); overflow: hidden; flex-shrink: 0; }
.avatar-lg img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .mission-grid { grid-template-columns: 1fr 1fr; }
  .achievement-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 960px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .pipeline-steps { grid-template-columns: 1fr 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .mock-layout { grid-template-columns: 1fr; }
  .palette { position: static; }
  .palette-grid { grid-template-columns: repeat(10, 1fr); }
  .practice-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero h1 { font-size: 2.4rem; }
}
@media (max-width: 860px) {
  .nav {
    display: none; position: absolute; top: 68px; left: 0; right: 0; z-index: 60;
    background: var(--card); border-bottom: 1px solid var(--border);
    flex-direction: column; align-items: stretch; padding: 12px 16px 16px; gap: 2px;
    box-shadow: var(--shadow);
  }
  .nav.open { display: flex; }
  .nav a { padding: 13px 14px; font-size: 1rem; }
  .nav-cta { margin: 10px 0 0; }
  .hamburger { display: block; }
  .auth-area { margin-left: auto; }
}
@media (max-width: 640px) {
  h1 { font-size: 1.9rem; }
  .hero { padding: 60px 0 52px; }
  .hero h1 { font-size: 2rem; }
  .grid-4, .grid-3, .grid-2, .circular-grid, .mission-grid, .saved-grid { grid-template-columns: 1fr; }
  .pipeline-steps { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .achievement-grid { grid-template-columns: 1fr 1fr; }
  .topic-bar-row { grid-template-columns: 110px 1fr 56px; }
  .footer-grid { grid-template-columns: 1fr; }
  .palette-grid { grid-template-columns: repeat(8, 1fr); }
  .hero-search { flex-direction: column; }
  .hero-search svg { display: none; }
  .hero-search input { padding: 15px 18px; }
  .hero-search button { border-radius: 0 0 12px 12px; }
  .section { padding: 48px 0; }
  .xp-widget { flex-wrap: wrap; }
  .reading-progress { top: 68px; }
  .readiness-top { gap: 16px; }
  .score-ring-wrap, .score-ring { width: 104px; height: 104px; }
  .score-num { font-size: 1.6rem; }
}

/* ---------- Forms (profile settings) ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 16px; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-weight: 600; font-size: 0.9rem; color: var(--heading); }
.input { font: inherit; font-size: 1rem; color: var(--text); background: var(--card); border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 10px 14px; width: 100%; transition: border-color var(--t-fast), box-shadow var(--t-fast); }
.input:focus { outline: none; border-color: var(--primary); box-shadow: var(--focus-ring); }
.checkbox-row { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--heading); cursor: pointer; }
.checkbox-row input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--primary); cursor: pointer; flex-shrink: 0; }

/* ---------- Footer "last updated" ---------- */
.footer-updated { display: inline-flex; align-items: center; gap: 6px; color: var(--primary-ink); font-weight: 600; font-size: 0.85rem; }
.footer-updated::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--success); flex-shrink: 0; }
