/*
 * Shared styling for the two public legal pages — /privacy.html and /terms.html.
 *
 * These are static files rather than routes in the app: Google's OAuth verification
 * needs a policy a reviewer can read without signing in, and the app is a single bundle
 * behind an auth gate. That means they cannot use src/styles/tokens.css either, so the
 * handful of tokens they need are repeated below. Kept in one file rather than inlined
 * twice, because two policy pages that drift apart visually look like one of them is
 * stale — which, for a legal page, is a worse impression than plain.
 *
 * Fonts are the same self-hosted files the app uses. No third-party request here: a page
 * about how carefully this handles names should not fetch a webfont from somebody else
 * in order to render.
 */

@font-face {
  font-family: 'Newsreader';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('/fonts/newsreader.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('/fonts/ibm-plex-sans.woff2') format('woff2');
}

:root {
  --plaster: #f0efea;
  --paper: #ffffff;
  --ink: #1b2430;
  --soft: #5a6672;
  --faint: #8e98a3;
  --slate: #3c566e;
  --line: #e2e0d9;
  --display: 'Newsreader', Georgia, serif;
  --ui: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --plaster: #191c1f;
    --paper: #20262e;
    --ink: #e8e6e1;
    --soft: #a8b2bd;
    --faint: #7d8894;
    --slate: #8ca3b8;
    --line: #2c333c;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0 20px calc(64px + env(safe-area-inset-bottom, 0px));
  background: var(--plaster);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 17px;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

main {
  max-width: 40rem;
  margin: 0 auto;
}

header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 40px 0 8px;
}
header img {
  width: 44px;
  height: 44px;
  border-radius: 10px;
}
header .wordmark {
  font-family: var(--display);
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1 {
  font-family: var(--display);
  font-size: 34px;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin: 24px 0 6px;
}

.dateline {
  color: var(--faint);
  font-size: 14px;
  margin: 0 0 32px;
}

h2 {
  font-family: var(--display);
  font-size: 23px;
  font-weight: 600;
  line-height: 1.25;
  margin: 40px 0 10px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

h3 {
  font-family: var(--ui);
  font-size: 16px;
  font-weight: 600;
  margin: 24px 0 6px;
}

p,
li {
  color: var(--soft);
}
p {
  margin: 0 0 14px;
}
ul {
  margin: 0 0 14px;
  padding-left: 22px;
}
li {
  margin-bottom: 7px;
}

strong {
  color: var(--ink);
  font-weight: 600;
}
a {
  color: var(--slate);
  text-underline-offset: 2px;
}

.lede {
  font-size: 19px;
  color: var(--ink);
  border-left: 3px solid var(--slate);
  padding-left: 18px;
  margin: 0 0 28px;
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 20px 22px 6px;
  margin: 0 0 18px;
}
.card h3 {
  margin-top: 0;
}

.never li {
  color: var(--ink);
}

footer {
  margin-top: 48px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 14px;
}
footer a {
  color: var(--faint);
}
