/* legal.css — shared styling for /privacy and /terms.
   Kept as a real stylesheet (not inline) so the two documents can never drift
   from each other visually. Light and dark are both defined explicitly; the
   page must never borrow a background from the host. */

/* The palette lives in tokens.css, which mirrors the iOS asset catalog. These
   names stay so the rules below need no rewrite, but every value now resolves
   to a real MoneyBeh token rather than a web-only approximation of one. */
:root {
  --bg: var(--mb-background);
  --surface: var(--mb-surface);
  --text: var(--mb-text-primary);
  --text-secondary: var(--mb-text-secondary);
  --text-tertiary: var(--mb-text-tertiary);
  --border: var(--mb-border);
  --accent: var(--mb-accent);
  --callout-bg: var(--mb-accent-soft);
}

/* No dark override here on purpose. tokens.css redefines the mb-* tokens under
   prefers-color-scheme: dark, and the aliases above resolve through to them, so
   a second list of colors would be a second place to forget to update. */

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-text-size-adjust: 100%;
}

.wrap {
  max-width: 46rem;
  margin: 0 auto;
  padding: 56px 24px 96px;
}

header.doc {
  border-bottom: 1px solid var(--border);
  padding-bottom: 28px;
  margin-bottom: 40px;
}

.eyebrow {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 10px;
  font-weight: 500;
}

h1 {
  font-size: 34px;
  font-weight: 300;
  letter-spacing: -0.01em;
  margin: 0 0 14px;
  line-height: 1.2;
}

.dates {
  font-size: 14px;
  color: var(--text-tertiary);
  margin: 0;
}

h2 {
  font-size: 21px;
  font-weight: 500;
  margin: 48px 0 14px;
  letter-spacing: -0.005em;
  scroll-margin-top: 24px;
}

h3 {
  font-size: 17px;
  font-weight: 600;
  margin: 30px 0 10px;
}

p { margin: 0 0 16px; }

ul, ol { margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 9px; }

a { color: var(--accent); }
a:hover { text-decoration: none; }

strong { font-weight: 600; }

.lede {
  font-size: 19px;
  line-height: 1.6;
  color: var(--text-secondary);
}

.callout {
  background: var(--callout-bg);
  border-left: 3px solid var(--accent);
  border-radius: 0 8px 8px 0;
  padding: 18px 20px;
  margin: 0 0 22px;
}
.callout p:last-child { margin-bottom: 0; }

.table-scroll { overflow-x: auto; margin: 0 0 22px; }

table {
  border-collapse: collapse;
  width: 100%;
  font-size: 15px;
  min-width: 30rem;
}
th, td {
  text-align: left;
  vertical-align: top;
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
}
th {
  font-weight: 600;
  color: var(--text-secondary);
  background: var(--surface);
  font-size: 13px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.toc {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px 24px;
  margin-bottom: 44px;
}
.toc p {
  margin: 0 0 10px;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  font-weight: 500;
}
.toc ol { margin: 0; padding-left: 20px; font-size: 15px; }
.toc li { margin-bottom: 5px; }

footer.doc {
  margin-top: 64px;
  padding-top: 26px;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--text-tertiary);
}
footer.doc a { margin-right: 18px; }

@media (max-width: 600px) {
  body { font-size: 16px; }
  .wrap { padding: 40px 20px 72px; }
  h1 { font-size: 28px; }
  h2 { font-size: 19px; }
  .lede { font-size: 17px; }
}
