@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/Fraunces-Regular.ttf") format("truetype");
}
@font-face {
  font-family: "Fraunces";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/Fraunces-Italic.ttf") format("truetype");
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/IBMPlexSans-Regular.ttf") format("truetype");
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/IBMPlexSans-Italic.ttf") format("truetype");
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/IBMPlexSans-Medium.ttf") format("truetype");
}

:root {
  --navy: #0B2545;
  --teal: #0E7C7B;
  --ink: #233747;
  --paper: #F6F3EC;
  --card: #FFFFFF;
  --wash: #EDF4F3;
  --line: #D5E0DE;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.7 "IBM Plex Sans", Georgia, sans-serif;
}

.skip {
  position: absolute;
  left: 12px;
  top: 8px;
  background: var(--card);
  color: var(--navy);
  padding: 6px 10px;
  z-index: 20;
}
.skip:not(:focus) {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  width: 1px;
  overflow: hidden;
  white-space: nowrap;
}

header.site {
  background: var(--navy);
  color: #fff;
  padding: 18px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
header.site a { color: #fff; text-decoration: none; }
header.site a:hover { text-decoration: underline; text-underline-offset: 4px; }
header.site .brand { font-weight: 500; letter-spacing: 0.02em; }
header.site .brand span { font-weight: 400; opacity: 0.85; }

a { color: var(--teal); text-underline-offset: 3px; }
a:focus-visible { outline: 3px solid var(--teal); outline-offset: 4px; }

.wrap { max-width: 820px; margin: 0 auto; padding: 0 24px; }

nav.crumb {
  max-width: 820px;
  margin: 22px auto 0;
  padding: 0 24px;
  font-size: 14px;
  color: #5b6b76;
}
nav.crumb a { color: var(--navy); }

main { max-width: 820px; margin: 0 auto 48px; padding: 0 24px; }

section.card {
  background: var(--card);
  margin: 22px 0;
  padding: 48px 52px;
  border: 1px solid var(--line);
  scroll-margin-top: 16px;
}

.eyebrow {
  color: var(--teal);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 500;
}

h1, h2 {
  font-family: Fraunces, Georgia, serif;
  font-weight: 400;
  color: var(--navy);
  line-height: 1.15;
  margin: 8px 0 16px;
}
h1 { font-size: clamp(32px, 5vw, 48px); }
h2 { font-size: clamp(26px, 4vw, 34px); }
h3 {
  font-size: 18px;
  font-weight: 500;
  color: var(--navy);
  margin-top: 28px;
}

.dek {
  color: var(--teal);
  font-size: 20px;
  line-height: 1.45;
  margin-top: 0;
}

aside, pre {
  background: var(--wash);
  border-left: 3px solid var(--teal);
  padding: 16px 20px;
  margin: 22px 0;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 14px;
  line-height: 1.65;
  font-family: "IBM Plex Sans", ui-monospace, monospace;
}

table { border-collapse: collapse; width: 100%; font-size: 15px; }
th { text-align: left; background: var(--navy); color: #fff; font-weight: 500; }
td, th { padding: 12px; vertical-align: top; border-bottom: 1px solid var(--line); }
tr:nth-child(even) td { background: #f7faf9; }
.table-wrap { overflow-x: auto; }

.chapter-link {
  display: block;
  border: 1px solid var(--line);
  background: var(--wash);
  padding: 20px 22px;
  text-decoration: none;
  color: inherit;
  margin: 16px 0;
}
.chapter-link strong {
  display: block;
  color: var(--navy);
  font-size: 20px;
  font-family: Fraunces, Georgia, serif;
  font-weight: 400;
  margin: 4px 0 6px;
}
.chapter-link span { color: var(--teal); font-size: 15px; }

ol.pillars {
  columns: 2;
  padding-left: 20px;
}
ol.pillars li[aria-current="true"] { font-weight: 500; color: var(--navy); }

details.toc {
  margin: 18px 0 8px;
  border: 1px solid var(--line);
  background: var(--wash);
  padding: 8px 16px;
}
details.toc summary {
  cursor: pointer;
  font-weight: 500;
  color: var(--navy);
  padding: 8px 0;
}
details.toc a {
  display: block;
  padding: 6px 0;
  color: var(--navy);
  text-decoration: none;
}
details.toc a:hover { text-decoration: underline; }

.meta { font-size: 15px; color: #5b6b76; }

footer.site {
  text-align: center;
  padding: 36px 20px 48px;
  font-size: 14px;
  color: #5b6b76;
}

@media (max-width: 640px) {
  section.card { padding: 28px 20px; }
  ol.pillars { columns: 1; }
}

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

@media print {
  @page { size: letter; margin: 0.7in; }
  header.site, nav.crumb, details.toc, footer.site, .skip { display: none; }
  body { background: #fff; font-size: 10.5pt; }
  section.card { margin: 0; padding: 0; border: 0; break-before: page; }
  section.card:first-of-type { break-before: auto; }
}
