:root {
  color-scheme: light;
  /* Brand palette derived from the IXA logo: navy → vivid purple */
  --bg: #f7f6fc;
  --bg-tint: #f5f3ff;
  --panel: #ffffff;
  --ink: #1e1b4b;          /* deep navy from logo */
  --ink-soft: #312e81;
  --muted: #64748b;
  --accent: #7c3aed;       /* vivid purple from logo */
  --accent-dark: #5b21b6;
  --accent-light: #a855f7;
  --accent-bright: #8b5cf6;
  --border: #e5e7eb;
  --border-soft: #ede9fe;
  --shadow: 0 20px 50px rgba(30, 27, 75, 0.14);
  --shadow-soft: 0 4px 12px rgba(30, 27, 75, 0.06);
  --danger: #b91c1c;
  --success: #15803d;
  --gradient: linear-gradient(135deg, #1e1b4b 0%, #7c3aed 100%);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(124, 58, 237, 0.10), transparent 32rem),
    radial-gradient(circle at bottom right, rgba(30, 27, 75, 0.06), transparent 28rem),
    var(--bg);
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* ---------- Header ---------- */
.site-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 32px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  position: sticky; top: 0; z-index: 10;
}
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.brand-logo { width: 44px; height: 44px; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; align-items: flex-end; }
.brand-name { font-family: var(--serif); font-weight: 500; font-size: 1.08rem; letter-spacing: -0.012em; }
.brand-name .x { color: var(--accent); font-style: italic; }
.brand-tagline {
  font-family: var(--mono); font-size: 0.7rem; color: var(--accent);
  text-transform: uppercase; letter-spacing: 0.18em; font-weight: 700;
  align-self: flex-end; text-align: right;
}

.site-nav { display: flex; align-items: center; gap: 16px; }
.site-nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.92rem; }
.site-nav a:hover { color: var(--accent); }
.site-nav a.cta { background: var(--accent); color: white; padding: 10px 16px; border-radius: 10px; box-shadow: var(--shadow-soft); }
.site-nav a.cta:hover { background: var(--accent-dark); color: white; }
.user-pill { padding: 5px 10px; border: 1px solid var(--border-soft); border-radius: 999px; color: var(--muted); font-size: 0.82rem; }

.inline-form { display: inline; }
.link-button { background: transparent; border: 0; padding: 0; color: var(--accent); font-weight: 700; cursor: pointer; font: inherit; }
.link-button:hover { color: var(--accent-dark); text-decoration: underline; }

.site-main { flex: 1; width: min(1120px, calc(100% - 32px)); margin: 0 auto; padding: 40px 0; }
.site-footer { border-top: 1px solid var(--border); padding: 18px 32px; color: var(--muted); font-size: 0.82rem; text-align: center; }

/* ---------- Hero ---------- */
.hero { max-width: 720px; }
.hero.compact h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
.eyebrow { margin: 0 0 8px; text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.74rem; font-weight: 800; color: var(--accent); }
.hero h1 { margin: 0 0 16px; font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.05; letter-spacing: -0.015em; color: var(--ink); }
.subtitle { color: var(--muted); font-size: 1.04rem; line-height: 1.6; max-width: 760px; }
.hero-actions { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn-primary, .btn-secondary {
  display: inline-block; padding: 12px 22px; border-radius: 12px;
  font-weight: 700; text-decoration: none; border: 0; cursor: pointer; font: inherit;
  transition: transform 100ms ease, box-shadow 100ms ease, background-color 100ms ease;
}
.btn-primary { background: var(--accent); color: white; box-shadow: 0 10px 24px rgba(124, 58, 237, 0.28); }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); }
.btn-primary.disabled { opacity: 0.5; pointer-events: none; }
.btn-secondary { background: var(--bg-tint); color: var(--ink); border: 1px solid var(--border-soft); }
.btn-secondary:hover { background: var(--border-soft); }
.btn-danger { background: var(--danger); color: white; border: 0; padding: 8px 14px; border-radius: 10px; font-weight: 700; cursor: pointer; font: inherit; }
.btn-small { padding: 8px 14px; border-radius: 10px; border: 0; font-weight: 700; cursor: pointer; font: inherit; text-decoration: none; display: inline-block; }
.btn-approve { background: var(--accent); color: white; }
.btn-approve:hover { background: var(--accent-dark); color: white; }
.btn-reject { background: var(--bg-tint); color: var(--ink); }

/* ---------- Auth cards ---------- */
.auth-card {
  max-width: 440px; margin: 0 auto;
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 20px; box-shadow: var(--shadow); padding: 32px;
}
.auth-card h1 { margin-top: 0; }
.stack { display: flex; flex-direction: column; gap: 14px; margin-top: 12px; }
.stack label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 0.92rem; }
.stack input { width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; font: inherit; background: #fff; outline: none; transition: border-color 100ms; }
.stack input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.14); }
.stack button { margin-top: 8px; }

.muted { color: var(--muted); }
.small { font-size: 0.86rem; }
.center { text-align: center; }

.alert { padding: 12px 14px; border-radius: 10px; margin-bottom: 12px; font-size: 0.95rem; }
.alert.error { background: #fee2e2; color: var(--danger); border: 1px solid #fecaca; }
.alert.info { background: var(--bg-tint); color: var(--accent-dark); border: 1px solid var(--border-soft); }
.alert.success { background: #dcfce7; color: var(--success); border: 1px solid #bbf7d0; }

/* ---------- Admin tables ---------- */
.admin-wrap { display: flex; flex-direction: column; gap: 32px; }
.admin-header h1 { margin: 0; }
.count { background: var(--accent); color: white; padding: 2px 10px; border-radius: 999px; font-size: 0.82rem; margin-left: 8px; font-weight: 700; }

.table { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--border-soft); border-radius: 14px; overflow: hidden; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border-soft); }
.table th { background: var(--bg-tint); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.table tr:last-child td { border-bottom: 0; }
.row-actions { display: flex; gap: 8px; }

/* ---------- Diagnostic ---------- */
.diagnostic-wrap { display: flex; flex-direction: column; gap: 24px; }
.diagnostic { display: flex; flex-direction: column; gap: 14px; }
.q-card { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 16px; padding: 18px 22px; margin: 0; }
.q-card legend { font-weight: 800; font-size: 1rem; padding: 0 6px; color: var(--ink); }
.q-card .optional { background: var(--border-soft); color: var(--muted); font-size: 0.66rem; padding: 2px 8px; border-radius: 999px; margin-left: 6px; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; }
.q-card .helper { color: var(--muted); margin: 4px 0 12px; font-size: 0.9rem; }
.options { display: flex; flex-wrap: wrap; gap: 8px; }
.options .opt {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px; border: 1px solid var(--border);
  border-radius: 10px; background: #fff; cursor: pointer;
  font-size: 0.92rem; font-weight: 500;
  transition: border-color 100ms, background-color 100ms;
}
.options .opt:hover { border-color: var(--accent); }
.options .opt input { margin: 0; accent-color: var(--accent); }
.options .opt:has(input:checked) { border-color: var(--accent); background: var(--bg-tint); font-weight: 700; }
.q-card textarea { width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; font: inherit; background: #fff; resize: vertical; min-height: 80px; }
.q-card textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.14); }
.range-row { display: flex; align-items: center; gap: 16px; }
.range-row input[type=range] { flex: 1; accent-color: var(--accent); }
.range-row output { min-width: 36px; text-align: center; background: var(--accent); color: white; padding: 4px 10px; border-radius: 999px; font-weight: 800; }
.submit-row { display: flex; justify-content: flex-end; padding-top: 8px; }

/* ---------- Dashboard ---------- */
.dashboard { display: flex; flex-direction: column; gap: 32px; }
.section-title { margin: 0 0 14px; font-size: 1.05rem; letter-spacing: -0.01em; }

.track-strip { display: flex; flex-direction: column; gap: 10px; }
.track-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.track-card { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow-soft); }
.track-card h3 { margin: 0 0 6px; color: var(--accent); font-size: 1rem; }
.track-card p { margin: 0; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }

.module-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.module-card {
  background: var(--panel); border: 1px solid var(--border-soft); border-radius: 16px;
  padding: 18px 20px; display: flex; flex-direction: column; gap: 8px;
  transition: transform 120ms, box-shadow 120ms; box-shadow: var(--shadow-soft);
}
.module-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.module-card.status-done { border-color: rgba(21, 128, 61, 0.4); }
.module-card.status-in_progress { border-color: var(--accent); }
.module-card h3 { margin: 0; font-size: 1.02rem; color: var(--ink); }
.module-card p { margin: 0; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.module-meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-right: 56px; font-size: 0.74rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700; min-height: 44px; }
.module-meta .module-time { text-align: right; line-height: 1.3; }
.module-cta { margin-top: 6px; display: flex; align-items: center; gap: 10px; }

.badge { display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 0.74rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; }
.badge.muted { background: var(--border-soft); color: var(--ink-soft); }
.badge.success { background: #dcfce7; color: var(--success); }
.badge.in-progress { background: rgba(124, 58, 237, 0.12); color: var(--accent); }

/* ---------- Breadcrumb ---------- */
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 0.86rem; color: var(--muted); margin-bottom: 24px; }
.breadcrumb a { color: var(--accent); text-decoration: none; font-weight: 600; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb .sep { color: var(--muted); }
.breadcrumb .current { color: var(--ink); font-weight: 600; }

/* ---------- Module page ---------- */
.lesson-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.lesson-row {
  background: var(--panel); border: 1px solid var(--border-soft); border-radius: 12px;
  padding: 14px 18px; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  transition: border-color 100ms;
}
.lesson-row:hover { border-color: var(--accent); }
.lesson-left { display: flex; align-items: flex-start; gap: 14px; flex: 1; }
.lesson-num { background: var(--gradient); color: white; padding: 4px 10px; border-radius: 8px; font-weight: 800; font-size: 0.82rem; min-width: 44px; text-align: center; }
.lesson-left h3 { margin: 0 0 4px; font-size: 0.98rem; }
.lesson-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* ---------- Generating page ---------- */
.generating { display: flex; justify-content: center; padding: 40px 0; }
.generating-card { max-width: 520px; text-align: center; background: var(--panel); border: 1px solid var(--border-soft); border-radius: 24px; box-shadow: var(--shadow); padding: 40px 32px; }
.spinner-wrap { margin: 28px 0; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.spinner { width: 48px; height: 48px; border: 4px solid var(--border-soft); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.status { color: var(--muted); font-weight: 600; min-height: 1.4em; }
.error-wrap { display: flex; flex-direction: column; align-items: center; gap: 16px; margin-top: 20px; }

/* ---------- Lesson ---------- */
.lesson { max-width: 760px; margin: 0 auto; }
.lesson-header { margin-bottom: 32px; }
.lesson-header h1 { margin: 0 0 12px; font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.15; letter-spacing: -0.015em; }
.lesson-meta { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.lesson-meta .badge { background: var(--accent); color: white; }

.lesson-section { margin-bottom: 32px; }
.lesson-section h2 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--accent); margin: 0 0 12px; }
.lesson-section h3 { margin: 16px 0 8px; font-size: 1rem; }
.lesson-section.callout { background: var(--bg-tint); border-left: 3px solid var(--accent); padding: 18px 22px; border-radius: 0 14px 14px 0; }
.lesson-section.callout h2 { color: var(--accent-dark); }

.prose { line-height: 1.65; font-size: 1rem; white-space: pre-wrap; }
.prose strong { color: var(--ink); }

.key-concepts { display: grid; grid-template-columns: 1fr; gap: 10px; }
.key-concepts dt { font-weight: 800; color: var(--accent-dark); }
.key-concepts dd { margin: 4px 0 0; color: var(--muted); line-height: 1.55; }

.resource-card { display: flex; justify-content: space-between; align-items: center; gap: 16px; background: var(--panel); border: 1px solid var(--border-soft); border-radius: 12px; padding: 16px 20px; text-decoration: none; color: inherit; transition: border-color 100ms, transform 100ms; }
.resource-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.resource-card h3 { margin: 0 0 6px; }
.resource-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.resource-arrow { font-size: 1.6rem; color: var(--accent); }

.slide-list { padding-left: 20px; display: flex; flex-direction: column; gap: 12px; }
.slide-list li { line-height: 1.55; }
.slide-list strong { display: block; color: var(--ink); }
.slide-list p { margin: 4px 0 0; color: var(--muted); }

pre.mermaid { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 12px; padding: 16px; overflow: auto; font-family: ui-monospace, monospace; font-size: 0.9rem; }

.quiz { display: flex; flex-direction: column; gap: 10px; }
.quiz-item { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 12px; padding: 14px 18px; }
.quiz-item summary { cursor: pointer; font-weight: 700; display: flex; align-items: flex-start; gap: 10px; list-style: none; }
.quiz-item summary::-webkit-details-marker { display: none; }
.q-num { color: var(--accent); font-weight: 800; }
.quiz-options { margin: 12px 0; padding-left: 22px; }
.quiz-answer { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border-soft); }

.checklist { padding-left: 22px; }
.checklist li { margin-bottom: 4px; }

.lesson-footer { margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border-soft); display: flex; flex-direction: column; gap: 14px; }
.nav-row { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.footer-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Admin pages ---------- */
.admin-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
.config-card { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 16px; padding: 22px; box-shadow: var(--shadow-soft); }
.config-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.config-status { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.config-status.ok { color: var(--success); }
.config-status.missing { color: var(--danger); }
.config-form { display: flex; gap: 8px; flex-wrap: wrap; }
.config-form input { flex: 1; min-width: 280px; padding: 10px 14px; border: 1px solid var(--border); border-radius: 10px; font: inherit; }
.config-form input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.14); }
.config-help { font-size: 0.86rem; color: var(--muted); margin-top: 8px; line-height: 1.5; }

.lesson-admin-list { display: flex; flex-direction: column; gap: 24px; }
.lesson-admin-group h2 { margin: 0 0 8px; font-size: 1.04rem; }
.lesson-admin-row { display: grid; grid-template-columns: 60px 1fr auto auto auto; gap: 14px; align-items: center; padding: 12px 16px; background: var(--panel); border: 1px solid var(--border-soft); border-radius: 10px; }
.lesson-admin-row .num { font-weight: 800; color: var(--accent); }
.lesson-admin-row h4 { margin: 0; font-size: 0.95rem; }
.lesson-admin-row .meta { color: var(--muted); font-size: 0.8rem; }
.platform-pill { font-size: 0.7rem; padding: 3px 8px; border-radius: 999px; font-weight: 700; }
.platform-pill.has { background: var(--success); color: white; }
.platform-pill.missing { background: var(--border-soft); color: var(--muted); }

.carousel-block { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 14px; padding: 20px; }
.carousel-block h3 { margin: 0 0 6px; }
.image-prompt-card { background: var(--bg-tint); border: 1px solid var(--border-soft); border-radius: 10px; padding: 12px 14px; margin-bottom: 8px; }
.image-prompt-card pre { white-space: pre-wrap; font-family: ui-monospace, monospace; font-size: 0.84rem; margin: 4px 0; color: var(--ink); }
.image-prompt-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }

/* ---------- Cheat sheet (print-optimised) ---------- */
.cheat-sheet { max-width: 720px; margin: 0 auto; background: white; padding: 32px; border-radius: 12px; box-shadow: var(--shadow-soft); }
.cheat-sheet h1 { color: var(--ink); margin: 0 0 4px; }
.cheat-sheet .cs-meta { color: var(--muted); font-size: 0.88rem; margin-bottom: 24px; }
.cheat-sheet h2 { color: var(--accent); font-size: 0.92rem; text-transform: uppercase; letter-spacing: 0.1em; margin: 22px 0 8px; }
.cheat-sheet ul, .cheat-sheet ol { margin: 6px 0 12px; padding-left: 22px; }
.cheat-sheet dt { font-weight: 800; color: var(--ink); margin-top: 6px; }
.cheat-sheet dd { margin: 2px 0 0; color: var(--ink-soft); }
.print-bar { display: flex; gap: 8px; max-width: 720px; margin: 0 auto 16px; }

@media print {
  .site-header, .site-footer, .print-bar { display: none !important; }
  body { background: white; }
  .cheat-sheet { box-shadow: none; padding: 0; max-width: 100%; }
  a { color: var(--ink); text-decoration: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .site-header { padding: 12px 16px; flex-wrap: wrap; gap: 8px; }
  .site-nav { gap: 10px; font-size: 0.85rem; }
  .brand-logo { width: 36px; height: 36px; }
  .site-main { padding: 24px 0; }
  .options { flex-direction: column; }
  .options .opt { width: 100%; }
  .lesson-row, .lesson-admin-row { flex-direction: column; align-items: flex-start; }
  .lesson-right { width: 100%; justify-content: space-between; }
  .table thead { display: none; }
  .table tr { display: block; padding: 12px; border-bottom: 1px solid var(--border-soft); }
  .table td { display: block; border: 0; padding: 4px 0; }
}

/* ===== Wave 1: rich lesson presentation ===== */

/* Section head with action button on the right */
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.section-head h2 { margin: 0; }
.btn-small { padding: 6px 12px !important; font-size: 0.85rem; }

/* Prose markdown content from the lesson generator */
.prose { color: var(--ink); line-height: 1.65; font-size: 1.0rem; }
.prose h1, .prose h2, .prose h3, .prose h4 {
  color: var(--ink); margin: 18px 0 8px;
}
.prose h3 { font-size: 1.05rem; }
.prose h4 { font-size: 0.98rem; }
.prose p { margin: 0 0 10px; }
.prose strong { color: var(--ink); }
.prose em { color: var(--ink-soft); }
.prose ul, .prose ol { margin: 6px 0 14px; padding-left: 22px; }
.prose li { margin: 4px 0; }
.prose a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; }
.prose a:hover { color: var(--accent-dark); }
.prose code {
  background: var(--bg-tint); padding: 2px 6px; border-radius: 4px;
  font-size: 0.9em; color: var(--accent-dark);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
.prose pre {
  background: var(--ink); color: #ede9fe; padding: 14px 16px;
  border-radius: 10px; overflow-x: auto; margin: 12px 0;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
.prose pre code { background: transparent; color: inherit; padding: 0; }
.prose blockquote {
  margin: 12px 0; padding: 8px 14px;
  border-left: 3px solid var(--accent);
  background: var(--bg-tint);
  color: var(--ink-soft); border-radius: 0 6px 6px 0;
}
.prose hr { border: 0; border-top: 1px solid var(--border-soft); margin: 18px 0; }

/* Branded comparison tables (from markdown tables in lesson body) */
.prose table {
  width: 100%; border-collapse: separate; border-spacing: 0;
  margin: 14px 0; border-radius: 12px; overflow: hidden;
  box-shadow: var(--shadow-soft);
  font-size: 0.95rem;
}
.prose thead th {
  background: var(--gradient); color: white !important;
  text-align: left; padding: 10px 14px; font-weight: 700;
  letter-spacing: 0.02em;
}
.prose tbody td {
  padding: 10px 14px; border-top: 1px solid var(--border-soft);
  background: var(--panel); vertical-align: top;
}
.prose tbody tr:nth-child(even) td { background: var(--bg-tint); }
.prose tbody tr:hover td { background: rgba(124, 58, 237, 0.06); }

/* Interactive quiz */
.quiz { list-style: none; padding: 0; counter-reset: q; }
.quiz-item {
  padding: 14px 18px; margin: 0 0 12px; border-radius: 12px;
  background: var(--panel); border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-soft); transition: border-color .2s;
}
.quiz-item.answered-ok { border-color: var(--success); }
.quiz-item.answered-miss { border-color: var(--danger); }
.quiz-item .q-text { margin: 0 0 10px; font-size: 1rem; }
.quiz-options { display: flex; flex-direction: column; gap: 6px; margin: 6px 0 10px; }
.quiz-options .opt {
  display: flex; gap: 10px; align-items: center; padding: 8px 12px;
  border: 1px solid var(--border-soft); border-radius: 8px; cursor: pointer;
  transition: background .15s, border-color .15s;
}
.quiz-options .opt:hover { background: var(--bg-tint); border-color: var(--accent-light); }
.quiz-options input[type=radio] { accent-color: var(--accent); }
.quiz-short {
  width: 100%; padding: 10px 12px;
  border: 1px solid var(--border-soft); border-radius: 8px;
  font: inherit; resize: vertical;
}
.quiz-short:focus { outline: 2px solid var(--accent-light); border-color: var(--accent); }
.quiz-actions { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.quiz-feedback {
  margin-top: 12px; padding: 12px 14px; border-radius: 8px;
  background: var(--bg-tint);
}
.quiz-feedback .result { margin: 0 0 4px; font-weight: 700; }
.quiz-feedback .result.ok { color: var(--success); }
.quiz-feedback .result.miss { color: var(--danger); }
.quiz-feedback .correct { margin: 4px 0; }

/* Practical task with checkable steps + notes */
.practical-task .practical-steps,
.practical-task .checklist { list-style: none; padding: 0; }
.practical-task .practical-steps li,
.practical-task .checklist li { margin: 6px 0; }
.practical-task label { display: inline-flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.practical-task input[type=checkbox] { margin-top: 4px; accent-color: var(--accent); }
.practical-notes-wrap { margin-top: 12px; }
.practical-notes-wrap label { display: block; margin-bottom: 6px; }
.practical-notes {
  width: 100%; min-height: 100px; padding: 10px 12px;
  border: 1px solid var(--border-soft); border-radius: 8px;
  font: inherit; resize: vertical; background: var(--panel);
}
.practical-notes:focus { outline: 2px solid var(--accent-light); border-color: var(--accent); }
.practical-actions { display: flex; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.practical-status.ok { color: var(--success); }
.practical-status.miss { color: var(--danger); }

/* Polished loading spinner: logo pulse + outer progress ring */
.generating { display: flex; justify-content: center; padding: 40px 0; }
.generating-card {
  background: var(--panel); padding: 40px 48px; border-radius: 20px;
  box-shadow: var(--shadow); max-width: 560px; width: 100%;
  text-align: center;
}
.gen-ring-wrap { position: relative; width: 180px; height: 180px; margin: 24px auto; }
.gen-ring {
  width: 100%; height: 100%;
  transform: rotate(-90deg);
}
.gen-ring .track {
  stroke: var(--border-soft); fill: none; stroke-width: 6;
}
.gen-ring .arc {
  stroke: url(#ixa-gradient); fill: none; stroke-width: 6;
  stroke-linecap: round;
  transition: stroke-dashoffset .35s ease;
}
.gen-logo {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 96px; height: 96px;
  animation: pulse 1.6s ease-in-out infinite;
  filter: drop-shadow(0 6px 18px rgba(124, 58, 237, 0.35));
}
.gen-pct {
  position: absolute; bottom: -8px; left: 50%;
  transform: translateX(-50%);
  font-size: 0.85rem; font-weight: 800; color: var(--accent-dark);
  background: var(--panel); padding: 2px 10px; border-radius: 999px;
  border: 1px solid var(--border-soft);
}
@keyframes pulse {
  0%   { transform: translate(-50%, -50%) scale(1);   opacity: 1;   }
  50%  { transform: translate(-50%, -50%) scale(1.08); opacity: 0.85; }
  100% { transform: translate(-50%, -50%) scale(1);   opacity: 1;   }
}
.status { color: var(--ink-soft); margin: 8px 0 4px; font-weight: 600; }

/* Slide deck (present mode) */
.deck { min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: var(--gradient); padding: 32px; }
.deck-slide {
  background: var(--panel); width: min(1000px, 100%); padding: 56px 64px;
  border-radius: 18px; box-shadow: var(--shadow);
  min-height: 520px; display: flex; flex-direction: column;
}
.deck-slide[hidden] { display: none !important; }
.deck-num { color: var(--muted); font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; }
.deck-title { color: var(--ink); font-size: clamp(1.6rem, 3.2vw, 2.4rem); margin: 6px 0 14px; }
.deck-body { color: var(--ink); font-size: 1.15rem; line-height: 1.6; }
.deck-visual { margin-top: auto; padding-top: 24px; color: var(--muted); font-style: italic; font-size: 0.9rem; }
.deck-controls {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 12px; align-items: center;
  background: rgba(255,255,255,.92); padding: 10px 18px; border-radius: 999px;
  box-shadow: var(--shadow-soft);
}
.deck-controls button {
  background: transparent; border: 0; cursor: pointer; padding: 6px 12px;
  border-radius: 8px; font: inherit; font-weight: 700; color: var(--ink);
}
.deck-controls button:hover { background: var(--bg-tint); color: var(--accent-dark); }
.deck-counter { color: var(--ink-soft); font-weight: 700; font-size: 0.92rem; }
.deck-exit { color: var(--accent); text-decoration: none; font-weight: 700; font-size: 0.9rem; padding: 6px 12px; border-radius: 8px; }
.deck-exit:hover { background: var(--bg-tint); }

/* Dashboard readiness widget */
.readiness {
  background: var(--panel); padding: 22px 26px; border-radius: 16px;
  border: 1px solid var(--border-soft); box-shadow: var(--shadow-soft);
  margin: 16px 0 24px;
}
.readiness-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; }
.readiness h3 { margin: 0; }
.readiness .stars { font-size: 1.5rem; letter-spacing: 0.05em; color: var(--accent); }
.readiness .stars .star { filter: grayscale(.85) opacity(.4); }
.readiness .stars .star.on { filter: none; }
.readiness-bar { margin-top: 14px; height: 10px; background: var(--bg-tint); border-radius: 999px; overflow: hidden; }
.readiness-bar .fill {
  height: 100%; background: var(--gradient); width: 0%;
  border-radius: 999px; transition: width .6s ease;
}
.readiness-stats { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; color: var(--muted); font-size: 0.9rem; }
.readiness-stats strong { color: var(--ink); }
.readiness-cert { margin-top: 10px; color: var(--ink-soft); }
.readiness-cert.ready { color: var(--success); font-weight: 700; }

/* Cheat sheet — branded, printable */
.cheatsheet {
  background: var(--panel); padding: 36px 42px;
  border-radius: 14px; box-shadow: var(--shadow);
  max-width: 880px; margin: 24px auto;
}
.cheatsheet .cs-head { display: flex; justify-content: space-between; align-items: baseline; }
.cheatsheet h1 { margin: 6px 0 18px; }
.cheatsheet .cs-section { margin-bottom: 18px; }
.cheatsheet .cs-section h2 {
  margin: 0 0 6px; font-size: 1rem; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--accent);
}
.cheatsheet .cs-actions { margin: 14px 0; display: flex; gap: 10px; }
@media print {
  .site-header, .site-footer, .cs-actions, .breadcrumb { display: none !important; }
  body { background: white; }
  .cheatsheet { box-shadow: none; padding: 0; max-width: 100%; }
  .prose table { box-shadow: none; }
  .prose thead th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  a { color: var(--ink); text-decoration: none; }
}

/* =================================================================
   Landing page — editorial-futurist
   Fraunces serif + JetBrains Mono accents, dark hero, asymmetric
   layout, animated SVG mesh, grain overlay, mosaic curriculum.
   ================================================================= */

:root {
  --serif: "Fraunces", "Iowan Old Style", "Apple Garamond", Georgia, serif;
  --mono:  "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --cream: #f4f1ea;
  --paper: #ecead2;
  --ink-deep: #0e0c2a;
  --line: #1e1b4b;
  --hl-warm: #f5b945;
  --hl-pink: #ff7da3;
}

/* Grain overlay covers whole page on the landing */
.lp-grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 1;
  opacity: .08; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* Mono utility — paired with the serif throughout */
.mono { font-family: var(--mono); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; font-size: 0.74rem; }

.lp-kicker {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--ink); margin: 0 0 18px;
}
.lp-kicker .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(124,58,237,.15); animation: ringPulse 2.4s ease-in-out infinite; }
.lp-kicker .dot.light { background: var(--hl-warm); box-shadow: 0 0 0 4px rgba(245,185,69,.25); }
@keyframes ringPulse { 0%,100% { box-shadow: 0 0 0 4px rgba(124,58,237,.15); } 50% { box-shadow: 0 0 0 10px rgba(124,58,237,0); } }

.lp-h1, .lp-h2 {
  font-family: var(--serif); font-weight: 400;
  letter-spacing: -0.02em; color: var(--ink-deep);
  font-variation-settings: "opsz" 144, "SOFT" 60;
}
.lp-h1 { font-size: clamp(2.4rem, 5.8vw, 4.4rem); line-height: 0.98; margin: 0 0 22px; }
.lp-h1 em { font-style: italic; color: var(--accent); font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1; }
.lp-h2 { font-size: clamp(1.9rem, 4.2vw, 3rem); line-height: 1.04; margin: 0 0 14px; }
.lp-h2 em { font-style: italic; color: var(--accent); font-variation-settings: "opsz" 144, "SOFT" 100, "WONK" 1; }
.lp-h2.invert { color: white; }

.lp-lede {
  font-size: clamp(1.05rem, 1.4vw, 1.2rem); line-height: 1.6;
  color: var(--ink-soft); max-width: 56ch; margin: 0 0 26px;
}
.lp-lede .hl {
  background-image: linear-gradient(180deg, transparent 60%, rgba(245,185,69,.45) 60%);
  padding: 0 .15em;
}

.lp-section { padding: 88px 0; position: relative; z-index: 2; }
.lp-band { max-width: 920px; margin: 0 0 36px; }
.lp-section-sub { color: var(--ink-soft); font-size: 1.02rem; line-height: 1.6; max-width: 60ch; margin: 0 0 28px; }

/* ---------- Buttons ---------- */
.lp-btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px;
  font-weight: 700; font-size: 0.98rem; text-decoration: none; border: 1.5px solid transparent;
  transition: transform .25s cubic-bezier(.2,.8,.2,1), background .15s, color .15s, border-color .15s;
  cursor: pointer;
}
.lp-btn-ink     { background: var(--ink-deep); color: white; border-color: var(--ink-deep); }
.lp-btn-ink:hover { background: var(--accent); border-color: var(--accent); }
.lp-btn-ghost   { background: transparent; color: var(--ink-deep); border-color: rgba(14,12,42,.18); }
.lp-btn-ghost:hover { background: var(--ink-deep); color: white; border-color: var(--ink-deep); }
.lp-btn-light   { background: white; color: var(--ink-deep); border-color: white; }
.lp-btn-light:hover { background: var(--hl-warm); border-color: var(--hl-warm); }
.lp-btn-outline { background: transparent; color: white; border-color: rgba(255,255,255,.35); }
.lp-btn-outline:hover { background: white; color: var(--ink-deep); border-color: white; }

.lp-cta-cluster { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.lp-cta-row { display: flex; justify-content: center; margin-top: 32px; }
.lp-fineprint {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
  margin: 16px 0 0; color: var(--ink-soft);
}
.lp-fineprint .sep { color: rgba(14,12,42,.25); }
.lp-fineprint.invert { color: rgba(255,255,255,.7); }

/* ---------- Hero ---------- */
.lp-hero {
  position: relative; z-index: 2;
  background: var(--cream);
  margin: -40px calc(50% - 50vw) 0; /* break out of the .site-main container */
  padding: 56px max(28px, calc(50vw - 560px)) 0;
  overflow: hidden;
}
.lp-hero-inner {
  display: grid; gap: 40px;
  grid-template-columns: 1fr;
  align-items: end;
  padding-bottom: 48px;
}
@media (min-width: 980px) {
  .lp-hero-inner { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.9fr); gap: 64px; }
}
.lp-hero-copy { padding-top: 24px; }
.lp-hero-art {
  margin: 0; position: relative;
  display: flex; align-items: center; justify-content: center;
  min-height: 480px;
}
.lp-hero-art .lp-mesh-backdrop {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain; opacity: 0.10;
  filter: drop-shadow(0 12px 36px rgba(124,58,237,.18));
  pointer-events: none;
  z-index: 0;
  animation: backdropBreath 9s ease-in-out infinite;
}
@keyframes backdropBreath {
  0%, 100% { opacity: 0.10; transform: scale(1); }
  50%      { opacity: 0.18; transform: scale(1.02); }
}
.lp-hero-art .lp-mesh {
  position: relative; z-index: 1;
  width: 100%; height: auto; max-width: 480px;
  display: block; margin: 0 auto;
}

/* Mesh animations */
.lp-mesh .ln {
  stroke-dasharray: 4 6; stroke-dashoffset: 0;
  animation: lineFlow 4.2s linear infinite;
}
.lp-mesh .ln:nth-child(even) { animation-direction: reverse; animation-duration: 5.6s; }
@keyframes lineFlow { to { stroke-dashoffset: -120; } }
.lp-mesh .node { animation: nodePulse 3.2s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
.lp-mesh .node.n2 { animation-delay: .4s; }
.lp-mesh .node.n3 { animation-delay: .8s; }
.lp-mesh .node.n4 { animation-delay: 1.2s; }
.lp-mesh .node.n5 { animation-delay: 1.6s; }
.lp-mesh .node.nC { animation-delay: 2s; }
@keyframes nodePulse { 0%,100% { opacity: 1; } 50% { opacity: 0.55; } }
.lp-mesh .node text {
  font-family: var(--mono); font-size: 9px; fill: var(--ink-deep); letter-spacing: 0.04em; text-transform: uppercase; font-weight: 600;
}
.lp-mesh .centerlabel { font-family: var(--serif) !important; font-size: 11px !important; font-style: italic; font-weight: 500; fill: var(--accent) !important; text-transform: none !important; letter-spacing: 0; }

/* Marquee ticker — pure CSS scroll */
.lp-ticker {
  border-top: 1px solid rgba(14,12,42,.12);
  border-bottom: 1px solid rgba(14,12,42,.12);
  margin: 8px 0 0;
  overflow: hidden; background: var(--paper);
}
.lp-ticker-track {
  display: flex; gap: 32px; align-items: center; white-space: nowrap;
  padding: 14px 0;
  animation: tickerScroll 60s linear infinite;
  font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.06em;
  color: var(--ink-deep); text-transform: uppercase;
}
.lp-ticker-track span { flex-shrink: 0; }
.lp-ticker:hover .lp-ticker-track { animation-play-state: paused; }
@keyframes tickerScroll { to { transform: translateX(-50%); } }

/* ---------- Diagnostic preview ---------- */
.lp-diag-card {
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 20px; padding: 36px 32px;
  box-shadow: 0 20px 50px rgba(30,27,75,.10);
  max-width: 760px; margin-top: 8px;
  position: relative; overflow: hidden;
}
.lp-diag-card::before {
  content: ""; position: absolute; top: 0; right: 0; width: 240px; height: 240px;
  background: radial-gradient(circle at top right, rgba(124,58,237,.10), transparent 70%);
  pointer-events: none;
}
.diag-progress { display: flex; gap: 8px; margin-bottom: 26px; }
.diag-progress .step { height: 4px; flex: 1; background: rgba(14,12,42,.08); border-radius: 4px; transition: background .3s; }
.diag-progress .step.active { background: var(--accent); }
.diag-progress .step.done { background: var(--ink-deep); }
.diag-eyebrow { color: var(--accent); margin: 0 0 12px; }
.diag-q { font-family: var(--serif); font-size: clamp(1.3rem, 2.3vw, 1.65rem); line-height: 1.2; color: var(--ink-deep); margin: 0 0 22px; font-weight: 500; }
.diag-opts { display: grid; gap: 10px; }
.diag-opt {
  display: flex; justify-content: space-between; align-items: center;
  background: transparent; border: 1.5px solid rgba(14,12,42,.12);
  padding: 16px 20px; border-radius: 12px; font: inherit; cursor: pointer;
  color: var(--ink-deep); font-weight: 600; text-align: left;
  transition: all .2s cubic-bezier(.2,.8,.2,1);
}
.diag-opt .arrow { opacity: 0; transform: translateX(-6px); transition: all .2s; color: var(--accent); }
.diag-opt:hover { border-color: var(--accent); background: rgba(124,58,237,.05); transform: translateX(4px); }
.diag-opt:hover .arrow { opacity: 1; transform: translateX(0); }
.diag-opt.picked { background: var(--accent); color: white; border-color: var(--accent); }
.diag-summary { list-style: none; padding: 0; margin: 18px 0 26px; display: grid; gap: 14px; }
.diag-summary li { display: grid; grid-template-columns: 24px 1fr; gap: 10px 14px; font-family: var(--serif); color: var(--ink-deep); }
.diag-summary li .bullet { color: var(--accent); font-weight: 700; }
.diag-summary li strong { font-weight: 500; font-size: 1rem; line-height: 1.4; grid-column: 2; }
.diag-summary li .sig { grid-column: 2; color: var(--ink-soft); font-family: var(--mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; }
.diag-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; }
.lp-diag-footer { margin: 18px 0 0; color: var(--muted); }

/* ---------- Pathway rail ---------- */
.lp-rail { list-style: none; padding: 0; display: grid; gap: 18px; counter-reset: rail; }
@media (min-width: 760px) { .lp-rail { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .lp-rail { grid-template-columns: repeat(4, 1fr); } }
.lp-rail li {
  background: var(--panel); border: 1px solid rgba(14,12,42,.08); border-radius: 18px;
  padding: 26px 24px 22px; position: relative; transition: transform .3s, box-shadow .3s;
  overflow: hidden;
}
.lp-rail li:hover { transform: translateY(-4px); box-shadow: 0 14px 40px rgba(30,27,75,.10); }
.lp-rail-num {
  display: inline-block; font-family: var(--mono); font-weight: 800; font-size: 0.78rem;
  color: var(--accent); letter-spacing: 0.1em; margin-bottom: 10px;
}
.lp-rail li h3 { font-family: var(--serif); font-weight: 500; font-size: 1.18rem; color: var(--ink-deep); margin: 6px 0 8px; }
.lp-rail li p { color: var(--ink-soft); font-size: 0.92rem; line-height: 1.55; margin: 0; }
.lp-rail-glyph { position: absolute; bottom: -8px; right: -8px; width: 90px; height: 90px; color: rgba(124,58,237,.15); }

/* ---------- Tracks mosaic ---------- */
.lp-track-mosaic {
  display: grid; gap: 14px;
  grid-template-columns: 1fr;
}
@media (min-width: 800px) {
  .lp-track-mosaic { grid-template-columns: repeat(6, 1fr); }
  .lp-track-mosaic .t1 { grid-column: span 3; }
  .lp-track-mosaic .t2 { grid-column: span 3; }
  .lp-track-mosaic .t3 { grid-column: span 2; }
  .lp-track-mosaic .t4 { grid-column: span 2; }
  .lp-track-mosaic .t5 { grid-column: span 2; }
}
.lp-track-mosaic .track {
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 18px; padding: 26px 26px 22px; position: relative; overflow: hidden;
  transition: transform .3s, box-shadow .3s, background .3s;
}
.lp-track-mosaic .track:hover { transform: translateY(-3px); box-shadow: 0 16px 40px rgba(30,27,75,.10); }
.lp-track-mosaic .track:nth-child(2) { background: var(--ink-deep); color: var(--cream); border-color: var(--ink-deep); }
.lp-track-mosaic .track:nth-child(2) h3, .lp-track-mosaic .track:nth-child(2) p { color: white; }
.lp-track-mosaic .track:nth-child(4) { background: var(--paper); }
.lp-track-mosaic .track .track-tag { color: var(--accent); margin: 0 0 8px; display: inline-block; }
.lp-track-mosaic .track:nth-child(2) .track-tag { color: var(--hl-warm); }
.lp-track-mosaic .track h3 { font-family: var(--serif); font-weight: 500; font-size: 1.3rem; color: var(--ink-deep); margin: 0 0 8px; }
.lp-track-mosaic .track p { color: var(--ink-soft); font-size: 0.95rem; line-height: 1.5; margin: 0; }
.lp-track-mosaic .track .track-art { position: absolute; bottom: -10px; right: -10px; width: 80px; height: 80px; color: rgba(124,58,237,.2); }
.lp-track-mosaic .track:nth-child(2) .track-art { color: rgba(255,255,255,.15); }

/* ---------- Curriculum (typographic list) ---------- */
.lp-curriculum { list-style: none; padding: 0; margin: 0; border-top: 1px solid rgba(14,12,42,.12); }
.lp-curr-row {
  display: grid; grid-template-columns: 70px 1fr 30px;
  gap: 24px; align-items: center;
  padding: 22px 4px; border-bottom: 1px solid rgba(14,12,42,.12);
  transition: padding .25s ease, background .25s ease;
  cursor: default;
}
.lp-curr-row:hover { padding-left: 14px; padding-right: 14px; background: var(--paper); }
.lp-curr-num { color: var(--accent); font-weight: 800; font-size: 0.9rem; }
.lp-curr-meta h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.15rem, 2vw, 1.45rem); color: var(--ink-deep); margin: 0 0 4px; line-height: 1.2; }
.lp-curr-meta p { color: var(--ink-soft); font-size: 0.95rem; line-height: 1.5; margin: 0; max-width: 75ch; }
.lp-curr-arrow { font-size: 1.3rem; color: rgba(14,12,42,.25); transition: transform .25s, color .25s; text-align: right; }
.lp-curr-row:hover .lp-curr-arrow { color: var(--accent); transform: translateX(6px); }

/* ---------- Feature grid (practical + responsible) ---------- */
.lp-feat-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .lp-feat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .lp-feat-grid { grid-template-columns: repeat(4, 1fr); } }
.lp-feat-grid .feat {
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 14px; padding: 24px 22px;
  transition: transform .25s, box-shadow .25s;
}
.lp-feat-grid .feat:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(30,27,75,.10); }
.lp-feat-grid .feat .feat-num { color: var(--accent); margin: 0 0 12px; display: block; }
.lp-feat-grid .feat h3 { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; color: var(--ink-deep); margin: 0 0 8px; }
.lp-feat-grid .feat p { color: var(--ink-soft); font-size: 0.93rem; line-height: 1.5; margin: 0; }

/* ---------- Capstone ---------- */
.lp-capstone-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .lp-capstone-grid { grid-template-columns: repeat(3, 1fr); } }
.lp-capstone-grid article {
  background: var(--paper); border-radius: 18px; padding: 28px 26px;
  border: 1px solid rgba(14,12,42,.08);
}
.lp-capstone-grid article h3 { font-family: var(--serif); font-weight: 500; color: var(--ink-deep); margin: 0 0 10px; font-size: 1.2rem; }
.lp-capstone-grid article p { color: var(--ink-soft); margin: 0; line-height: 1.55; font-size: 0.95rem; }

/* ---------- Certification ---------- */
.lp-cert-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .lp-cert-grid { grid-template-columns: repeat(3, 1fr); } }
.lp-cert-grid article {
  background: var(--panel); border-radius: 18px; padding: 26px 24px;
  border: 1px solid rgba(14,12,42,.08); position: relative;
}
.lp-cert-grid article.cert-disclaimer { background: var(--ink-deep); color: var(--cream); border-color: var(--ink-deep); }
.lp-cert-grid article.cert-disclaimer h3, .lp-cert-grid article.cert-disclaimer p { color: white; }
.lp-cert-grid article.cert-disclaimer .cert-tag { color: var(--hl-warm); }
.lp-cert-grid .cert-tag { color: var(--accent); display: inline-block; margin: 0 0 12px; }
.lp-cert-grid h3 { font-family: var(--serif); font-weight: 500; font-size: 1.25rem; color: var(--ink-deep); margin: 0 0 10px; }
.lp-cert-grid p { color: var(--ink-soft); line-height: 1.55; margin: 0; font-size: 0.95rem; }

/* ---------- FAQ ---------- */
.lp-faq-list { display: grid; gap: 8px; max-width: 880px; }
.lp-faq-list details {
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 12px; padding: 18px 22px;
  transition: border-color .2s, box-shadow .2s;
}
.lp-faq-list details[open] { border-color: var(--accent); box-shadow: 0 8px 24px rgba(30,27,75,.08); }
.lp-faq-list summary {
  font-family: var(--serif); font-weight: 500; font-size: 1.1rem;
  color: var(--ink-deep); cursor: pointer;
  list-style: none; padding-right: 28px; position: relative;
  line-height: 1.3;
}
.lp-faq-list summary::-webkit-details-marker { display: none; }
.lp-faq-list summary::after {
  content: "+"; position: absolute; right: 0; top: -2px;
  color: var(--accent); font-weight: 800; font-size: 1.5rem;
  transition: transform .2s;
}
.lp-faq-list details[open] summary::after { content: "−"; }
.lp-faq-list p { margin: 12px 0 0; color: var(--ink-soft); line-height: 1.6; }

/* ---------- Final CTA ---------- */
.lp-final {
  background: linear-gradient(135deg, #0e0c2a 0%, #1e1b4b 50%, #4c1d95 100%);
  color: white; border-radius: 28px;
  margin: 24px 0 0; padding: 60px 36px;
  position: relative; overflow: hidden;
}
.lp-final::before {
  content: ""; position: absolute; inset: 0;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.3 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: 0.12; pointer-events: none;
}
.lp-final-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr; gap: 36px; align-items: center;
}
@media (min-width: 880px) { .lp-final-grid { grid-template-columns: 1.4fr 1fr; gap: 56px; } }
.lp-final-art { width: 100%; max-width: 320px; height: auto; justify-self: end; }

/* ---------- Scroll reveal ---------- */
.lp-section, .lp-hero, .lp-final {
  opacity: 0; transform: translateY(24px);
  transition: opacity .8s cubic-bezier(.2,.8,.2,1), transform .8s cubic-bezier(.2,.8,.2,1);
}
.lp-section.in-view, .lp-hero.in-view, .lp-final.in-view { opacity: 1; transform: none; }

/* Reduced motion respect */
@media (prefers-reduced-motion: reduce) {
  .lp-mesh .ln, .lp-mesh .node, .lp-ticker-track, .lp-kicker .dot { animation: none !important; }
  .lp-section, .lp-hero, .lp-final { opacity: 1; transform: none; transition: none; }
}

/* Header tweak — make brand-name use the serif on landing only */
body.has-lp .brand-name { font-family: var(--serif); font-weight: 500; letter-spacing: 0; font-size: 1.08rem; }
body.has-lp .brand-tagline { font-family: var(--mono); }

/* ============ Landing additions: hover-expand tracks + flip feature cards ============ */

/* Adaptive tracks: clickable, expand on hover/focus to reveal detail block */
.lp-track-mosaic .track {
  cursor: pointer;
  display: flex; flex-direction: column;
}
.lp-track-mosaic .track .track-expand {
  margin-top: 14px;
  max-height: 0; opacity: 0;
  overflow: hidden;
  transform: translateY(8px);
  transition: max-height .55s cubic-bezier(.2,.8,.2,1),
              opacity .35s ease, transform .55s cubic-bezier(.2,.8,.2,1),
              margin-top .35s ease;
}
.lp-track-mosaic .track:hover .track-expand,
.lp-track-mosaic .track:focus .track-expand,
.lp-track-mosaic .track:focus-within .track-expand {
  max-height: 320px; opacity: 1; transform: translateY(0);
}
.lp-track-mosaic .track .track-expand h4 {
  font-family: var(--mono); font-size: 0.72rem;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--accent); margin: 0 0 8px;
}
.lp-track-mosaic .track:nth-child(2) .track-expand h4 { color: var(--hl-warm); }
.lp-track-mosaic .track .track-expand ul {
  list-style: none; padding: 0; margin: 0;
  display: grid; gap: 6px;
  color: var(--ink-soft); font-size: 0.9rem; line-height: 1.45;
}
.lp-track-mosaic .track:nth-child(2) .track-expand ul { color: rgba(255,255,255,.85); }
.lp-track-mosaic .track .track-expand li {
  padding-left: 14px; position: relative;
}
.lp-track-mosaic .track .track-expand li::before {
  content: "→"; position: absolute; left: 0; top: 0;
  color: var(--accent); font-weight: 700;
}
.lp-track-mosaic .track:nth-child(2) .track-expand li::before { color: var(--hl-warm); }
.lp-track-mosaic .track:hover { transform: translateY(-6px) scale(1.005); }

/* Module rows are anchors — reset link styling */
.lp-curriculum li a.lp-curr-row {
  text-decoration: none; color: inherit;
  display: grid; grid-template-columns: 70px 1fr 30px;
  gap: 24px; align-items: center;
}
.lp-curriculum li a.lp-curr-row:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 8px;
}

/* Practical resources: 3D flip card to reveal sample on hover/focus */
.feat-flip {
  perspective: 1200px; position: relative;
  min-height: 280px;
}
.feat-flip .feat-face, .feat-flip .feat-back {
  position: absolute; inset: 0;
  padding: 24px 22px;
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 14px;
  backface-visibility: hidden;
  transition: transform .55s cubic-bezier(.2,.8,.2,1), box-shadow .25s;
}
.feat-flip .feat-back {
  background: var(--ink-deep);
  color: var(--cream);
  transform: rotateY(180deg);
  overflow: hidden; display: flex; flex-direction: column; gap: 10px;
}
.feat-flip:hover .feat-face,
.feat-flip:focus-within .feat-face { transform: rotateY(-180deg); }
.feat-flip:hover .feat-back,
.feat-flip:focus-within .feat-back { transform: rotateY(0); }
.feat-flip:hover { box-shadow: 0 22px 50px rgba(30,27,75,.18); }

.feat-flip .feat-face h3,
.feat-flip .feat-face p { margin: 0 0 8px; }
.feat-flip .feat-hint {
  position: absolute; bottom: 14px; left: 22px; right: 22px;
  color: var(--accent); display: flex; justify-content: space-between;
  opacity: .9;
}
.feat-flip .feat-back .feat-num { color: var(--hl-warm); }
.feat-pre {
  font-family: var(--mono); font-size: 0.74rem; line-height: 1.5;
  color: rgba(244, 241, 234, 0.92);
  background: transparent;
  margin: 0; padding: 0;
  white-space: pre-wrap; word-break: normal; flex: 1;
  overflow-y: auto;
}
.feat-slide {
  background: rgba(255,255,255,.06); border-radius: 8px; padding: 14px 16px;
  flex: 1; display: flex; flex-direction: column; gap: 10px;
}
.feat-slide-num { font-family: var(--mono); font-size: 0.66rem; color: var(--hl-warm); letter-spacing: 0.12em; }
.feat-slide-h { font-family: var(--serif); font-size: 1.25rem; line-height: 1.15; color: white; }
.feat-slide-b { font-size: 0.85rem; color: rgba(255,255,255,.85); line-height: 1.5; }

@media (prefers-reduced-motion: reduce) {
  .feat-flip .feat-face, .feat-flip .feat-back { transition: none; }
  .feat-flip .feat-face { transform: rotateY(0); }
  .feat-flip .feat-back { display: none; }
  .lp-track-mosaic .track .track-expand { transition: none; }
}

/* ============ Loading games panel (rotates on each reload) ============ */
.lg-wrap {
  max-width: 520px; margin: 28px auto 0;
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 14px 14px 16px;
  box-shadow: var(--shadow-soft);
}
.lg-eyebrow {
  display: flex; align-items: center; gap: 8px;
  margin: 0 0 8px; color: var(--accent-dark);
  font-size: 0.72rem; letter-spacing: 0.1em;
}
.lg-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); animation: ringPulse 2s ease-in-out infinite;
}
.lg-bar {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px;
  align-items: center; margin-bottom: 10px;
}
.lg-name { color: var(--accent); font-size: 0.74rem; }
.lg-help { color: var(--muted); font-size: 0.78rem; line-height: 1.35; }
.lg-cycle {
  border: 1px solid var(--border-soft); background: transparent;
  border-radius: 8px; padding: 6px 10px; cursor: pointer;
  font: inherit; font-size: 0.78rem; color: var(--ink);
  transition: all .15s;
}
.lg-cycle:hover { background: var(--bg-tint); color: var(--accent-dark); border-color: var(--accent-light); }
.lg-canvas {
  display: block; width: 100%; height: auto;
  max-width: 460px; aspect-ratio: 460 / 260;
  margin: 0 auto;
  background: #0e0c2a; border-radius: 10px;
  cursor: pointer; outline: none;
  image-rendering: pixelated;
}
.lg-canvas:focus { box-shadow: 0 0 0 3px rgba(124, 58, 237, .4); }

/* ============ Games panel: in-card sizing for spinner placement ============ */
.generating-card .lg-wrap {
  margin: 24px 0 8px;
  padding: 12px;
  max-width: 100%;
  background: var(--bg-tint);
  border: 1px solid var(--border-soft);
}
.generating-card .lg-canvas { max-width: 100%; }
.lg-skipped { margin-top: 16px; }

/* ============ Responsive polish across the platform ============ */

/* Header collapses on narrow screens */
@media (max-width: 720px) {
  .site-header { padding: 10px 16px; flex-wrap: wrap; gap: 8px; }
  .site-nav { gap: 10px; flex-wrap: wrap; }
  .site-nav a { font-size: 0.86rem; }
  .site-nav .user-pill { display: none; }   /* keep header tight */
  .brand-logo { width: 36px; height: 36px; }
  .brand-name { font-size: 0.92rem; }
  .brand-tagline { font-size: 0.62rem; }
  .site-main { padding: 24px 0; }
}

/* Hero shrinks on tablets / phones */
@media (max-width: 720px) {
  .lp-hero { padding-top: 32px; }
  .lp-hero-inner { gap: 24px; padding-bottom: 28px; }
  .lp-h1 { font-size: clamp(1.85rem, 8vw, 2.6rem); }
  .lp-h2 { font-size: clamp(1.5rem, 6.5vw, 2rem); }
  .lp-lede { font-size: 1rem; }
  .lp-cta-cluster { gap: 10px; }
  .lp-btn { padding: 12px 18px; font-size: 0.9rem; width: 100%; justify-content: center; }
  .lp-cta-cluster .lp-btn { width: auto; flex: 1 1 0; min-width: 180px; }
  .lp-section { padding: 56px 0; }
  .lp-section-tinted { padding: 40px 18px; }
  .lp-ticker-track { font-size: 0.7rem; gap: 18px; }
}

/* Module curriculum list: stack number/meta on tiny screens */
@media (max-width: 540px) {
  .lp-curriculum li a.lp-curr-row {
    grid-template-columns: 1fr 24px;
    gap: 6px 12px;
  }
  .lp-curr-num { grid-column: 1; }
  .lp-curr-meta { grid-column: 1 / span 2; }
  .lp-curr-arrow { grid-row: 1; grid-column: 2; }
}

/* Track mosaic: stack on narrow, override the desktop 2-3 / 2-2-2 grid */
@media (max-width: 799px) {
  .lp-track-mosaic { grid-template-columns: 1fr !important; }
  .lp-track-mosaic .track { grid-column: span 1 !important; }
  .feat-flip { min-height: 240px; }
}

/* Lesson page polish on mobile */
@media (max-width: 720px) {
  .lesson-header h1 { font-size: clamp(1.6rem, 6vw, 2.2rem); line-height: 1.1; }
  .lesson-section { padding: 4px 0; }
  .lesson-section h2 { font-size: 1.15rem; }
  .prose { font-size: 0.96rem; }
  .quiz-item { padding: 12px 14px; }
  .quiz-options .opt { padding: 10px 12px; }
  .footer-actions { flex-wrap: wrap; gap: 8px; }
  .footer-actions .btn-primary, .footer-actions .btn-secondary { width: 100%; text-align: center; }
  .nav-row { flex-direction: column; gap: 8px; }
  .nav-row a { width: 100%; text-align: center; }
}

/* Dashboard readiness + module list */
@media (max-width: 720px) {
  .readiness { padding: 16px 18px; }
  .readiness-head { flex-direction: column; align-items: flex-start; gap: 10px; }
  .readiness .stars { font-size: 1.3rem; }
  .readiness-stats { gap: 10px; font-size: 0.85rem; }
  .module-list .module-card,
  .lesson-list .lesson-row { padding: 14px 16px; }
  .lesson-row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .lesson-left { width: 100%; }
  .lesson-right { width: 100%; display: flex; justify-content: space-between; }
}

/* Slide deck — fit narrow screens */
@media (max-width: 720px) {
  .deck { padding: 16px; }
  .deck-slide { padding: 32px 24px; min-height: 380px; }
  .deck-title { font-size: clamp(1.4rem, 6vw, 2rem); }
  .deck-body { font-size: 1rem; }
  .deck-controls { padding: 8px 14px; gap: 8px; bottom: 12px; }
  .deck-controls button { padding: 5px 10px; font-size: 0.85rem; }
}

/* Admin lesson detail polish on mobile */
@media (max-width: 720px) {
  .admin-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
  .carousel-block { padding: 16px; }
  .image-prompt-card pre { font-size: 0.78rem; }
}

/* Diagnostic card on narrow screens */
@media (max-width: 540px) {
  .lp-diag-card { padding: 24px 18px; }
  .diag-q { font-size: 1.15rem; }
  .diag-opt { padding: 13px 14px; font-size: 0.95rem; }
}

/* Final CTA stacks the art block under on narrow */
@media (max-width: 720px) {
  .lp-final { padding: 40px 22px; border-radius: 18px; }
  .lp-final-art { max-width: 200px; }
}

/* Body font tiny screens: prevent iOS zoom on form inputs */
@media (max-width: 720px) {
  input, select, textarea, button { font-size: 16px; }
  .quiz-short, .practical-notes { font-size: 16px; }
}

/* ============ Breakout room — games lounge layout ============ */
.br-wrap {
  display: grid; gap: 22px; margin-top: 24px;
  grid-template-columns: 1fr;
}
@media (min-width: 880px) {
  .br-wrap { grid-template-columns: 260px 1fr; align-items: start; }
}
@media (min-width: 1200px) {
  .br-wrap { grid-template-columns: 240px 1fr 280px; }
}
.br-picker {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 18px 18px 14px;
  box-shadow: var(--shadow-soft);
  position: sticky; top: 80px;
}
.br-list { list-style: none; padding: 0; margin: 8px 0 14px; display: grid; gap: 6px; }
.br-pick {
  width: 100%; display: grid; grid-template-columns: 28px 1fr auto 14px;
  align-items: center; gap: 8px;
  padding: 9px 11px; border: 1px solid var(--border-soft); border-radius: 10px;
  background: transparent; font: inherit; cursor: pointer;
  color: var(--ink); text-align: left;
  transition: all .15s;
}
.br-pick:hover { background: var(--bg-tint); border-color: var(--accent-light); }
.br-pick.active { background: var(--ink-deep); color: white; border-color: var(--ink-deep); }
.br-pick.active .br-num { color: var(--hl-warm); }
.br-pick.is-loading { opacity: .6; }
.br-num { font-family: var(--mono); font-size: 0.74rem; color: var(--accent); letter-spacing: 0.06em; }
.br-name { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.br-arrow { color: var(--accent); opacity: 0; transform: translateX(-4px); transition: all .15s; }
.br-pick:hover .br-arrow, .br-pick.active .br-arrow { opacity: 1; transform: translateX(0); }
.br-pick.active .br-arrow { color: var(--hl-warm); }
/* Per-game rank pill — current learner's standing on each game. */
.br-rank {
  font-family: var(--mono);
  font-size: 0.66rem; font-weight: 800; letter-spacing: 0.04em;
  padding: 2px 6px; border-radius: 999px;
  background: var(--bg-tint); color: var(--ink-soft);
  border: 1px solid var(--border-soft);
  white-space: nowrap;
}
.br-rank.is-gold   { background: linear-gradient(135deg, #fde68a, #f5b945); color: #5a3b00; border-color: #f5b945; box-shadow: 0 0 6px rgba(245,185,69,.45); }
.br-rank.is-silver { background: linear-gradient(135deg, #f2f4f7, #c0c4cc); color: #2a2f36; border-color: #c0c4cc; }
.br-rank.is-bronze { background: linear-gradient(135deg, #f0c79b, #cd7f32); color: #4a2300; border-color: #cd7f32; }
.br-pick.active .br-rank { background: rgba(255,255,255,.18); color: white; border-color: rgba(255,255,255,.25); }
.br-pick.active .br-rank.is-gold,
.br-pick.active .br-rank.is-silver,
.br-pick.active .br-rank.is-bronze { color: #0e0c2a; }
.br-tip { margin: 0; padding-top: 8px; border-top: 1px solid var(--border-soft); }

.br-stage .lg-wrap {
  max-width: none; margin: 0;
  background: var(--panel); padding: 18px;
}
.br-stage .lg-canvas { max-width: 100%; }

/* Games panel — shared bar layout */
.lg-bar { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-bottom: 10px; }
.lg-actions { display: flex; gap: 8px; }
.lg-actions .lg-restart, .lg-actions .lg-cycle {
  border: 1px solid var(--border-soft); background: transparent;
  border-radius: 8px; padding: 6px 10px; cursor: pointer;
  font: inherit; font-size: 0.78rem; color: var(--ink);
  transition: all .15s; white-space: nowrap;
}
.lg-actions .lg-restart:hover { background: var(--bg-tint); color: var(--accent-dark); border-color: var(--accent); }
.lg-actions .lg-cycle:hover   { background: var(--bg-tint); color: var(--accent-dark); border-color: var(--accent-light); }

@media (max-width: 720px) {
  .lg-bar { grid-template-columns: 1fr; }
  .lg-actions { justify-content: flex-end; }
  .br-picker { position: static; }
}

/* ============================================================
   Pace-aware lesson rendering: short = notepad, deep = full
   ============================================================ */

.lesson-pace-short .lesson-header { margin-bottom: 18px; }
.pace-pill {
  display: inline-block; margin-left: 10px;
  padding: 2px 8px; border-radius: 999px;
  background: var(--bg-tint); color: var(--accent-dark);
  font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase;
}

/* Notepad cards used in short-pace layout */
.notepad-card {
  position: relative;
  background: #fffdf6;
  border: 1px solid #ecead2;
  border-radius: 14px;
  padding: 22px 26px 18px;
  margin: 14px 0;
  box-shadow: 0 6px 20px rgba(30, 27, 75, 0.06);
}
.notepad-card::before {
  content: ""; position: absolute; top: 0; left: 28px; right: 28px; height: 3px;
  background: var(--gradient); border-radius: 0 0 6px 6px;
}
.notepad-card .np-tag {
  display: inline-block; margin: 0 0 8px;
  font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); font-family: var(--mono); font-weight: 700;
}
.notepad-card p { margin: 0 0 6px; line-height: 1.55; color: var(--ink); }
.notepad-objective { background: linear-gradient(180deg, #fffdf6 0%, #f4f1ea 100%); }

.notepad-grid {
  display: grid; gap: 12px; margin: 18px 0;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .notepad-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .notepad-grid { grid-template-columns: repeat(3, 1fr); } }
.notepad-tile {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 18px 18px 16px;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .25s;
  animation: tileIn .55s cubic-bezier(.2,.8,.2,1) backwards;
  animation-delay: calc(var(--i, 0) * 80ms);
}
@keyframes tileIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.notepad-tile:hover { transform: translateY(-3px) rotate(-0.4deg); box-shadow: 0 16px 36px rgba(30, 27, 75, 0.10); }
.notepad-tile .np-num {
  position: absolute; top: -10px; right: 14px;
  background: var(--ink-deep); color: var(--cream);
  font-size: 0.7rem; padding: 2px 8px; border-radius: 999px;
}
.notepad-tile h3 { margin: 0 0 6px; font-size: 1rem; color: var(--ink); }
.notepad-tile p { margin: 0; color: var(--ink-soft); font-size: 0.92rem; line-height: 1.5; }

/* Animation strip (deep pace) */
.anim-section .anim-strip {
  display: flex; gap: 12px; align-items: stretch;
  overflow-x: auto; padding: 10px 4px 14px;
  scroll-snap-type: x mandatory;
  border-radius: 14px;
}
.anim-section .anim-strip:hover .anim-frame { animation-play-state: paused; }
.anim-frame {
  flex: 0 0 240px; scroll-snap-align: start;
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 12px; padding: 16px 16px 14px;
  position: relative;
  animation: framePulse 6s ease-in-out infinite;
  transform-origin: center;
}
.anim-frame .anim-num {
  display: inline-block; padding: 2px 8px; border-radius: 999px;
  background: var(--accent); color: white;
  font-size: 0.66rem; letter-spacing: 0.1em;
}
.anim-frame h3 { margin: 8px 0 4px; font-size: 0.98rem; color: var(--ink); }
.anim-frame p { margin: 0; color: var(--ink-soft); font-size: 0.88rem; line-height: 1.5; }
@keyframes framePulse {
  0%, 100% { transform: scale(1);   box-shadow: 0 6px 18px rgba(30,27,75,.05); }
  50%      { transform: scale(1.02); box-shadow: 0 14px 32px rgba(124,58,237,.18); }
}
.anim-arrow {
  align-self: center; font-size: 1.4rem; color: var(--accent);
  flex-shrink: 0;
  animation: arrowFlow 1.8s ease-in-out infinite;
}
@keyframes arrowFlow { 0%, 100% { transform: translateX(0); opacity: .7; } 50% { transform: translateX(4px); opacity: 1; } }

/* Video grid */
.video-grid {
  display: grid; gap: 14px;
  grid-template-columns: 1fr;
}
@media (min-width: 800px) { .video-grid { grid-template-columns: repeat(2, 1fr); } }
.video-card { background: var(--panel); border: 1px solid var(--border-soft); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-soft); }
.video-frame { position: relative; aspect-ratio: 16 / 9; background: var(--ink-deep); }
.video-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.video-fallback {
  display: flex; align-items: center; justify-content: center;
  height: 100%; color: white; text-decoration: none; font-weight: 700;
  background: var(--gradient);
}
.video-meta { padding: 14px 16px; }
.video-meta h3 { margin: 0 0 4px; font-size: 1rem; color: var(--ink); }
.video-meta p { margin: 6px 0 0; color: var(--ink-soft); font-size: 0.92rem; line-height: 1.5; }

/* Practical workspace — code/writing editor */
.practical-workspace {
  margin-top: 12px;
  background: var(--ink-deep); border-radius: 12px; overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
}
.practical-workspace .workspace-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 12px; background: rgba(255,255,255,.04);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.practical-workspace .ws-tag {
  font-size: 0.72rem; color: var(--hl-warm, #f5b945); letter-spacing: 0.1em;
}
.practical-workspace .ws-actions { display: flex; gap: 6px; }
.practical-workspace .ws-actions .btn-secondary {
  background: rgba(255,255,255,.06); color: white; border: 0;
  padding: 4px 10px; font-size: 0.78rem;
}
.practical-workspace .ws-actions .btn-secondary:hover { background: rgba(255,255,255,.14); }
.ws-editor {
  width: 100%; min-height: 280px; padding: 16px 18px;
  background: transparent; border: 0; outline: none;
  color: #ede9fe; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 14px; line-height: 1.55; resize: vertical;
  tab-size: 2;
}
.ws-editor.ws-writing { font-family: Inter, system-ui, sans-serif; line-height: 1.7; color: #f5f3ff; font-size: 15px; }
.ws-editor.ws-analysis { font-family: Inter, system-ui, sans-serif; line-height: 1.65; color: #f5f3ff; font-size: 15px; }
.ws-editor:focus { box-shadow: inset 0 0 0 2px rgba(124,58,237,.45); }

.practical-expect {
  margin-top: 12px; padding: 14px 16px;
  background: var(--bg-tint); border-radius: 10px;
  border-left: 3px solid var(--accent);
}
.practical-expect p { margin: 0; color: var(--ink); }
.practical-expect details { margin-top: 8px; }
.practical-expect .ws-sample {
  margin: 8px 0 0; padding: 12px 14px;
  background: var(--ink-deep); color: #ede9fe;
  border-radius: 8px; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.82rem; line-height: 1.5; overflow-x: auto;
  white-space: pre-wrap;
}
.practical-steps-wrap { margin: 14px 0 6px; }
.practical-steps-wrap summary { cursor: pointer; color: var(--accent-dark); }

/* Practical sessions list — show artefact outputs */
.practical-list { list-style: none; padding: 0; display: grid; gap: 14px; }
.practical-item {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 18px 20px;
  box-shadow: var(--shadow-soft);
}
.practical-item-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 14px; flex-wrap: wrap; margin-bottom: 12px;
}
.practical-item-head h3 { margin: 4px 0 4px; font-size: 1.1rem; color: var(--ink); }
.practical-status-wrap { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.practical-output { margin-top: 8px; }
.po-bar {
  display: flex; justify-content: space-between; align-items: center;
  padding: 6px 12px; background: rgba(124,58,237,.08);
  border-radius: 8px 8px 0 0; gap: 8px;
}
.po-tag { color: var(--accent); font-size: 0.7rem; letter-spacing: 0.1em; }
.po-actions { display: flex; gap: 6px; }
.po-actions .btn-small { background: transparent; border: 1px solid var(--border-soft); color: var(--ink); cursor: pointer; padding: 4px 10px; font-size: 0.78rem; }
.po-actions .btn-small:hover { background: var(--bg-tint); border-color: var(--accent-light); color: var(--accent-dark); }
.po-pre {
  margin: 0; padding: 14px 16px;
  background: var(--ink-deep); color: #ede9fe;
  border-radius: 0 0 8px 8px;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.82rem; line-height: 1.55;
  white-space: pre-wrap; word-break: normal;
  overflow: auto;
  transition: max-height .35s ease;
}
.po-pre.po-collapsed { max-height: 200px; }

@media (prefers-reduced-motion: reduce) {
  .notepad-tile, .anim-frame, .anim-arrow { animation: none !important; }
}

/* Tighten on mobile */
@media (max-width: 720px) {
  .notepad-card { padding: 16px 18px; }
  .notepad-tile { padding: 14px 16px; }
  .anim-frame { flex-basis: 80%; }
  .ws-editor { min-height: 220px; font-size: 14px; }
  .practical-item-head { flex-direction: column; }
  .practical-status-wrap { width: 100%; justify-content: space-between; }
}

/* ============ Avatar + profile ============ */
.user-pill-link {
  display: inline-flex; align-items: center; gap: 8px;
  text-decoration: none; padding: 4px 10px 4px 4px;
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 999px; color: var(--ink); font-size: 0.82rem;
  transition: border-color .15s, background .15s;
}
.user-pill-link:hover { background: var(--bg-tint); border-color: var(--accent-light); }
.user-avatar {
  width: 28px; height: 28px; border-radius: 50%; object-fit: cover;
  background: var(--gradient); color: white;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 0.78rem;
}
.user-avatar-letter { font-family: var(--mono); }
.user-pill-email { color: var(--muted); }
.user-pill-badge {
  background: var(--accent); color: white;
  padding: 1px 6px; border-radius: 999px;
  font-size: 0.62rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase;
}

.profile-card {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 26px; margin-top: 24px;
  box-shadow: var(--shadow-soft); max-width: 640px;
}
.profile-row { display: flex; gap: 18px; align-items: center; margin-bottom: 20px; }
.profile-avatar {
  width: 88px; height: 88px; border-radius: 50%; object-fit: cover;
  background: var(--gradient);
}
.profile-avatar-placeholder {
  display: flex; align-items: center; justify-content: center;
  color: white; font-family: var(--serif); font-size: 2.4rem;
}
.profile-meta h2 { margin: 0 0 4px; color: var(--ink); }
.profile-form { display: grid; gap: 14px; }
.profile-file {
  display: block; padding: 18px; border-radius: 10px;
  border: 1.5px dashed var(--border-soft); background: var(--bg-tint);
  cursor: pointer; transition: border-color .15s, background .15s;
}
.profile-file:hover { border-color: var(--accent); background: var(--panel); }
.profile-file input[type=file] { display: block; margin-bottom: 8px; }
.profile-file span { color: var(--muted); font-size: 0.88rem; }
.profile-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ============ Multi-source resource grid ============ */
.resource-grid {
  list-style: none; padding: 0; display: grid; gap: 12px;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) { .resource-grid { grid-template-columns: repeat(2, 1fr); } }
.resource-card-multi {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: 12px; padding: 16px 18px;
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 14px; text-decoration: none; color: var(--ink);
  transition: transform .15s, border-color .15s, box-shadow .15s;
}
.resource-card-multi:hover { transform: translateY(-2px); border-color: var(--accent-light); box-shadow: 0 12px 28px rgba(30,27,75,.08); }
.resource-card-multi h3 { margin: 6px 0 6px; font-size: 1rem; color: var(--ink); }
.provider-tag {
  display: inline-block; padding: 2px 8px; border-radius: 999px;
  background: var(--ink-deep); color: white;
  font-size: 0.66rem; letter-spacing: 0.1em;
}
.provider-anthropic { background: #cc785c; }
.provider-openai    { background: #10a37f; }
.provider-google    { background: #4285f4; }
.provider-deeplearningai { background: #0080a9; }
.provider-stanford  { background: #8c1515; }
.provider-mit       { background: #750014; }
.provider-youtube   { background: #ff0000; }

/* ============ Downloadable files ============ */
.download-grid { list-style: none; padding: 0; display: grid; gap: 14px; }
.download-card {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 12px; overflow: hidden;
}
.dl-head {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; background: var(--bg-tint);
  border-bottom: 1px solid var(--border-soft);
}
.dl-lang {
  background: var(--accent); color: white;
  padding: 2px 8px; border-radius: 999px; font-size: 0.66rem;
}
.dl-name { color: var(--ink); font-family: var(--mono); font-size: 0.9rem; }
.download-card .muted { padding: 10px 16px 4px; margin: 0; }
.dl-pre {
  margin: 0; padding: 14px 16px;
  background: var(--ink-deep); color: #ede9fe;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.82rem; line-height: 1.5;
  max-height: 240px; overflow: auto;
  white-space: pre-wrap;
}
.dl-actions { display: flex; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--border-soft); }
.dl-actions .btn-small { padding: 6px 12px; font-size: 0.82rem; }

/* ============ Dashboard: "tailored away from you" panel ============ */
.tailor-panel {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 22px 24px;
  box-shadow: var(--shadow-soft); margin: 20px 0;
}
.tailor-panel h2 { margin: 0 0 6px; }
.tailor-list { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.tailor-list li {
  display: grid; grid-template-columns: auto 1fr auto;
  gap: 14px; align-items: center;
  padding: 12px 14px; background: var(--bg-tint); border-radius: 10px;
}
.tailor-skipped {
  background: var(--accent); color: white;
  padding: 4px 8px; border-radius: 999px; font-size: 0.66rem;
  font-weight: 800; letter-spacing: 0.1em;
}
.tailor-list li strong { display: block; color: var(--ink); margin-bottom: 2px; }
.tailor-list li p { margin: 0; }
@media (max-width: 720px) {
  .tailor-list li { grid-template-columns: 1fr; }
}

/* ============ Landing redo additions ============ */

/* Scroll progress bar pinned to top */
.lp-scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px;
  z-index: 1000; pointer-events: none;
  background: rgba(14,12,42,.05);
}
.lp-scroll-progress span {
  display: block; height: 100%;
  background: var(--gradient);
  width: 0; transition: width .12s linear;
  box-shadow: 0 0 8px rgba(124,58,237,.5);
}

/* Mesh node text labels — readable over the watermark logo + grain */
.lp-mesh .node text {
  font-family: var(--mono); font-size: 12px; fill: var(--ink-deep);
  letter-spacing: 0.06em; text-transform: uppercase; font-weight: 800;
  paint-order: stroke fill;
  stroke: var(--cream); stroke-width: 5px; stroke-linejoin: round;
}
.lp-mesh .centerlabel {
  font-family: var(--serif) !important; font-size: 13px !important;
  font-style: italic; font-weight: 600;
  fill: var(--accent) !important;
  text-transform: none !important; letter-spacing: 0;
  stroke: var(--cream) !important; stroke-width: 4px !important;
  paint-order: stroke fill;
}
.lp-mesh { transition: transform .25s cubic-bezier(.2,.8,.2,1); }
.lp-mesh .node { transform-origin: center; transform-box: fill-box; transition: transform .25s; }
.lp-mesh .node:hover circle { transform: scale(1.35); fill: var(--accent); }
.lp-mesh .node:hover text { fill: var(--accent-dark); }

/* Click ripple on hero CTAs */
.lp-btn { position: relative; overflow: hidden; }
.lp-ripple {
  position: absolute; width: 12px; height: 12px;
  border-radius: 50%; transform: translate(-50%, -50%) scale(0);
  background: rgba(255,255,255,.55);
  animation: ripple .65s cubic-bezier(.2,.8,.2,1) forwards;
  pointer-events: none;
}
@keyframes ripple { to { transform: translate(-50%, -50%) scale(28); opacity: 0; } }

/* Counters strip */
.lp-counters {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px;
  margin: 8px calc(-1 * (50vw - min(560px, 50%))) 8px;
  padding: 22px 28px;
  background: var(--ink-deep); color: var(--cream);
  border-radius: 14px;
}
@media (min-width: 700px) { .lp-counters { grid-template-columns: repeat(5, 1fr); } }
.lp-counter { text-align: center; padding: 6px 0; }
.lp-counter .num {
  display: block; font-family: var(--serif); font-weight: 500;
  font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1; color: white;
  font-variation-settings: "opsz" 144, "SOFT" 100;
}
.lp-counter .label {
  display: block; margin-top: 6px; color: var(--hl-warm);
  font-size: 0.7rem; letter-spacing: 0.1em;
}

/* Tilt-on-hover hooks for card grids */
.feat-flip, .lp-track-mosaic .track, .lp-capstone-grid article {
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s;
}

@media (prefers-reduced-motion: reduce) {
  .lp-counter .num { animation: none !important; }
  .lp-scroll-progress span { transition: none; }
  .lp-mesh { transform: none !important; }
  .lp-ripple { animation: none !important; opacity: 0; }
}

/* ============ Landing — prominent brand mark above the hero copy ============ */
.lp-brandmark {
  display: inline-flex; align-items: center; gap: 14px;
  margin: 0 0 22px;
  padding: 8px 16px 8px 8px;
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(30, 27, 75, 0.08);
  transition: transform .25s, box-shadow .25s;
}
.lp-brandmark:hover { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(124, 58, 237, 0.18); }
.lp-brandmark-logo {
  width: 72px; height: 72px; object-fit: contain;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(168,85,247,.12), rgba(30,27,75,.04));
  padding: 4px;
  /* Subtle breath only — no spin per user direction. */
  animation: logoBreath 5.5s ease-in-out infinite;
}
@keyframes logoBreath {
  0%, 100% { transform: scale(1);    filter: drop-shadow(0 4px 12px rgba(124,58,237,.18)); }
  50%      { transform: scale(1.03); filter: drop-shadow(0 8px 20px rgba(124,58,237,.32)); }
}
@media (prefers-reduced-motion: reduce) { .lp-brandmark-logo { animation: none; } }
.lp-brandmark-text { display: flex; flex-direction: column; line-height: 1.05; }
.lp-brandmark-name { font-family: var(--serif); font-weight: 500; font-size: 1.4rem; color: var(--ink-deep); letter-spacing: -0.01em; }
.lp-brandmark-name .x { color: var(--accent); font-style: italic; }
.lp-brandmark-tag { color: var(--accent); margin-top: 4px; }

@media (max-width: 720px) {
  .lp-brandmark { padding: 6px 14px 6px 6px; }
  .lp-brandmark-logo { width: 44px; height: 44px; }
  .lp-brandmark-name { font-size: 1.15rem; }
}

/* ============ Admin usage tiles ============ */
.usage-totals {
  display: grid; gap: 14px; margin: 16px 0 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) { .usage-totals { grid-template-columns: repeat(4, 1fr); } }
.ut-tile {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 18px 20px;
  box-shadow: var(--shadow-soft);
}
.ut-tile-strong {
  background: var(--ink-deep); color: var(--cream);
  border-color: var(--ink-deep);
}
.ut-tile .ut-label { display: block; color: var(--accent-dark); font-size: 0.74rem; letter-spacing: 0.1em; }
.ut-tile-strong .ut-label { color: var(--hl-warm); }
.ut-tile .ut-value {
  display: block; margin-top: 6px;
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.6rem, 3.6vw, 2.4rem); color: var(--ink-deep);
  line-height: 1;
}
.ut-tile-strong .ut-value { color: white; }
.ut-tile .ut-sub { display: block; margin-top: 8px; color: var(--muted); font-size: 0.85rem; }
.ut-tile-strong .ut-sub { color: rgba(255,255,255,.72); }

/* ============ Feedback block on lesson page ============ */
.feedback-block { background: var(--bg-tint); }
.feedback-block label { display: block; margin-top: 10px; }
.feedback-block textarea {
  width: 100%; min-height: 60px; margin-top: 4px;
  padding: 10px 12px; border-radius: 8px;
  border: 1px solid var(--border-soft);
  font: inherit; background: var(--panel);
}
.feedback-block textarea:focus { outline: 2px solid var(--accent-light); border-color: var(--accent); }
.fb-rating { display: flex; gap: 10px; flex-wrap: wrap; margin: 10px 0 4px; }
.fb-rate {
  background: var(--panel); border: 1.5px solid var(--border-soft);
  padding: 8px 14px; border-radius: 999px; cursor: pointer;
  font: inherit; font-weight: 600; color: var(--ink);
  transition: all .15s;
}
.fb-rate:hover { background: var(--bg); border-color: var(--accent-light); color: var(--accent-dark); }
.fb-rate.picked { background: var(--accent); color: white; border-color: var(--accent); }
.fb-actions { display: flex; gap: 12px; align-items: center; margin-top: 14px; flex-wrap: wrap; }
.fb-status.ok { color: var(--success); }
.fb-status.miss { color: var(--danger); }

/* ============ Curriculum — tile grid, title-first, hover reveals body ============ */
.lp-curr-grid {
  display: grid; gap: 14px;
  grid-template-columns: 1fr;
  margin-top: 18px;
}
@media (min-width: 640px) { .lp-curr-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .lp-curr-grid { grid-template-columns: repeat(3, 1fr); } }

.lp-curr-tile {
  position: relative;
  display: flex; flex-direction: column; gap: 8px;
  padding: 22px 22px 20px;
  background: var(--panel);
  border: 1px solid var(--border-soft);
  border-radius: 16px;
  color: var(--ink); text-decoration: none;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  opacity: 0; transform: translateY(12px);
  animation: tileRise .6s cubic-bezier(.2,.8,.2,1) forwards;
  animation-delay: calc(var(--i, 0) * 60ms);
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .25s, border-color .25s;
}
@keyframes tileRise { to { opacity: 1; transform: none; } }
.lp-curr-tile::before {
  content: ""; position: absolute; inset: -1px;
  border-radius: inherit; padding: 1.5px;
  background: linear-gradient(135deg, var(--accent), transparent 65%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .25s;
  pointer-events: none;
}
.lp-curr-tile:hover, .lp-curr-tile:focus-visible {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 18px 40px rgba(30, 27, 75, .14);
  border-color: var(--accent-light);
}
.lp-curr-tile:hover::before, .lp-curr-tile:focus-visible::before { opacity: 1; }
.lp-curr-tile:focus-visible { outline: none; }
.lp-curr-num {
  display: inline-block;
  background: var(--ink-deep); color: var(--cream);
  padding: 4px 10px; border-radius: 999px;
  font-size: 0.72rem; letter-spacing: 0.08em;
  align-self: flex-start;
}
.lp-curr-tile h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: 1.15rem; color: var(--ink-deep);
  margin: 4px 0 0; line-height: 1.2;
}
.lp-curr-body {
  max-height: 0; opacity: 0; overflow: hidden;
  transition: max-height .45s cubic-bezier(.2,.8,.2,1), opacity .25s ease, margin-top .25s ease;
}
.lp-curr-tile:hover .lp-curr-body,
.lp-curr-tile:focus-visible .lp-curr-body,
.lp-curr-tile:focus-within .lp-curr-body {
  max-height: 220px; opacity: 1; margin-top: 4px;
}
.lp-curr-body p { margin: 0 0 8px; color: var(--ink-soft); font-size: 0.92rem; line-height: 1.5; }
.lp-curr-go { color: var(--accent); font-weight: 700; font-size: 0.86rem; }

/* ============ Animate capstone + responsible AI tiles ============ */
.lp-capstone-grid article,
.lp-resp .feat {
  opacity: 0; transform: translateY(16px);
  animation: cardWake .65s cubic-bezier(.2,.8,.2,1) forwards;
}
.lp-capstone-grid article:nth-child(1) { animation-delay: .05s; }
.lp-capstone-grid article:nth-child(2) { animation-delay: .18s; }
.lp-capstone-grid article:nth-child(3) { animation-delay: .31s; }
.lp-resp .feat:nth-child(1) { animation-delay: .05s; }
.lp-resp .feat:nth-child(2) { animation-delay: .18s; }
.lp-resp .feat:nth-child(3) { animation-delay: .31s; }
.lp-resp .feat:nth-child(4) { animation-delay: .44s; }
@keyframes cardWake { to { opacity: 1; transform: none; } }

.lp-capstone-grid article {
  position: relative; overflow: hidden;
  transition: transform .35s, box-shadow .25s;
}
.lp-capstone-grid article::after {
  content: ""; position: absolute; inset: -40% -40% auto auto;
  width: 220px; height: 220px;
  background: radial-gradient(closest-side, rgba(168,85,247,.18), transparent 70%);
  transform: translate(40%, -40%) scale(0.4);
  transition: transform .55s cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
}
.lp-capstone-grid article:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 44px rgba(30, 27, 75, .14);
}
.lp-capstone-grid article:hover::after { transform: translate(20%, -20%) scale(1); }

.lp-resp .feat {
  position: relative;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}
.lp-resp .feat::before {
  content: ""; position: absolute; top: 14px; right: 14px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
  opacity: .55;
  box-shadow: 0 0 0 0 rgba(124,58,237,.5);
  animation: respPulse 2.6s ease-in-out infinite;
}
@keyframes respPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(124,58,237,.5); }
  50%      { box-shadow: 0 0 0 9px rgba(124,58,237,0); }
}
.lp-resp .feat:hover {
  transform: translateY(-4px);
  border-color: var(--accent-light);
}

@media (prefers-reduced-motion: reduce) {
  .lp-curr-tile, .lp-capstone-grid article, .lp-resp .feat { animation: none !important; opacity: 1; transform: none; }
  .lp-resp .feat::before { animation: none; }
}

/* ============ Pathway tiles — thematic on-hover animations ============ */

/* Each rail card now hosts a self-contained anim canvas */
.lp-rail .rail-card { position: relative; overflow: hidden; }
.lp-rail .rail-card .rail-anim {
  position: relative; height: 64px; margin: 12px 0 4px;
}

/* Hide the old static glyph (in case any leftovers ride on .lp-rail li) */
.lp-rail-glyph { display: none !important; }

/* --- 01 — Sign-up envelope flight ---------------------------------- */
.rail-signup .rail-anim {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px;
}
.rail-signup .ra-word {
  justify-self: end;
  font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.1em;
  color: var(--ink-deep); text-transform: uppercase;
  padding: 6px 10px; background: var(--bg-tint); border-radius: 999px;
  border: 1px dashed rgba(14,12,42,.18);
  transition: transform .35s ease, opacity .25s ease;
}
.rail-signup .ra-envelope {
  width: 60px; height: 40px; display: inline-block;
  transform: translateX(-32px) scale(0.6); opacity: 0;
  transition: transform .9s cubic-bezier(.2,.8,.2,1) .2s, opacity .35s ease .25s;
}
.rail-signup .ra-envelope svg { width: 100%; height: 100%; }
.rail-signup .ra-tray {
  justify-self: start; width: 100%; max-width: 130px;
  color: var(--accent);
  transition: transform .25s ease;
}
.rail-signup .ra-tray svg { width: 100%; height: auto; }
.rail-signup .ra-tray-label {
  font-family: var(--mono); font-size: 6px; fill: var(--accent-dark);
  letter-spacing: 0.16em; text-transform: uppercase; font-weight: 800;
}
.rail-signup:hover .ra-word { opacity: 0; transform: translateX(-12px) scale(.85); }
.rail-signup:hover .ra-envelope { transform: translateX(0) scale(1); opacity: 1; }
.rail-signup:hover .ra-tray     { transform: scale(1.04); }

/* --- 02 — Diagnostic form ticks + gauge ---------------------------- */
.rail-diag .ra-form { width: 100%; height: 100%; color: var(--ink-deep); }
.rail-diag .ra-tick path {
  stroke-dasharray: 28; stroke-dashoffset: 28;
  transition: stroke-dashoffset .45s ease;
}
.rail-diag:hover .ra-tick .t1 { transition-delay: .05s; stroke-dashoffset: 0; }
.rail-diag:hover .ra-tick .t2 { transition-delay: .2s;  stroke-dashoffset: 0; }
.rail-diag:hover .ra-tick .t3 { transition-delay: .35s; stroke-dashoffset: 0; }
.rail-diag:hover .ra-tick .t4 { transition-delay: .5s;  stroke-dashoffset: 0; }
.rail-diag .ra-gauge {
  transition: stroke-dashoffset .9s cubic-bezier(.2,.8,.2,1) .55s;
}
.rail-diag:hover .ra-gauge { stroke-dashoffset: 22; }   /* ~75% filled */
.rail-diag .ra-gauge-num {
  font-family: var(--mono); font-size: 8px; fill: var(--accent-dark);
  font-weight: 800; opacity: 0; transition: opacity .25s ease 1.1s;
}
.rail-diag:hover .ra-gauge-num { opacity: 1; }

/* --- 03 — Approval clock + APPROVED stamp -------------------------- */
.rail-approval .rail-anim {
  display: flex; align-items: center; gap: 12px; color: var(--ink-deep);
}
.rail-approval .ra-clock { width: 80px; height: 60px; flex-shrink: 0; }
.rail-approval .ra-min { transform-origin: 40px 30px; transition: transform .9s cubic-bezier(.5,0,.2,1); }
.rail-approval .ra-hr  { transform-origin: 40px 30px; transition: transform 1.2s cubic-bezier(.5,0,.2,1); }
.rail-approval:hover .ra-min { transform: rotate(720deg); }
.rail-approval:hover .ra-hr  { transform: rotate(60deg);  }
.rail-approval .ra-stamp {
  font-family: var(--mono); font-weight: 900; font-size: 0.85rem;
  letter-spacing: 0.12em; color: white; background: var(--success);
  padding: 8px 12px; border-radius: 6px;
  transform: translateY(-12px) rotate(-12deg) scale(0.4);
  opacity: 0; transition: transform .35s cubic-bezier(.2,.8,.2,1) .9s, opacity .25s ease .95s;
  box-shadow: 0 8px 20px rgba(21,128,61,.35);
}
.rail-approval:hover .ra-stamp { transform: translateY(0) rotate(-6deg) scale(1); opacity: 1; }

/* --- 04 — Unlock + M1 badge --------------------------------------- */
.rail-unlock .rail-anim {
  display: flex; align-items: center; gap: 14px; color: var(--ink-deep);
}
.rail-unlock .ra-lock { width: 90px; height: 60px; flex-shrink: 0; }
.rail-unlock .ra-lock-shackle {
  transform-origin: 60px 22px;
  transition: transform .45s cubic-bezier(.2,.8,.2,1);
}
.rail-unlock:hover .ra-lock-shackle { transform: rotate(-22deg) translate(-6px, -2px); }
.rail-unlock .ra-badge {
  background: var(--gradient); color: white;
  padding: 8px 14px; border-radius: 10px;
  font-family: var(--serif); font-weight: 600; font-size: 1.2rem; line-height: 1;
  display: inline-flex; flex-direction: column; align-items: center; gap: 2px;
  opacity: 0; transform: translateX(-10px) scale(0.7);
  transition: transform .4s cubic-bezier(.2,.8,.2,1) .35s, opacity .25s ease .35s;
}
.rail-unlock .ra-badge small {
  font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.18em;
  text-transform: uppercase; font-weight: 700; opacity: .9;
}
.rail-unlock:hover .ra-badge { opacity: 1; transform: translateX(0) scale(1); }

/* Mobile: skip the wider grid, stack vertically */
@media (max-width: 720px) {
  .rail-signup .rail-anim { grid-template-columns: 1fr; gap: 6px; }
  .rail-signup .ra-word, .rail-signup .ra-tray { justify-self: start; }
}

@media (prefers-reduced-motion: reduce) {
  .rail-card .rail-anim * { transition: none !important; animation: none !important; }
  .rail-signup .ra-envelope { opacity: 1; transform: none; }
  .rail-signup .ra-word { opacity: 1; transform: none; }
  .rail-diag .ra-tick path { stroke-dashoffset: 0; }
  .rail-diag .ra-gauge { stroke-dashoffset: 22; }
  .rail-diag .ra-gauge-num { opacity: 1; }
  .rail-approval .ra-stamp { opacity: 1; transform: none; }
  .rail-unlock .ra-badge { opacity: 1; transform: none; }
}

/* =================================================================
   Landing tweaks — brandmark text-only, counters & ticker sizing,
   pathway slower full-tile expansion, capstone + responsible AI
   hover-reveal, final CTA logo backdrop
   ================================================================= */

/* Brandmark — "AI Academy" leads, "InnovateXperts" follows */
.lp-brandmark {
  padding: 10px 22px;
  align-items: center;
}
.lp-brandmark-text {
  flex-direction: row; gap: 16px; align-items: baseline;
}
.lp-brandmark-tag {
  font-family: var(--mono); font-weight: 800;
  font-size: 0.95rem; letter-spacing: 0.18em;
  color: var(--accent);
  text-transform: uppercase;
  border-left: 1px solid rgba(14,12,42,.2);
  border-right: 0;
  padding-left: 16px; padding-right: 0;
  align-self: stretch; display: flex; align-items: center;
}
.lp-brandmark-name {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.6rem, 3.4vw, 2.2rem);
  font-variation-settings: "opsz" 144, "SOFT" 60;
  letter-spacing: -0.012em;
  color: var(--ink-deep);
}
.lp-brandmark-name .x { color: var(--accent); font-style: italic; }

@media (max-width: 720px) {
  .lp-brandmark { padding: 8px 16px; }
  .lp-brandmark-text { gap: 10px; }
  .lp-brandmark-name { font-size: 1.4rem; }
  .lp-brandmark-tag  { font-size: 0.78rem; padding-right: 10px; }
}

/* Ticker — span the same width as the counters strip + larger text.
   Both bleed out of .site-main via negative margin. */
.lp-counters,
.lp-ticker {
  margin-left:  calc(-1 * (50vw - min(560px, 50%)));
  margin-right: calc(-1 * (50vw - min(560px, 50%)));
}
.lp-ticker { border-radius: 14px; }
.lp-ticker-track {
  font-size: 0.95rem; letter-spacing: 0.04em;
  padding: 18px 0; gap: 36px;
  text-transform: none;
}
.lp-ticker-track span:nth-child(even) { color: var(--accent); font-weight: 800; }

/* Counters: numbers are already big — make them count from 0 */
.lp-counter .num { display: block; }

/* ============ Pathway tile animations: slower + full-tile cover ============ */
.lp-rail .rail-card { position: relative; overflow: hidden; min-height: 260px; }
.lp-rail .rail-card .rail-anim {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,.0) 0%, rgba(244,241,234,.92) 30%, rgba(244,241,234,.98) 100%);
  opacity: 0; pointer-events: none;
  padding: 24px;
  transition: opacity .55s ease;
  height: auto; margin: 0;
}
.lp-rail .rail-card:hover .rail-anim,
.lp-rail .rail-card:focus-within .rail-anim {
  opacity: 1;
}

/* Sign-up tile — fill the tile on hover */
.rail-signup .rail-anim {
  display: grid; align-items: center;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1.6fr);
  gap: 24px;
  padding: 18px 22px !important;
}
.rail-signup .ra-envelope {
  transition: transform 1.6s cubic-bezier(.2,.8,.2,1) .3s, opacity .5s ease .35s;
  width: 180px; height: auto;
  display: inline-flex; align-items: center; justify-content: center;
}
.rail-signup .ra-envelope svg {
  width: 100%; height: auto;
  filter: drop-shadow(0 8px 18px rgba(124, 58, 237, 0.35));
}
.rail-signup .ra-envelope svg rect { fill: var(--cream); stroke: var(--accent-dark); }
.rail-signup .ra-envelope svg path { stroke: var(--accent); }
.rail-signup .ra-tray { width: 90%; max-width: none; color: var(--accent-dark); }
.rail-signup .ra-tray svg { width: 100%; height: auto; }
.rail-signup .ra-tray svg rect { fill: rgba(124,58,237,.08); stroke: var(--accent); stroke-width: 2; }
.rail-signup .ra-tray svg path { stroke: var(--accent); stroke-width: 2; }
.rail-signup .ra-tray-label {
  font-size: 9.5px; fill: var(--accent-dark); font-weight: 800;
}
.rail-signup .ra-word {
  font-size: 1.7rem; padding: 16px 26px;
  background: var(--cream); color: var(--accent-dark);
  border: 1.5px dashed var(--accent);
  border-radius: 999px;
  transition: transform .6s ease, opacity .4s ease;
  justify-self: end;
}

.rail-diag .ra-form { width: 80%; height: auto; max-height: 70%; }
.rail-diag .ra-tick path { transition: stroke-dashoffset .9s ease; }
.rail-diag:hover .ra-tick .t1 { transition-delay: .25s; }
.rail-diag:hover .ra-tick .t2 { transition-delay: .55s; }
.rail-diag:hover .ra-tick .t3 { transition-delay: .85s; }
.rail-diag:hover .ra-tick .t4 { transition-delay: 1.15s; }
.rail-diag .ra-gauge { transition: stroke-dashoffset 1.8s cubic-bezier(.2,.8,.2,1) 1.4s; }
.rail-diag .ra-gauge-num { transition: opacity .35s ease 2.4s; }

.rail-approval .ra-clock { width: 40%; height: auto; }
.rail-approval .ra-min { transition: transform 1.8s cubic-bezier(.5,0,.2,1); }
.rail-approval .ra-hr  { transition: transform 2.4s cubic-bezier(.5,0,.2,1); }
.rail-approval .ra-stamp {
  font-size: 1.2rem; padding: 12px 18px;
  transition: transform .55s cubic-bezier(.2,.8,.2,1) 1.8s, opacity .35s ease 1.85s;
}

.rail-unlock .ra-lock { width: 35%; height: auto; }
.rail-unlock .ra-lock-shackle { transition: transform .9s cubic-bezier(.2,.8,.2,1) .25s; }
.rail-unlock .ra-badge {
  font-size: 1.8rem; padding: 14px 22px;
  transition: transform .7s cubic-bezier(.2,.8,.2,1) 1.0s, opacity .35s ease 1.05s;
}

/* The card title/body shouldn't disappear behind the anim — keep them visible
   while the anim animates as a foreground layer instead of background fill. */
.lp-rail .rail-card .rail-anim {
  /* allow the underlying text to peek through softly */
  background: linear-gradient(180deg, rgba(255,255,255,.0) 0%, rgba(244,241,234,.85) 22%, rgba(244,241,234,.97) 100%);
}

@media (prefers-reduced-motion: reduce) {
  .lp-rail .rail-card .rail-anim { transition: none; }
}

/* ============ Capstone — vertical note-flip on hover ============ */
.lp-capstone-grid { gap: 18px; perspective: 1400px; }
.lp-capstone-grid article {
  position: relative; min-height: 260px;
  padding: 0; background: transparent !important;
  border: 0 !important; box-shadow: none !important;
  transform-style: preserve-3d;
  cursor: default;
}
.lp-capstone-grid article .cap-face,
.lp-capstone-grid article .cap-back {
  position: absolute; inset: 0;
  background: var(--paper);
  border: 1px solid rgba(14,12,42,.08); border-radius: 18px;
  padding: 28px 28px 24px;
  display: flex; flex-direction: column; justify-content: center;
  backface-visibility: hidden;
  transition: transform .65s cubic-bezier(.2,.8,.2,1), box-shadow .25s;
  transform-origin: 50% 50%;
}
.lp-capstone-grid article .cap-back {
  background: var(--ink-deep); color: var(--cream);
  transform: rotateX(180deg);
}
.lp-capstone-grid article:hover .cap-face,
.lp-capstone-grid article:focus-within .cap-face { transform: rotateX(-180deg); }
.lp-capstone-grid article:hover .cap-back,
.lp-capstone-grid article:focus-within .cap-back { transform: rotateX(0); }
.lp-capstone-grid article:hover { z-index: 2; }
.lp-capstone-grid article .cap-face h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.2rem, 2.2vw, 1.6rem); color: var(--ink-deep); margin: 0;
}
.lp-capstone-grid article .cap-back h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: 1.1rem; color: var(--hl-warm); margin: 0 0 12px;
}
.lp-capstone-grid article .cap-back p {
  font-size: 1.05rem; line-height: 1.55; margin: 0; color: rgba(255,255,255,.95);
}
@media (prefers-reduced-motion: reduce) {
  .lp-capstone-grid article .cap-face, .lp-capstone-grid article .cap-back { transition: none; }
  .lp-capstone-grid article .cap-back { transform: rotateX(0); }
  .lp-capstone-grid article .cap-face { display: none; }
}

/* ============ Responsible AI — flip cards (front title, back body) ============ */
.lp-resp .feat {
  position: relative; perspective: 1200px;
  min-height: 220px; padding: 0;
  background: transparent !important;
  border: 0 !important; box-shadow: none !important;
  cursor: default;
}
.lp-resp .feat::before { display: none; }   /* kill old pulse dot */
.lp-resp .feat .resp-face,
.lp-resp .feat .resp-back {
  position: absolute; inset: 0;
  padding: 26px 26px 22px;
  background: var(--panel); border: 1px solid rgba(14,12,42,.08);
  border-radius: 14px;
  backface-visibility: hidden;
  transition: transform .55s cubic-bezier(.2,.8,.2,1), box-shadow .25s;
}
.lp-resp .feat .resp-back {
  background: var(--ink-deep); color: var(--cream);
  transform: rotateY(180deg);
  display: flex; flex-direction: column; gap: 8px;
}
.lp-resp .feat:hover .resp-face,
.lp-resp .feat:focus-within .resp-face { transform: rotateY(-180deg); }
.lp-resp .feat:hover .resp-back,
.lp-resp .feat:focus-within .resp-back { transform: rotateY(0); }
.lp-resp .feat .resp-face .feat-num { color: var(--accent); }
.lp-resp .feat .resp-back .feat-num { color: var(--hl-warm); }
.lp-resp .feat .resp-face h3,
.lp-resp .feat .resp-back h3 {
  font-family: var(--serif); font-weight: 500; font-size: 1.1rem; margin: 8px 0 0;
}
.lp-resp .feat .resp-back h3 { color: var(--hl-warm); }
.lp-resp .feat .resp-back p {
  margin: 6px 0 0; font-size: 0.98rem; line-height: 1.55; color: rgba(255,255,255,.95);
}
.lp-resp .feat:hover { z-index: 2; }
@media (prefers-reduced-motion: reduce) {
  .lp-resp .feat .resp-face, .lp-resp .feat .resp-back { transition: none; }
  .lp-resp .feat .resp-back { display: none; }
}

/* ============ FAQ — sticker peel on open ============ */
.lp-faq-list details {
  position: relative; transform-origin: top right;
  transition: transform .45s cubic-bezier(.2,.8,.2,1), box-shadow .35s, border-color .35s;
}
.lp-faq-list details[open] {
  transform: rotate(-2.2deg) translateY(-3px);
  box-shadow: 12px 16px 30px rgba(30, 27, 75, .14);
  border-color: var(--accent);
}
.lp-faq-list details::before {
  content: ""; position: absolute; top: 0; right: 0;
  width: 0; height: 0;
  border-style: solid; border-width: 0 22px 22px 0;
  border-color: transparent var(--accent) transparent transparent;
  opacity: 0; transform: scale(.4); transform-origin: top right;
  transition: opacity .35s ease, transform .45s cubic-bezier(.2,.8,.2,1);
  border-top-right-radius: 12px;
}
.lp-faq-list details[open]::before { opacity: 1; transform: scale(1); }
.lp-faq-list details::after {
  content: ""; position: absolute; top: 0; right: 0;
  width: 28px; height: 28px;
  border-bottom-left-radius: 14px;
  background: linear-gradient(225deg, rgba(0,0,0,.18), transparent 60%);
  opacity: 0; pointer-events: none;
  transition: opacity .4s ease;
}
.lp-faq-list details[open]::after { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .lp-faq-list details { transition: none; }
  .lp-faq-list details[open] { transform: none; }
}

/* ============ Curriculum tiles — notepad flip on hover (hinged at top) ============ */
.lp-curr-grid { perspective: 1400px; }
.lp-curr-tile {
  position: relative; transform-style: preserve-3d;
  background: transparent !important;
  border: 0 !important; box-shadow: none !important;
  overflow: visible; min-height: 200px;
  text-decoration: none;
}
.lp-curr-tile .ct-face,
.lp-curr-tile .ct-back {
  position: absolute; inset: 0;
  background: var(--panel);
  border: 1px solid var(--border-soft); border-radius: 16px;
  padding: 22px 22px 20px;
  display: flex; flex-direction: column; gap: 8px;
  backface-visibility: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform .65s cubic-bezier(.2,.8,.2,1), box-shadow .35s;
  transform-origin: 50% 0%;
}
.lp-curr-tile .ct-back {
  background: var(--ink-deep); color: var(--cream);
  transform: rotateX(-180deg);
}
.lp-curr-tile:hover { z-index: 5; }
.lp-curr-tile:hover .ct-face,
.lp-curr-tile:focus-within .ct-face,
.lp-curr-tile:focus-visible .ct-face { transform: rotateX(180deg); }
.lp-curr-tile:hover .ct-back,
.lp-curr-tile:focus-within .ct-back,
.lp-curr-tile:focus-visible .ct-back { transform: rotateX(0); box-shadow: 0 22px 50px rgba(30,27,75,.18); }
.lp-curr-tile .ct-back .lp-curr-num { background: var(--hl-warm); color: var(--ink-deep); }
.lp-curr-tile .ct-back h3 { color: var(--hl-warm); font-family: var(--serif); font-weight: 500; }
.lp-curr-tile .ct-back p  { color: rgba(255,255,255,.92); font-size: 0.95rem; line-height: 1.5; margin: 0; }
.lp-curr-tile .ct-back .lp-curr-go { color: var(--hl-warm); margin-top: auto; }
/* Existing body-on-hover rule was for the old single-face design — disable */
.lp-curr-tile:hover .lp-curr-body,
.lp-curr-tile:focus-visible .lp-curr-body,
.lp-curr-tile:focus-within .lp-curr-body { max-height: 0; opacity: 0; margin-top: 0; }
@media (prefers-reduced-motion: reduce) {
  .lp-curr-tile .ct-face, .lp-curr-tile .ct-back { transition: none; }
  .lp-curr-tile .ct-back { display: none; }
}

/* ============ Final CTA — logo backdrop CENTRED, orbit SVG 25% smaller ============ */
.lp-final-art-wrap {
  position: relative;
  /* Roomier wrap + the logo at 88% gives breathing room around the
     "InnovateXperts AI Academy" wordmark so it does not feel clipped. */
  width:  min(440px, 100%);
  height: min(440px, 92vw);
  justify-self: center;
  padding: 28px;
  box-sizing: border-box;
  display: flex; align-items: center; justify-content: center;
}
.lp-final-backdrop {
  position: absolute; top: 50%; left: 50%;
  /* Logo is square (1254x1254) and rectangular by shape — wordmark sits
     below the brain head. A circular clip would chop "InnovateXperts AI
     Academy". Use the full wrap area and let object-fit keep aspect. */
  width: 100%; height: 100%;
  transform: translate(-50%, -50%);
  object-fit: contain;
  filter: drop-shadow(0 0 32px rgba(255, 255, 255, 0.5))
          drop-shadow(0 10px 28px rgba(168, 85, 247, 0.6));
  z-index: 0;
  pointer-events: none;
  animation: finalBackdropBreath 7s ease-in-out infinite;
}
/* Soft radial halo lives on the wrap, not the image, so the image can
   render edge-to-edge without being clipped by border-radius. */
.lp-final-art-wrap::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(closest-side, rgba(255,255,255,.10), transparent 70%);
  border-radius: 50%;
  pointer-events: none; z-index: 0;
}
@keyframes finalBackdropBreath {
  0%, 100% { opacity: 0.85; transform: translate(-50%, -50%) scale(1); }
  50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.025); }
}
@media (prefers-reduced-motion: reduce) {
  .lp-final-backdrop { animation: none; opacity: 0.9; }
}
.lp-final-art {
  position: absolute; inset: 28px; z-index: 2;
  /* Match the logo's drawable area so SVG coords align with image coords:
     image is 1:1 inside (wrap - padding), so is this SVG. The "ship" word
     can then be positioned over the chip in the middle of the brain. */
  width: calc(100% - 56px); height: calc(100% - 56px);
  display: block; pointer-events: none;
}
.lp-final-art .lf-orbit   { animation: orbitSpin 22s linear infinite; transform-origin: 120px 120px; }
.lp-final-art .lf-word {
  font-family: var(--serif); font-style: italic;
  font-size: 24px; font-weight: 700; fill: var(--hl-warm);
  paint-order: stroke fill;
  stroke: rgba(14,12,42,.65); stroke-width: 1.4px;
  letter-spacing: 0.5px;
}
@keyframes orbitSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .lp-final-art .lf-orbit, .lp-final-art .lf-orbit-2, .lp-final-backdrop { animation: none; }
}

/* ============ Cohesive typography across landing + platform + admin ============ */
.lp-brandmark-name,
.brand-name { font-family: var(--serif); }
.lp-brandmark-tag,
.brand-tagline { font-family: var(--mono); }

/* Platform pages share the same display serif on h1/h2 to match the landing */
.hero h1, .lesson-header h1,
.dashboard h1, .module h1, .admin-grid h2,
.cheatsheet h1 {
  font-family: var(--serif);
  font-weight: 500; letter-spacing: -0.012em;
}
/* Eyebrow chrome (small mono labels) uses JetBrains Mono across the platform */
.eyebrow, .mono, .badge.muted, .ut-label, .feat-num,
.lesson-num, .module-number, .module-time {
  font-family: var(--mono);
}

/* ============ Pulse-on-scroll dot ============ */
.lp-kicker .dot { animation: none; }   /* default: idle */
.lp-kicker .dot.is-pulsing {
  animation: ringPulse 1.2s ease-in-out 2;   /* two beats per scroll burst */
}

/* ============ Diagnostic footer marquee ============ */
.lp-diag-footer {
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  margin: 14px 0 0;
  padding: 8px 0;
  border-top: 1px solid rgba(14,12,42,.08);
  border-bottom: 1px solid rgba(14,12,42,.08);
  color: var(--muted);
  font-size: 0.8rem; letter-spacing: 0.04em;
}
.lp-diag-footer > span.df-track {
  display: inline-block;
  padding-left: 100%;
  animation: dfMarquee 24s linear infinite;
}
.lp-diag-footer:hover > span.df-track { animation-play-state: paused; }
@keyframes dfMarquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}
@media (prefers-reduced-motion: reduce) {
  .lp-diag-footer > span.df-track { animation: none; padding-left: 0; }
}

/* AEO summary — visually subtle but extractable for answer engines */
.lp-aeo-summary {
  margin: 0 0 14px;
  font-size: 1.02rem; line-height: 1.55;
  color: var(--ink-soft);
  border-left: 3px solid var(--accent);
  padding: 8px 14px;
  background: linear-gradient(90deg, rgba(124,58,237,.06), transparent 70%);
  border-radius: 0 8px 8px 0;
}
.lp-aeo-summary strong { color: var(--ink-deep); font-weight: 700; }

/* Freshness stamp — small, top-right, signals recency */
.lp-freshness {
  position: fixed; top: 70px; right: 16px;
  font-size: 0.66rem; letter-spacing: 0.1em;
  color: var(--accent); opacity: 0.55;
  background: var(--panel); padding: 4px 10px; border-radius: 999px;
  border: 1px solid var(--border-soft);
  z-index: 5; pointer-events: none;
}
@media (max-width: 720px) { .lp-freshness { display: none; } }

/* =================================================================
   Rebuild — sign-up animation v2 (single SVG, fits the tile)
   ================================================================= */

/* Reset old rules that fight the new markup */
.rail-signup .ra-word,
.rail-signup .ra-envelope,
.rail-signup .ra-tray { all: unset; }
.rail-signup .rail-anim { display: block !important; padding: 0 !important; }

.rail-signup .ra-svg {
  display: block;
  width: 100%; max-width: 360px; height: auto;
  margin: 0 auto;
}

/* "sign up" pill — fades + collapses on hover */
.rail-signup .ra-word-g {
  transform-origin: 53px 60px;
  transition: transform .55s cubic-bezier(.2,.8,.2,1) .1s,
              opacity   .35s ease .15s;
}
.rail-signup:hover .ra-word-g,
.rail-signup:focus-within .ra-word-g {
  transform: translate(-26px, 0) scale(.6);
  opacity: 0;
}

/* envelope — starts at the word's spot, flies to the tray */
.rail-signup .ra-env-g {
  transform: translate(28px, 60px) scale(.92);
  opacity: 0;
  transition: transform 1.3s cubic-bezier(.2,.8,.2,1) .25s,
              opacity   .35s ease .25s;
}
.rail-signup:hover .ra-env-g,
.rail-signup:focus-within .ra-env-g {
  transform: translate(128px, 60px) scale(1);
  opacity: 1;
}

/* tray + label settle in */
.rail-signup .ra-tray-g {
  transform: translateY(8px);
  opacity: .55;
  transition: transform .5s ease .3s, opacity .35s ease .3s;
}
.rail-signup:hover .ra-tray-g,
.rail-signup:focus-within .ra-tray-g {
  transform: translateY(0);
  opacity: 1;
}

/* tick stamp pops once the envelope lands */
.rail-signup .ra-tick-g {
  transform-origin: 150px 61px;
  transform: scale(0);
  opacity: 0;
  transition: transform .45s cubic-bezier(.2,1.8,.4,1) 1.5s,
              opacity   .25s ease 1.55s;
}
.rail-signup:hover .ra-tick-g,
.rail-signup:focus-within .ra-tick-g {
  transform: scale(1);
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  .rail-signup .ra-word-g  { opacity: 0; }
  .rail-signup .ra-env-g   { transform: translate(128px, 60px); opacity: 1; }
  .rail-signup .ra-tray-g  { transform: none; opacity: 1; }
  .rail-signup .ra-tick-g  { transform: scale(1); opacity: 1; }
}

/* =================================================================
   Curriculum back face — fit content for long bodies (M5/M8)
   ================================================================= */
.lp-curr-tile { min-height: 220px; }
.lp-curr-tile .ct-back {
  padding: 16px 18px;
  gap: 6px;
  justify-content: flex-start;
  overflow: hidden;
}
.lp-curr-tile .ct-back h3 {
  font-size: 1rem; margin: 4px 0 2px; line-height: 1.2;
}
.lp-curr-tile .ct-back p {
  font-size: 0.86rem; line-height: 1.45;
  margin: 0; flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.lp-curr-tile .ct-back .lp-curr-go {
  font-size: 0.78rem; margin-top: 4px;
  align-self: flex-start;
}
@media (min-width: 980px) {
  .lp-curr-tile { min-height: 240px; }
}

/* =================================================================
   Responsible AI back face — clamp body so it fits the tile
   ================================================================= */
.lp-resp .feat .resp-back {
  padding: 16px 18px;
  gap: 4px;
}
.lp-resp .feat .resp-back .feat-num { margin: 0; font-size: 0.72rem; }
.lp-resp .feat .resp-back h3 { font-size: 1rem; margin: 4px 0 0; line-height: 1.2; }
.lp-resp .feat .resp-back p {
  font-size: 0.88rem; line-height: 1.45; margin: 4px 0 0;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* =================================================================
   FAQ — peel like a label corner BUT stay straight on open
   ================================================================= */
.lp-faq-list details {
  transform: none !important;
  transition: box-shadow .35s, border-color .35s;
}
.lp-faq-list details[open] {
  transform: none !important;
  box-shadow: 14px 14px 28px rgba(30, 27, 75, .14);
  border-color: var(--accent);
}
.lp-faq-list details::before {
  /* peeled triangle corner — larger on open */
  width: 0; height: 0;
  border-style: solid;
  border-width: 0 28px 28px 0;
  border-color: transparent var(--accent) transparent transparent;
  border-top-right-radius: 12px;
}
.lp-faq-list details[open]::before { transform: scale(1.1); }

/* =================================================================
   Final CTA — backdrop logo definitely sits BEHIND the SVG
   ================================================================= */
.lp-final-art-wrap {
  position: relative;
  isolation: isolate;     /* new stacking context so z-index sticks */
}
.lp-final-backdrop {
  z-index: 0 !important;
}
.lp-final-art {
  position: relative;
  z-index: 2 !important;
  /* SVG circles + text only — no fill that would hide the logo */
  background: transparent !important;
}
.lp-final-art circle { fill: none !important; }

/* =================================================================
   Dashboard — progress rings, module states, stars, hologram,
   goal picker, 3-state track cards, breakout timer
   ================================================================= */

.module-card { position: relative; }

/* Circular progress ring — top-right of each card */
.mod-ring {
  position: absolute; top: 14px; right: 14px;
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.mod-ring-svg { width: 100%; height: 100%; overflow: visible; }
.mod-ring .ring-track { fill: none; stroke: var(--border-soft); stroke-width: 4; }
.mod-ring .ring-fill {
  fill: none; stroke: var(--accent); stroke-width: 4;
  stroke-linecap: round;
  transform: rotate(-90deg); transform-origin: 22px 22px;
  transition: stroke-dashoffset .7s cubic-bezier(.2,.8,.2,1);
}
.mod-ring .ring-num {
  font-family: var(--mono); font-size: 11px; font-weight: 800;
  fill: var(--ink-deep); dominant-baseline: middle;
}
.module-card.state-red    .mod-ring .ring-fill { stroke: var(--danger); }
.module-card.state-orange .mod-ring .ring-fill { stroke: var(--hl-warm); }
.module-card.state-green  .mod-ring .ring-fill { stroke: var(--success); }
.module-card.state-gold   .mod-ring .ring-fill { stroke: gold; filter: drop-shadow(0 0 4px rgba(255, 215, 0, .7)); }

/* Module state colours — applied to the whole tile when done */
.module-card.state-red    { background: rgba(185, 28, 28, .08); border-color: rgba(185, 28, 28, .35); }
.module-card.state-white  { background: var(--panel); border-color: var(--border); }
.module-card.state-orange { background: rgba(245, 185, 69, .12); border-color: rgba(245, 185, 69, .45); }
.module-card.state-green  { background: rgba(21, 128, 61, .10); border-color: rgba(21, 128, 61, .35); }
.module-card.state-gold {
  background: linear-gradient(135deg, rgba(255, 215, 0, .22), rgba(168, 85, 247, .15));
  border-color: rgba(245, 185, 69, .65);
  box-shadow: 0 14px 40px rgba(245, 185, 69, .25);
}
.module-card.needs-redo .mod-badge::before { content: "🚩 "; }

/* Per-module stars + state badge */
.mod-grade {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin: 10px 0 4px;
}
.mod-stars { letter-spacing: 0.04em; }
.mod-star { color: rgba(14, 12, 42, .15); font-size: 1rem; }
.mod-star.on { color: var(--hl-warm); text-shadow: 0 0 6px rgba(245, 185, 69, .35); }
.module-card.state-gold .mod-star.on { color: gold; text-shadow: 0 0 8px rgba(255, 215, 0, .6); }
.mod-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 999px;
  font-family: var(--mono); font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
}
.mod-badge-red    { background: rgba(185, 28, 28, .15); color: var(--danger); }
.mod-badge-white  { background: var(--bg-tint); color: var(--ink-soft); }
.mod-badge-orange { background: rgba(245, 185, 69, .25); color: #8a5d00; }
.mod-badge-green  { background: rgba(21, 128, 61, .15); color: var(--success); }
.mod-badge-gold   { background: gold; color: var(--ink-deep); box-shadow: 0 0 14px rgba(255, 215, 0, .55); }
.mod-note { margin: 6px 0 0; font-size: 0.85rem; line-height: 1.4; }

/* Tile centre holograms — celebratory star for gold mastery, thumbs-up
   for a strong pass, thumbs-down for a fail. Sit behind the tile content
   (pointer-events: none, low opacity) so they read as a watermark glow. */
.mod-hologram {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
  z-index: 0;
  opacity: .55;
}
.module-card > *:not(.mod-hologram) { z-index: 1; }
.module-card > .module-meta,
.module-card > h3,
.module-card > p,
.module-card > .mod-grade,
.module-card > .mod-note,
.module-card > .module-cta { position: relative; }
.mod-hologram .holo-glyph {
  font-size: 4.5rem; line-height: 1;
  text-shadow: none;
  animation: holoShimmer 4s ease-in-out infinite;
}

/* Gold: iridescent gradient text-fill star */
.mod-hologram-gold .holo-glyph {
  background: linear-gradient(135deg, #fde68a 0%, #f5b945 30%, #a855f7 65%, #f5b945 100%);
  background-size: 300% 300%;
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 20px rgba(245, 185, 69, .55));
}
.mod-hologram-gold { opacity: .8; }

/* Green: emoji can't gradient-fill, so glow + shimmer via drop-shadow */
.mod-hologram-green .holo-glyph {
  filter: drop-shadow(0 0 14px rgba(21, 128, 61, .65))
          drop-shadow(0 0 28px rgba(21, 128, 61, .35));
}

/* Red: same trick with a danger glow */
.mod-hologram-red .holo-glyph {
  filter: drop-shadow(0 0 14px rgba(185, 28, 28, .65))
          drop-shadow(0 0 28px rgba(185, 28, 28, .35));
}

@keyframes holoShimmer {
  0%, 100% { background-position: 0% 50%; transform: rotate(-3deg) scale(1); }
  50%      { background-position: 100% 50%; transform: rotate(3deg) scale(1.04); }
}
@media (prefers-reduced-motion: reduce) {
  .mod-hologram .holo-glyph { animation: none; }
}

/* Goal picker — playful but minimal */
.goal-picker {
  margin-top: 16px;
  background: var(--bg-tint); border: 1px solid var(--border-soft);
  border-radius: 12px; padding: 14px 18px;
}
.goal-picker summary {
  cursor: pointer; font-weight: 600; color: var(--ink-deep);
  list-style: none;
}
.goal-picker summary::-webkit-details-marker { display: none; }
.goal-picker[open] summary { margin-bottom: 10px; }
.goal-form { display: grid; gap: 10px; }
.goal-radio {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 10px 14px; border-radius: 10px;
  background: var(--panel); border: 1px solid var(--border-soft);
  cursor: pointer; transition: border-color .15s, background .15s;
}
.goal-radio:hover { border-color: var(--accent-light); background: var(--bg-tint); }
.goal-radio input { margin-top: 4px; accent-color: var(--accent); }
.goal-radio input:checked + span strong { color: var(--accent-dark); }
.goal-radio:has(input:checked) { border-color: var(--accent); background: rgba(124,58,237,.06); }
.goal-form button { justify-self: start; margin-top: 6px; }
.goal-status { margin-left: 8px; }

/* Track cards — 3 states: title / hover-flip body / click-expand details */
.track-3-state {
  position: relative; min-height: 120px;
  cursor: pointer; perspective: 1100px;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s, min-height .55s cubic-bezier(.2,.8,.2,1);
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; overflow: hidden;
}
.track-3-state .tc-face,
.track-3-state .tc-back {
  position: absolute; inset: 0; padding: 18px 20px;
  display: flex; flex-direction: column; justify-content: center;
  backface-visibility: hidden;
  transition: transform .55s cubic-bezier(.2,.8,.2,1);
}
.track-3-state .tc-face h3,
.track-3-state .tc-back h3 {
  font-family: var(--serif); font-weight: 500;
  font-size: 1.1rem; color: var(--ink-deep); margin: 0 0 4px;
}
.track-3-state .tc-back { transform: rotateY(180deg); background: var(--bg-tint); }
.track-3-state .tc-back p { margin: 4px 0 6px; color: var(--ink-soft); font-size: 0.92rem; line-height: 1.45; }
.track-3-state:not(.is-expanded):hover .tc-face,
.track-3-state:not(.is-expanded):focus-within .tc-face { transform: rotateY(-180deg); }
.track-3-state:not(.is-expanded):hover .tc-back,
.track-3-state:not(.is-expanded):focus-within .tc-back { transform: rotateY(0); }
.track-3-state .tc-hint { display: block; margin-top: 6px; color: var(--accent); font-size: 0.66rem; letter-spacing: 0.1em; }

/* Expanded state — replaces the flip, shows the full read */
.track-3-state .tc-expand {
  position: relative;
  padding: 22px 22px 20px;
  display: none;
  background: var(--panel);
}
.track-3-state .tc-expand h3 {
  font-family: var(--serif); font-weight: 500; font-size: 1.15rem;
  color: var(--ink-deep); margin: 0 0 8px;
}
.track-3-state .tc-expand p { color: var(--ink); font-size: 0.95rem; line-height: 1.55; margin: 0 0 8px; }
.track-3-state.is-expanded {
  min-height: 280px;
  box-shadow: 0 14px 36px rgba(30, 27, 75, .14);
  border-color: var(--accent);
}
.track-3-state.is-expanded .tc-face,
.track-3-state.is-expanded .tc-back { display: none; }
.track-3-state.is-expanded .tc-expand { display: block; }

@media (prefers-reduced-motion: reduce) {
  .track-3-state .tc-face, .track-3-state .tc-back { transition: none; }
}

/* =================================================================
   Breakout — 10-minute timer + back-to-study overlay animation
   ================================================================= */
.br-timer-wrap {
  display: flex; align-items: center; gap: 12px;
  background: var(--ink-deep); color: var(--cream);
  padding: 10px 16px; border-radius: 999px;
  margin: 0 0 16px;
  box-shadow: var(--shadow-soft);
  font-family: var(--mono); font-weight: 800;
}
.br-timer-wrap.is-warning { background: #b45309; }
.br-timer-wrap.is-critical { background: var(--danger); animation: timerPulse .6s ease-in-out infinite; }
@keyframes timerPulse { 50% { transform: scale(1.02); } }
.br-timer-label { font-size: 0.7rem; letter-spacing: 0.1em; color: var(--hl-warm); }
.br-timer-clock { font-size: 1.4rem; letter-spacing: 0.04em; }
.br-timer-bar {
  flex: 1; height: 4px; background: rgba(255,255,255,.18); border-radius: 999px; overflow: hidden;
}
.br-timer-bar > span {
  display: block; height: 100%; background: var(--hl-warm);
  width: 100%; transition: width 1s linear;
}

.br-shake { animation: shake .55s cubic-bezier(.36,.07,.19,.97) 3; }
@keyframes shake {
  10%, 90% { transform: translate3d(-1px, 0, 0); }
  20%, 80% { transform: translate3d(2px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
  40%, 60% { transform: translate3d(4px, 0, 0); }
}

.br-overlay {
  position: fixed; inset: 0;
  background: radial-gradient(circle at center, rgba(30,27,75,.94), rgba(14,12,42,.98));
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; padding: 24px;
  animation: brOverlayIn .5s cubic-bezier(.2,.8,.2,1);
}
@keyframes brOverlayIn { from { opacity: 0; backdrop-filter: blur(0); } to { opacity: 1; backdrop-filter: blur(6px); } }
.br-overlay-card {
  background: var(--panel); border-radius: 18px;
  padding: 38px 36px; max-width: 480px; width: 100%;
  text-align: center; color: var(--ink);
  position: relative; overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,.4);
}
.br-overlay-card .br-bookmark {
  font-size: 4.5rem; line-height: 1; display: inline-block;
  animation: bookWag 1.8s ease-in-out infinite;
}
@keyframes bookWag {
  0%, 100% { transform: rotate(-8deg); }
  50%      { transform: rotate(8deg); }
}
.br-overlay-card h2 {
  font-family: var(--serif); font-weight: 500;
  font-size: 1.8rem; margin: 16px 0 10px; color: var(--ink-deep);
}
.br-overlay-card p { color: var(--ink-soft); line-height: 1.55; margin: 0 0 18px; }
.br-overlay-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.br-overlay-card .br-confetti {
  position: absolute; pointer-events: none; font-size: 1.3rem;
  animation: floatUp 3s ease-in-out infinite;
}
@keyframes floatUp {
  0% { transform: translateY(0) rotate(0); opacity: 0; }
  20% { opacity: 1; }
  100% { transform: translateY(-180px) rotate(360deg); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .br-shake, .br-overlay-card .br-bookmark, .br-confetti, .br-timer-wrap.is-critical { animation: none !important; }
}

/* =================================================================
   Breakout-room leaderboard — top 10 + current user standing
   ================================================================= */
.br-leaderboard {
  background: var(--panel); border: 1px solid var(--border-soft);
  border-radius: 14px; padding: 16px 16px 14px;
  box-shadow: var(--shadow-soft);
  position: sticky; top: 80px;
  min-width: 0;
}
.br-lb-head { margin: 0 0 10px; }
.br-lb-title { margin: 4px 0 2px; font-size: 1.05rem; color: var(--ink-deep); }
.br-lb-sub { margin: 0; }

.br-lb-list { list-style: none; padding: 0; margin: 8px 0 12px; display: grid; gap: 4px; }
.br-lb-empty { padding: 10px 4px; }

.br-lb-row {
  display: grid; grid-template-columns: 36px 1fr auto;
  align-items: center; gap: 10px;
  padding: 7px 10px; border-radius: 10px;
  border: 1px solid transparent;
  background: transparent;
  font-size: 0.92rem; color: var(--ink);
  transition: background .12s, border-color .12s;
}
.br-lb-row + .br-lb-row { margin-top: 0; }
.br-lb-row.is-you {
  background: rgba(124, 58, 237, 0.08);
  border-color: rgba(124, 58, 237, 0.35);
}

.br-lb-rank { display: inline-flex; align-items: center; justify-content: center; }
.br-medal-rank { color: var(--muted); font-size: 0.78rem; }

/* Medal stars: ★ glyph filled with metal-gradient + soft drop-shadow */
.br-medal {
  display: inline-block; font-size: 1.4rem; line-height: 1;
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  text-shadow: none;
  filter: drop-shadow(0 1px 1px rgba(0,0,0,.35));
}
.br-medal-gold {
  background: linear-gradient(135deg, #fde68a 0%, #f5b945 45%, #b8860b 100%);
  -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 0 6px rgba(245, 185, 69, .55));
}
.br-medal-silver {
  background: linear-gradient(135deg, #f2f4f7 0%, #c0c4cc 50%, #6b7280 100%);
  -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 0 5px rgba(192, 196, 204, .55));
}
.br-medal-bronze {
  background: linear-gradient(135deg, #f0c79b 0%, #cd7f32 50%, #7a3e0e 100%);
  -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 0 5px rgba(205, 127, 50, .55));
}
.br-lb-row.rank-1 { background: linear-gradient(90deg, rgba(245, 185, 69, .14), transparent 70%); }
.br-lb-row.rank-2 { background: linear-gradient(90deg, rgba(192, 196, 204, .14), transparent 70%); }
.br-lb-row.rank-3 { background: linear-gradient(90deg, rgba(205, 127, 50, .14), transparent 70%); }

.br-lb-name {
  min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-weight: 600;
}
.br-you-pill {
  display: inline-block; margin-left: 6px;
  padding: 1px 7px; border-radius: 999px;
  background: var(--accent); color: white;
  font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase;
  font-weight: 800; vertical-align: middle;
}
.br-lb-score {
  font-family: var(--mono); font-weight: 800;
  color: var(--ink-deep);
}

.br-lb-me {
  margin: 0; padding: 8px 10px;
  background: var(--bg-tint); border-radius: 10px;
  font-size: 0.85rem; color: var(--ink-soft);
}
.br-lb-me strong { color: var(--accent); }

/* On narrow widths the leaderboard falls below the stage. Make it
   readable rather than squashed into the sidebar slot. */
@media (max-width: 1199px) {
  .br-leaderboard { position: static; margin-top: 0; }
}

/* =================================================================
   External-resource modal — keep learners inside the platform
   ================================================================= */
.ext-modal {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(14, 12, 42, 0.62);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  animation: extFade .18s ease-out;
}
@keyframes extFade { from { opacity: 0; } to { opacity: 1; } }
body.ext-modal-open { overflow: hidden; }

.ext-modal-card {
  width: min(1100px, 100%); height: min(82vh, 820px);
  background: var(--panel, #fff);
  border-radius: 14px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.ext-modal-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 10px 14px;
  background: var(--ink-deep, #0e0c2a);
  color: white;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.ext-modal-title-wrap { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.ext-modal-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: linear-gradient(135deg, #f5b945, #a855f7);
  flex-shrink: 0;
}
.ext-modal-title {
  font-weight: 700; font-size: 0.95rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ext-modal-host { color: rgba(255, 255, 255, 0.55); font-size: 0.78rem; white-space: nowrap; }

.ext-modal-actions { display: flex; gap: 8px; flex-shrink: 0; }
.ext-modal-newtab, .ext-modal-close {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: transparent; color: white;
  font: inherit; padding: 6px 12px;
  border-radius: 8px; cursor: pointer;
  transition: background .12s, border-color .12s;
}
.ext-modal-newtab { font-size: 0.78rem; letter-spacing: 0.04em; }
.ext-modal-close { padding: 4px 10px; font-size: 1.4rem; line-height: 1; }
.ext-modal-newtab:hover, .ext-modal-close:hover {
  background: rgba(255, 255, 255, 0.10); border-color: rgba(255, 255, 255, 0.4);
}

.ext-modal-body { flex: 1; min-height: 0; position: relative; background: #f3f1ec; }
.ext-modal-frame {
  width: 100%; height: 100%; border: 0; display: block;
  background: white;
}
.ext-modal-loader {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; color: var(--ink-soft, #555);
  background: rgba(255,255,255,0.96);
  pointer-events: none;
  font-size: 0.92rem;
}
.ext-modal-spinner {
  width: 32px; height: 32px;
  border: 3px solid rgba(124, 58, 237, 0.18);
  border-top-color: var(--accent, #7c3aed);
  border-radius: 50%;
  animation: extSpin 0.8s linear infinite;
}
@keyframes extSpin { to { transform: rotate(360deg); } }
.ext-modal-fallback {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 32px; text-align: center; gap: 12px;
  background: white;
}
.ext-modal-fallback p { margin: 0; max-width: 480px; }
.ext-modal-fallback-link { margin-top: 8px; }

@media (max-width: 720px) {
  .ext-modal { padding: 0; }
  .ext-modal-card { width: 100%; height: 100vh; border-radius: 0; }
}

/* === Rich lesson blocks: tables, visuals, match game (amendment #2/#6) === */
.lesson-table { width: 100%; border-collapse: collapse; margin: 12px 0; }
.lesson-table th, .lesson-table td { border: 1px solid var(--border, #2a2a40); padding: 8px 10px; text-align: left; vertical-align: top; }
.lesson-table th { background: var(--bg-tint, #1a1a2a); font-weight: 700; }
.table-wrap { overflow-x: auto; }

.visuals { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.visual { margin: 0; padding: 12px; border: 1px solid var(--border, #2a2a40); border-radius: 10px; text-align: center; }
.svg-frame { display: flex; justify-content: center; padding: 8px; }
.svg-frame svg { max-width: 100%; height: auto; }
.emoji-art { font-size: 3rem; line-height: 1.2; }
.visual figcaption { margin-top: 6px; font-size: 0.85rem; color: var(--muted, #9aa); }

.match-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.match-col { list-style: none; padding: 0; margin: 0; }
.match-col li { padding: 8px 10px; margin: 4px 0; border: 1px solid var(--border, #2a2a40); border-radius: 6px; cursor: pointer; transition: outline 0.1s; }
.match-col li.picked { outline: 2px solid var(--accent, #8a6cff); }
.match-col li.matched { background: rgba(70,211,154,.12); border-color: #46d39a; cursor: default; }
.match-col li.wrong { background: rgba(255,136,102,.18); }
/* =====================================================================
   Landing v2 — dark mirror of innovatexperts-landing visual language
   Activated by <body class="has-lp-v2"> set inline in landing.html.
   Scoped entirely under body.has-lp-v2 so other pages stay light.
   ===================================================================== */

body.has-lp-v2 {
  --v2-bg:        #07070f;
  --v2-surface:   #0e0c22;
  --v2-card:      #141230;
  --v2-purple:    #7c3aed;
  --v2-purple-2:  #8b5cf6;
  --v2-purple-3:  #a855f7;
  --v2-blue:      #3b82f6;
  --v2-emerald:   #10b981;
  --v2-amber:     #f59e0b;
  --v2-text-1:    #f0eeff;
  --v2-text-2:    #9d99c0;
  --v2-text-3:    #4d4a6e;
  --v2-border:      rgba(124, 58, 237, 0.18);
  --v2-border-soft: rgba(139, 92, 246, 0.08);
  color-scheme: dark;
  color: var(--v2-text-1);
  background:
    radial-gradient(ellipse 100% 60% at 50% -10%, rgba(124,58,237,0.22) 0%, transparent 65%),
    radial-gradient(ellipse 60% 40% at 80% 90%, rgba(59,130,246,0.10) 0%, transparent 55%),
    var(--v2-bg);
}

/* Film grain overlay */
body.has-lp-v2::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 1000;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  background-size: 200px;
  opacity: 0.32;
}

/* Header — glass over dark */
body.has-lp-v2 .site-header {
  background: rgba(7, 7, 15, 0.55);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--v2-border-soft);
}
body.has-lp-v2 .brand { color: var(--v2-text-1); }
body.has-lp-v2 .brand-logo {
  border-radius: 50%; padding: 2px;
  background: white;
  box-shadow: 0 0 14px rgba(124,58,237,0.32);
  width: 40px; height: 40px;
}
body.has-lp-v2 .brand-name { color: var(--v2-text-1); }
body.has-lp-v2 .brand-name .x {
  background: linear-gradient(135deg, var(--v2-purple), var(--v2-purple-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: normal;
}
body.has-lp-v2 .brand-tagline { color: var(--v2-purple-3); }
body.has-lp-v2 .site-nav a { color: var(--v2-text-2); }
body.has-lp-v2 .site-nav a:hover { color: var(--v2-text-1); }
body.has-lp-v2 .site-nav a.cta {
  background: var(--v2-purple);
  color: white;
  border-radius: 999px;
  box-shadow: 0 0 28px rgba(124,58,237,0.45);
}
body.has-lp-v2 .site-nav a.cta:hover {
  background: var(--v2-purple-2);
  box-shadow: 0 0 44px rgba(124,58,237,0.65);
}

/* Site footer dark */
body.has-lp-v2 .site-footer {
  background: transparent;
  border-top-color: var(--v2-border-soft);
  color: var(--v2-text-3);
}

/* Grain layer scoped to body (replace the .lp-grain divs use) */
body.has-lp-v2 .lp-grain { display: none; }

/* Scroll progress — purple over dark */
body.has-lp-v2 .lp-scroll-progress span {
  background: linear-gradient(90deg, var(--v2-purple), var(--v2-purple-3));
}

/* Freshness pill — dark */
body.has-lp-v2 .lp-freshness {
  color: var(--v2-text-3);
  border-color: var(--v2-border-soft);
}

/* =========================
   v2 hero
   ========================= */
body.has-lp-v2 .lp-v2-hero {
  position: relative;
  min-height: 100dvh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 96px 24px 64px;
  margin: -40px calc(50% - 50vw) 0;
}

body.has-lp-v2 .lp-v2-hero-dot-grid {
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(124,58,237,0.18) 1px, transparent 1px);
  background-size: 28px 28px;
  opacity: 0.25;
  pointer-events: none;
}
body.has-lp-v2 .lp-v2-hero-glow {
  position: absolute;
  top: 32%; left: 50%;
  transform: translate(-50%, -50%);
  width: 680px; height: 680px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.14) 0%, transparent 60%);
  pointer-events: none;
}
body.has-lp-v2 .lp-v2-hero-fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 72vh;
  background: linear-gradient(to top, #07070f 0%, rgba(7,7,15,0.88) 35%, transparent 100%);
  pointer-events: none;
}

/* Beam svg fills hero */
body.has-lp-v2 .lp-v2-beams {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  overflow: hidden;
}
body.has-lp-v2 .lp-v2-beams path {
  stroke-dasharray: 800;
  animation: lp-v2-beam-stream 7s ease-in-out infinite;
}
body.has-lp-v2 .lp-v2-beams path.b2 { animation-delay: 1.3s; animation-duration: 8s; }
body.has-lp-v2 .lp-v2-beams path.b3 { animation-delay: 2.4s; animation-duration: 6s; }
body.has-lp-v2 .lp-v2-beams path.b4 { animation-delay: 0.8s; animation-duration: 9s; }
@keyframes lp-v2-beam-stream {
  0%   { stroke-dashoffset: 800; opacity: 0; }
  40%  { stroke-dashoffset: 0;   opacity: 0.9; }
  80%  { stroke-dashoffset: -400; opacity: 0.6; }
  100% { stroke-dashoffset: -800; opacity: 0; }
}

/* Logo well — centred above headline, with orbital rings + halo */
body.has-lp-v2 .lp-v2-logo-well {
  position: relative;
  width: 420px; height: 420px;
  margin: 16px 0 -120px;
  display: flex; align-items: center; justify-content: center;
  z-index: 1;
}
body.has-lp-v2 .lp-v2-logo-img {
  width: 240px; height: 240px;
  object-fit: contain;
  filter: drop-shadow(0 0 64px rgba(124,58,237,0.55));
  opacity: 0.92;
  animation: lp-v2-float-y 6s ease-in-out infinite;
}
body.has-lp-v2 .lp-v2-ring {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
body.has-lp-v2 .lp-v2-ring.r1 {
  width: 400px; height: 400px;
  border: 1px solid rgba(124,58,237,0.10);
  animation: lp-v2-orbit-cw 24s linear infinite;
}
body.has-lp-v2 .lp-v2-ring.r2 {
  width: 320px; height: 320px;
  border: 1px dashed rgba(168,85,247,0.18);
  animation: lp-v2-orbit-ccw 32s linear infinite;
}
body.has-lp-v2 .lp-v2-ring.r3 {
  width: 262px; height: 262px;
  border: 1px solid rgba(124,58,237,0.20);
  animation: lp-v2-orbit-cw 40s linear infinite;
}
body.has-lp-v2 .lp-v2-halo {
  position: absolute;
  width: 340px; height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,0.22) 0%, transparent 70%);
  filter: blur(36px);
  animation: lp-v2-halo-pulse 4.5s ease-in-out infinite;
}
@keyframes lp-v2-orbit-cw  { from { transform: rotate(0deg); }  to { transform: rotate(360deg); } }
@keyframes lp-v2-orbit-ccw { from { transform: rotate(0deg); }  to { transform: rotate(-360deg); } }
@keyframes lp-v2-halo-pulse {
  0%, 100% { opacity: 0.5; transform: scale(0.96); }
  50%      { opacity: 1;   transform: scale(1.04); }
}
@keyframes lp-v2-float-y {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* Hero copy stack */
body.has-lp-v2 .lp-v2-hero-copy {
  position: relative;
  z-index: 2;
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  padding: 0 16px;
}

body.has-lp-v2 .lp-v2-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono, ui-monospace, monospace);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--v2-purple-3);
  background: rgba(124, 58, 237, 0.10);
  border: 1px solid rgba(124, 58, 237, 0.24);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 24px;
}
body.has-lp-v2 .lp-v2-eyebrow::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--v2-purple-3);
  box-shadow: 0 0 12px rgba(168,85,247,0.8);
  animation: lp-v2-halo-pulse 2.4s ease-in-out infinite;
}

body.has-lp-v2 .lp-v2-h1 {
  font-family: var(--serif, "Fraunces", ui-serif, Georgia, serif);
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  line-height: 0.96;
  letter-spacing: -0.02em;
  font-weight: 500;
  color: var(--v2-text-1);
  margin: 0 0 22px;
}
body.has-lp-v2 .lp-v2-h1 .shimmer {
  background: linear-gradient(90deg, var(--v2-purple), var(--v2-purple-3), var(--v2-purple));
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
  animation: lp-v2-shimmer 3.5s linear infinite;
}
@keyframes lp-v2-shimmer {
  0%   { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

body.has-lp-v2 .lp-v2-sub {
  font-size: 1.06rem;
  line-height: 1.6;
  color: var(--v2-text-2);
  max-width: 44ch;
  margin: 0 auto 32px;
  font-weight: 400;
}

body.has-lp-v2 .lp-v2-cta-cluster {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}
body.has-lp-v2 .lp-v2-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  border: 1px solid transparent;
  text-decoration: none;
  transition: all 0.2s ease;
}
body.has-lp-v2 .lp-v2-btn.primary {
  background: var(--v2-purple);
  color: white;
  box-shadow: 0 0 36px rgba(124,58,237,0.55);
}
body.has-lp-v2 .lp-v2-btn.primary:hover {
  background: var(--v2-purple-2);
  box-shadow: 0 0 56px rgba(124,58,237,0.80);
  transform: translateY(-1px);
}
body.has-lp-v2 .lp-v2-btn.ghost {
  background: transparent;
  color: var(--v2-text-2);
  border-color: rgba(124,58,237,0.26);
}
body.has-lp-v2 .lp-v2-btn.ghost:hover {
  color: var(--v2-text-1);
  border-color: rgba(124,58,237,0.55);
}
body.has-lp-v2 .lp-v2-btn .arrow-cap {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  display: inline-flex; align-items: center; justify-content: center;
  transition: transform 0.2s ease;
}
body.has-lp-v2 .lp-v2-btn:hover .arrow-cap {
  transform: translate(2px, -2px);
}

body.has-lp-v2 .lp-v2-microproof {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--v2-text-2);
  font-size: 0.88rem;
}
body.has-lp-v2 .lp-v2-microproof .pulse {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--v2-emerald);
  box-shadow: 0 0 0 4px rgba(16,185,129,0.18);
  animation: lp-v2-halo-pulse 2.4s ease-in-out infinite;
}

/* =========================
   v2 pillars — "How it works"
   ========================= */
body.has-lp-v2 .lp-v2-pillars {
  position: relative;
  padding: 96px 24px;
  margin: 0 calc(50% - 50vw);
  background: var(--v2-bg);
}
body.has-lp-v2 .lp-v2-pillars-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 56px;
}
@media (min-width: 980px) {
  body.has-lp-v2 .lp-v2-pillars-inner {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    align-items: center;
  }
}

body.has-lp-v2 .lp-v2-pillars-h2 {
  font-family: var(--serif, "Fraunces", serif);
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--v2-text-1);
  margin: 16px 0 16px;
  font-weight: 500;
}
body.has-lp-v2 .lp-v2-pillars-h2 .shimmer {
  background: linear-gradient(90deg, var(--v2-purple), var(--v2-purple-3), var(--v2-blue));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
}
body.has-lp-v2 .lp-v2-pillars-lede {
  color: var(--v2-text-2);
  line-height: 1.6;
  max-width: 42ch;
  font-size: 1rem;
}

body.has-lp-v2 .lp-v2-pillar-list {
  list-style: none;
  margin: 0; padding: 0;
  display: grid;
  gap: 14px;
}
body.has-lp-v2 .lp-v2-pillar {
  position: relative;
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 18px;
  padding: 22px;
  background: var(--v2-card);
  border: 1px solid var(--v2-border-soft);
  border-radius: 18px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
body.has-lp-v2 .lp-v2-pillar:hover {
  border-color: var(--v2-border);
  transform: translateY(-2px);
}
body.has-lp-v2 .lp-v2-pillar-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(124,58,237,0.10);
  border: 1px solid var(--v2-border);
}
body.has-lp-v2 .lp-v2-pillar-icon svg { width: 22px; height: 22px; }
body.has-lp-v2 .lp-v2-pillar.p2 .lp-v2-pillar-icon { background: rgba(59,130,246,0.10); border-color: rgba(59,130,246,0.30); color: var(--v2-blue); }
body.has-lp-v2 .lp-v2-pillar.p3 .lp-v2-pillar-icon { background: rgba(16,185,129,0.10); border-color: rgba(16,185,129,0.30); color: var(--v2-emerald); }
body.has-lp-v2 .lp-v2-pillar.p4 .lp-v2-pillar-icon { background: rgba(245,158,11,0.10); border-color: rgba(245,158,11,0.30); color: var(--v2-amber); }
body.has-lp-v2 .lp-v2-pillar.p1 .lp-v2-pillar-icon { color: var(--v2-purple-3); }

body.has-lp-v2 .lp-v2-pillar-label {
  display: block;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--v2-text-1);
  margin-bottom: 4px;
}
body.has-lp-v2 .lp-v2-pillar-sub {
  display: block;
  color: var(--v2-text-2);
  font-size: 0.88rem;
  line-height: 1.55;
}

/* =========================
   Retheme existing lp-* sections for dark
   ========================= */

/* Sections backgrounds → dark, text light */
body.has-lp-v2 .lp-section {
  background: transparent;
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-section .lp-band,
body.has-lp-v2 .lp-section h2,
body.has-lp-v2 .lp-section h3 {
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-h2 {
  font-family: var(--serif, "Fraunces", serif);
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-h2 em {
  background: linear-gradient(90deg, var(--v2-purple), var(--v2-purple-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
}
body.has-lp-v2 .lp-section-sub,
body.has-lp-v2 .lp-section p {
  color: var(--v2-text-2);
}
body.has-lp-v2 .lp-kicker {
  color: var(--v2-purple-3);
}
body.has-lp-v2 .lp-kicker .dot { background: var(--v2-purple-3); box-shadow: 0 0 0 4px rgba(168,85,247,.18); }

/* Counter strip — dark */
body.has-lp-v2 .lp-counters {
  background: rgba(14, 12, 34, 0.55);
  border: 1px solid var(--v2-border-soft);
}
body.has-lp-v2 .lp-counter .num { color: var(--v2-text-1); }
body.has-lp-v2 .lp-counter .label { color: var(--v2-text-3); }

/* Ticker dark */
body.has-lp-v2 .lp-ticker {
  background: transparent;
  border-top: 1px solid var(--v2-border-soft);
  border-bottom: 1px solid var(--v2-border-soft);
}
body.has-lp-v2 .lp-ticker-track span {
  color: var(--v2-text-3);
}

/* Diagnostic card — dark glass */
body.has-lp-v2 .lp-diag-card {
  background: var(--v2-card);
  border: 1px solid var(--v2-border-soft);
  box-shadow: 0 24px 48px rgba(0,0,0,0.35);
  color: var(--v2-text-1);
}
body.has-lp-v2 .diag-eyebrow { color: var(--v2-purple-3); }
body.has-lp-v2 .diag-q { color: var(--v2-text-1); }
body.has-lp-v2 .diag-opt {
  background: rgba(124,58,237,0.06);
  border: 1px solid var(--v2-border-soft);
  color: var(--v2-text-1);
}
body.has-lp-v2 .diag-opt:hover {
  background: rgba(124,58,237,0.18);
  border-color: var(--v2-border);
}
body.has-lp-v2 .diag-summary li {
  color: var(--v2-text-2);
  border-bottom-color: var(--v2-border-soft);
}
body.has-lp-v2 .diag-summary .sig { color: var(--v2-text-3); }
body.has-lp-v2 .diag-progress .step {
  background: rgba(255,255,255,0.06);
}
body.has-lp-v2 .diag-progress .step.active,
body.has-lp-v2 .diag-progress .step.done {
  background: var(--v2-purple);
}

/* Curriculum tiles — flip-card. .lp-curr-tile is transparent;
   the two faces hold the visible surface. Theme both faces. */
body.has-lp-v2 .lp-curr-tile { color: var(--v2-text-1); }
body.has-lp-v2 .lp-curr-tile .ct-face {
  background: var(--v2-card) !important;
  border-color: var(--v2-border-soft) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35) !important;
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-curr-tile:hover .ct-face,
body.has-lp-v2 .lp-curr-tile:focus-within .ct-face {
  box-shadow: 0 22px 50px rgba(124, 58, 237, 0.32) !important;
}
body.has-lp-v2 .lp-curr-tile .ct-face h3 {
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-curr-tile .ct-face p {
  color: var(--v2-text-2);
}
body.has-lp-v2 .lp-curr-tile .ct-face .lp-curr-num {
  background: rgba(124, 58, 237, 0.20);
  color: var(--v2-purple-3);
}
body.has-lp-v2 .lp-curr-tile .ct-face .lp-curr-go {
  color: var(--v2-purple-3);
}
body.has-lp-v2 .lp-curr-tile .ct-back {
  background: linear-gradient(135deg, var(--v2-purple), #4c1d95) !important;
  border-color: var(--v2-purple) !important;
}
body.has-lp-v2 .lp-curr-tile .ct-back h3,
body.has-lp-v2 .lp-curr-tile .ct-back p,
body.has-lp-v2 .lp-curr-tile .ct-back .lp-curr-go {
  color: white;
}
body.has-lp-v2 .lp-curr-tile .ct-back .lp-curr-num {
  background: rgba(255, 255, 255, 0.18);
  color: white;
}

/* Tracks — dark */
body.has-lp-v2 .lp-tracks .lp-track {
  background: var(--v2-card);
  border: 1px solid var(--v2-border-soft);
  color: var(--v2-text-1);
}

/* Buttons remap to v2 palette */
body.has-lp-v2 .lp-btn-ink {
  background: var(--v2-purple);
  border-color: var(--v2-purple);
  color: white;
  box-shadow: 0 0 32px rgba(124,58,237,0.45);
}
body.has-lp-v2 .lp-btn-ink:hover {
  background: var(--v2-purple-2);
  border-color: var(--v2-purple-2);
  box-shadow: 0 0 52px rgba(124,58,237,0.65);
}
body.has-lp-v2 .lp-btn-ghost {
  background: transparent;
  color: var(--v2-text-2);
  border-color: rgba(124,58,237,0.26);
}
body.has-lp-v2 .lp-btn-ghost:hover {
  background: rgba(124,58,237,0.12);
  color: var(--v2-text-1);
  border-color: rgba(124,58,237,0.55);
}
body.has-lp-v2 .lp-btn-light {
  background: white;
  color: var(--v2-bg);
  border-color: white;
}
body.has-lp-v2 .lp-btn-outline {
  background: transparent;
  color: var(--v2-text-1);
  border-color: rgba(255,255,255,0.30);
}
body.has-lp-v2 .lp-btn-outline:hover {
  background: white;
  color: var(--v2-bg);
}

/* Final CTA — dark with sparkles vibe */
body.has-lp-v2 .lp-final {
  background:
    radial-gradient(ellipse 60% 80% at 50% 0%, rgba(124,58,237,0.22), transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(59,130,246,0.12), transparent 60%),
    var(--v2-bg);
  color: var(--v2-text-1);
  border-top: 1px solid var(--v2-border-soft);
}
body.has-lp-v2 .lp-final h2,
body.has-lp-v2 .lp-final p {
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-final em {
  background: linear-gradient(90deg, var(--v2-purple), var(--v2-purple-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
}

/* FAQ — real selectors target .lp-faq-list details / summary / p */
body.has-lp-v2 .lp-faq-list details {
  background: var(--v2-card) !important;
  border-color: var(--v2-border-soft) !important;
  color: var(--v2-text-1);
  box-shadow: none !important;
}
body.has-lp-v2 .lp-faq-list details[open] {
  border-color: var(--v2-purple) !important;
  background: rgba(20, 18, 48, 0.95) !important;
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.22) !important;
}
body.has-lp-v2 .lp-faq-list summary {
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-faq-list summary::after {
  color: var(--v2-purple-3);
}
body.has-lp-v2 .lp-faq-list p {
  color: var(--v2-text-2);
}

/* Brandmark inside hero */
body.has-lp-v2 .lp-brandmark { display: none; }

@media (max-width: 720px) {
  body.has-lp-v2 .lp-v2-hero { padding: 64px 16px 40px; }
  body.has-lp-v2 .lp-v2-logo-well { width: 280px; height: 280px; margin: 0 0 -80px; }
  body.has-lp-v2 .lp-v2-logo-img { width: 160px; height: 160px; }
  body.has-lp-v2 .lp-v2-ring.r1 { width: 260px; height: 260px; }
  body.has-lp-v2 .lp-v2-ring.r2 { width: 210px; height: 210px; }
  body.has-lp-v2 .lp-v2-ring.r3 { width: 170px; height: 170px; }
  body.has-lp-v2 .lp-v2-halo { width: 220px; height: 220px; }
  body.has-lp-v2 .lp-v2-pillars { padding: 64px 16px; }
}

@media (prefers-reduced-motion: reduce) {
  body.has-lp-v2 .lp-v2-logo-img,
  body.has-lp-v2 .lp-v2-ring,
  body.has-lp-v2 .lp-v2-halo,
  body.has-lp-v2 .lp-v2-beams path,
  body.has-lp-v2 .lp-v2-h1 .shimmer,
  body.has-lp-v2 .lp-v2-eyebrow::before,
  body.has-lp-v2 .lp-v2-microproof .pulse {
    animation: none !important;
  }
}

/* =========================
   v2 interior re-theme — sweep
   ========================= */

/* Curriculum rows + meta — dark cards */
body.has-lp-v2 .lp-curriculum { border-top-color: var(--v2-border-soft); }
body.has-lp-v2 .lp-curr-row {
  border-bottom-color: var(--v2-border-soft);
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-curr-row:hover {
  background: rgba(124, 58, 237, 0.08);
}
body.has-lp-v2 .lp-curr-num { color: var(--v2-purple-3); }
body.has-lp-v2 .lp-curr-meta h3 { color: var(--v2-text-1); }
body.has-lp-v2 .lp-curr-meta p  { color: var(--v2-text-2); }
body.has-lp-v2 .lp-curr-arrow   { color: rgba(255,255,255,0.30); }
body.has-lp-v2 .lp-curr-row:hover .lp-curr-arrow { color: var(--v2-purple-3); }

/* Tracks mosaic — dark cards with restyled accent variant */
body.has-lp-v2 .lp-track-mosaic .track {
  background: var(--v2-card);
  border-color: var(--v2-border-soft);
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-track-mosaic .track h3 { color: var(--v2-text-1); }
body.has-lp-v2 .lp-track-mosaic .track p  { color: var(--v2-text-2); }
body.has-lp-v2 .lp-track-mosaic .track:hover {
  box-shadow: 0 16px 40px rgba(124, 58, 237, 0.22);
  border-color: var(--v2-border);
}
body.has-lp-v2 .lp-track-mosaic .track:nth-child(2) {
  background: linear-gradient(135deg, #1a1640, var(--v2-purple));
  border-color: var(--v2-purple);
}
body.has-lp-v2 .lp-track-mosaic .track:nth-child(2) h3,
body.has-lp-v2 .lp-track-mosaic .track:nth-child(2) p { color: white; }
body.has-lp-v2 .lp-track-mosaic .track:nth-child(4) {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.30);
}
body.has-lp-v2 .lp-track-mosaic .track .track-tag { color: var(--v2-purple-3); }
body.has-lp-v2 .lp-track-mosaic .track .track-art { color: rgba(124, 58, 237, 0.20); }

/* Feature grid — flip cards (practical + responsible AI sections).
   Style both faces; the outer .feat is just a flip container. */
body.has-lp-v2 .feat-flip .feat-face,
body.has-lp-v2 .feat-flip .feat-back,
body.has-lp-v2 .lp-resp .feat .resp-face,
body.has-lp-v2 .lp-resp .feat .resp-back {
  background: var(--v2-card) !important;
  border-color: var(--v2-border-soft) !important;
  color: var(--v2-text-1);
}
body.has-lp-v2 .feat-flip .feat-back,
body.has-lp-v2 .lp-resp .feat .resp-back {
  background: linear-gradient(135deg, #1a1640, #2a2160) !important;
  border-color: var(--v2-border) !important;
}
body.has-lp-v2 .feat-flip:hover {
  box-shadow: 0 22px 50px rgba(124, 58, 237, 0.28);
}
body.has-lp-v2 .feat-flip .feat-face h3,
body.has-lp-v2 .lp-resp .feat .resp-face h3 { color: var(--v2-text-1); }
body.has-lp-v2 .feat-flip .feat-face p,
body.has-lp-v2 .lp-resp .feat .resp-face p { color: var(--v2-text-2); }
body.has-lp-v2 .feat-flip .feat-face .feat-num,
body.has-lp-v2 .feat-flip .feat-hint,
body.has-lp-v2 .lp-resp .feat .resp-face .feat-num { color: var(--v2-purple-3); }
body.has-lp-v2 .feat-flip .feat-back h3,
body.has-lp-v2 .feat-flip .feat-back p,
body.has-lp-v2 .feat-flip .feat-back .feat-num,
body.has-lp-v2 .lp-resp .feat .resp-back h3,
body.has-lp-v2 .lp-resp .feat .resp-back p,
body.has-lp-v2 .lp-resp .feat .resp-back .feat-num { color: var(--v2-amber); }
body.has-lp-v2 .feat-flip .feat-back .feat-pre,
body.has-lp-v2 .feat-flip .feat-back .feat-slide,
body.has-lp-v2 .feat-flip .feat-back pre {
  color: rgba(240, 238, 255, 0.95);
}

/* Rail (numbered steps) — dark cards */
body.has-lp-v2 .lp-rail li {
  background: var(--v2-card);
  border: 1px solid var(--v2-border-soft);
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-rail-num {
  background: rgba(124, 58, 237, 0.16);
  color: var(--v2-purple-3);
}
body.has-lp-v2 .lp-rail li h3 { color: var(--v2-text-1); }
body.has-lp-v2 .lp-rail li p  { color: var(--v2-text-2); }
body.has-lp-v2 .lp-rail-glyph { color: rgba(124, 58, 237, 0.18); }

/* Capstone — flip cards (cap-face / cap-back). Style both faces. */
body.has-lp-v2 .lp-capstone-grid article {
  background: transparent;
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-capstone-grid article .cap-face {
  background: var(--v2-card) !important;
  border-color: var(--v2-border-soft) !important;
}
body.has-lp-v2 .lp-capstone-grid article .cap-face h3 {
  color: var(--v2-text-1);
}
body.has-lp-v2 .lp-capstone-grid article .cap-back {
  background: linear-gradient(135deg, var(--v2-purple), #4c1d95) !important;
  border-color: var(--v2-purple) !important;
}
body.has-lp-v2 .lp-capstone-grid article .cap-back h3 { color: var(--v2-amber); }
body.has-lp-v2 .lp-capstone-grid article .cap-back p  { color: rgba(255,255,255,0.95); }

/* Cert grid */
body.has-lp-v2 .lp-cert-grid > * {
  background: var(--v2-card);
  border: 1px solid var(--v2-border-soft);
  color: var(--v2-text-1);
}

/* Fineprint */
body.has-lp-v2 .lp-fineprint { color: var(--v2-text-2); }
body.has-lp-v2 .lp-fineprint .sep { color: var(--v2-text-3); }

/* Tinted section — wash dark */
body.has-lp-v2 .lp-section-tinted {
  background: var(--v2-surface);
  margin: 0 calc(50% - 50vw);
  padding-left: 24px; padding-right: 24px;
}

/* Final CTA artwork wrapper */
body.has-lp-v2 .lp-final-backdrop { display: none; }
body.has-lp-v2 .lp-final-art { filter: drop-shadow(0 0 32px rgba(124, 58, 237, 0.45)); }

/* Faq list spacing */
body.has-lp-v2 .lp-faq-list { gap: 12px; }
body.has-lp-v2 .lp-faq summary::marker { color: var(--v2-purple-3); }

/* Aeo summary + lede (if still present anywhere) */
body.has-lp-v2 .lp-aeo-summary { color: var(--v2-text-2); }
body.has-lp-v2 .lp-aeo-summary strong { color: var(--v2-text-1); }
body.has-lp-v2 .lp-lede { color: var(--v2-text-2); }

/* Diag footer marquee */
body.has-lp-v2 .lp-diag-footer { color: var(--v2-text-3); }
