/* ===== Legal Pages Stylesheet ===== */

/* === Scope Isolation Rule (MUST BE FIRST) === */
.legal-page section {
  background-color: transparent !important;
}

/* ===== Legal Page Layout ===== */
.legal-page {
  padding-top: 100px;
  padding-bottom: 60px;
  background-color: #faf8f5;
  min-height: 100vh;
}

.legal-page .legal-header {
  text-align: center;
  padding: 40px 0 30px;
  border-bottom: 1px solid #e5e0d8;
  margin-bottom: 50px;
}

.legal-page .legal-header h1 {
  font-size: 38px;
  font-weight: 800;
  color: #181c26;
  letter-spacing: -0.5px;
  margin-bottom: 10px;
}

.legal-page .legal-header .legal-updated {
  font-size: 13px;
  color: #8a8d95;
}

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

.legal-page .legal-body .legal-intro {
  font-size: 16px;
  color: #5c5f6b;
  line-height: 1.8;
  margin-bottom: 40px;
}

/* ===== Table of Contents ===== */
.legal-toc {
  background-color: #ffffff;
  border: 1px solid #e5e0d8;
  border-radius: 12px;
  padding: 28px 32px;
  margin-bottom: 48px;
}

.legal-toc h2 {
  font-size: 18px;
  font-weight: 700;
  color: #181c26;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 2px solid #c87a3e;
}

.legal-toc ol {
  list-style: decimal;
  padding-left: 20px;
}

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

.legal-toc ol li a {
  color: #5c5f6b;
  transition: color 0.2s ease;
}

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

/* ===== Legal Content Sections ===== */
.legal-body section {
  margin-bottom: 40px;
  background-color: transparent !important;
}

.legal-body section h2 {
  font-size: 24px;
  font-weight: 700;
  color: #181c26;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e5e0d8;
  scroll-margin-top: 90px;
}

.legal-body section p {
  font-size: 15px;
  color: #5c5f6b;
  line-height: 1.8;
  margin-bottom: 16px;
}

.legal-body section ul {
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 16px;
}

.legal-body section ul li {
  font-size: 15px;
  color: #5c5f6b;
  line-height: 1.8;
  margin-bottom: 6px;
}

.legal-body section ol {
  list-style: decimal;
  padding-left: 24px;
  margin-bottom: 16px;
}

.legal-body section ol li {
  font-size: 15px;
  color: #5c5f6b;
  line-height: 1.8;
  margin-bottom: 6px;
}

.legal-body .highlight-box {
  background-color: #ffffff;
  border: 1px solid #e5e0d8;
  border-left: 4px solid #c87a3e;
  border-radius: 0 8px 8px 0;
  padding: 20px 24px;
  margin-bottom: 20px;
}

.legal-body .highlight-box p {
  margin-bottom: 0;
  font-weight: 500;
}

/* ===== Back to Top Link ===== */
.back-to-toc {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #c87a3e;
  margin-top: 8px;
  transition: color 0.2s ease;
}

.back-to-toc:hover {
  color: #d98f52;
}

/* ===== Legal Footer ===== */
.legal-page .legal-footer {
  max-width: 800px;
  margin: 50px auto 0;
  padding: 0 24px;
  text-align: center;
  border-top: 1px solid #e5e0d8;
  padding-top: 30px;
}

.legal-page .legal-footer p {
  font-size: 14px;
  color: #8a8d95;
  margin-bottom: 10px;
}

.legal-page .legal-footer a {
  font-weight: 600;
  color: #c87a3e;
  transition: color 0.2s ease;
}

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

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .legal-page .legal-header h1 {
    font-size: 28px;
  }

  .legal-toc {
    padding: 20px;
  }

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