/* Pixtape site: Privacy Policy, Terms of Use and data deletion.
   Colours are the app's (lib/core/theme/pix_colors.dart); system fonts only,
   so the pages load nothing from anyone else. */

:root {
  --canvas: #F6F3EE;
  --surface: #FFFFFF;
  --soft: #EFEBE4;
  --line: #E5E0D8;
  --ink: #121212;
  --ink-soft: #57534E;
  --accent: #FF4F2E;      /* the app's accent: marks and fills */
  --accent-ink: #B8321A;  /* the accent, dark enough for text on the canvas */
  --accent-soft: #FFE4DD;
  --measure: 44rem;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #141312;
    --surface: #1D1C1A;
    --soft: #262422;
    --line: #34312D;
    --ink: #F2EEE8;
    --ink-soft: #BDB7AE;
    --accent: #FF5A3A;
    --accent-ink: #FF8466;
    --accent-soft: #3A2019;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  padding: 0 16px 80px;
  background: var(--canvas);
  color: var(--ink);
  font: 16.5px/1.7 ui-sans-serif, -apple-system, "Segoe UI", Roboto, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

main, .site-nav, .site-foot { max-width: var(--measure); margin-left: auto; margin-right: auto; }

a { color: var(--accent-ink); text-underline-offset: 2px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }
code { font: 0.92em ui-monospace, "SF Mono", Menlo, Consolas, monospace; }

/* ── navigation ── */
.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
}
.brand {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-decoration: none;
}
.brand::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 3px;
  border-radius: 50%;
  background: var(--accent);
}
.site-nav ul { display: flex; gap: 18px; margin: 0; padding: 0; list-style: none; }
.site-nav li { margin: 0; }
.site-nav a { color: var(--ink-soft); text-decoration: none; font-size: 15px; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); }
.site-nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--accent); }

/* ── masthead ── */
header { padding: 48px 0 28px; }
.eyebrow {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
h1 {
  margin: 0 0 16px;
  font-size: clamp(34px, 7vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 800;
  text-wrap: balance;
}
.meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; color: var(--ink-soft); font-size: 14.5px; }
.meta span { white-space: nowrap; }

.summary {
  margin: 8px 0 0;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 14px;
}
.summary p { margin: 0; font-size: 17px; }
.summary p + p { margin-top: 10px; }

/* ── contents ── */
nav.toc { margin: 36px 0 4px; }
nav.toc ol { margin: 0; padding-left: 22px; columns: 2 14rem; column-gap: 32px; color: var(--ink-soft); }
nav.toc li { margin: 0 0 6px; break-inside: avoid; }
nav.toc a { color: var(--ink-soft); text-decoration: none; }
nav.toc a:hover, nav.toc a:focus-visible { color: var(--ink); }

/* ── body ── */
section { scroll-margin-top: 16px; }
h2 {
  margin: 44px 0 0;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-size: 23px;
  line-height: 1.25;
  letter-spacing: -0.015em;
  font-weight: 750;
}
h2 + p, h2 + ul, h2 + ol, h2 + .wrap { margin-top: 12px; }
h3 { margin: 26px 0 4px; font-size: 17.5px; font-weight: 700; }
p { margin: 0 0 14px; }
ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin: 8px 0; }
li::marker { color: var(--accent); }
strong { font-weight: 650; }

.note {
  margin: 18px 0;
  padding: 14px 16px;
  background: var(--accent-soft);
  border-radius: 12px;
  font-size: 15.5px;
}

/* ── tables: rows become cards on narrow screens ── */
.wrap { margin: 16px 0 18px; }
table { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--surface); border-radius: 14px; overflow: hidden; }
th, td { padding: 11px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-soft); background: var(--soft); font-weight: 700; }
tr:last-child td { border-bottom: 0; }

@media (max-width: 40rem) {
  table, thead, tbody, tr, th, td { display: block; }
  table { background: none; border-radius: 0; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  tr { margin: 0 0 12px; padding: 4px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
  td { padding: 9px 0; border-bottom: 1px solid var(--line); }
  tr td:last-child { border-bottom: 0; }
  td::before {
    content: attr(data-label);
    display: block;
    font-size: 11.5px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-soft);
    font-weight: 700;
  }
}

/* ── footer ── */
.site-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 14px;
}
.site-foot a { color: var(--ink-soft); }
