/* The privacy page and the terms of use (issue 117). A text people read to the end when it matters to
   them, so the page is the calm side of the system (DESIGN.md §1): graphite on white, one column at
   a reading width, Quicksand for the headings and Figtree for the text, rosa only in the logo's "y"
   and the links. tokens.css (packages/design) is linked before this file; nothing is fetched from
   anyone else and nothing here needs a script. */

:root {
  --gutter: 16px;
  --measure: 42rem;
}
@media (min-width: 768px) {
  :root {
    --gutter: 32px;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.6;
  overflow-wrap: break-word;
}
a {
  color: var(--tinta);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover {
  text-decoration-thickness: var(--stroke);
}
:focus-visible {
  outline: var(--stroke) solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}
.skip {
  position: absolute;
  left: var(--gutter);
  top: -4rem;
  z-index: 1;
  padding: 0.6rem 1.1rem;
  border-radius: var(--radius-pill);
  background: var(--ink-soft);
  color: var(--bg);
  font-weight: 600;
  text-decoration: none;
}
.skip:focus {
  top: 0.75rem;
}

/* ---- The top: the logo home, and the two texts side by side ---- */
.top,
.foot nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-5);
}
.top {
  justify-content: space-between;
  max-width: calc(var(--measure) + 2 * var(--gutter));
  margin: 0 auto;
  padding: var(--space-5) var(--gutter) var(--space-4);
}
.brand {
  display: inline-flex;
  border-radius: var(--radius-sm);
}
.wordmark img {
  display: block;
  height: 1.75rem;
  width: auto;
}
.wordmark .wordmark-dark {
  display: none;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .wordmark .wordmark-light {
    display: none;
  }
  :root:not([data-theme="light"]) .wordmark .wordmark-dark {
    display: block;
  }
}
.pages {
  display: flex;
  gap: var(--space-2);
}
.pages a,
.foot a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 var(--space-4);
  border: var(--stroke) solid var(--line);
  border-radius: var(--radius-pill);
  color: var(--ink);
  font-size: var(--text-small);
  font-weight: 600;
  text-decoration: none;
  transition: border-color var(--dur-fast, 120ms) ease, background-color var(--dur-fast, 120ms) ease;
}
.pages a:hover,
.foot a:hover {
  border-color: var(--line-strong);
}
.pages a[aria-current="page"] {
  border-color: var(--ink-soft);
  background: var(--surface);
}

/* ---- The text ---- */
.text {
  max-width: calc(var(--measure) + 2 * var(--gutter));
  margin: 0 auto;
  padding: var(--space-4) var(--gutter) var(--space-8);
}
.text:focus {
  outline: none;
}
h1,
h2,
h3 {
  margin: 0;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  text-wrap: balance;
  scroll-margin-top: var(--space-5);
}
h1 {
  margin-bottom: var(--space-4);
  font-size: var(--text-display);
  line-height: 1.1;
}
h2 {
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: var(--stroke) solid var(--line);
  font-size: var(--text-h2);
  line-height: 1.25;
}
h3 {
  margin-top: var(--space-6);
  font-size: var(--text-h3);
  line-height: 1.3;
}
h2 + *,
h3 + * {
  margin-top: var(--space-3);
}
/* An anchor someone was sent to (the app links #voice, #links-anyone-can-try …): marked, not moved. */
h2:target,
h3:target {
  color: var(--tinta);
}
p,
ul,
blockquote,
.table {
  margin: var(--space-4) 0 0;
}
ul {
  padding-left: 1.25rem;
}
li + li {
  margin-top: var(--space-2);
}
li::marker {
  color: var(--muted);
}
strong {
  font-weight: 650;
}
code {
  padding: 0.05em 0.35em;
  border-radius: 6px;
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 0.9em;
}
/* The date the text took effect, right under the title. */
h1 + p,
blockquote + p {
  color: var(--muted);
  font-size: var(--text-small);
}
blockquote {
  padding: var(--space-4) var(--space-5);
  border-left: 4px solid var(--warning-fill);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--surface);
}
blockquote > :first-child {
  margin-top: 0;
}

/* Tables scroll inside themselves on a phone; the page never scrolls sideways. */
.table {
  overflow-x: auto;
  border: var(--stroke) solid var(--line);
  border-radius: var(--radius-md);
}
table {
  width: 100%;
  min-width: 32rem;
  border-collapse: collapse;
  font-size: var(--text-small);
  line-height: 1.45;
}
th,
td {
  padding: var(--space-3) var(--space-4);
  text-align: left;
  vertical-align: top;
}
th {
  background: var(--surface);
  color: var(--ink-soft);
  font-weight: 650;
}
tr + tr td,
tbody tr:first-child td {
  border-top: 1px solid var(--line);
}

/* ---- The foot ---- */
.foot {
  border-top: var(--stroke) solid var(--line);
  background: var(--surface);
}
.foot nav {
  max-width: calc(var(--measure) + 2 * var(--gutter));
  margin: 0 auto;
  padding: var(--space-5) var(--gutter) var(--space-6);
  gap: var(--space-2);
}
.foot a {
  border-color: var(--line-strong);
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
@media print {
  .top nav,
  .foot,
  .skip {
    display: none;
  }
  a {
    color: inherit;
  }
}
