:root {
  --navy: #123044;
  --navy-deep: #0b2231;
  --teal: #277e8b;
  --gold: #c7a764;
  --cream: #faf7f0;
  --sand: #ede6da;
  --white: #ffffff;
  --ink: #173041;
  --muted: #65717a;
  --line: rgba(18, 48, 68, 0.15);
  --shadow: 0 20px 50px rgba(18, 48, 68, 0.1);
  --max: 1080px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-color: var(--teal) var(--sand); }
body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.68;
}
a { color: inherit; }
img { display: block; max-width: 100%; }
::selection { color: var(--white); background: var(--teal); }
.container { width: min(var(--max), calc(100% - 40px)); margin-inline: auto; }
.skip-link {
  position: fixed;
  top: -100px;
  left: 18px;
  z-index: 100;
  padding: 10px 15px;
  color: var(--navy);
  background: var(--white);
  border-radius: 8px;
}
.skip-link:focus { top: 16px; }
.topbar {
  padding: 8px 20px;
  color: rgba(255, 255, 255, 0.85);
  background: var(--navy-deep);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
}
.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(250, 247, 240, 0.97);
}
.nav {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand-logo { width: min(280px, 60vw); }
.nav-links { display: flex; align-items: center; gap: 20px; }
.nav-links a { display: inline-flex; min-height: 44px; align-items: center; color: var(--navy); font-size: 0.9rem; font-weight: 800; text-decoration: none; }
.nav-links a:focus-visible, .toc a:focus-visible, .legal-card a:focus-visible, .footer-grid a:focus-visible { outline: 2px solid var(--teal); outline-offset: 4px; }
.nav-links .book-link {
  min-height: 42px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  color: var(--white);
  background: var(--navy);
}
.hero { padding: 72px 0 42px; }
.eyebrow {
  margin-bottom: 14px;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
h1, h2, h3 { color: var(--navy); }
h1 {
  max-width: 850px;
  margin: 0 0 20px;
  font: 400 clamp(3.1rem, 7vw, 6rem) / 0.96 Georgia, "Times New Roman", serif;
  letter-spacing: -0.04em;
}
.hero p { max-width: 760px; margin: 0; color: var(--muted); font-size: 1.08rem; }
.effective { margin-top: 18px !important; font-size: 0.9rem !important; font-weight: 750; }
.legal-shell {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 44px;
  padding: 24px 0 88px;
  align-items: start;
}
.toc {
  position: sticky;
  top: 22px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  box-shadow: var(--shadow);
}
.toc strong { display: block; margin-bottom: 10px; color: var(--navy); }
.toc a { display: flex; min-height: 36px; align-items: center; padding: 5px 0; color: var(--muted); font-size: 0.88rem; text-decoration: none; }
.toc a:hover, .toc a:focus { color: var(--teal); }
.legal-card {
  padding: clamp(28px, 5vw, 54px);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--white);
  box-shadow: var(--shadow);
}
.legal-card section + section { margin-top: 42px; padding-top: 36px; border-top: 1px solid var(--line); }
.legal-card h2 { margin: 0 0 14px; font: 600 clamp(1.55rem, 3vw, 2.1rem) / 1.15 Georgia, serif; }
.legal-card h3 { margin: 24px 0 8px; font-size: 1.05rem; }
.legal-card p { margin: 0 0 14px; }
.legal-card ul, .legal-card ol { margin: 12px 0 0; padding-left: 1.25rem; }
.legal-card li + li { margin-top: 8px; }
.legal-card a { color: var(--teal); font-weight: 750; text-underline-offset: 3px; }
.notice {
  margin: 22px 0;
  padding: 20px 22px;
  border-left: 4px solid var(--gold);
  border-radius: 0 10px 10px 0;
  background: var(--sand);
}
.notice strong { color: var(--navy); }
.help-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.help-card { padding: 22px; border: 1px solid var(--line); border-radius: 12px; background: var(--cream); }
.help-card h2, .help-card h3 { margin-top: 0; }
.choice-box { padding: 22px; border: 1px solid var(--navy); background: #f7f7f5; }
.choice-box p { margin-bottom: 8px; }
.signature-note { color: var(--muted); font-size: 0.92rem; }
.site-footer { padding: 40px 0 28px; color: rgba(255, 255, 255, 0.76); background: var(--navy-deep); }
.footer-grid { display: grid; grid-template-columns: 1.35fr 1fr 1fr; gap: 30px; }
.footer-grid h2, .footer-grid h3 { margin: 0 0 12px; color: var(--white); font: 700 0.83rem/1.2 ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; letter-spacing: 0.1em; text-transform: uppercase; }
.footer-grid p { max-width: 470px; margin: 0; }
.footer-grid a { display: flex; min-height: 38px; width: fit-content; align-items: center; margin-top: 8px; color: inherit; text-decoration: none; }
.footer-grid a:hover, .footer-grid a:focus { color: var(--white); }
.footer-grid a:focus-visible { outline-color: var(--gold); }
.footer-bottom { margin-top: 30px; padding-top: 20px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; border-top: 1px solid rgba(255, 255, 255, 0.14); font-size: 0.82rem; }

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

@media (max-width: 820px) {
  .legal-shell { grid-template-columns: 1fr; }
  .toc { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 590px) {
  .container { width: min(100% - 26px, var(--max)); }
  .nav { min-height: 72px; }
  .nav-links a:not(.book-link) { display: none; }
  .hero { padding-top: 52px; }
  .legal-shell { gap: 24px; padding-bottom: 60px; }
  .legal-card { padding: 24px 19px; }
  .help-grid, .footer-grid { grid-template-columns: 1fr; }
}
