/* ============================================================
   LEGAL PAGES (v39) — Gizlilik Siyasəti & İstifadə Şərtləri.
   Təmiz, oxunaqlı sənəd düzümü; saytın token/şrift sisteminə uyğun.
   ============================================================ */

/* --- Hero --- */
.legal-hero {
  max-width: 760px;
}
.legal-hero .about-headline { margin-bottom: 16px; }
.legal-updated {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--brand);
  background: rgba(91, 79, 207, 0.08);
  padding: 7px 14px;
  border-radius: var(--r-pill);
  margin-top: 18px;
}

/* --- Document layout --- */
.legal-doc {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  align-items: start;
}

/* Table of contents — sticky on desktop */
.legal-toc {
  position: sticky;
  top: 24px;
  font-family: 'Inter', sans-serif;
}
.legal-toc-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
  margin: 0 0 14px 0;
}
.legal-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.legal-toc li { counter-increment: toc; }
.legal-toc a {
  display: flex;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.875rem;
  color: var(--ink);
  opacity: 0.7;
  text-decoration: none;
  transition: background var(--t-fast) var(--ease), opacity var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.legal-toc a::before {
  content: counter(toc);
  font-weight: 700;
  color: var(--brand);
  flex-shrink: 0;
  min-width: 16px;
}
.legal-toc a:hover {
  background: rgba(91, 79, 207, 0.07);
  opacity: 1;
  color: var(--brand-dark, var(--brand));
}

/* Body prose */
.legal-body {
  font-family: 'Inter', sans-serif;
  color: var(--ink);
  max-width: 760px;
}
.legal-intro {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  opacity: 0.85;
  padding: 18px 22px;
  background: rgba(91, 79, 207, 0.05);
  border-left: 3px solid var(--brand);
  border-radius: 0 14px 14px 0;
  margin-bottom: 36px;
}
.legal-section {
  scroll-margin-top: 24px;
  margin-bottom: 38px;
}
.legal-section h2 {
  counter-increment: legal;
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--ink);
  letter-spacing: -0.01em;
  margin: 0 0 14px 0;
  display: flex;
  gap: 12px;
  align-items: baseline;
}
.legal-section h2::before {
  content: counter(legal);
  font-size: 0.95rem;
  font-weight: 800;
  color: #fff;
  background: var(--brand-gradient);
  width: 30px;
  height: 30px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  align-self: flex-start;
}
.legal-body { counter-reset: legal; }
.legal-section h3 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--ink);
  margin: 22px 0 8px 0;
}
.legal-section p {
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--ink);
  opacity: 0.82;
  margin: 0 0 12px 0;
}
.legal-section ul {
  margin: 0 0 12px 0;
  padding-left: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.legal-section ul li {
  position: relative;
  padding-left: 24px;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--ink);
  opacity: 0.82;
}
.legal-section ul li::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 9px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand-gradient);
}
.legal-section ul li strong { opacity: 1; font-weight: 600; color: var(--ink); }
.legal-section a { color: var(--brand); font-weight: 600; text-decoration: none; }
.legal-section a:hover { text-decoration: underline; }

/* Contact card at the end */
.legal-contact {
  margin-top: 8px;
  padding: 24px 26px;
  border-radius: 18px;
  background: rgba(91, 79, 207, 0.05);
  border: 1px solid var(--border);
}
.legal-contact p { opacity: 0.9; }

/* Disclaimer note */
.legal-note {
  margin-top: 30px;
  font-family: 'Inter', sans-serif;
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--mute);
  font-style: italic;
}

@media (max-width: 880px) {
  .legal-doc { grid-template-columns: 1fr; gap: 28px; }
  .legal-toc { position: static; border-bottom: 1px solid var(--border); padding-bottom: 18px; }
  .legal-toc ol { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; }
}
