/* Gramlet site: home, help, privacy, terms, support, contact, delete-account.
   Colours mirror shared/brand.json (design.md §7); the prototype (index.html) keeps its own inline style.
   Light and dark follow the visitor's system setting. */
:root {
  --bg: #f6f5fa; --surface: #ffffff; --muted: #f1eff7; --line: #e7e4ef;
  --ink: #1c1828; --ink2: #5d586b; --ink3: #6b6679;
  --accent: #7c3aed; --link: #6d28d9; --soft: #ede7fd;
  --brand: linear-gradient(135deg, #7c3aed, #ec4899 55%, #fb923c);
  --button: linear-gradient(135deg, #7c3aed, #db2777);
  --glow: .15; --shadow: 0 8px 24px rgba(124, 58, 237, .18);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f0d14; --surface: #1a1722; --muted: #241f2e; --line: #2e2939;
    --ink: #f4f2f8; --ink2: #a9a3b8; --ink3: #8f89a0;
    --accent: #a78bfa; --link: #c4b5fd; --soft: #2a2240;
    --glow: .22; --shadow: none;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--link); text-underline-offset: 2px; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 720px; }

/* ── header ─────────────────────────────────────────── */
.top { position: relative; z-index: 2; }
.top .wrap { display: flex; align-items: center; gap: 12px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: -.01em; }
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.brand sup { font-size: .5em; font-weight: 600; }
.top nav { margin-left: auto; display: flex; gap: 4px; }
.top nav a { color: var(--ink2); text-decoration: none; font-weight: 600; font-size: 16px; padding: 10px 12px; border-radius: 12px; }
.top nav a:hover, .top nav a[aria-current="page"] { color: var(--ink); background: var(--muted); }

/* ── page title band (legal and support pages) ─────── */
.glow { position: relative; overflow: hidden; }
.glow::before {
  content: ""; position: absolute; inset: -120px -10% auto; height: 420px; z-index: 0; pointer-events: none;
  background: var(--brand); opacity: var(--glow); filter: blur(70px); border-radius: 50%;
}
.glow > * { position: relative; z-index: 1; }
.pagehead { padding-top: 28px; padding-bottom: 8px; }
.pagehead h1 { font-size: clamp(30px, 6vw, 40px); line-height: 1.15; margin: 0 0 8px; letter-spacing: -.02em; }
.pagehead p { margin: 0; color: var(--ink2); font-size: 18px; }

/* ── cards and text ─────────────────────────────────── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 8px 24px 20px; margin: 16px 0; }
@media (prefers-color-scheme: dark) { .card { border-color: transparent; } }
.card h2 { font-size: 21px; line-height: 1.3; margin: 22px 0 6px; }
.card h3 { font-size: 18px; margin: 18px 0 4px; }
.card p, .card li { color: var(--ink); }
.card ul, .card ol { padding-left: 1.3em; }
.card li { margin: 4px 0; }
.lead { font-size: 18px; color: var(--ink2); }
.callout { background: var(--soft); border-radius: 16px; padding: 14px 18px; margin: 16px 0; }
.callout p { margin: 0; }
table.kv { border-collapse: collapse; width: 100%; font-size: 16px; margin: 6px 0 4px; }
table.kv td { border-top: 1px solid var(--line); padding: 10px 6px; vertical-align: top; }
table.kv td:first-child { font-weight: 600; width: 40%; }
.updated { color: var(--ink3); font-size: 14px; margin: 18px 0 0; }

/* FAQ */
details.q { border-top: 1px solid var(--line); }
details.q:first-of-type { border-top: 0; }
details.q summary { cursor: pointer; list-style: none; font-weight: 600; font-size: 18px; padding: 16px 32px 16px 0; position: relative; }
details.q summary::-webkit-details-marker { display: none; }
details.q summary::after { content: "+"; position: absolute; right: 4px; top: 12px; font-size: 24px; color: var(--accent); font-weight: 400; }
details.q[open] summary::after { content: "–"; }
details.q > div { padding: 0 0 12px; }
details.q > div p { margin: 0 0 10px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 24px; border-radius: 16px; font-weight: 700; font-size: 17px; text-decoration: none; }
.btn.primary { background: var(--button); color: #fff; box-shadow: var(--shadow); }
.btn.secondary { background: var(--surface); color: var(--link); border: 1px solid var(--line); }

/* ── contact form ───────────────────────────────────── */
.form { padding: 14px 0 4px; }
.field { margin: 0 0 20px; }
.field label { display: block; font-weight: 700; font-size: 17px; margin: 0 0 6px; }
.field .opt { font-weight: 500; color: var(--ink2); }
.form input, .form select, .form textarea {
  display: block; width: 100%; min-height: 52px; padding: 12px 14px; font: inherit; font-size: 17px; color: var(--ink);
  background: var(--bg); border: 1.5px solid var(--line); border-radius: 14px; appearance: none; -webkit-appearance: none;
}
.form textarea { min-height: 170px; resize: vertical; line-height: 1.5; }
.form select {
  padding-right: 44px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink2) 50%), linear-gradient(135deg, var(--ink2) 50%, transparent 50%);
  background-position: right 22px center, right 16px center; background-size: 6px 6px; background-repeat: no-repeat;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--soft); }
.form [aria-invalid="true"] { border-color: #dc2626; }
.form .hint { color: var(--ink2); font-size: 15px; margin: 6px 0 0; }
.form .hint.center { text-align: center; margin-top: 12px; }
.form .err { color: #b91c1c; font-size: 15px; font-weight: 600; margin: 6px 0 0; }
.formerror { background: #fef2f2; color: #991b1b; border-radius: 14px; padding: 12px 16px; margin: 0 0 16px; font-weight: 600; }
.formerror:focus { outline: 3px solid var(--accent); outline-offset: 2px; }
@media (prefers-color-scheme: dark) {
  .form .err { color: #fca5a5; }
  .form [aria-invalid="true"] { border-color: #f87171; }
  .formerror { background: #3b1219; color: #fecaca; }
}
.btn.send { width: 100%; border: 0; cursor: pointer; font-family: inherit; }
.btn.send:disabled { opacity: .7; cursor: progress; }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.done { text-align: center; padding: 28px 24px 24px; }
.done .tick { width: 56px; height: 56px; border-radius: 50%; background: var(--soft); color: var(--accent); display: grid; place-items: center; margin: 0 auto 6px; }
.done h2 { margin: 10px 0 8px; outline: none; }
.done p { color: var(--ink2); margin: 0; }
.contactband { text-align: center; padding: 20px 24px 24px; }
.contactband h2 { margin: 6px 0 4px; }
.contactband p { margin: 0 0 16px; color: var(--ink2); }

/* ── footer ─────────────────────────────────────────── */
.foot { color: var(--ink2); font-size: 14px; text-align: center; padding: 32px 20px 40px; line-height: 1.9; }
.foot a { color: var(--ink2); }
.foot .sep { color: var(--ink3); padding: 0 4px; }

/* ── home ───────────────────────────────────────────── */
.hero { display: grid; gap: 28px; align-items: center; padding-top: 24px; padding-bottom: 8px; }
.hero h1 { font-size: clamp(38px, 9vw, 60px); line-height: 1.05; letter-spacing: -.03em; margin: 0 0 14px; }
.hero h1 span { background: var(--button); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { font-size: 19px; margin: 0 0 22px; max-width: 34em; }
.price-pill { display: inline-block; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: 15px; font-weight: 600; color: var(--ink2); margin-bottom: 18px; }
.price-pill b { color: var(--ink); }
.badges { display: flex; flex-wrap: wrap; gap: 12px; }
.badge { display: inline-flex; align-items: center; gap: 10px; min-height: 56px; padding: 8px 18px 8px 14px; border-radius: 14px; background: #16131d; color: #fff; text-decoration: none; border: 1px solid #16131d; }
@media (prefers-color-scheme: dark) { .badge { background: #f4f2f8; color: #16131d; border-color: #f4f2f8; } }
.badge svg { width: 26px; height: 26px; flex: none; }
.badge small { display: block; font-size: 11px; line-height: 1.2; opacity: .8; letter-spacing: .02em; }
.badge b { display: block; font-size: 19px; line-height: 1.15; font-weight: 700; }
.phone { justify-self: center; width: min(300px, 78vw); border-radius: 44px; padding: 10px; background: #16131d; box-shadow: 0 30px 60px rgba(76, 29, 149, .25); }
.phone img { display: block; border-radius: 34px; width: 100%; }
.hero .note { font-size: 14px; color: var(--ink2); margin: 16px 0 0; }

.section { padding-top: 40px; padding-bottom: 8px; }
.section > h2 { font-size: clamp(26px, 5vw, 34px); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 8px; }
.section > p.lead { margin: 0 0 20px; }
.grid4 { display: grid; gap: 14px; grid-template-columns: 1fr; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 18px 20px; }
@media (prefers-color-scheme: dark) { .tile { border-color: transparent; } }
.tile .ic { width: 44px; height: 44px; border-radius: 12px; background: var(--soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 10px; }
.tile .ic svg { width: 24px; height: 24px; }
.tile h3 { margin: 0 0 4px; font-size: 18px; }
.tile p { margin: 0; color: var(--ink2); font-size: 16px; line-height: 1.5; }
.modes { display: grid; gap: 14px; }
.mode { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 20px; }
@media (prefers-color-scheme: dark) { .mode { border-color: transparent; } }
.mode h3 { margin: 0 0 4px; font-size: 20px; }
.mode p { margin: 0; color: var(--ink2); }
.shots { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 20px 20px; margin: 0 -20px; scrollbar-width: thin; }
.shots figure { margin: 0; flex: 0 0 auto; width: 220px; scroll-snap-align: center; text-align: center; }
.shots img { width: 100%; border-radius: 26px; border: 1px solid var(--line); display: block; background: var(--surface); }
.shots figcaption { font-size: 15px; color: var(--ink2); margin-top: 8px; }
.private { display: grid; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 24px; }
@media (prefers-color-scheme: dark) { .private { border-color: transparent; } }
.private h2 { margin: 0; font-size: 26px; letter-spacing: -.01em; }
.private ul { margin: 0; padding: 0; list-style: none; }
.private li { padding: 6px 0 6px 30px; position: relative; }
.private li::before { content: ""; position: absolute; left: 4px; top: 14px; width: 12px; height: 7px; border-left: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent); transform: rotate(-45deg); }
.pricecard { text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 28px 20px; }
@media (prefers-color-scheme: dark) { .pricecard { border-color: transparent; } }
.pricecard .big { font-size: 44px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.pricecard .big small { font-size: 20px; font-weight: 600; color: var(--ink2); }
.pricecard p { margin: 8px 0 0; color: var(--ink2); }
.helpband { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; background: var(--soft); border-radius: 24px; padding: 22px 24px; }
.helpband h2 { margin: 0 0 2px; font-size: 22px; }
.helpband p { margin: 0; color: var(--ink2); }
.medical { font-size: 15px; color: var(--ink2); text-align: center; max-width: 40em; margin: 28px auto 0; }

@media (min-width: 720px) {
  .grid4 { grid-template-columns: 1fr 1fr; }
  .modes { grid-template-columns: 1fr 1fr; }
  .private { grid-template-columns: 1fr 1.2fr; align-items: center; padding: 32px; }
}
@media (min-width: 960px) {
  .hero { grid-template-columns: 1.15fr .85fr; padding-top: 48px; padding-bottom: 16px; }
  .grid4 { grid-template-columns: repeat(4, 1fr); }
  .shots { display: grid; grid-template-columns: repeat(5, 1fr); overflow: visible; margin: 0; padding: 4px 0 20px; }
  .shots figure { width: auto; }
}

/* ── help (site) ───────────────────────────────────── */
.helpwrap { display: grid; gap: 24px; padding-bottom: 8px; }
.helpnav { display: none; }
@media (min-width: 960px) {
  .helpwrap { grid-template-columns: 240px minmax(0, 1fr); align-items: start; }
  .helpnav { display: block; position: sticky; top: 16px; padding-top: 24px; }
  .helpnav h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink3); margin: 0 0 8px 12px; }
  .helpnav a { display: block; padding: 8px 12px; border-radius: 12px; color: var(--ink2); text-decoration: none; font-weight: 500; font-size: 16px; }
  .helpnav a:hover { background: var(--muted); color: var(--ink); }
  .helpnav a[aria-current="page"] { background: var(--soft); color: var(--link); font-weight: 700; }
}
.crumb { font-size: 15px; margin: 20px 0 0; }

@media print { .top nav, .helpnav, .glow::before { display: none; } body { background: #fff; } }
