/* Navigation Impact — Mission & Data. */
.md-header {
  --md-nav-ink: #190b36;
  --md-nav-purple: #6a00ff;
  --md-nav-muted: #746b82;
  position: fixed !important;
  inset: 0 0 auto !important;
  z-index: 120 !important;
  background: rgba(251,250,246,.97) !important;
  border-bottom: 1px solid #e7e1ec !important;
  backdrop-filter: blur(20px);
  box-shadow: none !important;
  color: var(--md-nav-ink);
}
.md-header * { box-sizing: border-box; }
.md-header button { font: inherit; cursor: pointer; }
.md-header .md-header-inner {
  position: relative;
  display: flex !important;
  justify-content: space-between;
  gap: 24px;
  min-height: 94px;
  width: min(1220px, calc(100% - 64px));
  margin: 0 auto;
}
.md-header .brand { gap: 13px; flex: 0 0 auto; }
.md-header .brand-mark { width: 48px; height: 48px; }
.md-header .brand-copy strong { color: var(--md-nav-ink) !important; font-size: 17px; }
.md-header .brand-copy small { color: #da501e !important; font-size: 7px; }
.md-header .md-primary-nav {
  display: flex;
  position: static;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}
.md-header .md-nav-link,
.md-header .md-impact-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #62596e !important;
  font-family: var(--body);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
  text-decoration: none;
  transition: background .18s, color .18s, border-color .18s;
}
.md-header .md-nav-link:hover { background: #f0ebf6; color: var(--md-nav-purple) !important; }
.md-header .md-section-link[aria-current="location"] { background: #f3ebff; border-color: #e1d1f6; color: #6016c9 !important; }
.md-context-header .md-primary-nav { gap: 3px; }
.md-context-header .md-nav-link, .md-context-header .md-impact-trigger { padding-inline: 10px; }
html.md-context-page { scroll-padding-top: 110px; }
.md-context-page main > section[id] { scroll-margin-top: 0; }
.md-header .md-impact-trigger { color: var(--md-nav-ink) !important; }
.md-header .md-impact-trigger:hover,
.md-header .md-impact-trigger[aria-expanded="true"] {
  background: #eee5fc;
  border-color: #ded0f3;
  color: #5c14c7 !important;
}
.md-header .md-impact-trigger[data-current="true"]::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--md-nav-purple);
}
.md-chevron { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.8; transition: transform .2s; }
[aria-expanded="true"] > .md-chevron { transform: rotate(180deg); }
.md-mega[hidden], .md-nav-scrim[hidden], .md-primary-nav[hidden] { display: none !important; }
.md-mega {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(870px, calc(100vw - 64px));
  max-height: calc(100dvh - 130px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 25px 25px 0;
  color: var(--md-nav-ink);
  background: #fff;
  border: 1px solid #dbd2e6;
  border-radius: 20px;
  box-shadow: 0 24px 65px #180b3621, 0 3px 9px #180b3608;
  animation: md-menu-in .18s ease-out;
  text-align: left;
}
.md-mega::before { content: ""; position: absolute; inset: -17px 0 auto; height: 18px; }
.md-mega-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; padding: 0 9px 18px; }
.md-mega-eyebrow { display: block; color: #7843bc; font-size: 9px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; line-height: 1.5; }
.md-mega-title { display: block; margin-top: 5px; color: var(--md-nav-ink); font-family: var(--display); font-size: 23px; font-weight: 750; letter-spacing: -.045em; line-height: 1.25; }
.md-menu-mark { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid #e4d9f3; border-radius: 12px; color: #7d3cce; background: #fbf8ff; }
.md-menu-mark svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.md-impact-list { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; margin: 0; padding: 0 0 17px; list-style: none; }
.md-impact-list > li { min-width: 0; margin: 0; padding: 0; }
.md-header .md-impact-item {
  display: grid;
  grid-template-columns: 44px minmax(0,1fr) 14px;
  gap: 13px;
  align-items: center;
  min-height: 104px;
  width: 100%;
  padding: 14px 11px;
  background: #fff;
  border: 1px solid transparent;
  border-radius: 12px;
  color: var(--md-nav-ink) !important;
  text-decoration: none;
  white-space: normal;
  transition: background .18s, border-color .18s;
}
.md-header a.md-impact-item:hover,
.md-header a.md-impact-item:focus-visible { background: #f5efff; border-color: #e7dafa; }
.md-impact-item img { display: block; width: 44px; height: 44px; border-radius: 12px; object-fit: cover; }
.md-impact-copy { display: block; min-width: 0; }
.md-impact-meta { display: flex; align-items: center; gap: 9px; min-height: 17px; margin-bottom: 3px; }
.md-impact-number { color: #7b6e89; font-family: var(--body); font-size: 9px; font-weight: 750; letter-spacing: .08em; line-height: 1.2; }
.md-impact-badge { padding: 2px 6px; border-radius: 4px; background: #eeebf0; color: #716779; font-size: 8px; font-weight: 650; line-height: 1.3; white-space: nowrap; }
.md-impact-copy strong { display: block; margin: 0; color: var(--md-nav-ink); font-family: var(--body); font-size: 14px; font-weight: 720; letter-spacing: -.025em; line-height: 1.4; }
.md-impact-copy small { display: block; margin-top: 4px; color: #7b7186; font-family: var(--body); font-size: 11px; font-weight: 450; letter-spacing: 0; line-height: 1.45; }
.md-impact-arrow { align-self: center; color: #a392b8; font-size: 17px; transition: color .18s, transform .18s; }
a.md-impact-item:hover .md-impact-arrow { color: var(--md-nav-purple); transform: translateX(3px); }
.md-header .md-impact-item[aria-current="page"] { background: #f3ebff; border-color: #dfcdf9; }
.md-impact-item[aria-current="page"] .md-impact-number { color: var(--md-nav-purple); }
.md-impact-item[aria-current="page"] .md-impact-arrow { width: 6px; height: 6px; border-radius: 50%; background: var(--md-nav-purple); font-size: 0; }
.md-header .md-impact-item[aria-disabled="true"] { background: #fbfafc; cursor: default; }
.md-impact-item[aria-disabled="true"] img { opacity: .65; }
.md-impact-item[aria-disabled="true"] .md-impact-copy strong { color: #71677c; }
.md-impact-item[aria-disabled="true"] .md-impact-copy small { color: #786d83; }
.md-header .md-overview-item { background: #fbfaf6; }
.md-overview-icon { display: grid; place-items: center; width: 44px; height: 44px; color: #8b5aac; border: 1px solid #e5ddec; border-radius: 12px; background: #fff; }
.md-overview-icon svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.md-mega-footer { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 0 -25px; padding: 17px 34px; border-top: 1px solid #eee8f4; background: #fcfbfe; }
.md-mega-footer p { margin: 0; color: #80758d; font-size: 11px; line-height: 1.5; }
.md-header .md-mega-footer a { display: inline-flex; align-items: center; gap: 18px; color: #6924b9 !important; font-size: 11px; font-weight: 750; text-decoration: none; white-space: nowrap; }
.md-header .header-tools { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }
.md-header .lang-switch { min-width: 39px; min-height: 39px; color: var(--md-nav-ink) !important; border: 1px solid #d8cfdf !important; background: transparent; font-size: 10px; }
.md-header .header-action { min-height: 42px; padding: 11px 17px; color: #fff !important; background: #1a073c !important; font-size: 11px; }
.md-header .header-action:hover { background: #6a00ff !important; }
.md-nav-toggle { display: none; }
.md-mobile-contact { display: none !important; }
.md-nav-scrim { position: fixed; z-index: 119; inset: 94px 0 0; border: 0; padding: 0; background: #1403260b; cursor: default; }
.md-topic-dock { display: none; }
.md-header :focus-visible { outline: 3px solid #b18bff; outline-offset: 3px; }
@keyframes md-menu-in { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }
@media(min-width:1051px) and (max-width:1250px) {
  .md-header .md-header-inner { gap: 16px; width: calc(100% - 40px); }
  .md-header .md-primary-nav { gap: 0; }
  .md-header .md-nav-link, .md-header .md-impact-trigger { padding-inline: 10px; }
  .md-header .brand-copy strong { font-size: 14px; }
  .md-header .brand-mark { width: 42px; height: 42px; }
}
@media(max-width:1050px) {
  html.md-context-page { scroll-padding-top: 96px; }
  .md-header .md-header-inner { min-height: 80px; width: calc(100% - 40px); }
  .md-header .md-primary-nav { display: none; position: fixed; inset: 80px 0 auto; max-height: calc(100dvh - 80px); padding: 18px max(20px, calc((100vw - 680px)/2)) 26px; overflow-y: auto; overscroll-behavior: contain; flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 4px; background: #fff; border-top: 1px solid #eee7f3; border-bottom: 1px solid #ded4e6; box-shadow: 0 15px 35px #18052d1c; }
  .md-header .md-primary-nav > * { flex-shrink: 0; }
  .md-header.md-mobile-open .md-primary-nav { display: flex; }
  .md-header .md-nav-link, .md-header .md-impact-trigger { width: 100%; min-height: 44px; justify-content: space-between; padding: 12px 14px; font-size: 14px; border-radius: 9px; }
  .md-header .md-impact-trigger[data-current="true"]::before { display: none; }
  .md-nav-toggle { display: inline-flex; justify-content: center; align-items: center; gap: 9px; height: 40px; padding: 0 12px; border: 1px solid #dacfe4; border-radius: 9px; background: #fff; color: #352147; font-size: 11px !important; font-weight: 650 !important; }
  .md-toggle-lines { width: 15px; display: grid; gap: 4px; }
  .md-toggle-lines i { display: block; width: 15px; height: 1.5px; background: currentColor; transition: transform .2s; }
  [aria-expanded="true"] .md-toggle-lines i:first-child { transform: translateY(2.75px) rotate(45deg); }
  [aria-expanded="true"] .md-toggle-lines i:last-child { transform: translateY(-2.75px) rotate(-45deg); }
  .md-header .header-action { display: none; }
  .md-mega { position: static; width: 100%; max-height: none; margin-top: 8px; padding: 8px 0 0; overflow: visible; border: 0; border-radius: 0; box-shadow: none; animation: none; }
  .md-mega::before { display: none; }
  .md-mega-heading { padding: 9px 14px 12px; }
  .md-mega-title { font-size: 19px; }
  .md-menu-mark { display: none; }
  .md-impact-list { grid-template-columns: 1fr; gap: 3px; padding-bottom: 8px; }
  .md-header .md-impact-item { grid-template-columns: 40px minmax(0,1fr) 14px; gap: 12px; min-height: 86px; padding: 10px 13px; }
  .md-impact-item img, .md-overview-icon { width: 40px; height: 40px; border-radius: 10px; }
  .md-impact-copy strong { font-size: 14px; }
  .md-impact-copy small { font-size: 11px; }
  .md-impact-meta { margin-bottom: 1px; }
  .md-mega-footer { margin: 0 0 12px; padding: 13px 15px; border-radius: 10px; }
  .md-mega-footer p { max-width: 155px; font-size: 10px; }
  .md-header .md-mega-footer a { gap: 8px; font-size: 11px; }
  .md-header .md-mobile-contact { display: flex !important; align-items: center; justify-content: space-between; padding: 14px; margin-top: 8px; border-radius: 9px; color: #fff; background: #1a073c; font-size: 14px; font-weight: 650; }
  .md-nav-scrim { inset-block-start: 80px; background: #14032642; }
  body.md-nav-locked { overflow: hidden; }
}
@media(max-width:600px) {
  html.md-context-page { scroll-padding-top: 92px; }
  .md-header .md-header-inner { min-height: 76px; width: calc(100% - 30px); gap: 10px; }
  .md-header .brand { gap: 8px; }
  .md-header .brand-mark { width: 34px; height: 34px; }
  .md-header .brand-copy strong { font-size: 10px; letter-spacing: .16em; }
  .md-header .brand-copy small { font-size: 5px; letter-spacing: .19em; }
  .md-header .header-tools { gap: 8px; }
  .md-header .lang-switch { min-width: 34px; min-height: 36px; padding: 0 8px; font-size: 9px; }
  .md-nav-toggle { padding-inline: 10px; height: 36px; gap: 7px; }
  .md-header .md-primary-nav { inset-block-start: 76px; max-height: calc(100dvh - 76px); padding: 13px 15px 20px; }
  .md-nav-scrim { inset-block-start: 76px; }
}
@media(prefers-reduced-motion:reduce) {
  html.md-context-page { scroll-behavior: auto; }
  .md-header *, .md-header *::before, .md-header *::after { transition: none !important; animation: none !important; }
}

/* Keep page topics visible on mobile, without opening the main menu. */
@media(max-width:1050px) {
  html.md-floating-topic-page { --md-topic-offset: 190px; scroll-padding-top: var(--md-topic-offset); }
  .md-floating-topic-page .budget-content { padding-top: var(--md-topic-offset); }
  .md-floating-topic-page .gt-hero { padding-top: calc(var(--md-topic-offset) + 32px); }
  .md-header .md-topic-dock { display: block; position: absolute; top: calc(100% + 8px); left: 50%; transform: translateX(-50%); width: min(680px, calc(100% - 24px)); padding: 9px 8px 8px; border: 1px solid #e1d5f1; border-radius: 15px; background: rgba(255,255,255,.98); box-shadow: 0 9px 24px #210b4617; }
  .md-header.md-mobile-open .md-topic-dock { display: none; }
  .md-topic-caption { display: block; padding: 0 6px 6px; color: #70617d; font: 650 10px/1.4 var(--body); letter-spacing: .03em; }
  .md-topic-links { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 3px; }
  .md-time-topics .md-topic-links { grid-template-columns: 1fr 1fr 1fr 1.2fr .65fr; }
  .md-header .md-topic-link { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 2px; border: 1px solid transparent; border-radius: 9px; background: #f8f5fc; color: #5c4c6e; font: 650 clamp(11px,3vw,12px)/1.2 var(--body); text-decoration: none; white-space: nowrap; }
  .md-header .md-topic-link:hover, .md-header .md-topic-link:focus-visible { background: #eee4ff; color: #6016c9; }
  .md-header .md-topic-link[aria-current="location"] { border-color: #6a00ff; background: #6a00ff; color: #fff; box-shadow: 0 3px 8px #6a00ff20; }
}
