:root {
  --bg: #14110e;
  --bg-raise: #1c1814;
  --bg-card: #221c17;
  --line: #3a322a;
  --gold: #c4a574;
  --gold-dim: #8a7352;
  --ink: #efe6d8;
  --muted: #b7aa96;
  --faint: #8a7d6b;
  --shadow: 0 18px 40px rgba(0,0,0,.35);
  --radius: 18px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  background: #070605;
  color: var(--ink);
  font-family: "Source Sans 3", system-ui, sans-serif;
  min-height: 100%;
}
body { display: flex; justify-content: center; padding: 12px; }
.device {
  width: min(480px, 100%);
  min-height: calc(100vh - 24px);
  background: radial-gradient(1200px 400px at 50% -10%, rgba(196,165,116,.08), transparent 50%), var(--bg);
  border: 1px solid #2a241e;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--shadow);
  position: relative;
  display: flex;
  flex-direction: column;
}
header.appbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px 10px;
}
header .ghost {
  color: var(--gold);
  font-family: "Cormorant Garamond", serif;
  font-size: 22px;
  letter-spacing: .04em;
  background: none;
  border: 0;
  cursor: pointer;
}
header button.ghost:last-child { color: var(--faint); font-size: 15px; font-family: inherit; }
main { flex: 1; padding: 8px 16px 24px; overflow: auto; }
.screen { display: none; animation: rise .35s ease; }
.screen.active { display: block; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.kicker {
  color: var(--gold-dim);
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
h1, h2 { font-family: "Cormorant Garamond", serif; font-weight: 600; line-height: 1.15; }
h1 { font-size: 34px; margin-bottom: 8px; }
h2 { font-size: 26px; margin-bottom: 6px; }
p.lede { color: var(--muted); line-height: 1.5; margin-bottom: 18px; }
.continue {
  background: linear-gradient(180deg, #2a231c, #1d1915);
  border: 1px solid #4a3d2e;
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
}
.continue .ref { font-family: "Cormorant Garamond", serif; font-size: 24px; color: var(--ink); }
.continue .light { color: var(--muted); font-size: 14px; font-style: italic; margin: 8px 0 14px; line-height: 1.45; }
button.primary, button.secondary { font-family: inherit; cursor: pointer; }
button.primary {
  width: 100%; background: var(--gold); color: #1a140e; border: 0;
  border-radius: 12px; padding: 12px 14px; font-weight: 600; font-size: 15px;
}
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 22px; }
button.secondary {
  background: var(--bg-card); color: var(--ink); border: 1px solid var(--line);
  border-radius: 12px; padding: 14px 12px; font-weight: 500;
}
.quiet-link { display: block; text-align: center; color: var(--gold-dim); font-size: 14px; padding: 8px; cursor: pointer; }
.book-list button, .unit {
  width: 100%; text-align: left; background: var(--bg-card); border: 1px solid var(--line);
  color: var(--ink); border-radius: 14px; padding: 14px; margin-bottom: 8px; cursor: pointer;
}
.book-list button strong, .unit strong { display: block; font-family: "Cormorant Garamond", serif; font-size: 20px; font-weight: 600; }
.unit span, .book-list em { display: block; color: var(--muted); font-size: 13px; font-style: normal; margin-top: 4px; line-height: 1.4; }
.unit.current { border-color: var(--gold-dim); }
.chip-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip-grid button {
  background: var(--bg-card); border: 1px solid var(--line); color: var(--ink);
  border-radius: 10px; padding: 10px 14px; font-size: 14px; cursor: pointer; min-width: 44px;
}
.passage { font-family: "Cormorant Garamond", serif; font-size: 21px; line-height: 1.5; color: #f3eadc; }
.passage p { margin-bottom: 10px; }
.passage sup { font-family: "Source Sans 3", sans-serif; font-size: 11px; color: var(--gold-dim); margin-right: 4px; cursor: pointer; }
.passage .pinned { background: rgba(196,165,116,.16); border-radius: 4px; }
.deskLink { margin-top: 16px; }
.deskLink a.unitCta {
  display: block; text-align: center; background: var(--gold); color: #1a140e;
  border-radius: 12px; padding: 12px; font-weight: 600; text-decoration: none; cursor: pointer;
}
.notWritten { color: var(--faint); font-style: italic; font-size: 14px; padding: 10px 0; }
.steps { display: flex; gap: 6px; overflow-x: auto; padding: 12px 0 8px; margin-top: 8px; }
.steps button {
  flex: 0 0 auto; border: 1px solid var(--line); background: var(--bg-raise); color: var(--muted);
  border-radius: 999px; padding: 7px 12px; font-size: 13px; cursor: pointer;
}
.steps button.on { background: #2c241c; color: var(--gold); border-color: var(--gold-dim); }
.sheet { background: var(--bg-card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; margin-top: 6px; }
.sheet h3 { font-family: "Cormorant Garamond", serif; color: var(--gold); font-size: 20px; margin-bottom: 8px; }
.sheet p { color: var(--muted); line-height: 1.55; font-size: 15px; margin-bottom: 10px; }
.datechip {
  display: inline-block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--gold); border: 1px solid var(--gold-dim); border-radius: 999px; padding: 3px 8px; margin-bottom: 10px;
}
.doors { display: grid; gap: 8px; }
.doors button {
  background: #1a1713; border: 1px solid var(--line); color: var(--ink);
  border-radius: 12px; padding: 12px; text-align: left; cursor: pointer; width: 100%;
}
.doors button small { display: block; color: var(--faint); margin-top: 4px; }
.live-out { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); color: var(--ink); line-height: 1.5; }
.back { background: none; border: 0; color: var(--gold-dim); font-size: 13px; margin-bottom: 12px; cursor: pointer; }
.searchbox {
  width: 100%; background: var(--bg-card); border: 1px solid var(--line); color: var(--ink);
  border-radius: 12px; padding: 12px 14px; font-size: 15px; margin-bottom: 14px; font-family: inherit;
}
footer.hint { text-align: center; color: #6d6254; font-size: 12px; padding: 0 16px 14px; }
