/* Textbound site. Candlelight, wet stone, gold lamps. */
:root {
  --bg: #12100f;
  --bg-2: #1a1716;
  --surface: #221e1c;
  --surface-2: #2b2624;
  --text: #efe9e3;
  --muted: #a89f97;
  --faint: #6f6761;
  --border: #3a3330;
  --gold: #d9a95b;
  --gold-soft: rgba(217, 169, 91, 0.14);
  --wine: #9b3150;
  --wine-soft: rgba(155, 49, 80, 0.22);
  --bubble-him: #2b2624;
  --bubble-you: #6e2239;
  --crisis-bg: #2a1c1a;
  --crisis-border: #6b3b33;
  --display: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--body);
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--gold); text-underline-offset: 3px; }
p, li { overflow-wrap: anywhere; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: rgba(18, 16, 15, 0.82);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(58, 51, 48, 0.6);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.wordmark {
  font-family: var(--display); font-weight: 600; font-size: 1.55rem; letter-spacing: 0.01em;
  color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 10px;
}
.wordmark .flame { width: 14px; height: 20px; }
.nav-links { display: flex; align-items: center; gap: 22px; font-size: 0.92rem; }
.nav-links a:not(.btn) { color: var(--muted); text-decoration: none; }
.nav-links a:not(.btn):hover { color: var(--text); }
.nav-links .hide-sm { display: none; }
@media (min-width: 720px) { .nav-links .hide-sm { display: inline; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 0.95rem/1 var(--body);
  padding: 13px 20px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--gold); color: #1a1310; text-decoration: none; white-space: nowrap;
  transition: transform .15s ease, background .15s ease;
}
.btn:hover { background: #e6b96d; transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--surface); }
.btn-sm { padding: 9px 14px; font-size: 0.85rem; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: 56px 0 72px;
  background:
    radial-gradient(600px 420px at 78% 30%, rgba(217, 169, 91, 0.16), transparent 70%),
    radial-gradient(700px 500px at 10% 0%, rgba(155, 49, 80, 0.20), transparent 70%);
}
.hero .wrap { display: grid; gap: 48px; align-items: center; }
@media (min-width: 900px) {
  .hero { padding: 88px 0 104px; }
  .hero .wrap { grid-template-columns: 1.1fr 0.9fr; gap: 64px; }
}
.eyebrow {
  font-size: 0.78rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold);
  margin: 0 0 16px;
}
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: -0.01em; }
.hero h1 { font-size: clamp(2.7rem, 7vw, 4.6rem); line-height: 1.02; margin: 0 0 20px; }
.hero h1 em { font-style: italic; color: var(--gold); font-weight: 500; }
.lede { font-size: 1.15rem; color: var(--muted); max-width: 34em; margin: 0 0 28px; }
.lede strong { color: var(--text); font-weight: 500; }

.notify { display: flex; flex-wrap: wrap; gap: 10px; max-width: 460px; }
.notify input {
  flex: 1 1 220px; min-width: 0;
  font: 400 1rem var(--body); color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
  padding: 13px 18px;
}
.notify input:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: transparent; }
.notify-note { font-size: 0.82rem; color: var(--faint); margin: 12px 0 0; }
.notify-msg { font-size: 0.9rem; color: var(--gold); margin: 12px 0 0; min-height: 1.4em; }

/* ---------- phone ---------- */
.phone {
  width: min(340px, 100%); margin: 0 auto;
  background: #0b0a09; border-radius: 44px; padding: 12px;
  box-shadow: 0 0 0 1px #2f2a27, 0 40px 80px -20px rgba(0,0,0,.7), 0 0 120px -30px rgba(217,169,91,.35);
  position: relative;
}
.screen {
  background: linear-gradient(180deg, #171413 0%, #12100f 100%);
  border-radius: 34px; overflow: hidden; height: 640px; display: flex; flex-direction: column;
}
.island { width: 96px; height: 26px; background: #000; border-radius: 20px; margin: 10px auto 0; }
.chat-head {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px 12px;
  border-bottom: 1px solid #2a2523;
}
.avatar {
  width: 36px; height: 36px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 35% 30%, #5a4637, #2a201b 70%);
  display: grid; place-items: center; font-family: var(--display); font-weight: 600; color: var(--gold);
  box-shadow: 0 0 0 1px rgba(217,169,91,.35);
}
.chat-head .who { line-height: 1.2; }
.chat-head .name { font-weight: 600; font-size: 0.95rem; }
.chat-head .ai { font-size: 0.72rem; color: var(--muted); }
.daychip {
  margin-left: auto; font-size: 0.7rem; color: var(--gold); border: 1px solid rgba(217,169,91,.4);
  border-radius: 999px; padding: 3px 9px; white-space: nowrap;
}
.thread { flex: 1; padding: 14px 14px 10px; display: flex; flex-direction: column; gap: 7px; overflow: hidden; }
.sys {
  align-self: center; font-size: 0.68rem; color: var(--faint); text-align: center;
  background: #1d1a18; border-radius: 10px; padding: 5px 10px; margin-bottom: 4px;
}
.narr { font-family: var(--display); font-style: italic; color: var(--muted); font-size: 0.95rem; line-height: 1.35; margin: 2px 4px 4px; }
.b {
  max-width: 82%; padding: 8px 12px; border-radius: 18px; font-size: 0.86rem; line-height: 1.38;
  opacity: 0; transform: translateY(6px); animation: pop .4s ease forwards;
}
.b.him { background: var(--bubble-him); align-self: flex-start; border-bottom-left-radius: 6px; }
.b.you { background: var(--bubble-you); align-self: flex-end; border-bottom-right-radius: 6px; }
.b.recall { box-shadow: inset 0 0 0 1px rgba(217,169,91,.45); }
.recall-tag { display: block; font-size: 0.66rem; color: var(--gold); margin-top: 3px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; padding: 0 14px 14px; }
.chip {
  font-size: 0.74rem; padding: 6px 10px; border-radius: 999px;
  border: 1px solid rgba(217,169,91,.45); color: var(--gold); background: rgba(217,169,91,.06);
}
@keyframes pop { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .b { animation: none; opacity: 1; transform: none; } }

.toast {
  position: absolute; left: -18px; right: 22px; top: -26px;
  background: rgba(46, 41, 38, 0.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-radius: 18px; padding: 10px 12px; display: flex; gap: 10px; align-items: center;
  box-shadow: 0 20px 40px -10px rgba(0,0,0,.6);
  opacity: 0; animation: pop .5s ease 3.2s forwards;
}
@media (max-width: 420px) { .toast { left: 6px; right: 6px; } }
.toast .icon { width: 30px; height: 30px; border-radius: 8px; background: var(--bg); display: grid; place-items: center; flex: none; }
.toast .t { font-size: 0.78rem; line-height: 1.3; }
.toast .t b { display: block; font-weight: 600; }
.toast .t span { color: var(--muted); }
.toast .when { margin-left: auto; align-self: flex-start; font-size: 0.68rem; color: var(--faint); }

/* ---------- sections ---------- */
section { padding: 80px 0; }
.section-alt { background: var(--bg-2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head h2 { font-size: clamp(2rem, 4.5vw, 2.9rem); line-height: 1.08; margin: 0 0 14px; }
.section-head p { color: var(--muted); margin: 0; font-size: 1.05rem; }

/* premise */
.premise { display: grid; gap: 32px; align-items: start; }
@media (min-width: 900px) { .premise { grid-template-columns: 0.9fr 1.1fr; gap: 56px; } }
.portrait {
  border-radius: 20px; overflow: hidden; border: 1px solid var(--border);
  background:
    radial-gradient(240px 200px at 70% 25%, rgba(217,169,91,.35), transparent 70%),
    linear-gradient(180deg, #2a221d 0%, #15110f 100%);
  aspect-ratio: 4 / 5; position: relative; display: flex; align-items: flex-end;
}
.portrait svg.scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.portrait .cap { position: relative; padding: 22px; width: 100%; background: linear-gradient(0deg, rgba(12,10,9,.92), transparent); }
.portrait .cap h3 { margin: 0; font-size: 2rem; }
.portrait .cap p { margin: 2px 0 0; color: var(--muted); font-size: 0.9rem; }
.season-title { font-family: var(--display); font-style: italic; color: var(--gold); font-size: 1.3rem; margin: 0 0 8px; }
.premise-copy p { color: var(--muted); }
.premise-copy p strong { color: var(--text); font-weight: 500; }
.quote {
  font-family: var(--display); font-size: 1.6rem; line-height: 1.3; font-style: italic;
  border-left: 2px solid var(--gold); padding: 4px 0 4px 20px; margin: 28px 0; color: var(--text);
}
.quote cite { display: block; font-family: var(--body); font-style: normal; font-size: 0.82rem; color: var(--faint); margin-top: 8px; }
.tropes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; padding: 0; list-style: none; }
.tropes li { font-size: 0.82rem; padding: 6px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); color: var(--muted); }

/* steps */
.steps { display: grid; gap: 16px; }
@media (min-width: 800px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 26px; }
.step .num { font-family: var(--display); font-size: 2.4rem; color: var(--gold); line-height: 1; }
.step h3 { font-size: 1.5rem; margin: 12px 0 8px; }
.step p { color: var(--muted); margin: 0; font-size: 0.97rem; }

/* knows */
.knows-grid { display: grid; gap: 40px; align-items: center; }
@media (min-width: 900px) { .knows-grid { grid-template-columns: 1fr 1fr; gap: 64px; } }
.knows-card { background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 22px; max-width: 440px; width: 100%; }
.knows-card .top { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 14px; }
.knows-card h3 { margin: 0; font-size: 1.5rem; }
.knows-card .top span { font-size: 0.78rem; color: var(--faint); }
.mem { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--border); }
.mem .k { font-size: 0.72rem; color: var(--faint); text-transform: uppercase; letter-spacing: 0.08em; }
.mem .v { font-size: 0.96rem; }
.mem .acts { margin-left: auto; display: flex; gap: 6px; flex: none; }
.mem .acts button {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border); background: transparent;
  color: var(--muted); cursor: pointer; display: grid; place-items: center; padding: 0;
}
.mem .acts button:hover { color: var(--text); background: var(--surface-2); }
.mem.gone { opacity: 0; height: 0; padding: 0; overflow: hidden; transition: all .3s ease; }
.forget { margin-top: 14px; width: 100%; background: transparent; border: 1px solid var(--wine); color: #e88aa5; border-radius: 12px; padding: 11px; font: 600 0.88rem var(--body); cursor: pointer; }
.forget:hover { background: var(--wine-soft); }
.checks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.checks li { display: flex; gap: 12px; color: var(--muted); }
.checks li svg { flex: none; margin-top: 4px; color: var(--gold); }
.checks li strong { color: var(--text); font-weight: 500; }

/* week */
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; margin-top: 8px; }
.night { text-align: center; padding: 14px 4px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.night .d { font-family: var(--display); font-size: 1.6rem; line-height: 1; }
.night .l { font-size: 0.66rem; color: var(--faint); margin-top: 6px; text-transform: uppercase; letter-spacing: 0.08em; }
.night.end { background: var(--gold-soft); border-color: rgba(217,169,91,.5); }
.night.end .d { color: var(--gold); }
.week-note { color: var(--muted); margin-top: 22px; max-width: 640px; }

/* coming next */
.cards { display: grid; gap: 16px; }
@media (min-width: 800px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.card {
  border-radius: 20px; padding: 24px; border: 1px solid var(--border); background: var(--surface);
  display: flex; flex-direction: column; gap: 10px; position: relative; overflow: hidden;
}
.card.live { border-color: rgba(217,169,91,.55); background: linear-gradient(180deg, rgba(217,169,91,.10), var(--surface) 60%); }
.card .tag { font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.card.live .tag { color: var(--gold); }
.card h3 { margin: 0; font-size: 1.7rem; line-height: 1.1; }
.card .tl { font-family: var(--display); font-style: italic; font-size: 1.15rem; color: var(--text); margin: 0; }
.card p { margin: 0; color: var(--muted); font-size: 0.93rem; }
.card .foot { margin-top: auto; padding-top: 10px; display: flex; align-items: center; gap: 10px; font-size: 0.82rem; color: var(--faint); }
.card .lock { width: 14px; height: 14px; }

/* safety strip */
.promises { display: grid; gap: 14px; }
@media (min-width: 700px) { .promises { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .promises { grid-template-columns: repeat(4, 1fr); } }
.promise { padding: 22px; border-radius: 18px; border: 1px solid var(--border); background: var(--bg); }
.promise h3 { font-size: 1.3rem; margin: 0 0 6px; }
.promise p { margin: 0; color: var(--muted); font-size: 0.93rem; }

/* faq */
.faq { max-width: 760px; }
.faq details { border-top: 1px solid var(--border); padding: 18px 0; }
.faq details:last-child { border-bottom: 1px solid var(--border); }
.faq summary { cursor: pointer; font-weight: 500; font-size: 1.05rem; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--gold); font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--muted); margin: 10px 0 0; }

/* final cta */
.final { text-align: center; padding: 96px 0; background: radial-gradient(600px 300px at 50% 100%, rgba(217,169,91,.16), transparent 70%); }
.final h2 { font-size: clamp(2.2rem, 5vw, 3.4rem); margin: 0 0 14px; line-height: 1.05; }
.final p { color: var(--muted); margin: 0 auto 28px; max-width: 520px; }
.final .notify { margin: 0 auto; }

/* footer */
.footer { border-top: 1px solid var(--border); padding: 40px 0 48px; font-size: 0.88rem; color: var(--faint); }
.footer .wrap { display: grid; gap: 18px; }
.footer .minors { color: var(--muted); }
.footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.footer nav a { color: var(--muted); text-decoration: none; }
.footer nav a:hover { color: var(--text); }

/* ---------- legal / doc pages ---------- */
.doc { max-width: 720px; margin: 0 auto; padding: 48px 16px 80px; }
.doc header p { color: var(--muted); margin-top: 6px; }
.doc h1 { font-size: clamp(2.2rem, 6vw, 3rem); line-height: 1.1; margin: 0; }
.doc h2 { font-size: 1.6rem; margin: 44px 0 8px; padding-top: 14px; border-top: 1px solid var(--border); }
.doc h3 { font-family: var(--body); font-size: 1.02rem; font-weight: 600; margin: 22px 0 4px; letter-spacing: 0; }
.doc p, .doc li { color: #d8d1ca; }
.doc ul, .doc ol { padding-left: 1.25rem; }
.doc li { margin: 5px 0; }
.doc .note { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 14px 16px; }
.doc .crisis { background: var(--crisis-bg); border: 1px solid var(--crisis-border); border-radius: 14px; padding: 18px 20px; margin: 28px 0 8px; }
.doc .crisis h2 { border: 0; margin: 0 0 6px; padding: 0; }
.doc .crisis ul { list-style: none; padding: 0; margin: 8px 0 0; }
.doc nav.toc { margin: 18px 0 0; font-size: 0.92rem; }
.doc nav.toc a { display: inline-block; margin: 3px 14px 3px 0; }
.table-wrap { overflow-x: auto; margin: 14px 0; border: 1px solid var(--border); border-radius: 12px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 0.9rem; min-width: 520px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--border); color: #d8d1ca; }
.doc th { background: var(--surface); color: var(--text); font-weight: 600; }
.doc tr:last-child td { border-bottom: 0; }
.todo { color: var(--gold); background: var(--gold-soft); border-radius: 4px; padding: 0 4px; }
