/* ==========================================================================
   Scripture Quest — design system
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --font-ui: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, "Times New Roman", serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", Consolas, monospace;

  --rail-w: 256px;
  --top-h: 76px;
  --tab-h: 64px;
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-spring: cubic-bezier(.2, .9, .25, 1.15);

  --gold: #e5b567;
  --gold-deep: #c9913c;
  --teal: #57c7bb;
  --rose: #e8848a;
  --violet: #a99bf0;
  --sky: #79b8f3;
  --sage: #9ac48a;
  --amber: #efc25f;

  --theme-faith: #e5b567;
  --theme-prayer: #a99bf0;
  --theme-salvation: #e8848a;
  --theme-wisdom: #79b8f3;
  --theme-promise: #9ac48a;
  --theme-love: #f0a08a;

  --ok: #63c08a;
  --warn: #e5b567;
  --bad: #e07a80;

  --focus: 0 0 0 3px rgba(229, 181, 103, .45);
  --shadow-sm: 0 1px 2px rgba(4, 8, 18, .25);
  --shadow: 0 10px 30px -12px rgba(4, 8, 18, .55);
  --shadow-lg: 0 30px 70px -24px rgba(2, 5, 14, .7);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #080d18;
  --bg-2: #0b1220;
  --surface: #101a2b;
  --surface-2: #142034;
  --surface-3: #1a2942;
  --line: rgba(158, 183, 220, .14);
  --line-strong: rgba(158, 183, 220, .26);
  --ink: #eef3fb;
  --ink-2: #c3cfdf;
  --ink-3: #8d9db4;
  --ink-4: #67788f;
  --accent: #e5b567;
  --accent-ink: #1a1206;
  --accent-soft: rgba(229, 181, 103, .13);
  --accent-line: rgba(229, 181, 103, .34);
  --good-soft: rgba(99, 192, 138, .14);
  --bad-soft: rgba(224, 122, 128, .14);
  --paper: #0e1728;
  --paper-line: rgba(158, 183, 220, .12);
  --grid-line: rgba(158, 183, 220, .09);
  --glass: rgba(10, 17, 30, .78);
  --grain-opacity: .035;
  --board-bg: #0c1524;
  --board-cell: #122036;
  --board-cell-2: #16263f;
  --wall: #22334f;
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #f6f1e6;
  --bg-2: #efe8d9;
  --surface: #fffdf8;
  --surface-2: #f8f3e8;
  --surface-3: #f0e8d8;
  --line: rgba(60, 48, 26, .13);
  --line-strong: rgba(60, 48, 26, .26);
  --ink: #211b12;
  --ink-2: #4a4031;
  --ink-3: #776a55;
  --ink-4: #9c8e77;
  --accent: #a8721f;
  --accent-ink: #fff9ec;
  --accent-soft: rgba(168, 114, 31, .11);
  --accent-line: rgba(168, 114, 31, .32);
  --good-soft: rgba(38, 128, 78, .12);
  --bad-soft: rgba(168, 60, 66, .11);
  --paper: #fffdf7;
  --paper-line: rgba(60, 48, 26, .1);
  --grid-line: rgba(60, 48, 26, .07);
  --glass: rgba(250, 245, 234, .86);
  --grain-opacity: .045;
  --board-bg: #ece3d2;
  --board-cell: #f6efdf;
  --board-cell-2: #efe6d3;
  --wall: #c9b998;
  --gold: #a8721f;
  --gold-deep: #8a5a14;
  --teal: #218f85;
  --rose: #b8565e;
  --violet: #6f5fc4;
  --sky: #2f6fa8;
  --sage: #4c7a3f;
  --shadow-sm: 0 1px 2px rgba(70, 54, 24, .1);
  --shadow: 0 12px 30px -14px rgba(70, 54, 24, .32);
  --shadow-lg: 0 30px 70px -30px rgba(70, 54, 24, .4);
  --theme-faith: #a8721f;
  --theme-prayer: #6f5fc4;
  --theme-salvation: #b8565e;
  --theme-wisdom: #2f6fa8;
  --theme-promise: #4c7a3f;
  --theme-love: #b46a4c;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow: hidden;
}
[hidden] { display: none !important; }
h1, h2, h3, h4, p, figure { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--radius-xs); }
::selection { background: var(--accent-soft); color: var(--ink); }

.skip-link {
  position: fixed; left: 12px; top: -60px; z-index: 200;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 16px; border-radius: var(--radius-sm); font-weight: 600;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

/* ---------- Boot ---------- */
.boot {
  position: fixed; inset: 0; z-index: 300;
  display: grid; place-content: center; justify-items: center; gap: 14px;
  background:
    radial-gradient(1000px 600px at 50% 20%, rgba(229, 181, 103, .1), transparent 60%),
    var(--bg);
  transition: opacity .5s var(--ease), visibility .5s;
}
.boot.done { opacity: 0; visibility: hidden; pointer-events: none; }
.boot-mark { color: var(--accent); animation: breathe 3.2s ease-in-out infinite; }
.boot-title { font-family: var(--font-serif); font-size: 30px; letter-spacing: .02em; }
.boot-sub { color: var(--ink-3); font-size: 13px; letter-spacing: .04em; }
.boot-bar { width: 180px; height: 3px; border-radius: 99px; background: var(--surface-3); overflow: hidden; margin-top: 6px; }
.boot-bar span { display: block; height: 100%; width: 0; background: var(--accent); transition: width .3s var(--ease); }
@keyframes breathe { 0%, 100% { opacity: .65; transform: scale(.97); } 50% { opacity: 1; transform: scale(1); } }

/* ---------- Shell ---------- */
.app { display: grid; grid-template-columns: var(--rail-w) minmax(0, 1fr); height: 100vh; height: 100dvh; }

.rail {
  position: relative; z-index: 20;
  display: flex; flex-direction: column; gap: 8px;
  padding: 22px 16px 16px;
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border-right: 1px solid var(--line);
  overflow-y: auto; overscroll-behavior: contain;
}
.brand { display: flex; align-items: center; gap: 11px; padding: 4px 8px 18px; }
.brand-mark { color: var(--accent); display: grid; place-items: center; }
.brand-text { display: flex; flex-direction: column; line-height: 1.02; }
.brand-text strong { font-family: var(--font-serif); font-size: 21px; font-weight: 600; letter-spacing: .01em; }
.brand-text em { font-style: normal; font-size: 10px; letter-spacing: .34em; text-transform: uppercase; color: var(--ink-3); margin-top: 3px; padding-left: 1px; }

.rail-nav { display: flex; flex-direction: column; gap: 3px; }
.nav-group-label {
  font-size: 10px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--ink-4); padding: 18px 12px 7px;
}
.nav-item {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 11px 12px; border-radius: var(--radius-sm);
  color: var(--ink-2); font-size: 14px; font-weight: 500;
  transition: background .18s var(--ease), color .18s var(--ease), transform .18s var(--ease);
}
.nav-item:hover { background: var(--surface-2); color: var(--ink); }
.nav-item.active { background: var(--accent-soft); color: var(--accent); }
.nav-item.active::before {
  content: ""; position: absolute; left: -16px; top: 50%; transform: translateY(-50%);
  width: 3px; height: 20px; border-radius: 0 3px 3px 0; background: var(--accent);
}
.nav-ico { display: grid; place-items: center; width: 20px; height: 20px; opacity: .92; }
.nav-ico svg { width: 19px; height: 19px; }

.rail-foot { margin-top: auto; display: flex; flex-direction: column; gap: 8px; padding-top: 16px; }
.streak-pill {
  display: flex; align-items: center; gap: 9px;
  padding: 10px 12px; border-radius: var(--radius-sm);
  background: var(--accent-soft); border: 1px solid var(--accent-line);
  color: var(--accent); font-size: 12.5px; font-weight: 600;
}
.streak-pill svg { width: 16px; height: 16px; }
.rail-settings {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: var(--radius-sm);
  color: var(--ink-3); font-size: 13px; transition: background .18s, color .18s;
}
.rail-settings:hover { background: var(--surface-2); color: var(--ink); }
.rail-settings svg { width: 17px; height: 17px; }
.rail-license { font-size: 10px; color: var(--ink-4); padding: 4px 12px 0; line-height: 1.5; }

.main-wrap { display: flex; flex-direction: column; min-width: 0; min-height: 0; position: relative; }

.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: var(--top-h); padding: 14px clamp(18px, 3vw, 38px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(14px);
  position: relative; z-index: 15;
}
.topbar-kicker { display: block; font-size: 10px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-4); margin-bottom: 3px; }
.topbar-title { font-family: var(--font-serif); font-size: clamp(20px, 2.2vw, 25px); font-weight: 600; letter-spacing: -.01em; line-height: 1.1; }
.topbar-right { display: flex; align-items: center; gap: 8px; }
.mini-stat {
  display: flex; align-items: baseline; gap: 5px; padding: 7px 11px;
  border: 1px solid var(--line); border-radius: 99px; background: var(--surface);
  font-size: 13px; font-weight: 650; color: var(--ink-2);
}
.mini-stat .mini-ico { color: var(--accent); display: grid; place-items: center; align-self: center; }
.mini-stat .mini-ico svg { width: 14px; height: 14px; }
.mini-label { font-size: 10.5px; font-weight: 500; color: var(--ink-4); }
.icon-btn {
  display: grid; place-items: center; width: 38px; height: 38px;
  border: 1px solid var(--line); border-radius: 50%; background: var(--surface);
  color: var(--ink-2); transition: background .18s, color .18s, border-color .18s, transform .18s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--ink); border-color: var(--line-strong); }
.icon-btn:active { transform: scale(.94); }
.icon-btn svg { width: 18px; height: 18px; }
.install-btn { color: var(--accent); border-color: var(--accent-line); }
.install-steps { margin: 2px 0 0; padding-left: 22px; list-style: decimal; display: grid; gap: 9px; font-size: 14px; color: var(--ink-2); line-height: 1.55; }
.install-steps li::marker { color: var(--accent); font-weight: 700; }
.avatar-btn {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--gold-deep));
  color: var(--accent-ink); font-family: var(--font-serif); font-size: 17px; font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3);
}

#view {
  flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior-y: contain;
  padding: clamp(20px, 3vw, 34px) clamp(18px, 3vw, 38px) 48px;
  scroll-behavior: smooth;
}
#view:focus { outline: none; }
.view-inner { max-width: 1180px; margin: 0 auto; animation: rise .34s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: none; } }

.tabbar { display: none; }

/* ---------- Type & primitives ---------- */
.eyebrow { font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-4); font-weight: 650; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 22px; }
.page-title { font-family: var(--font-serif); font-size: clamp(26px, 3.4vw, 38px); font-weight: 600; letter-spacing: -.02em; line-height: 1.08; }
.page-sub { color: var(--ink-3); font-size: 14px; margin-top: 7px; max-width: 62ch; line-height: 1.6; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 30px 0 13px; }
.section-title { font-family: var(--font-serif); font-size: 19px; font-weight: 600; letter-spacing: -.01em; display: flex; align-items: center; gap: 9px; }
.section-title svg { width: 17px; height: 17px; color: var(--accent); }
.section-link { font-size: 12.5px; font-weight: 600; color: var(--accent); display: inline-flex; align-items: center; gap: 4px; padding: 4px; border-radius: 6px; }
.section-link:hover { text-decoration: underline; text-underline-offset: 3px; }

.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}
.card-pad { padding: clamp(16px, 2.2vw, 24px); }
.muted { color: var(--ink-3); }
.tiny { font-size: 11.5px; }
.small { font-size: 13px; }
.mono { font-family: var(--font-mono); }
.serif { font-family: var(--font-serif); }
.row { display: flex; align-items: center; gap: 10px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.stack { display: flex; flex-direction: column; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 17px; border-radius: 99px; border: 1px solid transparent;
  font-size: 13.5px; font-weight: 650; letter-spacing: .005em; white-space: nowrap;
  transition: transform .16s var(--ease), background .18s, border-color .18s, color .18s, box-shadow .18s;
}
.btn svg { width: 16px; height: 16px; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 6px 18px -8px rgba(229, 181, 103, .7); }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, #fff); }
.btn-ghost { border-color: var(--line-strong); color: var(--ink-2); background: transparent; }
.btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn-soft { background: var(--accent-soft); color: var(--accent); border-color: var(--accent-line); }
.btn-soft:hover { background: color-mix(in srgb, var(--accent) 18%, transparent); }
.btn-quiet { color: var(--ink-3); }
.btn-quiet:hover { color: var(--ink); background: var(--surface-2); }
.btn-sm { padding: 7px 13px; font-size: 12px; }
.btn-lg { padding: 13px 24px; font-size: 14.5px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .45; pointer-events: none; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px; border-radius: 99px; border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink-2);
  font-size: 11.5px; font-weight: 600; white-space: nowrap;
}
.chip svg { width: 13px; height: 13px; }
.chip-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.chip-faith { color: var(--theme-faith); border-color: color-mix(in srgb, var(--theme-faith) 35%, transparent); background: color-mix(in srgb, var(--theme-faith) 10%, transparent); }
.chip-prayer { color: var(--theme-prayer); border-color: color-mix(in srgb, var(--theme-prayer) 35%, transparent); background: color-mix(in srgb, var(--theme-prayer) 10%, transparent); }
.chip-salvation { color: var(--theme-salvation); border-color: color-mix(in srgb, var(--theme-salvation) 35%, transparent); background: color-mix(in srgb, var(--theme-salvation) 10%, transparent); }
.chip-wisdom { color: var(--theme-wisdom); border-color: color-mix(in srgb, var(--theme-wisdom) 35%, transparent); background: color-mix(in srgb, var(--theme-wisdom) 10%, transparent); }
.chip-promise { color: var(--theme-promise); border-color: color-mix(in srgb, var(--theme-promise) 35%, transparent); background: color-mix(in srgb, var(--theme-promise) 10%, transparent); }
.chip-love { color: var(--theme-love); border-color: color-mix(in srgb, var(--theme-love) 35%, transparent); background: color-mix(in srgb, var(--theme-love) 10%, transparent); }

.bar { height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 99px; background: var(--accent); transition: width .5s var(--ease); }

.seg {
  display: inline-flex; padding: 3px; gap: 2px; border-radius: 99px;
  background: var(--surface-2); border: 1px solid var(--line);
}
.seg button {
  padding: 6px 12px; border-radius: 99px; font-size: 12px; font-weight: 600; color: var(--ink-3);
  transition: background .18s, color .18s;
}
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }

.input, .select, .textarea {
  width: 100%; padding: 10px 13px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--ink);
  font-size: 13.5px; transition: border-color .18s, background .18s;
}
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--accent-line); box-shadow: var(--focus); }
.input::placeholder, .textarea::placeholder { color: var(--ink-4); }
.textarea { resize: vertical; min-height: 92px; line-height: 1.55; }

.empty {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px;
  padding: 42px 24px; border: 1px dashed var(--line-strong); border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface), transparent);
}
.empty-ico { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); }
.empty-ico svg { width: 24px; height: 24px; }
.empty h3 { font-family: var(--font-serif); font-size: 19px; font-weight: 600; }
.empty p { color: var(--ink-3); font-size: 13.5px; max-width: 46ch; line-height: 1.6; }

/* ---------- Today ---------- */
.hero {
  position: relative; overflow: hidden;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background:
    radial-gradient(900px 420px at 88% -20%, rgba(229, 181, 103, .2), transparent 62%),
    radial-gradient(700px 380px at 8% 120%, rgba(87, 199, 187, .12), transparent 60%),
    linear-gradient(150deg, var(--surface-2), var(--surface));
  padding: clamp(22px, 3.4vw, 38px);
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(240px, .85fr); gap: clamp(20px, 3vw, 40px); align-items: center; }
.hero-date { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); font-weight: 650; }
.hero-title { font-family: var(--font-serif); font-size: clamp(30px, 4.6vw, 50px); line-height: 1.03; letter-spacing: -.025em; font-weight: 600; margin: 12px 0 12px; }
.hero-title em { font-style: italic; color: var(--accent); }
.hero-sub { color: var(--ink-2); font-size: 14.5px; line-height: 1.65; max-width: 50ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.hero-meta { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.hero-meta div { display: flex; flex-direction: column; gap: 3px; }
.hero-meta b { font-family: var(--font-serif); font-size: 20px; font-weight: 600; }
.hero-meta span { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-4); }

.ring-wrap { display: grid; place-items: center; position: relative; }
.ring { transform: rotate(-90deg); }
.ring-track { stroke: var(--surface-3); }
.ring-fill { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .8s var(--ease); filter: drop-shadow(0 0 6px rgba(229, 181, 103, .4)); }
.ring-center { position: absolute; display: grid; place-items: center; text-align: center; }
.ring-center b { font-family: var(--font-serif); font-size: 32px; line-height: 1; }
.ring-center span { font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-4); margin-top: 4px; }
.ring-caption { text-align: center; font-size: 11.5px; color: var(--ink-3); margin-top: 10px; }

.journey { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.journey-step {
  position: relative; display: flex; flex-direction: column; gap: 9px;
  padding: 16px; border-radius: var(--radius); border: 1px solid var(--line);
  background: var(--surface); transition: border-color .2s, transform .2s, background .2s;
  text-align: left; min-height: 148px;
}
.journey-step:hover { border-color: var(--accent-line); transform: translateY(-2px); }
.journey-step.done { background: linear-gradient(180deg, var(--accent-soft), var(--surface)); border-color: var(--accent-line); }
.journey-top { display: flex; align-items: center; justify-content: space-between; }
.journey-num { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-4); letter-spacing: .1em; }
.journey-check { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line-strong); color: transparent; }
.journey-step.done .journey-check { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.journey-check svg { width: 13px; height: 13px; }
.journey-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: var(--surface-2); color: var(--accent); border: 1px solid var(--line); }
.journey-ico svg { width: 17px; height: 17px; }
.journey-step h4 { font-size: 13.5px; font-weight: 650; }
.journey-step p { font-size: 11.5px; color: var(--ink-3); line-height: 1.5; }
.journey-time { margin-top: auto; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-4); }

.two-col { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(280px, .95fr); gap: 20px; align-items: start; }

.verse-of-day { position: relative; overflow: hidden; }
.vod-quote { font-family: var(--font-serif); font-size: clamp(18px, 2.1vw, 23px); line-height: 1.55; letter-spacing: -.005em; }
.vod-quote::before { content: "“"; color: var(--accent); font-size: 1.4em; line-height: 0; margin-right: 2px; }
.vod-ref { font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); font-weight: 650; margin-top: 12px; }

.due-item {
  display: flex; align-items: center; gap: 12px; padding: 11px 0;
  border-bottom: 1px solid var(--line); width: 100%; text-align: left;
}
.due-item:last-child { border-bottom: 0; }
.due-item:hover .due-ref { color: var(--accent); }
.due-ref { font-size: 12.5px; font-weight: 650; transition: color .18s; }
.due-text { font-family: var(--font-serif); font-size: 12.5px; color: var(--ink-3); line-height: 1.45; margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.due-stage { flex-shrink: 0; }

.recent-card {
  display: flex; flex-direction: column; gap: 8px; padding: 15px 16px;
  border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface);
  transition: border-color .18s, transform .18s; text-align: left;
}
.recent-card:hover { border-color: var(--accent-line); transform: translateY(-2px); }
.recent-ref { font-size: 11px; letter-spacing: .13em; text-transform: uppercase; font-weight: 650; color: var(--accent); }
.recent-text { font-family: var(--font-serif); font-size: 14px; line-height: 1.5; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.recent-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 4px; }
.recent-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }

/* ---------- Reader ---------- */
.reader-shell { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; align-items: start; }
.reader-main { min-width: 0; }
.reader-toolbar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); margin-bottom: 14px; position: sticky; top: 0; z-index: 8;
  box-shadow: var(--shadow-sm);
}
.reader-loc { display: flex; align-items: center; gap: 6px; min-width: 0; }
.reader-loc-btn {
  display: flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 650; color: var(--ink); border: 1px solid transparent;
  transition: background .18s, border-color .18s;
}
.reader-loc-btn:hover { background: var(--surface-2); border-color: var(--line); }
.reader-loc-btn svg { width: 14px; height: 14px; color: var(--ink-4); }
.reader-loc-sep { color: var(--ink-4); }
.reader-tools { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.tool-btn {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px;
  color: var(--ink-3); transition: background .18s, color .18s;
}
.tool-btn:hover { background: var(--surface-2); color: var(--ink); }
.tool-btn svg { width: 17px; height: 17px; }
.tool-btn[disabled] { opacity: .3; pointer-events: none; }
.reading-time { font-size: 11px; color: var(--ink-4); font-variant-numeric: tabular-nums; padding: 0 6px; white-space: nowrap; }

.chapter-card {
  position: relative; padding: clamp(22px, 4vw, 52px) clamp(20px, 5vw, 64px) clamp(30px, 5vw, 60px);
  background: var(--paper); border: 1px solid var(--paper-line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
  background-image: radial-gradient(circle at 20% 0%, color-mix(in srgb, var(--accent) 6%, transparent), transparent 55%);
}
.chapter-eyebrow { text-align: center; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--ink-4); }
.chapter-title { font-family: var(--font-serif); text-align: center; font-size: clamp(27px, 3.6vw, 40px); font-weight: 600; letter-spacing: -.02em; margin: 8px 0 4px; }
.chapter-sub { text-align: center; font-size: 11.5px; color: var(--ink-4); margin-bottom: 26px; }
.chapter-rule { width: 54px; height: 1px; background: var(--accent); opacity: .55; margin: 0 auto 30px; }

.verse-flow { font-family: var(--font-serif); font-size: var(--reader-size, 19px); line-height: var(--reader-leading, 1.82); color: var(--ink); }
.verse {
  position: relative; cursor: pointer; border-radius: 4px;
  padding: 2px 1px; margin: 0 -1px;
  transition: background .16s, box-shadow .16s;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.verse:hover { background: color-mix(in srgb, var(--accent) 7%, transparent); }
.verse .vn {
  font-family: var(--font-ui); font-size: .56em; font-weight: 700; vertical-align: super;
  color: var(--ink-4); margin-right: 4px; letter-spacing: .02em; user-select: none;
}
.verse.hl { background: color-mix(in srgb, var(--hl-color, var(--accent)) 22%, transparent); box-shadow: inset 0 -2px 0 color-mix(in srgb, var(--hl-color, var(--accent)) 70%, transparent); }
.verse.hl .vn { color: color-mix(in srgb, var(--hl-color, var(--accent)) 85%, var(--ink)); }
.verse.sel { background: color-mix(in srgb, var(--accent) 26%, transparent); box-shadow: inset 0 0 0 1px var(--accent-line); }
.verse.note-mark::after {
  content: ""; position: absolute; top: 2px; right: -2px; width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
}
.verse .note-badge {
  display: inline-grid; place-items: center; width: 13px; height: 13px; margin-left: 3px;
  vertical-align: middle; color: var(--ink-3);
}
.verse .note-badge svg { width: 12px; height: 12px; }
.verse.anchor { background: color-mix(in srgb, var(--accent) 18%, transparent); }

.reader-end { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 34px 0 8px; }
.reader-end p { font-size: 12px; color: var(--ink-4); letter-spacing: .06em; }
.reader-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; }
.reader-nav-btn {
  display: flex; align-items: center; gap: 9px; padding: 11px 15px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface); font-size: 12.5px; color: var(--ink-2);
  max-width: 46%; transition: border-color .18s, background .18s;
}
.reader-nav-btn:hover { border-color: var(--accent-line); background: var(--surface-2); }
.reader-nav-btn svg { width: 15px; height: 15px; flex-shrink: 0; }
.reader-nav-btn span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.reader-nav-btn.next { text-align: right; }

.reader-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 0; }
.side-card { padding: 16px; }
.side-title { font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-4); font-weight: 650; margin-bottom: 10px; }
.side-verse { font-family: var(--font-serif); font-size: 13.5px; line-height: 1.55; color: var(--ink-2); }
.side-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; }
.mini-hl { display: flex; flex-direction: column; gap: 7px; padding: 9px 0; border-bottom: 1px solid var(--line); text-align: left; width: 100%; }
.mini-hl:last-child { border-bottom: 0; }
.mini-hl:hover .mini-hl-ref { color: var(--accent); }
.mini-hl-ref { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; font-weight: 650; color: var(--ink-2); transition: color .18s; }
.mini-hl-text { font-family: var(--font-serif); font-size: 12px; color: var(--ink-3); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.selection-bar {
  position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%) translateY(0);
  z-index: 60; display: flex; align-items: center; gap: 8px; padding: 8px 10px 8px 14px;
  border-radius: 99px; border: 1px solid var(--line-strong); background: var(--glass);
  backdrop-filter: blur(18px); box-shadow: var(--shadow-lg);
  animation: selIn .26s var(--ease-spring) both; max-width: calc(100vw - 24px);
}
@keyframes selIn { from { opacity: 0; transform: translateX(-50%) translateY(16px); } }
.selection-bar.leaving { animation: selOut .18s var(--ease) forwards; }
@keyframes selOut { to { opacity: 0; transform: translateX(-50%) translateY(14px); } }
.sel-ref { font-size: 12px; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }
.sel-sep { width: 1px; height: 22px; background: var(--line-strong); }
.swatches { display: flex; gap: 5px; }
.swatch {
  width: 23px; height: 23px; border-radius: 50%; border: 2px solid transparent;
  transition: transform .16s var(--ease-spring), border-color .16s;
  position: relative;
}
.swatch:hover { transform: scale(1.14); }
.swatch.on { border-color: var(--ink); }
.swatch svg { width: 100%; height: 100%; opacity: 0; }
.swatch.on svg { opacity: 1; }
.sel-btn { display: grid; place-items: center; width: 33px; height: 33px; border-radius: 50%; color: var(--ink-2); transition: background .16s, color .16s; }
.sel-btn:hover { background: var(--surface-3); color: var(--ink); }
.sel-btn svg { width: 17px; height: 17px; }

/* ---------- Vault ---------- */
.vault-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat-card { padding: 15px 16px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.stat-label { font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-4); font-weight: 650; }
.stat-value { font-family: var(--font-serif); font-size: 27px; font-weight: 600; line-height: 1.1; margin-top: 6px; }
.stat-foot { font-size: 11px; color: var(--ink-3); margin-top: 3px; }

.vault-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.search-box { position: relative; flex: 1; min-width: 180px; max-width: 340px; }
.search-box svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; color: var(--ink-4); }
.search-box .input { padding-left: 34px; }

.vault-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.scripture-card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 18px; border-radius: var(--radius); border: 1px solid var(--line);
  background: var(--surface); transition: border-color .2s, transform .2s, box-shadow .2s;
  overflow: hidden;
}
.scripture-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--hl-color, var(--accent)); opacity: .85;
}
.scripture-card:hover { border-color: var(--line-strong); transform: translateY(-2px); box-shadow: var(--shadow); }
.sc-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.sc-ref { font-family: var(--font-serif); font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.sc-theme { margin-top: 4px; }
.sc-text {
  font-family: var(--font-serif); font-size: 14px; line-height: 1.62; color: var(--ink-2);
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.sc-note {
  font-size: 11.5px; color: var(--ink-3); background: var(--surface-2); border-left: 2px solid var(--line-strong);
  padding: 7px 9px; border-radius: 0 6px 6px 0; line-height: 1.5;
}
.sc-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 2px; }
.sc-abilities { display: flex; gap: 3px; }
.ability-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--surface-3); }
.ability-dot.on { background: var(--accent); }
.sc-actions { display: flex; gap: 4px; }
.sc-btn { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; color: var(--ink-3); border: 1px solid transparent; transition: background .16s, color .16s, border-color .16s; }
.sc-btn:hover { background: var(--surface-2); color: var(--ink); border-color: var(--line); }
.sc-btn svg { width: 15px; height: 15px; }
.stage-pill { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; padding: 4px 8px; border-radius: 99px; white-space: nowrap; }
.stage-new { background: var(--surface-3); color: var(--ink-3); }
.stage-learning { background: rgba(121, 184, 243, .16); color: var(--sky); }
.stage-remembering { background: rgba(169, 155, 240, .16); color: var(--violet); }
.stage-retained { background: rgba(154, 196, 138, .18); color: var(--sage); }

/* ---------- Games: shared ---------- */
.game-shell { display: grid; grid-template-columns: minmax(0, 1fr) 316px; gap: 20px; align-items: start; }
.game-main { min-width: 0; }
.game-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-bottom: 14px; }
.game-title-row { display: flex; align-items: center; gap: 12px; }
.game-badge { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); border: 1px solid var(--accent-line); }
.game-badge svg { width: 22px; height: 22px; }
.game-name { font-family: var(--font-serif); font-size: 24px; font-weight: 600; letter-spacing: -.015em; line-height: 1.1; }
.game-tag { font-size: 11px; color: var(--ink-4); letter-spacing: .1em; text-transform: uppercase; margin-top: 2px; }
.game-hud { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.hud-pill {
  display: flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 99px;
  border: 1px solid var(--line); background: var(--surface); font-size: 12px; font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.hud-pill svg { width: 14px; height: 14px; color: var(--accent); }
.hud-pill .hud-label { font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-4); font-weight: 600; }

.board-frame {
  position: relative; border-radius: var(--radius-lg); border: 1px solid var(--line);
  background: var(--board-bg); padding: clamp(8px, 1.4vw, 14px);
  box-shadow: var(--shadow); overflow: hidden;
}
.board-frame::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(700px 300px at 50% -10%, rgba(229, 181, 103, .08), transparent 60%);
}
.board {
  position: relative; width: 100%; aspect-ratio: var(--aspect, 1);
  border-radius: var(--radius); overflow: hidden; touch-action: manipulation;
  background: var(--board-bg);
}
.board-grid {
  position: absolute; inset: 0; display: grid;
  grid-template-columns: var(--cols); grid-template-rows: var(--rows);
}
.board-cell { background: var(--board-cell); position: relative; }
.board-cell.alt { background: var(--board-cell-2); }
.board-cell::after {
  content: ""; position: absolute; inset: 0;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .14), inset 0 0 0 2px rgba(255, 255, 255, .012);
}
.board.is-paused { filter: blur(7px) saturate(.7); pointer-events: none; }

.board-overlay {
  position: absolute; inset: 0; z-index: 12; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px; text-align: center;
  padding: clamp(14px, 3vw, 24px); overflow-y: auto;
  background: color-mix(in srgb, var(--board-bg) 72%, transparent); backdrop-filter: blur(3px);
  border-radius: var(--radius);
}
.board-overlay h3 { font-family: var(--font-serif); font-size: clamp(21px, 3.4vw, 27px); line-height: 1.1; }
.board-overlay p { font-size: clamp(11px, 1.5vw, 12.5px); color: var(--ink-3); max-width: 34ch; line-height: 1.55; }
.overlay-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 6px; }

.game-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.game-help { font-size: 12px; color: var(--ink-3); line-height: 1.6; }
.game-help b { color: var(--ink-2); }

.game-side { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 0; }
.panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 16px; }
.panel-title { display: flex; align-items: center; gap: 7px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-4); font-weight: 650; margin-bottom: 11px; }
.panel-title svg { width: 13px; height: 13px; color: var(--accent); }
.scripture-mini { font-family: var(--font-serif); font-size: 14.5px; line-height: 1.6; color: var(--ink-2); }
.scripture-mini .ref { display: block; font-family: var(--font-ui); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); font-weight: 650; margin-bottom: 7px; }
.queue-list { display: flex; flex-direction: column; gap: 7px; }
.queue-item { display: flex; align-items: center; gap: 9px; font-size: 12px; color: var(--ink-3); }
.queue-dot { width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; font-size: 9px; font-weight: 700; background: var(--surface-2); border: 1px solid var(--line); flex-shrink: 0; }
.queue-item.done { color: var(--ink-4); text-decoration: line-through; }
.queue-item.done .queue-dot { background: var(--good-soft); border-color: color-mix(in srgb, var(--ok) 40%, transparent); color: var(--ok); }
.queue-item.current { color: var(--ink); font-weight: 600; }
.queue-item.current .queue-dot { border-color: var(--accent-line); color: var(--accent); background: var(--accent-soft); }

/* ---------- Arrow clearing maze ---------- */
.maze-frame { display: flex; flex-direction: column; align-items: center; }
.arrow-board-svg {
  display: block; width: 100%; height: auto; max-height: clamp(360px, 68vh, 780px);
  overflow: hidden; margin: 0 auto; touch-action: manipulation;
  user-select: none; -webkit-user-select: none;
}
.arrow-dot { fill: var(--line-strong); opacity: .5; }
.arrow { cursor: pointer; }
.arrow-hit {
  fill: none; stroke: transparent; stroke-width: 30;
  stroke-linecap: round; stroke-linejoin: round; pointer-events: stroke;
}
.arrow-line {
  fill: none; stroke: var(--ink); stroke-width: 10;
  stroke-linecap: round; stroke-linejoin: round; pointer-events: none;
  transition: stroke .16s, filter .16s;
}
.arrow-head { fill: var(--ink); pointer-events: fill; transition: fill .16s, filter .16s; }
.arrow:hover .arrow-line, .arrow:focus-visible .arrow-line { stroke: var(--accent); }
.arrow:hover .arrow-head, .arrow:focus-visible .arrow-head { fill: var(--accent); }
.arrow:focus { outline: none; }
.arrow:focus-visible .arrow-line {
  stroke: var(--accent);
  filter: drop-shadow(0 0 5px color-mix(in srgb, var(--accent) 65%, transparent));
}
.arrow.hint .arrow-line {
  stroke: var(--sky);
  filter: drop-shadow(0 0 5px color-mix(in srgb, var(--sky) 85%, transparent))
          drop-shadow(0 0 13px color-mix(in srgb, var(--sky) 55%, transparent));
}
.arrow.hint .arrow-head {
  fill: var(--sky);
  filter: drop-shadow(0 0 6px color-mix(in srgb, var(--sky) 85%, transparent));
}
.arrow.blocked .arrow-line { stroke: var(--bad); }
.arrow.blocked .arrow-head { fill: var(--bad); }
.arrow.blocked { animation: arrowBlocked .44s var(--ease); }
.arrow.shooting { pointer-events: none; }
@keyframes arrowBlocked {
  15% { transform: translateX(-5px); }
  35% { transform: translateX(5px); }
  55% { transform: translateX(-3px); }
  75% { transform: translateX(3px); }
  90% { transform: translateX(-1px); }
}
.arrow-progress { margin: 0 0 12px; }
.arrow-progress .bar { height: 4px; }
.arrow-progress .bar > span { background: linear-gradient(90deg, var(--teal), var(--accent)); }
.maze-legend { display: flex; gap: 12px; flex-wrap: wrap; font-size: 10.5px; color: var(--ink-4); margin-top: 10px; }
.maze-legend span { display: inline-flex; align-items: center; gap: 5px; }
.legend-dot { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.legend-dot.clear { background: var(--ink-3); }
.legend-dot.blocked { background: var(--bad); }
.legend-dot.hint { background: var(--sky); }

/* HUD hearts + clock */
.hud-lives { gap: 8px; }
.hud-hearts { display: inline-flex; gap: 2px; }
.heart-row { display: inline-flex; align-items: center; gap: 3px; }
.heart { display: inline-grid; place-items: center; width: 14px; height: 14px; color: var(--rose); }
.heart svg { width: 100%; height: 100%; }
.heart.on svg path { fill: currentColor; }
.heart.off { opacity: .28; }
.heart.off svg path { fill: none; }
.heart-row.lg { gap: 5px; }
.heart-row.lg .heart { width: 24px; height: 24px; }
.hud-time {
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 700; letter-spacing: .02em;
  color: var(--ink-2); padding-left: 7px; border-left: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}
.hud-time.low { color: var(--bad); animation: lowPulse 1.1s ease-in-out infinite; }
@keyframes lowPulse { 50% { opacity: .55; } }
.hud-errors, .hud-errors svg { color: var(--bad); }

/* Life + gate panels */
.life-panel .panel-title svg { color: var(--rose); }
.life-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.life-clock { font-family: var(--font-mono); font-size: 21px; font-weight: 700; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.life-clock.low { color: var(--bad); }
.life-panel .bar > span { background: linear-gradient(90deg, var(--rose), var(--accent)); }
.rule-list { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
.rule-list li { position: relative; padding-left: 15px; font-size: 11.5px; line-height: 1.55; color: var(--ink-3); }
.rule-list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
.gate-kicker { font-size: 9px; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; color: var(--accent); }
.gate-hearts { margin: 1px 0; }
.gate-hearts .heart-row.lg .heart { width: 27px; height: 27px; }
.gate-dots { display: flex; gap: 6px; align-items: center; justify-content: center; margin-top: 2px; }
.gate-dot { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--line-strong); background: transparent; }
.gate-dot.on { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 8px rgba(229, 181, 103, .5); }
.gate-progress { font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-4); font-weight: 600; }
.gate-foot { font-size: 10px; color: var(--ink-4); }
.gate-score { font-variant-numeric: tabular-nums; }
.board-overlay .overlay-actions { margin-top: 4px; }
.board-overlay .btn-lg { padding: 11px 18px; font-size: 13px; }
.board-overlay .btn { white-space: nowrap; }
@media (max-width: 720px) {
  .arrow-board-svg { max-height: 50vh; }
  .maze-frame { padding: 8px; }
  .maze-legend { gap: 8px; font-size: 9.5px; }
  .board-overlay { padding: 12px; gap: 6px; }
  .board-overlay h3 { font-size: 21px; }
  .board-overlay p { font-size: 11px; }
  .gate-hearts .heart-row.lg .heart { width: 21px; height: 21px; }
  .gate-kicker { font-size: 8px; }
  .board-overlay .btn-lg { padding: 9px 14px; font-size: 12px; }
  .hud-pill { padding: 6px 9px; font-size: 11px; }
  .hud-time { font-size: 10.5px; }
  .life-clock { font-size: 18px; }
}

/* ---------- Challenges ---------- */
.challenge { display: flex; flex-direction: column; gap: 18px; }
.challenge-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.challenge-type { display: inline-flex; align-items: center; gap: 6px; font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; color: var(--accent); }
.challenge-type svg { width: 13px; height: 13px; }
.challenge-prompt { font-family: var(--font-serif); font-size: clamp(19px, 2.4vw, 24px); line-height: 1.35; letter-spacing: -.01em; font-weight: 600; }
.challenge-verse {
  font-family: var(--font-serif); font-size: 16px; line-height: 1.75; color: var(--ink-2);
  padding: 16px 18px; border-radius: var(--radius-sm); background: var(--surface-2);
  border-left: 3px solid var(--accent); position: relative;
}
.challenge-verse .blank {
  display: inline-block; min-width: 70px; border-bottom: 2px solid var(--accent); margin: 0 3px;
  color: var(--accent); font-weight: 600; text-align: center;
}
.challenge-verse .blank.filled { border-bottom-color: var(--ok); color: var(--ok); }
.challenge-hint { font-size: 11.5px; color: var(--ink-4); }
.option-list { display: flex; flex-direction: column; gap: 8px; }
.option {
  display: flex; align-items: center; gap: 11px; width: 100%; text-align: left;
  padding: 13px 15px; border-radius: var(--radius-sm); border: 1px solid var(--line-strong);
  background: var(--surface); font-size: 13.5px; line-height: 1.45; color: var(--ink-2);
  transition: border-color .16s, background .16s, transform .16s, color .16s;
}
.option:hover { border-color: var(--accent-line); background: var(--surface-2); color: var(--ink); }
.option:active { transform: scale(.995); }
.option-key {
  display: grid; place-items: center; width: 24px; height: 24px; flex-shrink: 0;
  border-radius: 6px; border: 1px solid var(--line-strong); font-size: 10.5px; font-weight: 700;
  font-family: var(--font-mono); color: var(--ink-4);
}
.option.correct { border-color: color-mix(in srgb, var(--ok) 55%, transparent); background: var(--good-soft); color: var(--ink); }
.option.correct .option-key { border-color: var(--ok); color: var(--ok); background: color-mix(in srgb, var(--ok) 16%, transparent); }
.option.wrong { border-color: color-mix(in srgb, var(--bad) 55%, transparent); background: var(--bad-soft); color: var(--ink); animation: shakeX .32s var(--ease); }
.option.wrong .option-key { border-color: var(--bad); color: var(--bad); }
.option[disabled] { pointer-events: none; }
@keyframes shakeX { 25% { transform: translateX(-4px); } 50% { transform: translateX(4px); } 75% { transform: translateX(-2px); } }

.order-answer {
  display: flex; flex-wrap: wrap; gap: 6px; min-height: 52px; padding: 10px;
  border-radius: var(--radius-sm); border: 1px dashed var(--line-strong); background: var(--surface-2);
  align-content: flex-start;
}
.order-answer:empty::before { content: "Tap the phrases below in the right order"; font-size: 11.5px; color: var(--ink-4); align-self: center; padding: 4px; }
.order-bank { display: flex; flex-wrap: wrap; gap: 6px; }
.phrase-chip {
  padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line-strong);
  background: var(--surface); font-size: 12.5px; line-height: 1.3; color: var(--ink-2);
  transition: border-color .16s, background .16s, transform .16s;
}
.phrase-chip:hover { border-color: var(--accent-line); color: var(--ink); }
.phrase-chip:active { transform: scale(.97); }
.phrase-chip.used { opacity: .32; pointer-events: none; }
.phrase-chip.in-answer { background: var(--accent-soft); border-color: var(--accent-line); color: var(--accent); }
.phrase-chip.bad { border-color: var(--bad); background: var(--bad-soft); color: var(--bad); }
.phrase-chip.good { border-color: var(--ok); background: var(--good-soft); color: var(--ok); }
.challenge-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 2px; }
.feedback { display: flex; gap: 11px; padding: 13px 14px; border-radius: var(--radius-sm); font-size: 12.5px; line-height: 1.55; align-items: flex-start; }
.feedback.good { background: var(--good-soft); border: 1px solid color-mix(in srgb, var(--ok) 30%, transparent); }
.feedback.bad { background: var(--bad-soft); border: 1px solid color-mix(in srgb, var(--bad) 30%, transparent); }
.feedback-ico { flex-shrink: 0; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; }
.feedback.good .feedback-ico { background: var(--ok); color: #08140c; }
.feedback.bad .feedback-ico { background: var(--bad); color: #1a0809; }
.feedback-ico svg { width: 12px; height: 12px; }
.feedback b { display: block; margin-bottom: 2px; }

/* ---------- Modal / sheet ---------- */
.scrim {
  position: fixed; inset: 0; z-index: 90; background: rgba(4, 7, 14, .62);
  backdrop-filter: blur(5px); display: flex; align-items: center; justify-content: center;
  padding: 20px; animation: fadeIn .2s var(--ease) both;
}
[data-theme="light"] .scrim { background: rgba(40, 30, 14, .38); }
@keyframes fadeIn { from { opacity: 0; } }
.modal {
  position: relative; width: min(560px, 100%); max-height: min(88vh, 900px); overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); animation: modalIn .28s var(--ease-spring) both;
}
.modal.wide { width: min(760px, 100%); }
.modal.narrow { width: min(440px, 100%); }
@keyframes modalIn { from { opacity: 0; transform: translateY(14px) scale(.985); } }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 22px 0; }
.modal-title { font-family: var(--font-serif); font-size: 21px; font-weight: 600; letter-spacing: -.01em; }
.modal-sub { font-size: 12.5px; color: var(--ink-3); margin-top: 4px; line-height: 1.5; }
.modal-body { padding: 18px 22px 22px; }
.modal-foot { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 0 22px 22px; flex-wrap: wrap; }
.modal-close { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--ink-3); flex-shrink: 0; }
.modal-close:hover { background: var(--surface-2); color: var(--ink); }
.modal-close svg { width: 17px; height: 17px; }

.book-picker-tabs { display: flex; gap: 4px; padding: 3px; background: var(--surface-2); border-radius: 99px; margin-bottom: 14px; }
.book-picker-tabs button { flex: 1; padding: 7px 10px; border-radius: 99px; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.book-picker-tabs button.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.book-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(108px, 1fr)); gap: 5px; }
.book-btn {
  display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 8px;
  border: 1px solid transparent; text-align: left; transition: background .14s, border-color .14s;
}
.book-btn:hover { background: var(--surface-2); border-color: var(--line); }
.book-btn.active { background: var(--accent-soft); border-color: var(--accent-line); }
.book-btn b { font-size: 12px; font-weight: 600; }
.book-btn span { font-size: 10px; color: var(--ink-4); }
.chapter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(42px, 1fr)); gap: 5px; }
.chapter-btn {
  aspect-ratio: 1; display: grid; place-items: center; border-radius: 8px;
  border: 1px solid var(--line); background: var(--surface-2); font-size: 12px; font-weight: 600;
  color: var(--ink-2); transition: border-color .14s, background .14s, color .14s;
}
.chapter-btn:hover { border-color: var(--accent-line); color: var(--accent); }
.chapter-btn.active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.chapter-btn.read { border-color: color-mix(in srgb, var(--ok) 35%, transparent); }
.chapter-btn.read::after { content: ""; position: absolute; }

.search-results { display: flex; flex-direction: column; gap: 4px; max-height: 52vh; overflow-y: auto; margin: 0 -6px; padding: 0 6px; }
.search-result { display: flex; flex-direction: column; gap: 4px; padding: 10px; border-radius: 8px; text-align: left; border: 1px solid transparent; }
.search-result:hover { background: var(--surface-2); border-color: var(--line); }
.search-result .sr-ref { font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); font-weight: 650; }
.search-result .sr-text { font-family: var(--font-serif); font-size: 13px; line-height: 1.5; color: var(--ink-2); }
.search-result mark { background: var(--accent-soft); color: var(--accent); border-radius: 2px; padding: 0 1px; }

.note-editor { display: flex; flex-direction: column; gap: 12px; }
.note-verse { font-family: var(--font-serif); font-size: 14.5px; line-height: 1.65; color: var(--ink-2); padding: 12px 14px; background: var(--surface-2); border-radius: var(--radius-sm); border-left: 2px solid var(--accent); }
.note-meta { display: flex; align-items: center; justify-content: space-between; font-size: 11px; color: var(--ink-4); }
.theme-picker { display: flex; gap: 6px; flex-wrap: wrap; }
.theme-opt {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 99px;
  border: 1px solid var(--line); font-size: 11.5px; font-weight: 600; color: var(--ink-3);
  transition: border-color .16s, background .16s, color .16s;
}
.theme-opt .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.theme-opt.on { border-color: currentColor; background: color-mix(in srgb, currentColor 12%, transparent); }

/* ---------- Progress ---------- */
.progress-hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; margin-bottom: 20px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; }
.big-stat { padding: 18px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.big-stat .n { font-family: var(--font-serif); font-size: 30px; line-height: 1; }
.big-stat .l { font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-4); margin-top: 7px; font-weight: 650; }
.big-stat .d { font-size: 11px; color: var(--ink-3); margin-top: 4px; }

.heatmap { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 12px); grid-auto-columns: 12px; gap: 3px; overflow-x: auto; padding-bottom: 4px; align-content: start; }
.hm-cell { width: 12px; height: 12px; border-radius: 3px; background: var(--surface-3); }
.hm-cell[data-level="1"] { background: color-mix(in srgb, var(--accent) 28%, var(--surface-3)); }
.hm-cell[data-level="2"] { background: color-mix(in srgb, var(--accent) 50%, var(--surface-3)); }
.hm-cell[data-level="3"] { background: color-mix(in srgb, var(--accent) 72%, var(--surface-3)); }
.hm-cell[data-level="4"] { background: var(--accent); }
.hm-legend { display: flex; align-items: center; gap: 5px; font-size: 10px; color: var(--ink-4); margin-top: 8px; justify-content: flex-end; }

.achievement-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.achievement {
  display: flex; gap: 12px; padding: 13px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface); align-items: flex-start;
  transition: border-color .18s, background .18s;
}
.achievement.locked { opacity: .55; }
.achievement.unlocked { border-color: var(--accent-line); background: linear-gradient(140deg, var(--accent-soft), var(--surface) 70%); }
.ach-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink-4); flex-shrink: 0; }
.achievement.unlocked .ach-ico { color: var(--accent); border-color: var(--accent-line); background: var(--accent-soft); }
.ach-ico svg { width: 18px; height: 18px; }
.ach-name { font-size: 12.5px; font-weight: 650; }
.ach-desc { font-size: 11px; color: var(--ink-3); line-height: 1.45; margin-top: 2px; }
.ach-date { font-size: 10px; color: var(--accent); margin-top: 4px; letter-spacing: .04em; }

.ability-row { display: grid; grid-template-columns: 96px 1fr 42px; gap: 10px; align-items: center; padding: 7px 0; }
.ability-name { font-size: 11.5px; color: var(--ink-3); }
.ability-val { font-size: 11px; color: var(--ink-4); text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Toast ---------- */
.toast-root { position: fixed; z-index: 200; bottom: 22px; right: 22px; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px; padding: 11px 15px;
  background: var(--glass); backdrop-filter: blur(16px); border: 1px solid var(--line-strong);
  border-radius: 99px; box-shadow: var(--shadow-lg); font-size: 12.5px; font-weight: 550;
  animation: toastIn .3s var(--ease-spring) both; max-width: 360px; color: var(--ink);
}
.toast.leaving { animation: toastOut .22s var(--ease) forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.96); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px) scale(.97); } }
.toast .t-ico { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); flex-shrink: 0; }
.toast .t-ico svg { width: 12px; height: 12px; }
.toast.good .t-ico { background: var(--good-soft); color: var(--ok); }
.toast.bad .t-ico { background: var(--bad-soft); color: var(--bad); }

/* ---------- Confetti ---------- */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 210; overflow: hidden; }
.confetti i {
  position: absolute; width: 7px; height: 11px; border-radius: 1px; top: -20px;
  animation: fall linear forwards;
}
@keyframes fall { to { transform: translateY(110vh) rotate(720deg); opacity: .2; } }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .reader-shell { grid-template-columns: minmax(0, 1fr) 260px; }
  .game-shell { grid-template-columns: minmax(0, 1fr) 270px; }
  .journey { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1020px) {
  :root { --rail-w: 76px; }
  .brand-text, .nav-item span:not(.nav-ico), .nav-group-label, .rail-settings span:not(:first-child), .rail-license { display: none; }
  .brand { justify-content: center; padding: 4px 0 18px; }
  .nav-item { justify-content: center; padding: 12px; }
  .nav-item.active::before { left: -16px; }
  .streak-pill { justify-content: center; padding: 10px; }
  .streak-pill span:last-child { display: none; }
  .rail-settings { justify-content: center; }
  .reader-shell, .game-shell { grid-template-columns: minmax(0, 1fr); }
  .reader-side, .game-side { position: static; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
  .hero-grid { grid-template-columns: 1fr; }
  .ring-wrap { display: none; }
  .two-col { grid-template-columns: 1fr; }
  .progress-hero { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .app { grid-template-columns: 1fr; }
  .rail { display: none; }
  .tabbar {
    display: flex; align-items: stretch; justify-content: space-around;
    height: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    border-top: 1px solid var(--line); background: var(--glass);
    backdrop-filter: blur(18px); position: relative; z-index: 30;
  }
  .tabbar a {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    color: var(--ink-4); font-size: 9.5px; letter-spacing: .06em; text-transform: uppercase; font-weight: 650;
    transition: color .18s;
  }
  .tabbar a svg { width: 20px; height: 20px; }
  .tabbar a.active { color: var(--accent); }
  .tabbar a.active svg { filter: drop-shadow(0 0 6px rgba(229, 181, 103, .5)); }
  .tabbar em { font-style: normal; }
  .topbar { min-height: 62px; padding: 10px 16px; }
  .mini-stat .mini-label { display: none; }
  .mini-stat { padding: 6px 9px; }
  #view { padding: 18px 16px calc(24px + env(safe-area-inset-bottom, 0px)); }
  .hero { padding: 22px 18px; border-radius: var(--radius); }
  .hero-title { font-size: 30px; }
  .hero-meta { gap: 14px; }
  .journey { grid-template-columns: 1fr 1fr; gap: 9px; }
  .journey-step { min-height: 132px; padding: 13px; }
  .vault-stats { grid-template-columns: 1fr 1fr; }
  .vault-grid { grid-template-columns: 1fr; }
  .reader-toolbar { position: static; }
  .chapter-card { padding: 24px 18px 34px; border-radius: var(--radius); }
  .verse-flow { font-size: var(--reader-size-mobile, 18px); }
  .selection-bar { bottom: calc(var(--tab-h) + 12px + env(safe-area-inset-bottom, 0px)); }
  .modal { max-height: 92vh; border-radius: var(--radius) var(--radius) 0 0; }
  .scrim { align-items: flex-end; padding: 0; }
  .modal.wide, .modal.narrow { width: 100%; }
  .toast-root { left: 12px; right: 12px; bottom: calc(var(--tab-h) + 12px); align-items: center; }
  .toast { max-width: 100%; }
  .board-frame { padding: 6px; border-radius: var(--radius); }
  .game-head { gap: 10px; }
  .game-name { font-size: 20px; }
  .game-badge { width: 38px; height: 38px; }
  .game-side { grid-template-columns: 1fr; }
  .reader-side { grid-template-columns: 1fr; }
  .page-title { font-size: 27px; }
}
@media (max-width: 400px) {
  .journey { grid-template-columns: 1fr; }
  .journey-step { min-height: 0; }
  .vault-stats { grid-template-columns: 1fr 1fr; }
  .hero-meta { gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

/* ---------- Reader font scaling ---------- */
[data-reader-size="sm"] { --reader-size: 17px; --reader-leading: 1.75; --reader-size-mobile: 16px; }
[data-reader-size="md"] { --reader-size: 19px; --reader-leading: 1.82; --reader-size-mobile: 18px; }
[data-reader-size="lg"] { --reader-size: 22px; --reader-leading: 1.9; --reader-size-mobile: 20px; }
[data-reader-size="xl"] { --reader-size: 25px; --reader-leading: 1.95; --reader-size-mobile: 22px; }

/* ---------- Misc ---------- */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.divider { height: 1px; background: var(--line); margin: 16px 0; }
.kbd {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px;
  border-radius: 4px; border: 1px solid var(--line-strong); background: var(--surface-2);
  font-family: var(--font-mono); font-size: 10px; color: var(--ink-3);
}
.insight {
  padding: 14px 15px; border-radius: var(--radius-sm); background: var(--surface-2);
  border: 1px solid var(--line); font-size: 12.5px; line-height: 1.65; color: var(--ink-2);
}
.insight b { color: var(--accent); font-weight: 650; }

/* ---------- Verse moments (reading, not quizzing) ---------- */
.verse-moment { display: flex; flex-direction: column; gap: 18px; }
.vm-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.vm-kicker {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 10px; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; color: var(--accent);
}
.vm-kicker svg { width: 14px; height: 14px; }
.vm-verse {
  font-family: var(--font-serif); font-size: clamp(19px, 2.5vw, 25px); line-height: 1.62;
  color: var(--ink); letter-spacing: -.005em; margin: 0;
  padding: 22px 24px; border-radius: var(--radius);
  background: linear-gradient(160deg, var(--accent-soft), var(--surface-2) 70%);
  border-left: 4px solid var(--accent);
}
.vm-ref { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-4); font-weight: 600; }
.vm-note {
  display: flex; align-items: flex-start; gap: 8px;
  font-size: 13px; line-height: 1.6; color: var(--ink-2);
  padding: 11px 13px; border-radius: var(--radius-sm);
  background: var(--surface-2); border: 1px solid var(--line);
}
.vm-note svg { width: 15px; height: 15px; color: var(--accent); flex-shrink: 0; margin-top: 1px; }
.vm-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.vm-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

/* ---------- Floating score pops ---------- */
.float-pop {
  position: absolute; z-index: 30; transform: translate(-50%, -50%);
  font-family: var(--font-ui); font-weight: 800; font-size: 16px;
  color: var(--accent); text-shadow: 0 2px 10px rgba(0, 0, 0, .5);
  pointer-events: none; white-space: nowrap;
  animation: floatUp 1s var(--ease) forwards;
}
.float-pop.good { color: var(--ok); }
.float-pop.leaving { opacity: 0; }
@keyframes floatUp {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.7); }
  24% { opacity: 1; transform: translate(-50%, -84%) scale(1.08); }
  100% { opacity: 0; transform: translate(-50%, -168%) scale(1); }
}

/* ---------- Star ratings ---------- */
.star-row { display: inline-flex; gap: 4px; }
.star-mark { color: var(--surface-3); display: inline-grid; place-items: center; }
.star-mark svg { width: 26px; height: 26px; }
.star-mark.on { color: var(--gold); animation: starPop .5s var(--ease-spring) both; }
.star-row.sm { gap: 3px; }
.star-row.sm .star-mark svg { width: 15px; height: 15px; }
@keyframes starPop { 0% { transform: scale(.4) rotate(-18deg); opacity: 0; } 70% { transform: scale(1.18) rotate(6deg); } 100% { transform: scale(1) rotate(0); opacity: 1; } }
.best-stars { display: inline-flex; align-items: center; gap: 8px; margin-top: 6px; }

/* ---------- Game HUD extras ---------- */
.hud-pill.hud-score { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent); }
.hud-pill.hud-flow.on {
  border-color: var(--accent-line);
  background: linear-gradient(120deg, var(--accent-soft), rgba(87, 199, 187, .16));
  animation: flowPulse 1.4s ease-in-out infinite;
}
.hud-pill.hud-flow.on svg { color: var(--sky); }
@keyframes flowPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(229, 181, 103, .35); } 50% { box-shadow: 0 0 0 5px rgba(229, 181, 103, 0); } }
.board-overlay .star-row { margin-bottom: 2px; }
.ov-score { font-size: 13px !important; color: var(--ink-2) !important; }

/* ---------- Translation banner ---------- */
.translation-banner {
  display: flex; align-items: center; gap: 9px;
  padding: 10px 13px; margin-bottom: 14px; border-radius: var(--radius-sm);
  font-size: 12.5px; line-height: 1.5;
  background: var(--accent-soft); border: 1px solid var(--accent-line); color: var(--ink-2);
}
.translation-banner svg { width: 15px; height: 15px; color: var(--accent); flex-shrink: 0; }
.translation-banner[data-t="error"] { background: var(--bad-soft); border-color: color-mix(in srgb, var(--bad) 34%, transparent); }
.translation-banner[data-t="error"] svg { color: var(--bad); }
.link-btn {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--accent); font: inherit; font-weight: 650;
  text-decoration: underline; text-underline-offset: 3px;
}
.link-btn:hover { color: var(--ink); }

/* ---------- Read pill ---------- */
.read-pill {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 10.5px; font-weight: 650; color: var(--ink-3);
  padding: 3px 9px; border-radius: 99px;
  background: var(--surface-2); border: 1px solid var(--line);
}
.read-pill svg { width: 12px; height: 12px; color: var(--accent); }

/* ---------- Bible settings pane ---------- */
.bible-vers { display: flex; flex-direction: column; gap: 8px; }
.bible-ver {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 13px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface);
}
.bible-ver.on { border-color: var(--accent-line); background: linear-gradient(140deg, var(--accent-soft), var(--surface)); }
.bible-ver .grow { min-width: 0; }
.bible-ver .ach-desc { font-size: 11.5px; }
