/* AbitAI — Legal/Policy pages
   Editorial, restrained, brand-consistent. */

@font-face {
  font-family: "Eina01";
  src: url("../fonts/Eina01-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Eina01";
  src: url("../fonts/Eina01-SemiBold.otf") format("opentype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --c-bg: #F7F7F5;
  --c-white: #FFFFFF;
  --c-light: #E6E6E8;
  --c-soft: #A7A7AD;
  --c-mid: #6E6E73;
  --c-dark: #2A2A2E;
  --c-near-black: #0F0F10;
  --c-accent: #FF3D5D;

  --font-sans: "Eina01", "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --maxw: 1080px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  background: var(--c-bg);
  color: var(--c-near-black);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.005em;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
::selection { background: var(--c-accent); color: var(--c-white); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* HEADER */
.l-hdr {
  position: sticky; top: 0; z-index: 50;
  background: rgba(247,247,245,0.85);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--c-light);
}
.l-hdr-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.l-wordmark {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.l-wordmark img { height: 26px; width: auto; }
.l-back {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-mid);
  display: inline-flex; align-items: center; gap: 8px;
  transition: color 200ms ease;
}
.l-back:hover { color: var(--c-near-black); }
.l-back svg { width: 14px; height: 10px; }

/* HERO */
.l-hero {
  padding: clamp(56px, 8vw, 96px) 0 clamp(40px, 5vw, 64px);
  border-bottom: 1px solid var(--c-light);
}
.l-hero .meta {
  display: flex; gap: 22px; align-items: baseline; flex-wrap: wrap;
  margin-bottom: 28px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-mid);
}
.l-hero .meta .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--c-accent);
  display: inline-block;
}
.l-title {
  font-size: clamp(36px, 5.6vw, 72px);
  line-height: 1.0;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin: 0 0 22px 0;
  text-wrap: balance;
  max-width: 18ch;
}
.l-lede {
  font-size: clamp(16px, 1.3vw, 19px);
  line-height: 1.55;
  color: var(--c-dark);
  max-width: 62ch;
  margin: 0;
}

/* BODY GRID — TOC + content */
.l-body {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: clamp(40px, 6vw, 80px);
  padding: clamp(48px, 6vw, 80px) 0 clamp(72px, 8vw, 120px);
}
.l-toc {
  position: sticky;
  top: 84px;
  align-self: start;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
}
.l-toc .toc-label {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--c-mid);
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--c-light);
}
.l-toc ol {
  list-style: none;
  padding: 0; margin: 0;
  counter-reset: toc;
  display: flex; flex-direction: column; gap: 8px;
}
.l-toc li {
  counter-increment: toc;
  display: flex; gap: 10px;
  line-height: 1.45;
}
.l-toc li::before {
  content: counter(toc, decimal-leading-zero);
  color: var(--c-soft);
  flex-shrink: 0;
}
.l-toc a {
  color: var(--c-dark);
  transition: color 180ms ease;
  text-transform: none;
  letter-spacing: 0;
  font-family: var(--font-sans);
  font-size: 13px;
}
.l-toc a:hover { color: var(--c-accent); }

@media (max-width: 860px) {
  .l-body { grid-template-columns: 1fr; }
  .l-toc { position: static; padding: 20px; border: 1px solid var(--c-light); border-radius: 6px; background: var(--c-white); }
}

/* CONTENT */
.l-content {
  font-size: 15.5px;
  line-height: 1.7;
  color: var(--c-dark);
  max-width: 68ch;
}
.l-content section { padding-top: 8px; padding-bottom: 8px; }
.l-content section + section { margin-top: clamp(40px, 4vw, 56px); }
.l-content h2 {
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.2;
  letter-spacing: -0.015em;
  font-weight: 600;
  color: var(--c-near-black);
  margin: 0 0 8px 0;
  display: flex; align-items: baseline; gap: 14px;
}
.l-content h2 .sec-n {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--c-soft);
  font-weight: 500;
}
.l-content h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-near-black);
  margin: 22px 0 6px 0;
  letter-spacing: -0.005em;
}
.l-content p { margin: 10px 0; text-wrap: pretty; }
.l-content p + p { margin-top: 12px; }
.l-content ul, .l-content ol {
  margin: 10px 0;
  padding-left: 22px;
}
.l-content li { margin: 4px 0; }
.l-content li::marker { color: var(--c-soft); }
.l-content a.in {
  color: var(--c-near-black);
  border-bottom: 1px solid var(--c-soft);
  transition: border-color 180ms ease;
}
.l-content a.in:hover { border-color: var(--c-accent); }
.l-content code {
  font-family: var(--font-mono);
  font-size: 13px;
  background: var(--c-white);
  border: 1px solid var(--c-light);
  padding: 1px 6px;
  border-radius: 3px;
}

/* Definition table — used for data fields, cookies, etc. */
.l-table {
  width: 100%;
  border-collapse: collapse;
  margin: 18px 0 4px;
  font-size: 13.5px;
  background: var(--c-white);
  border: 1px solid var(--c-light);
}
.l-table th, .l-table td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border-bottom: 1px solid var(--c-light);
}
.l-table tr:last-child td { border-bottom: 0; }
.l-table th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--c-mid);
  background: var(--c-bg);
  border-bottom: 1px solid var(--c-light);
}
.l-table td.mono {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--c-near-black);
  white-space: nowrap;
}

/* Callout block */
.l-callout {
  margin: 22px 0;
  padding: 18px 20px;
  background: var(--c-white);
  border: 1px solid var(--c-light);
  border-left: 2px solid var(--c-accent);
  border-radius: 4px;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--c-dark);
}
.l-callout .label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-mid);
  margin-bottom: 6px;
  display: block;
}

/* Contact card */
.l-contact {
  margin-top: 28px;
  padding: 22px 24px;
  background: var(--c-near-black);
  color: var(--c-white);
  border-radius: 6px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}
.l-contact .label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 8px;
}
.l-contact a { color: var(--c-white); border-bottom: 1px solid rgba(255,255,255,0.3); }
.l-contact a:hover { border-color: var(--c-accent); }
.l-contact p { margin: 0; font-size: 14px; line-height: 1.6; color: rgba(255,255,255,0.85); }

/* FOOTER */
.l-foot {
  border-top: 1px solid var(--c-light);
  padding: 28px 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-mid);
}
.l-foot-inner {
  display: flex; justify-content: space-between; align-items: center;
  gap: 24px; flex-wrap: wrap;
}
.l-foot-links { display: flex; gap: 22px; flex-wrap: wrap; }
.l-foot-links a { transition: color 180ms ease; }
.l-foot-links a:hover { color: var(--c-near-black); }
.l-foot-links a.current { color: var(--c-near-black); }

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

/* Focus */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--c-accent);
  outline-offset: 3px;
  border-radius: 2px;
}
