/* Landing pages for SEO (exams/index.html and exams/<id>/index.html).
   Mirrors the main site palette and supports the shared dark theme
   (body.dark-mode, toggled by assets/js/legal-page.js). */
body.exam-landing {
  --primary: #0f766e;
  --primary-dark: #0b5d57;
  --accent: #2dd4bf;
  --ink: #1e293b;
  --muted: #5b6b7f;
  --card: #ffffff;
  --card-border: #e3e6ea;
  --shadow: 0 1px 2px rgba(31, 39, 51, 0.05);
  --page-bg: #f1f3f5;

  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: var(--page-bg) fixed;
  font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, Roboto, sans-serif;
  line-height: 1.6;
}

body.exam-landing.dark-mode {
  --primary: #2bb3a3;
  --accent: #2dd4bf;
  --ink: #f1f5f9;
  --muted: #cbd5e1;
  --card: #1a212c;
  --card-border: #28303d;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  --page-bg: #10141b;
}

/* Topbar */
.exam-landing .landing-topbar {
  width: min(960px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}
.exam-landing .landing-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 800;
  font-size: 1.1rem;
  text-decoration: none;
}
.exam-landing .landing-theme-toggle {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  box-shadow: var(--shadow);
  cursor: pointer;
  font-size: 1rem;
}
.exam-landing .landing-theme-toggle:hover { color: var(--primary); }

/* Main column */
.exam-landing .landing-main {
  width: min(960px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 56px;
}

/* Breadcrumb */
.exam-landing .breadcrumbs { font-size: 0.9rem; color: var(--muted); margin: 4px 0 16px; }
.exam-landing .breadcrumbs a { color: var(--primary); text-decoration: none; }
.exam-landing .breadcrumbs a:hover { text-decoration: underline; }

/* Hero (graphite control-room band, mirrors the homepage) */
.exam-landing .landing-hero {
  position: relative;
  overflow: hidden;
  padding: 34px 36px;
  color: #aab2c0;
  background:
    radial-gradient(520px 240px at 80% 0%, rgba(45, 212, 191, 0.09), transparent 70%),
    #1d232f;
  border: 1px solid #313947;
  border-radius: 16px;
  box-shadow: none;
}
.exam-landing .landing-hero h1,
.exam-landing .landing-hero strong { color: #e8ebf0; }
.exam-landing .landing-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  padding: 5px 12px;
  color: #2dd4bf;
  background: rgba(45, 212, 191, 0.08);
  border: 1px solid rgba(45, 212, 191, 0.35);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.exam-landing .landing-hero h1 { margin: 0 0 6px; font-size: 2rem; line-height: 1.15; }
.exam-landing .landing-subhead { margin: 0 0 14px; font-size: 1.15rem; opacity: 0.92; }
.exam-landing .landing-intro { margin: 0; max-width: 640px; font-size: 1.02rem; opacity: 0.94; }
.exam-landing .hero-cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.exam-landing .landing-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  background: #2dd4bf;
  color: #08312d;
  box-shadow: none;
  transition: filter .12s ease;
}
.exam-landing .landing-cta:hover { filter: brightness(1.08); }
.exam-landing .landing-cta-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  color: #e8ebf0;
  background: transparent;
  border: 1px solid #313947;
  transition: border-color .12s ease;
}
.exam-landing .landing-cta-ghost:hover { border-color: #aab2c0; background: transparent; }

/* Section cards */
.exam-landing .exam-section {
  margin-top: 22px;
  padding: 24px 26px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  box-shadow: var(--shadow);
}
.exam-landing .exam-section h2 {
  margin: 0 0 14px;
  font-size: 1.3rem;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}
.exam-landing .exam-section h2::before {
  content: "";
  width: 4px;
  height: 1.05em;
  border-radius: 4px;
  background: var(--primary);
}

/* Facts table */
.exam-landing .exam-facts {
  margin-top: 22px;
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.exam-landing .exam-facts caption {
  text-align: left;
  font-weight: 800;
  padding: 14px 18px;
  color: var(--ink);
  background: rgba(15, 118, 110, 0.06);
}
.exam-landing.dark-mode .exam-facts caption { background: rgba(43, 179, 163, 0.14); }
.exam-landing .exam-facts th,
.exam-landing .exam-facts td { text-align: left; padding: 11px 18px; border-top: 1px solid var(--card-border); }
.exam-landing .exam-facts th { width: 46%; color: var(--muted); font-weight: 600; }

/* Lists */
.exam-landing .exam-domains,
.exam-landing .exam-modules,
.exam-landing .exam-resources,
.exam-landing .exam-crosslinks { margin: 0; padding-left: 20px; }
.exam-landing .exam-domains li,
.exam-landing .exam-modules li,
.exam-landing .exam-resources li,
.exam-landing .exam-crosslinks li { margin: 7px 0; }
.exam-landing .exam-modules { columns: 2; column-gap: 28px; }
.exam-landing .domain-weight { color: var(--primary); font-weight: 700; }
.exam-landing a { color: var(--primary); }

/* FAQ */
.exam-landing .faq-item { border-top: 1px solid var(--card-border); padding: 12px 0; }
.exam-landing .faq-item:first-of-type { border-top: none; padding-top: 0; }
.exam-landing .faq-item summary { cursor: pointer; font-weight: 700; color: var(--ink); list-style: none; }
.exam-landing .faq-item summary::-webkit-details-marker { display: none; }
.exam-landing .faq-item summary::before { content: "+ "; color: var(--accent); font-weight: 800; }
.exam-landing .faq-item[open] summary::before { content: "\2013 "; }
.exam-landing .faq-item p { margin: 8px 0 0; color: var(--muted); }

/* Pro upsell */
.exam-landing .exam-pro {
  margin-top: 22px;
  padding: 24px 26px;
  background: rgba(15, 118, 110, 0.05);
  border: 1px solid rgba(15, 118, 110, 0.22);
  border-left: 4px solid var(--primary);
  border-radius: 14px;
}
.exam-landing.dark-mode .exam-pro {
  background: rgba(43, 179, 163, 0.08);
  border-color: rgba(43, 179, 163, 0.3);
}
.exam-landing .exam-pro h2 { margin-top: 0; }
.exam-landing .pro-price { font-weight: 800; color: var(--primary); }
.exam-landing .pro-highlights { margin: 12px 0 18px; padding-left: 20px; }
.exam-landing .pro-highlights li { margin: 6px 0; color: var(--muted); }
.exam-landing .pro-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  color: #fff;
  background: var(--primary);
  box-shadow: none;
  transition: filter .12s ease;
}
.exam-landing .pro-cta:hover { filter: brightness(1.1); }
.exam-landing.dark-mode .pro-cta { color: #0d1a18; }

/* Hub grid */
.exam-landing .hub-grid {
  list-style: none;
  padding: 0;
  margin: 22px 0 0;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.exam-landing .hub-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
  transition: transform .12s ease, box-shadow .12s ease;
}
.exam-landing .hub-card:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(15, 23, 42, 0.14); }
.exam-landing .hub-code { font-weight: 800; font-size: 1.1rem; color: var(--primary); }
.exam-landing .hub-name { font-size: 0.92rem; color: var(--muted); }
.exam-landing .hub-badge {
  align-self: flex-start;
  margin-top: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--primary);
  background: rgba(15, 118, 110, 0.1);
}

/* Footer */
.exam-landing .landing-footer {
  width: min(960px, calc(100% - 32px));
  margin: 40px auto 0;
  padding: 22px 0 40px;
}
.exam-landing .landing-footer-links { display: flex; flex-wrap: wrap; gap: 18px; }
.exam-landing .landing-footer a { color: var(--muted); text-decoration: none; }
.exam-landing .landing-footer a:hover { color: var(--primary); }

/* Responsive */
@media (max-width: 640px) {
  .exam-landing .landing-hero { padding: 28px 22px; }
  .exam-landing .landing-hero h1 { font-size: 1.8rem; }
  .exam-landing .exam-modules { columns: 1; }
}
