:root {
  color-scheme: light;
  --ink: #12363a;
  --body: #31484a;
  --green: #08785e;
  --green-dark: #075d4b;
  --coral: #e95845;
  --paper: #f7f9f7;
  --surface: #ffffff;
  --soft-green: #edf7f3;
  --soft-coral: #fff4f1;
  --muted: #637477;
  --line: #dce6e2;
  --shadow: 0 14px 40px rgba(18, 54, 58, 0.07);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

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

a { color: var(--green); }
a:hover { color: var(--green-dark); }
a:focus-visible, [tabindex="0"]:focus-visible {
  outline: 3px solid rgba(8, 120, 94, 0.25);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 10px;
  left: 10px;
  padding: 10px 14px;
  background: var(--ink);
  color: white;
  transform: translateY(-160%);
  text-decoration: none;
}

.skip-link:focus { transform: translateY(0); }

.site-header,
header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid rgba(220, 230, 226, 0.9);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

nav {
  width: min(1120px, calc(100% - 40px));
  min-height: 72px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-mark {
  position: relative;
  width: 28px;
  height: 28px;
  border: 6px solid var(--green);
  border-right-color: var(--coral);
  border-radius: 7px;
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: var(--green);
}

.links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.links a {
  padding: 8px 10px;
  color: var(--body);
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
}

.links a:hover,
.links a.active {
  color: var(--green);
}

.links a.active { box-shadow: inset 0 -2px var(--green); }

main {
  width: min(760px, calc(100% - 40px));
  margin: 0 auto;
  padding: 64px 0 88px;
}

.legal-page {
  width: min(1120px, calc(100% - 40px));
  padding-top: 72px;
}

.legal-hero { max-width: 820px; }

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: clamp(40px, 7vw, 62px);
  line-height: 1.08;
  letter-spacing: 0;
}

h2 {
  margin: 0 0 16px;
  color: var(--ink);
  font-size: 25px;
  line-height: 1.25;
  letter-spacing: 0;
}

h3 {
  margin: 28px 0 8px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
  letter-spacing: 0;
}

p, li { color: var(--body); }
p { margin: 0 0 16px; }
li + li { margin-top: 7px; }

.updated {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
}

.lede {
  max-width: 760px;
  margin-bottom: 28px;
  color: var(--body);
  font-size: 20px;
  line-height: 1.55;
}

.summary,
.notice {
  margin: 28px 0 0;
  padding: 20px 22px;
  border: 1px solid #cde2d9;
  border-left: 4px solid var(--green);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.notice {
  border-color: #f1d2ca;
  border-left-color: var(--coral);
  background: var(--soft-coral);
}

.summary > strong,
.notice > strong {
  color: var(--ink);
  font-size: 17px;
}

.summary ul { margin: 12px 0 0; padding-left: 20px; }

.legal-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 780px);
  gap: 72px;
  align-items: start;
  margin-top: 72px;
}

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

.table-of-contents {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 6px;
  padding: 4px 0 4px 18px;
  border-left: 2px solid var(--line);
}

.table-of-contents strong {
  margin-bottom: 6px;
  color: var(--ink);
  font-size: 13px;
  text-transform: uppercase;
}

.table-of-contents a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

.table-of-contents a:hover { color: var(--green); }

.legal-content section {
  padding: 0 0 44px;
  border-bottom: 1px solid var(--line);
}

.legal-content section + section { padding-top: 44px; }
.legal-content section:last-child { border-bottom: 0; }

.legal-content ul,
.legal-content ol {
  margin: 16px 0;
  padding-left: 24px;
}

.table-wrap {
  max-width: 100%;
  margin: 22px 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  background: var(--surface);
}

table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.5;
}

th, td {
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: var(--soft-green);
  color: var(--ink);
  font-size: 12px;
  text-transform: uppercase;
}

td:first-child {
  width: 20%;
  color: var(--ink);
  font-weight: 700;
}

tbody tr:last-child td { border-bottom: 0; }

.site-footer,
footer {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 30px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-size: 14px;
}

.site-footer div { display: flex; flex-wrap: wrap; gap: 18px; }

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

  .table-of-contents {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 18px 20px;
    border: 1px solid var(--line);
    background: var(--surface);
  }

  .table-of-contents strong { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  nav {
    min-height: auto;
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    padding: 15px 0 13px;
  }

  .links {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .links a { white-space: nowrap; }
  .legal-page, main { padding-top: 42px; }
  .legal-layout { margin-top: 48px; }
  .table-of-contents { grid-template-columns: 1fr; }
  .table-of-contents strong { grid-column: auto; }
  .lede { font-size: 18px; }
  h1 { font-size: 42px; }
  h2 { font-size: 22px; }

  .site-footer,
  footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
