:root {
  --bg:        #faf7f1;
  --bg-card:   #fffdf8;
  --rule:      #d9d2c2;
  --rule-soft: #e8e2d3;
  --ink:       #1f1d18;
  --ink-soft:  #4a463d;
  --ink-mute:  #7a7466;
  --accent:    #6b3a2c;     /* muted oxblood */
  --accent-bg: #f1e6df;     /* whisper of accent for soft fills */
  --serif:     "Source Serif 4", "Charter", "Iowan Old Style", "Sitka Text", Cambria, Georgia, serif;
  --sans:      "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;

  --measure:   42rem;
  --gutter:    1.5rem;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-feature-settings: "kern", "liga", "onum";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  transition: border-color 120ms ease, color 120ms ease;
}
a:hover {
  border-bottom-color: var(--accent);
}

.page {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 4rem var(--gutter) 3rem;
}

/* ——— Masthead ——— */

.eyebrow {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  font-weight: 500;
  margin: 0 0 0.75rem;
}

/* Breadcrumb-style links inside the eyebrow keep the muted tone
   instead of jumping to the accent color. */
.eyebrow a {
  color: inherit;
  border-bottom-color: color-mix(in srgb, var(--ink-mute) 25%, transparent);
}
.eyebrow a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

h1.title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
  color: var(--ink);
}

.subtitle {
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.125rem;
  margin: 0 0 2rem;
}

.lede {
  font-size: 1.0625rem;
  color: var(--ink-soft);
  margin: 0 0 0.75rem;
}

hr.rule {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 2.5rem 0;
}

hr.rule-soft {
  border: 0;
  border-top: 1px solid var(--rule-soft);
  margin: 1.75rem 0;
}

/* ——— Breadcrumbs ——— */

.crumbs {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 2rem;
}
.crumbs a {
  color: var(--ink-mute);
  border-bottom-color: transparent;
}
.crumbs a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}
.crumbs .sep {
  margin: 0 0.6em;
  opacity: 0.6;
}
/* Deepest node — the current page — is not a link; give it contrast. */
.crumbs .current {
  color: var(--ink);
  font-weight: 600;
}

/* ——— Section heads ——— */

section.group {
  margin: 3rem 0 0;
}

.section-label {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 600;
  margin: 0 0 0.4rem;
}

h2.section-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.5rem;
  line-height: 1.25;
  letter-spacing: -0.005em;
  margin: 0 0 0.5rem;
  color: var(--ink);
}
/* On the home page the section title links to that section's own index;
   keep it looking like a heading, reveal the accent only on hover. */
.section-title a {
  color: inherit;
  border-bottom-color: transparent;
}
.section-title a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.section-blurb {
  color: var(--ink-soft);
  font-style: italic;
  margin: 0 0 1.5rem;
}

/* ——— Report groups (sectioned lists with linked headings) ——— */

.report-group {
  margin: 1.75rem 0 0;
}
.group-label {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.2rem;
  line-height: 1.25;
  margin: 0 0 0.85rem;
}
.group-label a {
  color: var(--accent);
  border-bottom-color: transparent;
}
.group-label a:hover {
  border-bottom-color: var(--accent);
}

/* ——— Entries ——— */

.entry {
  padding: 1.25rem 0 1.25rem 1.25rem;
  border-left: 2px solid var(--rule-soft);
  margin: 0 0 0.25rem;
  transition: border-color 160ms ease;
}
.entry:hover {
  border-left-color: var(--accent);
}
.entry + .entry {
  border-top: 1px solid var(--rule-soft);
}

.entry h2,
.entry h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.1875rem;
  line-height: 1.3;
  margin: 0 0 0.25rem;
}
.entry h2 a,
.entry h3 a {
  color: var(--ink);
  border-bottom-color: transparent;
}
.entry h2 a:hover,
.entry h3 a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.entry .meta {
  font-family: var(--sans);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 0.5rem;
}
.entry .meta .dot {
  margin: 0 0.5em;
  opacity: 0.6;
}

.entry p {
  margin: 0.5rem 0 0;
  color: var(--ink-soft);
}

.entry .aside {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--rule-soft);
  font-size: 0.95rem;
  color: var(--ink-mute);
}
.entry .aside a {
  color: var(--ink-soft);
}

/* ——— Details/expandable sublist (charter guides) ——— */

details.sublist {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border: 1px solid var(--rule-soft);
  border-radius: 2px;
  font-size: 0.95rem;
}
details.sublist[open] {
  background: var(--accent-bg);
}
details.sublist summary {
  cursor: pointer;
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--accent);
  list-style: none;
  outline: none;
}
details.sublist summary::-webkit-details-marker { display: none; }
details.sublist summary::before {
  content: "▸";
  display: inline-block;
  margin-right: 0.5em;
  transition: transform 160ms ease;
  color: var(--ink-mute);
}
details.sublist[open] summary::before {
  transform: rotate(90deg);
}

details.sublist ul {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
}
details.sublist li {
  padding: 0.5rem 0;
  border-top: 1px solid var(--rule-soft);
}
details.sublist li:first-child { border-top: 0; }
details.sublist li a {
  font-weight: 600;
  color: var(--ink);
  border-bottom-color: transparent;
}
details.sublist li a:hover {
  color: var(--accent);
}
details.sublist li span.gloss {
  display: block;
  color: var(--ink-soft);
  font-style: italic;
  margin-top: 0.15rem;
}

/* ——— Footer ——— */

footer.colophon {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 0.8125rem;
  color: var(--ink-mute);
  line-height: 1.55;
}
footer.colophon p { margin: 0 0 0.5rem; }
footer.colophon strong {
  color: var(--ink-soft);
  font-weight: 500;
}
footer.colophon a {
  color: var(--ink-soft);
  border-bottom-color: var(--rule);
}
footer.colophon a:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ——— Responsive ——— */

@media (max-width: 480px) {
  .page { padding: 2.5rem var(--gutter) 2rem; }
  .entry { padding-left: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* ===================================================================
   Dark variant — navy + gold (the dark half of the bluegold palette,
   matching the 55th landing). Opt in per page with <body class="dark">.
   Most rules already use the palette vars, so this is mostly an override.
   =================================================================== */

body.dark {
  --bg-card:   #15395d;
  --rule:      rgba(221, 232, 245, 0.22);
  --rule-soft: rgba(221, 232, 245, 0.12);
  --ink:       #eef4fb;
  --ink-soft:  #c7d6e8;
  --ink-mute:  #95a9c4;
  --accent:    #e8a800;                 /* gold */
  --accent-bg: rgba(232, 168, 0, 0.14);

  min-height: 100vh;
  background:
    radial-gradient(1100px 520px at 50% -8%, #1c4e80, transparent 60%),
    linear-gradient(180deg, #0f2a4a, #143862);
  background-attachment: fixed;
}

/* On the dark field, entries read as cards with a gold edge. */
body.dark .entry {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--rule-soft);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  padding: 1.1rem 1.25rem;
  margin: 0 0 0.9rem;
  transition: background 160ms ease, border-color 160ms ease;
}
body.dark .entry:hover {
  background: rgba(255, 255, 255, 0.06);
  border-left-color: var(--accent);
}
body.dark .entry + .entry {
  border-top: 1px solid var(--rule-soft);
}

@media (max-width: 480px) {
  body.dark .entry { padding: 1rem; }
}

/* ===================================================================
   Light variant — bluegold (blue-gray paper, gold rules, blue links).
   The light half of the bluegold palette, for content pages such as the
   meeting-transcript collection under /reference/video/. Opt in per page
   with <body class="bluegold">. Like body.dark, most rules already use
   the palette vars, so this is mostly a recolor.
   =================================================================== */

body.bluegold {
  --bg-card:   #ffffff;
  --rule:      #e3e8ef;
  --rule-soft: #eef2f7;
  --ink:       #19222e;
  --ink-soft:  #2b3744;
  --ink-mute:  #5b6775;
  --accent:    #e8a800;                 /* gold — reserved for rules/labels */
  --accent-bg: rgba(232, 168, 0, 0.14);

  background: #f4f6f9;
}

/* On the light field, links read as blue; gold stays a rules/accent color. */
body.bluegold a { color: #245c95; border-bottom-color: #cfe0f2; }
body.bluegold a:hover { color: #1c4e80; border-bottom-color: #1c4e80; }

/* ——— Full-width breadcrumb banner (navy + gold underline) ———
   The signature top bar for light content pages. Crumbs go inside it instead
   of inline. (Dark/index pages keep inline .crumbs on the dark field.) */
.page-banner {
  background: linear-gradient(180deg, #0f2a4a, #143862);
  border-bottom: 3px solid #e8a800;
  color: #dde8f5;
}
.page-banner-inner {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0.85rem var(--gutter);
}
/* Reset the inline-crumbs bottom margin when the crumbs live in the banner.
   Keep the `auto` left/right so .page-banner-inner stays centered (this rule is
   more specific than .page-banner-inner, so a bare `margin: 0` would un-center it). */
.page-banner .crumbs { margin: 0 auto; color: #dde8f5; }
.page-banner .crumbs a { color: #e8a800; border-bottom-color: transparent; }
.page-banner .crumbs a:hover { color: #fff; border-bottom-color: transparent; }
.page-banner .crumbs .sep { color: #dde8f5; opacity: 0.5; }
.page-banner .crumbs .current { color: #fff; }
