/* ═══════════════════════════════════════════════════════
   MindSkin Connect — style.css
   Mobile-first: base ≈ 375 px → 768 px → 1024 px
═══════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Lilita+One&family=Poppins:wght@400;600&display=swap');

/* ── Custom properties ────────────────────────────────── */
:root {
  --navy:       #1B3068;
  --teal:       #2BBFAA;
  --teal-ink:   #0E7468; /* teal for text/links on light surfaces (5.6:1 on white) */
  --white:      #FFFFFF;
  --text:       #2D2D2D;
  --accent:     #1B3068; /* overridden per page via <body style="--accent: …"> */
  --card-bg:    #FAF8F4;
  --page-h-pad: 24px;    /* synced with .page-wrapper padding; used for banner breakout */
  --page-max:   720px;   /* max content width; widens on large screens (see media queries) */

  /* Shared with handout pages */
  --navy-dark:   #142554;
  --muted:       #666;
  --hairline:    #f0e8e8;
  --radius-xl:   12px;
  --radius-2xl:  16px;
  --radius-pill: 999px;
  --shadow-card: 0 2px 10px rgba(0,0,0,.06),0 1px 3px rgba(0,0,0,.04);
  --accent-tint: transparent; /* overridden per handout page via <body style> */
}

/* ── Reset ────────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── Base ─────────────────────────────────────────────── */
html {
  font-size: 100%;
  height: 100%;
  margin: 0;
  scroll-padding-top: 60px;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  font-family: 'Poppins', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background-color: var(--white);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin: 0;
}

main {
  flex: 1;
}

img {
  max-width: 100%;
  display: block;
}

button {
  font: inherit;
  color: inherit;
}

::selection {
  background: #BFEDE5;
  color: var(--navy);
}

/* ── Skip link ────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -4rem;
  left: 0.5rem;
  padding: 0.75rem 1rem;
  background: var(--navy);
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
  z-index: 200;
}

.skip-link:focus {
  top: 0;
}

/* ── Site header & nav ────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--white);
  border-bottom: 2px solid var(--navy);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 16px 24px;
  gap: 0.125rem;
}

/* Site wordmark */
.site-logo {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  color: var(--navy);
  text-decoration: none;
  margin-right: auto;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.site-logo:hover,
.site-logo:focus-visible {
  text-decoration: none;
  color: var(--navy);
}

/* Nav links (Home, All modules, For clinicians) */
.site-nav a:not(.site-logo) {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 4px 10px;
  color: var(--navy);
  font-family: 'Poppins', sans-serif;
  font-size: 0.9rem;
  font-weight: 400;
  text-decoration: none;
}

.site-nav a:not(.site-logo):hover {
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-underline-offset: 3px;
}

.site-nav a:focus-visible {
  outline: 2px solid var(--teal-ink);
  outline-offset: 2px;
  border-radius: 2px;
}

.site-nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-underline-offset: 3px;
}

/* Phones: the nav wraps to two rows, so let it scroll away instead of
   pinning ~120px over the content on every scroll. */
@media (max-width: 599px) {
  html { scroll-padding-top: 0; }
  .site-header { position: static; }
  .site-nav { padding: 8px 12px 8px 16px; }
  .site-logo { font-size: 0.9375rem; }
  .site-nav a:not(.site-logo) { padding: 4px 6px; font-size: 0.8125rem; }
  /* The current page's own link is redundant here (its h1 says where you are);
     dropping it lets the nav fit on one row on the landing and All modules pages. */
  .site-nav a[aria-current="page"] { display: none; }
}

/* Text for screen readers only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ── Body links ───────────────────────────────────────── */
a {
  color: var(--teal-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

a:hover {
  text-decoration: none;
}

a:focus-visible {
  outline: 2px solid var(--teal-ink);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ── Content column — used inside handout hero & toolbar ─ */
.wrap {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 24px;
}
@media (min-width: 768px) {
  .wrap { padding: 0 32px; }
}

/* ── Page wrapper ─────────────────────────────────────── */
.page-wrapper {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--page-h-pad) 4rem;
}

/* ── Back link ────────────────────────────────────────── */
.back-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 1.25rem 0 0.75rem;
  font-family: 'Poppins', sans-serif;
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--teal-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.back-link:hover {
  text-decoration: none;
}

/* ── Hero banner — wraps back link + h1 on module pages ── */
.hero-banner {
  position: relative;
  background-image: linear-gradient(
    135deg,
    var(--accent),
    var(--accent-light),
    var(--accent-dark)
  );
  background-size: 300% 300%;
  background-position: 0% 50%;
  color: var(--white);
  text-align: center;
  padding: 28px 24px;
  border-radius: 12px;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
}

.page-heading {
  font-family: 'Lilita One', cursive;
  font-weight: 400;
  font-size: clamp(1.6rem, 4.5vw, 2.75rem);
  text-transform: uppercase;
  line-height: 1.15;
  letter-spacing: 0.02em;
  color: var(--white);
  margin: 0;
}

/* ── Hero back button ─────────────────────────────────── */
.hero-back-btn {
  position: absolute;
  top: 16px;
  left: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: var(--white);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
  line-height: 1;
}

.hero-back-btn:hover {
  background: rgba(255, 255, 255, 0.4);
  color: var(--white);
  text-decoration: none;
}

/* ── Module section cards ─────────────────────────────── */
.module-section {
  background-color: var(--card-bg);
  border-radius: 16px;
  padding: 24px 28px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06), 0 1px 3px rgba(0, 0, 0, 0.04);
  margin-top: 1.5rem;
  margin-bottom: 32px;
}

/* ── Section headings (h2) ────────────────────────────── */
.section-bar {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin-bottom: 1rem;
  /* reset any prior bar styling */
  background: none;
  padding: 0;
  border-radius: 0;
}

/* ── Section content wrapper ──────────────────────────── */
.section-content {
  padding: 0;
}

.section-content > p {
  line-height: 1.75;
  max-width: 65ch;
}

/* ── Video embed (16:9) ───────────────────────────────── */
.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  background-color: #f0f0f0;
  border-radius: 10px;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.video-fallback {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: #666;
}

/* ── Key points (details / summary) ──────────────────── */
.key-points {
  border: none;
  background: transparent;
  border-radius: 0;
  overflow: visible;
}

.key-points summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  min-height: 44px;
  padding: 0;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--teal-ink);
  background: none;
  user-select: none;
}

.key-points summary::-webkit-details-marker {
  display: none;
}

.key-points summary::before {
  content: "›";
  font-size: 1.25em;
  line-height: 1;
  flex-shrink: 0;
}

.label-open  { display: none; }
.key-points[open] .label-closed { display: none; }
.key-points[open] .label-open   { display: inline; }

.key-points-list {
  list-style: none;
  padding: 0;
  margin: 0.25rem 0 0;
}

.key-points-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 10px 0;
  border-bottom: 1px solid #f0e8e8;
  font-size: 0.9375rem;
  line-height: 1.65;
  max-width: 65ch;
}

.key-points-list li:last-child {
  border-bottom: none;
}

.key-points-list li::before {
  content: "›";
  color: var(--teal);
  font-size: 1.2em;
  font-weight: 700;
  flex-shrink: 0;
  line-height: 1.55;
}

/* ── Appointment box ──────────────────────────────────── */
/*
  Faint concentric circles (white, stroke-only, 15% opacity) are placed
  at the top-right corner via a data-URI background-image.
*/
.appointment-box {
  background-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200' viewBox='0 0 200 200'%3E%3Ccircle cx='200' cy='0' r='55' fill='none' stroke='white' stroke-width='1.5' opacity='0.15'/%3E%3Ccircle cx='200' cy='0' r='90' fill='none' stroke='white' stroke-width='1.5' opacity='0.15'/%3E%3Ccircle cx='200' cy='0' r='125' fill='none' stroke='white' stroke-width='1.5' opacity='0.15'/%3E%3Ccircle cx='200' cy='0' r='160' fill='none' stroke='white' stroke-width='1.5' opacity='0.15'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: top right;
  background-size: 180px 180px;
  color: var(--white);
  border-radius: 16px;
  padding: 28px;
  overflow: hidden;
}

.appointment-box ul {
  list-style: none;
  padding: 0;
}

.appointment-box li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  line-height: 1.65;
  max-width: 65ch;
}

.appointment-box li:last-child {
  border-bottom: none;
}

.appointment-box li::before {
  content: "›";
  color: var(--white);
  font-size: 1.25em;
  font-weight: 700;
  flex-shrink: 0;
  line-height: 1.5;
}

/* ── Site footer ──────────────────────────────────────── */
.site-footer {
  background-color: var(--navy);
  color: var(--white);
  padding: 32px 24px;
  font-family: 'Poppins', sans-serif;
  font-size: 0.875rem;
  line-height: 1.65;
  text-align: center;
}

.site-footer p {
  max-width: min(var(--page-max), 72ch);
  margin: 0 auto;
}

.site-footer p + p {
  margin-top: 0.375rem;
}

/* .site-footer prefix outranks `.site-footer p`; 60ch keeps the 13px disclaimer under ~80 characters a line */
.site-footer .footer-disclaimer {
  max-width: min(var(--page-max), 60ch);
  margin: 0 auto 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.82);
}
.footer-disclaimer a {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── About this resource / For clinicians (landing) ── */
.about-resource {
  max-width: var(--page-max);
  margin: 3.5rem auto 0;
  scroll-margin-top: 110px;
}
.about-heading {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  color: var(--navy);
  font-size: clamp(1.375rem, 1.1rem + 1.2vw, 1.75rem);
  line-height: 1.25;
  text-wrap: balance;
  margin: 0 0 1.5rem;
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}
@media (min-width: 700px) {
  .about-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
.about-point h3,
.about-cta h3 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1.0625rem;
  color: var(--navy);
  margin: 0 0 0.4rem;
}
.about-point p {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--text);
  margin: 0;
}
.about-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  background: var(--card-bg);
  border: 1px solid #E2DDD3;
  border-radius: 16px;
  padding: 1.75rem;
}
.about-cta > div { flex: 1 1 280px; }
.about-cta p {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--text);
  margin: 0;
}
.about-contact-btn {
  flex-shrink: 1;
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--white);
  color: var(--navy);
  border: 2px solid var(--navy);
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  padding: 0.6rem 1.5rem;
  border-radius: 999px;
  min-height: 52px;
  transition: background-color 0.15s, color 0.15s;
}
.about-contact-btn:hover {
  background: var(--navy);
  color: var(--white);
  text-decoration: none;
}
.about-contact-btn:focus-visible { outline: 3px solid var(--teal-ink); outline-offset: 3px; }
.about-mshi {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--text);
  max-width: 65ch;
  margin: 1.25rem 0 0;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem 1.25rem;
  max-width: var(--page-max);
  margin: 0.875rem auto 0;
}

.footer-links a {
  color: var(--teal);
  text-decoration: underline;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  font-family: 'Poppins', sans-serif;
}

.footer-links a:hover {
  text-decoration: none;
}

.site-footer a:focus-visible {
  outline-color: var(--teal);
}

.footer-links a::after {
  content: " →";
  color: #2BBFAA;
  opacity: 0;
  transition: opacity 0.2s;
}

.footer-links a:hover::after {
  opacity: 1;
}

/* ── Active nav link ──────────────────────────────────── */
.nav-active {
  color: var(--teal-ink) !important;
  border-bottom: 3px solid var(--teal-ink);
  padding-bottom: 1px;
  text-decoration: none !important; /* the border is the active marker; no second underline */
}

/* ── Module completion footer ─────────────────────────── */
.module-end {
  text-align: center;
  padding: 2.5rem 0 1rem;
}

.module-end-text {
  font-family: 'Poppins', sans-serif;
  font-style: italic;
  color: #888;
  margin-bottom: 1.25rem;
}

.module-end-btn {
  display: inline-flex;
  align-items: center;
  background-color: var(--teal);
  color: var(--white);
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  border-radius: 999px;
  padding: 12px 28px;
}

.module-end-btn:hover {
  text-decoration: none;
  color: var(--white);
}

/* ── Read-instead section (module-1a) ─────────────────── */
.section-pill {
  display: inline-block;
  background: #2BBFAA;
  color: white;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.7rem;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  margin-bottom: 6px;
}

.partner-item {
  margin-bottom: 20px;
  padding: 16px 20px;
  background: #FAF8F4;
  border-radius: 8px;
  border-left: 4px solid #C2607A;
}

.q-label {
  display: inline-block;
  background: #f5d0d8;
  color: #C2607A;
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 0.8rem;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  margin-bottom: 10px;
}

.scenario-box {
  background: white;
  border-radius: 12px;
  padding: 16px 20px;
  border-left: 4px solid #C2607A;
  margin: 12px 0 16px;
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1.65;
}

.read-intro {
  line-height: 1.75;
  max-width: 65ch;
  margin-bottom: 32px;
  padding: 16px 20px;
  background: #f5f0ff;
  border-radius: 8px;
  font-style: italic;
}

.read-block {
  margin-bottom: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid #f0e8e8;
}

.read-block h3 {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1.1rem;
  color: #C2607A;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 0;
  margin-bottom: 12px;
}

.impact-card {
  background-color: #FAF8F4;
  border-left: 4px solid #2BBFAA;
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.deeper-dive {
  border: 1px solid #e8d0d6;
  border-left: 4px solid #2BBFAA;
  border-radius: 8px;
  background-color: #FAF8F4;
  padding: 16px;
  margin: 20px 0;
}

.deeper-dive > summary {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  color: #2BBFAA;
  cursor: pointer;
  list-style: none;
}

.deeper-dive > summary::-webkit-details-marker {
  display: none;
}

.quiz-block {
  background: #FAF8F4;
  border-radius: 16px;
  padding: 28px;
  margin-top: 32px;
}

.quiz-block h3 {
  font-family: 'Lilita One', cursive;
  font-weight: 400;
  font-size: 1.4rem;
  color: #C2607A;
  margin-bottom: 8px;
}

.quiz-block > p {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 24px;
}

.quiz-question {
  background: white;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.quiz-question:last-of-type {
  margin-bottom: 0;
}

.scenario {
  font-size: 0.9375rem;
  line-height: 1.7;
  margin-bottom: 0.75rem;
  max-width: 65ch;
}

.quiz-option {
  display: block;
  width: 100%;
  text-align: left;
  background: white;
  border: 1.5px solid #e0e0e0;
  border-radius: 12px;
  padding: 14px 20px;
  margin-bottom: 8px;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  font-size: 0.95rem;
  line-height: 1.5;
  transition: background 0.2s, border-color 0.2s;
}

.quiz-option:hover:not(:disabled) {
  background: #fdf0f2;
  border-color: #C2607A;
}

.quiz-option:disabled {
  cursor: default;
}

.quiz-feedback {
  margin-top: 16px;
  padding: 16px 20px;
  background: #fdf0f2;
  border-radius: 12px;
  border-left: 4px solid #C2607A;
  font-size: 0.9rem;
  line-height: 1.65;
}

.sources-block {
  margin-top: 24px;
  font-size: 0.85rem;
  color: #666;
}

.sources-block > summary {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  color: #888;
  cursor: pointer;
  list-style: none;
  padding: 8px 0;
}

.sources-block > summary::-webkit-details-marker {
  display: none;
}

.sources-block ol {
  margin: 0.75rem 0 0 1.25rem;
  line-height: 1.8;
}

/* ── Media: tablet ≥ 768 px ───────────────────────────── */
@media (min-width: 768px) {
  :root {
    --page-h-pad: 32px;
  }

  .site-nav {
    padding: 16px 32px;
  }

  .site-footer {
    padding: 32px 32px;
  }
}

/* ── Media: desktop ≥ 1024 px ─────────────────────────── */
@media (min-width: 1024px) {
  :root {
    --page-h-pad: 40px;
    --page-max:   900px;
  }

  .site-nav {
    padding: 16px 40px;
  }

  .site-footer {
    padding: 32px 40px;
  }
}

/* ── Media: large / maximized ≥ 1440 px ───────────────── */
@media (min-width: 1440px) {
  :root {
    --page-max: 1040px;
  }
}

/* ═══════════════════════════════════════════════════════
   Motion and transitions
   All animations are inside prefers-reduced-motion: no-preference
   so they are off by default and only activate for users
   who have not requested reduced motion.
═══════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: no-preference) {

  /* 1 — Page load fade-in ──────────────────────────── */
  @keyframes page-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  main {
    animation: page-fade-in 0.5s ease-out both;
  }

  /* 2 — Card hover lift ────────────────────────────── */
  .module-section {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .module-section:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1), 0 2px 8px rgba(0, 0, 0, 0.06);
  }

  /* 3 — Details smooth expand ──────────────────────── */
  @keyframes details-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  .key-points[open] .key-points-list {
    animation: details-fade-in 0.3s ease;
  }

  /* 4 — Appointment prompt hover ───────────────────── */
  .appointment-box li {
    transition: filter 0.15s ease;
  }

  .appointment-box li:hover {
    filter: brightness(1.08);
  }

  /* 5 — Quiz scale buttons ─────────────────────────── */
  .scale-btn {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  }

  /* 7 — Nav link hover underline slide-in ──────────── */
  .site-nav a:not(.site-logo) {
    position: relative;
  }

  .site-nav a:not(.site-logo):hover {
    text-decoration: none;
  }

  .site-nav a[aria-current="page"] {
    text-decoration: none;
  }

  .site-nav a:not(.site-logo)::after {
    content: '';
    position: absolute;
    bottom: 8px;
    left: 10px;
    height: 2px;
    width: calc(100% - 20px);
    background: var(--teal);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .site-nav a:not(.site-logo):not(.nav-active):hover::after,
  .site-nav a[aria-current="page"]:not(.nav-active)::after {
    transform: scaleX(1);
  }

  /* 8 — Button hover lift ──────────────────────────── */
  .result-cta,
  .error-home-link,
  .quiz-btn-next:not(:disabled),
  .module-end-btn {
    transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
  }

  .result-cta:hover,
  .error-home-link:hover,
  .quiz-btn-next:not(:disabled):hover,
  .module-end-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
  }

}

/* ── index.html page effects ─────────────────────────── */

@media (prefers-reduced-motion: no-preference) {

  /* 3 — Quiz question slide transitions */
  @keyframes quiz-slide-in-right {
    from { opacity: 0; transform: translateX(16px); }
    to   { opacity: 1; transform: translateX(0); }
  }

  @keyframes quiz-slide-out-left {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(-16px); }
  }

  @keyframes quiz-slide-in-left {
    from { opacity: 0; transform: translateX(-16px); }
    to   { opacity: 1; transform: translateX(0); }
  }

  @keyframes quiz-slide-out-right {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(16px); }
  }

  .quiz-step.slide-in-right {
    animation: quiz-slide-in-right 0.22s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .quiz-step.slide-out-left {
    animation: quiz-slide-out-left 0.18s cubic-bezier(0.16, 1, 0.3, 1) both;
    pointer-events: none;
  }

  .quiz-step.slide-in-left {
    animation: quiz-slide-in-left 0.22s cubic-bezier(0.16, 1, 0.3, 1) both;
  }

  .quiz-step.slide-out-right {
    animation: quiz-slide-out-right 0.18s cubic-bezier(0.16, 1, 0.3, 1) both;
    pointer-events: none;
  }

}

/* ── Module hero shimmer ─────────────────────────────── */
@keyframes heroShimmer {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@media (prefers-reduced-motion: no-preference) {

  .hero-banner {
    animation: heroShimmer 5s ease-in-out infinite;
  }

}

/* ═══════════════════════════════════════════════════════
   Handout pages (handout-pmr.html etc.)
   Shared components — page-specific CSS stays inline.
═══════════════════════════════════════════════════════ */

/* ── Hero (full-width, solid accent, concentric circles) ── */
.handout-hero {
  background: var(--accent);
  color: #fff;
  position: relative;
  overflow: hidden;
  padding: 20px 0 34px;
}
.handout-hero::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -70px;
  width: 260px;
  height: 260px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cg fill='none' stroke='white' stroke-width='2'%3E%3Ccircle cx='100' cy='100' r='30'/%3E%3Ccircle cx='100' cy='100' r='55'/%3E%3Ccircle cx='100' cy='100' r='80'/%3E%3Ccircle cx='100' cy='100' r='98'/%3E%3C/g%3E%3C/svg%3E") no-repeat center / contain;
  opacity: .15;
  pointer-events: none;
}
.handout-hero h1 {
  font-family: 'Lilita One', cursive;
  font-weight: 400;
  text-transform: uppercase;
  line-height: 1.15;
  letter-spacing: .02em;
  font-size: clamp(1.85rem, 6.2vw, 2.85rem);
  margin: .2em 0 .1em;
  color: #fff;
}
.handout-subtitle {
  margin: 0;
  font-size: 1.0625rem;
  opacity: .95;
  max-width: 40ch;
}

/* ── Back link inside hero ─────────────────────────────── */
.back-to-module {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  color: #fff;
  font-weight: 600;
  font-size: .9375rem;
  text-decoration: none;
}
.back-to-module:hover,
.back-to-module:focus-visible {
  text-decoration: underline;
  color: #fff;
}

/* ── Print / toolbar row ───────────────────────────────── */
.handout-toolbar {
  display: flex;
  justify-content: flex-end;
  padding-top: 18px;
}

/* ── Pill button (Print, Start, etc.) ─────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border: none;
  border-radius: var(--radius-pill);
  background: var(--navy);
  color: #fff;
  font-weight: 600;
  font-size: .9375rem;
  cursor: pointer;
}
.btn-mini {
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius-pill);
  border: 2px solid var(--navy);
  background: #fff;
  color: var(--navy);
  font-weight: 600;
  font-size: .875rem;
  cursor: pointer;
}
.btn-mini:hover { background: #f2f4fa; }

@media (prefers-reduced-motion: no-preference) {
  .btn { transition: background .15s, transform .15s, box-shadow .15s; }
  .btn:hover {
    background: var(--navy-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,.18);
  }
}

/* ── Cards ─────────────────────────────────────────────── */
.handout-card {
  background: var(--card-bg);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-card);
  padding: 24px;
  margin-top: 28px;
}
@media (min-width: 768px) {
  .handout-card { padding: 32px; }
}
.handout-card p { max-width: 65ch; }
.handout-card--navy {
  background: var(--navy);
  color: #fff;
}
.handout-card--tint {
  background: var(--accent-tint);
}

/* ── Section headings ──────────────────────────────────── */
.handout-h2 {
  font-family: 'Lilita One', cursive;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: .02em;
  line-height: 1.15;
  font-size: 1.4rem;
  color: var(--navy);
  margin: 0 0 14px;
}

/* ── Numbered steps list ───────────────────────────────── */
.handout-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.handout-steps li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.handout-step-num {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-family: 'Lilita One', cursive;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.handout-steps p { margin: 6px 0 0; }

/* ── Bulleted tips list ─────────────────────────────────── */
.handout-tips {
  margin: 0;
  padding-left: 1.15em;
}
.handout-tips li { margin-bottom: 10px; }

/* ═══════════════════════════════════════════════════════
   Handout print styles
═══════════════════════════════════════════════════════ */
@media print {
  @page { size: letter portrait; margin: .6in; }

  .site-header,
  .no-print { display: none !important; }

  .handout-hero {
    background: #fff !important;
    color: #000;
    padding: 0 0 6pt;
  }
  .handout-hero::after,
  .back-to-module { display: none; }
  .handout-hero h1 { font-size: 22pt; color: #000; margin: 0; }

  .wrap,
  .page-wrapper { padding: 0; max-width: none; }

  .handout-card {
    background: #fff;
    box-shadow: none;
    border: 1pt solid #000;
    padding: 10pt;
    margin-top: 9pt;
    break-inside: avoid;
  }
  .handout-card--navy { background: #fff !important; color: #000; }
  .handout-card--tint { background: #fff; }

  .handout-h2 { color: #000; font-size: 14pt; margin-bottom: 8pt; }

  .handout-step-num {
    background: #fff;
    color: #000;
    border: 1.25pt solid #000;
    width: 26px;
    height: 26px;
    font-size: 11pt;
  }

  .site-footer {
    background: #fff !important;
    color: #000;
    border-top: .75pt solid #000;
    padding-top: 8pt;
  }
  .site-footer .footer-links a { color: #000; }
}
