/* =====================================================================
   GOTHAM FELLOWSHIP WORKSHEETS · shared look
   This first part (down to "END OF SHARED LOOK") is the same in every
   worksheet app (the Calling Exercise, the Self-Counseling Project), so
   they read as one family. If you change something here, make the same
   change in the other app's styles.css.

   Type sizes: only the six below are used. Colours: navy for the frame,
   one accent (a deep orange drawn from the Gotham logo), and the
   movement colours each worksheet defines further down.
   ===================================================================== */
:root {
  color-scheme: light;
  --navy: #1d2b45;
  --navy-dark: #141f33;
  --ink: #1f2a33;
  --muted: #56636e;
  --line: #d9dfe4;
  --field: #8a96a0;      /* borders of things you type in or tick */
  --paper: #ffffff;
  --bg: #f4f2ee;
  --cream: #f4f1ea;
  --cream-line: #ddd5c2;
  --green: #3f7550;
  --green-bg: #eef3ee;
  --red: #a3442e;
  --red-bg: #f7eeeb;
  --danger: #9b2c3c;
  --gold: #96560a;       /* the accent: dark enough to read as text and to carry white text */
  --logo: #f5871f;       /* the Gotham logo orange: decoration only, never text */
  --focus: #2f6da0;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --radius: 10px;
  --fs-1: 14px;          /* small print, labels */
  --fs-2: 16px;          /* supporting text, buttons */
  --fs-3: 18px;          /* reading text */
  --fs-4: 22px;          /* sub-headings */
  --fs-5: 28px;          /* page titles */
  --fs-6: 36px;          /* the welcome title */
}
@media (min-width: 900px) { :root { --fs-3: 19px; } }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: var(--fs-3);
  line-height: 1.6;
}
a { color: var(--navy); }
.sc { font-variant: small-caps; letter-spacing: 0.03em; }
.nb { white-space: nowrap; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; top: 0; z-index: 100; background: #fff; color: var(--navy); font: 600 var(--fs-2) var(--sans); padding: 10px 14px; border-radius: 0 0 8px 0; }
.skip:focus { left: 0; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 8px 20px; min-height: 46px;
  background: var(--navy); color: #fff;
  font-family: var(--sans); font-size: var(--fs-1); white-space: nowrap;
}
.brand { display: inline-flex; align-items: center; gap: 8px; min-width: 0; color: #fff; text-decoration: none; font-weight: 600; letter-spacing: 0.01em; }
.brand a, a.brand { display: inline-flex; align-items: center; gap: 8px; min-width: 0; color: inherit; text-decoration: none; }
.brand .brand-app { font-weight: 400; opacity: 0.85; }
.brand-mark { width: 26px; height: 26px; flex: none; }
.topbar-right { display: flex; align-items: center; gap: 18px; flex: none; }
.who { opacity: 0.9; }
.signout { color: #fff; }
.save-status { opacity: 0.95; }
.save-status.error { color: #ffd2d2; opacity: 1; }
.fb-launch {
  all: unset; box-sizing: border-box; cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
  color: #fff; font: inherit; padding: 6px 0;
}
.fb-launch:hover span { text-decoration: underline; }
.topbar a:focus-visible, .fb-launch:focus-visible { outline: 2px solid #fff; outline-offset: 3px; border-radius: 3px; }
@media (max-width: 640px) {
  .brand .brand-app, .who, .fb-launch span { display: none; }
  /* If space runs out (a leader's extra link, a narrow phone), the name shortens instead of overlapping. */
  .brand { flex: 1 1 auto; }
  .brand a, a.brand { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .brand-mark { display: inline-block; vertical-align: middle; margin-right: 8px; }
  .topbar { padding: 6px 14px; }
  .topbar-right { gap: 16px; }
  .signout, .fb-launch { padding: 8px 0; }
}

/* ---------- Layout ---------- */
.app { max-width: 760px; margin: 0 auto; padding: 24px 16px 80px; outline: none; }
.app.wide { max-width: 1100px; }
.card {
  background: var(--paper);
  border-radius: var(--radius);
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 6px 24px rgba(0,0,0,0.04);
  padding: 36px 40px;
  animation: stepIn 0.35s ease-out;
}
@keyframes stepIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (max-width: 640px) { .card { padding: 24px 18px; } }
.loading { font-family: var(--sans); font-size: var(--fs-2); color: var(--muted); text-align: center; padding: 60px 0; }

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; color: var(--navy); line-height: 1.25; }
h1 { font-size: var(--fs-6); margin: 0 0 6px; letter-spacing: -0.01em; }
h2 { font-size: var(--fs-5); margin: 0 0 14px; letter-spacing: -0.01em; }
h3 { font-size: var(--fs-4); margin: 24px 0 8px; }
@media (max-width: 640px) { h1 { font-size: var(--fs-5); } }
h2.step-title { margin-bottom: 6px; }
.step-title + .lead { font-family: var(--serif); font-style: italic; }
.lead { color: var(--muted); font-size: var(--fs-3); margin: 0 0 22px; }
p { margin: 0 0 16px; }
.muted { color: var(--muted); }
.small { font-size: var(--fs-2); }
.block { margin: 32px 0 10px; }
/* Small headings above a group of things ("What to expect", "Worksheet 1"). */
.block-h { font-family: var(--sans); font-size: var(--fs-2); font-weight: 700; color: var(--t, var(--navy)); margin: 0 0 12px; }
.eyebrow-line { font-family: var(--sans); font-size: var(--fs-1); font-weight: 700; color: var(--gold); margin-bottom: 4px; }

/* ---------- Buttons & forms ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px;
  font-family: var(--sans); font-size: var(--fs-2); font-weight: 600;
  padding: 10px 20px; border-radius: 8px; border: 1px solid var(--navy);
  background: var(--navy); color: #fff; cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--navy-dark); }
.btn.secondary { background: #fff; color: var(--navy); }
.btn.secondary:hover { background: #eef2f5; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--navy); padding: 8px 10px; }
.btn.ghost:hover { background: #eef2f5; }
.btn.danger { background: #fff; color: var(--danger); border-color: #e3c4c9; }
.btn[disabled] { opacity: 0.5; cursor: default; }
.small-btn { min-height: 36px; padding: 6px 12px; font-size: var(--fs-1); }
.btn:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 3px solid var(--focus); outline-offset: 2px;
}
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 14px; }

/* Labels and hints are in the sans face; what you write is in the serif face. */
.field { margin: 0 0 22px; }
.field > label, .field .label { display: block; font-family: var(--sans); font-weight: 600; font-size: var(--fs-2); margin-bottom: 6px; color: var(--ink); }
.field .letter { font-family: var(--sans); font-weight: 700; color: var(--navy); margin-right: 6px; }
.field .hint { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); margin: -2px 0 8px; }
.optional-tag { font-family: var(--sans); font-size: var(--fs-1); font-weight: 400; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 6px; margin-left: 6px; }
input[type="text"], input[type="date"], input[type="email"], input[type="password"], textarea, select.big-select {
  width: 100%;
  font-family: var(--serif); font-size: var(--fs-3); line-height: 1.5; color: var(--ink);
  background: #fff; border: 1px solid var(--field); border-radius: 8px;
  padding: 10px 12px;
}
textarea { resize: vertical; min-height: 110px; display: block; }
input:focus, textarea:focus { border-color: var(--focus); }
::placeholder { color: #6b7883; opacity: 1; }
.checks { display: grid; gap: 10px; margin: 6px 0 18px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-3); cursor: pointer; }
.check input { width: 22px; height: 22px; margin-top: 4px; accent-color: var(--navy); flex: none; }
.notice { font-family: var(--sans); font-size: var(--fs-1); border-radius: 8px; padding: 12px 14px; margin: 0 0 16px; }
.notice.ok { background: var(--green-bg); color: #2f5a3a; }
.notice.warn { background: #fff6e5; color: #6b4d12; }
.notice.err { background: #fbeaea; color: #7a2323; }

/* ---------- List of worksheets (inside each app) ---------- */
.home-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.ws-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.ws-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; background: #fff;
}
.ws-title { font-family: var(--sans); font-weight: 600; font-size: var(--fs-3); color: var(--ink); margin: 0 0 2px; }
.ws-meta { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); }
.ws-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.badge { display: inline-block; font-family: var(--sans); font-size: var(--fs-1); font-weight: 600; border-radius: 4px; padding: 1px 8px; margin-left: 10px; vertical-align: 1px; }
.badge.done { background: var(--green-bg); color: #2f5a3a; }
.badge.progress { background: #eef2f5; color: var(--navy); }
.badge.new { background: #fbefe0; color: #7a4a08; }
.badge.cohort { background: #fdf0e1; color: #7a4a08; }
.empty { text-align: center; padding: 30px 10px; color: var(--muted); }

/* ---------- Where you are: one labelled strip ---------- */
nav.progress { margin: 0 0 14px; font-family: var(--sans); }
.progress-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: var(--fs-1); color: var(--muted); margin-bottom: 6px; }
.progress-top strong { color: var(--navy); font-weight: 600; }
.strip { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; }
.strip li { flex: 1 1 auto; min-width: 0; }
.seg {
  all: unset; box-sizing: border-box; display: block; width: 100%; min-height: 44px; cursor: pointer; text-align: center;
  font: 600 var(--fs-1)/1.2 var(--sans); color: var(--muted); white-space: nowrap;
}
.seg::before {
  content: ""; display: block; height: 5px; border-radius: 3px; margin-bottom: 7px;
  background: linear-gradient(90deg, var(--c, var(--navy)) var(--fill, 0%), #c5cdd4 var(--fill, 0%));
}
.seg.done { color: var(--ink); --c: #6f7d89; --fill: 100%; }
.seg.current { color: var(--c, var(--navy)); font-weight: 700; }
.seg:hover { text-decoration: underline; }
.seg:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
@media (max-width: 400px) { .strip { gap: 4px; } .seg { letter-spacing: -0.01em; } }

/* A time label. Tap it to start a quiet countdown; tap again to stop. */
.pill {
  all: unset; box-sizing: border-box; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; cursor: pointer;
  font: 600 var(--fs-1)/1 var(--sans); padding: 7px 12px; border-radius: 999px; border: 1.5px solid currentColor; color: var(--navy);
}
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid currentColor; }
.pill.running::before { background: currentColor; }
.pill.over { background: var(--cream); }
.pill:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.section-band .pill { color: #fff; border-color: rgba(255,255,255,0.75); }
.section-band .pill.over { background: rgba(255,255,255,0.18); }
.section-band .pill:focus-visible { outline-color: #fff; }

/* ---------- Coloured band across the top of a section ---------- */
.section-band {
  display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap;
  margin: -36px -40px 26px; padding: 14px 40px;
  background: linear-gradient(90deg, var(--t, var(--c, var(--navy))), color-mix(in srgb, var(--t, var(--c, var(--navy))) 82%, #000));
  color: #fff; border-radius: var(--radius) var(--radius) 0 0; font-family: var(--sans);
}
.sb-title { font-size: var(--fs-1); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
@media (max-width: 640px) { .section-band { margin: -24px -18px 20px; padding: 12px 18px; } }

/* ---------- Step nav ---------- */
.step-nav { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 26px; }
.step-nav .right { display: flex; gap: 10px; margin-left: auto; }

/* ---------- Things you wrote earlier, shown again where a question needs them ---------- */
.recall { font-family: var(--sans); font-size: var(--fs-1); margin: 0 0 14px; border: 1px solid var(--line); border-radius: 8px; background: #fbfaf7; }
.recall summary { cursor: pointer; padding: 10px 14px; font-weight: 600; color: var(--navy); }
.recall-body { padding: 0 14px 6px; }
.recall-body h4 { font: 600 var(--fs-1) var(--sans); color: var(--muted); margin: 8px 0 2px; }
.recall-body p { font-family: var(--serif); font-size: var(--fs-2); white-space: pre-wrap; margin: 0 0 10px; }
.recall-body .none { color: var(--muted); font-style: italic; }

/* ---------- Review ---------- */
.review-section { border-top: 1px solid var(--line); padding: 18px 0 6px; }
.review-section h3 { margin: 0 0 10px; display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.review-section h3 a { font: 600 var(--fs-2) var(--sans); padding: 4px 0; }
.review-q { font-size: var(--fs-2); color: var(--muted); margin: 0 0 4px; }
.review-a { white-space: pre-wrap; margin: 0 0 14px; padding-left: 12px; border-left: 3px solid #cfd9e0; }
.review-a.empty-a { color: var(--muted); font-style: italic; border-left-color: #e3e7ea; }
.review-a.empty-a a { font-family: var(--sans); font-style: normal; font-size: var(--fs-1); margin-left: 8px; }
.finish-box { background: #fbfaf7; border: 1px solid var(--navy); border-radius: var(--radius); padding: 20px; margin: 0 0 24px; }
.finish-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.finish-text p { margin: 0; font-size: var(--fs-2); }
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: var(--fs-2); }
.checklist li { display: grid; grid-template-columns: 24px 1fr; gap: 10px; align-items: start; }
.cl-box { width: 22px; height: 22px; border: 1.5px solid var(--navy); border-radius: 4px; font: 700 var(--fs-1)/20px var(--sans); text-align: center; margin-top: 2px; }
.checklist li.ok .cl-box { background: var(--green); border-color: var(--green); color: #fff; }
.cl-miss { display: block; font: var(--fs-1)/1.5 var(--sans); color: var(--red); margin-top: 2px; }
.cl-miss a { color: var(--red); }
.checklist a { font-family: var(--sans); font-size: var(--fs-1); }
.miss-list { margin: 8px 0 0; padding-left: 20px; font-size: var(--fs-2); }

/* ---------- Modal ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(20,30,40,0.45); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 50; }
.modal { background: #fff; border-radius: 12px; max-width: 520px; width: 100%; max-height: calc(100vh - 32px); overflow: auto; padding: 26px; box-shadow: 0 20px 50px rgba(0,0,0,0.25); }
.modal.wide { max-width: 760px; }
.modal h2 { font-size: var(--fs-4); }
.modal .actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.copy-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-family: var(--sans); font-size: var(--fs-2); }
.copy-row code { background: #f1f3f5; padding: 4px 8px; border-radius: 5px; }

/* ---------- Scripture references and the passage pop-up ---------- */
/* Inside a sentence a reference looks like the sentence; in a list of readings it uses the sans face. */
.ref { all: unset; cursor: pointer; font: inherit; color: var(--c, var(--navy)); border-bottom: 1.5px dotted currentColor; line-height: 1.3; }
.ref:hover, .ref[aria-expanded="true"] { border-bottom-style: solid; }
.ref:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
.read { font-family: var(--sans); font-size: var(--fs-2); margin: -2px 0 26px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; }
.read b { font-size: var(--fs-1); color: var(--muted); margin-right: 8px; }
.read .ref { font-weight: 500; }
.sep { color: var(--muted); margin: 0 6px; }
.passage {
  position: absolute; z-index: 60; width: min(440px, calc(100vw - 32px)); max-height: min(70vh, 520px);
  display: flex; flex-direction: column;
  background: #fff; border-radius: 14px; box-shadow: 0 18px 50px rgba(20, 35, 48, 0.28), 0 0 0 1px rgba(0,0,0,0.05);
  animation: stepIn 0.18s ease-out;
}
.passage-head { display: flex; align-items: center; gap: 8px; padding: 14px 16px 10px; border-bottom: 1px solid var(--line); font-family: var(--sans); }
.passage-ref { font-weight: 700; color: var(--navy); font-size: var(--fs-2); }
.passage-ver { font-size: var(--fs-1); color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 5px; }
.passage-close { all: unset; cursor: pointer; margin-left: auto; width: 36px; height: 36px; border-radius: 50%; text-align: center; line-height: 36px; color: var(--muted); }
.passage-close:hover { background: #f1f3f5; }
.passage-close:focus-visible { outline: 2px solid var(--focus); }
.passage-body { padding: 14px 18px; overflow: auto; }
.passage-text { white-space: pre-wrap; font-size: var(--fs-3); line-height: 1.65; }
.vn { font-family: var(--sans); font-size: 0.68em; font-weight: 700; color: var(--gold); margin-right: 3px; vertical-align: super; line-height: 0; }
.passage-notice { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); line-height: 1.4; margin: 14px 0 0; }
.passage-foot { padding: 10px 18px 14px; border-top: 1px solid var(--line); font-family: var(--sans); font-size: var(--fs-1); }
.passage-foot a { color: var(--muted); }
.passage.sheet { position: fixed; left: 0 !important; right: 0; bottom: 0; top: auto !important; width: 100%; max-height: 75vh; border-radius: 18px 18px 0 0; animation: sheetUp 0.22s ease-out; }
.passage-backdrop { position: fixed; inset: 0; background: rgba(20,30,40,0.35); z-index: 59; }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }

/* ---------- Intro video (only shown once a link is added in content.js) ---------- */
.video { margin: 0 0 28px; }
.video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #1d2c38; box-shadow: 0 10px 30px rgba(20, 35, 48, 0.18); }
.video-frame iframe, .video-frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video figcaption { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); margin-top: 8px; }

/* ---------- Footer ---------- */
.site-footer {
  max-width: 760px; margin: -50px auto 0; padding: 0 16px 36px; text-align: center;
  font-family: var(--sans); font-size: var(--fs-1); color: var(--muted);
  display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 8px;
}
.site-footer a { color: var(--muted); }

/* ---------- Leaders ---------- */
.admin-tools { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; margin: 0 0 16px; }
.admin-tools input[type="text"] { flex: 1 1 260px; font-family: var(--sans); font-size: var(--fs-2); }
.admin-tools .check { font-family: var(--sans); font-size: var(--fs-1); }
.admin-tools select { font-family: var(--sans); font-size: var(--fs-1); padding: 8px 10px; border: 1px solid var(--field); border-radius: 8px; background: #fff; }
.sub-item .ws-title .badge { margin-left: 6px; }
.admin-tabs { display: flex; gap: 4px; margin-bottom: 12px; font-family: var(--sans); }
.admin-tabs a { padding: 8px 14px; border-radius: 999px; text-decoration: none; font-size: var(--fs-1); font-weight: 600; color: var(--muted); }
.admin-tabs a.on { background: var(--navy); color: #fff; }

/* ---------- Feedback (opens from the link in the top bar) ---------- */
.fb-panel {
  position: fixed; right: 14px; top: 54px; z-index: 45; width: min(420px, calc(100vw - 28px)); max-height: calc(100vh - 70px);
  display: flex; flex-direction: column; background: #fff; border-radius: 16px;
  box-shadow: 0 20px 50px rgba(20,35,48,0.3), 0 0 0 1px rgba(0,0,0,0.05); animation: stepIn 0.18s ease-out;
}
.fb-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; padding: 16px 18px 10px; border-bottom: 1px solid var(--line); }
.fb-head h2 { font-size: var(--fs-4); margin: 0; }
.fb-page { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); margin-top: 2px; }
.fb-x { all: unset; cursor: pointer; width: 36px; height: 36px; border-radius: 50%; text-align: center; line-height: 36px; color: var(--muted); }
.fb-x:hover { background: #f1f3f5; }
.fb-x:focus-visible { outline: 2px solid var(--focus); }
.fb-body { padding: 12px 18px 18px; overflow: auto; font-size: var(--fs-2); }
.fb-body textarea { min-height: 90px; font-size: var(--fs-2); margin: 10px 0; }
.fb-cats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.fb-chip input { position: absolute; opacity: 0; }
.fb-chip span { display: inline-block; font: 500 var(--fs-1) var(--sans); padding: 6px 11px; border-radius: 999px; border: 1px solid var(--field); cursor: pointer; color: var(--ink); }
.fb-chip input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.fb-chip input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 2px; }
.fb-point { font-size: var(--fs-1); padding: 8px 12px; min-height: 36px; }
.fb-anchor { font-family: var(--serif); font-style: italic; font-size: var(--fs-1); color: var(--muted); background: #f6f6f3; border-left: 3px solid var(--gold); padding: 6px 10px; border-radius: 0 6px 6px 0; margin: 4px 0 6px; }
.fb-chosen { display: flex; gap: 8px; align-items: flex-start; justify-content: space-between; }
.fb-clear { all: unset; cursor: pointer; color: var(--muted); font-style: normal; }
.fb-list-h { font: 700 var(--fs-1) var(--sans); margin: 20px 0 8px; }
.fb-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.fb-item { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: var(--fs-2); }
.fb-item.resolved { opacity: 0.7; }
.fb-item.flash { animation: fbFlash 1.4s ease-out; }
@keyframes fbFlash { 0% { background: #fdf0d8; } 100% { background: #fff; } }
.fb-meta { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; font: var(--fs-1) var(--sans); color: var(--muted); margin-bottom: 4px; }
.fb-meta b { color: var(--ink); }
.fb-num { width: 22px; height: 22px; border-radius: 50%; background: var(--gold); color: #fff; text-align: center; line-height: 22px; font-weight: 700; }
.fb-cat { border: 1px solid var(--line); border-radius: 999px; padding: 0 7px; }
.fb-cat.ok { color: var(--green); border-color: color-mix(in srgb, var(--green) 40%, #fff); }
.fb-text { white-space: pre-wrap; }
.fb-resolve { font-size: var(--fs-1); padding: 4px 8px; margin-top: 4px; min-height: 32px; }
.fb-pin {
  position: absolute; z-index: 30; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; cursor: pointer;
  background: var(--gold); color: #fff; font: 700 var(--fs-1)/20px var(--sans); text-align: center; padding: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
body.fb-picking #app * { cursor: crosshair !important; }
.fb-hover { outline: 3px dashed var(--gold) !important; outline-offset: 4px; border-radius: 6px; background-color: rgba(150, 86, 10, 0.06); }
#fb-pickbar {
  position: fixed; left: 50%; top: 58px; transform: translateX(-50%); z-index: 50; background: var(--navy); color: #fff;
  font: 500 var(--fs-1) var(--sans); padding: 8px 10px 8px 16px; border-radius: 999px; box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  display: flex; align-items: center; gap: 10px; max-width: calc(100vw - 32px);
}
#fb-pickbar .btn { color: #fff; padding: 6px 12px; min-height: 32px; }
#fb-pickbar .btn:hover { background: rgba(255,255,255,0.12); }
.fb-group h3 { margin: 22px 0 10px; font-size: var(--fs-3); }
@media (max-width: 640px) {
  .fb-panel { right: 0; left: 0; top: auto; bottom: 0; width: 100%; max-height: 85vh; border-radius: 18px 18px 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  .card, .passage, .fb-panel, .dgm-piece, .dgm-badge { animation: none !important; }
}
/* ===================== END OF SHARED LOOK ===================== */

/* =====================================================================
   THE BIBLICAL NARRATIVE PAPER
   Copied from the Self-Counseling Project's own section (November 2026); its diagram styles are
   unused here. The paper's own additions are at the end of this file.
   ===================================================================== */
:root {
  /* The diagram's colours where they carry words (the drawing uses brighter tones, set in content.js). */
  --heat: var(--gold);
  --thorn: #a3442e;
  --cross: #2e4a5f;
  --fruit: #3f7550;
}
.theme-heat { --t: var(--heat); }
.theme-thorn { --t: var(--thorn); }
.theme-cross { --t: var(--cross); }
.theme-fruit { --t: var(--fruit); }
.theme-plain { --t: var(--navy); }

/* ---------- Diagram component ---------- */
.dgm { position: relative; overflow: hidden; width: 100%; }
.dgm-stage { position: absolute; }
.dgm-piece { position: absolute; inset: 0; }
.dgm-layer {
  position: absolute; inset: 0; background: var(--c, var(--cross));
  -webkit-mask: url(/diagram-ink.png?v=20261113c) 0 0 / 100% 100% no-repeat;
          mask: url(/diagram-ink.png?v=20261113c) 0 0 / 100% 100% no-repeat;
}
.dgm-layer.dark {
  -webkit-mask-image: url(/diagram-ink-dark.png?v=20261113c);
          mask-image: url(/diagram-ink-dark.png?v=20261113c);
}
.dgm-piece.ghost { opacity: 0.08; }
.dgm-piece.ghost .dgm-layer { background: var(--cross); }
.dgm-piece.dim { opacity: 0.8; }
.dgm-piece.focus {
  filter: drop-shadow(0 0 6px color-mix(in srgb, var(--c) 55%, transparent));
  animation: dgmPop 1s cubic-bezier(.2,.8,.2,1) both;
}
.dgm-piece.pop { animation: dgmPop 1s cubic-bezier(.2,.8,.2,1) both; }
.dgm-piece.build { animation: dgmPop 0.9s cubic-bezier(.2,.8,.2,1) both; }
@keyframes dgmPop { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: none; } }
.dgm-badge {
  position: absolute; transform: translate(-50%, -50%);
  width: 26px; height: 26px; border-radius: 50%; background: var(--c); color: #fff;
  font: 700 var(--fs-1)/26px var(--sans); text-align: center; box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  animation: dgmPop 0.6s ease-out both;
}
@media (max-width: 640px) { .dgm-badge { width: 22px; height: 22px; line-height: 22px; } }
.dgm-button, .dgm-card { all: unset; display: block; width: 100%; cursor: zoom-in; box-sizing: border-box; }
.dgm-button:focus-visible, .dgm-card:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; border-radius: 12px; }
.dgm-modal .dgm { max-width: 640px; margin: 0 auto; }

/* ---------- Welcome hero ---------- */
.hero {
  position: relative; overflow: hidden;
  margin: -36px -40px 28px; padding: 44px 40px 40px;
  background:
    radial-gradient(circle at 88% 30%, rgba(245, 135, 31, 0.32), transparent 45%),
    linear-gradient(135deg, #141f33 0%, #1d2b45 55%, #2b3d5e 100%);
  color: #fff; border-radius: var(--radius) var(--radius) 0 0;
  display: grid; grid-template-columns: 1fr 170px; gap: 20px; align-items: center;
}
.hero h1 { color: #fff; margin: 4px 0 8px; }
.hero .eyebrow { font-family: var(--sans); font-size: var(--fs-1); font-weight: 600; opacity: 0.85; }
.hero-lead { font-style: italic; font-size: var(--fs-4); margin: 0; opacity: 0.95; }
.hero-art { filter: drop-shadow(0 0 22px rgba(240, 190, 90, 0.45)); }
.hero-art .dgm-layer { background: #f0b34a !important; }
@media (max-width: 640px) {
  .hero { margin: -24px -18px 22px; padding: 30px 20px; grid-template-columns: 1fr 96px; }
  .hero-lead { font-size: var(--fs-3); }
}

/* ---------- Three cards ---------- */
.three { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 760px) { .three { grid-template-columns: 1fr; } }
.three-card { position: relative; background: var(--cream); border-radius: 12px; padding: 20px 18px 6px; font-size: var(--fs-2); line-height: 1.55; border-top: 3px solid var(--navy); }
.three-num { display: inline-flex; width: 28px; height: 28px; border-radius: 50%; background: var(--navy); color: #fff; font: 700 var(--fs-1)/28px var(--sans); justify-content: center; margin-bottom: 8px; }

/* ---------- Path strip ---------- */
.path-list { list-style: none; padding: 0; margin: 18px 0 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.path-list li { text-align: center; position: relative; }
.path-list li:not(:last-child)::after {
  content: ""; position: absolute; top: 34px; right: -9px; width: 8px; height: 8px;
  border-top: 2px solid #aab4bd; border-right: 2px solid #aab4bd; transform: rotate(45deg);
}
.path-art {
  width: 78px; height: 78px; margin: 0 auto 8px; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 40%, #fff 0%, color-mix(in srgb, var(--c) 14%, #fff) 100%);
  border: 2px solid color-mix(in srgb, var(--c) 30%, #fff); border-radius: 50%; padding: 12px; overflow: hidden;
}
.path-art .dgm { max-height: 50px; max-width: 50px; width: auto; height: 50px; }
.path-label { font-family: var(--sans); font-weight: 700; font-size: var(--fs-2); color: var(--ink-c, var(--c)); }
.path-note { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); line-height: 1.35; }
@media (max-width: 760px) {
  .path-list { grid-template-columns: repeat(3, 1fr); row-gap: 16px; }
  .path-list li::after { display: none; }
}
.note-line { display: flex; gap: 10px; align-items: center; font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); background: #f4f6f8; border-radius: 10px; padding: 12px 14px; margin-top: 26px; }
.note-line svg { flex: none; color: var(--navy); }
.print-line { display: flex; gap: 10px; align-items: center; font-family: var(--sans); font-size: var(--fs-1); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; margin: 0 0 22px; }
.print-line svg { flex: none; color: var(--navy); }
.print-line a { font-weight: 600; color: var(--navy); white-space: nowrap; }
.ws-list + .print-line, .empty + .print-line { margin: 22px 0 0; }

/* ---------- Two Trees (Scripture is upright) ---------- */
.art { margin: 0 auto 18px; text-align: center; }
.art .dgm { margin: 0 auto; }
.art-sun { max-width: 200px; }
.art figcaption { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); margin-top: 6px; }
.trees { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 6px 0 26px; }
@media (max-width: 680px) { .trees { grid-template-columns: 1fr; } }
.tree { border-radius: 14px; padding: 18px 20px 6px; font-size: var(--fs-2); line-height: 1.6; }
.tree h4 { font-family: var(--sans); font-size: var(--fs-2); font-weight: 700; margin: 0 0 2px; }
.tree.good { background: var(--green-bg); border-top: 4px solid var(--fruit); }
.tree.good h4, .tree.good .ref { color: var(--fruit); }
.tree.bad { background: var(--red-bg); border-top: 4px solid var(--thorn); }
.tree.bad h4, .tree.bad .ref { color: var(--thorn); }
.tree .ref { font-family: var(--sans); font-size: var(--fs-1); font-weight: 500; display: inline-block; margin-bottom: 8px; }
.tree-art { height: 190px; display: flex; justify-content: center; margin: 0 0 12px; }
.tree-art .dgm { height: 100%; width: auto; }
.pull { display: grid; grid-template-columns: 120px 1fr; gap: 22px; align-items: center; margin: 10px 0 24px; padding: 20px 22px; border-radius: 14px; background: #eef2f5; }
.pull p { margin: 0; line-height: 1.6; color: var(--navy-dark); }
.pull-art .dgm { width: 100%; }
@media (max-width: 640px) { .pull { grid-template-columns: 70px 1fr; gap: 14px; padding: 16px; } }
.callout { border-left: 4px solid var(--gold); background: #fbf6ec; border-radius: 0 12px 12px 0; padding: 16px 20px 2px; }

/* ---------- Before you begin ---------- */
.prayer { margin: 4px 0 26px; padding: 28px 30px 24px; text-align: center; font-size: var(--fs-4); line-height: 1.5; background: linear-gradient(180deg, #fbf6ec, #fff); border: 1px solid #efe3c8; border-radius: 16px; color: var(--navy-dark); }
.prayer-label, .prayer cite { display: block; font-style: normal; font-family: var(--sans); font-size: var(--fs-1); color: var(--gold); }
.prayer-label { margin-bottom: 10px; font-weight: 700; }
.prayer cite { color: var(--muted); margin-top: 12px; }
@media (max-width: 640px) { .prayer { font-size: var(--fs-3); padding: 20px 18px; } }
.notes { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 0 0 26px; font-size: var(--fs-2); line-height: 1.55; }
@media (max-width: 640px) { .notes { grid-template-columns: 1fr; } }
.note-card { display: flex; gap: 12px; background: var(--cream); border-radius: 12px; padding: 16px; }
.note-icon { flex: none; width: 38px; height: 38px; border-radius: 10px; background: #fff; color: var(--navy); display: flex; align-items: center; justify-content: center; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }
.fields-box { border-top: 1px solid var(--line); padding-top: 22px; }

/* ---------- Diagram step ---------- */
.diagram-full { max-width: 600px; margin: 0 auto 18px; }
.legend { list-style: none; padding: 0; margin: 0 auto 22px; max-width: 720px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 16px; font-family: var(--sans); font-size: var(--fs-1); }
.legend li { display: flex; align-items: center; gap: 6px; color: var(--c); font-weight: 600; }
.lg-num { width: 24px; height: 24px; border-radius: 50%; background: var(--c); color: #fff; line-height: 24px; text-align: center; }
.credit { font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); border-top: 1px solid var(--line); padding-top: 10px; }
.sb-range { font-size: var(--fs-1); opacity: 0.9; }

/* ---------- Question layout: the drawing beside the question ---------- */
.q-layout { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 36px; align-items: start; }
.q-aside { position: sticky; top: 66px; }
.dgm-card { background: #fbfaf7; border: 1px solid var(--line); border-radius: 16px; padding: 16px; width: 100%; transition: box-shadow 0.2s; }
.dgm-card:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.08); }
/* Under the drawing: this piece's name and its small print, in readable type. */
.dgm-caption { display: block; margin-top: 10px; font-family: var(--sans); font-size: var(--fs-1); color: var(--muted); line-height: 1.4; }
.dgm-caption b { display: block; font-size: var(--fs-2); color: var(--navy); }
.dgm-caption .words { display: block; color: var(--ink); font-family: var(--serif); font-size: var(--fs-2); font-style: italic; }
.dgm-caption .enlarge { display: block; margin-top: 6px; text-decoration: underline; }
@media (max-width: 860px) {
  .q-layout { grid-template-columns: 1fr; gap: 18px; }
  .q-aside { position: static; }
  .dgm-card { display: grid; grid-template-columns: 120px 1fr; gap: 14px; align-items: center; padding: 12px; }
  .dgm-caption { margin: 0; }
}
.q-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.q-num {
  flex: none; width: 44px; height: 44px; border-radius: 50%; color: #fff; background: var(--c, var(--navy));
  font: 700 var(--fs-4)/44px var(--sans); text-align: center;
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--c, var(--navy)) 15%, transparent);
}
.q-title { margin: 0; }
.q-tag { display: inline-block; font-family: var(--sans); font-size: var(--fs-1); font-weight: 600; color: var(--c, var(--muted)); background: color-mix(in srgb, var(--c, var(--navy)) 10%, #fff); border-radius: 999px; padding: 2px 10px; margin-top: 8px; }
.prompt { line-height: 1.7; }
.prompt em { color: color-mix(in srgb, var(--c, var(--navy)) 75%, #222); }
/* Sub-questions (a, b, c) are in the reading face, since they are the question itself. */
.answers .field > label { font-family: var(--serif); font-weight: 400; font-size: var(--fs-3); margin-bottom: 8px; }
.answers textarea, .answers input[type="text"] { border-left: 4px solid color-mix(in srgb, var(--c, var(--navy)) 55%, #fff); }
.answers .letter {
  display: inline-block; min-width: 26px; height: 26px; border-radius: 13px; margin-right: 8px; text-align: center;
  font: 700 var(--fs-1)/26px var(--sans); color: #fff; background: var(--c, var(--navy));
}
.list { padding-left: 0; list-style: none; margin: 0 0 16px; display: grid; gap: 12px; }
.list li { padding-left: 16px; border-left: 3px solid #d5dde3; }

/* ---------- Implement timeline ---------- */
.lead-serif { line-height: 1.7; }
.timeline { list-style: none; padding: 0; margin: 10px 0 18px; position: relative; }
.timeline::before { content: ""; position: absolute; left: 17px; top: 10px; bottom: 30px; width: 2px; background: #d9e1e7; }
.tl-item { position: relative; padding-left: 54px; margin-bottom: 18px; }
.tl-node { position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: #fff; font: 700 var(--fs-2)/36px var(--sans); text-align: center; box-shadow: 0 0 0 5px #fff; }
.tl-item:nth-child(2) .tl-node { background: var(--heat); }
.tl-item:nth-child(3) .tl-node { background: var(--fruit); }
.tl-body { background: #f8f8f6; border-radius: 12px; padding: 16px 18px 4px; }
.tl-body h3 { margin: 0 0 6px; font-size: var(--fs-3); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.tl-body .when { font-family: var(--sans); font-weight: 400; color: var(--muted); font-size: var(--fs-1); }
.closing { font-size: var(--fs-2); color: var(--muted); }
@media (max-width: 640px) { .tl-item { padding-left: 0; } .tl-node { position: static; margin-bottom: 8px; display: block; } .timeline::before { display: none; } }

/* ---------- Review ---------- */
.finish-box { display: grid; grid-template-columns: 1fr 200px; gap: 20px; align-items: center; }
.finish-box .cl-miss { margin: 10px 0 0; }
@media (max-width: 640px) { .finish-box { grid-template-columns: 1fr; } .finish-art { max-width: 220px; margin: 0 auto; } }

/* ---------- Passages table ---------- */
table.passages { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: var(--fs-1); margin: 6px 0 0; }
table.passages th, table.passages td { text-align: left; padding: 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.passages th { background: #f3f2ef; font-weight: 600; }
table.passages td:first-child { font-weight: 600; white-space: nowrap; color: var(--ink); }

/* ===================== THE PAPER'S OWN ADDITIONS ===================== */
:root {
  /* One colour per chapter, dark enough to read as text and to carry white text. */
  --creation: #3f7550;
  --fall: #a3442e;
  --redemption: #2e4a5f;
  --restoration: #96560a;
  --accent: var(--navy);
}
.progress-top .word-total { font-variant-numeric: tabular-nums; }
.part { margin: 26px 0 8px; padding-top: 18px; border-top: 1px solid var(--line); }
.part-h { display: flex; align-items: center; gap: 10px; font-size: var(--fs-3, 1.15rem); margin: 0 0 8px; color: var(--c, var(--navy)); }
.part-num { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--c, var(--navy)); color: #fff; font-size: .9rem; font-weight: 700; flex: none; }
.draw-on { background: var(--cream); border: 1px solid var(--cream-line); border-radius: var(--radius); padding: 10px 16px; margin: 12px 0 16px; }
.draw-on summary, .brainstorm summary { cursor: pointer; font-weight: 600; }
.draw-on .list { margin: 10px 0 4px; }
.draw-on .list li { margin-bottom: 8px; }
.brainstorm { border: 1px dashed var(--field); border-radius: var(--radius); padding: 10px 16px; margin: 16px 0; }
.brainstorm .field { margin-top: 10px; }
.examples { margin: 14px 0; }
.examples h4, .worked h4 { margin: 0 0 6px; font-size: .95rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.examples ul { margin: 0; padding-left: 20px; }
.worked { border-left: 4px solid var(--c, var(--navy)); background: var(--paper); padding: 10px 16px; margin: 14px 0; }
.worked p { margin: 0; }
.pull-quote { margin: 18px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--logo); font-family: var(--serif); font-size: 1.1rem; }
.pull-quote p { margin: 0; }
.pull-quote cite { display: block; margin-top: 6px; font-family: var(--sans); font-size: .85rem; font-style: normal; color: var(--muted); }
.counter { margin-top: 4px; font-size: .85rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.choice { border: 0; padding: 0; margin: 14px 0 0; }
.choice legend { font-weight: 600; margin-bottom: 4px; }
.choice label { display: block; margin: 4px 0; }
.self-check { margin: 22px 0; }
.paper { background: var(--paper); border: 1px solid var(--line); border-radius: 4px; box-shadow: 0 2px 10px rgba(20, 31, 51, .06);
  max-width: 680px; margin: 22px auto; padding: 48px 56px; font-family: var(--serif); font-size: 1.05rem; line-height: 1.65; }
.paper header { text-align: center; margin-bottom: 26px; }
.paper header h2 { margin: 0 0 6px; color: var(--navy); }
.paper-meta { margin: 0; color: var(--muted); font-size: .95rem; }
.paper h3 { font-size: 1.1rem; color: var(--navy); margin: 22px 0 6px; }
.paper p { margin: 0 0 12px; }
.paper-missing { color: var(--muted); font-style: italic; }
@media (max-width: 640px) {
  .paper { padding: 28px 20px; }
}
