/* ============================================================
   BERTRAM ENDEAVOURS — legal.css
   Shared stylesheet for privacy.html and terms-of-service.html
   Light theme: teal-jade accents on very light teal-white base
   ============================================================ */

:root {
  --ink: #0F2E2B;
  --ink-soft: #35524E;
  --bg: #F2FBFA;
  --surface: #FFFFFF;
  --accent: #14B8A6;
  --accent-deep: #0E7166;
  --pale: #B5E8E0;
  --hairline: #D5EAE6;
}

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

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

.legal-page {
  background-color: #F2FBFA;
  color: #0F2E2B;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  overflow-x: hidden;
}

/* ---------- Header (div/header, NOT a section) ---------- */
.legal-header {
  background-color: #0E7166;
}

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

.legal-back {
  display: inline-block;
  color: #B5E8E0;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  margin-bottom: 18px;
}

.legal-back:hover {
  color: #FFFFFF;
  text-decoration: underline;
}

.legal-header h1 {
  color: #FFFFFF;
  font-size: 2.5rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.legal-meta {
  color: #B5E8E0;
  font-size: 0.95rem;
}

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

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

/* ---------- Scope isolation ---------- */
.legal-page .legal-content section {
  background-color: transparent !important;
  margin-bottom: 44px;
}

.legal-page .legal-content h2 {
  color: #0E7166;
  font-size: 1.6rem;
  line-height: 1.25;
  margin-bottom: 16px;
  padding-top: 24px;
  scroll-margin-top: 24px;
}

.legal-page .legal-content p {
  color: #0F2E2B;
  margin-bottom: 16px;
}

.legal-page .legal-content strong {
  color: #0F2E2B;
  font-weight: 700;
}

.legal-page .legal-content a {
  color: #0E7166;
  text-decoration: underline;
}

.legal-page .legal-content a:hover {
  color: #0F2E2B;
}

/* ---------- Table of contents ---------- */
.toc {
  background-color: #FFFFFF;
  border: 1px solid #D5EAE6;
  border-top: 6px solid #14B8A6;
  border-radius: 8px;
  padding: 28px 28px 20px;
  margin-bottom: 44px;
}

.toc h2 {
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #0E7166;
  margin-bottom: 14px;
}

.toc ol {
  list-style: none;
  counter-reset: toc;
  padding-left: 0;
}

.toc li {
  counter-increment: toc;
  padding: 7px 0;
  border-bottom: 1px solid #F0F8F6;
}

.toc li:last-child {
  border-bottom: none;
}

.toc li a {
  color: #35524E;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.98rem;
}

.toc li a::before {
  content: counter(toc, decimal-leading-zero) ". ";
  color: #14B8A6;
  font-weight: 800;
}

.toc li a:hover {
  color: #0E7166;
  text-decoration: underline;
}

/* ---------- Footer ---------- */
.legal-footer {
  border-top: 4px solid #14B8A6;
  background-color: #F2FBFA;
}

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

.legal-footer p {
  color: #35524E;
  font-size: 0.9rem;
}

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

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

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
  .legal-header h1 {
    font-size: 1.9rem;
  }

  .legal-page .legal-content h2 {
    font-size: 1.35rem;
  }
}
