/* Sonar — legal documents. Same plate as the landing page: engraved rules,
   serif heads, one accent. Set in a single measure because these are read,
   not scanned. */

:root {
  --paper: #F5F0E5;
  --ink: #24211C;
  --ink-soft: #746D62;
  --ink-faint: #A79F92;
  --accent: #177E5B;
  --rule: rgba(36, 33, 28, 0.22);
  --wash: rgba(36, 33, 28, 0.035);
  --serif: "New York", ui-serif, "Iowan Old Style", "Times New Roman", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #171511;
    --ink: #F5F2EB;
    --ink-soft: #A8A196;
    --ink-faint: #6C655A;
    --accent: #4CCF9F;
    --rule: rgba(245, 242, 235, 0.22);
    --wash: rgba(245, 242, 235, 0.045);
  }
}
:root[data-theme="dark"] {
  --paper: #171511; --ink: #F5F2EB; --ink-soft: #A8A196; --ink-faint: #6C655A;
  --accent: #4CCF9F; --rule: rgba(245, 242, 235, 0.22); --wash: rgba(245, 242, 235, 0.045);
}
:root[data-theme="light"] {
  --paper: #F5F0E5; --ink: #24211C; --ink-soft: #746D62; --ink-faint: #A79F92;
  --accent: #177E5B; --rule: rgba(36, 33, 28, 0.22); --wash: rgba(36, 33, 28, 0.035);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { color-scheme: light dark; scroll-behavior: smooth; }
html, body { overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.68 var(--sans);
  -webkit-font-smoothing: antialiased;
}
/* Same plate as the landing page — masthead, rules and footer sit on exactly
   the same 880px measure, so the pages line up when you move between them.
   The prose runs narrower inside it: 880px of 17px text is a 100-character
   line, and nobody reads a privacy policy at 100 characters. */
main { max-width: 880px; margin: 0 auto; padding: 0 28px; }
.title, .contents, article, footer .links { max-width: 700px; margin-inline: auto; }

.rule { position: relative; height: 1px; background: var(--rule); }
.rule::before, .rule::after {
  content: ""; position: absolute; top: -4px; width: 1px; height: 9px; background: var(--rule);
}
.rule::before { left: 0; }
.rule::after { right: 0; }

.micro {
  font: 600 11px/1.5 var(--sans);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

/* ── masthead ── */
header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 30px 0 22px;
}
.wordmark { display: flex; align-items: center; gap: 14px; color: var(--ink); text-decoration: none; }
/* identical to the landing page masthead — 40px mark, 24px wordmark */
.wordmark svg { width: 40px; height: 40px; color: var(--accent); flex: none; }
.wordmark span { font: 600 24px/1 var(--serif); letter-spacing: -0.01em; }

/* ── title block ── */
.title { padding: 60px 0 40px; }
.title h1 {
  font: 600 clamp(31px, 5.4vw, 42px)/1.14 var(--serif);
  letter-spacing: -0.016em;
  text-wrap: balance;
}
.title .stamp { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 6px 22px; }
.title .lede {
  margin-top: 26px; color: var(--ink-soft); text-wrap: pretty;
  font-size: 17.5px;
}

/* ── contents ── */
.contents { padding: 30px 0 6px; }
.contents .micro { display: block; margin-bottom: 14px; }
.contents ol {
  list-style: none;
  columns: 2; column-gap: 34px;
  font-size: 14.5px; line-height: 1.9;
}
@media (max-width: 560px) { .contents ol { columns: 1; } }
.contents a { color: var(--ink-soft); text-decoration: none; }
.contents a:hover { color: var(--accent); }
.contents li::before {
  content: "§ " counter(toc);
  counter-increment: toc;
  color: var(--ink-faint);
  font: 600 12px/1 var(--serif);
  margin-right: 9px;
}
.contents ol { counter-reset: toc; }

/* ── body ── */
/* The closing rule needs air on both sides — at 10px it read as
   underlining the last paragraph rather than separating the footer. */
article { padding: 26px 0 52px; counter-reset: sect; }
article section { padding: 40px 0 0; scroll-margin-top: 22px; }
article h2 {
  font: 600 22px/1.32 var(--serif);
  letter-spacing: -0.008em;
  margin-bottom: 6px;
  text-wrap: balance;
}
article h2::before {
  content: "§ " counter(sect);
  counter-increment: sect;
  display: block;
  font: 600 14px/1 var(--serif);
  color: var(--accent);
  margin-bottom: 12px;
  letter-spacing: 0;
}
article h3 {
  font: 600 15px/1.4 var(--sans);
  margin: 26px 0 6px;
}
article p { margin-top: 14px; color: var(--ink); text-wrap: pretty; }
article p.note { color: var(--ink-soft); font-size: 15.5px; }
article ul { margin: 14px 0 0 0; padding: 0; list-style: none; }
article ul li {
  position: relative; padding-left: 20px; margin-top: 9px; text-wrap: pretty;
}
article ul li::before {
  content: ""; position: absolute; left: 2px; top: 12px;
  width: 5px; height: 1px; background: var(--ink-faint);
}
article a { color: var(--accent); text-underline-offset: 3px; }
article strong { font-weight: 600; }

/* the conspicuous clauses — U.C.C. 1-201(b)(10): contrasting type, set off */
.conspicuous {
  margin-top: 20px;
  border-left: 2px solid var(--accent);
  background: var(--wash);
  padding: 18px 22px;
}
.conspicuous p { font-weight: 600; }
.conspicuous p:first-child { margin-top: 0; }

/* collection table */
.tablewrap { margin-top: 20px; overflow-x: auto; }
table { border-collapse: collapse; width: 100%; min-width: 460px; font-size: 15.5px; }
th, td { text-align: left; vertical-align: top; padding: 13px 18px 13px 0; }
th {
  font: 600 11px/1.5 var(--sans); letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-faint); border-bottom: 1px solid var(--rule); padding-bottom: 10px;
}
td { border-bottom: 1px solid var(--rule); }
td:first-child { font-weight: 600; width: 31%; padding-right: 26px; }
tr:last-child td { border-bottom: none; }

/* On a phone the collection table stacks instead of scrolling sideways — a
   horizontal scroll inside a legal document is a good way to have half of it
   go unread. The source becomes the label above each entry. */
@media (max-width: 560px) {
  table { min-width: 0; }
  thead {
    position: absolute; width: 1px; height: 1px;
    overflow: hidden; clip-path: inset(50%); white-space: nowrap;
  }
  tbody tr { display: block; padding: 16px 0; border-bottom: 1px solid var(--rule); }
  tbody tr:last-child { border-bottom: none; }
  td { display: block; padding: 0; border: none; }
  td:first-child {
    width: auto; padding: 0 0 7px;
    font: 600 11px/1.5 var(--sans); letter-spacing: 0.14em;
    text-transform: uppercase; color: var(--ink-faint);
  }
}

/* ── footer ── */
footer { padding: 56px 0 72px; text-align: center; }
footer .links { display: flex; justify-content: center; gap: 26px; flex-wrap: wrap; margin-bottom: 18px; }
footer a { color: var(--ink-soft); text-decoration: none; font-size: 14px; }
footer a:hover { color: var(--accent); }
footer .legal { font-size: 12.5px; color: var(--ink-faint); }

a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
