/* ============================================================
   107.design — Legal pages styles
   Shared across privacy, terms, cookies, accessibility pages.
   ============================================================ */

:root {
  --paper: #F2EEE6;
  --ink: #16130F;
  --accent: #4B36F5;
  --accent-light: #9D93FF;
  --muted: rgba(22, 19, 15, 0.55);
  --label: rgba(22, 19, 15, 0.42);
  --line: rgba(22, 19, 15, 0.14);
  --pad: clamp(20px, 4.5vw, 76px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font-d: 'Clash Display', 'Inter', system-ui, sans-serif;
  --font-s: 'Instrument Serif', Georgia, serif;
  --font-b: 'Inter', system-ui, sans-serif;
  --font-m: 'JetBrains Mono', ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-b);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; transition: color 0.25s; }
a:hover { color: var(--ink); }

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

/* ─── Nav ──────────────────────────────────────────────────── */

.legal-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px var(--pad);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.legal-nav-logo {
  font-family: var(--font-d);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.25s;
}
.legal-nav-logo:hover { color: var(--accent); text-decoration: none; }
.legal-nav-logo sup { font-size: 0.5em; }

.legal-nav-back {
  font-family: var(--font-m);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.25s;
}
.legal-nav-back:hover { color: var(--ink); text-decoration: none; }

/* ─── Content ──────────────────────────────────────────────── */

.legal-page {
  max-width: 780px;
  margin: 80px auto 40px;
  padding: 0 var(--pad);
  scroll-margin-top: 80px;
}

.legal-page h1 {
  font-family: var(--font-d);
  font-weight: 600;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.legal-page .legal-meta {
  display: block;
  font-family: var(--font-m);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--label);
  margin-bottom: 48px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 16px;
}

.legal-page h2 {
  font-family: var(--font-d);
  font-weight: 600;
  font-size: clamp(1.3rem, 2.5vw, 1.7rem);
  letter-spacing: -0.01em;
  margin: 48px 0 14px;
  padding-top: 4px;
}

.legal-page h3 {
  font-family: var(--font-d);
  font-weight: 500;
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  margin: 32px 0 10px;
}

.legal-page p {
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  margin-bottom: 14px;
}

.legal-page a {
  word-break: break-word;
}

.legal-page ul,
.legal-page ol {
  margin: 0 0 14px 24px;
  font-size: 15px;
  line-height: 1.7;
}

.legal-page li { margin-bottom: 6px; }

.legal-page hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 48px 0;
}

.legal-page .legal-highlight {
  background: rgba(75, 54, 245, 0.06);
  border-left: 3px solid var(--accent);
  padding: 16px 20px;
  margin: 24px 0;
  border-radius: 0 4px 4px 0;
  font-size: 14px;
  line-height: 1.6;
}

.legal-page .legal-highlight a { color: var(--accent); }

/* ─── Footer ───────────────────────────────────────────────── */

.legal-footer {
  max-width: 780px;
  margin: 60px auto;
  padding: 0 var(--pad);
  text-align: center;
}

.legal-footer-inner {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.legal-footer-inner a {
  font-family: var(--font-m);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-decoration: none;
  position: relative;
  padding: 0 12px;
}
.legal-footer-inner a:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -4px;
  top: 50%;
  transform: translateY(-50%);
  width: 1px;
  height: 11px;
  background: var(--line);
}
.legal-footer-inner a:hover { color: var(--ink); text-decoration: underline; }

.legal-footer-inner .footer-cookie-btn {
  font-family: var(--font-m);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 12px;
  position: relative;
  transition: color 0.25s;
}

.legal-footer-inner .footer-cookie-btn:hover { color: var(--ink); text-decoration: underline; }

.legal-footer-copy {
  margin-top: 12px;
  font-family: var(--font-m);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--label);
}

/* ─── Responsive ───────────────────────────────────────────── */

@media (max-width: 560px) {
  .legal-page { margin-top: 70px; }
  .legal-page h1 { font-size: 1.7rem; }
}

/* ─── Reduced motion ───────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}