/* On-Site: How it Works — page styles. Scoped under .hiw / hw-* */
.hiw {
  --hw-navy: var(--bs-tertiary-hex, #1e2d3b);
  --hw-blue: var(--bs-primary-hex, #0072bc);
  --hw-blue-dark: #005b96;
  --hw-yellow: var(--bs-warning-hex, #ffd240);
  --hw-yellow-dark: #f5c51e;
  --hw-light: var(--bs-light-hex, #f2f8fc);
  --hw-sky: #80b7e3;
  --hw-mist: #dbe7f0;
  --hw-ink: var(--bs-heading-color-hex, #212124);
  --hw-muted: #495356;
  --hw-line: var(--bs-secondary-border-hex, #e7e7e7);
  --hw-radius: var(--bs-border-radius, 10px);
  --hw-head: 'Catamaran', sans-serif;
  --hw-body: 'Nunito Sans', system-ui, sans-serif;
  font-family: var(--hw-body); color: var(--hw-ink); -webkit-font-smoothing: antialiased; max-width: 100%; overflow-x: hidden;
}
.hiw *, .hiw *::before, .hiw *::after { box-sizing: border-box; }
.hiw a:not(.hw-btn) { color: var(--hw-navy); }
.hiw a:not(.hw-btn):hover { color: var(--hw-blue); }
.hw-wrap { max-width: 1180px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.hw-rel { position: relative; }

/* Type */
.hw-kicker { font-family: var(--hw-head); font-weight: 700; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--hw-blue); margin: 0 0 10px; }
.hw-kicker--sky { color: var(--hw-sky); }
.hw-kicker--navy { color: var(--hw-navy); margin-bottom: 8px; }
.hw-h1 { font-family: var(--hw-head); font-weight: 800; font-size: clamp(34px, 5vw, 56px); line-height: 1.04; letter-spacing: -.02em; margin: 0 0 18px; max-width: 16ch; text-wrap: balance; }
.hw-h2 { font-family: var(--hw-head); font-weight: 800; font-size: clamp(28px, 3.6vw, 40px); line-height: 1.1; letter-spacing: -.015em; margin: 0 0 12px; }
.hw-h2--gap { margin-bottom: 14px; }
.hw-sub { font-size: 17px; line-height: 1.55; color: var(--hw-muted); margin: 0; }
.hw-sub--onnavy { font-size: 18px; color: var(--hw-mist); margin-bottom: 24px; }
.hw-label { font-family: var(--hw-head); font-weight: 700; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--hw-muted); margin: 0; }
.hw-max18 { max-width: 18ch; }
.hw-max46 { max-width: 46ch; }
.hw-max56 { max-width: 56ch; }
.hw-fine { font-size: 14px; line-height: 1.5; color: var(--hw-muted); margin: 18px 0 0; }
.hw-head { max-width: 60ch; margin-bottom: 36px; }
.hw-head--tight { margin-bottom: 30px; }
.hw-pill { font-family: var(--hw-head); font-weight: 700; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--hw-muted); background: var(--hw-light); padding: 4px 10px; border-radius: 999px; white-space: nowrap; }

/* Buttons */
.hw-btn { display: inline-flex; align-items: center; justify-content: center; font-family: var(--hw-body); font-weight: 700; font-size: 16px; padding: 13px 24px; border-radius: var(--hw-radius); text-decoration: none; border: 2px solid transparent; transition: background .15s, color .15s, border-color .15s; }
.hw-btn--lg { font-size: 17px; padding: 15px 26px; }
.hw-btn--block { display: flex; font-size: 17px; padding: 14px 22px; }
.hw-btn--primary { background: var(--hw-blue); color: #fff; border-color: var(--hw-blue); }
.hw-btn--primary:hover { background: var(--hw-blue-dark); border-color: var(--hw-blue-dark); color: #fff; }
.hw-btn--shadow { box-shadow: 0 6px 18px rgba(0,114,188,.35); }
.hw-btn--ghost { color: #fff; border-color: rgba(255,255,255,.35); padding: 15px 18px; }
.hw-btn--ghost:hover { color: var(--hw-yellow); border-color: var(--hw-yellow); }
.hw-btn--yellow { background: var(--hw-yellow); color: var(--hw-navy); }
.hw-btn--yellow:hover { background: var(--hw-yellow-dark); color: var(--hw-navy); }
.hw-btn--outline-navy { color: var(--hw-navy); border-color: var(--hw-navy); background: transparent; }
.hw-btn--outline-navy:hover { background: var(--hw-navy); color: #fff; }
.hw-btnrow { display: flex; flex-wrap: wrap; gap: 12px; }

/* Sections */
.hw-sec { border-bottom: 1px solid var(--hw-line); }
.hw-sec--white { background: #fff; }
.hw-sec--white > .hw-wrap { padding-top: 68px; padding-bottom: 68px; }
.hw-sec--light { background: var(--hw-light); }
.hw-sec--light > .hw-wrap { padding-top: 64px; padding-bottom: 68px; }
.hw-sec--navy { background: var(--hw-navy); color: #fff; border-bottom: 0; }
.hw-sec--navy > .hw-wrap { padding-top: 64px; padding-bottom: 64px; }
.hw-split { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px 56px; }
.hw-split--end { align-items: end; gap: 24px 56px; margin-bottom: 30px; }
.hw-split--center { align-items: center; }

/* Hero */
.hw-hero { background: var(--hw-navy); color: #fff; position: relative; overflow: hidden; }
.hw-hero__grid { position: relative; padding-top: 72px; padding-bottom: 80px; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px 56px; align-items: center; }
.hw-hero__crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-family: var(--hw-head); font-weight: 700; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--hw-sky); margin-bottom: 14px; }
.hw-hero__crumb a { color: var(--hw-sky); text-decoration: none; }
.hw-hero__crumb a:hover { color: #fff; }
.hw-hero__lede { font-size: clamp(17px, 2vw, 20px); line-height: 1.5; color: var(--hw-mist); max-width: 48ch; margin: 0 0 28px; }
.hw-hero__media { position: relative; }
.hw-hero__media img { width: 100%; aspect-ratio: 4/3; object-fit: cover; object-position: center 40%; border-radius: 14px; display: block; box-shadow: 0 24px 60px rgba(0,0,0,.35); }
.hw-hero__badge { position: absolute; left: 18px; bottom: -18px; background: var(--hw-yellow); color: var(--hw-navy); border-radius: var(--hw-radius); padding: 14px 18px; display: flex; align-items: center; gap: 14px; box-shadow: 0 12px 30px rgba(0,0,0,.3); }
.hw-hero__badge-num { font-family: var(--hw-head); font-weight: 800; font-size: 30px; line-height: 1; }
.hw-hero__badge-txt { font-size: 14px; line-height: 1.3; font-weight: 600; max-width: 16ch; }

/* Steps */
.hw-steps { position: relative; overflow: hidden; }
.hw-steps > .hw-wrap { padding-top: 76px; }
.hw-watermark { position: absolute; right: -120px; top: -80px; width: min(560px, 60vw); opacity: .05; pointer-events: none; user-select: none; }
.hw-steps__grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.hw-step { position: relative; border: 1px solid var(--hw-line); border-radius: 12px; padding: 26px 24px; display: flex; flex-direction: column; gap: 12px; background: #fff; }
.hw-step__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.hw-step__num { width: 44px; height: 44px; border-radius: 50%; background: var(--hw-navy); color: var(--hw-yellow); display: inline-flex; align-items: center; justify-content: center; font-family: var(--hw-head); font-weight: 800; font-size: 20px; }
.hw-step__title { font-family: var(--hw-head); font-weight: 800; font-size: 22px; line-height: 1.2; margin: 0; }
.hw-step__body { font-size: 16px; line-height: 1.5; color: var(--hw-muted); margin: 0; }
.hw-step__note { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--hw-line); font-size: 14px; line-height: 1.45; color: var(--hw-navy); font-weight: 600; }

/* Outcomes */
.hw-outcomes { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.hw-outcome { background: #fff; border: 1px solid var(--hw-line); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; }
.hw-outcome__bar { height: 6px; }
.hw-outcome__bar--blue { background: var(--hw-blue); }
.hw-outcome__bar--navy { background: var(--hw-navy); }
.hw-outcome__bar--yellow { background: var(--hw-yellow); }
.hw-outcome__body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.hw-outcome__title { font-family: var(--hw-head); font-weight: 800; font-size: 22px; line-height: 1.2; margin: 0; }
.hw-outcome__text { font-size: 16px; line-height: 1.5; color: var(--hw-muted); margin: 0; }
.hw-outcome__result { margin: auto 0 0; padding: 12px 0 0 18px; position: relative; font-size: 15px; line-height: 1.45; font-weight: 600; color: var(--hw-navy); }
.hw-outcome__result::before { content: ""; position: absolute; left: 0; top: 19px; width: 8px; height: 8px; border-radius: 50%; background: var(--hw-blue); }
.hw-911 { margin-top: 20px; background: var(--hw-navy); color: #fff; border-radius: 12px; padding: 18px 22px; display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; font-size: 15px; line-height: 1.5; }
.hw-911 strong { font-family: var(--hw-head); font-size: 17px; color: var(--hw-yellow); }
.hw-911 span { color: var(--hw-mist); }

/* Contact band */
.hw-cta { background: var(--hw-yellow); overflow: hidden; }
.hw-cta__inner { padding-top: 56px; padding-bottom: 56px; display: flex; flex-wrap: wrap; gap: 28px 40px; align-items: center; justify-content: space-between; }
.hw-cta__copy { flex: 1 1 380px; min-width: 0; }
.hw-cta__title { color: var(--hw-navy); max-width: 22ch; }
.hw-cta__text { font-size: 18px; line-height: 1.55; color: var(--hw-navy); margin: 0; max-width: 56ch; }
.hw-cta__actions { flex: 0 1 300px; min-width: 240px; display: flex; flex-direction: column; gap: 8px; }

/* Comparison table */
.hw-table-wrap { overflow-x: auto; border: 1px solid var(--hw-line); border-radius: 14px; }
.hw-table { width: 100%; min-width: 720px; border-collapse: separate; border-spacing: 0; font-size: 15px; }
.hw-table th, .hw-table td { border-bottom: 1px solid var(--hw-line); background: #fff; }
.hw-table tbody tr:last-child th, .hw-table tbody tr:last-child td { border-bottom: 0; }
.hw-table thead th { padding: 18px 16px; text-align: center; font-family: var(--hw-head); font-weight: 800; font-size: 15px; color: var(--hw-navy); min-width: 120px; }
.hw-table__lead { text-align: left !important; padding: 18px 22px !important; font-weight: 700 !important; font-size: 13px !important; letter-spacing: .12em; text-transform: uppercase; color: var(--hw-muted) !important; }
.hw-table__colhead { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.hw-table__colhead img { width: 34px; height: 34px; display: block; }
.hw-table tbody th { text-align: left; font-weight: 600; color: var(--hw-ink); padding: 16px 22px; line-height: 1.4; }
.hw-table tbody td { text-align: center; vertical-align: middle; padding: 16px 14px; color: var(--hw-ink); }
.hw-table .hw-table__ica { background: var(--hw-light); }
.hw-table__txt { font-size: 14px; line-height: 1.35; display: inline-block; max-width: 16ch; }
.hw-check { display: inline-flex; width: 22px; height: 22px; border-radius: 50%; background: var(--hw-blue); color: #fff; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.hw-dash { color: #b9c1c6; font-size: 18px; }

/* Getting started */
.hw-setup { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.hw-setup__item { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: start; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: var(--hw-radius); padding: 18px 20px; }
.hw-setup__num { font-family: var(--hw-head); font-weight: 800; font-size: 24px; line-height: 1; color: var(--hw-yellow); min-width: 28px; }
.hw-setup__title { font-family: var(--hw-head); font-weight: 800; font-size: 18px; line-height: 1.2; margin-bottom: 4px; }
.hw-setup__body { font-size: 15px; line-height: 1.5; color: var(--hw-mist); }

/* Motion */
@keyframes hwIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.hw-in { animation: hwIn .7s cubic-bezier(.2,.7,.3,1) both; }
.hw-in--1 { animation-duration: .6s; }
.hw-in--2 { animation-delay: .08s; }
.hw-in--3 { animation-delay: .16s; }
.hw-in--4 { animation-delay: .24s; }
.hiw.hw-js [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .7s cubic-bezier(.2,.7,.3,1), transform .7s cubic-bezier(.2,.7,.3,1); }
.hiw.hw-js [data-reveal].is-in { opacity: 1; transform: none; }
.hiw:not(.hw-js) [data-reveal] { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .hiw * { animation: none !important; transition: none !important; }
  .hiw.hw-js [data-reveal] { opacity: 1; transform: none; }
}


/* === how-it-works — appended for the live theme ==================== */
/* The theme colours h1..h6 directly (Bootstrap `h1 { color: var(--bs-heading-color) }`),
   and a direct rule beats the design's inherited colour. Every heading sitting on a
   dark band has to restate it or it renders #212124 ink on #1e2d3b navy (~1.1:1).
   BUILD-RECIPE: "Headline invisible, dark on dark". */
.hiw .hw-hero .hw-h1,
.hiw .hw-sec--navy .hw-h2,
.hiw .hw-sec--navy .hw-h3,
.hiw .hw-911 strong { color: #fff; }
.hiw .hw-cta .hw-cta__title { color: var(--hw-navy); }
.hiw .hw-step__title,
.hiw .hw-outcome__title,
.hiw .hw-table tbody th { color: var(--hw-ink); }

/* The site's ICA mark is inlined by getSvg and carries fill="#ffffff" on the <svg>
   root, so both uses here have to recolour it in CSS. White-on-white is invisible. */
.hiw .hw-watermark { fill: var(--hw-navy); }
.hiw .hw-table__colhead svg { width: 20px; height: 20px; fill: var(--hw-navy); flex: 0 0 auto; }

/* Design defect, not a theme collision: `.hiw a:not(.hw-btn)` (0,2,1) outranks
   `.hw-hero__crumb a` (0,1,1), so the breadcrumb link renders navy on the navy
   hero and disappears. Restate it at matching specificity. */
.hiw .hw-hero__crumb a { color: var(--hw-sky); }
.hiw .hw-hero__crumb a:hover { color: #fff; }

/* The hero <img> carries width/height attributes so the browser reserves the box
   (no layout shift). Those attributes are presentational hints, and an explicit
   height beats `aspect-ratio` — without this the photo renders at its natural
   1:1 instead of the design's 4:3. */
.hiw .hw-hero__media img { height: auto; }

/* Breadcrumb link was a 22px tap target; the design brief asks for >= 44px. */
.hiw .hw-hero__crumb a { display: inline-block; padding: 11px 0; }
.hiw .hw-hero__crumb { margin-bottom: 3px; }

/* The design hardcodes 1..4 and 1..3 in the markup; the MIGX rows cannot, and
   :lpad / :index are not core MODX output modifiers (BUILD-RECIPE). CSS counters
   instead, so the numbers follow whatever order an editor puts the rows in. */
.hiw .hw-steps__grid { counter-reset: hw-step; }
.hiw .hw-step { counter-increment: hw-step; }
.hiw .hw-step__num::before { content: counter(hw-step); }
.hiw .hw-setup { counter-reset: hw-setup; }
.hiw .hw-setup__item { counter-increment: hw-setup; }
.hiw .hw-setup__num::before { content: counter(hw-setup); }

/* A step row with no note must not leave an empty <p> holding the card's
   foot spacing open. */
.hiw .hw-step__note:empty { display: none; }

/* The design's three bar colours were modifier classes in hand-written markup.
   The cards now come from triage-cards-migx, and the order is fixed by meaning
   (most common -> escalation -> emergency), so the colours key off position.
   The original --blue/--navy/--yellow modifiers are left in place above and still
   work if anyone ever hand-writes a card. */
.hiw .hw-outcomes > :nth-child(1) .hw-outcome__bar { background: var(--hw-blue); }
.hiw .hw-outcomes > :nth-child(2) .hw-outcome__bar { background: var(--hw-navy); }
.hiw .hw-outcomes > :nth-child(3) .hw-outcome__bar { background: var(--hw-yellow); }

/* Three slots take richtext TVs (types-content, middle-content, bottom-text) or a
   richtext MIGX field, all of which emit their own <p>. They render inside a div
   rather than a <p> so the markup stays valid; restate the paragraph styling. */
.hiw .hw-outcome__text > p:last-child,
.hiw .hw-sub > p:last-child,
.hiw .hw-compare__note > p:last-child { margin-bottom: 0; }
.hiw .hw-outcome__text > p { font-size: 16px; line-height: 1.5; color: var(--hw-muted); }
.hiw .hw-sub > p { font: inherit; color: inherit; }

/* getSvg injects only id and class, so the two decorative marks are wrapped in a
   span that carries aria-hidden. display:contents keeps that span out of layout,
   so the watermark's absolute positioning and the column head's flex row behave
   exactly as the design drew them. */
.hiw .hw-deco { display: contents; }
