/* ── Design Tokens (ported from frank-privacy/index.html:23-64) ── */
:root {
  --bg: #0E0E0E;
  --bg-warm: #121110;
  --surface: #1A1918;
  --surface-elevated: #242220;
  --primary: #9AC494;
  --primary-dim: rgba(154, 196, 148, 0.12);
  --primary-glow: rgba(154, 196, 148, 0.06);
  --secondary: #8DB4D4;
  --text: #E8E4DF;
  --text-secondary: #B5AFA7;
  --muted: #7A756E;
  --border: rgba(155, 149, 139, 0.08);
  --border-hover: rgba(154, 196, 148, 0.2);

  --font-heading: 'Instrument Serif', Georgia, serif;
  --font-body: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;

  --text-xs: 0.8rem;
  --text-sm: 0.9rem;
  --text-base: 1rem;
  --text-lg: 1.15rem;
  --text-xl: 1.35rem;
  --text-2xl: 1.75rem;
  --text-3xl: 2.25rem;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;

  --max-width-narrow: 680px;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --duration: 0.6s;
}

/* ── Reset & Base ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Grain overlay — paired with the inline SVG <filter id="grain"> in each HTML file */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.022;
  filter: url(#grain);
  width: 100%;
  height: 100%;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.3s var(--ease-out);
}

a:hover { color: var(--primary); }
a:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Header ── */
.legal-header {
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--border);
}

.legal-header .logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 0 var(--space-md);
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  color: var(--text);
  text-decoration: none;
}

.legal-header .logo:hover { color: var(--primary); }

/* ── Main content column ── */
.legal-content {
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: var(--space-xl) var(--space-md);
}

.legal-content h1 {
  font-family: var(--font-heading);
  font-size: var(--text-3xl);
  font-weight: 400;
  color: var(--text);
  margin-bottom: var(--space-xs);
  letter-spacing: -0.01em;
}

.legal-content .updated {
  color: var(--muted);
  font-size: var(--text-sm);
  margin-bottom: var(--space-xl);
}

.legal-content h2 {
  font-family: var(--font-heading);
  font-size: var(--text-2xl);
  font-weight: 400;
  color: var(--text);
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
  letter-spacing: -0.01em;
}

.legal-content h3 {
  font-family: var(--font-body);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--text);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.legal-content p,
.legal-content li {
  color: var(--text-secondary);
  font-size: var(--text-base);
  line-height: 1.7;
  margin-bottom: var(--space-sm);
}

.legal-content strong {
  color: var(--text);
  font-weight: 600;
}

.legal-content ul,
.legal-content ol {
  padding-left: var(--space-md);
  margin-bottom: var(--space-md);
}

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-md) 0;
  font-size: var(--text-sm);
}

.legal-content th,
.legal-content td {
  text-align: left;
  padding: var(--space-sm);
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

.legal-content th {
  color: var(--text);
  font-weight: 600;
}

/* ── Footer cross-link block ── */
.legal-footer {
  border-top: 1px solid var(--border);
  padding: var(--space-lg) var(--space-md);
  text-align: center;
  font-size: var(--text-sm);
  color: var(--muted);
}

.legal-footer a {
  color: var(--text-secondary);
  text-decoration: none;
  margin: 0 var(--space-sm);
}

.legal-footer a:hover {
  color: var(--primary);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  :root {
    --text-3xl: 1.75rem;
    --text-2xl: 1.5rem;
  }
  .legal-content {
    padding: var(--space-lg) var(--space-md);
  }
}

@media (max-width: 480px) {
  :root {
    --text-3xl: 1.5rem;
  }
}
