/* ============================================================
   CKGCARWASH — shared legal pages stylesheet
   Loaded by privacy.html and terms-of-service.html ONLY
   ============================================================ */

:root {
  --bg: #0C1315;
  --surface: #142226;
  --surface-2: #1A2C31;
  --line: #22383E;
  --line-soft: #1B2E33;
  --text: #E8F4F5;
  --text-soft: #B9CFD1;
  --text-muted: #7C9A9E;
  --tiffany: #0ABAB5;
  --tiffany-deep: #08918D;
  --ice: #CFFAFE;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

/* Legal pages define their own body background. */
.legal-page {
  background-color: #0C1315;
  color: #E8F4F5;
  font-size: 16px;
  font-family: "Segoe UI", "Inter", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.75;
  overflow-x: hidden;
}

.legal-page a {
  color: inherit;
  text-decoration: none;
}

/* Scope isolation: never paint dark backgrounds over legal body sections. */
.legal-page .legal-content section {
  background-color: transparent !important;
}

/* ============================================================
   LEGAL HEADER
   ============================================================ */

.legal-header {
  background: linear-gradient(135deg, #0A3537 0%, #0C1315 100%);
  border-bottom: 3px solid #0ABAB5;
  padding: 64px 0 48px;
}

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

.legal-header .back-link {
  display: inline-block;
  margin-bottom: 24px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #CFFAFE;
}

.legal-header .back-link:hover {
  color: #0ABAB5;
}

.legal-header h1 {
  font-size: clamp(2rem, 5vw, 2.9rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.4px;
  color: #E8F4F5;
  margin-bottom: 12px;
}

.legal-header .legal-meta {
  font-size: 0.9rem;
  color: #7C9A9E;
}

/* ============================================================
   TABLE OF CONTENTS
   ============================================================ */

.legal-toc {
  margin: 40px 0 8px;
  background: #142226;
  border: 1px solid #22383E;
  border-left: 4px solid #0ABAB5;
  border-radius: 14px;
  padding: 28px 30px;
}

.legal-toc h2 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #0ABAB5;
  margin-bottom: 16px;
}

.legal-toc ol {
  list-style: none;
  counter-reset: toc;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}

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

.legal-toc li a {
  display: flex;
  gap: 10px;
  font-size: 0.92rem;
  color: #B9CFD1;
  line-height: 1.4;
}

.legal-toc li a::before {
  content: counter(toc, decimal-leading-zero);
  color: #0ABAB5;
  font-weight: 700;
  flex-shrink: 0;
}

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

/* ============================================================
   LEGAL BODY
   ============================================================ */

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

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

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

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

.legal-content h2 {
  font-size: 1.55rem;
  font-weight: 700;
  color: #0ABAB5;
  margin-bottom: 16px;
  letter-spacing: -0.2px;
  scroll-margin-top: 24px;
}

.legal-content h3 {
  font-size: 1.12rem;
  font-weight: 700;
  color: #CFFAFE;
  margin: 24px 0 10px;
}

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

.legal-content ul {
  margin: 0 0 20px 22px;
  color: #B9CFD1;
}

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

.legal-content strong {
  color: #E8F4F5;
}

/* ============================================================
   LEGAL FOOTER
   ============================================================ */

.legal-footer {
  background: #0A1012;
  border-top: 3px solid #0ABAB5;
  padding: 44px 0;
}

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

.legal-footer p {
  color: #7C9A9E;
  font-size: 0.9rem;
  margin-bottom: 10px;
}

.legal-footer a {
  color: #CFFAFE;
  font-weight: 600;
}

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

.legal-footer .legal-links {
  margin-top: 6px;
}

.legal-footer .legal-links a {
  margin-right: 20px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 640px) {
  .legal-toc ol {
    grid-template-columns: 1fr;
  }

  .legal-header {
    padding: 44px 0 36px;
  }
}
