/* Legal-page layout only. Shared chrome + primitives (.btn/.tag, nav,
   footer) live in /components.css (base.njk + the scanner Pages Function).
   Design tokens come from the shared /tokens.css — see adr/0016. */

/* Legal pages read as documents: slightly looser body rhythm and
   underlined in-text links, scoped so the shared chrome is unaffected. */
body { line-height: 1.55; }

/* Pages that don't end on a ruled section carry the footer's top rule. */
.site-footer { border-top: 1.5px solid hsl(var(--ink)); }

/* ---------- legal layout ---------- */
.legal {
  padding: 80px 48px;
  max-width: 880px;
  margin: 0 auto;
}
.legal-head { margin-bottom: 48px; }
/* Utility pages don't shout: match the homepage section-head scale (52px),
   not the hero scale. */
.legal-head h1 {
  font-size: clamp(36px, 5vw, 52px);
  line-height: 1;
  margin: 16px 0 12px;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.legal-head .meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: hsl(var(--ink-muted));
  letter-spacing: 0.04em;
}
.legal-body { font-size: 17px; line-height: 1.65; }
.legal-body h2 {
  font-size: 28px;
  line-height: 1.15;
  margin: 48px 0 16px;
  border-top: 1.5px solid hsl(var(--ink));
  padding-top: 32px;
}
.legal-body h2:first-of-type { margin-top: 16px; }
.legal-body h3 {
  font-size: 19px;
  line-height: 1.2;
  margin: 32px 0 12px;
  font-weight: 700;
}
.legal-body p { margin: 0 0 16px; max-width: 70ch; }
.legal-body ul, .legal-body ol { margin: 0 0 16px 24px; }
.legal-body li { margin-bottom: 8px; max-width: 68ch; }
.legal-body strong { font-weight: 700; }
.legal-body a {
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
.legal-body code {
  font-size: 14px;
  background: hsl(var(--paper-2));
  padding: 1px 6px;
  border: 1px solid hsl(var(--hairline));
}
.legal-body hr {
  border: 0;
  border-top: 1.5px solid hsl(var(--ink));
  margin: 48px 0;
}

/* ---------- legal tables ---------- */
.legal-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 24px;
  font-size: 14px;
  line-height: 1.45;
}
.legal-table th,
.legal-table td {
  border: 1.5px solid hsl(var(--ink));
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.legal-table th {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: hsl(var(--paper-2));
}
.legal-table code { font-size: 13px; }
/* Wide tables scroll inside their own container instead of the page body. */
.legal-table-wrap { overflow-x: auto; margin: 0 0 24px; }
.legal-table-wrap .legal-table { margin: 0; min-width: 640px; }

/* ---------- responsive ---------- */
@media (max-width: 719px) {
  .legal { padding: 56px 20px; }
  .legal-head h1 { font-size: clamp(32px, 9vw, 48px); }
  .legal-body { font-size: 16px; }
  .legal-body h2 { font-size: 24px; padding-top: 24px; margin-top: 40px; }
}
@media (max-width: 479px) {
  .legal { padding: 40px 16px; }
}
