/* ——— Shared legal page styles — matches main site ——— */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

:root {
  --paper: #F4F1EA;
  --paper-2: #EDE9E0;
  --ink: #0B0B0B;
  --ink-60: rgba(11,11,11,.6);
  --ink-40: rgba(11,11,11,.4);
  --ink-20: rgba(11,11,11,.2);
  --ink-10: rgba(11,11,11,.1);
  --accent: #D63A1F;
  --rule: rgba(11,11,11,.14);

  --f-display: "Europa Grotesk", "Inter", system-ui, sans-serif;
  --f-body:    "Inter", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --f-serif:   "Instrument Serif", "Times New Roman", serif;

  --pad: clamp(20px, 4vw, 56px);
}

@font-face {
  font-family: "Europa Grotesk";
  src: url("/assets/EuropaGroteskSH-DemBol.otf") format("opentype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

/* subtle paper grain */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 1;
  background-image:
    radial-gradient(rgba(0,0,0,.035) 1px, transparent 1px),
    radial-gradient(rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 3px 3px, 5px 5px;
  background-position: 0 0, 1px 2px;
  mix-blend-mode: multiply;
  opacity: .55;
}

a { color: inherit; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; text-decoration-color: var(--ink-20); transition: text-decoration-color .2s ease; }
a:hover { text-decoration-color: var(--ink); }

::selection { background: var(--ink); color: var(--paper); }

.eyebrow {
  font-family: var(--f-body);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-60);
}

/* ——— Marquee ——— */
.marquee {
  position: relative;
  border-bottom: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  overflow: hidden;
  height: 34px;
  display: flex;
  align-items: center;
  z-index: 2;
}
.marquee-track {
  display: flex;
  gap: 48px;
  white-space: nowrap;
  animation: slide 38s linear infinite;
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  padding-left: 48px;
}
.marquee-track span { display: inline-flex; align-items: center; gap: 14px; }
.marquee-track em { font-style: normal; color: #D63A1F; }
@keyframes slide { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ——— Nav ——— */
.nav {
  position: sticky; top: 0; z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px var(--pad);
  background: rgba(244,241,234,.86);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--rule);
}
.nav-brand { display: flex; align-items: center; gap: 10px; }
.logo {
  display: block;
  width: auto;
  object-fit: contain;
}
.logo-ink { filter: invert(1); }
.logo-nav { height: 84px; margin: -18px 0; }
.logo-foot { height: 72px; margin: -14px 0; }

.nav-links {
  display: flex; align-items: center; gap: 28px;
  font-size: 13px; color: var(--ink-60);
}
.nav-links a { text-decoration: none; transition: color .2s ease; }
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  padding: 10px 16px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  transition: background .2s ease, color .2s ease;
}
.nav-cta:hover { background: var(--ink); color: var(--paper); }
@media (max-width: 720px){
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ——— Page ——— */
main { position: relative; z-index: 2; }

.legal-hero {
  padding: clamp(40px, 8vh, 96px) var(--pad) clamp(28px, 4vh, 48px);
  border-bottom: 1px solid var(--ink);
}
.legal-hero .crumb {
  display: flex; gap: 10px; align-items: center;
  font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-60);
  margin-bottom: 18px;
}
.legal-hero .crumb a { text-decoration: none; }
.legal-hero .crumb .sep { opacity: .4; }
.legal-hero h1 {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: clamp(44px, 9vw, 140px);
  line-height: .94;
  letter-spacing: -0.035em;
  margin: 0 0 20px;
}
.legal-hero h1 em {
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
}
.legal-hero .updated {
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 17px;
  color: var(--ink-60);
}

.legal-wrap {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(0, 3.2fr);
  gap: clamp(24px, 5vw, 80px);
  padding: clamp(40px, 6vh, 72px) var(--pad) clamp(56px, 10vh, 120px);
}
@media (max-width: 900px) {
  .legal-wrap { grid-template-columns: 1fr; gap: 32px; }
}

/* Sticky TOC */
.toc {
  position: sticky;
  top: calc(34px + 84px); /* marquee + nav height-ish */
  align-self: start;
  font-size: 13px;
  max-height: calc(100vh - 140px);
  overflow-y: auto;
  padding-right: 8px;
}
.toc .eyebrow { display: block; margin-bottom: 14px; }
.toc ol {
  list-style: none;
  margin: 0; padding: 0;
  counter-reset: tocitem;
  display: flex; flex-direction: column; gap: 8px;
}
.toc ol li {
  counter-increment: tocitem;
  line-height: 1.4;
}
.toc ol li a {
  text-decoration: none;
  color: var(--ink-60);
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 8px;
  align-items: baseline;
  padding: 3px 0;
  transition: color .18s ease;
}
.toc ol li a::before {
  content: counter(tocitem, decimal-leading-zero);
  font-family: var(--f-serif); font-style: italic;
  font-size: 12px; color: var(--ink-40);
}
.toc ol li a:hover { color: var(--ink); }
@media (max-width: 900px){
  .toc { position: static; max-height: none; border-bottom: 1px solid var(--rule); padding-bottom: 24px; }
}

/* ——— Prose ——— */
.prose {
  max-width: 72ch;
  font-size: 16px;
  line-height: 1.68;
  color: var(--ink);
}
.prose > * + * { margin-top: 1.05em; }

.prose h2 {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 2.2em 0 0.6em;
  padding-top: 1.8em;
  border-top: 1px solid var(--rule);
  scroll-margin-top: 130px;
}
.prose h2:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.prose h2 .num {
  display: inline-block;
  font-family: var(--f-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 14px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-60);
  margin-right: 12px;
  transform: translateY(-4px);
}

.prose h3 {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin: 1.8em 0 0.3em;
  color: var(--ink);
}

.prose p { margin: 0; }
.prose strong { font-weight: 600; }
.prose em { font-family: var(--f-serif); font-style: italic; font-weight: 400; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }

.prose ul, .prose ol {
  padding-left: 1.35em;
  margin: 0.2em 0 0;
  display: flex; flex-direction: column; gap: 6px;
}
.prose ul li::marker { color: var(--ink-40); }
.prose ol li::marker { color: var(--ink-40); font-family: var(--f-serif); font-style: italic; }

.prose blockquote {
  border-left: 2px solid var(--ink);
  margin: 1.4em 0;
  padding: 2px 0 2px 20px;
  font-family: var(--f-serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ink);
}

.prose hr {
  border: 0;
  height: 1px;
  background: var(--rule);
  margin: 2.6em 0;
}

.prose .callout {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: 18px 20px;
  font-size: 15px;
}
.prose .callout strong { display: block; font-family: var(--f-display); font-weight: 600; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; margin-bottom: 6px; }

.contact-card {
  margin-top: 2.4em;
  padding: 24px 26px;
  border: 1px solid var(--ink);
  border-radius: 18px;
  background: var(--paper-2);
}
.contact-card .eyebrow { display: block; margin-bottom: 8px; }
.contact-card .name {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}
.contact-card a { text-decoration: underline; }

/* ——— Footer ——— */
footer {
  padding: 34px var(--pad) 40px;
  border-top: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-60);
  position: relative;
  z-index: 2;
}
footer nav { display: flex; gap: 22px; flex-wrap: wrap; }
footer nav a { text-decoration: none; transition: color .2s ease; }
footer nav a:hover { color: var(--ink); }

.socials {
  display: inline-flex;
  gap: 8px;
  align-items: center;
}
.socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 999px;
  border: 1px solid var(--ink-20);
  color: var(--ink);
  text-decoration: none;
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}
.socials a:hover {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
  transform: translateY(-1px);
}
.socials svg { width: 16px; height: 16px; display: block; }

@media (prefers-reduced-motion: reduce) { .marquee-track { animation: none; } }
