/* Provider Compliance Bureau
   Layout concept: a regulatory binder. Left-aligned content on a steady grid; a narrow
   margin column carries section labels and CFR references. */
:root {
  /* Color */
  --ink: #0d1a2b;          /* headings */
  --text: #233041;         /* body */
  --slate: #566377;        /* secondary text */
  --navy: #13294b;         /* brand, dark sections */
  --navy-deep: #0c1c35;    /* footer */
  --navy-line: #2a4369;    /* rules on navy */
  --on-navy: #e9eef6;      /* text on navy */
  --on-navy-muted: #a9b8cd;
  --accent: #2b67ab;       /* links, focus, restrained highlight */
  --accent-strong: #1f5290;
  --sky: #6fa3dc;          /* accent on navy */
  --paper: #ffffff;
  --mist: #f3f6f9;
  --mist-2: #e7ecf3;
  --line: #d7dee8;
  --ok: #1d6f5c;  --ok-bg: #e3f1ec;
  --warn: #93600f; --warn-bg: #f8eedb;
  --crit: #9f3636; --crit-bg: #f7e5e3;

  /* Type */
  --display: "Source Serif 4", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: "IBM Plex Sans", -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: var(--sans); /* small-caps labels use the body face */
  --fs-xs: .8125rem; --fs-sm: .9375rem; --fs-base: 1.0625rem; --fs-md: 1.25rem;
  --fs-lg: clamp(1.45rem, 1.2rem + 1vw, 1.85rem);
  --fs-xl: clamp(1.9rem, 1.4rem + 2vw, 2.7rem);
  --fs-xxl: clamp(2.25rem, 1.5rem + 3.2vw, 3.6rem);

  /* Layout */
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --radius: 4px;
  --header-h: 72px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0; background: var(--paper); color: var(--text);
  font-family: var(--sans); font-size: var(--fs-base); line-height: 1.65;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
a { color: var(--accent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-strong); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.2; margin: 0; text-wrap: balance; }
h1, h2 { font-family: var(--display); font-weight: 600; letter-spacing: -.01em; }
h3, h4 { font-family: var(--sans); font-weight: 600; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; background: var(--navy); color: #fff; padding: 10px 16px; z-index: 100; border-radius: var(--radius); }
.skip:focus { top: 12px; color: #fff; }
.wrap { max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.muted { color: var(--slate); }
.icon { width: 24px; height: 24px; flex: none; }

/* ---------- Eyebrows, section heads ---------- */
.eyebrow {
  font-family: var(--mono); font-size: var(--fs-xs); font-weight: 500;
  text-transform: uppercase; letter-spacing: .09em; color: var(--accent);
  display: inline-flex; align-items: center; gap: .6em;
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: currentColor; }
.section-head { display: grid; gap: 14px; max-width: 46rem; margin-bottom: clamp(28px, 4vw, 44px); }
.section-head h2 { font-size: var(--fs-xl); }
.section-head p { color: var(--slate); font-size: var(--fs-md); line-height: 1.55; }
.cite { font-family: var(--mono); font-size: var(--fs-xs); color: var(--slate); letter-spacing: .02em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: 600 var(--fs-sm)/1.2 var(--sans); letter-spacing: .01em;
  padding: 14px 22px; border-radius: var(--radius); border: 1px solid transparent;
  text-decoration: none; cursor: pointer; transition: background-color .15s, border-color .15s, color .15s;
  text-align: center;
}
.btn .icon { width: 18px; height: 18px; }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--accent-strong); color: #fff; }
.btn-secondary { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-secondary:hover { background: var(--navy); color: #fff; }
.on-navy .btn-primary, .btn-light { background: #fff; color: var(--navy); }
.on-navy .btn-primary:hover, .btn-light:hover { background: var(--mist-2); color: var(--navy); }
.on-navy .btn-secondary { color: #fff; border-color: rgba(255,255,255,.45); }
.on-navy .btn-secondary:hover { background: rgba(255,255,255,.1); border-color: #fff; color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.text-link { display: inline-flex; align-items: center; gap: .4em; font-weight: 600; font-size: var(--fs-sm); text-decoration: none; }
.text-link .icon { width: 16px; height: 16px; transition: transform .15s; }
.text-link:hover .icon { transform: translateX(3px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: rgba(255,255,255,.97); border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(1.4) blur(6px);
}
.header-row { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand img { width: 34px; height: 34px; flex: none; }
.brand-text { display: grid; line-height: 1.15; min-width: 0; }
.brand-name { font-family: var(--display); font-weight: 600; font-size: 1.12rem; letter-spacing: -.005em; color: var(--ink); }
.brand-sub { font-family: var(--mono); font-size: .66rem; letter-spacing: .08em; text-transform: uppercase; color: var(--slate); }
.brand:hover .brand-name { color: var(--navy); }
.site-nav { display: flex; align-items: center; gap: 20px; margin-left: auto; }
.nav-list { list-style: none; display: flex; align-items: center; gap: 4px; }
.nav-list > li > a, .sub-toggle {
  display: inline-flex; align-items: center; gap: 4px; padding: 8px 12px;
  font: 500 var(--fs-sm)/1.2 var(--sans); color: var(--text); text-decoration: none; white-space: nowrap;
  background: none; border: 0; cursor: pointer; border-radius: var(--radius);
}
.nav-list > li > a:hover, .sub-toggle:hover { color: var(--navy); background: var(--mist); }
.nav-list > li > a[aria-current="page"], .sub-toggle.is-current { color: var(--navy); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.chev { width: 16px; height: 16px; transition: transform .15s; }
.sub-toggle[aria-expanded="true"] .chev { transform: rotate(180deg); }
.has-sub { position: relative; }
.sub {
  list-style: none; position: absolute; top: calc(100% + 10px); left: -12px; width: 330px;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 18px 40px -18px rgba(13,26,43,.35); padding: 8px; display: none;
}
.sub-toggle[aria-expanded="true"] + .sub { display: grid; }
.sub a { display: grid; gap: 2px; padding: 10px 12px; text-decoration: none; border-radius: var(--radius); }
.sub a strong { font-size: var(--fs-sm); color: var(--ink); font-weight: 600; }
.sub a span { font-size: var(--fs-xs); color: var(--slate); }
.sub a:hover, .sub a[aria-current="page"] { background: var(--mist); }
.nav-cta { padding: 11px 18px; white-space: nowrap; }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; color: var(--navy); cursor: pointer; }
.nav-toggle-close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-close { display: inline; }
.nav-toggle span { display: inline-flex; }

@media (max-width: 1180px) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%; display: none; flex-direction: column; align-items: stretch;
    background: var(--paper); border-bottom: 1px solid var(--line); padding: 12px var(--gutter) 20px;
    box-shadow: 0 20px 30px -20px rgba(13,26,43,.3); max-height: calc(100dvh - var(--header-h)); overflow-y: auto;
  }
  .site-nav.is-open { display: flex; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-list > li { border-bottom: 1px solid var(--mist-2); }
  .nav-list > li > a, .sub-toggle { width: 100%; justify-content: space-between; padding: 14px 4px; font-size: var(--fs-base); }
  .nav-list > li > a[aria-current="page"], .sub-toggle.is-current { box-shadow: none; color: var(--accent); }
  .sub { position: static; width: auto; box-shadow: none; border: 0; padding: 0 0 10px; }
  .nav-cta { margin-top: 8px; }
}
@media (max-width: 480px) { .brand-sub { display: none; } .brand-name { font-size: 1rem; } }

/* ---------- Sections ---------- */
.section { padding-block: clamp(56px, 8vw, 104px); }
.section-tight { padding-block: clamp(40px, 6vw, 72px); }
.bg-mist { background: var(--mist); }
.bg-navy { background: var(--navy); color: var(--on-navy); }
.bg-navy h1, .bg-navy h2, .bg-navy h3 { color: #fff; }
.bg-navy .eyebrow { color: var(--sky); }
.bg-navy .section-head p, .bg-navy .muted { color: var(--on-navy-muted); }
.bg-navy a:not(.btn) { color: #fff; }
.rule-top { border-top: 1px solid var(--line); }

/* ---------- Home hero ---------- */
.hero { position: relative; overflow: hidden; background: var(--navy); color: var(--on-navy); }
.hero-grid { position: relative; padding-block: clamp(64px, 9vw, 120px); }
.hero-copy { max-width: 52rem; }
.hero h1 { color: #fff; font-size: var(--fs-xxl); line-height: 1.08; margin-top: 18px; max-width: 24ch; }
.hero .eyebrow { color: var(--sky); }
.hero-lead { margin-top: 22px; font-size: var(--fs-md); line-height: 1.55; color: var(--on-navy); max-width: 46rem; }
.hero-sub { margin-top: 14px; color: var(--on-navy-muted); max-width: 46rem; }
.hero .btn-row { margin-top: 32px; }
.hero-identity { margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--navy-line); font-size: var(--fs-xs); color: var(--on-navy-muted); max-width: 46rem; }

.status {
  font-family: var(--mono); font-size: .7rem; font-weight: 500; text-transform: uppercase; letter-spacing: .06em;
  padding: 4px 8px; border-radius: 3px; white-space: nowrap; border: 1px solid transparent;
}
.status-ok { color: var(--ok); background: var(--ok-bg); }
.status-warn { color: var(--warn); background: var(--warn-bg); }
.status-crit { color: var(--crit); background: var(--crit-bg); }

/* ---------- Interior page hero ---------- */
.page-hero { background: var(--mist); border-bottom: 1px solid var(--line); }
.page-hero .wrap { padding-block: clamp(48px, 7vw, 88px); display: grid; gap: 18px; }
.page-hero h1 { font-size: var(--fs-xxl); line-height: 1.1; max-width: 22ch; }
.page-hero .lead { font-size: var(--fs-md); line-height: 1.55; color: var(--slate); max-width: 44rem; }
.page-hero .btn-row { margin-top: 10px; }
.breadcrumb { font-size: var(--fs-xs); color: var(--slate); display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumb a { color: var(--slate); }

/* ---------- Margin layout (label column + content) ---------- */
.margin-layout { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); }
.margin-layout + .margin-layout { margin-top: clamp(40px, 6vw, 72px); padding-top: clamp(40px, 6vw, 72px); border-top: 1px solid var(--line); }
.margin-label { display: grid; gap: 10px; align-content: start; }
.margin-label h2 { font-size: var(--fs-lg); }
.margin-label .cite { display: block; }
@media (max-width: 820px) { .margin-layout { grid-template-columns: 1fr; } }

/* ---------- Text ---------- */
.lede { font-size: var(--fs-md); line-height: 1.6; color: var(--text); max-width: 44rem; }
.stack > * + * { margin-top: 1em; }
.measure { max-width: 44rem; }

/* ---------- Lists ---------- */
.check-list { list-style: none; display: grid; gap: 10px; }
.check-list li { position: relative; padding-left: 28px; }
.check-list li::before {
  content: ""; position: absolute; left: 2px; top: .5em; width: 14px; height: 8px;
  border-left: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(-45deg) translateY(-2px);
}
.bg-navy .check-list li::before { border-color: var(--sky); }
.dash-list { list-style: none; display: grid; gap: 8px; }
.dash-list li { position: relative; padding-left: 20px; }
.dash-list li::before { content: ""; position: absolute; left: 0; top: .8em; width: 10px; height: 1px; background: var(--slate); }
.cols-2 { columns: 2 18rem; column-gap: 40px; }
.cols-2 li { break-inside: avoid; margin-bottom: 10px; }

/* ---------- Grids & cards ---------- */
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 2.4vw, 30px); display: grid; gap: 12px; align-content: start; min-width: 0; }
.card h3 { font-size: 1.12rem; }
.card p { color: var(--slate); font-size: var(--fs-sm); }
.card .icon-badge { width: 44px; height: 44px; border-radius: var(--radius); background: var(--mist); color: var(--navy); display: grid; place-items: center; }
.card-link { text-decoration: none; color: inherit; transition: border-color .15s, box-shadow .15s, transform .15s; }
.card-link:hover { border-color: var(--accent); box-shadow: 0 12px 28px -18px rgba(19,41,75,.45); color: inherit; }
.card-link:hover h3 { color: var(--accent-strong); }
.card .text-link { margin-top: auto; padding-top: 6px; }

/* Consequences (restrained risk grid) */
.risk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.risk { padding: 22px 24px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: grid; gap: 6px; align-content: start; background: var(--paper); }
.risk h3 { font-size: 1rem; }
.risk p { font-size: var(--fs-sm); color: var(--slate); }
.note { font-size: var(--fs-sm); color: var(--slate); border-left: 2px solid var(--line); padding-left: 14px; max-width: 46rem; }

/* Process steps (a real sequence, so numbered) */
.steps { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: 0; counter-reset: step; }
.step { position: relative; padding: 26px 24px 26px 0; display: grid; gap: 10px; align-content: start; border-top: 2px solid var(--line); }
.step::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  font-family: var(--mono); font-size: var(--fs-xs); color: var(--accent); letter-spacing: .08em; font-weight: 500;
}
.step::after { content: ""; position: absolute; top: -2px; left: 0; width: 40px; height: 2px; background: var(--accent); }
.step h3 { font-size: 1.12rem; }
.step p { color: var(--slate); font-size: var(--fs-sm); }
.bg-navy .step { border-color: var(--navy-line); }
.bg-navy .step::after { background: var(--sky); }
.bg-navy .step::before { color: var(--sky); }
.bg-navy .step p { color: var(--on-navy-muted); }

.timeline { list-style: none; counter-reset: step; display: grid; gap: 0; }
.timeline > li { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 0 24px; padding-bottom: 36px; position: relative; }
.timeline > li::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  width: 48px; height: 48px; border: 1px solid var(--navy); border-radius: 50%; display: grid; place-items: center;
  font-family: var(--mono); font-size: var(--fs-sm); color: var(--navy); background: var(--paper); position: relative; z-index: 1;
}
.timeline > li::after { content: ""; position: absolute; left: 24px; top: 48px; bottom: 0; width: 1px; background: var(--line); }
.timeline > li:last-child::after { display: none; }
.timeline h3 { font-size: var(--fs-md); margin-top: 10px; font-family: var(--display); font-weight: 600; }
.timeline .tl-body { display: grid; gap: 12px; min-width: 0; }
.timeline .tl-body > p { color: var(--slate); }

/* Priority chips (roadmap) */
.priority-row { display: flex; flex-wrap: wrap; gap: 8px; }

/* Segment tiles */
.segment-tile { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 16px; align-items: start; }
.segment-tile .icon-badge { grid-row: span 2; }

/* Service detail blocks */
.service { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 56px); padding-block: clamp(32px, 4vw, 48px); border-top: 1px solid var(--line); }
.service:first-child { border-top: 0; padding-top: 0; }
.service-head { display: grid; gap: 12px; align-content: start; }
.service-head h2 { font-size: var(--fs-lg); }
.service-head p { color: var(--slate); }
.service-num { font-family: var(--mono); font-size: var(--fs-xs); color: var(--accent); letter-spacing: .08em; }
.deliverables { background: var(--mist); border-radius: var(--radius); padding: 22px 24px; display: grid; gap: 14px; align-content: start; }
.deliverables h3 { font-family: var(--mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .09em; color: var(--slate); font-weight: 500; }
@media (max-width: 820px) { .service { grid-template-columns: 1fr; } }

/* Safeguards trio */
.safeguards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: clamp(16px, 2vw, 24px); }
.safeguard { border-top: 3px solid var(--navy); background: var(--paper); padding: 24px; display: grid; gap: 12px; align-content: start; border-left: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.safeguard h3 { font-family: var(--display); font-size: var(--fs-md); }

/* Gap table */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); min-width: 34rem; }
th, td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--mist-2); vertical-align: top; }
th { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--slate); font-weight: 500; background: var(--mist); }
tr:last-child td { border-bottom: 0; }
td:first-child { color: var(--ink); font-weight: 500; }

/* Exposure map (security page) */
.flow { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.flow-cell { background: var(--paper); padding: 20px; display: grid; gap: 8px; align-content: start; }
.flow-cell .icon { color: var(--accent); }
.flow-cell h3 { font-size: 1rem; }
.flow-cell p { font-size: var(--fs-sm); color: var(--slate); }

/* Callout panel */
.panel { background: var(--navy); color: var(--on-navy); border-radius: 6px; padding: clamp(24px, 3vw, 40px); display: grid; gap: 14px; }
.panel h2, .panel h3 { color: #fff; }
.panel p { color: var(--on-navy-muted); }
.panel-light { background: var(--mist); color: var(--text); border: 1px solid var(--line); }
.panel-light h2, .panel-light h3 { color: var(--ink); }
.panel-light p { color: var(--slate); }

/* CTA band */
.cta-band { background: var(--navy); color: var(--on-navy); position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; right: -10%; top: -40%; width: 60%; height: 180%; background: radial-gradient(closest-side, rgba(111,163,220,.16), transparent); pointer-events: none; }
.cta-inner { position: relative; display: grid; grid-template-columns: minmax(0, 1.4fr) auto; gap: 32px; align-items: center; padding-block: clamp(48px, 7vw, 88px); }
.cta-inner h2 { color: #fff; font-size: var(--fs-xl); }
.cta-inner p { color: var(--on-navy-muted); margin-top: 12px; max-width: 40rem; }
@media (max-width: 820px) { .cta-inner { grid-template-columns: 1fr; } }

/* ---------- Resources ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 28px; }
.chip {
  font: 500 var(--fs-xs)/1 var(--sans); padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--paper); color: var(--text); cursor: pointer; text-decoration: none;
}
.chip:hover { border-color: var(--navy); color: var(--navy); }
.chip[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.search { position: relative; flex: 1 1 16rem; max-width: 22rem; margin-left: auto; }
.search .icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--slate); }
.search input { width: 100%; padding: 10px 12px 10px 38px; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; font-size: var(--fs-sm); background: var(--paper); color: var(--text); }
.article-card { display: grid; gap: 10px; align-content: start; }
.article-card .meta, .meta { font-family: var(--mono); font-size: .72rem; color: var(--slate); letter-spacing: .03em; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.article-card h3 { font-family: var(--display); font-size: 1.3rem; font-weight: 600; line-height: 1.25; }
.tag { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; color: var(--accent); }
.topic-list { list-style: none; display: grid; gap: 6px; }
.topic-list li { font-size: var(--fs-sm); color: var(--slate); }
.empty { padding: 32px; text-align: center; color: var(--slate); border: 1px dashed var(--line); border-radius: var(--radius); }

/* Article page */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 17rem; gap: clamp(32px, 5vw, 72px); align-items: start; }
.article-aside { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 18px; }
@media (max-width: 960px) { .article-layout { grid-template-columns: 1fr; } .article-aside { position: static; } }
.takeaways { background: var(--mist); border-left: 3px solid var(--navy); padding: 20px 24px; border-radius: 0 var(--radius) var(--radius) 0; display: grid; gap: 10px; margin-bottom: 36px; }
.takeaways h2 { font-family: var(--mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .09em; color: var(--slate); font-weight: 500; }
.prose { max-width: 44rem; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: var(--fs-lg); margin-top: 1.9em; }
.prose h3 { font-size: 1.15rem; margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; display: grid; gap: .45em; }
.prose li::marker { color: var(--accent); }
.prose blockquote { margin: 1.4em 0; padding-left: 18px; border-left: 2px solid var(--accent); color: var(--slate); }
.prose code { font-family: var(--mono); font-size: .88em; background: var(--mist); padding: 1px 5px; border-radius: 3px; }
.prose table { min-width: 0; }
.disclaimer { margin-top: 40px; padding-top: 18px; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--slate); max-width: 44rem; }

/* ---------- Forms ---------- */
.form-layout { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 960px) { .form-layout { grid-template-columns: 1fr; } }
.form { background: var(--paper); border: 1px solid var(--line); border-radius: 6px; padding: clamp(22px, 3vw, 40px); display: grid; gap: 28px; }
.form-progress { display: flex; gap: 8px; align-items: center; font-family: var(--mono); font-size: var(--fs-xs); color: var(--slate); letter-spacing: .04em; }
.form-progress span { display: inline-flex; align-items: center; gap: 8px; }
.form-progress b { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-weight: 500; }
.form-progress .is-active b { background: var(--navy); border-color: var(--navy); color: #fff; }
.form-progress .is-active { color: var(--ink); }
.form-progress .sep { flex: 0 0 28px; height: 1px; background: var(--line); }
fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 18px; min-width: 0; }
legend { font-family: var(--display); font-weight: 600; font-size: var(--fs-md); color: var(--ink); padding: 0; margin-bottom: 4px; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: 18px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field label, .field .label { font-size: var(--fs-sm); font-weight: 500; color: var(--ink); }
.field .hint { font-size: var(--fs-xs); color: var(--slate); }
.req { color: var(--crit); margin-left: 2px; }
.opt { font-weight: 400; color: var(--slate); font-size: var(--fs-xs); }
input[type="text"], input[type="email"], input[type="tel"], input[type="number"], select, textarea {
  width: 100%; font: inherit; font-size: var(--fs-base); color: var(--text); background: var(--paper);
  border: 1px solid #b9c4d3; border-radius: var(--radius); padding: 11px 12px; min-height: 46px;
  transition: border-color .15s, box-shadow .15s;
}
textarea { min-height: 130px; resize: vertical; line-height: 1.5; }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23566377' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 16px; padding-right: 40px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(43,103,171,.18); }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--crit); }
.error-msg { font-size: var(--fs-xs); color: var(--crit); }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); gap: 8px; }
.choice { display: flex; gap: 10px; align-items: flex-start; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; font-size: var(--fs-sm); line-height: 1.35; }
.choice:hover { border-color: #b9c4d3; }
.choice input { margin: 2px 0 0; width: 16px; height: 16px; accent-color: var(--navy); flex: none; }
.choice:has(input:checked) { border-color: var(--navy); background: var(--mist); }
.inline-choices { display: flex; flex-wrap: wrap; gap: 8px; }
.inline-choices .choice { flex: 0 1 auto; }
.phi-warning { display: flex; gap: 12px; align-items: flex-start; background: var(--warn-bg); color: #5f3f09; border-radius: var(--radius); padding: 14px 16px; font-size: var(--fs-sm); }
.phi-warning .icon { color: var(--warn); width: 20px; height: 20px; margin-top: 2px; }
.form-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); padding-top: 22px; }
.form-actions .fine { font-size: var(--fs-xs); color: var(--slate); max-width: 26rem; }
.hp { position: absolute; left: -9999px; }
.form-aside { display: grid; gap: 20px; position: sticky; top: calc(var(--header-h) + 24px); }
@media (max-width: 960px) { .form-aside { position: static; } }
.js .step-hidden { display: none; }
.form-error-summary { background: var(--crit-bg); color: var(--crit); padding: 12px 16px; border-radius: var(--radius); font-size: var(--fs-sm); }

/* Confirmation */
.confirm { max-width: 46rem; display: grid; gap: 20px; }
.confirm-mark { width: 56px; height: 56px; border-radius: 50%; background: var(--ok-bg); color: var(--ok); display: grid; place-items: center; }
.confirm-mark .icon { width: 28px; height: 28px; stroke-width: 2; }
.confirm h1 { font-size: var(--fs-xl); }

/* Team */
.person { display: grid; gap: 6px; }
.person img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: var(--radius); background: var(--mist); }
.person h3 { font-size: 1.05rem; margin-top: 8px; }
.person .role { font-size: var(--fs-sm); color: var(--slate); }

/* Checklist (lead magnet) */
.readiness-list { counter-reset: item; list-style: none; display: grid; gap: 0; border-top: 1px solid var(--line); }
.readiness-list li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.readiness-list .box { width: 20px; height: 20px; border: 1.5px solid var(--slate); border-radius: 3px; margin-top: 3px; }
.readiness-list strong { color: var(--ink); font-weight: 600; display: block; }
.readiness-list span { font-size: var(--fs-sm); color: var(--slate); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: var(--on-navy-muted); font-size: var(--fs-sm); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 32px; padding-block: 64px 40px; }
.footer-brand { display: grid; gap: 18px; align-content: start; }
.brand-invert .brand-name { color: #fff; }
.brand-invert .brand-sub { color: var(--on-navy-muted); }
.brand-invert:hover .brand-name { color: #fff; }
.footer-identity { max-width: 26rem; }
.footer-col h2 { font-family: var(--mono); font-size: .72rem; font-weight: 500; text-transform: uppercase; letter-spacing: .1em; color: var(--sky); margin-bottom: 14px; }
.footer-col ul { list-style: none; display: grid; gap: 9px; }
.site-footer a { color: var(--on-navy); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer .muted { color: var(--on-navy-muted); }
.footer-legal { border-top: 1px solid rgba(255,255,255,.1); padding-block: 26px 36px; display: grid; gap: 10px; font-size: var(--fs-xs); line-height: 1.6; }
.footer-legal p { max-width: 62rem; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 10px; color: var(--on-navy-muted); }
.footer-links { display: flex; gap: 20px; }
@media (max-width: 920px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* ---------- Utilities ---------- */
.mt-s { margin-top: 16px; } .mt-m { margin-top: 28px; } .mt-l { margin-top: 48px; }
.center-row { display: flex; justify-content: flex-start; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .site-footer, .cta-band, .btn { display: none !important; }
}
.h-xl { font-size: var(--fs-xl); }
.h-lg { font-size: var(--fs-lg); }
.hero-split { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.stack-hero { display: grid; gap: 18px; }
@media (max-width: 920px) { .hero-split { grid-template-columns: 1fr; } }
.icon-badge, .icon-badge-plain { color: var(--navy); }
.icon-badge-plain { width: 44px; height: 44px; border-radius: var(--radius); background: var(--mist); display: grid; place-items: center; }
.bg-mist .icon-badge-plain, .page-hero .icon-badge-plain { background: var(--paper); border: 1px solid var(--line); }
.margin-label .text-link { margin-top: 4px; }
.status-neutral { color: var(--accent-strong); background: var(--mist-2); }
.panel .eyebrow { color: var(--sky); }
.panel-light .eyebrow { color: var(--accent); }
.steps-compact { grid-template-columns: 1fr; }
.steps-compact .step { padding: 16px 0; }
.steps-compact .step h3 { font-size: 1rem; }
.panel .step h3 { color: #fff; }
.panel .step p { color: var(--on-navy-muted); }
.panel .step { border-color: var(--navy-line); }
.panel .step::after { background: var(--sky); }
.panel .step::before { color: var(--sky); }
.h-sm { font-size: 1rem; display: flex; align-items: center; gap: 8px; }
.h-sm .icon { width: 18px; height: 18px; color: var(--accent); }
.lead-magnet { display: flex; flex-wrap: wrap; gap: 20px 32px; align-items: center; justify-content: space-between; text-decoration: none; transition: background-color .15s; }
.lead-magnet > div { display: grid; gap: 10px; max-width: 40rem; }
.lead-magnet:hover { background: var(--accent-strong); }
.lead-magnet .btn { pointer-events: none; }
.article-title { max-width: 30ch; }
.page-hero .meta { margin-top: 4px; }
.related { display: grid; gap: 12px; }
.related-list { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--line); }
.related-list li { padding: 12px 0; border-bottom: 1px solid var(--line); display: grid; gap: 4px; }
.related-list a { font-weight: 500; text-decoration: none; color: var(--ink); line-height: 1.35; }
.related-list a:hover { color: var(--accent); }
.panel .h-sm { color: #fff; }
[hidden] { display: none !important; }
.panel-light .h-sm { color: var(--ink); }
.nav-toggle .nav-toggle-close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-close { display: inline-flex; }

/* ---------- Photos (replaceable; see src/_data/images.json) ---------- */
.photo { margin: 0; overflow: hidden; border-radius: 6px; background: var(--mist-2); }
.photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.hero-grid.has-media { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero-media { aspect-ratio: 4 / 5; max-width: 100%; box-shadow: 0 30px 60px -30px rgba(0,0,0,.55); }
.page-hero-split { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.page-hero-copy { display: grid; gap: 18px; align-content: start; }
.page-hero-media { aspect-ratio: 8 / 5; max-width: 100%; }
.page-hero.has-media h1 { font-size: var(--fs-xl); }
.card-media { padding: 0; gap: 0; overflow: hidden; }
.card-photo { aspect-ratio: 16 / 10; border-radius: 0; }
.card-body { padding: clamp(20px, 2.2vw, 26px); display: grid; gap: 10px; }
.segment-photo { aspect-ratio: 16 / 10; }
@media (max-width: 920px) {
  .hero-grid.has-media, .page-hero-split { grid-template-columns: 1fr; }
  .hero-media { aspect-ratio: 16 / 10; }
}

/* ================= Responsive refinements ================= */
/* Small-label legibility: keep supporting text at 12px or above */
.tag, .status, .meta, .article-card .meta, th, .footer-col h2, .ledger-meta { font-size: .78rem; }
.brand-sub { font-size: .75rem; letter-spacing: .05em; }
.cite { font-size: .8125rem; }

/* Collapsed layouts never exceed the column */
@media (max-width: 820px) { .margin-layout { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 1100px) { .margin-layout.stack-tablet { grid-template-columns: minmax(0, 1fr); gap: 20px; } .stack-tablet .margin-label { grid-template-columns: auto 1fr auto; align-items: center; } }
@media (max-width: 560px) { .stack-tablet .margin-label { grid-template-columns: auto 1fr; } .stack-tablet .margin-label .text-link { grid-column: 1 / -1; } }

/* Risk grid: 8 cells, always full rows */
.risk-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.risk-cta { background: var(--navy); color: var(--on-navy); text-decoration: none; }
.risk-cta h3 { color: #fff; }
.risk-cta p { color: var(--on-navy-muted); }
.risk-cta .text-link { color: #fff; margin-top: 6px; }
.risk-cta:hover { background: var(--accent-strong); color: #fff; }
@media (max-width: 960px) { .risk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .risk-grid { grid-template-columns: minmax(0, 1fr); } }

/* Process steps: full rows at every width */
.steps-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.steps-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1000px) {
  .steps-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 32px; }
  .steps-5 { grid-template-columns: minmax(0, 1fr); }
  .steps-5 .step { grid-template-columns: 2.5rem minmax(0, 1fr); column-gap: 12px; padding-block: 18px; }
  .steps-5 .step::before { grid-row: span 2; padding-top: 3px; }
}
@media (max-width: 560px) { .steps-4 { grid-template-columns: minmax(0, 1fr); } .steps-4 .step { padding-block: 20px; } }

/* Closing call to action stacks before the heading gets squeezed */
@media (max-width: 1180px) { .cta-inner { grid-template-columns: minmax(0, 1fr); gap: 24px; } .cta-inner h2 { max-width: 30ch; } }

/* Header: the main button stays visible on tablets; phones get a bottom bar */
.header-cta { display: none; padding: 11px 16px; white-space: nowrap; }
@media (max-width: 1180px) and (min-width: 641px) { .header-cta { display: inline-flex; margin-left: auto; } .header-cta + .nav-toggle { margin-left: 0; } .site-nav .nav-cta { display: none; } }
.mobile-cta { display: none; }
@media (max-width: 640px) {
  .mobile-cta {
    display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(255,255,255,.97); border-top: 1px solid var(--line);
    box-shadow: 0 -10px 24px -16px rgba(13,26,43,.35);
    transform: translateY(110%); transition: transform .2s ease;
  }
  .mobile-cta.is-visible { transform: none; }
  .mobile-cta .btn { width: 100%; }
}

/* Hero proportions */
.hero-grid.has-media { grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); }
@media (max-width: 920px) {
  .hero-grid.has-media { grid-template-columns: minmax(0, 1fr); }
  .hero-media { aspect-ratio: 3 / 2; }
  .page-hero-media { aspect-ratio: 16 / 9; }
}

/* Touch targets on phones and tablets */
@media (max-width: 1180px) {
  .text-link { min-height: 40px; }
  .chip { min-height: 40px; display: inline-flex; align-items: center; }
  .footer-col ul { gap: 2px; }
  .footer-col a { display: inline-flex; align-items: center; min-height: 40px; }
  .footer-links a { display: inline-flex; align-items: center; min-height: 40px; }
  .related-list a { display: block; padding-block: 4px; }
  .prose a { padding-block: 2px; }
}

/* Phones */
@media (max-width: 640px) {
  .hero-grid { padding-block: 44px 52px; }
  .hero .btn-row .btn, .page-hero .btn-row .btn, .cta-inner .btn-row .btn { width: 100%; }
  .page-hero .wrap { padding-block: 36px 40px; }
  .section { padding-block: 48px; }
  .section-head { margin-bottom: 24px; }
  /* Who We Serve cards become compact rows */
  .card-media { grid-template-columns: 104px minmax(0, 1fr); align-items: stretch; }
  .card-media .card-photo { aspect-ratio: auto; height: 100%; min-height: 120px; }
  .card-media .card-body { padding: 14px 16px; gap: 6px; }
  .card-media .card-body p { font-size: .875rem; }
  .card-media .text-link { min-height: 32px; }
  /* Service cards: tighter */
  .grid-3 > .card:not(.card-media) { padding: 18px; gap: 8px; }
  .card .icon-badge { width: 38px; height: 38px; }
  /* Forms use the full width */
  .form { border: 0; padding: 0; border-radius: 0; }
  .form-actions { flex-direction: column-reverse; align-items: stretch; }
  .form-actions .btn { width: 100%; }
  .form-actions .fine { text-align: center; max-width: none; }
  .form-progress .sep { flex-basis: 16px; }
  /* Footer: two link columns side by side, room for the bottom bar */
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; padding-block: 48px 28px; }
  .footer-col:last-child { grid-column: 1 / -1; }
  .site-footer { padding-bottom: 76px; }
  .compliance-page .site-footer { padding-bottom: 0; }
  .footer-bottom { flex-direction: column; gap: 4px; }
}
.brand-sub { white-space: nowrap; }
.brand-invert .brand-sub { white-space: normal; }
