/* Content pages: download, delete-account, privacy-policy, terms.
   Requires base.css (tokens, header, footer, buttons, badges). Not used by the homepage/tutorial. */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 20px); }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  background: var(--bg); color: var(--text); line-height: 1.65; min-height: 100vh;
  display: flex; flex-direction: column;
}
main { flex: 1; }

/* Type scale — display face for headings, native UI face for reading */
h1, h2, h3 { font-family: var(--font-display); letter-spacing: -.02em; }
h1 { font-size: clamp(34px, 5.4vw, 56px); line-height: 1.04; font-weight: 800; margin-bottom: 16px; letter-spacing: -.035em; }
h2 { font-size: clamp(22px, 2.6vw, 28px); line-height: 1.2; font-weight: 700; margin: 48px 0 14px; }
h3 { font-size: 17px; line-height: 1.3; font-weight: 700; margin: 26px 0 8px; }
p { margin-bottom: 16px; }
ul, ol { margin: 0 0 18px 22px; }
li { margin-bottom: 7px; }
strong { color: #fff; }
.lede { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 60ch; line-height: 1.6; }
.meta { font-size: 13.5px; color: var(--muted); }
.flush-top { margin-top: 0; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.actions.spaced { margin-top: 22px; }

/* Page header band */
.page-head { position: relative; border-bottom: 1px solid var(--line); overflow: hidden; }
.page-head::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 120% at 85% -20%, rgba(37,99,235,.20), transparent 60%);
}
.page-head .inner { position: relative; max-width: 1200px; margin: 0 auto; padding: 64px 28px 44px; }
.page-head .lede { margin-top: 6px; }
.page-head .meta { margin-top: 14px; }
@media (max-width: 600px) { .page-head .inner { padding: 44px 20px 32px; } }

.wrap { max-width: 800px; margin: 0 auto; padding: 44px 28px 72px; }
.wrap.wide { max-width: 1200px; }
@media (max-width: 600px) { .wrap { padding: 32px 20px 56px; } }

/* Cards & callouts (used sparingly: an action area and warnings, not every block) */
.card { background: var(--bg2); border: 1px solid var(--line); border-radius: 18px; padding: 28px; margin: 22px 0; }
.card > :last-child { margin-bottom: 0; }
@media (max-width: 600px) { .card { padding: 22px 18px; } }
.callout { border-left: 3px solid var(--link); background: rgba(141,177,255,.07); border-radius: 0 12px 12px 0; padding: 16px 20px; margin: 22px 0; }
.callout.warn { border-left-color: #f5b13d; background: rgba(245,177,61,.08); }
.callout.danger { border-left-color: var(--danger); background: var(--danger-bg); }
.callout > :last-child { margin-bottom: 0; }

/* Legal layout: sticky contents beside a readable measure */
.legal { max-width: 1200px; margin: 0 auto; padding: 40px 28px 72px; display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 56px; align-items: start; }
.toc { position: sticky; top: calc(var(--nav-h) + 24px); font-size: 14px; }
.toc p { font-family: var(--font-display); font-weight: 700; color: var(--text); margin-bottom: 10px; font-size: 14px; }
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.toc li { margin: 0; }
.toc a { display: block; padding: 6px 0 6px 14px; margin-left: -1px; border-left: 2px solid transparent; color: var(--muted); }
.toc a:hover { color: var(--text); text-decoration: none; border-left-color: #4b5a96; }
.toc a.is-current { color: var(--text); border-left-color: var(--link); }
.prose { font-size: 17px; line-height: 1.75; color: #d3dbee; max-width: 70ch; }
.prose > h2:first-child { margin-top: 0; }
.prose h2 { color: var(--text); scroll-margin-top: calc(var(--nav-h) + 20px); }
.prose a { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(141,177,255,.45); }
.prose a:hover { text-decoration-color: currentColor; }
table { width: 100%; border-collapse: collapse; margin: 8px 0 22px; font-size: 14.5px; line-height: 1.5; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--text); font-weight: 700; background: var(--bg2); font-family: var(--font-display); }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: 12px; margin: 8px 0 22px; }
.table-scroll table { margin: 0; min-width: 560px; }
.table-scroll tr:last-child td { border-bottom: 0; }
@media (max-width: 1000px) {
  .legal { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 28px 20px 56px; }
  .toc { position: static; background: var(--bg2); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin-bottom: 20px; }
  .toc ol { border-left: 0; columns: 2; column-gap: 24px; }
  .toc a { padding: 5px 0; border-left: 0; margin: 0; }
}
@media (max-width: 560px) { .toc ol { columns: 1; } .prose { font-size: 16.5px; } }

/* Forms & status */
label { font-weight: 600; }
input[type="text"] { width: 100%; max-width: 320px; background: var(--bg); color: var(--text); border: 1px solid #3a4374; border-radius: 10px; padding: 12px 14px; font: inherit; min-height: 48px; }
input[type="text"]:focus-visible { outline-offset: 1px; }
.check { display: flex; gap: 12px; align-items: flex-start; margin: 16px 0; }
.check input { width: 22px; height: 22px; margin-top: 3px; accent-color: var(--blue); flex: none; }
.field-help { font-size: 13.5px; color: var(--muted); margin-top: 6px; }
.status { border-radius: 12px; padding: 14px 18px; margin: 18px 0; font-weight: 600; }
.status.error { background: var(--danger-bg); border: 1px solid var(--danger); color: #ffd0d8; }
.status.success { background: rgba(74,222,128,.10); border: 1px solid var(--ok); color: #c2f5d3; }

/* Download page */
.dl { max-width: 1200px; margin: 0 auto; padding: 72px 28px 40px; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 64px; align-items: center; }
.dl-copy .lede { margin-bottom: 32px; }
.dl-hint { margin-top: 22px; font-size: 14px; color: var(--muted); max-width: 46ch; }
.dl-qr-wrap { justify-self: center; text-align: center; }
.dl-qr { background: #fff; padding: 18px; border-radius: 22px; width: 264px; box-shadow: 0 30px 80px rgba(37,99,235,.28), 0 0 0 1px rgba(255,255,255,.06); }
.dl-qr img { display: block; width: 100%; height: auto; }
.dl-qr-cap { font-size: 14px; color: var(--muted); margin-top: 16px; }
.redirecting { text-align: center; padding: 120px 24px; }
.redirect-title { font-family: var(--font-display); font-size: clamp(28px, 4.4vw, 40px); font-weight: 800; margin-bottom: 12px; letter-spacing: -.03em; }
@media (max-width: 860px) {
  .dl { grid-template-columns: 1fr; gap: 40px; padding: 44px 20px 24px; }
  .dl-qr-wrap { display: none; } /* a QR is for scanning from another device — pointless on a phone */
}

/* FAQ: native disclosure widgets */
.faq { margin: 4px 0 24px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 44px 18px 0; position: relative;
  font-family: var(--font-display); font-size: 18px; font-weight: 700; letter-spacing: -.015em; line-height: 1.35; color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px; margin-top: -8px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -3px; }
.faq summary:hover { color: #fff; }
.faq summary:focus-visible { outline-offset: 2px; border-radius: 8px; }
.faq details > p { margin: 0 0 20px; padding-right: 44px; max-width: 62ch; }
