/* The privacy notice at /privacy. Loaded after site.css, which owns every token
   and every shared component used here. */

.legal-intro { max-width: 66ch; }
.legal-dates { margin-top: clamp(22px, 2.4vw, 34px); font-size: var(--text-lg); color: var(--text-muted); }
.legal-dates span + span::before { content: "·"; margin: 0 10px; }

/* A flat list of links to the sections below. Two tracks on a wide viewport, one on a
   phone. It sits in the page and scrolls away with it. */
.legal-toc {
  margin-top: clamp(30px, 3.4vw, 48px);
  padding-top: clamp(24px, 2.6vw, 34px);
  border-top: 1px solid var(--border-strong);
  columns: 2;
  column-gap: clamp(28px, 4vw, 68px);
  max-width: 74ch;
}

.legal-toc a {
  display: block;
  break-inside: avoid;
  padding-block: 7px;
  font-size: var(--text-lg);
  color: var(--text);
  text-decoration: none;
  transition: color var(--motion-base) var(--ease-out);
}

.legal-toc a:active { color: var(--emerald); }
@media (hover: hover) { .legal-toc a:hover { color: var(--emerald-deep); } }
.legal-toc a b { font-weight: 400; color: var(--text-muted); margin-right: 9px; font-variant-numeric: tabular-nums; }

/* Section: the title holds a column of its own, the way an open role does. */
.legal-section {
  display: grid;
  grid-template-columns: minmax(0, 268px) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 68px);
  align-items: start;
  padding-block: clamp(32px, 3.4vw, 52px);
  border-top: 1px solid var(--border);
}

.legal-section:first-of-type { border-top-color: var(--border-strong); }
.legal-section:last-of-type { padding-bottom: 0; }

/* The title holds the first track. Everything else stacks down the second one, so a
   section can alternate prose and a table without either landing under the title. */
.legal-section > :not(h2) { grid-column: 2; }

.legal-section h2 {
  font-family: var(--font-sans);
  font-weight: var(--weight-heading);
  font-size: var(--text-2xl);
  line-height: var(--leading-heading);
  color: var(--ink);
  scroll-margin-top: 24px;
}

.legal-section h2 b { display: block; margin-bottom: 8px; font-size: var(--text-md); font-weight: var(--weight-label); color: var(--text-label); }

.legal-body { max-width: 66ch; }
.legal-body > :first-child { margin-top: 0; }
.legal-body p + p { margin-top: 1.05em; }
.legal-body ul + p { margin-top: 1.05em; }
.legal-body .legal-aside + p, .legal-body .legal-table-scroll + p { margin-top: 1.4em; }

.legal-body h3 {
  margin-top: clamp(28px, 2.8vw, 40px);
  margin-bottom: 10px;
  font-size: var(--text-xl);
  font-weight: var(--weight-heading);
  color: var(--ink);
}

.legal-body ul { margin: 1.05em 0 0; padding-left: 0; list-style: none; }
.legal-body li { position: relative; padding-left: 22px; margin-top: .7em; }
.legal-body li::before { position: absolute; left: 4px; top: -1px; content: "·"; color: var(--sage); }
.legal-body a { color: var(--emerald-deep); text-decoration-color: var(--emerald); text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }

/* A quiet aside. A rule, not a box: the site gives a box to controls, not to prose. */
.legal-aside {
  margin-top: clamp(26px, 2.6vw, 36px);
  padding-left: clamp(16px, 1.6vw, 22px);
  border-left: 2px solid var(--emerald);
  color: var(--ink-soft);
}

/* Tables. The body measure is too narrow for them, so they take the section's full
   track and scroll inside themselves on a phone. */
.legal-table-scroll {
  margin-top: 1.4em;
  overflow-x: auto;
  border-top: 1px solid var(--border-strong);
}

.legal-table { border-collapse: collapse; width: 100%; min-width: 540px; font-size: var(--text-lg); }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: 14px 20px 14px 0; border-bottom: 1px solid var(--border); }
.legal-table th:last-child, .legal-table td:last-child { padding-right: 0; }
.legal-table thead th { padding-top: 12px; font-size: var(--text-md); font-weight: var(--weight-label); color: var(--ink); }
.legal-table td { color: var(--text); }
.legal-table td:first-child { color: var(--ink-soft); font-weight: 500; }
.legal-table .num { font-variant-numeric: tabular-nums; white-space: nowrap; }

@media (max-width: 900px) {
  .legal-section { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .legal-section > :not(h2) { grid-column: 1; }
  .legal-toc { columns: 1; }
}
