/* Legal pages — shared stylesheet for privacy.html and terms-of-service.html */

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

:root {
  --bg: #0B0E14;
  --bg-raised: #151927;
  --line: #232839;
  --text: #E8EAED;
  --text-muted: #B7BECB;
  --accent: #8B5CF6;
  --accent-hot: #C026D3;
}

html {
  scroll-behavior: smooth;
}

.legal-page,
.legal-page body {
  background-color: #0B0E14;
  color: #E8EAED;
}

body {
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  background-color: #0B0E14;
  color: #E8EAED;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

/* Scope isolation: never let homepage section styling bleed into legal content */
.legal-page .legal-content section {
  background-color: transparent !important;
}

.legal-page .legal-content h1,
.legal-page .legal-content h2,
.legal-page .legal-content h3 {
  color: #E8EAED;
}

/* ---------- Legal header (element, not section) ---------- */

.legal-header {
  background: linear-gradient(135deg, #10131B 0%, #1A1430 100%);
  border-bottom: 1px solid #232839;
  padding: 72px 0 56px;
  text-align: center;
}

.legal-header .legal-header-inner {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
}

.legal-header .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 18px;
  color: #E8EAED;
  margin-bottom: 26px;
}

.legal-header .brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: linear-gradient(135deg, #7C3AED 0%, #C026D3 100%);
  position: relative;
  display: inline-block;
}

.legal-header .brand-mark::after {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 4px;
  background: #0B0E14;
}

.legal-header .legal-eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #C026D3;
  margin-bottom: 14px;
}

.legal-header h1 {
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #FFFFFF;
  margin-bottom: 16px;
}

.legal-header .legal-updated {
  font-size: 15px;
  color: #9AA2B1;
}

/* ---------- Legal content ---------- */

.legal-content {
  padding: 64px 0 40px;
}

.legal-content .container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Table of contents */
.legal-toc {
  background: #151927;
  border: 1px solid #232839;
  border-radius: 16px;
  padding: 26px 28px;
  margin-bottom: 48px;
}

.legal-toc h2 {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #C026D3;
  margin-bottom: 16px;
}

.legal-toc ol {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.legal-toc ol li {
  counter-increment: toc;
}

.legal-toc ol li a {
  display: flex;
  gap: 12px;
  color: #B7BECB;
  font-size: 15px;
  transition: color 0.2s ease;
}

.legal-toc ol li a:hover {
  color: #E8EAED;
}

.legal-toc ol li a::before {
  content: counter(toc, decimal-leading-zero);
  color: #C026D3;
  font-weight: 700;
  font-size: 13px;
  min-width: 24px;
}

.legal-content section {
  margin-bottom: 44px;
}

.legal-content section:last-child {
  margin-bottom: 0;
}

.legal-content h2 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #E8EAED;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #232839;
}

.legal-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: #E8EAED;
  margin: 22px 0 10px;
}

.legal-content p {
  color: #B7BECB;
  margin-bottom: 16px;
}

.legal-content ul {
  margin: 0 0 16px 22px;
  color: #B7BECB;
}

.legal-content ul li {
  margin-bottom: 8px;
}

.legal-content a {
  color: #C026D3;
}

.legal-content a:hover {
  text-decoration: underline;
}

.legal-back {
  display: inline-block;
  margin-top: 40px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1px solid #3A4054;
  color: #E8EAED;
  font-weight: 700;
  font-size: 15px;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.legal-back:hover {
  border-color: #C026D3;
  color: #C026D3;
}

/* ---------- Legal footer ---------- */

.legal-footer {
  background: #080A0F;
  border-top: 1px solid #1C2130;
  padding: 40px 0;
}

.legal-footer .legal-footer-inner {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
}

.legal-footer .footer-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  margin-bottom: 18px;
}

.legal-footer .footer-links a {
  color: #9AA2B1;
  font-size: 15px;
}

.legal-footer .footer-links a:hover {
  color: #C026D3;
}

.legal-footer p {
  color: #6B7280;
  font-size: 14px;
}

@media (max-width: 560px) {
  .legal-header {
    padding: 56px 0 40px;
  }

  .legal-content {
    padding: 44px 0 24px;
  }

  .legal-footer .footer-links {
    gap: 16px;
  }
}
