:root {
  --bg: #F7F9FB;
  --surface: #FFFFFF;
  --surface-alt: #F1F5F9;
  --ink: #0B1324;
  --muted: #475569;
  --subtle: #64748B;
  --brand: #0B6E4F;
  --brand-dark: #074F38;
  --brand-soft: #EAF6F0;
  --accent: #D97706;
  --accent-soft: #FEF3C7;
  --danger: #B91C1C;
  --danger-soft: #FEE2E2;
  --border: #E2E8F0;
  --border-strong: #CBD5E1;
  --shadow-sm: 0 1px 2px rgba(11, 19, 36, 0.05);
  --shadow-lg: 0 20px 44px -14px rgba(11, 19, 36, 0.14), 0 4px 12px rgba(11, 19, 36, 0.05);
  --radius: 14px;
  --max-w: 1160px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--brand);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header & Preserved Text-Based Logo */
.site-header {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 40;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 70px;
  position: relative;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}

.menu-toggle:hover {
  background: var(--surface-alt);
}

.header-spacer {
  display: none;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0;
  text-decoration: none;
  letter-spacing: -0.03em;
  line-height: 1;
  white-space: nowrap;
}

.brand-logo:hover {
  text-decoration: none;
}

.brand-logo .logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: var(--brand);
  color: #FFFFFF;
  font-size: 0.92rem;
  font-weight: 800;
  margin-right: 10px;
  position: relative;
  flex-shrink: 0;
}

.brand-logo .logo-mark::before {
  content: "T";
}

.brand-logo .logo-mark::after {
  content: "";
  position: absolute;
  right: 4px;
  bottom: 4px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #FBBF24;
}

.brand-logo .logo-primary {
  font-size: 1.24rem;
  font-weight: 800;
  color: var(--ink);
}

.brand-logo .logo-accent {
  font-size: 1.24rem;
  font-weight: 700;
  color: var(--brand);
}

.brand-logo .logo-tld {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--subtle);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.main-nav a {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav a[aria-current="page"] {
  color: var(--brand);
  text-decoration: none;
}

.nav-cta {
  background: var(--brand);
  color: #FFFFFF !important;
  padding: 9px 17px;
  border-radius: 8px;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}

.nav-cta:hover {
  background: var(--brand-dark);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 20px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.94rem;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
  white-space: nowrap;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  text-decoration: none;
}

.btn-primary {
  background: var(--brand);
  color: #FFFFFF;
  box-shadow: 0 6px 16px -4px rgba(11, 110, 79, 0.35);
}

.btn-primary:hover {
  background: var(--brand-dark);
}

.btn-secondary {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background: var(--surface-alt);
}

/* Redesigned Hero */
.hero {
  padding: 60px 0 68px;
  background:
    radial-gradient(760px 440px at 92% 10%, rgba(11, 110, 79, 0.09), transparent 70%),
    radial-gradient(620px 360px at 8% 90%, rgba(11, 19, 36, 0.04), transparent 70%),
    #FFFFFF;
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: 48px;
  align-items: center;
}

.region-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--brand);
  background: var(--brand-soft);
  border: 1px solid rgba(11, 110, 79, 0.2);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

.region-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand);
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.15rem, 3.9vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.035em;
  color: var(--ink);
}

.hero-lead {
  margin: 0 0 28px;
  font-size: 1.08rem;
  color: var(--muted);
  max-width: 52ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}

.hero-features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

.hero-feature {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-feature svg {
  color: var(--brand);
  flex-shrink: 0;
}

/* Read-Only Image Question Previewer */
.sim-window {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  pointer-events: none;
  user-select: none;
}

.sim-body {
  padding: 22px 24px 24px;
}

.sim-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand);
  margin-bottom: 14px;
}

.sim-question-row {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.sim-visual {
  width: 104px;
  height: 104px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 6px;
  flex-shrink: 0;
}

.sample-q {
  font-size: 1.04rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0;
  color: var(--ink);
}

.sample-opts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sample-opt {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 9px;
  font-size: 0.9rem;
  text-align: left;
  width: 100%;
  font-family: inherit;
  color: var(--ink);
}

button.sample-opt {
  cursor: pointer;
  transition: border-color 0.12s ease, background-color 0.12s ease;
}

button.sample-opt:hover {
  border-color: var(--brand);
  background: var(--surface);
}

.sample-opt.is-correct {
  background: var(--brand-soft);
  border-color: var(--brand);
}

.sample-opt.is-wrong {
  background: var(--danger-soft);
  border-color: var(--danger);
}

.opt-key {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  font-weight: 700;
  font-size: 0.78rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.sample-opt.is-correct .opt-key {
  background: var(--brand);
  border-color: var(--brand);
  color: #FFFFFF;
}

.sample-explain {
  margin-top: 12px;
  font-size: 0.86rem;
  color: var(--muted);
  background: var(--brand-soft);
  border-left: 3px solid var(--brand);
  padding: 10px 13px;
  border-radius: 0 8px 8px 0;
}

/* Sections */
.section {
  padding: 68px 0;
}

.section-alt {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-header {
  max-width: 64ch;
  margin-bottom: 34px;
}

.section-header h2 {
  margin: 0 0 10px;
  font-size: clamp(1.55rem, 2.7vw, 2.05rem);
  letter-spacing: -0.025em;
  line-height: 1.2;
}

.section-header p {
  margin: 0;
  color: var(--muted);
  font-size: 1.02rem;
}

/* Study Pathways (Replaces Coming Soon Region/Vehicle Grid) */
.pathway-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.pathway-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 22px;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pathway-card:hover {
  border-color: var(--brand);
  box-shadow: 0 10px 26px -12px rgba(11, 110, 79, 0.25);
}

.pathway-card.is-primary {
  background: linear-gradient(160deg, #0B1324 0%, #093C2C 100%);
  border-color: #0B1324;
  color: #FFFFFF;
}

.pathway-card.is-primary p {
  color: rgba(255, 255, 255, 0.8);
}

.pathway-card.is-primary .v-icon {
  background: rgba(255, 255, 255, 0.14);
  color: #6EE7B7;
}

.pathway-card.is-primary .pathway-link {
  color: #6EE7B7;
}

.v-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.pathway-card h3 {
  margin: 0 0 8px;
  font-size: 1.08rem;
  line-height: 1.3;
}

.pathway-card p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
}

.pathway-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 18px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--brand);
}

/* Bento Study Modes */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.bento-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
}

.bento-card.featured {
  background: #0B1324;
  color: #FFFFFF;
  border-color: #0B1324;
}

.bento-card.featured p {
  color: rgba(255, 255, 255, 0.78);
}

.bento-card h3 {
  margin: 14px 0 8px;
  font-size: 1.15rem;
}

.bento-card p {
  margin: 0;
  font-size: 0.94rem;
  color: var(--muted);
}

.bento-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.bento-card.featured .bento-icon {
  background: rgba(11, 110, 79, 0.35);
  color: #6EE7B7;
}

/* Clean Topic Links (No Counts) */
.section:not(.section-alt) .bento-card:not(.featured),
.section:not(.section-alt) .guide-box {
  background: var(--surface);
}

.section-alt .topic-item {
  background: var(--bg);
}

/* Essential Road Signs Quick Guide */
.signs-header-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.signs-header-row .section-header {
  margin-bottom: 0;
}

.signs-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.signs-more-link {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brand);
  padding: 8px 6px;
  white-space: nowrap;
}

.signs-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.sign-card {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.sign-card:hover {
  border-color: var(--brand);
  box-shadow: 0 10px 26px -14px rgba(11, 110, 79, 0.25);
}

.sign-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}

.sign-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.sign-badge--regulatory {
  background: #FEE2E2;
  color: #991B1B;
}

.sign-badge--warning {
  background: #FEF3C7;
  color: #92400E;
}

.sign-badge--temporary {
  background: #FFEDD5;
  color: #9A3412;
}

.sign-badge--mandatory {
  background: #DBEAFE;
  color: #1E40AF;
}

.sign-shape-note {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--subtle);
}

.sign-thumb {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  height: 126px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  margin-bottom: 16px;
}

.sign-thumb img {
  max-width: 94px;
  max-height: 94px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.sign-meaning {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.sign-meaning h3 {
  margin: 0 0 6px;
  font-size: 1.05rem;
  line-height: 1.3;
  color: var(--ink);
}

.sign-meaning p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.5;
}

.sign-timer {
  display: none;
  margin-top: 10px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--brand);
}

.sign-card.is-revealed .sign-timer {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.sign-reveal-cover {
  display: none;
}

.signs-grid.is-quiz-mode .sign-card:not(.is-revealed) .sign-meaning > h3,
.signs-grid.is-quiz-mode .sign-card:not(.is-revealed) .sign-meaning > p {
  visibility: hidden;
}

.signs-grid.is-quiz-mode .sign-card:not(.is-revealed) .sign-thumb {
  cursor: pointer;
}

.signs-grid.is-quiz-mode .sign-card:not(.is-revealed) .sign-reveal-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  inset: 0;
  border-radius: 10px;
  border: 1px dashed var(--border-strong);
  background: var(--surface);
  color: var(--brand);
  font-family: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  cursor: pointer;
  padding: 10px;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.signs-grid.is-quiz-mode .sign-card:not(.is-revealed) .sign-reveal-cover:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}

.topic-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 14px;
}

.topic-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 20px 22px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--ink);
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}

.topic-item:hover {
  border-color: var(--brand);
  text-decoration: none;
}

.topic-sub {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  margin-top: 4px;
}

.topic-go {
  font-size: 0.86rem;
  color: var(--brand);
  font-weight: 700;
  white-space: nowrap;
}

/* Editorial Exam Guide */
.guide-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 36px;
  align-items: start;
}

.guide-copy h3 {
  margin: 22px 0 8px;
  font-size: 1.12rem;
}

.guide-copy h3:first-child {
  margin-top: 0;
}

.guide-copy p {
  margin: 0 0 12px;
  color: var(--muted);
}

.guide-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.guide-box h3 {
  margin: 0 0 14px;
  font-size: 1.06rem;
}

.guide-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
  font-size: 0.92rem;
  color: var(--muted);
}

.guide-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--border);
}

.guide-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.guide-list strong {
  color: var(--ink);
}

/* CTA Banner */
.cta-band {
  background: linear-gradient(135deg, #0B1324 0%, #0A3D2C 100%);
  color: #FFFFFF;
  border-radius: 18px;
  padding: 40px 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}

.cta-band h2 {
  margin: 0 0 8px;
  font-size: 1.7rem;
  letter-spacing: -0.025em;
}

.cta-band p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  max-width: 52ch;
}

/* FAQ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 78ch;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 22px;
}

.faq-item summary {
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  font-size: 1.2rem;
  color: var(--brand);
  font-weight: 700;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Legal & Document Pages */
.doc-wrap {
  max-width: 78ch;
  margin: 0 auto;
  padding: 40px 20px 72px;
}

.doc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 36px 40px;
}

.doc-card h1 {
  margin: 0 0 8px;
  font-size: 2rem;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.doc-meta {
  color: var(--subtle);
  font-size: 0.9rem;
  margin-bottom: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.doc-card h2 {
  margin: 28px 0 10px;
  font-size: 1.25rem;
  color: var(--ink);
}

.doc-card h3 {
  margin: 18px 0 8px;
  font-size: 1.04rem;
  color: var(--ink);
}

.doc-card p,
.doc-card li {
  color: var(--muted);
  font-size: 0.97rem;
}

.doc-card ul,
.doc-card ol {
  padding-left: 22px;
}

.doc-card li {
  margin-bottom: 6px;
}

.notice-box {
  background: var(--brand-soft);
  border-left: 4px solid var(--brand);
  padding: 14px 16px;
  border-radius: 0 8px 8px 0;
  margin: 18px 0;
  font-size: 0.94rem;
  color: var(--ink);
}

/* Quiz Runner */
.quiz-shell {
  max-width: 820px;
  margin: 0 auto;
  padding: 32px 20px 72px;
}

.quiz-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin-bottom: 18px;
}

.timer-pill {
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}

/* Topic Practice Controls & Progress */
.practice-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
  width: 100%;
}

.practice-chip {
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.practice-chip.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #FFFFFF;
}

.progress-track {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: var(--surface-alt);
  overflow: hidden;
  margin-bottom: 16px;
}

.progress-fill {
  height: 100%;
  background: var(--brand);
  border-radius: 999px;
  transition: width 0.2s ease;
}

.keypoint-box {
  margin-top: 10px;
  font-size: 0.88rem;
  color: #78350F;
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  padding: 9px 13px;
  border-radius: 0 8px 8px 0;
}

/* Topic Practice Setup Picker */
.setup-section-title {
  margin: 0 0 10px;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--muted);
}

.setup-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 20px;
}

.setup-choice {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.14s ease, background-color 0.14s ease;
}

.setup-choice:hover {
  border-color: var(--brand);
  background: var(--surface);
  text-decoration: none;
}

.setup-choice.active {
  background: var(--brand-soft);
  border-color: var(--brand);
  box-shadow: 0 0 0 1px var(--brand);
}

.setup-choice strong {
  font-size: 0.96rem;
  color: var(--ink);
}

.setup-choice span {
  font-size: 0.83rem;
  color: var(--muted);
}

.setup-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

/* Floating Scroll-to-Top Arrow Button */
.scroll-top-btn {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(11, 19, 36, 0.12);
  background: var(--brand);
  color: #FFFFFF;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 10px 24px -6px rgba(11, 19, 36, 0.32);
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.18s ease, transform 0.18s ease, background-color 0.15s ease;
  z-index: 50;
}

.scroll-top-btn.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.scroll-top-btn:hover {
  background: var(--brand-dark);
}

/* Firebase Auth Modal & Account Controls */
.nav-auth-btn {
  background: var(--surface);
  color: var(--ink) !important;
  border: 1px solid var(--border-strong);
  padding: 8px 14px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}

.nav-auth-btn:hover {
  background: var(--surface-alt);
}

.nav-auth-btn.is-signed-in {
  background: var(--brand-soft);
  border-color: rgba(11, 110, 79, 0.3);
  color: var(--brand) !important;
}

.auth-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(11, 19, 36, 0.62);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 100;
}

.auth-modal {
  width: 100%;
  max-width: 440px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.auth-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}

.auth-close:hover {
  background: var(--surface-alt);
  color: var(--ink);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: var(--surface-alt);
  padding: 4px;
  border-radius: 10px;
  margin-bottom: 18px;
}

.auth-tab {
  border: none;
  background: transparent;
  padding: 8px 12px;
  border-radius: 7px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
}

.auth-tab.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.auth-field {
  margin-bottom: 12px;
}

.auth-field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--ink);
}

.auth-field input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  font: inherit;
  font-size: 0.94rem;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  color: var(--subtle);
  font-size: 0.82rem;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-error {
  background: var(--danger-soft);
  color: var(--danger);
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 0.86rem;
  margin-bottom: 12px;
}

.auth-success {
  background: var(--brand-soft);
  color: var(--brand-dark);
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 0.86rem;
  margin-bottom: 12px;
}

.auth-gate {
  text-align: center;
  padding: 18px 8px;
}

.auth-gate h2 {
  margin: 0 0 8px;
  font-size: 1.45rem;
}

.auth-gate p {
  margin: 0 auto 20px;
  color: var(--muted);
  max-width: 48ch;
}

.auth-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pw-meter-wrap {
  margin-top: 6px;
}

.pw-meter-bar {
  height: 5px;
  border-radius: 999px;
  background: var(--surface-alt);
  overflow: hidden;
}

.pw-meter-fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  transition: width 0.15s ease, background-color 0.15s ease;
}

.pw-meter-label {
  font-size: 0.78rem;
  font-weight: 700;
  margin-top: 4px;
  color: var(--muted);
}

.pw-match-msg {
  font-size: 0.78rem;
  font-weight: 700;
  margin-top: 4px;
}

.auth-check-row {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 12px 0 14px;
  font-size: 0.84rem;
  color: var(--muted);
}

.auth-check-row input {
  margin-top: 3px;
  width: 16px;
  height: 16px;
  accent-color: var(--brand);
  flex-shrink: 0;
}

@media (max-width: 480px) {
  .auth-row-2 {
    grid-template-columns: 1fr;
  }
}

.otp-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 8px;
}

.otp-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border-strong);
  border-radius: 10px;
  font-family: inherit;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.36em;
  text-align: center;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--bg);
}

.otp-input::placeholder {
  color: #94A3B8;
  opacity: 0.7;
}

.otp-input:focus {
  border-color: var(--brand);
  background: var(--surface);
  outline: none;
  box-shadow: 0 0 0 3px rgba(11, 110, 79, 0.12);
}

.otp-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0 18px;
  font-size: 0.84rem;
}

.otp-timer-inline {
  color: var(--muted);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.otp-timer-inline strong {
  color: var(--ink);
  font-weight: 800;
}

.otp-timer-inline.is-expired,
.otp-timer-inline.is-expired strong {
  color: var(--danger);
}

.otp-resend-link {
  border: none;
  background: none;
  padding: 0;
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  color: #1D4ED8;
  cursor: pointer;
}

.otp-resend-link:hover:not(:disabled) {
  text-decoration: underline;
}

.otp-resend-link:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.otp-back-wrap {
  margin-top: 16px;
  text-align: center;
}

.otp-back-link {
  border: none;
  background: none;
  padding: 4px 8px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}

.otp-back-link:hover {
  color: var(--ink);
}

.dev-otp-banner {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #FFFBEB;
  border: 1px dashed #D97706;
  color: #92400E;
  font-size: 0.84rem;
  text-align: center;
}

.dev-otp-banner code {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #78350F;
}

.account-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.account-stat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 8px;
  text-align: center;
}

.account-stat-card span {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 2px;
}

.account-stat-card strong {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--ink);
}

@media (max-width: 480px) {
  .account-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Dedicated Auth Pages (/signup & /signin) & Animated Driving Scene */
.auth-main {
  padding: 40px 0 64px;
  min-height: calc(100vh - 140px);
  display: flex;
  align-items: center;
  background:
    radial-gradient(680px 380px at 88% 12%, rgba(11, 110, 79, 0.08), transparent 70%),
    radial-gradient(560px 340px at 10% 88%, rgba(11, 19, 36, 0.05), transparent 70%),
    var(--bg);
}

.auth-shell {
  display: grid;
  grid-template-columns: 0.96fr 1.04fr;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  max-width: 1020px;
  margin: 0 auto;
}

.auth-showcase {
  background: linear-gradient(155deg, #0B1324 0%, #093C2C 62%, #0B6E4F 100%);
  color: #FFFFFF;
  padding: 36px 34px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  position: relative;
}

.auth-showcase-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #A7F3D0;
  font-size: 0.78rem;
  font-weight: 700;
}

.auth-showcase h1 {
  margin: 0 0 10px;
  font-size: clamp(1.55rem, 2.4vw, 2rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: #FFFFFF;
}

.auth-showcase-lead {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.94rem;
  line-height: 1.55;
}

.drive-stage {
  background: linear-gradient(180deg, rgba(7, 17, 36, 0.65) 0%, rgba(11, 31, 46, 0.85) 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 14px 14px 10px;
  position: relative;
  overflow: hidden;
}

.drive-stage-badge {
  position: absolute;
  top: 10px;
  left: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(11, 19, 36, 0.72);
  border: 1px solid rgba(110, 231, 183, 0.25);
  color: #6EE7B7;
  font-size: 0.72rem;
  font-weight: 700;
}

.drive-stage-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #FBBF24;
  animation: driveBeamPulse 1.4s ease-in-out infinite;
}

.drive-svg {
  width: 100%;
  height: auto;
  display: block;
}

.drive-hills {
  animation: driveHillsScroll 9s linear infinite;
}

.drive-signpost {
  animation: driveSignScroll 5.5s linear infinite;
}

.drive-road-lines {
  animation: driveDashScroll 0.85s linear infinite;
}

.drive-car-group {
  animation: driveCarBob 0.7s ease-in-out infinite alternate;
}

.drive-wheel {
  transform-box: fill-box;
  transform-origin: center;
  animation: driveWheelRotate 0.65s linear infinite;
}

.drive-beam {
  animation: driveBeamPulse 1.8s ease-in-out infinite;
}

@keyframes driveDashScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-64px); }
}

@keyframes driveHillsScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-180px); }
}

@keyframes driveSignScroll {
  from { transform: translateX(260px); }
  to { transform: translateX(-340px); }
}

@keyframes driveCarBob {
  from { transform: translateY(0); }
  to { transform: translateY(-2.5px); }
}

@keyframes driveWheelRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes driveBeamPulse {
  0%, 100% { opacity: 0.88; }
  50% { opacity: 0.55; }
}

.auth-perks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.86);
}

.auth-perks li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.auth-perks svg {
  color: #6EE7B7;
  flex-shrink: 0;
}

.auth-panel {
  padding: 36px 40px;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-panel h2 {
  margin: 0 0 6px;
  font-size: 1.55rem;
  letter-spacing: -0.025em;
  color: var(--ink);
}

.auth-panel-sub {
  margin: 0 0 20px;
  font-size: 0.92rem;
  color: var(--muted);
}

.auth-switch-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: var(--surface-alt);
  padding: 4px;
  border-radius: 10px;
  margin-bottom: 20px;
}

.auth-switch-link {
  text-align: center;
  padding: 8px 12px;
  border-radius: 7px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
  transition: background-color 0.14s ease, color 0.14s ease;
}

.auth-switch-link:hover {
  color: var(--ink);
  text-decoration: none;
}

.auth-switch-link.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.auth-panel .auth-field input:focus {
  border-color: var(--brand);
  outline: none;
  box-shadow: 0 0 0 3px rgba(11, 110, 79, 0.12);
}

.auth-footer-note {
  margin: 16px 0 0;
  text-align: center;
  font-size: 0.86rem;
  color: var(--muted);
}

.auth-footer-note a {
  font-weight: 700;
  color: var(--brand);
}

.verify-badge-icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: var(--brand-soft);
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.btn-spinner {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #FFFFFF;
  animation: btnSpin 0.7s linear infinite;
  display: inline-block;
}

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

/* Results Upgrade & Submit Confirm Modals */
.result-popup-score {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 6px 0 6px;
  color: var(--ink);
}

.result-popup-list {
  list-style: none;
  margin: 14px 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--muted);
}

.result-popup-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.locked-review-card {
  margin-top: 20px;
  background: linear-gradient(180deg, #F8FAFC 0%, #EAF6F0 100%);
  border: 1px dashed var(--brand);
  border-radius: 12px;
  padding: 26px 22px;
  text-align: center;
}

.locked-review-card h3 {
  margin: 0 0 8px;
  font-size: 1.2rem;
}

.locked-review-card p {
  margin: 0 auto 18px;
  color: var(--muted);
  max-width: 50ch;
  font-size: 0.94rem;
}

.quiz-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 26px;
}

.quiz-img {
  margin: 14px 0;
  text-align: center;
}

.quiz-img img {
  max-width: 100%;
  max-height: 320px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.quiz-practice-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.quiz-counter-text {
  font-size: 0.86rem;
  color: var(--muted);
  font-weight: 600;
}

.quiz-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.quiz-category-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
}

.quiz-meta-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.quiz-step-pill {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.quiz-mini-btn {
  padding: 5px 11px;
  font-size: 0.8rem;
}

.quiz-mini-btn.is-flagged-btn {
  background: #FFFBEB;
  border-color: #F59E0B;
  color: #B45309;
}

.quiz-mini-btn.is-saved-btn {
  background: var(--brand-soft);
  border-color: var(--brand);
  color: var(--brand);
}

.quiz-question-title {
  margin: 0 0 14px;
  font-size: 1.22rem;
  line-height: 1.38;
  color: var(--ink);
}

.quiz-footer-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.quiz-footer-nav,
.quiz-footer-end {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .quiz-footer-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .quiz-footer-nav,
  .quiz-footer-end {
    justify-content: space-between;
  }
  .quiz-footer-end > .btn-primary {
    flex: 1;
  }
}

/* Footer */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 48px 0 28px;
  font-size: 0.9rem;
  color: var(--muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 28px;
  margin-bottom: 28px;
}

.footer-col h4 {
  margin: 0 0 12px;
  font-size: 0.92rem;
  color: var(--ink);
}

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.footer-links a {
  color: var(--muted);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 18px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.84rem;
  color: var(--subtle);
}

@media (max-width: 980px) {
  .pathway-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .signs-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .header-inner {
    display: grid;
    grid-template-columns: 36px 1fr 36px;
    align-items: center;
    padding: 10px 0;
    min-height: 60px;
    gap: 12px;
  }
  .menu-toggle {
    display: inline-flex;
  }
  .header-spacer {
    display: block;
  }
  .brand-logo {
    justify-self: center;
  }
  .main-nav {
    display: none;
    grid-column: 1 / -1;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding: 14px 0 6px;
    margin-top: 8px;
    border-top: 1px solid var(--border);
  }
  .main-nav.is-open {
    display: flex;
  }
  .main-nav a {
    padding: 10px 12px;
    border-radius: 8px;
  }
  .main-nav a:hover {
    background: var(--surface-alt);
  }
  .main-nav .nav-cta {
    text-align: center;
    margin-top: 4px;
  }
  .setup-grid {
    grid-template-columns: 1fr;
  }
  .hero {
    padding: 36px 0 44px;
  }
  .hero-grid,
  .bento-grid,
  .guide-grid,
  .auth-shell,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .auth-main {
    padding: 24px 0 42px;
  }
  .auth-shell {
    gap: 0;
  }
  .auth-showcase {
    padding: 24px 20px;
  }
  .auth-panel {
    padding: 26px 20px;
  }
  .section {
    padding: 46px 0;
  }
  .doc-card {
    padding: 24px 20px;
  }
  .cta-band {
    padding: 28px 22px;
  }
}

@media (max-width: 540px) {
  .container {
    padding: 0 16px;
  }
  .brand-logo .logo-mark {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    font-size: 0.82rem;
    margin-right: 7px;
  }
  .brand-logo .logo-mark::after {
    right: 3px;
    bottom: 3px;
    width: 4px;
    height: 4px;
  }
  .brand-logo .logo-primary,
  .brand-logo .logo-accent {
    font-size: 1.06rem;
  }
  .brand-logo .logo-tld {
    font-size: 0.78rem;
  }
  .pathway-grid,
  .signs-grid,
  .hero-features {
    grid-template-columns: 1fr;
  }
  .hero-actions {
    flex-direction: column;
  }
  .hero-actions .btn {
    width: 100%;
    white-space: normal;
  }
  .sim-body {
    padding: 18px 16px;
  }
  .sim-question-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .sim-visual {
    width: 100%;
    max-width: 220px;
    height: auto;
    max-height: 150px;
  }
  .cta-band .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* Topic Practice Rich Header & SEO Guide Sections */
.topic-intro-strip {
  margin-bottom: 22px;
}

.topic-intro-strip h1 {
  margin: 12px 0 8px;
  font-size: clamp(1.65rem, 3vw, 2.25rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--ink);
}

.topic-intro-lead {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 1rem;
  max-width: 64ch;
}

.topic-stat-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.topic-stat-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.topic-stat-pill strong {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--brand);
  letter-spacing: -0.02em;
}

.topic-stat-pill span {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.topic-seo-sections {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.topic-guide-block h2 {
  margin: 0 0 6px;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.topic-guide-sub {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.94rem;
}

.topic-guide-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.topic-guide-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px 20px;
}

.topic-guide-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.topic-guide-head h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--ink);
}

.topic-guide-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.55;
}

.cheat-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.cheat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
}

.cheat-num {
  display: inline-block;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--brand);
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.cheat-card strong {
  display: block;
  font-size: 0.88rem;
  color: var(--ink);
  margin-bottom: 4px;
}

.cheat-card p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.45;
}

.topic-cta-banner {
  background: linear-gradient(135deg, #0B1324 0%, #0B6E4F 100%);
  color: #FFFFFF;
  border-radius: 16px;
  padding: 24px 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.topic-cta-banner h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
  color: #FFFFFF;
}

.topic-cta-banner p {
  margin: 0;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.84);
}

.topic-cta-banner .btn-secondary {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.28);
  color: #FFFFFF;
}

.topic-cta-banner .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.22);
}

.mock-intro-strip {
  margin-bottom: 16px;
}

.mock-intro-strip h1 {
  font-size: clamp(1.45rem, 2.5vw, 1.85rem);
  margin: 10px 0 6px;
}

.mock-intro-strip .topic-intro-lead {
  margin-bottom: 0;
  font-size: 0.94rem;
}

.quiz-kbd-hint {
  margin: 10px 0 0;
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
}

.results-topic-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 4px;
}

.results-topic-title {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 10px;
}

.results-topic-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
}

.results-topic-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.results-topic-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--ink);
}

.results-topic-bar {
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
}

.results-topic-bar span {
  display: block;
  height: 100%;
  border-radius: 999px;
}

@media (max-width: 600px) {
  .results-topic-grid {
    grid-template-columns: 1fr;
  }
}

/* About Page Layout */
.about-shell {
  max-width: 1000px;
  margin: 0 auto;
  padding: 36px 20px 68px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.about-hero-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.about-hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: center;
}

.about-hero-card h1 {
  margin: 12px 0 12px;
  font-size: clamp(1.75rem, 3vw, 2.3rem);
  line-height: 1.14;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.about-lead {
  margin: 0 0 22px;
  font-size: 1rem;
  line-height: 1.62;
  color: var(--muted);
}

.about-hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.about-blueprint {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.about-blueprint-label {
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--brand);
}

.about-blueprint-item {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.about-bp-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 0.75rem;
  font-weight: 800;
  flex-shrink: 0;
  margin-top: 2px;
}

.about-blueprint-item strong {
  display: block;
  font-size: 0.88rem;
  color: var(--ink);
  margin-bottom: 2px;
}

.about-blueprint-item p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.45;
}

.about-stat-strip {
  margin-top: 24px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}

.about-pillars-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.about-pillar-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 22px;
}

.about-pillar-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.about-pillar-card h3 {
  margin: 0 0 6px;
  font-size: 1.02rem;
  color: var(--ink);
}

.about-pillar-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.55;
}

@media (max-width: 860px) {
  .about-hero-grid,
  .about-pillars-grid {
    grid-template-columns: 1fr;
  }
}

.about-section-head {
  margin-bottom: 16px;
}

.about-section-head h2 {
  margin: 0 0 4px;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.about-section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.about-steps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.about-step-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
}

.about-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 0.84rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.about-step-card h3 {
  margin: 0 0 6px;
  font-size: 1rem;
  color: var(--ink);
}

.about-step-card p {
  margin: 0;
  font-size: 0.89rem;
  color: var(--muted);
  line-height: 1.55;
}

.about-trust-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 14px;
  align-items: stretch;
}

.about-support-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}

.about-support-card h3 {
  margin: 0 0 4px;
  font-size: 1rem;
  color: var(--ink);
}

.about-support-card p {
  margin: 0;
  font-size: 0.89rem;
  color: var(--muted);
  line-height: 1.55;
}

.about-support-links {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 0.86rem;
  color: var(--muted);
}

@media (max-width: 820px) {
  .about-steps-grid,
  .about-trust-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .about-shell {
    padding: 22px 14px 48px;
    gap: 24px;
  }
  .about-hero-card {
    padding: 22px 18px;
  }
}

/* Contact Page Layout */
.contact-shell {
  max-width: 1000px;
  margin: 0 auto;
  padding: 36px 20px 68px;
}

.contact-hero {
  margin-bottom: 24px;
}

.contact-hero h1 {
  margin: 12px 0 8px;
  font-size: clamp(1.7rem, 3vw, 2.25rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--ink);
}

.contact-lead {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  max-width: 62ch;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 20px;
  align-items: start;
}

.contact-form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 26px;
  box-shadow: var(--shadow-sm);
}

.contact-form-card h2 {
  margin: 0 0 4px;
  font-size: 1.32rem;
  color: var(--ink);
}

.contact-card-sub {
  margin: 0 0 18px;
  font-size: 0.9rem;
  color: var(--muted);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  font-family: inherit;
  font-size: 0.95rem;
  background: var(--surface);
  color: var(--ink);
}

.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--brand);
  outline: none;
  box-shadow: 0 0 0 3px rgba(11, 110, 79, 0.12);
}

.contact-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-dept-card,
.contact-tips-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
}

.contact-dept-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brand);
  margin-bottom: 4px;
}

.contact-dept-card h3,
.contact-tips-card h3 {
  margin: 0 0 4px;
  font-size: 0.98rem;
  color: var(--ink);
}

.contact-dept-card p {
  margin: 0 0 8px;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.48;
}

.contact-mail-link {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--brand);
  word-break: break-all;
}

.contact-tips-card ul {
  margin: 8px 0 0;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.48;
}

@media (max-width: 820px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .contact-shell {
    padding: 22px 14px 48px;
  }
  .contact-form-card {
    padding: 20px 16px;
  }
}

.turnstile-slot {
  margin: 6px 0 8px;
  min-height: 66px;
  display: flex;
  align-items: center;
}

.turnstile-slot[hidden] {
  display: none;
}

@media (max-width: 780px) {
  .topic-stat-row,
  .topic-guide-grid,
  .cheat-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .topic-stat-row,
  .topic-guide-grid,
  .cheat-strip {
    grid-template-columns: 1fr;
  }
  .topic-cta-banner {
    padding: 20px 18px;
  }
  .topic-cta-banner .btn {
    width: 100%;
  }
}
