/* NightPager: one idea per screen, dark, quiet. */
:root {
  --bg: #14110F;
  --panel: #1C1714;
  --text: #FFFBF5;
  --muted: #C8B6A4;
  --line: #3A2E27;
  --accent: #FF8533;
  --accent-hover: #FFA057;
  --body: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --mono: 'Consolas', 'SFMono-Regular', 'Liberation Mono', 'Menlo', monospace;
}

* { box-sizing: border-box; }
html { scroll-snap-type: y proximity; scroll-behavior: smooth; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body { font-family: var(--body); font-size: 17px; line-height: 1.55; }

a { color: var(--accent); }
a:hover { color: var(--accent-hover); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* Each section is its own screen */
.screen {
  min-height: 100vh;
  min-height: 100svh;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 16px;
  position: relative;
}
.inner { width: 100%; max-width: 560px; margin: 0 auto; }
.center { text-align: center; }

/* Fade in on scroll (only when the script runs and motion is allowed) */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js .reveal.shown { opacity: 1; transform: none; }

.mark {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 14px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); text-decoration: none;
}
.logo { width: 32px; height: 27px; shape-rendering: crispEdges; }

h1 { font-size: 34px; line-height: 1.18; font-weight: 650; margin: 18px 0 12px; }
h2 { font-size: 22px; font-weight: 600; margin: 0 0 20px; }
.lede { color: var(--muted); margin: 0; }

.scroll-hint {
  position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
  color: var(--muted); text-decoration: none; font-size: 22px;
}

/* How it works */
.steps { list-style: none; padding: 0; margin: 0 0 20px; color: var(--muted); }
.steps li { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.steps strong { color: var(--text); font-weight: 600; }
.step-icon { width: 32px; height: 32px; flex-shrink: 0; shape-rendering: crispEdges; }

/* The phone demo */
.phone {
  max-width: 340px;
  margin: 0 auto;
  background: #2A231E;
  border: 2px solid #4A3B31;
  border-radius: 22px;
  padding: 14px;
}
.phone-top {
  display: flex; justify-content: space-between;
  font-family: var(--mono); font-size: 12px; color: var(--muted);
  padding: 0 4px 8px;
}
.thread {
  background: #0E0C0A;
  border-radius: 10px;
  height: 260px;
  overflow-y: auto;
  padding: 10px;
  display: flex; flex-direction: column; gap: 8px;
}
.hint { color: var(--muted); font-size: 13px; margin: auto 0; text-align: center; }
.msg { white-space: pre-line; margin: 0; padding: 8px 10px; border-radius: 10px; font-size: 13px; line-height: 1.4; max-width: 88%; }
.msg.in { background: #2B2219; color: #FFE6C7; align-self: flex-start; }
.msg.in.urgent { border: 1px solid var(--accent); }
.msg.out { background: var(--accent); color: #171003; align-self: flex-end; font-family: var(--mono); font-weight: 700; }
.msg.sys { background: none; color: var(--muted); font-size: 12px; font-style: italic; align-self: center; text-align: center; max-width: 100%; padding: 2px 4px; }

.keys { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.keys button {
  flex: 1 1 auto;
  font-family: var(--mono); font-size: 13px; font-weight: 700;
  background: #3A2F27; color: var(--text);
  border: 1px solid #574638; border-radius: 6px;
  padding: 8px 6px; cursor: pointer;
}
.keys button:hover { border-color: var(--accent); }
.keys.demo button { font-family: var(--body); font-weight: 500; font-size: 12px; color: var(--muted); background: none; }

/* Calls */
.scenes { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.scenes figure { margin: 0; }
.scene {
  width: 100%; height: auto; display: block; shape-rendering: crispEdges;
  background: #0B0907; border: 1px solid var(--line); border-radius: 8px; padding: 10px;
}
figcaption { font-size: 14px; color: var(--muted); margin-top: 8px; }
figcaption strong { display: block; color: var(--text); font-weight: 600; }
.note { font-size: 14px; color: var(--accent-hover); margin: 8px 0 0; }

/* Start */
.promise { font-size: 20px; margin: 0 0 24px; }
.button {
  display: inline-block; background: var(--accent); color: #171003;
  font-weight: 600; text-decoration: none; padding: 12px 22px; border-radius: 6px;
}
.button:hover { background: var(--accent-hover); color: #171003; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 18px; }
.plan {
  border: 1px solid var(--line); border-radius: 10px; background: var(--panel);
  padding: 18px 14px; text-align: center;
}
.plan.featured { border-color: var(--accent); }
.price { font-size: 28px; font-weight: 650; }
.per { color: var(--muted); font-size: 14px; }
.name { display: block; color: var(--muted); font-size: 14px; margin-top: 4px; }
.incl { display: block; color: var(--muted); font-size: 13px; line-height: 1.45; margin-top: 8px; }
#pricing p { color: var(--muted); margin: 0 0 8px; }
#pricing .fine { font-size: 14px; }

.last { justify-content: space-between; }
.last .inner { margin-top: auto; margin-bottom: auto; }
footer { font-size: 13px; color: var(--muted); text-align: center; padding-top: 40px; }
footer a { color: var(--muted); }
footer p { margin: 4px 0; }

/* Privacy page */
.page main { max-width: 560px; margin: 0 auto; padding: 64px 16px 48px; }
.page h2 { font-size: 18px; margin: 32px 0 8px; }
.page p, .page li { color: var(--muted); }
.page li { margin-bottom: 6px; }
.page footer { padding-bottom: 32px; }

/* Pixel animations */
@keyframes np-spray { 0%, 100% { transform: translateY(0); opacity: 1; } 50% { transform: translateY(-4px); opacity: 0.82; } }
@keyframes np-puddle { 0%, 100% { transform: scaleX(1); } 50% { transform: scaleX(1.04); } }
@keyframes np-panic { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes np-float-z { 0%, 100% { transform: translateY(0); opacity: 0.98; } 50% { transform: translateY(-5px); opacity: 0.55; } }
@keyframes np-breathe { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2px); } }
.np-anim-spray { animation: np-spray 0.7s steps(2, start) infinite; }
.np-anim-puddle { transform-origin: center; animation: np-puddle 1.1s steps(2, start) infinite; }
.np-anim-panic { animation: np-panic 0.6s steps(2, start) infinite; }
.np-anim-z { animation: np-float-z 1.6s steps(2, start) infinite; }
.np-anim-breathe { animation: np-breathe 2.2s steps(2, start) infinite; }

@media (max-width: 480px) {
  h1 { font-size: 28px; }
  .scenes { grid-template-columns: 1fr; }
  .plans { gap: 8px; }
  .plan { padding: 14px 6px; }
  .price { font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .np-anim-spray, .np-anim-puddle, .np-anim-panic, .np-anim-z, .np-anim-breathe { animation: none !important; }
}

/* Scale up on large monitors */
@media (min-width: 1400px) {
  body { font-size: clamp(17px, 1.05vw, 22px); }
  .inner { max-width: clamp(560px, 40vw, 820px); }
  h1 { font-size: clamp(34px, 2.6vw, 54px); }
  h2 { font-size: clamp(22px, 1.5vw, 30px); }
  .mark { font-size: clamp(14px, 0.9vw, 18px); }
  .logo { width: clamp(32px, 2vw, 44px); height: auto; }
  .step-icon { width: clamp(32px, 2vw, 44px); height: auto; }
  .phone { max-width: clamp(340px, 24vw, 460px); }
  .msg, .keys button { font-size: clamp(13px, 0.85vw, 16px); }
  .thread { height: clamp(260px, 18vw, 360px); }
  figcaption, .note, #pricing .fine { font-size: clamp(14px, 0.9vw, 18px); }
  .promise { font-size: clamp(20px, 1.4vw, 28px); }
  .price { font-size: clamp(28px, 2vw, 40px); }
}

/* Wide screens: use the space */
@media (min-width: 1000px) {
  .inner { max-width: min(1180px, 84vw); }
  .hero .inner { max-width: min(1000px, 70vw); }
  h1 { font-size: clamp(40px, 3.6vw, 76px); }
  .lede { font-size: clamp(18px, 1.35vw, 26px); max-width: 46ch; }
  .how-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 4vw, 80px); align-items: center; }
  .how-grid .phone { margin: 0; width: 100%; max-width: clamp(360px, 28vw, 520px); justify-self: center; }
  .how-grid .thread { height: clamp(300px, 22vw, 440px); }
  .steps li { margin-bottom: 20px; }
  .scenes { gap: clamp(20px, 3vw, 56px); }
  .promise { font-size: clamp(22px, 1.8vw, 34px); }
  .plans { gap: clamp(12px, 2vw, 32px); }
  .plan { padding: clamp(18px, 2vw, 36px) 14px; }
  #pricing .inner { max-width: min(1000px, 70vw); }
}

/* Combined screens: pictures sit under How it works; trial button sits above pricing */
.calls { margin-top: 48px; }
.start { margin-bottom: 48px; }
.start .promise { margin-bottom: 20px; }
@media (min-width: 1000px) {
  .calls { margin-top: clamp(48px, 5vw, 96px); }
  #pricing .start { margin-bottom: clamp(48px, 4vw, 80px); }
}

/* Top bar */
html { scroll-padding-top: 60px; }
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: rgba(20, 17, 15, 0.9);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: min(1180px, 92vw); margin: 0 auto; height: 60px; padding: 0 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.topbar nav { display: flex; align-items: center; gap: 24px; }
.topbar nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
.topbar nav a:hover { color: var(--text); }
.topbar nav a.button { color: #171003; }
.button.small { padding: 8px 14px; font-size: 14px; }
.screen { min-height: calc(100vh - 60px); min-height: calc(100svh - 60px); }
@media (max-width: 600px) {
  .topbar nav a.link { display: none; }
}

/* Plan boxes are links */
a.plan { color: var(--text); text-decoration: none; display: block; }
a.plan:hover { border-color: var(--accent-hover); }

/* Forms */
.form-page { max-width: 560px; margin: 0 auto; padding: 48px 16px 32px; }
.form-page h1 { margin-top: 0; }
.form-page .lede { margin-bottom: 28px; }
.signup { display: flex; flex-direction: column; gap: 18px; }
.signup label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 15px; }
.signup small { font-weight: 400; color: var(--muted); font-size: 13px; }
.signup input[type=text], .signup input:not([type]), .signup input[type=tel], .signup input[type=email] {
  font: inherit; font-weight: 400; color: var(--text); background: var(--panel);
  border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px;
}
.signup input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.signup .check { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 400; color: var(--muted); font-size: 14px; }
.signup .check input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--accent); flex-shrink: 0; }
.signup button { border: 0; cursor: pointer; font: inherit; font-weight: 600; align-self: flex-start; }
.signup .fine { color: var(--muted); font-size: 13px; margin: -6px 0 0; }
.plan-pick { border: 0; padding: 0; margin: 0 0 4px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.plan-pick legend { font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.plan-option {
  position: relative; display: block !important; text-align: center; cursor: pointer;
  border: 1px solid var(--line); border-radius: 10px; background: var(--panel); padding: 14px 6px;
}
.plan-option input { position: absolute; opacity: 0; }
.plan-option:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.plan-option:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.plan-option .price { font-size: 24px; }
.plan-option .per, .plan-option .name { font-weight: 400; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.error { background: #3A1A12; border: 1px solid #B53812; color: #FFD9C7; padding: 10px 12px; border-radius: 6px; }

/* Sign-in and settings (preview) */
.topbar nav a.signin { color: var(--text); }
.narrow { max-width: 440px; }
.aside { color: var(--muted); font-size: 14px; margin-top: 28px; border-top: 1px solid var(--line); padding-top: 16px; }
.settings { max-width: 720px; margin: 0 auto; padding: 32px 16px 32px; }
.settings h1 { margin: 0 0 4px; }
.settings > .lede { margin: 8px 0 24px; }
.preview-note { background: var(--panel); border: 1px dashed var(--line); color: var(--muted); font-size: 13px; padding: 8px 12px; border-radius: 6px; margin: 0 0 24px; }
.settings-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.status-pill { margin: 6px 0 0; border: 1px solid var(--accent); border-radius: 999px; padding: 6px 14px; font-size: 14px; color: var(--muted); white-space: nowrap; }
.status-pill strong { color: var(--accent); font-family: var(--mono); }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin: 0 0 16px; display: flex; flex-direction: column; gap: 14px; }
.card h2 { margin: 0; font-size: 18px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.card .hint-line { color: var(--muted); font-size: 14px; margin: -6px 0 0; }
.card .button { align-self: flex-start; border: 0; cursor: pointer; font: inherit; font-weight: 600; font-size: 14px; }
.card .button.ghost { background: none; border: 1px solid var(--line); color: var(--muted); }
.choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.choices.stack { grid-template-columns: 1fr; }
.choice { position: relative; cursor: pointer; border: 1px solid var(--line); border-radius: 10px; padding: 12px; background: var(--bg); }
.choice input { position: absolute; opacity: 0; }
.choice span { display: block; color: var(--muted); font-size: 14px; }
.choice strong { display: block; color: var(--text); font-size: 15px; }
.choice:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.choice:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.card label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; }
.card input:not([type=radio]) { font: inherit; font-weight: 400; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 9px 12px; color-scheme: dark; min-width: 0; }
.card input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.people { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
ol.people { counter-reset: n; }
.people li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); margin: 0; flex-wrap: wrap; }
ol.people li::before { counter-increment: n; content: counter(n); color: var(--accent); font-family: var(--mono); font-weight: 700; width: 18px; }
.people .who { flex: 1; color: var(--muted); font-size: 14px; }
.people .who strong { color: var(--text); margin-right: 6px; font-size: 15px; }
.actions { display: flex; gap: 14px; }
.link-btn { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; font-size: 14px; cursor: pointer; }
.tag { font-size: 12px; font-weight: 600; color: var(--accent); border: 1px solid var(--accent); border-radius: 999px; padding: 2px 8px; }
.locked .tag { color: var(--muted); border-color: var(--line); }
.card details summary { cursor: pointer; color: var(--accent); font-size: 15px; }
.card details[open] { display: flex; flex-direction: column; gap: 12px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 8px; font-size: 14px; max-width: calc(100% - 32px); }
@media (max-width: 600px) {
  .choices { grid-template-columns: 1fr; }
  .row { grid-template-columns: 1fr; }
}
.topbar nav a { white-space: nowrap; }
@media (max-width: 600px) {
  .topbar nav { gap: 14px; }
  .topbar .mark { font-size: 12px; gap: 6px; letter-spacing: 0.06em; }
  .topbar .mark .logo { width: 26px; height: 22px; }
}

/* The two scene pictures were removed (Neema, 2026-10-28); the captions stand as two short text cards. */
.scenes figure { border-left: 3px solid var(--line); padding: 4px 0 4px 16px; }
.scenes figure:first-child { border-left-color: var(--accent); }
.scenes figcaption { margin-top: 0; font-size: 15px; }

.signout-row { text-align: center; margin: 8px 0 32px; font-size: 14px; }
.signout-row a { color: var(--muted); }
.toggles { display: grid; gap: 8px; margin: 4px 0 14px; }
.card label.toggle { display: flex; flex-direction: row; font-weight: 400; gap: 12px; margin: 0; align-items: flex-start; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; cursor: pointer; }
.toggle input { margin: 3px 0 0; width: 18px !important; min-width: 18px; height: 18px; padding: 0; accent-color: var(--accent); flex: none; }
.toggle span { display: block; color: var(--muted); font-size: 14px; }
.toggle strong { display: block; color: var(--text); font-size: 15px; }
.toggle.locked-row { opacity: .7; cursor: default; }
.people .actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
