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

.legal-page {
  background-color: #0F1413;
  color: #E9F2F1;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

.legal-page {
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.75;
  background-color: #0F1413;
  color: #E9F2F1;
}

/* Scope isolation: neutralise any same-id section styling leak */
.legal-page .legal-content section {
  background-color: transparent !important;
}

/* ---------- Legal header ---------- */
.legal-header {
  background: linear-gradient(135deg, #062E2B 0%, #0F1413 60%, #0D9488 160%);
  border-bottom: 3px solid #0ABAB5;
  padding: 72px 24px 56px;
  text-align: center;
}

.legal-header__inner {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 24px;
}

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

.legal-header h1 {
  font-size: 44px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #E9F2F1;
  margin-bottom: 16px;
}

.legal-header p {
  color: #C7D6D4;
  font-size: 17px;
  max-width: 680px;
  margin: 0 auto;
}

.legal-header .legal-brand {
  color: #99F6E4;
  font-weight: 700;
}

.legal-header .legal-brand a {
  color: #99F6E4;
}

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

/* ---------- Table of contents ---------- */
.toc-wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 40px 24px 8px;
}

.toc-wrap .toc-title {
  color: #0ABAB5;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

nav.toc {
  background-color: #16211F;
  border: 1px solid #1E2C2A;
  border-radius: 12px;
  padding: 22px 26px;
  margin-bottom: 8px;
}

nav.toc ol {
  list-style: none;
  columns: 2;
  column-gap: 32px;
}

nav.toc li {
  margin-bottom: 10px;
  break-inside: avoid;
}

nav.toc a {
  color: #C7D6D4;
  font-size: 15px;
  text-decoration: none;
}

nav.toc a:hover {
  color: #0ABAB5;
}

nav.toc a::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #0ABAB5;
  margin-right: 10px;
  vertical-align: middle;
}

/* ---------- Legal content ---------- */
.legal-content {
  max-width: 820px;
  margin: 0 auto;
  padding: 24px 24px 40px;
}

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

.legal-content h2 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #2DD4BF;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid #0D9488;
}

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

.legal-content p {
  color: #C7D6D4;
  font-size: 16px;
  margin-bottom: 16px;
}

.legal-content ul,
.legal-content ol {
  color: #C7D6D4;
  font-size: 16px;
  margin: 0 0 16px 22px;
}

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

.legal-content a {
  color: #99F6E4;
  text-decoration: underline;
}

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

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

.legal-content .legal-note {
  background-color: #16211F;
  border-left: 4px solid #0ABAB5;
  padding: 18px 20px;
  border-radius: 0 10px 10px 0;
  margin: 20px 0;
}

.legal-content .legal-note p {
  margin-bottom: 0;
  color: #C7D6D4;
}

/* ---------- Back link ---------- */
.legal-back {
  max-width: 820px;
  margin: 0 auto;
  padding: 8px 24px 32px;
}

.legal-back a {
  display: inline-block;
  color: #062E2B;
  background-color: #0ABAB5;
  font-weight: 700;
  padding: 12px 24px;
  border-radius: 8px;
  text-decoration: none;
}

.legal-back a:hover {
  background-color: #0D9488;
  color: #062E2B;
}

/* ---------- Legal footer ---------- */
.legal-footer {
  background-color: #0F1413;
  border-top: 3px solid #0ABAB5;
  padding: 40px 24px 32px;
  text-align: center;
}

.legal-footer p {
  color: #9FB4B1;
  font-size: 15px;
  margin-bottom: 6px;
}

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

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

/* ---------- Responsive ---------- */
@media (max-width: 720px) {
  .legal-header {
    padding: 56px 24px 44px;
  }

  .legal-header h1 {
    font-size: 32px;
  }

  nav.toc ol {
    columns: 1;
  }
}
