/* ==========================================================================
   Manifesto — Interactive Course
   Extends the site's visual language (base.css tokens + self-hosted fonts).
   Load base.css first, then this file.
   ========================================================================== */

:root {
  --paper: #f7f6f2;
  --card: #ffffff;
  --ink: #21252e;
  --ink-soft: #565d6b;
  --line: #e3e0d8;
  --accent: #1b4f5c; /* course chrome — ties to the main site header */
  --accent-deep: #123a44;
  --maxw: 1180px;
  --radius: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

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

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent-deep); }
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 200;
}
.skip:focus { left: 0.5rem; top: 0.5rem; }

/* --- Theme shapes --------------------------------------------------------- */
.shape { display: inline-block; vertical-align: middle; }
.shape :where(path, rect, circle) { fill: currentColor; }
.shape-1 { color: var(--theme-1); }
.shape-2 { color: var(--theme-2); }
.shape-3 { color: var(--theme-3); }

/* --- Buttons -------------------------------------------------------------- */
.c-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font: inherit;
  font-weight: 600;
  padding: 0.7rem 1.4rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: filter 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.c-btn:hover { filter: brightness(1.08); }
.c-btn.ghost { background: transparent; color: var(--accent); }
.c-btn.ghost:hover { background: color-mix(in srgb, var(--accent) 8%, transparent); filter: none; }
.c-btn.small { padding: 0.4rem 0.85rem; font-size: 0.85rem; }
.c-btn.large { padding: 0.9rem 1.9rem; font-size: 1.05rem; }

/* ==========================================================================
   WELCOME (index.html)
   ========================================================================== */
.welcome {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
}
.welcome-main {
  max-width: 44rem;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  text-align: center;
  align-self: center;
}
.hero-shapes {
  display: flex;
  justify-content: center;
  gap: 1.4rem;
  margin-bottom: 2.4rem;
}
.hero-shapes .shape {
  width: clamp(2.6rem, 7vw, 3.6rem);
  height: clamp(2.6rem, 7vw, 3.6rem);
}
/* Shapes are visible by default; the entrance is a motion-safe enhancement. */
@media (prefers-reduced-motion: no-preference) {
  .hero-shapes .shape { animation: shape-in 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .hero-shapes .shape-1 { animation-delay: 0.05s; }
  .hero-shapes .shape-2 { animation-delay: 0.18s; }
  .hero-shapes .shape-3 { animation-delay: 0.31s; }
}
@keyframes shape-in {
  from { transform: translateY(16px) scale(0.8); }
  to { transform: none; }
}
.welcome h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.3rem, 6vw, 3.8rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
}
.welcome .tagline {
  font-size: clamp(1.05rem, 2.4vw, 1.3rem);
  color: var(--ink-soft);
  margin-top: 1rem;
}
.welcome .lede {
  font-size: 1.1rem;
  line-height: 1.7;
  margin: 2rem auto 0;
  max-width: 34em;
}
.welcome .lede strong { font-weight: 600; }
.welcome-actions {
  margin-top: 2.4rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}
.outcomes {
  margin: 2.4rem auto 0;
  max-width: 34em;
  text-align: left;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.4rem 1.2rem;
}
.outcomes summary {
  cursor: pointer;
  font-weight: 600;
  padding: 0.8rem 0;
  list-style: none;
}
.outcomes summary::-webkit-details-marker { display: none; }
.outcomes summary::before { content: "＋ "; color: var(--accent); }
.outcomes[open] summary::before { content: "－ "; }
.outcomes ul { margin: 0 0 1rem 1.2rem; }
.outcomes li { margin: 0.35rem 0; }
.outcomes-subhead { font-family: var(--font-display); font-size: 1.05rem; margin: 0.4rem 0 0.6rem; }
.outcomes-formal { margin: 0 0 1rem 1.2rem; }
.outcomes-formal li { margin: 0.4rem 0; }

.welcome-top, .welcome-foot {
  padding: 1.2rem 1.5rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
}
.welcome-foot { text-align: center; border-top: 1px solid var(--line); }
.welcome-top { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.welcome-top .brand { font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.welcome-top a { text-decoration: none; }

/* ==========================================================================
   COURSE SHELL (course.html)
   ========================================================================== */
.course-header {
  position: sticky;
  top: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem 1.2rem;
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
.course-brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--ink);
  text-decoration: none;
}
.header-actions { margin-left: auto; display: flex; gap: 0.6rem; }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.4rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.4rem 0.7rem;
  cursor: pointer;
  color: var(--ink);
}
.nav-toggle::before {
  content: "";
  width: 1rem;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor, 0 -5px 0 currentColor;
}

.progress-rail {
  height: 4px;
  background: var(--line);
}
.progress-bar {
  height: 100%;
  width: 0;
  background: var(--accent);
  transition: width 0.35s ease;
}

.course-app {
  display: grid;
  grid-template-columns: 264px 1fr;
  gap: 2.5rem;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* --- Sidebar navigation --------------------------------------------------- */
.course-nav {
  align-self: start;
  position: sticky;
  top: 5.2rem;
  padding: 1.8rem 0;
}
.nav-heading {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.7rem;
  padding-left: 0.6rem;
}
.nav-list { list-style: none; display: grid; gap: 0.15rem; }
.nav-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.6rem;
  border-radius: 6px;
  text-decoration: none;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.3;
}
.nav-link:hover { background: color-mix(in srgb, var(--accent) 7%, transparent); }
.nav-link[aria-current="true"] {
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  font-weight: 600;
}
.nav-marker {
  flex: none;
  width: 1.4rem;
  display: inline-flex;
  justify-content: center;
  align-items: center;
}
.nav-marker .shape { width: 0.78rem; height: 0.78rem; }
.nav-num {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.nav-label { flex: 1; }
.nav-tick { flex: none; width: 1rem; text-align: center; color: var(--theme-3); font-weight: 700; }
.nav-link.completed .nav-tick::after { content: "✓"; }
.nav-link.visited:not(.completed) .nav-tick::after { content: "·"; color: var(--ink-soft); }

.nav-footer { margin-top: 1.4rem; padding-left: 0.4rem; }
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 40;
}

/* --- Section content ------------------------------------------------------ */
.course-view { padding: 2.4rem 0 4rem; min-height: 70vh; }
.section-kicker {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-deep);
}
.section-kicker .kicker-shape { width: 0.85rem; height: 0.85rem; }
.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0.7rem 0 0;
  outline: none;
}
.section-lead {
  font-size: 1.15rem;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 40em;
  margin-top: 1.2rem;
}
.section-placeholder {
  margin-top: 2.2rem;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
  background: color-mix(in srgb, var(--card) 60%, transparent);
}
.theme-1 .section-title { color: var(--theme-1); }
.theme-2 .section-title { color: var(--theme-2); }
.theme-3 .section-title { color: var(--theme-3); }

.section-pager {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 3rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
}
.pager-link {
  display: inline-flex;
  flex-direction: column;
  gap: 0.2rem;
  text-decoration: none;
  color: var(--ink);
  max-width: 46%;
}
.pager-link.next { text-align: right; }
.pager-link .dir { font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-deep); }
.pager-link .lbl { font-family: var(--font-display); font-size: 0.98rem; }
.pager-link:hover .lbl { text-decoration: underline; }

/* ==========================================================================
   RESPONSIVE — drawer navigation
   ========================================================================== */
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .course-app { grid-template-columns: 1fr; gap: 0; }
  .course-nav {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(80vw, 300px);
    background: var(--card);
    border-right: 1px solid var(--line);
    padding: 1.5rem 1rem;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 50;
  }
  body.nav-open .course-nav { transform: none; }
  body:not(.nav-open) .nav-overlay { display: none; }
}
@media (min-width: 861px) {
  .nav-overlay { display: none; }
}

/* ==========================================================================
   INTERACTION COMPONENTS (js/interactions.js)
   ========================================================================== */
.theme-1 { --c: var(--theme-1); }
.theme-2 { --c: var(--theme-2); }
.theme-3 { --c: var(--theme-3); }

/* --- Feedback panel ------------------------------------------------------- */
.feedback {
  margin-top: 1rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 4px solid var(--ink-soft);
  border-radius: var(--radius);
  padding: 0.9rem 1.1rem;
}
.feedback-label { display: block; font-weight: 700; font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.07em; margin-bottom: 0.3rem; }
.feedback-text { font-size: 0.98rem; line-height: 1.6; }
.feedback-corrective { border-left-color: var(--theme-3); }
.feedback-corrective .feedback-label { color: #1f7a4d; }
.feedback-interpretive { border-left-color: var(--theme-2); }
.feedback-interpretive .feedback-label { color: #b0532f; }
.feedback-reflective { border-left-color: var(--theme-1); }
.feedback-reflective .feedback-label { color: var(--theme-1); }

/* --- Statement card ------------------------------------------------------- */
.statement-card {
  --c: var(--line);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 5px solid var(--c);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
}
.statement-card.theme-1 { --c: var(--theme-1); }
.statement-card.theme-2 { --c: var(--theme-2); }
.statement-card.theme-3 { --c: var(--theme-3); }
.statement-card.selected { border-color: var(--c); box-shadow: 0 0 0 2px var(--c) inset; }
.sc-body { display: flex; gap: 0.8rem; align-items: flex-start; }
.sc-num { display: inline-flex; align-items: center; gap: 0.4rem; flex: none; }
.sc-num .shape { width: 0.9rem; height: 0.9rem; }
.sc-num b { font-family: var(--font-display); font-size: 1.1rem; }
.sc-text { font-family: var(--font-display); font-weight: 550; font-size: 1.15rem; line-height: 1.35; }
.sc-foot { display: flex; justify-content: space-between; align-items: center; gap: 0.6rem; font-size: 0.78rem; color: var(--ink-soft); }
.sc-theme { text-transform: uppercase; letter-spacing: 0.05em; }
.sc-link { text-decoration: none; font-weight: 600; white-space: nowrap; }
.statement-card.selectable { padding-right: 2.8rem; }
.sc-select {
  position: absolute; top: 0.8rem; right: 0.8rem;
  width: 1.8rem; height: 1.8rem; border-radius: 50%;
  border: 1.5px solid var(--line); background: var(--card); cursor: pointer;
}
.sc-select[aria-pressed="true"] { background: var(--c); border-color: var(--c); }
.sc-select[aria-pressed="true"]::after { content: "✓"; color: #fff; display: grid; place-items: center; height: 100%; font-size: 0.9rem; }

/* --- Statement spotlight -------------------------------------------------- */
.spotlight { --c: var(--theme-1); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); border-left: 5px solid var(--c); padding: 1rem 1.2rem 1.1rem; }
.spotlight.theme-1 { --c: var(--theme-1); }
.spotlight.theme-2 { --c: var(--theme-2); }
.spotlight.theme-3 { --c: var(--theme-3); }
.spot-head { display: flex; align-items: baseline; gap: 1rem; }
.spot-num { display: inline-flex; align-items: center; gap: 0.4rem; flex: none; }
.spot-num .shape { width: 0.9rem; height: 0.9rem; }
.spot-num b { font-family: var(--font-display); font-size: 1.1rem; }
.spot-statement { flex: 1; font-family: var(--font-display); font-weight: 550; font-size: 1.15rem; line-height: 1.35; }
.spot-short { margin-top: 0.55rem; line-height: 1.6; color: var(--ink); }
.spot-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.9rem; margin-top: 0.85rem; }
.spot-more { display: inline-flex; align-items: center; gap: 0.4rem; background: none; border: none; padding: 0.2rem 0; cursor: pointer; font: inherit; font-weight: 600; color: var(--accent-deep); }
.spot-caret { color: var(--c); font-weight: 700; font-size: 1.05rem; }
.spot-panel { margin-top: 0.9rem; padding-top: 0.9rem; border-top: 1px solid var(--line); }
.spot-interp { font-size: 1rem; line-height: 1.65; }
.spot-why-h { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); margin-top: 1rem; }
.spot-why { margin-top: 0.25rem; line-height: 1.6; }
.spot-reflect { margin-top: 1rem; background: color-mix(in srgb, var(--c) 8%, transparent); border-radius: 6px; padding: 0.8rem 1rem; }
.spot-reflect-l { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--c); font-weight: 700; }
.spot-reflect p { font-family: var(--font-display); font-size: 1.05rem; margin-top: 0.2rem; }
.spot-link { display: inline-block; margin-top: 1rem; font-weight: 600; text-decoration: none; }

/* --- Keep this statement -------------------------------------------------- */
.keep-btn { display: inline-flex; align-items: center; gap: 0.4rem; background: none; border: 1px solid var(--line); border-radius: 999px; padding: 0.32rem 0.85rem; cursor: pointer; font: inherit; font-size: 0.9rem; color: var(--ink-soft); }
.keep-btn:hover { border-color: var(--c, var(--accent)); color: var(--ink); }
.keep-btn .keep-heart { font-size: 1.05rem; line-height: 1; color: var(--c, var(--accent)); }
.keep-btn.kept { background: color-mix(in srgb, var(--c, var(--accent)) 12%, transparent); border-color: var(--c, var(--accent)); color: var(--ink); font-weight: 600; }
.kept-counter { min-height: 1.2rem; margin-bottom: 0.7rem; font-size: 0.9rem; color: var(--ink-soft); }
.kept-counter:empty { min-height: 0; margin: 0; }

/* --- My Reflections notebook ---------------------------------------------- */
.find-theme-more { margin-top: 1rem; }
.reflections-list { display: grid; gap: 1.1rem; }
.reflection-entry { display: grid; gap: 0.4rem; }
.reflection-label { font-weight: 600; font-size: 0.95rem; }
.reflection-actions { display: flex; justify-content: flex-end; }
.reflections-empty { color: var(--ink-soft); font-style: italic; }
.reflections-foot { display: flex; align-items: center; gap: 0.8rem; margin-top: 1.2rem; }
.reflections-status { font-size: 0.9rem; color: var(--accent-deep); }
.reflections-note { margin-top: 0.8rem; font-size: 0.85rem; color: var(--ink-soft); }

/* --- Where statements pull apart (tension) -------------------------------- */
.tension-pickers { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 0.5rem; }
.tension-field { display: flex; flex-direction: column; gap: 0.3rem; min-width: 0; }
.tension-field-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-soft); font-weight: 700; }
.tension-select { font: inherit; padding: 0.55rem 0.7rem; border: 1px solid var(--line); border-radius: 6px; background: var(--card); color: var(--ink); width: 100%; max-width: 100%; }
.tension-note { margin-top: 0.7rem; font-size: 0.9rem; color: var(--theme-2); }
.tension-note:empty { display: none; }
.tension-pair { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; gap: 0.8rem; margin-top: 1.1rem; }
.tension-card { --c: var(--theme-1); background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: var(--radius); padding: 0.8rem 0.9rem; }
.tension-card.theme-1 { --c: var(--theme-1); } .tension-card.theme-2 { --c: var(--theme-2); } .tension-card.theme-3 { --c: var(--theme-3); }
.tension-side { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--c); font-weight: 700; }
.tension-mark { display: inline-flex; align-items: center; gap: 0.35rem; margin: 0.25rem 0; }
.tension-mark .shape { width: 0.85rem; height: 0.85rem; }
.tension-mark b { font-family: var(--font-display); }
.tension-statement { font-family: var(--font-display); font-size: 1.02rem; line-height: 1.35; }
.tension-arrow { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.3rem; }
.tension-word { font-size: 0.82rem; color: var(--ink-soft); white-space: nowrap; }
.tension-prio-prompt, .tension-change { margin-top: 1.1rem; }
.tension-prio-prompt { font-family: var(--font-display); font-size: 1.05rem; }
@media (max-width: 620px) {
  .tension-pickers { grid-template-columns: 1fr; }
  .tension-pair { grid-template-columns: 1fr; }
  .tension-arrow { flex-direction: row; }
}

/* --- Selection cards ------------------------------------------------------ */
.selection-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 0.8rem; }
.selection-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.select-card { --c: var(--accent); display: flex; flex-direction: column; gap: 0.35rem; text-align: left; background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; cursor: pointer; font: inherit; transition: border-color 0.15s ease, transform 0.15s ease; }
.select-card.theme-1 { --c: var(--theme-1); }
.select-card.theme-2 { --c: var(--theme-2); }
.select-card.theme-3 { --c: var(--theme-3); }
.select-card:hover { transform: translateY(-2px); }
.select-card[aria-pressed="true"] { border-color: var(--c); box-shadow: 0 0 0 1px var(--c) inset; background: color-mix(in srgb, var(--c) 6%, var(--card)); }
.select-shape .shape { width: 1rem; height: 1rem; }
.select-label { font-weight: 600; }
.select-desc { font-size: 0.88rem; color: var(--ink-soft); }

/* --- Multiple choice ------------------------------------------------------ */
.mcq-prompt { font-family: var(--font-display); font-size: 1.25rem; line-height: 1.4; margin-bottom: 1rem; }
.mcq-options { display: grid; gap: 0.6rem; }
.mcq-option { display: flex; align-items: center; gap: 0.7rem; text-align: left; background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 0.8rem 1rem; cursor: pointer; font: inherit; font-size: 1rem; }
.mcq-option:hover { border-color: var(--accent); }
.mcq-key { flex: none; width: 1.7rem; height: 1.7rem; border-radius: 50%; display: grid; place-items: center; background: var(--paper); font-weight: 700; font-size: 0.85rem; }
.mcq-option.chosen { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.mcq-option[data-state="correct"] { border-color: var(--theme-3); }
.mcq-option[data-state="correct"] .mcq-key { background: var(--theme-3); color: #fff; }
.mcq-option[data-state="incorrect"] { border-color: #c0563a; }
.mcq-option[data-state="incorrect"] .mcq-key { background: #c0563a; color: #fff; }

/* --- Knowledge check ------------------------------------------------------ */
.kcheck { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem; }
.kcheck-counter { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); margin-bottom: 0.8rem; }
.kcheck-nav { margin-top: 1.1rem; }
.kcheck-done { font-size: 1rem; line-height: 1.6; }

/* --- Reflection prompt ---------------------------------------------------- */
.reflect { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.2rem; }
.reflect-label { font-weight: 600; display: block; margin-bottom: 0.4rem; }
.reflect-prompt { font-family: var(--font-display); font-size: 1.1rem; margin-bottom: 0.6rem; }
.reflect-ta { width: 100%; min-height: 5.5rem; font: inherit; padding: 0.7rem 0.8rem; border: 1px solid var(--line); border-radius: 6px; resize: vertical; }
.reflect-ta:focus { border-color: var(--accent); outline: none; }
.reflect-note { font-size: 0.8rem; color: var(--ink-soft); margin-top: 0.4rem; }
.reflect-status { color: #1f7a4d; font-weight: 600; }

/* --- Slider --------------------------------------------------------------- */
.slider-block { margin: 1rem 0; }
.c-slider { width: 100%; accent-color: var(--accent); height: 1.6rem; }
.slider-labels { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.85rem; color: var(--ink-soft); margin-top: 0.4rem; }
.slider-labels .s-mid { text-align: center; flex: 1; }
.slider-labels .s-left { text-align: left; }
.slider-labels .s-right { text-align: right; }

/* --- Accordion ------------------------------------------------------------ */
.accordion { display: grid; gap: 0.5rem; }
.acc-item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); overflow: hidden; }
.acc-head { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 1rem; background: none; border: none; padding: 0.9rem 1.1rem; font: inherit; font-weight: 600; cursor: pointer; text-align: left; }
.acc-caret { color: var(--accent); font-weight: 700; }
.acc-panel { padding: 0 1.1rem 1.1rem; }

/* --- Modal ---------------------------------------------------------------- */
.c-modal-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4); display: grid; place-items: center; padding: 1.5rem; z-index: 120; }
.c-modal-dialog { background: var(--card); border-radius: var(--radius); max-width: 36rem; width: 100%; max-height: 85vh; overflow: auto; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25); }
.c-modal-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1.1rem 1.3rem; border-bottom: 1px solid var(--line); }
.c-modal-title { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; }
.c-modal-close { background: none; border: none; font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--ink-soft); }
.c-modal-body { padding: 1.3rem; }

/* --- Toast ---------------------------------------------------------------- */
.toast-host { position: fixed; left: 50%; bottom: 1.5rem; transform: translateX(-50%); z-index: 200; display: grid; gap: 0.5rem; }
.toast { background: var(--ink); color: #fff; padding: 0.7rem 1.1rem; border-radius: 6px; font-size: 0.9rem; opacity: 0; transform: translateY(8px); transition: opacity 0.3s ease, transform 0.3s ease; }
.toast.show { opacity: 1; transform: none; }

/* --- Tooltip -------------------------------------------------------------- */
.tooltip-wrap { position: relative; display: inline-block; }
.c-tooltip { position: absolute; bottom: calc(100% + 0.4rem); left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 0.35rem 0.6rem; border-radius: 4px; font-size: 0.8rem; white-space: nowrap; z-index: 130; }

/* ==========================================================================
   SECTION CONTENT (activities within sections)
   ========================================================================== */
.section-head { margin-bottom: 2rem; }
.activity { margin-top: 2.8rem; }
.activity-title { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.4rem, 3vw, 1.9rem); line-height: 1.2; }
.activity-intro { color: var(--ink-soft); max-width: 42em; margin: 0.5rem 0 1.2rem; }
.reveal { margin-top: 0.9rem; font-weight: 600; color: var(--accent-deep); }

/* Theme triptych */
.theme-triptych { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 2rem; }
.theme-intro-card { --c: var(--theme-1); display: flex; flex-direction: column; gap: 0.6rem; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--c); border-radius: var(--radius); padding: 1.2rem 1.2rem 1.4rem; transition: transform 0.15s ease; }
.theme-intro-card.theme-1 { --c: var(--theme-1); }
.theme-intro-card.theme-2 { --c: var(--theme-2); }
.theme-intro-card.theme-3 { --c: var(--theme-3); }
.theme-intro-card:hover { transform: translateY(-3px); }
.ti-shape .shape { width: 1.4rem; height: 1.4rem; }
.ti-name { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; color: var(--c); }
.ti-q { color: var(--ink-soft); font-size: 0.95rem; line-height: 1.5; }
@media (max-width: 720px) { .theme-triptych { grid-template-columns: 1fr; } }

/* Explore the landscape */
.explore-toolbar { display: flex; flex-wrap: wrap; gap: 0.8rem 1rem; align-items: center; justify-content: space-between; margin-bottom: 0.9rem; }
.explore-filters { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.filter-chip { --c: var(--accent); display: inline-flex; align-items: center; gap: 0.4rem; font: inherit; font-size: 0.85rem; font-weight: 600; padding: 0.35rem 0.8rem; border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; cursor: pointer; }
.filter-chip.theme-1 { --c: var(--theme-1); }
.filter-chip.theme-2 { --c: var(--theme-2); }
.filter-chip.theme-3 { --c: var(--theme-3); }
.filter-chip .chip-shape .shape { width: 0.75rem; height: 0.75rem; }
.filter-chip[aria-pressed="true"] { border-color: var(--c); background: color-mix(in srgb, var(--c) 10%, var(--card)); color: var(--c); }
.explore-search { font: inherit; padding: 0.5rem 0.85rem; border: 1.5px solid var(--line); border-radius: 999px; min-width: 12rem; background: var(--card); }
.explore-search:focus { border-color: var(--accent); outline: none; }
.explore-counter { font-family: var(--font-display); font-size: 1.05rem; color: var(--ink-soft); margin-bottom: 1rem; }
.explore-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.explore-grid .empty { color: var(--ink-soft); font-style: italic; grid-column: 1 / -1; }

/* Your Practice */
.practice-seed { margin-bottom: 0.9rem; }
.explore-counter.full { color: var(--accent-deep); font-weight: 600; }
.anchor-host { margin-top: 0.4rem; }
.anchor-host .empty { color: var(--ink-soft); font-style: italic; }
.anchor-host .select-label { font-family: var(--font-display); font-size: 1.05rem; line-height: 1.35; }
.practice-closing { margin-top: 1.6rem; padding-top: 1.3rem; border-top: 1px solid var(--line); }
.choose-line { font-family: var(--font-display); font-size: 1.05rem; margin: 0.1rem 0; }
.browse-toggle { margin-top: 1rem; }
.choose-root .recap-label { margin-top: 1.1rem; }
.ssc-grid { display: grid; gap: 1rem; }
.ssc-field { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.9rem 1rem; }
.ssc-label { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-deep); font-weight: 700; margin-bottom: 0.4rem; }
.ssc-field .reflect-label { font-family: var(--font-display); font-size: 1.02rem; }

/* Spotlights, cards, scenario conclusion */
.spotlight-stack { display: grid; gap: 0.7rem; }
.card-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; margin-top: 1rem; }
.reveal-block { margin-top: 1.3rem; }
.scenario-conclusion { font-family: var(--font-display); font-size: 1.15rem; line-height: 1.5; }

/* Sorter */
.sorter { display: grid; gap: 0.8rem; }
.sort-item { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: var(--radius); padding: 0.9rem 1.1rem; }
.sort-item[data-state="right"] { border-left-color: var(--theme-3); }
.sort-item[data-state="rethink"] { border-left-color: var(--theme-2); }
.sort-item[data-state="answered"] { border-left-color: var(--accent); }
.sort-label { font-weight: 600; margin-bottom: 0.5rem; }
.sort-buckets { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.sort-btn { font: inherit; font-size: 0.9rem; font-weight: 600; padding: 0.4rem 0.9rem; border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; cursor: pointer; }
.sort-btn[aria-pressed="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--card)); color: var(--accent); }
.sort-fb { margin-top: 0.5rem; font-size: 0.9rem; color: var(--ink-soft); }
.sort-fb.right { color: #1f7a4d; }
.sort-fb.rethink { color: #b0532f; }

/* Opening question list */
.question-list { margin: 1rem 0 0 1.1rem; display: grid; gap: 0.4rem; }
.question-list li { font-family: var(--font-display); font-size: 1.05rem; line-height: 1.4; }

/* Allocator */
.allocator { display: grid; gap: 0.6rem; }
.alloc-row { display: grid; grid-template-columns: 12rem 1fr auto auto; gap: 0.9rem; align-items: center; }
.alloc-label { font-weight: 600; font-size: 0.95rem; }
.alloc-bar { height: 0.5rem; background: var(--paper); border-radius: 999px; overflow: hidden; }
.alloc-bar-fill { display: block; height: 100%; background: var(--accent); width: 0; transition: width 0.12s ease; }
.alloc-val { font-variant-numeric: tabular-nums; font-weight: 700; min-width: 3rem; text-align: right; }
.alloc-ctrls { display: flex; gap: 0.3rem; }
.alloc-btn { width: 2rem; height: 2rem; border: 1.5px solid var(--line); background: var(--card); border-radius: 6px; font-size: 1.1rem; line-height: 1; cursor: pointer; }
.alloc-btn:hover { border-color: var(--accent); }
.alloc-btn:disabled { opacity: 0.4; cursor: default; }
.alloc-total { margin-top: 0.4rem; color: var(--ink-soft); font-size: 0.9rem; }
.alloc-total.balanced { color: #1f7a4d; font-weight: 600; }
@media (max-width: 620px) {
  .alloc-row { grid-template-columns: 1fr auto auto; }
  .alloc-bar { grid-column: 1 / -1; order: 5; }
}

/* What must remain human — concept chips */
.concept-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin-bottom: 0.6rem; }
.concept-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.concept-chip {
  background: color-mix(in srgb, var(--theme-3) 8%, var(--card));
  border: 1px solid color-mix(in srgb, var(--theme-3) 30%, var(--line));
  color: var(--accent-deep);
  border-radius: 999px;
  padding: 0.3rem 0.85rem;
  font-size: 0.92rem;
}
@media (prefers-reduced-motion: no-preference) {
  .concept-reveal .concept-chip { animation: chip-in 0.4s ease both; }
  .concept-reveal .concept-chip:nth-child(n) { animation-delay: calc(0.03s * var(--i, 0)); }
}
@keyframes chip-in { from { transform: translateY(6px); } to { transform: none; } }

/* Constraint challenge */
.constraint-list { margin: 1rem 0 1.4rem 0; display: grid; gap: 0.45rem; list-style: none; }
.constraint-list li { position: relative; padding-left: 1.5rem; color: var(--ink-soft); }
.constraint-list li::before { content: "▸"; position: absolute; left: 0; color: var(--theme-3); }

/* ==========================================================================
   PRINT (expanded in a later phase for the Action Plan)
   ========================================================================== */
/* --- Manifesto in Action (dilemmas) --------------------------------------- */
.standalone-intro { max-width: 60ch; }
.dilemma { border-top: 1px solid var(--line); padding-top: 1.4rem; }
.dilemma-kicker { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin: 0 0 0.5rem; }
.dilemma-scenario { font-family: var(--font-display); font-size: 1.2rem; line-height: 1.5; margin-bottom: 1.1rem; }
.play-block { margin-top: 1.2rem; }
.play-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin: 0 0 0.5rem; }
.play-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.play-chip { --c: var(--line); display: inline-flex; align-items: center; gap: 0.4rem; max-width: 100%; padding: 0.35rem 0.7rem; border: 1px solid var(--line); border-left: 3px solid var(--c); border-radius: 999px; background: var(--card); text-decoration: none; color: inherit; font-size: 0.85rem; }
.play-chip:hover { background: color-mix(in srgb, var(--c) 8%, var(--card)); }
.play-chip.theme-1 { --c: var(--theme-1); }
.play-chip.theme-2 { --c: var(--theme-2); }
.play-chip.theme-3 { --c: var(--theme-3); }
.play-mark .shape { width: 0.75rem; height: 0.75rem; }
.play-num { font-family: var(--font-display); font-weight: 700; }
.play-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 22ch; }
.action-closing { margin-top: 1.6rem; padding-top: 1.3rem; border-top: 1px solid var(--line); }

/* --- Branching scenarios -------------------------------------------------- */
.scenario-counter { margin: 0.4rem 0 1rem; }
.scenario-list { display: grid; gap: 1.2rem; }
.scenario-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem 1.3rem; }
.scenario-card-head { display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap; margin-bottom: 0.5rem; }
.scenario-title { font-family: var(--font-display); font-size: 1.25rem; }
.scenario-badge { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 700; color: var(--accent-deep); background: color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 999px; padding: 0.2rem 0.6rem; }
.scenario-situation { font-family: var(--font-display); font-size: 1.1rem; line-height: 1.5; margin-bottom: 1rem; }
.scenario-interest { font-size: 0.92rem; color: var(--ink-soft); background: color-mix(in srgb, var(--accent) 7%, transparent); border-left: 3px solid var(--accent); border-radius: 4px; padding: 0.6rem 0.8rem; margin-bottom: 1rem; }
.scenario-flow { display: grid; gap: 1.1rem; }
.scenario-stage { border-top: 1px solid var(--line); padding-top: 1rem; }
.scenario-decision { font-weight: 600; margin-bottom: 0.7rem; }
.scenario-options { display: grid; gap: 0.5rem; }
.scenario-option { display: flex; gap: 0.7rem; align-items: baseline; text-align: left; width: 100%; background: var(--card); border: 1px solid var(--line); border-radius: 6px; padding: 0.7rem 0.9rem; cursor: pointer; font: inherit; }
.scenario-option:hover:not(:disabled) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 5%, var(--card)); }
.scenario-option:disabled { cursor: default; opacity: 0.55; }
.scenario-option.chosen { opacity: 1; border-color: var(--accent); border-left: 4px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--card)); font-weight: 600; }
.scenario-opt-key { flex: none; font-family: var(--font-display); font-weight: 700; color: var(--accent-deep); }
.scenario-consequence { margin-top: 0.9rem; }
.scenario-consequence:focus { outline: none; }
.scenario-consequence-text { line-height: 1.6; background: var(--paper); border-radius: 6px; padding: 0.8rem 1rem; }
.scenario-continue { margin-top: 0.9rem; }
.scenario-end { margin-top: 1rem; border-top: 2px solid var(--accent); padding-top: 1rem; }
.scenario-end-title { font-family: var(--font-display); font-size: 1.15rem; font-weight: 600; margin-bottom: 0.8rem; }
.scenario-sum-block { margin-bottom: 0.9rem; }
.scenario-sum-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin-bottom: 0.35rem; }
.scenario-principles { margin: 0; padding-left: 1.1rem; }
.scenario-principles li { margin: 0.1rem 0; }
.scenario-protected, .scenario-atrisk { line-height: 1.55; }
.scenario-reflection { font-family: var(--font-display); font-size: 1.08rem; line-height: 1.5; margin-top: 1rem; background: color-mix(in srgb, var(--accent) 7%, transparent); border-radius: 6px; padding: 0.9rem 1.1rem; }
.scenario-restart { margin-top: 1rem; }

/* --- Connecting the Manifesto (threads) ----------------------------------- */
.thread-links { display: grid; gap: 0.9rem; }
.thread-link { --c: var(--line); display: flex; gap: 0.8rem; align-items: flex-start; border-left: 4px solid var(--c); padding: 0.2rem 0 0.2rem 0.9rem; }
.thread-link.theme-1 { --c: var(--theme-1); }
.thread-link.theme-2 { --c: var(--theme-2); }
.thread-link.theme-3 { --c: var(--theme-3); }
.thread-mark { display: inline-flex; align-items: center; gap: 0.35rem; flex: none; margin-top: 0.15rem; }
.thread-mark .shape { width: 0.85rem; height: 0.85rem; }
.thread-mark b { font-family: var(--font-display); font-size: 1rem; }
.thread-statement { font-family: var(--font-display); font-weight: 550; font-size: 1.05rem; line-height: 1.35; }
.thread-statement a { text-decoration: none; }
.thread-statement a:hover { text-decoration: underline; }
.thread-theme { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-soft); margin-top: 0.15rem; }
.thread-note { margin-top: 0.35rem; line-height: 1.55; }

/* --- The Conversation Continues (recap / takeaway / coda) ----------------- */
.sentiment-move { line-height: 1.6; }
.recap { display: grid; gap: 1.6rem; }
.recap-block { display: grid; gap: 0.6rem; }
.recap-label { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin: 0; }
.recap-anchor .statement-card { box-shadow: 0 0 0 2px var(--c) inset; }
.recap-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 0.9rem; }
.recap-quote { margin: 0; padding: 0.7rem 1rem; border-left: 3px solid var(--accent); background: color-mix(in srgb, var(--accent) 5%, var(--card)); border-radius: 0 6px 6px 0; font-family: var(--font-display); font-size: 1.05rem; line-height: 1.5; }
.recap-empty { color: var(--ink-soft); font-style: italic; }
.recap-empty a { font-style: normal; font-weight: 600; white-space: nowrap; }
.recap-notebook { display: grid; gap: 1rem; }
.notebook-entry { display: grid; gap: 0.4rem; }
.notebook-q { margin: 0; font-weight: 600; font-size: 0.95rem; }
.recap-value { line-height: 1.55; }
.sentiment-start { font-size: 0.9rem; color: var(--ink-soft); }
.takeaway-actions { margin-top: 0.4rem; display: flex; flex-wrap: wrap; gap: 0.6rem; }
.takeaway-status { display: inline-block; margin-top: 0.5rem; font-size: 0.9rem; color: var(--accent-deep); min-height: 1.1rem; }
.takeaway-hint { margin-top: 0.6rem; font-size: 0.85rem; color: var(--ink-soft); }
.activity-subtitle { font-family: var(--font-display); font-size: 1.15rem; margin-bottom: 0.6rem; }
.final-thinking { margin-top: 1.1rem; }

/* --- Statement 31 --------------------------------------------------------- */
.statement31 { border-top: 2px solid var(--accent); }
.s31-unwritten { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; }
.s31-copy { font-family: var(--font-display); font-size: 1.1rem; line-height: 1.5; margin: 0.2rem 0; }
.s31-guidance { font-size: 0.85rem; color: var(--ink-soft); margin-top: 0.4rem; }
.s31-note { font-family: var(--font-display); font-size: 1.1rem; margin-top: 0.8rem; color: var(--accent-deep); }

/* --- Action Plan (exportable summary) ------------------------------------- */
.action-plan { margin-top: 1.4rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem 1.4rem; }
.ap-title { font-family: var(--font-display); font-size: 1.4rem; margin-bottom: 1rem; }
.ap-block { margin-bottom: 1rem; }
.ap-label { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 700; margin-bottom: 0.3rem; }
.ap-value { line-height: 1.55; }
.ap-list { margin: 0; padding-left: 1.2rem; }
.ap-list li { margin: 0.15rem 0; line-height: 1.45; }
.ap-footer { margin-top: 1.2rem; padding-top: 0.9rem; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--ink-soft); }
.ap-footer p { margin: 0.1rem 0; }

.course-coda { margin-top: 1.4rem; padding-top: 1.6rem; border-top: 1px solid var(--line); text-align: center; }
.course-coda .coda-line { font-size: 1.5rem; }
.course-coda .c-btn { margin-top: 0.6rem; }

@media print {
  /* Print only the Action Plan — hide chrome and every interactive block. */
  .course-header, .course-nav, .nav-overlay, .progress-rail, .section-pager,
  .section-placeholder, .nav-toggle,
  .section-head, .activity { display: none !important; }
  .course-app { display: block; }
  body { background: #fff; }
  .action-plan { display: block !important; border: none; padding: 0; margin: 0; }
  .action-plan, .ap-block { break-inside: avoid; }
}
