/* booknookd.com: the app's true-black look with its purple accent.
   Base styles serve every page; .home / .guide add the landing pages. */
:root {
  --bg: #000;
  --surface: #111113;
  --surface-2: #17171a;
  --text: #f4f4f5;
  --dim: #b4b4bb;
  --muted: #8b8b94;
  --line: #222226;
  --accent: #b9a6ff;
  --accent-hover: #cdbfff;
  --radius: 14px;
  --max: 1120px;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ── Legal pages (privacy, terms, delete account, confirmed) ─────────────── */
main { max-width: 720px; margin: 0 auto; padding: 32px 20px 64px; }
header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 28px; }
.wordmark { font-size: 26px; font-weight: 800; letter-spacing: -0.8px; color: var(--text); text-decoration: none; }
nav a { color: var(--dim); margin-left: 14px; text-decoration: none; font-size: 15px; }
nav a:hover { color: var(--text); }
h1 { font-size: 30px; line-height: 1.2; margin: 8px 0 6px; letter-spacing: -0.4px; }
h2 { font-size: 20px; margin: 34px 0 8px; }
p, li { color: var(--dim); }
strong { color: var(--text); }
.updated { color: var(--muted); font-size: 14px; margin-bottom: 24px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; margin: 18px 0; }
table { width: 100%; border-collapse: collapse; margin: 10px 0; font-size: 15px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--text); font-weight: 600; }
td { color: var(--dim); }
footer { margin-top: 48px; color: var(--muted); font-size: 14px; border-top: 1px solid var(--line); padding-top: 18px; }
footer a { color: var(--muted); }

/* ── Landing pages: shared pieces ─────────────────────────────────────────── */
.home main, .guide main { max-width: none; padding: 0; }
.guide main { overflow-x: clip; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

.site-header { position: sticky; top: 0; z-index: 20; margin: 0; display: block; background: rgba(0, 0, 0, .72); -webkit-backdrop-filter: saturate(140%) blur(14px); backdrop-filter: saturate(140%) blur(14px); border-bottom: 1px solid rgba(255, 255, 255, .06); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.site-header .wordmark { font-size: 22px; }
.site-header nav { display: flex; align-items: center; gap: 6px; }
.site-header nav a { margin: 0; padding: 8px 12px; font-size: 14.5px; color: var(--dim); border-radius: 8px; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: var(--text); text-decoration: none; }
.site-header nav a.btn, .site-header nav a.btn:hover { color: #0d0b14; margin-left: 6px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 24px; border: 0; border-radius: 999px; background: var(--accent); color: #0d0b14; font: 700 16px/1 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s ease, transform .15s ease; }
.btn:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn.small { height: 38px; padding: 0 16px; font-size: 14px; }
.btn.ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px #34343a; }
.btn.ghost:hover { box-shadow: inset 0 0 0 1px var(--text); background: transparent; }

/* A screen on its own, no device outline (#136): the app's true black
   meets the page's black, so only the content shows. */
.phone { margin: 0; border-radius: 14px; overflow: hidden; background: #000; }
.phone img { display: block; width: 100%; height: auto; }
.sheet-shot { margin: 0; border-radius: 14px; overflow: hidden; }
.sheet-shot img { display: block; width: 100%; height: auto; }

.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin: 0 0 14px; }

/* ── Home ─────────────────────────────────────────────────────────────────── */
.hero { position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: -20% -10% auto; height: 120%; background: radial-gradient(600px 420px at 72% 38%, rgba(140, 110, 255, .22), transparent 70%), radial-gradient(500px 360px at 18% 70%, rgba(80, 60, 160, .16), transparent 70%); pointer-events: none; }
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; min-height: calc(100vh - 64px); max-height: 980px; padding-top: 40px; padding-bottom: 40px; }
.home h1, .guide h1 { font: 700 clamp(40px, 6vw, 72px)/1.04 var(--serif); letter-spacing: -1.2px; margin: 0 0 20px; }
.lede { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.6; color: var(--dim); max-width: 520px; margin: 0 0 32px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.platforms { margin: 22px 0 0; font-size: 14px; color: var(--muted); }
/* Fits the whole screen in the first screen on laptops: width = height × 720/1450. */
.hero-phone { justify-self: center; width: clamp(240px, calc((100vh - 170px) * .4966), 330px); }

.tiles { padding: 72px 0 32px; }
.section-title { font: 700 clamp(28px, 3.4vw, 40px)/1.15 var(--serif); letter-spacing: -.5px; margin: 0 0 10px; }
.section-sub { color: var(--dim); font-size: 17px; margin: 0 0 32px; max-width: 560px; }
.tile-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.tile { display: flex; gap: 16px; align-items: flex-start; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); text-decoration: none; transition: border-color .15s ease, background .15s ease, transform .15s ease; }
.tile svg { flex: none; width: 30px; height: 30px; fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; margin-top: 2px; }
.tile b { display: block; font-size: 16px; margin-bottom: 4px; }
.tile span { display: block; color: var(--dim); font-size: 14.5px; line-height: 1.5; }
.tile .go { display: inline-block; margin-top: 10px; color: var(--accent); font-size: 14px; font-weight: 600; font-style: normal; }
.tile .go::after { content: " →"; }
.tile:hover { border-color: rgba(185, 166, 255, .55); background: var(--surface-2); transform: translateY(-2px); text-decoration: none; }

.gallery { padding: 56px 0 24px; }
.strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 22px; align-items: start; }
.strip .item:nth-child(even) { margin-top: 48px; }
.strip figcaption { margin-top: 14px; text-align: center; color: var(--muted); font-size: 14px; }
.strip figure.item { margin: 0; }

.promise { padding: 72px 0 96px; }
.promise .card-wide { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 34px 36px; }
.promise h2 { font: 700 26px/1.25 var(--serif); margin: 0 0 6px; }
.promise p { margin: 0; color: var(--dim); }

/* ── How it works ─────────────────────────────────────────────────────────── */
.intro { position: relative; text-align: center; padding: 80px 0 28px; }
/* Subtle purple accents through the guide (#140): a soft glow, never a colour block. */
.intro::before { content: ""; position: absolute; inset: 0; background: radial-gradient(520px 260px at 50% 30%, rgba(140, 110, 255, .14), transparent 70%); pointer-events: none; }
.intro .wrap { position: relative; }
.intro .lede { margin: 0 auto; max-width: 640px; }
.toc { position: sticky; top: 64px; z-index: 10; background: rgba(0, 0, 0, .82); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.toc ul { display: flex; gap: 6px; list-style: none; margin: 0 auto; padding: 10px 24px; max-width: var(--max); overflow-x: auto; scrollbar-width: none; }
.toc ul::-webkit-scrollbar { display: none; }
.toc a { display: block; white-space: nowrap; padding: 7px 14px; border-radius: 999px; color: var(--dim); text-decoration: none; font-size: 14px; background: var(--surface); border: 1px solid var(--line); }
.toc a:hover, .toc a.on { color: #0d0b14; background: var(--accent); border-color: var(--accent); }

.feature { position: relative; padding: 88px 0; scroll-margin-top: 48px; }
.feature::after { content: ""; position: absolute; left: 50%; bottom: 0; width: min(560px, 70%); height: 1px; transform: translateX(-50%); background: linear-gradient(90deg, transparent, rgba(185, 166, 255, .22), transparent); }
.feature .wrap { display: grid; grid-template-columns: 1fr 1.05fr; gap: 64px; align-items: center; }
.feature.flip .text { order: 2; }
.feature h2 { font: 700 clamp(28px, 3.2vw, 38px)/1.15 var(--serif); letter-spacing: -.4px; margin: 0 0 14px; }
.feature p { font-size: 17px; line-height: 1.7; color: var(--dim); margin: 0 0 14px; max-width: 520px; }
.feature b { color: var(--text); font-weight: 600; }
.shots { position: relative; display: flex; justify-content: center; gap: 22px; }
.shots::before { content: ""; position: absolute; inset: -22% -30%; z-index: -1; background: radial-gradient(closest-side, rgba(140, 110, 255, .16), transparent); pointer-events: none; }
.feature .wrap { position: relative; z-index: 0; }
.shots .phone { width: min(290px, 100%); }
.shots.two .phone { width: min(250px, 48%); }
.shots.two .phone:last-child { margin-top: 56px; }
.shots.three .phone { width: min(190px, 31%); }
.shots.three .phone:nth-child(2) { margin-top: 40px; }
.shots .sheet-shot { width: min(440px, 100%); }

.closing { text-align: center; padding: 96px 0 112px; background: radial-gradient(600px 300px at 50% 60%, rgba(140, 110, 255, .12), transparent 70%); }
.closing .lede { margin: 0 auto 28px; }

/* ── Footer ───────────────────────────────────────────────────────────────── */
.site-footer { margin: 0; padding: 28px 0 40px; border-top: 1px solid var(--line); }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; align-items: center; }
.site-footer nav a { margin: 0 18px 0 0; font-size: 14px; color: var(--dim); }
.site-footer p { margin: 0; font-size: 13px; color: var(--muted); }

/* ── Beta invite dialog ───────────────────────────────────────────────────── */
dialog.invite { width: min(440px, calc(100vw - 32px)); border: 1px solid #2c2c33; border-radius: 22px; padding: 30px 28px 26px; background: #0d0d10; color: var(--text); box-shadow: 0 40px 120px rgba(0, 0, 0, .8); }
dialog.invite::backdrop { background: rgba(0, 0, 0, .7); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.invite h2, .home .invite h1 { font: 700 26px/1.2 var(--serif); margin: 0 0 8px; letter-spacing: 0; }
.invite.panel { position: relative; width: min(440px, calc(100% - 32px)); margin: 72px auto 96px; border: 1px solid #2c2c33; border-radius: 22px; padding: 30px 28px 26px; background: #0d0d10; }
.invite p { margin: 0 0 20px; color: var(--dim); font-size: 15px; }
.invite label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.invite input[type="email"] { width: 100%; height: 50px; padding: 0 16px; border-radius: 12px; border: 1px solid #34343a; background: #000; color: var(--text); font: 16px var(--sans); }
.invite input[type="email"]:focus { border-color: var(--accent); outline: none; }
.invite .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.invite .actions { display: flex; gap: 10px; margin-top: 18px; }
.invite .actions .btn { flex: 1; }
.invite .msg { min-height: 22px; margin: 12px 0 0; font-size: 14px; }
.invite .msg.error { color: #ff8a9a; }
.invite .done { text-align: center; }
.invite .done .tick { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 14px; background: rgba(185, 166, 255, .16); color: var(--accent); font-size: 26px; }
.invite .close { position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); font-size: 22px; cursor: pointer; }
.invite .close:hover { color: var(--text); background: #1b1b20; }

/* ── Smaller screens ──────────────────────────────────────────────────────── */
@media (max-width: 960px) {
  .hero .wrap { grid-template-columns: 1fr; min-height: 0; max-height: none; text-align: center; padding-top: 56px; padding-bottom: 56px; }
  .lede { margin-left: auto; margin-right: auto; }
  .cta-row { justify-content: center; }
  .hero-phone { width: min(300px, 76vw); transform: none; }
  .tile-grid { grid-template-columns: 1fr 1fr; }
  .strip { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 16px; padding: 4px 24px 18px; margin: 0 -24px; scrollbar-width: none; }
  .strip::-webkit-scrollbar { display: none; }
  .strip figure.item { flex: 0 0 62%; max-width: 260px; scroll-snap-align: center; }
  .strip .item:nth-child(even) { margin-top: 0; }
  .feature { padding: 64px 0; }
  .feature .wrap { grid-template-columns: 1fr; gap: 36px; }
  .feature.flip .text { order: 0; }
  .feature p { max-width: none; }
  .promise .card-wide { grid-template-columns: 1fr; text-align: center; }
}
@media (max-width: 600px) {
  .wrap { padding: 0 18px; }
  .site-header nav a.hide-sm { display: none; }
  .site-header .wordmark { font-size: 20px; }
  .site-header nav { gap: 2px; }
  .site-header nav a { padding: 8px; white-space: nowrap; }
  .hero .wrap { padding-top: 36px; padding-bottom: 40px; gap: 36px; }
  .home h1 { font-size: 38px; }
  .lede { font-size: 17px; margin-bottom: 24px; }
  .cta-row .btn.ghost { display: none; }
  .platforms { margin-top: 16px; }
  .tile-grid { grid-template-columns: 1fr; }
  .shots.two .phone { width: 48%; }
  .shots.two .phone:last-child { margin-top: 32px; }
  .shots.three { gap: 10px; }
  .intro { padding-top: 56px; }
  .feature h2 { font-size: 28px; }
  .promise { padding: 48px 0 72px; }
  .promise .card-wide { padding: 26px 22px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .tile { transition: none; }
  .btn:hover, .tile:hover { transform: none; }
}
