/*
  privstory landing page, "Veil" theme, mirroring the desktop app
  (app/src/style.css). Near-chromeless and cinematic: serif-italic display voice
  over a scene backdrop with an adaptive scrim and film grain. Dark only; neutral
  palette (no primary hue, the accent is light itself). System fonts, no web
  fonts, no build step.
*/

:root {
  --ground: #0B0B0D;
  --text: #F6F6F7;
  --muted: #B9B9C0;
  --faint: #6E6E76;
  --accent: #FFFFFF;

  --serif: ui-serif, "New York", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, Roboto, sans-serif;

  --tint: rgba(16, 16, 20, 0.32);
  --tint-strong: rgba(12, 11, 16, 0.62);
  --hairline: rgba(255, 255, 255, 0.16);
  --hairline-soft: rgba(255, 255, 255, 0.08);
  --text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55), 0 2px 18px rgba(0, 0, 0, 0.4);
  --blur: saturate(140%) blur(20px);
  --maxw: 1080px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  background: var(--ground);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
a { color: inherit; text-decoration: none; }

/* Display voice: system serif, italic, the app's signature. */
h1, h2, .brand, .speaker, .tier h3 {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  letter-spacing: .2px;
  line-height: 1.12;
}

/* ---------- Cinematic page backdrop (fixed) ---------- */
.backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; }
.scene { position: absolute; inset: 0; }
.scene .subject {
  position: absolute; left: 50%; top: -10%; width: 60vh; height: 90vh; transform: translateX(-50%);
  border-radius: 50% 50% 44% 44% / 60% 60% 40% 40%; filter: blur(3px); opacity: .55;
}
.scene-dusk { background: radial-gradient(70% 55% at 28% 8%, #f0a3, transparent 60%), linear-gradient(160deg, #241033, #140b24 55%, #0b0b0d); }
.scene-dusk .subject { background: radial-gradient(60% 50% at 50% 30%, #ffd9b0, #7a3b5e 55%, transparent 75%); }
.scene-night { background: radial-gradient(90% 70% at 72% 0%, #15324a55, transparent 60%), linear-gradient(160deg, #0a1622, #060a12 70%); }
.scene-night .subject { background: radial-gradient(55% 50% at 50% 32%, #cfe6ff, #2a5572 55%, transparent 76%); }
.grain {
  position: absolute; inset: 0; pointer-events: none; opacity: .05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}
/* Fade the scene into flat ground below the fold so long content stays readable. */
.page-scrim {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to bottom, rgba(11,11,13,.35) 0%, rgba(11,11,13,.72) 42%, var(--ground) 78%);
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--ground) 62%, transparent);
  backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur);
  border-bottom: 1px solid var(--hairline-soft);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { font-size: 21px; color: var(--text); }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a { font-size: 14px; color: var(--muted); transition: color .15s; }
.nav a:not(.btn):hover { color: var(--text); }

/* ---------- buttons (mirror app .btn) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-size: 14px; cursor: pointer; border-radius: 12px;
  border: 1px solid transparent; color: var(--text);
  transition: background .14s, transform .1s, border-color .14s, opacity .14s;
}
.btn svg { width: 16px; height: 16px; }
.btn-primary { background: rgba(255, 255, 255, .94); color: #111; padding: 12px 22px; }
.btn-primary:hover { transform: translateY(-1px); }
.btn-secondary { background: var(--tint); border-color: var(--hairline); padding: 11px 18px; backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); }
.btn-secondary:hover { background: var(--tint-strong); }
.btn-ghost { background: transparent; color: var(--muted); padding: 11px 16px; }
.btn-ghost:hover { color: var(--text); background: rgba(255, 255, 255, .06); }
.btn-sm { padding: 8px 16px; font-size: 13px; border-radius: 10px; }

/* ---------- hero ---------- */
.hero { padding: 92px 0 56px; }
.hero h1 { font-size: clamp(38px, 6vw, 60px); text-shadow: var(--text-shadow); }
.hero p.lede { font-size: clamp(17px, 2.2vw, 21px); color: var(--muted); max-width: 58ch; margin: 24px 0 0; line-height: 1.55; text-shadow: var(--text-shadow); }
.hero .cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }
.hero .meta-line { margin-top: 20px; font-size: 13px; color: var(--muted); }
.dl-alts { display: inline-flex; align-items: center; gap: 10px; }
.dl-alt { color: var(--muted); border-bottom: 1px solid transparent; transition: color .15s, border-color .15s; }
.dl-alt:hover { color: var(--text); border-bottom-color: currentColor; }
.dl-alt[aria-current="true"] { color: var(--text); font-weight: 600; }

/* ---------- app frame (inline replica of the app) ---------- */
.appframe {
  margin-top: 60px; border: 1px solid var(--hairline); border-radius: 16px; overflow: hidden;
  background: #0b0b0d; box-shadow: 0 40px 120px -40px rgba(0, 0, 0, .9);
}
.appframe .titlebar { height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 15px; background: rgba(255,255,255,.03); border-bottom: 1px solid var(--hairline-soft); }
.appframe .titlebar i { width: 11px; height: 11px; border-radius: 50%; background: var(--hairline); }
.appwin { display: flex; height: min(58vw, 560px); }

.mini-side { width: 210px; flex-shrink: 0; display: flex; flex-direction: column; padding: 18px 14px; background: linear-gradient(to right, rgba(10,10,13,.72), rgba(10,10,13,.46)); border-right: 1px solid var(--hairline); }
.mini-brand { font-family: var(--serif); font-style: italic; font-size: 18px; }
.mini-new { margin-top: 14px; display: flex; align-items: center; gap: 9px; padding: 8px 4px; border: none; background: transparent; color: var(--muted); font: inherit; font-size: 13.5px; }
.mini-new svg { width: 15px; height: 15px; }
.mini-rows { margin-top: 14px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.mini-row { display: flex; align-items: center; gap: 11px; padding: 8px 8px; border-radius: 10px; }
.mini-row.active { background: rgba(255, 255, 255, .06); }
.mini-row .av { width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0; box-shadow: inset 0 0 0 1px var(--hairline); }
.mini-row.active .av { box-shadow: inset 0 0 0 1px var(--hairline), 0 0 0 2px rgba(255,255,255,.5); }
.av.a { background: linear-gradient(135deg, #b08, #503); }
.av.b { background: linear-gradient(135deg, #3a7, #163); }
.av.c { background: linear-gradient(135deg, #47a, #235); }
.mini-nm { font-size: 13.5px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-row:not(.active) .mini-nm { color: var(--muted); }
.mini-foot { display: flex; align-items: center; gap: 9px; font-size: 12.5px; color: var(--muted); }
.mini-foot svg { width: 15px; height: 15px; }

.mini-stage { position: relative; flex: 1; overflow: hidden; }
.mini-stage .scene .subject { top: auto; bottom: -8%; height: 108%; width: 46%; opacity: .95; filter: blur(2px); }
.stage-scrim { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to bottom, rgba(8,7,12,.55) 0%, rgba(8,7,12,0) 22%, rgba(8,7,12,0) 40%, rgba(8,7,12,.9) 100%); }
.mini-top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; padding: 16px 20px; z-index: 2; }
.name-pill { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--text); text-shadow: var(--text-shadow); }
.name-pill svg { width: 15px; height: 15px; }
.status { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text); text-shadow: var(--text-shadow); letter-spacing: .3px; }
.status .live { width: 6px; height: 6px; border-radius: 50%; background: #fff; box-shadow: 0 0 8px #fff; animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.mini-bottom { position: absolute; left: 0; right: 0; bottom: 0; padding: 0 6% 26px; display: flex; flex-direction: column; gap: 12px; z-index: 2; }
.speaker { font-size: 24px; color: var(--text); text-shadow: var(--text-shadow); }
.line { max-width: 60ch; font-size: clamp(15px, 1.8vw, 19px); line-height: 1.6; color: #fff; text-shadow: var(--text-shadow); }
.line .car { margin-left: 2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.composer { display: flex; align-items: center; gap: 12px; max-width: 60ch; margin-top: 4px; }
.mini-input { flex: 1; display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 999px; background: var(--tint); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--hairline); color: var(--muted); font-size: 14px; }
.mini-input svg { width: 16px; height: 16px; opacity: .6; }
.send { width: 44px; height: 44px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: rgba(255,255,255,.94); color: #111; }
.send svg { width: 18px; height: 18px; }

/* ---------- section scaffold ---------- */
section { padding: 76px 0; position: relative; }
.section-head { max-width: 60ch; margin-bottom: 44px; }
.section-head h2 { font-size: clamp(28px, 4vw, 40px); }
.section-head p { color: var(--muted); margin-top: 14px; font-size: 17px; }

/* ---------- features ---------- */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.feature {
  background: var(--tint); border: 1px solid var(--hairline-soft); border-radius: 16px; padding: 24px 22px;
  backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur);
}
.feature .ic { color: var(--text); margin-bottom: 15px; }
.feature .ic svg { width: 22px; height: 22px; stroke-width: 1.6; }
.feature h3 { font-size: 15.5px; font-weight: 600; margin-bottom: 8px; }
.feature p { font-size: 13.5px; color: var(--muted); line-height: 1.55; }
code { font-family: ui-monospace, "SFMono-Regular", Menlo, monospace; font-size: 0.86em; background: rgba(255,255,255,.08); padding: 1px 5px; border-radius: 4px; color: var(--text); }

/* ---------- how it works ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.step { position: relative; background: var(--tint); border: 1px solid var(--hairline-soft); border-radius: 16px; padding: 26px 24px; backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); }
.step-n { position: absolute; top: 22px; right: 24px; font-family: var(--serif); font-style: italic; font-size: 30px; color: var(--faint); }
.step .ic { color: var(--text); margin-bottom: 15px; }
.step .ic svg { width: 24px; height: 24px; stroke-width: 1.6; }
.step h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.step p { font-size: 14px; color: var(--muted); line-height: 1.55; }

/* ---------- pricing ---------- */
.tiers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.tier { border: 1px solid var(--hairline); border-radius: 18px; padding: 32px 30px; background: var(--tint); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); }
.tier.feat { border-color: rgba(255, 255, 255, .55); background: var(--tint-strong); }
.tier h3 { font-size: 26px; }
.tier .price { font-size: 15px; color: var(--muted); margin: 6px 0 22px; }
.tier ul { list-style: none; display: flex; flex-direction: column; gap: 12px; margin-bottom: 26px; }
.tier li { display: flex; gap: 11px; font-size: 14.5px; color: var(--text); align-items: flex-start; }
.tier li svg { width: 16px; height: 16px; color: var(--text); flex-shrink: 0; margin-top: 3px; stroke-width: 2.4; }
.tier .btn { width: 100%; }
.pricing-note { margin-top: 22px; font-size: 14px; color: var(--muted); }

/* ---------- faq ---------- */
.faq { border-top: 1px solid var(--hairline-soft); }
.faq details { border-bottom: 1px solid var(--hairline-soft); padding: 20px 0; }
.faq summary { font-size: 16.5px; color: var(--text); cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .pm { font-family: ui-monospace, monospace; color: var(--muted); transition: transform .2s; }
.faq details[open] summary .pm { transform: rotate(45deg); }
.faq details p { margin-top: 13px; color: var(--muted); font-size: 15px; max-width: 72ch; }
.faq a { color: var(--text); border-bottom: 1px solid var(--hairline); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--hairline-soft); padding: 40px 0; }
.site-footer .wrap { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.site-footer .brand { font-size: 18px; }
.site-footer .links { display: flex; gap: 22px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.site-footer .links a:hover { color: var(--text); }
.site-footer .legal { font-size: 12px; color: var(--faint); width: 100%; }

/* ---------- responsive ---------- */
@media (max-width: 980px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) {
  .mini-side { display: none; }
  .appwin { height: 72vw; }
}
@media (max-width: 680px) {
  .features, .steps, .tiers { grid-template-columns: 1fr; }
  .nav { gap: 14px; }
  .nav .hide-sm { display: none; }
}

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