/*
 * Privacy policy page — standalone, no build step, no external requests.
 *
 * The palette is lifted from the app's own tokens in `global.css` so the page a
 * store reviewer opens looks like the app it belongs to. Light values sit on
 * bare `:root`; the dark block only redefines them, so nothing has its single
 * definition inside a media query.
 */

:root {
  --bg: #f4f4ef;
  --surface: #ffffff;
  --surface-alt: #f0f0eb;
  --line: #e4e4dc;

  --ink: #16160f;
  --ink-soft: #5c5c55;
  --ink-faint: #8a8a80;

  --primary: #5b5bd6;
  --primary-soft: #ececfb;

  --warning: #c9a93f;
  --warning-soft: #f7f0d9;

  --measure: 44rem;
  --radius: 12px;

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101219;
    --surface: #1a1d26;
    --surface-alt: #232733;
    --line: #2c3140;

    --ink: #edeef3;
    --ink-soft: #a9afbf;
    --ink-faint: #7a8194;

    --primary: #8ecae6;
    --primary-soft: #16323f;

    --warning: #d6bc4e;
    --warning-soft: #2c2716;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0 0 4rem;
  background: var(--bg);
  color: var(--ink);
  font-family:
    -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
    sans-serif;
  font-size: 17px;
  line-height: 1.65;
  overflow-wrap: break-word;
}

.wrap {
  max-width: var(--measure);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

/* ── masthead ─────────────────────────────────────────────────────────────── */

.masthead {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 3rem 0 2.25rem;
  margin-bottom: 2.5rem;
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
}

h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 6vw, 2.75rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.dates {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

.dates strong {
  color: var(--ink);
  font-weight: 600;
}

/* ── headings and text ────────────────────────────────────────────────────── */

h2 {
  margin: 2.75rem 0 0.85rem;
  font-size: 1.3rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
  scroll-margin-top: 1.5rem;
}

h3 {
  margin: 1.75rem 0 0.6rem;
  font-size: 1.03rem;
  color: var(--ink);
}

p {
  margin: 0 0 1rem;
}

ul,
ol {
  margin: 0 0 1.15rem;
  padding-left: 1.3rem;
}

li {
  margin-bottom: 0.55rem;
}

li::marker {
  color: var(--ink-faint);
}

strong {
  font-weight: 650;
}

em {
  color: var(--ink-soft);
}

a {
  color: var(--primary);
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

a:hover {
  text-decoration-thickness: 2px;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em;
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 0.05em 0.35em;
}

/* Placeholders the operator must replace before publishing. Deliberately loud:
   an unfilled contact address is the one defect that makes the page useless. */
.fill {
  background: var(--warning-soft);
  border-bottom: 2px solid var(--warning);
  border-radius: 3px;
  padding: 0.05em 0.3em;
  font-weight: 600;
  white-space: nowrap;
}

/* ── summary card ─────────────────────────────────────────────────────────── */

.summary {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem 1.1rem;
}

.summary h2 {
  margin-top: 0;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

.summary ul {
  margin-bottom: 0;
}

/* ── table of contents ────────────────────────────────────────────────────── */

.toc {
  margin-top: 2.5rem;
  padding: 1.25rem 1.5rem;
  background: var(--surface-alt);
  border-radius: var(--radius);
}

.toc h2 {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.toc ol {
  columns: 2;
  column-gap: 2rem;
  margin: 0;
  padding-left: 1.2rem;
  font-size: 0.94rem;
}

.toc li {
  margin-bottom: 0.3rem;
  break-inside: avoid;
}

.toc a {
  text-decoration: none;
}

.toc a:hover {
  text-decoration: underline;
}

@media (max-width: 34rem) {
  .toc ol {
    columns: 1;
  }
}

/* ── callout ──────────────────────────────────────────────────────────────── */

.note {
  background: var(--primary-soft);
  border-radius: var(--radius);
  padding: 1rem 1.2rem;
  margin: 1.5rem 0;
  font-size: 0.96rem;
}

/* ── sub-processor table ──────────────────────────────────────────────────── */

.table-scroll {
  overflow-x: auto;
  margin: 1.25rem 0 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

table {
  border-collapse: collapse;
  width: 100%;
  min-width: 34rem;
  font-size: 0.92rem;
}

th,
td {
  text-align: left;
  vertical-align: top;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
}

thead th {
  background: var(--surface-alt);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  white-space: nowrap;
}

tbody tr:last-child td {
  border-bottom: 0;
}

td:first-child {
  font-weight: 600;
}

/* ── footer ───────────────────────────────────────────────────────────────── */

footer {
  margin-top: 3.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  font-size: 0.85rem;
  color: var(--ink-faint);
}

/* ── print ────────────────────────────────────────────────────────────────── */

@media print {
  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
  }

  .masthead,
  .summary,
  .toc,
  .note,
  .table-scroll {
    background: #fff;
    border-color: #ccc;
  }

  .toc {
    display: none;
  }

  a {
    color: #000;
  }

  section {
    break-inside: avoid-page;
  }
}
