/* Shared styling for the public legal + support pages (/privacy, /terms, /support). */

:root {
  --bg: #ffffff;
  --surface: #f7f7f8;
  --text: #16181d;
  --muted: #5c6169;
  --rule: #e5e6ea;
  --accent: #007aff;
  --accent-soft: rgba(0, 122, 255, 0.09);
  --maxw: 46rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115;
    --surface: #171a20;
    --text: #e9eaee;
    --muted: #9aa0aa;
    --rule: #262a32;
    --accent: #4da3ff;
    --accent-soft: rgba(77, 163, 255, 0.12);
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  padding: 0 1.25rem 5rem;
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  overflow-wrap: break-word;
}

.wrap { max-width: var(--maxw); margin: 0 auto; }

/* ---- masthead ---- */

.masthead {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1.5rem 0 1.25rem;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 2.5rem;
}

.masthead a.brand {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.masthead nav {
  margin-left: auto;
  display: flex;
  gap: 1.1rem;
  font-size: 0.9rem;
}

.masthead nav a { color: var(--muted); text-decoration: none; }
.masthead nav a:hover,
.masthead nav a[aria-current="page"] { color: var(--text); }

/* ---- headings ---- */

h1 {
  font-size: 2rem;
  line-height: 1.2;
  letter-spacing: -0.022em;
  margin: 0 0 0.5rem;
}

h2 {
  font-size: 1.25rem;
  letter-spacing: -0.014em;
  margin: 2.75rem 0 0.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
}

h3 {
  font-size: 1.02rem;
  margin: 1.75rem 0 0.5rem;
}

h2 + h3 { margin-top: 1rem; }

.effective {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0 0 2rem;
}

.lede {
  font-size: 1.06rem;
  color: var(--muted);
  margin: 0 0 2rem;
}

/* ---- body copy ---- */

p, li { margin: 0.75rem 0; }
ul, ol { padding-left: 1.35rem; }
li { margin: 0.4rem 0; }

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

strong { font-weight: 600; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.88em;
  background: var(--surface);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

/* ---- callout ---- */

.callout {
  background: var(--accent-soft);
  border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0;
  padding: 0.9rem 1.1rem;
  margin: 1.5rem 0;
}

.callout p:first-child { margin-top: 0; }
.callout p:last-child { margin-bottom: 0; }

/* ---- table of contents ---- */

.toc {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
  margin: 0 0 2rem;
}

.toc h2 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin: 0 0 0.6rem;
  padding: 0;
  border: 0;
}

.toc ol { margin: 0; padding-left: 1.25rem; font-size: 0.94rem; }
.toc li { margin: 0.28rem 0; }
.toc a { color: var(--text); text-decoration: none; }
.toc a:hover { color: var(--accent); text-decoration: underline; }

/* ---- tables ---- */

.table-scroll { overflow-x: auto; margin: 1.25rem 0; }

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.94rem;
}

/* Two-column tables read fine at any width, so they stay fluid. Only the
   three-column ones get a floor and scroll inside their own container —
   the page body itself must never scroll sideways. */
.table-scroll.wide table { min-width: 34rem; }

th, td {
  text-align: left;
  vertical-align: top;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid var(--rule);
}

th {
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  border-bottom-width: 2px;
}

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

/* ---- footer ---- */

footer {
  margin-top: 4rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.88rem;
}

footer a { color: var(--muted); }

/* A spot the operator must fill in before publishing. */
.fillme {
  background: #ffe9a8;
  color: #4a3800;
  padding: 0.08em 0.4em;
  border-radius: 4px;
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 34rem) {
  body { font-size: 16px; }
  h1 { font-size: 1.6rem; }
  .masthead { flex-wrap: wrap; }
  .masthead nav { margin-left: 0; width: 100%; padding-top: 0.5rem; }
}
