/* =========================================================
   Nexdriv Inc. — legal stylesheet (privacy + terms)
   Loaded ONLY by the legal pages, never by the main pages.
   ========================================================= */

.legal-page {
  background-color: #141109;
  color: #F4EEDC;
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  margin: 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.legal-page *,
.legal-page *::before,
.legal-page *::after {
  box-sizing: border-box;
}

/* Scope isolation: legal content sections must never inherit a dark
   painted background from any shared rules. */
.legal-page .legal-content section {
  background-color: transparent !important;
}

/* ============ Legal header ============ */
.legal-header {
  background: #D9A441;
  color: #1A1408;
  padding: 40px 0 40px;
}

.legal-header .legal-brand {
  display: inline-block;
  color: #1A1408;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.1em;
  text-decoration: none;
  margin-bottom: 18px;
}

.legal-header h1 {
  color: #1A1408;
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  margin: 0 0 10px;
  line-height: 1.15;
}

.legal-header .legal-updated {
  color: #332A0C;
  margin: 0;
  font-size: 0.98rem;
}

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

.legal-content {
  padding: 56px 0 72px;
}

.legal-content h2 {
  color: #E8C87A;
  font-size: 1.55rem;
  margin: 0 0 14px;
  line-height: 1.25;
  scroll-margin-top: 24px;
}

.legal-content h3 {
  color: #F4EEDC;
  font-size: 1.15rem;
  margin: 0 0 10px;
}

.legal-content p {
  color: #F4EEDC;
  margin: 0 0 18px;
}

.legal-content ul,
.legal-content ol {
  color: #F4EEDC;
  margin: 0 0 18px;
  padding-left: 24px;
}

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

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

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

/* ============ Table of contents ============ */
.legal-content .toc {
  background-color: #4A3A10;
  border: 1px solid #5A4718;
  border-radius: 12px;
  padding: 24px 28px;
  margin-bottom: 40px;
}

.legal-content .toc h2 {
  color: #E8C87A;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 14px;
}

.legal-content .toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
  columns: 2;
  column-gap: 32px;
}

.legal-content .toc li {
  margin-bottom: 8px;
  break-inside: avoid;
}

.legal-content .toc a {
  color: #F4EEDC;
  text-decoration: none;
  font-size: 0.94rem;
}

.legal-content .toc a:hover {
  color: #E8C87A;
}

/* ============ Legal footer ============ */
.legal-footer {
  background-color: #0E0B06;
  color: #C9BC9E;
  padding: 40px 0;
  border-top: 1px solid #2E2717;
}

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

.legal-footer p {
  margin: 0 0 10px;
  font-size: 0.95rem;
}

.legal-footer a {
  color: #D9A441;
  text-decoration: none;
}

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

/* ============ Responsive ============ */
@media (max-width: 640px) {
  .legal-content .toc ul {
    columns: 1;
  }
}
