.legal-page {
  min-height: 100vh;
  margin: 0;
  background: var(--page-bg);
  color: var(--ink);
}

.legal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(100% - 48px, 1120px);
  margin: 0 auto;
  padding: 24px 0 0;
}

.legal-logo {
  display: inline-flex;
  width: 132px;
  text-decoration: none;
}

.legal-logo img {
  display: block;
  width: 100%;
  height: auto;
}

.legal-back {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--olive);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.8px;
  text-decoration: none;
  text-transform: uppercase;
}

.legal-back:hover,
.legal-back:focus-visible {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.legal-shell {
  width: min(100% - 48px, 860px);
  margin: 0 auto;
  padding: 74px 0 96px;
}

.legal-content {
  width: 100%;
}

.legal-kicker {
  margin: 0 0 18px;
  color: var(--olive);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 1.4px;
  text-transform: uppercase;
}

.legal-title {
  max-width: 620px;
  margin: 0;
  color: var(--olive-strong);
  font-family: "Jun", Georgia, serif;
  font-size: clamp(26px, 2.35vw, 34px);
  font-weight: 400;
  line-height: 1.16;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.legal-lead {
  max-width: 720px;
  margin: 28px 0 0;
  color: rgba(1, 1, 2, 0.72);
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.5;
}

.legal-source-title {
  margin: 44px 0 0;
  padding: 20px 0 0;
  border-top: 1px solid rgba(62, 81, 52, 0.2);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.55;
  letter-spacing: 0.4px;
}

.legal-meta {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  color: rgba(1, 1, 2, 0.68);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
}

.legal-section {
  padding: 34px 0;
  border-top: 1px solid rgba(62, 81, 52, 0.14);
}

.legal-source-title + .legal-section,
.legal-meta + .legal-section {
  margin-top: 34px;
}

.legal-document-head {
  display: grid;
  gap: 8px;
}

.legal-section h2 {
  max-width: 760px;
  margin: 0 0 18px;
  color: var(--olive-strong);
  font-family: var(--mono);
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: 0.3px;
  overflow-wrap: anywhere;
}

.legal-document-title {
  margin-bottom: 0;
  color: var(--olive-strong);
  font-family: var(--mono);
  font-size: clamp(15px, 1.35vw, 18px);
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0.3px;
}

.legal-section p,
.legal-section li {
  color: rgba(1, 1, 2, 0.76);
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.72;
  overflow-wrap: anywhere;
}

.legal-section p {
  margin: 0;
}

.legal-section p + p {
  margin-top: 14px;
}

.legal-form-line {
  color: rgba(1, 1, 2, 0.42);
  font-family: var(--mono);
  font-size: 14px;
  letter-spacing: -0.2px;
  overflow-wrap: anywhere;
}

.legal-section ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

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

.legal-section li {
  position: relative;
  padding-left: 22px;
}

.legal-section ol > li {
  padding-left: 38px;
}

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

.legal-section ol > li::before {
  counter-increment: legal-list;
  content: counter(legal-list) ".";
  top: 0;
  width: auto;
  height: auto;
  border-radius: 0;
  background: none;
  color: var(--olive-strong);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.72;
}

.legal-section li > ul {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.legal-section li > ul > li {
  padding-left: 22px;
}

.legal-section li > ul > li::before {
  content: "";
  top: 0.78em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--olive);
}

.legal-numbered-paragraphs .legal-section {
  counter-increment: legal-section;
  counter-reset: legal-paragraph;
}

.legal-numbered-paragraphs .legal-content {
  counter-reset: legal-section;
}

.legal-numbered-paragraphs .legal-section > h2::before {
  content: counter(legal-section) ". ";
}

.legal-numbered-paragraphs .legal-appendix-section {
  counter-increment: none;
}

.legal-numbered-paragraphs .legal-appendix-section > h2::before {
  content: "";
}

.legal-numbered-paragraphs .legal-section > p:not(.legal-appendix-note):not(.legal-subitem):not(.legal-subbullet) {
  position: relative;
  padding-left: 52px;
}

.legal-numbered-paragraphs .legal-section > p:not(.legal-appendix-note):not(.legal-subitem):not(.legal-subbullet)::before {
  counter-increment: legal-paragraph;
  content: counter(legal-section) "." counter(legal-paragraph) ".";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--olive-strong);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.72;
}

.legal-numbered-paragraphs .legal-section > .legal-subitem,
.legal-numbered-paragraphs .legal-section > .legal-subbullet {
  position: relative;
  padding-left: 38px;
}

.legal-numbered-paragraphs .legal-section > .legal-subitem::before,
.legal-numbered-paragraphs .legal-section > .legal-subbullet::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 0.86em;
  width: 12px;
  height: 1px;
  background: var(--olive);
}

.legal-numbered-paragraphs .legal-section > .legal-subbullet {
  padding-left: 54px;
}

.legal-numbered-paragraphs .legal-section > .legal-subbullet::before {
  left: 28px;
  top: 0.78em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.legal-download-link {
  display: inline-flex;
  align-items: center;
  margin-top: 4px;
}

.legal-section a {
  color: var(--olive-strong);
  font-weight: 700;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

@media (max-width: 760px) {
  .legal-header {
    width: min(100% - 32px, 1120px);
    padding-top: 18px;
  }

  .legal-logo {
    width: 112px;
  }

  .legal-shell {
    width: min(100% - 32px, 860px);
    padding: 52px 0 72px;
  }

  .legal-title {
    font-size: clamp(22px, 6.2vw, 28px);
    line-height: 1.18;
  }

  .legal-lead {
    margin-top: 22px;
    font-size: 16px;
  }

  .legal-source-title {
    margin-top: 34px;
  }

  .legal-section {
    padding: 28px 0;
  }

  .legal-section p,
  .legal-section li,
  .legal-meta {
    font-size: 15px;
  }

  .legal-section ul,
  .legal-section ol {
    gap: 10px;
  }

  .legal-section ol > li,
  .legal-numbered-paragraphs .legal-section > p:not(.legal-appendix-note):not(.legal-subitem):not(.legal-subbullet),
  .legal-numbered-paragraphs .legal-section > .legal-subitem {
    padding-left: 44px;
  }

  .legal-numbered-paragraphs .legal-section > .legal-subbullet {
    padding-left: 44px;
  }

  .legal-numbered-paragraphs .legal-section > .legal-subitem::before {
    left: 8px;
  }

  .legal-numbered-paragraphs .legal-section > .legal-subbullet::before {
    left: 22px;
  }
}
