/* Shared stylesheet for the static documents: the three in /legal/, the
 * research log (/research-log.html), the methodology page
 * (/methodology.html) and the property-site guide (/property-sites.html),
 * the last three adding their tables' or list's rules inline.
 *
 * public/ is copied verbatim by vite, so these pages cannot pull in
 * src/styles/tokens.css -- that file only exists inside the bundle. The values
 * below are copied from it and have to be kept in step by hand; that is the
 * price of legal pages that render with no JS, no bundle and no build step,
 * which is what a regulator or a search crawler should be able to read.
 */

@font-face {
  font-family: "Chivo";
  src: url("/fonts/ui/chivo-latin-wght.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Chivo";
  src: url("/fonts/ui/chivo-latin-ext-wght.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
    U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg-space: #080b0f;
  --glass-bg: #11151a;
  --glass-border: #2d3239;
  --radius-card: 6px;
  --text-hi: #eaedf1;
  --text-mid: #ccd1d9;
  --text-lo: #a5adb8;
  --font-ui: "Chivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 180ms;
  --accent: #b3b3dd;
  --accent-soft: #38365d8c;
  /* the safe areas, as tokens.css reads them: inside the apps the page runs
     under the status bar, a landscape notch or the Duo's side strip */
  --sat: var(--safe-area-inset-top, env(safe-area-inset-top, 0px));
  --sal: var(--safe-area-inset-left, env(safe-area-inset-left, 0px));
  --sar: var(--safe-area-inset-right, env(safe-area-inset-right, 0px));
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: var(--bg-space);
  color: var(--text-hi);
  font-family: var(--font-ui);
  font-weight: 400;
  line-height: 1.75;
  -webkit-text-size-adjust: 100%;
}

.doc {
  /* a text column, not a layout: ~70 characters is the readable width */
  max-width: 46rem;
  margin: 0 auto;
  padding: calc(28px + var(--sat)) calc(22px + var(--sar)) 80px calc(22px + var(--sal));
}

.back {
  display: inline-block;
  margin-bottom: 26px;
  color: var(--text-lo);
  font-size: 0.9rem;
  text-decoration: none;
  transition: color var(--t-fast) var(--ease);
}

.back:hover,
.back:focus-visible {
  color: var(--accent);
}

h1 {
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.updated {
  margin: 8px 0 34px;
  color: var(--text-lo);
  font-size: 0.85rem;
}

h2 {
  margin: 38px 0 12px;
  font-size: 1.12rem;
  font-weight: 600;
  color: var(--text-hi);
}

h3 {
  margin: 24px 0 8px;
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text-hi);
}

p,
li {
  color: var(--text-mid);
  font-size: 1rem;
}

p + p {
  margin-top: 12px;
}

ul,
ol {
  margin: 12px 0 12px 22px;
}

li + li {
  margin-top: 7px;
}

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

strong {
  color: var(--text-hi);
  font-weight: 600;
}

code {
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.07);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
}

dl {
  margin: 12px 0;
}

dt {
  margin-top: 14px;
  color: var(--text-hi);
  font-weight: 600;
}

dd {
  margin-left: 0;
  color: var(--text-mid);
}

/* the one thing on the page that must not be missed: the no-warranty notice
   on Terms, and the automated-moderation notice on Privacy */
.callout {
  margin: 22px 0;
  padding: 16px 18px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-card);
  background: var(--glass-bg);
}

.callout p + p {
  margin-top: 10px;
}

/* Operator details that do not exist yet. Deliberately loud: this is what has
   to be filled in before the site is reachable from the public internet, and a
   quiet placeholder is one that ships. */
.fill-in {
  display: inline-block;
  padding: 1px 8px;
  border: 1px dashed var(--accent);
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
  font-size: 0.92em;
}

.doc-nav {
  margin-top: 52px;
  padding-top: 18px;
  border-top: 1px solid var(--glass-border);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  color: var(--text-lo);
  font-size: 0.88rem;
}

.doc-nav a {
  color: var(--text-lo);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease);
}

.doc-nav a:hover,
.doc-nav a:focus-visible {
  color: var(--accent);
}

@media (max-width: 640px) {
  .doc {
    padding: calc(20px + var(--sat)) calc(16px + var(--sar)) 64px calc(16px + var(--sal));
  }
}
