:root {
  --green: #1a3a2a;
  --green-mid: #2c5c40;
  --green-light: #3d7a57;
  --gold: #c9a84c;
  --gold-light: #e8c97a;
  --cream: #f5f0e8;
  --cream-dark: #ede6d6;
  --white: #ffffff;
  --text: #1a2318;
  --muted: #6b7c6b;
  --radius: 12px;
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --legal-sticky-offset: 72px;
}

.legal-page-template,
.legal-page-template * {
  box-sizing: border-box;
}

.legal-page-template {
  background: var(--cream);
  color: var(--text);
}

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

.legal-page-template button {
  border: none;
  background: none;
  font-family: inherit;
  cursor: pointer;
}

.legal-page-template .reading-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  transform-origin: left;
  transform: scaleX(0);
  z-index: 9999;
}

.legal-hero {
  background: var(--green);
  position: relative;
  overflow: hidden;
  padding: 72px 24px 64px;
  text-align: center;
}

.hero-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.2;
  animation: legalBlobDrift 12s ease-in-out infinite alternate;
}

.hero-blob-1 {
  width: 400px;
  height: 400px;
  background: var(--green-light);
  top: -100px;
  right: -80px;
}

.hero-blob-2 {
  width: 300px;
  height: 300px;
  background: var(--gold);
  bottom: -80px;
  left: 5%;
  animation-delay: -4s;
}

@keyframes legalBlobDrift {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(20px, 15px) scale(1.08); }
}

.legal-hero-inner {
  max-width: 760px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(201, 168, 76, 0.15);
  border: 1px solid rgba(201, 168, 76, 0.4);
  color: var(--gold-light);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.legal-hero h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 300;
  line-height: 1.1;
  color: var(--cream);
  margin: 0 0 16px;
}

.legal-hero h1 em {
  font-style: italic;
  color: var(--gold-light);
}

.legal-hero p {
  font-size: 0.95rem;
  line-height: 1.75;
  color: rgba(245, 240, 232, 0.7);
  max-width: 520px;
  margin: 0 auto 28px;
}

.legal-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.meta-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.78rem;
  color: rgba(245, 240, 232, 0.8);
}

.page-switcher-wrap {
  background: var(--cream-dark);
  border-bottom: 1px solid rgba(26, 58, 42, 0.1);
  padding: 0 24px;
  position: sticky;
  top: var(--legal-sticky-offset);
  z-index: 90;
}

.page-switcher {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 4px;
  overflow-x: auto;
  padding: 12px 0;
  scrollbar-width: none;
}

.page-switcher::-webkit-scrollbar {
  display: none;
}

.page-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--muted);
  white-space: nowrap;
  transition: all var(--transition);
  flex-shrink: 0;
  border: 1.5px solid transparent;
}

.page-tab:hover {
  color: var(--green);
  background: rgba(26, 58, 42, 0.05);
}

.page-tab.active {
  background: var(--green);
  color: var(--cream);
  border-color: var(--green);
}

.page-tab .tab-icon {
  font-size: 1rem;
}

.legal-layout {
  max-width: 1280px;
  margin: 0 auto;
  padding: 56px 24px 80px;
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 40px;
  align-items: start;
}

.legal-sidebar {
  position: sticky;
  top: calc(var(--legal-sticky-offset) + 76px);
}

.sidebar-card,
.sidebar-contact,
.legal-section {
  background: var(--white);
  border: 1px solid rgba(26, 58, 42, 0.08);
  border-radius: 20px;
}

.sidebar-card {
  overflow: hidden;
}

.sidebar-header {
  background: var(--green);
  padding: 20px 22px;
}

.sidebar-header h3 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.2rem;
  font-weight: 400;
  color: var(--cream);
}

.sidebar-header p {
  margin: 4px 0 0;
  font-size: 0.75rem;
  color: rgba(245, 240, 232, 0.55);
}

.sidebar-nav {
  padding: 12px;
}

.sidebar-link {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 0.83rem;
  color: var(--muted);
  text-align: left;
  transition: all var(--transition);
}

.sidebar-link:hover {
  background: var(--cream);
  color: var(--green);
}

.sidebar-link.active {
  background: var(--cream);
  color: var(--green);
  font-weight: 600;
}

.sidebar-link .sl-icon {
  font-size: 0.9rem;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
}

.sidebar-link .sl-text {
  min-width: 0;
}

.sidebar-link .sl-num {
  margin-left: auto;
  font-size: 0.7rem;
  font-weight: 700;
  background: var(--cream-dark);
  color: var(--muted);
  padding: 2px 7px;
  border-radius: 999px;
  flex-shrink: 0;
}

.sidebar-link.active .sl-num {
  background: var(--green);
  color: var(--gold-light);
}

.sidebar-contact {
  padding: 20px 22px;
  margin-top: 16px;
}

.sidebar-contact h4 {
  margin: 0 0 12px;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.1rem;
  color: var(--green);
}

.sc-item {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.sc-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: var(--cream);
  color: var(--green-light);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sc-item p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

.sc-item a {
  color: var(--green);
  font-weight: 500;
}

.btn-contact-small {
  display: block;
  width: 100%;
  text-align: center;
  background: var(--green);
  color: var(--cream);
  padding: 11px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 600;
  margin-top: 14px;
  transition: all var(--transition);
}

.btn-contact-small:hover {
  background: var(--green-mid);
}

.legal-content-wrap {
  min-width: 0;
}

.legal-page {
  display: none;
}

.legal-page.active {
  display: block;
}

.legal-summary-card {
  background: linear-gradient(135deg, var(--green) 0%, var(--green-mid) 100%);
  border-radius: 20px;
  padding: 30px 32px;
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
}

.legal-summary-card::after {
  content: "";
  position: absolute;
  width: 200px;
  height: 200px;
  background: rgba(201, 168, 76, 0.12);
  border-radius: 50%;
  top: -60px;
  right: -60px;
  filter: blur(40px);
}

.lsc-tag {
  position: relative;
  z-index: 1;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-light);
  font-weight: 700;
  margin-bottom: 8px;
}

.lsc-title {
  position: relative;
  z-index: 1;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.6rem;
  font-weight: 300;
  color: var(--cream);
  margin-bottom: 10px;
  line-height: 1.2;
}

.lsc-title em {
  font-style: italic;
  color: var(--gold-light);
}

.lsc-desc {
  position: relative;
  z-index: 1;
  font-size: 0.85rem;
  color: rgba(245, 240, 232, 0.68);
  line-height: 1.7;
  margin-bottom: 18px;
  max-width: 480px;
}

.lsc-pills {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lsc-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 0.75rem;
  color: rgba(245, 240, 232, 0.85);
}

.legal-section {
  padding: 32px 36px;
  margin-bottom: 16px;
  scroll-margin-top: calc(var(--legal-sticky-offset) + 100px);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.legal-section:hover {
  border-color: rgba(26, 58, 42, 0.18);
}

.legal-section.highlight-section {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.1);
}

.ls-head {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(26, 58, 42, 0.07);
}

.ls-num {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  background: var(--green);
  color: var(--gold);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.1rem;
  font-weight: 600;
}

.ls-title-wrap {
  min-width: 0;
}

.ls-icon {
  font-size: 0.9rem;
  color: var(--gold);
  margin-bottom: 4px;
  line-height: 1;
}

.ls-title {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.4rem;
  font-weight: 400;
  color: var(--green);
  line-height: 1.2;
}

.ls-body {
  color: #3a4a3a;
}

.ls-body p {
  margin: 0 0 14px;
  font-size: 0.9rem;
  line-height: 1.85;
  color: #3a4a3a;
}

.ls-body p:last-child {
  margin-bottom: 0;
}

.ls-body strong {
  color: var(--green);
  font-weight: 600;
}

.ls-body a {
  color: var(--green-light);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.ls-body ul,
.ls-body ol {
  margin: 10px 0 14px;
  padding-left: 0;
  list-style: none;
}

.ls-body ul li,
.ls-body ol li {
  position: relative;
  padding: 5px 0 5px 24px;
  font-size: 0.88rem;
  line-height: 1.75;
  color: #3a4a3a;
}

.ls-body ul li::before {
  content: "✦";
  position: absolute;
  left: 2px;
  top: 7px;
  color: var(--gold);
  font-size: 0.5rem;
}

.ls-body ol {
  counter-reset: item;
}

.ls-body ol li {
  counter-increment: item;
}

.ls-body ol li::before {
  content: counter(item) ".";
  position: absolute;
  left: 0;
  top: 5px;
  color: var(--green-light);
  font-size: 0.78rem;
  font-weight: 700;
}

.ls-body .sub-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 14px 0 6px;
}

.ls-infobox {
  background: var(--cream);
  border-left: 3px solid var(--green-light);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
  margin: 14px 0;
}

.ls-infobox p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.7;
}

.ls-infobox strong {
  color: var(--green);
}

.ls-warnbox {
  background: rgba(201, 168, 76, 0.08);
  border-left: 3px solid var(--gold);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
  margin: 14px 0;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.ls-warnbox .wb-icon {
  font-size: 1rem;
  margin-top: 2px;
  flex-shrink: 0;
}

.ls-warnbox p {
  margin: 0;
  font-size: 0.85rem;
  color: #5a4a1a;
  line-height: 1.7;
}

.ls-contact-block {
  background: var(--green);
  border-radius: 14px;
  padding: 22px 24px;
  margin-top: 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.lcb-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lcb-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--gold-light);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.lcb-item p {
  margin: 0;
  font-size: 0.8rem;
  color: rgba(245, 240, 232, 0.68);
  line-height: 1.45;
}

.lcb-item strong {
  color: var(--gold-light);
}

.lcb-item a {
  color: var(--gold-light);
  font-weight: 500;
  text-decoration: none;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1024px) {
  .legal-layout {
    grid-template-columns: 240px 1fr;
    gap: 28px;
  }
}

@media (max-width: 860px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }

  .legal-sidebar {
    position: static;
  }

  .ls-contact-block {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .legal-hero {
    padding: 56px 18px 48px;
  }

  .page-switcher-wrap {
    padding: 0 16px;
  }

  .legal-layout {
    padding: 32px 16px 56px;
  }

  .legal-section {
    padding: 24px 20px;
  }

  .legal-summary-card {
    padding: 22px 20px;
  }

  .ls-head {
    gap: 12px;
  }

  .ls-title {
    font-size: 1.25rem;
  }
}