:root {
  --brand: #509fcd;
  --brand-dark: #334a7f;
  --brand-ink: #21365f;
  --accent: #f28a19;
  --paper: #f6f8fb;
  --surface: #ffffff;
  --cream: #efe9d9;
  --ink: #172436;
  --muted: #657284;
  --line: #d8e3ec;
  --shadow: 0 18px 42px -32px rgba(31, 60, 92, 0.45);
  --max: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Aptos, "Segoe UI", Roboto, Arial, sans-serif;
  line-height: 1.62;
  letter-spacing: 0;
}

body.redirect-page {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(80, 159, 205, 0.16), transparent 34%),
    linear-gradient(315deg, rgba(242, 138, 25, 0.12), transparent 26%),
    var(--paper);
}

a {
  color: var(--brand-ink);
  text-decoration-color: rgba(80, 159, 205, 0.55);
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--brand-dark);
}

:focus-visible {
  outline: 3px solid rgba(242, 138, 25, 0.72);
  outline-offset: 4px;
}

.site-shell {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.topbar {
  background: var(--brand);
  padding: 38px clamp(16px, 4vw, 44px);
}

.nav {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
}

.brand img {
  width: 112px;
  height: 112px;
  display: block;
  object-fit: contain;
  border-radius: 0;
  box-shadow: none;
}

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.nav-links a {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 6px;
  padding: 8px 12px;
  background: rgba(51, 74, 127, 0.92);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  transition: transform 180ms ease, background-color 180ms ease, border-color 180ms ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: #ffffff;
  color: var(--brand-dark);
}

.nav-links a:active,
.button:active {
  transform: translateY(1px) scale(0.99);
}

.nav-links .nav-external {
  background: var(--accent);
  color: #321c05;
  border-color: rgba(255, 255, 255, 0.3);
}

.legal-hero {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(80, 159, 205, 0.16), rgba(255, 255, 255, 0.88)),
    linear-gradient(180deg, #ffffff 0%, #edf7fc 100%);
}

.legal-hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 58px;
  background: var(--paper);
  clip-path: polygon(0 100%, 0 42%, 50% 100%, 100% 42%, 100% 100%);
}

.hero-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(48px, 8vw, 92px) clamp(18px, 4vw, 44px) 100px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  line-height: 1.12;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

h1 {
  max-width: 780px;
  font-size: clamp(2.25rem, 6vw, 4.7rem);
  font-weight: 850;
}

h2 {
  font-size: clamp(1.45rem, 3vw, 2rem);
  margin-bottom: 18px;
}

h3 {
  font-size: 1.05rem;
  margin: 22px 0 8px;
}

.hero-inner > p:not(.eyebrow) {
  max-width: 720px;
  margin: 20px 0 0;
  color: #3f5267;
  font-size: clamp(1rem, 2vw, 1.18rem);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.meta-row span {
  border: 1px solid rgba(80, 159, 205, 0.3);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.72);
  color: #314154;
  font-size: 0.9rem;
  font-weight: 700;
}

.legal-layout {
  width: min(var(--max), calc(100% - 36px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: clamp(28px, 5vw, 64px);
  padding: clamp(42px, 7vw, 76px) 0 86px;
}

.toc {
  position: sticky;
  top: 18px;
  align-self: start;
  border-top: 4px solid var(--brand);
  padding-top: 16px;
}

.toc-title {
  margin: 0 0 10px;
  color: var(--brand-dark);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.toc a {
  display: block;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  color: #43566c;
  font-weight: 700;
  text-decoration: none;
}

.toc a:hover {
  color: var(--brand-dark);
}

.legal-content {
  min-width: 0;
  overflow-wrap: break-word;
  hyphens: auto;
}

.content-section {
  padding: 0 0 clamp(34px, 5vw, 54px);
  margin-bottom: clamp(34px, 5vw, 54px);
  border-bottom: 1px solid var(--line);
}

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

.content-section p {
  margin: 0 0 15px;
  color: #334155;
}

.content-section ul,
.content-section ol {
  margin: 0 0 18px;
  padding-left: 1.2rem;
  color: #334155;
}

.content-section li + li {
  margin-top: 8px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 20px;
}

.info-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.info-box strong {
  display: block;
  margin-bottom: 6px;
  color: var(--brand-dark);
}

.contact-list {
  display: grid;
  gap: 10px;
  margin: 20px 0 0;
}

.contact-list div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.contact-list dt {
  color: var(--muted);
  font-weight: 800;
}

.contact-list dd {
  margin: 0;
}

.note {
  border-left: 4px solid var(--accent);
  margin: 24px 0 0;
  padding: 14px 16px;
  background: #fff8ef;
  color: #3b2b17;
}

.check-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0;
  list-style: none;
}

.check-list li {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  background: var(--surface);
  color: #2c3e52;
  font-weight: 700;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 6px;
  padding: 11px 18px;
  background: var(--brand-dark);
  color: #ffffff;
  font-weight: 850;
  text-decoration: none;
  box-shadow: 0 14px 30px -24px rgba(10, 23, 43, 0.8);
  transition: transform 180ms ease, background-color 180ms ease;
}

.button:hover {
  background: var(--accent);
  color: #321c05;
}

.redirect-card {
  width: min(680px, calc(100% - 32px));
  border: 1px solid rgba(80, 159, 205, 0.22);
  border-radius: 8px;
  padding: clamp(28px, 6vw, 52px);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
}

.redirect-card img {
  width: 112px;
  height: 112px;
  display: block;
  margin-bottom: 26px;
  border-radius: 0;
  background: var(--brand);
}

.redirect-card h1 {
  font-size: clamp(2rem, 6vw, 3.7rem);
}

.redirect-card p {
  max-width: 54ch;
  color: #40556b;
}

.redirect-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.legal-mini-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-weight: 750;
}

.site-footer {
  position: relative;
  margin-top: auto;
  background: var(--brand);
  color: #102238;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: -45px 0 auto;
  height: 46px;
  background: var(--brand);
  clip-path: polygon(0 100%, 0 0, 50% 100%, 100% 0, 100% 100%);
}

.footer-inner {
  width: min(var(--max), calc(100% - 36px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 38px 0 32px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a {
  color: #0d243a;
  font-weight: 800;
  text-decoration: none;
}

.footer-links a:hover {
  color: #ffffff;
}

address {
  font-style: normal;
}

@media (max-width: 820px) {
  .nav,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    justify-content: flex-start;
  }

  .legal-layout {
    grid-template-columns: 1fr;
    width: min(100% - 28px, var(--max));
  }

  .toc {
    position: static;
  }

  .info-grid,
  .check-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .topbar {
    padding: 22px 14px;
  }

  .brand img {
    width: 88px;
    height: 88px;
  }

  .nav-links a {
    min-height: 36px;
    padding: 7px 10px;
    font-size: 0.84rem;
  }

  .hero-inner {
    padding-inline: 14px;
  }

  .contact-list div {
    grid-template-columns: 1fr;
    gap: 2px;
  }
}

@media print {
  .topbar,
  .toc,
  .site-footer,
  .redirect-actions,
  .legal-mini-nav {
    display: none;
  }

  body {
    background: #ffffff;
    color: #111827;
  }

  .legal-layout {
    display: block;
    width: 100%;
    padding: 0;
  }

  .legal-hero::after {
    display: none;
  }
}
