:root {
  color-scheme: light;
  --ink: #17313a;
  --muted: #53666d;
  --brand: #0a4d68;
  --green: #23834f;
  --green-soft: #e9f7ef;
  --gold: #d99a18;
  --line: #d9e4e2;
  --paper: #ffffff;
  --canvas: #f4f8f7;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  font-size: 16px;
  line-height: 1.7;
}

a {
  color: var(--brand);
  text-underline-offset: 3px;
}
a:hover {
  color: var(--green);
}
a:focus-visible {
  outline: 3px solid #f2c14e;
  outline-offset: 3px;
}

.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.header-inner,
.legal-layout,
.site-footer-inner {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.header-inner {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
}

.brand img {
  width: 46px;
  height: 46px;
  object-fit: contain;
}
.brand span {
  font-size: 1.2rem;
}

.document-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
}
.document-nav a {
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}
.document-nav a[aria-current="page"] {
  color: var(--green);
  text-decoration: underline;
}

.legal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 44px;
  align-items: start;
  padding: 56px 0 72px;
}

.legal-layout-single {
  display: block;
  width: min(920px, calc(100% - 32px));
}

.document {
  min-width: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(24px, 5vw, 56px);
  box-shadow: 0 16px 44px rgb(25 66 72 / 0.08);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2 {
  letter-spacing: 0;
  line-height: 1.2;
}
h1 {
  margin: 0;
  color: var(--brand);
  font-size: clamp(2rem, 5vw, 3.25rem);
}
h2 {
  margin: 42px 0 12px;
  color: var(--brand);
  font-size: 1.35rem;
}
p {
  margin: 0 0 16px;
}
ul,
ol {
  padding-left: 1.35rem;
}
li + li {
  margin-top: 7px;
}

.document > h1 + p {
  margin: 18px 0 34px;
  padding-bottom: 24px;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  font-size: 0.9rem;
  white-space: pre-line;
}

.document-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 18px 0 34px;
  padding-bottom: 24px;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  font-size: 0.9rem;
}

.callout {
  margin: 24px 0;
  padding: 18px 20px;
  background: var(--green-soft);
  border-left: 4px solid var(--green);
  border-radius: 0 6px 6px 0;
}

.contact-box {
  margin-top: 40px;
  padding: 22px;
  background: #f8fbfb;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.contact-box h2 {
  margin-top: 0;
}
.contact-box a {
  font-weight: 800;
}

.toc {
  position: sticky;
  top: 24px;
  padding: 20px;
  background: var(--paper);
  border-top: 4px solid var(--gold);
  border-radius: 6px;
  box-shadow: 0 10px 30px rgb(25 66 72 / 0.07);
}

.toc strong {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
}
.toc a {
  display: block;
  padding: 5px 0;
  color: var(--muted);
  font-size: 0.88rem;
  text-decoration: none;
}
.toc a:hover {
  color: var(--brand);
  text-decoration: underline;
}

.site-footer {
  background: #17313a;
  color: #f3f8f7;
}

.site-footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 30px 0;
}

.site-footer p {
  margin: 0;
}
.site-footer a {
  color: #a9efc8;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
}

@media (max-width: 840px) {
  .header-inner {
    align-items: flex-start;
    flex-direction: column;
    padding: 16px 0;
  }
  .legal-layout {
    grid-template-columns: 1fr;
    padding-top: 28px;
  }
  .toc {
    position: static;
    grid-row: 1;
  }
  .site-footer-inner {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .header-inner,
  .legal-layout,
  .site-footer-inner {
    width: min(100% - 20px, 1120px);
  }
  .document {
    padding: 22px 18px;
  }
  .document-nav {
    gap: 6px 14px;
  }
  .brand span {
    font-size: 1.05rem;
  }
}

@media print {
  body {
    background: #fff;
    font-size: 11pt;
  }
  .site-header,
  .toc,
  .site-footer {
    display: none;
  }
  .legal-layout {
    display: block;
    width: 100%;
    padding: 0;
  }
  .document {
    border: 0;
    box-shadow: none;
    padding: 0;
  }
  h2 {
    break-after: avoid;
  }
  p,
  li {
    orphans: 3;
    widows: 3;
  }
}
