/* ==========================================================================
   PayPress — legal.css
   Reading-column layout + vertical rhythm for legal/document pages
   (Privacy Policy, Terms & Conditions, future legal docs).
   Loaded only when the "Legal Page" template is active. Scoped entirely
   under .legal-content — does not touch global typography.
   ========================================================================== */

.legal-content {
  max-width: 760px;
  margin: 0 auto;
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--color-ink-soft);
}

/* Baseline rhythm: paragraph → paragraph, and a sane default for any
   other adjacent elements not covered by a more specific rule below. */
.legal-content > * + * { margin-top: var(--space-5); }

/* ---------- Headings ---------- */
.legal-content h2 {
  margin-top: var(--space-8);
  font-size: 25px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-ink);
}
.legal-content h3 {
  margin-top: var(--space-7);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--color-ink);
}

/* Small gap below a heading before its paragraph/list begins —
   H3 sits slightly tighter than H2, per the page's vertical scale. */
.legal-content h2 + p,
.legal-content h2 + ul,
.legal-content h2 + ol { margin-top: var(--space-3); }
.legal-content h3 + p,
.legal-content h3 + ul,
.legal-content h3 + ol { margin-top: var(--space-2); }

/* A list directly followed by a heading should still read as a new
   section — match the heading's own top margin, not the list's. */
.legal-content ul + h2,
.legal-content ol + h2 { margin-top: var(--space-8); }
.legal-content ul + h3,
.legal-content ol + h3 { margin-top: var(--space-7); }

/* ---------- Paragraphs & lists ---------- */
.legal-content p { line-height: 1.75; }

.legal-content p + ul,
.legal-content p + ol { margin-top: var(--space-6); }
.legal-content ul + p,
.legal-content ol + p { margin-top: var(--space-6); }

.legal-content ul,
.legal-content ol {
  padding-left: var(--space-5);
  line-height: 1.75;
}
.legal-content li + li { margin-top: var(--space-2); }
.legal-content li { padding-left: var(--space-1); }

/* ---------- Inline elements ---------- */
.legal-content a { color: var(--color-primary); font-weight: 600; }
.legal-content a:hover { text-decoration: underline; }
.legal-content strong { color: var(--color-ink); font-weight: 700; }
