.legal-page {
  background: #f7fbfc;
}

.legal-page .site-header {
  background: rgba(255, 255, 255, .96);
}

.legal-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 76px 0 70px;
  border-bottom: 1px solid var(--gray-100);
  background: linear-gradient(135deg, #f7fcfc, #eaf8f8);
}

.legal-hero::after {
  position: absolute;
  z-index: -1;
  top: -210px;
  right: -130px;
  width: 480px;
  height: 480px;
  border: 1px solid rgba(0, 152, 184, .12);
  border-radius: 50%;
  box-shadow: 0 0 0 64px rgba(0, 152, 184, .035), 0 0 0 128px rgba(43, 191, 167, .025);
  content: "";
}

.legal-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 25px;
  color: var(--gray-500);
  font-size: .83rem;
  font-weight: 650;
}

.legal-breadcrumbs a {
  color: var(--blue-700);
}

.legal-breadcrumbs a:hover {
  text-decoration: underline;
}

.legal-hero h1 {
  margin-bottom: 18px;
  font-size: clamp(2.65rem, 5vw, 4.15rem);
}

.legal-hero-copy {
  max-width: 740px;
  margin-bottom: 22px;
  font-size: 1.08rem;
}

.legal-updated {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 8px 12px;
  border: 1px solid #cfe8eb;
  border-radius: 9px;
  background: rgba(255, 255, 255, .75);
  color: var(--gray-700);
  font-size: .78rem;
  font-weight: 700;
}

.legal-updated span {
  color: var(--blue-700);
}

.legal-body {
  padding: 74px 0 104px;
}

.legal-layout {
  display: grid;
  grid-template-columns: 255px minmax(0, 790px);
  gap: clamp(50px, 7vw, 96px);
  justify-content: center;
  align-items: start;
}

.legal-toc {
  position: sticky;
  top: 108px;
  padding: 23px;
  border: 1px solid var(--gray-100);
  border-radius: var(--radius-md);
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.legal-toc > strong {
  display: block;
  margin-bottom: 13px;
  color: var(--navy-950);
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.legal-toc ol {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: legal-section;
}

.legal-toc li {
  counter-increment: legal-section;
}

.legal-toc a {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 6px;
  padding: 7px 5px;
  border-radius: 7px;
  color: var(--gray-700);
  font-size: .78rem;
  font-weight: 620;
  line-height: 1.35;
}

.legal-toc a::before {
  color: var(--blue-700);
  content: counter(legal-section, decimal-leading-zero);
  font-size: .66rem;
  font-weight: 800;
}

.legal-toc a:hover {
  background: var(--blue-50);
  color: var(--navy-950);
}

.legal-document {
  min-width: 0;
}

.legal-summary {
  margin-bottom: 42px;
  padding: 25px 27px;
  border: 1px solid #cfe8eb;
  border-left: 4px solid var(--blue-600);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--white);
  box-shadow: var(--shadow-sm);
}

.legal-summary strong {
  display: block;
  margin-bottom: 7px;
  color: var(--navy-950);
}

.legal-summary p {
  margin: 0;
  font-size: .94rem;
}

.legal-section {
  scroll-margin-top: 110px;
  padding: 4px 0 34px;
  border-bottom: 1px solid var(--gray-100);
}

.legal-section + .legal-section {
  padding-top: 34px;
}

.legal-section:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.legal-section h2 {
  margin-bottom: 15px;
  font-size: clamp(1.55rem, 3vw, 2rem);
  letter-spacing: -.025em;
}

.legal-section h3 {
  margin: 24px 0 9px;
  font-size: 1.05rem;
  letter-spacing: -.015em;
}

.legal-section p {
  margin-bottom: 14px;
  color: #395568;
  font-size: .97rem;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-section ul {
  display: grid;
  gap: 10px;
  margin: 14px 0 17px;
  padding-left: 0;
}

.legal-section li {
  position: relative;
  padding-left: 25px;
  color: #395568;
  font-size: .95rem;
}

.legal-section li::before {
  position: absolute;
  top: .72em;
  left: 4px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--mint-500);
  content: "";
}

.legal-section a,
.legal-contact-card a {
  color: var(--blue-700);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(0, 124, 159, .3);
  text-underline-offset: 3px;
}

.legal-contact-card {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 18px;
  padding: 20px;
  border-radius: var(--radius-md);
  background: var(--navy-950);
  color: var(--white);
}

.legal-contact-icon {
  display: grid;
  width: 45px;
  height: 45px;
  flex: 0 0 auto;
  border-radius: 13px;
  background: rgba(255, 255, 255, .1);
  color: #8de2d1;
  place-items: center;
}

.legal-contact-card span:last-child {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.legal-contact-card strong {
  font-size: .82rem;
}

.legal-contact-card a {
  overflow-wrap: anywhere;
  color: #8de2d1;
  font-size: .9rem;
}

.legal-page .footer-nav a[aria-current="page"] {
  color: var(--white);
  font-weight: 750;
}

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

  .legal-toc {
    position: static;
  }

  .legal-toc ol {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .legal-hero {
    padding: 47px 0 50px;
  }

  .legal-breadcrumbs {
    margin-bottom: 20px;
  }

  .legal-hero h1 {
    font-size: clamp(2.35rem, 12vw, 3.2rem);
  }

  .legal-hero-copy {
    font-size: .98rem;
  }

  .legal-body {
    padding: 50px 0 75px;
  }

  .legal-toc {
    padding: 19px;
  }

  .legal-toc ol {
    grid-template-columns: 1fr;
  }

  .legal-summary {
    margin-bottom: 34px;
    padding: 21px;
  }

  .legal-section,
  .legal-section + .legal-section {
    padding-top: 28px;
    padding-bottom: 28px;
  }

  .legal-section:first-of-type {
    padding-top: 0;
  }

  .legal-contact-card {
    align-items: flex-start;
  }
}
