﻿/* ── Keyframes ──────────────────────────────────────────────── */
@keyframes lg-fade-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes lg-scale-in {
  from { opacity: 0; transform: scale(.95); }
  to   { opacity: 1; transform: scale(1); }
}
@keyframes lg-shimmer-txt {
  0%   { background-position: -200% center; }
  100% { background-position:  200% center; }
}
@keyframes lg-pulse-blue {
  0%, 100% { box-shadow: 0 0 0 0   rgba(44, 176, 55, .5); }
  50%       { box-shadow: 0 0 0 7px rgba(44, 176, 55, 0);  }
}

/* ── Base page ──────────────────────────────────────────────── */
.legal-page {
  background: var(--dch-paper);
  color: var(--dch-ink);
  font-family: var(--dch-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.legal-page .main { overflow: hidden; }

/* ── Reading progress bar (fixed top) ──────────────────────── */
.lg-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2.5px;
  z-index: 9999;
  background: rgba(44, 176, 55, .08);
  pointer-events: none;
}
.lg-progress__fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--dch-accent) 0%, var(--dch-accent-soft) 60%, var(--dch-accent-2) 100%);
  transition: width .12s linear;
}

/* ── Hero ───────────────────────────────────────────────────── */
.lg-hero {
  position: relative;
  background: var(--dch-bg);
  color: var(--dch-fg);
  overflow: hidden;
  isolation: isolate;
  padding: 160px 0 110px;
}
.lg-hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.lg-hero__bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 700px 520px at 98%   0%,   rgba(12,  65, 255, .15) 0%, transparent 55%),
    radial-gradient(ellipse 540px 440px at  0%  100%,  rgba(31, 122, 140, .10) 0%, transparent 50%),
    radial-gradient(ellipse 880px 600px at 50%   50%,  rgba(12,  65, 255, .04) 0%, transparent 65%),
    linear-gradient(162deg, #0a0d12 0%, #0c1118 55%, #0a0d12 100%);
}
/* Subtle grid */
.lg-hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(0deg,
      transparent, transparent 79px,
      rgba(255,255,255,.018) 79px, rgba(255,255,255,.018) 80px),
    repeating-linear-gradient(90deg,
      transparent, transparent 79px,
      rgba(255,255,255,.012) 79px, rgba(255,255,255,.012) 80px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black 20%, transparent 80%);
}


.lg-hero__content {
  position: relative;
  z-index: 3;
  max-width: 800px;
}
.lg-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--dch-text);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--dch-accent);
  background: rgba(44, 176, 55, .1);
  border: 1px solid rgba(44, 176, 55, .26);
  padding: 7px 18px;
  border-radius: 100px;
  margin-bottom: 32px;
  animation: lg-fade-up .6s var(--ease-out) both;
}
.lg-hero__eyebrow::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--dch-accent);
  flex-shrink: 0;
  animation: lg-pulse-blue 2s ease infinite;
}
.lg-hero__title {
  font-family: var(--dch-display);
  font-size: clamp(2.9rem, 5.5vw, 5.4rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.05em;
  color: var(--dch-fg);
  margin: 0 0 28px;
  animation: lg-fade-up .65s .1s var(--ease-out) both;
}
.lg-hero__title em {
  font-style: normal;
  background: linear-gradient(135deg, var(--dch-accent) 0%, var(--dch-accent-soft) 45%, var(--dch-accent-2) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: lg-shimmer-txt 5s linear infinite;
}
.lg-hero__desc {
  font-family: var(--dch-text);
  font-size: 1.0625rem;
  line-height: 1.72;
  color: rgba(246, 244, 239, .5);
  margin: 0 0 44px;
  max-width: 58ch;
  animation: lg-fade-up .65s .18s var(--ease-out) both;
}
.lg-hero__pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  animation: lg-fade-up .65s .26s var(--ease-out) both;
}
.lg-hero__pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--dch-text);
  font-size: 12.5px;
  font-weight: 500;
  color: rgba(246, 244, 239, .6);
  background: rgba(246, 244, 239, .06);
  border: 1px solid rgba(246, 244, 239, .1);
  padding: 7px 16px;
  border-radius: 100px;
  letter-spacing: .01em;
  text-decoration: none;
  cursor: pointer;
  transition: background .3s var(--ease), border-color .3s var(--ease), color .3s var(--ease), transform .3s var(--ease);
}
.lg-hero__pill i { font-size: 13px; flex-shrink: 0; }
.lg-hero__pill:hover,
.lg-hero__pill.is-active {
  background: rgba(44, 176, 55, .14);
  border-color: rgba(44, 176, 55, .3);
  color: #fff;
  transform: translateY(-1px);
}
.lg-hero__updated {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: rgba(246, 244, 239, .28);
  letter-spacing: .03em;
  margin-left: 4px;
  font-family: var(--dch-text);
}
.lg-hero__updated i { font-size: 11px; }

/* ── Content section ────────────────────────────────────────── */
.lg-content {
  background: var(--dch-paper);
  padding: 88px 0 108px;
  color: var(--dch-ink);
  position: relative;
}
.lg-content::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(44,176,55,.18) 30%, rgba(44,176,55,.07) 70%, transparent 100%);
}

/* ── Sidebar ────────────────────────────────────────────────── */
.lg-sidebar {
  position: sticky;
  top: 96px;
}
.lg-sidebar__label {
  font-family: var(--dch-text);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(10, 13, 18, .35);
  margin: 0 0 18px;
  padding-left: 18px;
}
.lg-nav {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 28px;
}
/* Vertical track */
.lg-nav::before {
  content: '';
  position: absolute;
  left: 0; top: 6px; bottom: 6px;
  width: 1px;
  background: var(--dch-line-ink);
}
.lg-nav__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 11px 16px;
  text-decoration: none;
  color: var(--dch-muted-ink);
  font-family: var(--dch-text);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.4;
  border-left: 2px solid transparent;
  margin-left: -1px;
  border-radius: 0 var(--dch-radius-sm) var(--dch-radius-sm) 0;
  transition: color .25s var(--ease), border-color .25s var(--ease), background .25s var(--ease);
}
.lg-nav__item:hover {
  color: var(--dch-ink);
  background: rgba(44, 176, 55, .04);
}
.lg-nav__item.is-active {
  color: var(--dch-accent);
  border-left-color: var(--dch-accent);
  background: rgba(44, 176, 55, .06);
  font-weight: 600;
}
.lg-nav__num {
  font-family: var(--dch-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  color: inherit;
  opacity: .45;
  flex-shrink: 0;
  margin-top: 2px;
  transition: opacity .25s;
}
.lg-nav__item.is-active .lg-nav__num { opacity: 1; }

/* Contact callout in sidebar */
.lg-sidebar__contact {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 16px 18px;
  background: rgba(44, 176, 55, .05);
  border: 1px solid rgba(44, 176, 55, .12);
  border-radius: var(--dch-radius-sm);
  font-family: var(--dch-text);
  font-size: 12.5px;
  line-height: 1.5;
  color: rgba(10, 13, 18, .55);
}
.lg-sidebar__contact i {
  color: var(--dch-accent);
  font-size: 15px;
  flex-shrink: 0;
  margin-top: 1px;
}
.lg-sidebar__contact a {
  color: var(--dch-accent);
  font-weight: 600;
  text-decoration: none;
  transition: opacity .2s;
}
.lg-sidebar__contact a:hover { opacity: .75; }

/* Sidebar badge row */
.lg-sidebar__badges {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 20px;
}
.lg-sidebar__badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--dch-text);
  font-size: 12px;
  color: rgba(10, 13, 18, .45);
}
.lg-sidebar__badge i {
  color: #22c55e;
  font-size: 13px;
  flex-shrink: 0;
}

/* ── Article blocks ─────────────────────────────────────────── */
.lg-article {
  padding-bottom: 72px;
  scroll-margin-top: 100px;
}
.lg-article__header {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--dch-line-ink);
}
.lg-article__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--dch-accent);
  font-family: var(--dch-display);
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: -.02em;
  margin-top: 4px;
  box-shadow: 0 4px 20px rgba(44, 176, 55, .28);
}
.lg-article__title {
  font-family: var(--dch-display);
  font-size: clamp(1.45rem, 2.6vw, 2rem);
  font-weight: 700;
  letter-spacing: -.04em;
  color: var(--dch-ink);
  margin: 0 0 6px;
  line-height: 1.15;
}
.lg-article__updated {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-family: var(--dch-text);
  color: rgba(10, 13, 18, .38);
  margin: 0;
}

/* Lead callout */
.lg-callout {
  background: rgba(44, 176, 55, .05);
  border-left: 3px solid var(--dch-accent);
  border-radius: 0 var(--dch-radius-sm) var(--dch-radius-sm) 0;
  padding: 20px 24px;
  margin: 0 0 36px;
}
.lg-callout p {
  margin: 0;
  font-family: var(--dch-text);
  font-size: 15px;
  line-height: 1.66;
  color: rgba(10, 13, 18, .72);
}
.lg-callout p strong { color: var(--dch-ink); font-weight: 600; }

/* H3 */
.lg-article h3 {
  font-family: var(--dch-display);
  font-size: 1.0rem;
  font-weight: 700;
  letter-spacing: -.025em;
  color: var(--dch-ink);
  margin: 36px 0 10px;
  padding-left: 12px;
  border-left: 2px solid var(--dch-accent);
  line-height: 1.3;
}
/* Body text */
.lg-article p {
  font-family: var(--dch-text);
  font-size: 15px;
  line-height: 1.74;
  color: rgba(10, 13, 18, .68);
  margin: 0 0 16px;
}
/* Lists */
.lg-article ul,
.lg-article ol {
  font-family: var(--dch-text);
  font-size: 15px;
  line-height: 1.74;
  color: rgba(10, 13, 18, .68);
  margin: 0 0 20px;
  padding-left: 0;
  list-style: none;
}
.lg-article ul li,
.lg-article ol li {
  padding-left: 22px;
  margin-bottom: 9px;
  position: relative;
}
.lg-article ul li::before {
  content: '';
  position: absolute;
  left: 0; top: 10px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--dch-accent);
  opacity: .55;
}
.lg-article ol {
  counter-reset: lg-ol;
  padding-left: 0;
}
.lg-article ol li {
  counter-increment: lg-ol;
}
.lg-article ol li::before {
  content: counter(lg-ol);
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--dch-display);
  font-size: 11px;
  font-weight: 700;
  color: var(--dch-accent);
  opacity: .8;
}

/* Links */
.lg-article a {
  color: var(--dch-accent);
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid rgba(44, 176, 55, .25);
  transition: border-color .2s, opacity .2s;
}
.lg-article a:hover {
  opacity: .8;
  border-bottom-color: var(--dch-accent);
}
/* Strong */
.lg-article strong { color: var(--dch-ink); font-weight: 600; }

/* Section divider */
.lg-section-divider {
  height: 1px;
  background: var(--dch-line-ink);
  margin: 8px 0 72px;
  position: relative;
  overflow: visible;
}
.lg-section-divider::before {
  content: '';
  position: absolute;
  left: 0; top: 50%;
  transform: translateY(-50%);
  width: 52px; height: 3px;
  background: var(--dch-accent);
  border-radius: 100px;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 991px) {
  .lg-sidebar {
    position: static;
    margin-bottom: 48px;
  }
  .lg-nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
  }
  .lg-nav::before { display: none; }
  .lg-nav__item {
    border-left: none;
    border-bottom: 2px solid transparent;
    border-radius: var(--dch-radius-sm);
    padding: 8px 14px;
    background: rgba(10,13,18,.04);
  }
  .lg-nav__item.is-active {
    border-bottom-color: var(--dch-accent);
  }
  .lg-hero { padding: 130px 0 85px; }
  .lg-content { padding: 64px 0 80px; }
}
@media (max-width: 575px) {
  .lg-hero { padding: 110px 0 65px; }
  .lg-hero__updated { display: none; }
  .lg-article__header { gap: 14px; }
  .lg-article__badge { width: 40px; height: 40px; font-size: .85rem; border-radius: 10px; }
  .lg-article__title { font-size: 1.35rem; }
  .lg-content { padding: 48px 0 64px; }
}

/* ── Reduced motion ─────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .legal-page *, .legal-page *::before, .legal-page *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
