/* Shared styles for legal pages (privacy policy, terms of use) */

.legal-hero { padding: 96px 0 56px; }
.legal-hero .eyebrow { display: inline-block; }
.legal-title {
  font-weight: 700;
  font-size: clamp(2.75rem, 6.2vw, 6rem);
  line-height: 0.92;
  letter-spacing: -0.015em;
  text-transform: uppercase;
  margin: 24px 0 32px;
  text-wrap: balance;
}
.legal-lede {
  font-size: clamp(1.1rem, 1.6vw, 1.4rem);
  line-height: 1.45;
  max-width: 60ch;
  margin: 0 0 24px;
  opacity: 0.85;
}

/* The little "please review" caution callout on Terms */
.legal-flag {
  margin-top: 24px;
  padding: 18px 22px;
  border-left: 3px solid var(--night-blue);
  background: rgba(19, 23, 54, 0.04);
  font-size: 0.95rem;
  line-height: 1.5;
  max-width: 60ch;
}

/* Page body — two-column on desktop, stacked on mobile */
.legal-body { padding: 32px 0 96px; border-top: 1px solid var(--ink-12); }
.legal-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 64px;
  align-items: start;
}
@media (max-width: 920px) {
  .legal-grid { grid-template-columns: 1fr; gap: 32px; }
}

/* Sticky table of contents */
.legal-toc {
  position: sticky;
  top: 120px;
  font-family: "Relative", "Helvetica Neue", Helvetica, Arial, sans-serif;
}
@media (max-width: 920px) {
  .legal-toc { position: static; padding: 16px 0; border-top: 1px solid var(--ink-12); border-bottom: 1px solid var(--ink-12); }
}
.legal-toc-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  opacity: 0.5;
  margin: 0 0 16px;
}
.legal-toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: toc;
  display: grid;
  gap: 10px;
}
.legal-toc li {
  counter-increment: toc;
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 0.9rem;
  line-height: 1.35;
}
.legal-toc li::before {
  content: counter(toc, decimal-leading-zero);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  font-weight: 700;
  opacity: 0.4;
  min-width: 20px;
}
.legal-toc a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 1px;
  transition: border-color 150ms ease, opacity 150ms ease;
  opacity: 0.85;
}
.legal-toc a:hover, .legal-toc a:focus { border-bottom-color: currentColor; opacity: 1; }

/* Long-form prose */
.legal-prose {
  max-width: 70ch;
  font-size: 1rem;
  line-height: 1.65;
}
.legal-prose > p:first-of-type {
  font-size: 1.05rem;
  line-height: 1.55;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--ink-12);
  margin-bottom: 32px;
}
.legal-prose h2 {
  font-family: inherit;
  font-weight: 700;
  font-size: 1.4rem;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
  margin: 56px 0 16px;
  padding-top: 24px;
  border-top: 1px solid var(--ink-12);
  scroll-margin-top: 100px;
}
.legal-prose h2:first-of-type { margin-top: 32px; }
.legal-prose p { margin: 0 0 18px; text-wrap: pretty; }
.legal-prose ul {
  margin: 0 0 22px;
  padding: 0 0 0 22px;
  list-style: none;
}
.legal-prose ul li {
  position: relative;
  padding-left: 4px;
  margin: 0 0 8px;
  line-height: 1.55;
}
.legal-prose ul li::before {
  content: "";
  position: absolute;
  left: -16px;
  top: 0.7em;
  width: 8px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}
.legal-prose a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.legal-prose a:hover { text-decoration-thickness: 2px; }
.legal-prose strong { font-weight: 700; }

/* All-caps legal blocks (disclaimers, liability, arbitration) — set in Relative caps with letter-spacing
   for legibility, but desaturated so they read as "the fine print" rather than shouting headlines. */
.legal-prose .legal-allcaps {
  font-family: "Relative", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 0.78rem;
  line-height: 1.7;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 18px 22px;
  background: rgba(19, 23, 54, 0.04);
  border-left: 2px solid var(--ink-20);
  margin: 0 0 18px;
}
.legal-prose .legal-allcaps strong { font-weight: 700; }

.legal-prose .legal-copyright {
  margin-top: 48px;
  font-family: "Relative", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  opacity: 0.55;
}

.legal-foot {
  margin-top: 64px;
  padding-top: 32px;
  border-top: 1px solid var(--ink-12);
}
.legal-foot p { margin: 0; }
.legal-foot a {
  font-family: "Relative", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}
