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

:root {
  --forest: #1a2328;
  --parchment: #f5f0e8;
  --wisteria: #6b4c8a;
  --teal: #4a7c6f;
  --honey: #e8c76b;
  --white: #ffffff;
  --border: #ddd5c8;
  --text-muted: #5c554a;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  color: var(--forest);
  background: var(--parchment);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--wisteria);
  text-decoration: none;
}

a:hover {
  color: var(--teal);
}

.container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- NAVBAR ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--forest);
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar .logo {
  font-size: 26px;
  font-weight: 800;
  color: var(--honey);
  letter-spacing: -0.5px;
}

.navbar .logo span {
  color: var(--white);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-links a {
  color: var(--parchment);
  font-size: 15px;
  font-weight: 500;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--honey);
  transition: width 0.25s;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-links a:hover {
  color: var(--honey);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--honey);
  transition: all 0.3s;
}

.navbar.nav-open .nav-toggle span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.navbar.nav-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}

.navbar.nav-open .nav-toggle span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ---------- PAGE HEADER ---------- */
.page-header {
  background: linear-gradient(170deg, var(--forest) 60%, var(--teal) 100%);
  padding: 120px 0 60px;
  text-align: center;
  color: var(--parchment);
}

.page-header h1 {
  font-size: 42px;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 12px;
}

.page-header h1 span {
  color: var(--honey);
}

.page-header p {
  font-size: 16px;
  color: #b8b0a4;
}

/* ---------- CONTENT ---------- */
.legal-content {
  padding: 64px 0 72px;
}

.legal-content .last-updated {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 36px;
}

/* ---------- TABLE OF CONTENTS ---------- */
.toc {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 28px 32px;
  margin-bottom: 44px;
  background: var(--white);
}

.toc h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--forest);
  margin-bottom: 16px;
}

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

.toc ol li {
  margin-bottom: 8px;
  font-size: 14px;
  line-height: 1.5;
}

.toc ol li a {
  color: var(--wisteria);
  font-weight: 500;
}

.toc ol li a:hover {
  color: var(--teal);
}

/* ---------- SECTIONS ---------- */
.legal-body section {
  margin-bottom: 44px;
}

.legal-body h2 {
  font-size: 26px;
  font-weight: 800;
  color: var(--forest);
  margin-bottom: 14px;
  padding-top: 20px;
  border-top: 2px solid var(--border);
}

.legal-body section:first-of-type h2 {
  border-top: none;
  padding-top: 0;
}

.legal-body h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--forest);
  margin: 18px 0 8px;
}

.legal-body p {
  font-size: 16px;
  color: #3a352c;
  margin-bottom: 14px;
  line-height: 1.75;
}

.legal-body ul {
  margin: 8px 0 16px 24px;
}

.legal-body ul li {
  font-size: 16px;
  color: #3a352c;
  margin-bottom: 6px;
  line-height: 1.65;
}

/* ---------- FOOTER ---------- */
.site-footer {
  background: var(--forest);
  color: #9a958a;
  padding: 28px 0 36px;
  text-align: center;
  font-size: 14px;
}

.site-footer a {
  color: var(--honey);
}

.site-footer a:hover {
  color: var(--teal);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.footer-links a {
  color: #b8b0a4;
  font-size: 14px;
}

.footer-links a:hover {
  color: var(--honey);
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 68px;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--forest);
    flex-direction: column;
    justify-content: center;
    gap: 28px;
    transform: translateX(100%);
    transition: transform 0.35s ease;
    z-index: 999;
  }

  .navbar.nav-open .nav-links {
    transform: translateX(0);
  }

  .nav-links a {
    font-size: 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .page-header {
    padding: 104px 0 44px;
  }

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

  .toc ol {
    columns: 1;
  }

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

  .legal-body h2 {
    font-size: 22px;
  }
}

@media (max-width: 480px) {
  .page-header h1 {
    font-size: 26px;
  }

  .toc {
    padding: 20px;
  }
}
