/* The Canadian business funding directory (grants-directory.html + grants-directory/*.html).
   Built by dev-tools/build-grants-directory.js; behaviour in js/directory.src.js.
   Design: the approved "hybrid" mock (dev-assets/directory-ideation-2026-10-04/mocks2/hybrid/hybrid.css),
   ported 2026-10-04. Component-scoped: every rule lives under .fd / .fd-body, and the design tokens are
   declared on .fd (not the document root) so the site nav and footer keep their own values. */
/* fallback faces sized to the web fonts (measured 2026-10-11: DM Sans sets 3.4% wider than Arial at regular weight and the same at
   semibold; Fraunces 3.7% wider than Georgia at 500 and 9% narrower than Georgia Bold at 600), so text holds its line breaks
   when the web font replaces the fallback */
@font-face { font-family: 'DM Sans Fallback'; src: local('Arial'); font-weight: 100 500; size-adjust: 103.4%; }
@font-face { font-family: 'DM Sans Fallback'; src: local('Arial Bold'), local('Arial'); font-weight: 600 900; size-adjust: 100%; }
@font-face { font-family: 'Fraunces Fallback'; src: local('Georgia'); font-weight: 100 500; size-adjust: 103.7%; }
@font-face { font-family: 'Fraunces Fallback'; src: local('Georgia Bold'), local('Georgia'); font-weight: 600 900; size-adjust: 90.9%; }
.fd {
  --ink: #14231c; --ink-2: #3b4842; --ink-3: #5c6862; --ink-4: #7d8781;
  --forest: #1a3d2e; --forest-2: #24543f; --forest-tint: #e9f0eb; --forest-wash: #f2f6f3;
  --paper: #ffffff; --field: #f4f3ee; --field-2: #ecebe4; --rule: #e3e1d8; --rule-2: #d6d3c8;
  --signal: #b4532a; --signal-ink: #8f3d1c; --signal-tint: #fbece4;
  --ty-grant: #2f7f74; --ty-grant-ink: #1f5f56; --ty-grant-bg: #e3f0ee;
  --ty-tax: #b98a2e; --ty-tax-ink: #7d5a12; --ty-tax-bg: #f6eedb;
  --ty-loan: #5b6b7f; --ty-loan-ink: #424f60; --ty-loan-bg: #e7eaef;
  --ty-fl: #7d9a6b; --ty-fl-ink: #4d6a3d; --ty-fl-bg: #ebf1e6;
  --ty-award: #a5563b; --ty-award-ink: #87412a; --ty-award-bg: #f6e7e1;
  --ty-prog: #7a5b8c; --ty-prog-ink: #5e4370; --ty-prog-bg: #efe8f3;
  --display: 'Fraunces', 'Fraunces Fallback', Georgia, serif;
  --ui: 'DM Sans', 'DM Sans Fallback', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --navh: 64px; --barh: 0px;
  --pop-shadow: 0 18px 48px -16px rgba(20, 35, 28, .28), 0 2px 6px rgba(20, 35, 28, .06);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

html:has(body.fd-body) { overflow-x: clip !important; overflow-y: visible !important; }
body.fd-body { background: #f4f3ee; overflow: visible !important; overflow-x: clip !important; }
/* the sitewide verdict bar competes with this page's own handoff; the mock leaves it out */
body.fd-body .verdict-bar { display: none !important; }
.fd { font-family: var(--ui); color: var(--ink); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
.fd *, .fd *::before, .fd *::after { box-sizing: border-box; }
.fd [hidden] { display: none !important; }
:where(.fd) button, :where(.fd) select, :where(.fd) input { font: inherit; color: inherit; }
:where(.fd) button { background: none; border: 0; padding: 0; margin: 0; cursor: pointer; text-align: inherit; box-shadow: none; min-height: 0; }
.fd svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.fd a { color: var(--forest); }
.fd :focus-visible { outline: 2px solid var(--forest); outline-offset: 2px; }
.fd-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.fd-wrap { max-width: 1248px; margin: 0 auto; padding: 0 32px; }
.fd .fd-h1, .fd .fd-h2, .fd .fd-h3, .fd .fd-group__t, .fd .fd-count, .fd .fd-pop__q, .fd .fd-empty__t { margin: 0; letter-spacing: 0; text-transform: none; }

/* ── hero ── */
.fd-hero { padding: 56px 0 28px; }
.fd .fd-h1 {
  font-family: var(--display); font-weight: 600; font-variation-settings: 'opsz' 144;
  font-size: 54px; line-height: 1.04; letter-spacing: -.022em; color: var(--forest);
  text-wrap: balance;
}
/* widths in px, not ch: 62ch is 811px in DM Sans but far less in the fallback font, so the paragraph re-wrapped when the web font arrived
   (a 29px jump of everything under the hero; the fonts stopped blocking first paint on 2026-10-11) */
.fd-lede { margin: 16px 0 0; font-size: 19px; line-height: 1.5; color: var(--ink-2); max-width: 811px; text-wrap: balance; }
.fd-crumbs { display: flex; align-items: center; gap: 6px; margin: 0 0 18px; font-size: 14px; color: var(--ink-3); }
.fd-crumbs a { color: var(--ink-3); text-decoration: none; }
.fd-crumbs a:hover { color: var(--forest); text-decoration: underline; }
.fd-crumbs svg { font-size: 14px; color: var(--ink-4); }
.fd-crumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* ── the search bar: the hero instrument ── */
.fd-barwrap { position: sticky; top: var(--navh); z-index: 40; padding: 0 0 8px; }
.fd-barwrap::before { content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: var(--field); opacity: 0; transition: opacity .2s; }
.fd-barwrap.is-stuck::before { opacity: 1; }
.fd-barwrap.is-stuck .fd-try { display: none; }
.fd-barwrap.is-stuck { padding-top: 10px; padding-bottom: 10px; }
.fd-sbar {
  position: relative; background: var(--paper); border: 1px solid var(--rule-2); border-radius: 20px;
  box-shadow: 0 1px 2px rgba(20, 35, 28, .05); overflow: hidden; transition: box-shadow .2s;
}
.fd-barwrap.is-stuck .fd-sbar { box-shadow: 0 12px 32px -18px rgba(20, 35, 28, .35), 0 1px 2px rgba(20, 35, 28, .05); }
.fd-search { display: flex; align-items: center; gap: 14px; height: 68px; padding: 0 22px; cursor: text; }
.fd-search > svg { font-size: 22px; color: var(--forest); }
.fd-search input {
  flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent;
  font-size: 19px; color: var(--ink); -webkit-appearance: none; appearance: none;
}
.fd .fd-search input:focus, .fd .fd-search input:focus-visible { outline: 0 !important; box-shadow: none !important; }
.fd-search input::placeholder { color: var(--ink-4); }
.fd-search input::-webkit-search-cancel-button { display: none; }
.fd-search:focus-within { box-shadow: inset 0 0 0 2px var(--forest); border-radius: 20px 20px 0 0; }
.fd-kbd {
  display: inline-grid; place-items: center; min-width: 26px; height: 26px; padding: 0 6px; border: 1px solid var(--rule-2);
  border-radius: 6px; font: 500 13px var(--ui); color: var(--ink-3); background: var(--field);
}
.fd-search:focus-within .fd-kbd, .fd-search.has-q .fd-kbd { display: none; }
.fd-search__clear { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; color: var(--ink-3); font-size: 18px; }
.fd-search__clear:hover { background: var(--field); color: var(--ink); }

.fd-segs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--rule); }
.fd-seg:last-child { border-right: 0; }
.fd-seg {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; column-gap: 8px;
  align-content: center; min-height: 66px; padding: 10px 18px 10px 22px; border-right: 1px solid var(--rule);
  transition: background-color .15s;
}
.fd-seg:hover { background: #f9f9f5; }
.fd-seg[aria-expanded="true"] { background: var(--forest-wash); }
.fd-seg:focus-visible { outline: 0; box-shadow: inset 0 0 0 2px var(--forest); }
.fd-seg__k { grid-column: 1; font-size: 13px; font-weight: 500; color: var(--ink-3); line-height: 1.3; display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; }
.fd-seg__v { grid-column: 1; font-size: 15.5px; font-weight: 600; color: var(--ink); line-height: 1.35; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fd-seg__chev { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-size: 18px; color: var(--ink-4); transition: transform .2s var(--ease); }
.fd-seg[aria-expanded="true"] .fd-seg__chev { transform: rotate(180deg); }
.fd-seg.is-set .fd-seg__v { color: var(--forest); }
.fd-seg.is-set .fd-seg__k::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--forest); }
.fd-seg.is-locked .fd-seg__chev { opacity: .5; }

.fd-open { display: inline-flex; align-items: center; gap: 10px; height: 40px; padding: 0 14px 0 8px; border-radius: 999px; border: 1px solid var(--rule-2); background: var(--paper); cursor: pointer; user-select: none; transition: background-color .15s, border-color .15s; }
.fd-open:hover { border-color: var(--ink-4); }
.fd-open:has(input:checked) { background: var(--forest-tint); border-color: #b9cdbf; }
.fd-open input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fd-switch { position: relative; width: 36px; height: 22px; border-radius: 11px; background: var(--rule-2); transition: background-color .2s; flex: none; }
.fd-switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(20, 35, 28, .3); transition: transform .2s var(--ease); }
.fd-open input:checked + .fd-switch { background: var(--forest); }
.fd-open input:checked + .fd-switch::after { transform: translateX(14px); }
.fd-open:has(input:focus-visible) { outline: 2px solid var(--forest); outline-offset: 2px; }
.fd-open__l { font-size: 15px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.fd-open__l b { font-weight: 650; color: var(--ink); }

/* stuck: one compact row */
@media (min-width: 1024px) {
  .fd-barwrap.is-stuck .fd-sbar { display: grid; grid-template-columns: minmax(220px, 1fr) auto; }
  .fd-barwrap.is-stuck .fd-search { height: 58px; }
  .fd-barwrap.is-stuck .fd-search input { font-size: 17px; }
  .fd-barwrap.is-stuck .fd-search:focus-within { border-radius: 20px 0 0 20px; }
  .fd-barwrap.is-stuck .fd-segs { border-top: 0; border-left: 1px solid var(--rule); grid-template-columns: repeat(4, minmax(132px, max-content)); }
  .fd-barwrap.is-stuck .fd-seg__v { max-width: 200px; }
  .fd-barwrap.is-stuck .fd-try { display: none; }
  .fd-barwrap.is-stuck .fd-seg { padding: 0 12px 0 18px; grid-template-rows: auto; }
  .fd-barwrap.is-stuck .fd-seg__k { display: none; }
  .fd-barwrap.is-stuck .fd-seg__chev { grid-row: 1; }
  .fd-barwrap.is-stuck .fd-seg__v { font-size: 15px; display: flex; align-items: center; gap: 7px; }
  .fd-barwrap.is-stuck .fd-seg.is-set .fd-seg__v::before { content: ''; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--forest); }
  .fd-barwrap.is-stuck .fd-kbd { display: none; }
}

/* ── layout ── */
.fd-layout { display: grid; grid-template-columns: minmax(0, 1fr) 404px; gap: 32px; align-items: start; padding-top: 28px; padding-bottom: 72px; }
.fd-results { min-width: 0; }

/* results header */
.fd-rhead { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 18px; min-height: 44px; }
.fd .fd-count { display: flex; align-items: baseline; gap: 8px; font: 600 17px var(--ui); color: var(--ink); }
.fd-count__n { font-family: var(--display); font-weight: 600; font-size: 34px; line-height: 1; letter-spacing: -.02em; color: var(--forest); font-variant-numeric: tabular-nums lining-nums; font-variation-settings: 'opsz' 72; }
.fd-delta { font-size: 13px; font-weight: 600; color: var(--ink-3); padding: 3px 9px; border-radius: 999px; background: var(--field-2); opacity: 0; transform: translateY(2px); transition: opacity .25s, transform .25s var(--ease); font-variant-numeric: tabular-nums; }
.fd-delta.is-on { opacity: 1; transform: none; }
.fd-sort { margin-left: auto; position: relative; display: inline-flex; align-items: center; gap: 0; height: 44px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--rule-2); background: var(--paper); color: var(--ink-2); }
.fd-sort > svg:first-of-type { font-size: 17px; color: var(--ink-3); margin-right: 8px; }
.fd-sort > svg:last-child { font-size: 16px; color: var(--ink-3); pointer-events: none; margin-left: -22px; }
.fd-sort select { appearance: none; -webkit-appearance: none; border: 0; background: transparent; height: 100%; padding: 0 28px 0 0; font-size: 15px; font-weight: 600; color: var(--ink); cursor: pointer; outline: 0; }
.fd-sort:focus-within { box-shadow: 0 0 0 2px var(--forest); border-color: transparent; }
.fd-sort:hover { border-color: var(--ink-4); }

/* ── the list ── */
.fd-list { list-style: none; margin: 0; padding: 0; }
.fd-group { display: flex; align-items: baseline; gap: 10px; padding: 30px 4px 12px; }
.fd-group.is-lead { padding-top: 2px; }
.fd .fd-group__t { font-family: var(--display); font-weight: 600; font-size: 22px; line-height: 1.2; letter-spacing: -.01em; color: var(--ink); font-variation-settings: 'opsz' 48; }
.fd-group__n { font-size: 14px; font-weight: 600; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.fd-group__note { margin-left: auto; font-size: 14px; color: var(--ink-3); text-align: right; }

.fd-row { position: relative; background: var(--paper); border: 1px solid var(--rule); border-top-width: 0; }
.fd-row.is-first { border-top-width: 1px; border-top-left-radius: 14px; border-top-right-radius: 14px; }
.fd-row.is-last { border-bottom-left-radius: 14px; border-bottom-right-radius: 14px; }
.fd-row.is-first .fd-row__hit { border-top-left-radius: 13px; border-top-right-radius: 13px; }
.fd-row.is-last .fd-row__hit { border-bottom-left-radius: 13px; border-bottom-right-radius: 13px; }
.fd-row__hit {
  display: grid; grid-template-columns: 44px minmax(0, 1fr) minmax(112px, auto) 16px; column-gap: 16px; align-items: start;
  padding: 18px 16px 18px 20px; color: inherit; text-decoration: none; transition: background-color .12s;
}
.fd a.fd-row__hit { color: inherit; text-decoration: none; }
.fd-row__hit:hover { background: #fafaf6; }
.fd-row__hit:focus-visible { outline: 0; box-shadow: inset 0 0 0 2px var(--forest); }
.fd-row.is-sel .fd-row__hit { background: var(--forest-wash); box-shadow: inset 3px 0 0 var(--forest); }
.fd-row.is-sel .fd-row__hit:focus-visible { box-shadow: inset 3px 0 0 var(--forest), inset 0 0 0 2px var(--forest); }

/* funder monogram */
.fd-mono {
  display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 11px; margin-top: 1px;
  font: 700 12.5px/1 var(--ui); letter-spacing: .03em; white-space: nowrap; overflow: hidden;
}
.fd-mono--federal { background: var(--forest); color: #fff; }
.fd-mono--provincial, .fd-mono--territorial { background: #fff; color: var(--forest); box-shadow: inset 0 0 0 1px var(--forest); }
.fd-mono--municipal { background: var(--field-2); color: #4b4a40; }
.fd-mono--private { background: #e8eef1; color: #2e4655; }

.fd-row__main { min-width: 0; display: flex; flex-direction: column; }
.fd-row__title { font-size: 16.5px; line-height: 1.35; font-weight: 600; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-wrap: pretty; }
.fd-row__hit:hover .fd-row__title { color: var(--forest); }
.fd-row__sum { margin-top: 4px; font-size: 14.5px; line-height: 1.5; color: var(--ink-3); display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.fd-row__meta { display: flex; align-items: center; gap: 14px; margin-top: 10px; font-size: 13px; color: var(--ink-3); min-width: 0; }
.fd-type { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px 0 8px; border-radius: 6px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.fd-type::before { content: ''; width: 7px; height: 7px; border-radius: 2px; background: currentColor; opacity: .85; }
.fd-type--grant { background: var(--ty-grant-bg); color: var(--ty-grant-ink); }
.fd-type--tax-credit { background: var(--ty-tax-bg); color: var(--ty-tax-ink); }
.fd-type--loan { background: var(--ty-loan-bg); color: var(--ty-loan-ink); }
.fd-type--forgivable-loan { background: var(--ty-fl-bg); color: var(--ty-fl-ink); }
.fd-type--award { background: var(--ty-award-bg); color: var(--ty-award-ink); }
.fd-type--program { background: var(--ty-prog-bg); color: var(--ty-prog-ink); }
.fd-where { flex: none; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; color: var(--ink-2); }
.fd-where svg { font-size: 14px; color: var(--ink-4); }
.fd-org { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-3); }

.fd-row__side { display: flex; flex-direction: column; align-items: flex-end; gap: 7px; text-align: right; padding-top: 1px; }
.fd-amt { font-size: 15.5px; line-height: 1.35; font-weight: 650; color: var(--ink); font-variant-numeric: tabular-nums; max-width: 184px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fd-st { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; line-height: 1.3; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.fd-st__dot { width: 7px; height: 7px; border-radius: 50%; background: #2f8a5a; }
.fd-st--between { color: var(--ink-3); }
.fd-st--between .fd-st__dot { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ink-4); }
.fd-st--soon .fd-st__dot { background: transparent; box-shadow: inset 0 0 0 1.5px #2f8a5a; }
.fd-st__n { padding: 2px 7px; border-radius: 6px; background: var(--field-2); color: var(--ink-2); font-size: 12.5px; font-weight: 600; }
.fd-st__n.is-hot { background: #f8e1d6; color: #8a2f12; font-weight: 700; }
.fd-st__n.is-warn { background: #faf0d8; color: #6f4d06; }
.fd-row__go { align-self: center; font-size: 16px; color: var(--ink-4); opacity: 0; transform: translateX(-3px); transition: opacity .15s, transform .15s var(--ease); }
.fd-row__hit:hover .fd-row__go, .fd-row.is-sel .fd-row__go { opacity: 1; transform: none; }
.fd-row.is-sel .fd-row__go { color: var(--forest); }

/* empty state */
.fd-empty { background: var(--paper); border: 1px dashed var(--rule-2); border-radius: 20px; padding: 40px 36px; }
.fd .fd-empty__t { font-family: var(--display); font-size: 26px; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.fd-empty__p { margin: 8px 0 18px; color: var(--ink-2); }
.fd-empty__opts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.fd-empty__opts button {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; min-height: 52px; padding: 10px 16px;
  border: 1px solid var(--rule); border-radius: 12px; background: var(--paper); font-size: 15.5px; font-weight: 500;
}
.fd-empty__opts button:hover { border-color: var(--forest); background: var(--forest-wash); }
.fd-empty__opts b { font-weight: 600; color: var(--forest); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ── detail pane ── */
.fd-detail { position: sticky; top: calc(var(--navh) + var(--barh) + 20px); display: flex; flex-direction: column; gap: 14px; max-height: calc(100vh - var(--navh) - var(--barh) - 36px); }
.fd-pane { flex: 0 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: hidden; background: var(--paper); border: 1px solid var(--rule); border-radius: 20px; outline: 0; }
.fd-pane__body { flex: 0 1 auto; min-height: 0; overflow: auto; padding: 26px 28px 22px; overscroll-behavior: contain; scrollbar-width: thin; }
.fd-pane__body.is-clipped { -webkit-mask-image: linear-gradient(#000 calc(100% - 36px), transparent); mask-image: linear-gradient(#000 calc(100% - 36px), transparent); }
.fd-pane__foot { flex: none; padding: 14px 28px 18px; border-top: 1px solid var(--rule); }
.fd-pane__foot .fd-btn { width: 100%; }
.fd-pane__hint { margin: 8px 0 0; text-align: center; font-size: 13px; color: var(--ink-3); }
.fd-d__head { display: flex; align-items: center; gap: 14px; }
.fd-d__head .fd-mono { width: 52px; height: 52px; border-radius: 13px; font-size: 14px; margin: 0; }
.fd-d__org { font-size: 14.5px; font-weight: 600; line-height: 1.35; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fd-d__lvl { font-size: 13.5px; color: var(--ink-3); margin-top: 2px; }
.fd .fd-d__t { margin: 18px 0 0; font-family: var(--display); font-weight: 600; font-size: 23px; line-height: 1.2; letter-spacing: -.012em; color: var(--ink); font-variation-settings: 'opsz' 48; text-wrap: balance; }
.fd-d__sum { margin: 10px 0 0; font-size: 16px; line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }
.fd-d__facts { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; margin: 22px 0 0; padding: 0; border-top: 1px solid var(--rule); }
.fd-d__fact { padding: 13px 0; border-bottom: 1px solid var(--rule); min-width: 0; }
.fd-d__fact--wide { grid-column: 1 / -1; }
.fd-d__fact dt { font-size: 13px; color: var(--ink-3); margin: 0 0 3px; }
.fd-d__fact dd { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.4; color: var(--ink); display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; font-variant-numeric: tabular-nums; }
.fd-d__fact dd .fd-type { font-size: 13px; }
.fd-d__fact dd .fd-st__n { font-weight: 600; }
.fd-d__scales { margin: 20px 0 0; display: grid; gap: 12px; }
.fd-scale { display: grid; grid-template-columns: 112px auto minmax(0, 1fr); align-items: center; gap: 14px; font-size: 14px; }
.fd-scale__l { color: var(--ink-2); }
.fd-scale__bar { display: flex; gap: 3px; }
.fd-scale__bar i { width: 20px; height: 6px; border-radius: 3px; background: var(--field-2); }
.fd-scale__bar i.on { background: var(--forest-2); }
.fd-scale__w { color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fd-d__flags { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 8px; font-size: 14.5px; color: var(--ink-2); }
.fd-d__flags li { display: flex; gap: 10px; align-items: flex-start; line-height: 1.45; }
.fd-d__flags svg { font-size: 17px; color: var(--forest-2); margin-top: 1px; }
.fd-d__cta { margin-top: 22px; }

.fd-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 12px;
  font: 600 16px var(--ui); text-decoration: none; transition: background-color .15s, transform .1s;
}
.fd a.fd-btn--primary, .fd .fd-btn--primary { background: var(--forest); color: #fff; }
.fd a.fd-btn--primary:hover, .fd .fd-btn--primary:hover { background: #10291e; }
.fd .fd-btn--primary:active { transform: translateY(1px); }
.fd a.fd-btn--ghost { background: var(--paper); color: var(--forest); box-shadow: inset 0 0 0 1.5px var(--forest); }
.fd-btn--block { width: 100%; }
.fd-btn--sm { min-height: 44px; padding: 0 18px; font-size: 15px; }
.fd-textbtn { margin-top: 14px; min-height: 44px; font-size: 15px; font-weight: 600; color: var(--forest); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* the handoff */
.fd-handoff { flex: none; border-radius: 20px; padding: 22px 26px 24px; border: 1px solid var(--rule); background: var(--paper); transition: background-color .3s, border-color .3s; }
.fd-handoff[data-state="idle"] .fd-handoff__ready, .fd-handoff[data-state="ready"] .fd-handoff__idle { display: none; }
.fd-handoff[data-state="ready"] { background: var(--forest-tint); border-color: #cfdcd3; }
.fd-handoff__lead { margin: 0; font-family: var(--display); font-weight: 600; font-size: 21px; line-height: 1.25; color: var(--forest); letter-spacing: -.01em; font-variant-numeric: tabular-nums lining-nums; }
.fd-handoff__idle .fd-handoff__lead { font-size: 18px; color: var(--ink); }
.fd-handoff__q { margin: 4px 0 0; font-size: 17px; font-weight: 600; color: var(--ink); }
.fd-handoff__p { margin: 6px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }
.fd-handoff .fd-btn { margin-top: 16px; width: 100%; }
.fd-handoff .fd-handoff__start { margin-top: 14px; min-height: 44px; width: auto; padding: 0 16px; font-size: 15px; border-radius: 10px; background: var(--paper); color: var(--forest); box-shadow: inset 0 0 0 1.5px var(--forest); }
.fd-handoff .fd-handoff__start:hover { background: var(--forest-wash); }

/* ── popover (desktop) / sheet (phone) ── */
.fd-pop {
  position: fixed; z-index: 60; width: 360px; max-height: min(560px, calc(100vh - 140px)); display: flex; flex-direction: column;
  background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; box-shadow: var(--pop-shadow); padding: 18px 12px 12px;
  transform-origin: top left;
}
.fd-pop.is-in { animation: fd-pop-in .18s var(--ease); }
@keyframes fd-pop-in { from { opacity: 0; transform: translateY(-6px) scale(.985); } }
.fd-pop.is-wide { width: 560px; }
.fd-pop__grab { display: none; }
.fd-pop__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 8px 12px 10px; }
.fd .fd-pop__q { text-wrap: balance; font-family: var(--display); font-weight: 600; font-size: 20px; line-height: 1.25; color: var(--ink); letter-spacing: -.01em; }
.fd-iconbtn { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: var(--ink-3); font-size: 20px; flex: none; }
.fd-iconbtn:hover { background: var(--field); color: var(--ink); }
.fd-pop__head .fd-iconbtn { margin: -8px -4px -8px 0; }
.fd-pop__opts { overflow: auto; display: grid; grid-template-columns: 1fr; gap: 2px; padding: 2px; overscroll-behavior: contain; }
.fd-pop.is-wide .fd-pop__opts { grid-template-columns: 1fr 1fr; column-gap: 6px; }
.fd-opt { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 46px; padding: 6px 12px 6px 10px; border-radius: 10px; font-size: 15.5px; color: var(--ink); }
.fd-opt:hover { background: var(--field); }
.fd-opt:focus-visible { outline: 0; box-shadow: inset 0 0 0 2px var(--forest); }
.fd-opt svg { font-size: 18px; color: var(--forest); stroke-width: 2.4; visibility: hidden; }
.fd-opt[aria-checked="true"] { background: var(--forest-wash); font-weight: 600; }
.fd-opt[aria-checked="true"] svg { visibility: visible; }
.fd-opt__l { min-width: 0; line-height: 1.3; }
.fd-opt__n { font-size: 14px; color: var(--ink-3); font-variant-numeric: tabular-nums; font-weight: 500; }
.fd-opt.is-zero { color: var(--ink-3); }
.fd-opt--any { grid-column: 1 / -1; margin-bottom: 6px; }
.fd-pop__sep { grid-column: 1 / -1; height: 1px; background: var(--rule); margin: 2px 8px 6px; }
.fd-pop__note { grid-column: 1 / -1; margin: 8px 10px 2px; font-size: 13.5px; color: var(--ink-3); line-height: 1.45; }
.fd-pop__foot { display: none; padding: 12px 4px 0; }
a.fd-opt { text-decoration: none; }

.fd-scrim { position: fixed; inset: 0; z-index: 55; background: rgba(20, 35, 28, .42); }
.fd-scrim.is-in { animation: fd-fade .2s ease-out; }
@keyframes fd-fade { from { opacity: 0; } }

.fd-sheet { position: fixed; z-index: 70; left: 0; right: 0; bottom: 0; max-height: 90vh; background: var(--paper); border-radius: 22px 22px 0 0; box-shadow: var(--pop-shadow); display: flex; flex-direction: column; }
.fd-sheet.is-in { animation: fd-up .28s var(--ease); }
@keyframes fd-up { from { transform: translateY(100%); } }
.fd-sheet__x { position: absolute; top: 10px; right: 10px; z-index: 2; background: var(--paper); }
.fd-sheet__body { overflow: auto; padding: 8px 22px 20px; overscroll-behavior: contain; min-height: 0; }
.fd-sheet__foot { flex: none; padding: 12px 22px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid var(--rule); }
.fd-sheet__foot .fd-btn { width: 100%; }
.fd-sheet .fd-pop__grab, .fd-pop.is-sheet .fd-pop__grab { display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--rule-2); margin: 10px auto 6px; flex: none; }

/* phone sticky bar */
.fd-mbar {
  position: fixed; z-index: 50; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom));
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 8px 8px 18px;
  background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; box-shadow: var(--pop-shadow);
}
.fd-mbar.is-in { animation: fd-up .3s var(--ease); }
.fd-mbar__t { font-size: 15px; color: var(--ink-2); line-height: 1.3; min-width: 0; }
.fd-mbar .fd-btn { white-space: nowrap; flex: none; }
.fd-mbar__t b { font-family: var(--display); font-weight: 600; font-size: 20px; color: var(--forest); font-variant-numeric: tabular-nums lining-nums; }

/* ── what's in this directory ── */
.fd-about { border-top: 1px solid var(--rule); background: var(--paper); padding: 64px 0 56px; }
.fd-about__grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 64px; }
.fd .fd-h2 { font-family: var(--display); font-weight: 600; font-size: 33px; line-height: 1.15; letter-spacing: -.015em; color: var(--ink); font-variation-settings: 'opsz' 72; }
.fd .fd-h3 { font: 600 15px/1.35 var(--ui); color: var(--ink); display: flex; align-items: baseline; gap: 8px; }
.fd-h3__n { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.fd-about__lede { margin: 14px 0 0; font-size: 17px; line-height: 1.65; color: var(--ink-2); max-width: 64ch; }
.fd-about__lede strong { color: var(--ink); font-weight: 600; }
.fd-about__bars { display: grid; gap: 28px; margin-top: 32px; }
.fd-bar { display: flex; gap: 2px; height: 12px; margin: 12px 0 12px; border-radius: 6px; overflow: hidden; }
.fd-bar__seg { min-width: 3px; }
.fd-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: 14px; color: var(--ink-2); }
.fd-legend li { display: inline-flex; align-items: center; gap: 7px; }
.fd-legend i { width: 9px; height: 9px; border-radius: 2px; }
.fd-legend__n { font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.fd-ty--grant { background: var(--ty-grant); } .fd-ty--tax-credit { background: var(--ty-tax); } .fd-ty--loan { background: var(--ty-loan); }
.fd-ty--forgivable-loan { background: var(--ty-fl); } .fd-ty--award { background: var(--ty-award); } .fd-ty--program { background: var(--ty-prog); }
.fd-lv--federal { background: var(--forest); } .fd-lv--provincial { background: #5f7fa8; } .fd-lv--territorial { background: #9fb4cf; }
.fd-lv--municipal { background: #b5b09c; } .fd-lv--private { background: #d9d6ca; }
.fd-close { list-style: none; margin: 14px 0 0; padding: 0; }
.fd-close li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: center; padding: 10px 0; border-top: 1px solid var(--rule); }
.fd-close li:last-child { border-bottom: 1px solid var(--rule); }
.fd-cal { display: grid; place-items: center; align-content: center; flex: none; width: 44px; height: 46px; border-radius: 10px; background: #faf0d8; color: #6f4d06; line-height: 1; }
.fd-cal.is-hot { background: #f8e1d6; color: #8a2f12; }
.fd-cal b { font: 600 18px var(--display); font-variant-numeric: lining-nums; }
.fd-cal span { font-size: 11.5px; font-weight: 600; margin-top: 3px; }
.fd-close__t { min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 15px; line-height: 1.35; }
.fd-close__t a { color: var(--ink); font-weight: 600; text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fd-close__t a:hover { color: var(--forest); text-decoration: underline; }
.fd-close__w { font-size: 13.5px; color: var(--ink-3); }
.fd-about__foot { margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--rule); display: grid; gap: 6px; font-size: 14.5px; color: var(--ink-3); }
.fd-about__foot p { margin: 0; max-width: 92ch; }
.fd-about__foot a { color: var(--forest); font-weight: 500; }

/* motion */
.fd-row.is-enter { animation: fd-enter .26s var(--ease) both; }
@keyframes fd-enter { from { opacity: 0; transform: translateY(6px); } }
.fd-pane.is-swap > * { animation: fd-swap .22s var(--ease) both; }
@keyframes fd-swap { from { opacity: 0; transform: translateY(4px); } }
@media (prefers-reduced-motion: reduce) {
  .fd *, .fd *::before, .fd *::after { animation: none !important; transition: none !important; }
}

/* ── tablet: no master-detail; details open as a sheet ── */
@media (max-width: 1023px) {
  .fd-layout { grid-template-columns: minmax(0, 1fr); }
  .fd-detail { display: none; }
  .fd-row__go { opacity: 1; transform: none; }
  .fd-row.is-sel .fd-row__hit { background: transparent; box-shadow: none; }
  .fd-row.is-sel .fd-row__hit:hover { background: #fafaf6; }
  .fd-about__grid { grid-template-columns: 1fr; gap: 40px; }
  .fd-segs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .fd-seg { padding-left: 18px; padding-right: 12px; }
  .fd-barwrap.is-stuck .fd-search { height: 54px; }
  .fd-barwrap.is-stuck .fd-seg__k { display: none; }
  .fd-barwrap.is-stuck .fd-seg { min-height: 50px; }
  .fd-barwrap.is-stuck .fd-seg__chev { grid-row: 1; }
}

/* ── phone ── */
@media (max-width: 719px) {
  .fd-wrap { padding: 0 16px; }
  .fd-hero { padding: 20px 0 14px; }
  .fd .fd-h1 { font-size: 33px; line-height: 1.06; letter-spacing: -.02em; }
  .fd-lede { display: none; }
  .fd-lede.fd-lede--short { display: block; font-size: 15.5px; margin-top: 8px; color: var(--ink-3); }
  .fd-crumbs { margin-bottom: 12px; }
  .fd-barwrap { position: relative; top: auto; padding: 0; }
  .fd-sbar { background: transparent; border: 0; box-shadow: none; overflow: visible; border-radius: 0; }
  .fd-search { height: 54px; padding: 0 8px 0 16px; background: var(--paper); border: 1px solid var(--rule-2); border-radius: 14px; }
  .fd-search:focus-within { border-radius: 14px; border-color: transparent; }
  .fd-search input { font-size: 16.5px; }
  .fd-search > svg { font-size: 20px; }
  .fd-kbd { display: none; }
  .fd-segs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; border: 0; margin: 10px 0 0; }
  .fd-seg { min-height: 54px; padding: 7px 10px 7px 14px; border: 1px solid var(--rule-2); border-radius: 12px; background: var(--paper); }
  .fd-seg:last-child { border-right: 1px solid var(--rule-2); }
  .fd-seg__k { font-size: 12px; }
  .fd-seg__v { font-size: 15px; font-weight: 600; }
  .fd-seg__chev { font-size: 16px; }
  .fd-seg.is-set { background: var(--forest-tint); border-color: #b9cdbf; }
  .fd-seg:not(.is-set) .fd-seg__v { color: var(--ink); }

  .fd-layout { padding-top: 14px; padding-bottom: 40px; }
  .fd-rhead { flex-wrap: nowrap; gap: 8px; margin-bottom: 4px; }
  .fd .fd-count { gap: 6px; font-size: 15px; white-space: nowrap; }
  .fd-open { height: 44px; padding: 0 10px 0 6px; gap: 7px; }
  .fd-open__l { font-size: 14px; }
  .fd-open__w { display: none; }

  .fd-count__n { font-size: 26px; }
  .fd-delta { display: none; }
  .fd-sort { margin-left: auto; flex: none; width: 44px; height: 44px; padding: 0; justify-content: center; border-color: var(--rule); }
  .fd-sort > svg:first-of-type { margin: 0; font-size: 18px; }
  .fd-sort > svg:last-child { display: none; }
  .fd-sort select { position: absolute; inset: 0; width: 100%; opacity: 0; padding: 0; }
  .fd-group { padding-top: 18px; }
  .fd-group.is-lead { padding-top: 6px; }
  .fd-group { flex-wrap: wrap; padding: 24px 2px 10px; gap: 2px 8px; }
  .fd .fd-group__t { font-size: 20px; }
  .fd-group__note { margin-left: 0; width: 100%; text-align: left; font-size: 13.5px; margin-top: 2px; }

  .fd-row__hit { grid-template-columns: 40px minmax(0, 1fr); column-gap: 14px; padding: 16px 14px 16px 14px; }
  .fd-mono { width: 40px; height: 40px; border-radius: 10px; font-size: 11.5px; }
  .fd-row__title { font-size: 16px; }
  .fd-row__sum { -webkit-line-clamp: 2; font-size: 14px; }
  .fd-row__meta { margin-top: 10px; gap: 6px 12px; flex-wrap: wrap; }
  .fd-org { display: none; }
  .fd-row__side { grid-column: 2; flex-direction: row; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 12px; margin-top: 12px; text-align: left; }
  .fd-amt { max-width: none; font-size: 15px; }
  .fd-row__side .fd-st { margin-left: auto; }
  .fd-row__go { display: none; }

  .fd-pop, .fd-pop.is-wide { left: 0 !important; right: 0; top: auto !important; bottom: 0; width: auto; max-height: 86vh; border-radius: 22px 22px 0 0; padding: 0 12px calc(12px + env(safe-area-inset-bottom)); border: 0; transform-origin: bottom; }
  .fd-pop.is-in { animation: fd-up .26s var(--ease); }
  .fd-pop.is-wide .fd-pop__opts { grid-template-columns: 1fr; }
  .fd-pop__note { display: none; }
  .fd-pop__head { padding: 4px 4px 10px 10px; }
  .fd-pop__foot { display: block; }
  .fd-pop .fd-pop__grab { display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--rule-2); margin: 10px auto 8px; }
  .fd-opt { min-height: 48px; }

  .fd-about { padding: 44px 0 40px; }
  .fd .fd-h2 { font-size: 27px; }
  .fd-about__lede { font-size: 16px; }
}
@media (min-width: 1024px) {
  .fd-mbar { display: none !important; }
}

@media (max-width: 1023px) { .fd-body.has-mbar .gcx-footer { padding-bottom: 96px; } }
.fd-d__sub { flex-basis: 100%; font-size: 13.5px; font-weight: 400; color: var(--ink-3); }
.fd-d__muted { font-weight: 400; color: var(--ink-3); }

/* search suggestions */
.fd-try { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px; }
.fd-try__l { font-size: 14px; color: var(--ink-3); margin-right: 2px; }
.fd .fd-try__b { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--rule-2); background: transparent; font-size: 14px; font-weight: 500; color: var(--ink-2); transition: background-color .15s, border-color .15s; }
.fd .fd-try__b:hover { background: var(--paper); border-color: var(--ink-4); color: var(--ink); }
.fd-try__b span { font-size: 12.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.fd-try__b span:empty { display: none; }
@media (max-width: 719px) { .fd-try { display: none; } }

.fd-lede--short { display: none; }
@media (max-width: 1023px) and (min-width: 720px) { .fd-open__w { display: none; } }

/* rail value card */
.fd-value { background: var(--paper); border: 1px solid var(--rule); border-radius: 20px; padding: 26px 26px 22px; overflow: auto; min-height: 0; }
.fd-value__intro { padding-bottom: 22px; margin-bottom: 20px; border-bottom: 1px solid var(--rule); }
.fd .fd-value__t { margin: 0; font-family: var(--display); font-weight: 600; font-size: 24px; line-height: 1.2; letter-spacing: -.012em; color: var(--forest); font-variation-settings: 'opsz' 48; }
.fd-value__p { margin: 8px 0 16px; font-size: 15px; line-height: 1.55; color: var(--ink-2); }
.fd-value__intro .fd-btn { width: 100%; }
.fd-vlist { list-style: none; margin: 12px 0 0; padding: 0; }
.fd-vlist li { border-top: 1px solid var(--rule); }
.fd-vlist li:last-child { border-bottom: 1px solid var(--rule); }
.fd .fd-vlist a { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px 6px; margin: 0 -6px; border-radius: 10px; color: inherit; text-decoration: none; }
.fd .fd-vlist a:hover { background: #fafaf6; }
.fd-vlist__t { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fd-vlist__n { font-size: 14.5px; font-weight: 600; line-height: 1.35; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fd .fd-vlist a:hover .fd-vlist__n { color: var(--forest); }
.fd-vlist__w { font-size: 13px; color: var(--ink-3); }
.fd-vlist__none { padding: 14px 0; font-size: 14.5px; color: var(--ink-3); }
.fd-value__hint { margin: 14px 0 0; font-size: 13.5px; color: var(--ink-3); }
.fd-pane__bar { flex: none; display: flex; align-items: center; justify-content: space-between; padding: 8px 10px 0 14px; }
.fd .fd-pane__back { display: inline-flex; align-items: center; gap: 4px; min-height: 40px; padding: 0 10px 0 4px; border-radius: 10px; font-size: 14px; font-weight: 600; color: var(--forest); }
.fd .fd-pane__back:hover { background: var(--forest-wash); }
.fd-pane__back svg { font-size: 18px; }
.fd .fd-pane__x { width: 40px; height: 40px; font-size: 18px; }
.fd-pane__bar + .fd-pane__body { padding-top: 10px; }

/* ── the field (from Haystack): one square per program ── */
.fd-field { background: var(--paper); border: 1px solid var(--rule); border-radius: 16px; padding: 16px 18px 12px; margin: 0 0 20px; }
.fd-field__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(6px, 1fr)); gap: 2px; }
.fd .sq { display: block; aspect-ratio: 1; min-width: 0; border-radius: 1.5px; background: #e4e2da; transition: background-color .32s ease-out; cursor: pointer; }
.fd .sq.on.t-grant, .fd-field__legend .sq.t-grant { background: var(--ty-grant); }
.fd .sq.on.t-tax-credit, .fd-field__legend .sq.t-tax-credit { background: var(--ty-tax); }
.fd .sq.on.t-loan, .fd-field__legend .sq.t-loan { background: var(--ty-loan); }
.fd .sq.on.t-forgivable-loan, .fd-field__legend .sq.t-forgivable-loan { background: var(--ty-fl); }
.fd .sq.on.t-award, .fd-field__legend .sq.t-award { background: var(--ty-award); }
.fd .sq.on.t-program, .fd-field__legend .sq.t-program { background: var(--ty-prog); }
.fd .sq.is-hot { position: relative; z-index: 1; box-shadow: 0 0 0 1.5px var(--paper), 0 0 0 3px var(--ink); }
.fd-field__legend { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: var(--ink-3); }
.fd-field__legend li { display: inline-flex; align-items: center; gap: 6px; }
.fd-field__legend .sq { width: 8px; height: 8px; aspect-ratio: auto; border-radius: 2px; cursor: default; }
.lg-s { display: none; }
.fd-field__legend b { font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.fd-field__foot { display: flex; align-items: center; justify-content: space-between; gap: 6px 18px; flex-wrap: wrap; margin-top: 8px; padding-top: 9px; border-top: 1px solid var(--rule); min-height: 34px; }
.fd-field__dock { margin: 0; font-size: 13.5px; color: var(--ink-3); min-width: 0; flex: 1 1 260px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fd-field__dock.is-name b { color: var(--ink); font-weight: 600; margin-right: 8px; }
.fd-field__off { margin: 0; font-size: 14px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.fd-field__off [data-offn] { font-weight: 650; color: var(--ink); }
.fd .fd-linkbtn { display: inline; min-height: 0; padding: 0; font-size: 14px; font-weight: 600; color: var(--forest); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.fd .fd-linkbtn:hover { text-decoration-thickness: 2px; }

/* switched-off rows, shown on request */
.fd-row.is-off .fd-row__hit { background: #fbfbf8; }
/* switched off: faded by colour, not opacity, so every line still meets AA contrast */
.fd-row.is-off .fd-mono { background: var(--field-2); color: #4b4a40; box-shadow: none; }
.fd-row.is-off .fd-row__title, .fd-row.is-off .fd-amt { color: var(--ink-3); font-weight: 500; }
.fd-row.is-off .fd-type { filter: grayscale(1); }
.fd-row__why { display: none; }
.fd-row.is-off .fd-row__why { display: inline-flex; align-self: flex-start; align-items: center; gap: 6px; margin-top: 10px; padding: 3px 9px; border-radius: 6px; background: #f3ede4; color: #6b4a2e; font-size: 13px; font-weight: 600; line-height: 1.4; }
.fd-group[data-g="off"] .fd-group__t { color: var(--ink-2); }
.fd-row.is-flash .fd-row__hit { animation: fd-flash 1.4s ease-out; }
@keyframes fd-flash { 0%, 30% { box-shadow: inset 0 0 0 2px var(--forest); background: var(--forest-tint); } 100% { box-shadow: inset 0 0 0 2px transparent; } }

@media (max-width: 719px) {
  .fd-field { padding: 0; margin: 4px 0 6px; border: 0; border-radius: 0; background: transparent; }
  .lg-f { display: none; } .lg-s { display: inline; }
  .fd-field__legend { flex-wrap: nowrap; overflow: hidden; white-space: nowrap; }
  .fd-group { padding-top: 14px; }
  .fd-field__grid { grid-template-columns: repeat(auto-fill, minmax(3px, 1fr)); gap: 1px; }
  .fd .sq { border-radius: .5px; cursor: default; }
  .fd-field__legend { margin-top: 7px; gap: 2px 9px; font-size: 11.5px; }
  .fd-field__legend b { display: none; }
  .fd-field__legend .sq { width: 6px; height: 6px; }
  .fd-field__legend li { gap: 4px; }
  .fd-field__foot { border-top: 0; padding-top: 0; min-height: 0; margin-top: 4px; }
  .fd-field__dock { display: none; }
  .fd-field__off { font-size: 13.5px; }
  .fd-field__off .fd-linkbtn { font-size: 13.5px; display: inline-block; min-height: 32px; line-height: 32px; }
  .fd-hero { padding-top: 16px; padding-bottom: 12px; }
  .fd-search { height: 50px; }
  .fd-segs { gap: 6px; margin-top: 8px; }
  .fd-seg { min-height: 50px; padding-top: 5px; padding-bottom: 5px; }
  .fd-layout { padding-top: 10px; }
}
@media (prefers-reduced-motion: reduce) { .fd .sq { transition: none; } }

.fd-field__foot.is-hover .fd-field__off { display: none; }
.fd-field__foot.is-hover .fd-field__dock { flex-basis: 100%; }
.fd-handoff[data-state="ready"] { order: -1; }

/* ── polish round: the field breathes ── */
.fd-field { padding: 28px 30px 22px; margin: 0 0 28px; border-radius: 20px; }
.fd-field__grid { grid-template-columns: repeat(auto-fill, minmax(9px, 1fr)); gap: 3px; }
.fd .sq { border-radius: 2px; }
.fd-field__legend { margin-top: 22px; gap: 10px 24px; font-size: 14px; }
.fd-field__legend .sq { width: 10px; height: 10px; border-radius: 2.5px; }
.fd-field__legend li { gap: 8px; }
.fd-field__foot { margin-top: 18px; padding-top: 16px; min-height: 0; }
.fd-field__dock { font-size: 14px; }
.fd-opt__l small { display: block; margin-top: 1px; font-size: 13px; font-weight: 400; color: var(--ink-3); line-height: 1.35; }
.fd-opt[aria-checked="true"] .fd-opt__l small { color: var(--ink-2); }
.fd-pop:not(.is-wide) .fd-opt { min-height: 52px; }
.fd .fd-opt--edit { grid-template-columns: 92px minmax(0, 1fr) auto; min-height: 56px; padding: 8px 12px; }
.fd-opt__k { font-size: 13px; color: var(--ink-3); }
.fd-opt--edit .fd-opt__l { font-weight: 600; }
.fd-opt--edit .fd-opt__n { color: var(--forest); font-weight: 600; font-size: 14px; }
.fd-opt--edit[disabled] .fd-opt__n { color: var(--ink-4); font-weight: 400; }
.fd-prog { display: flex; gap: 3px; margin: 12px 0 10px; }
.fd-prog i { flex: 1; height: 6px; border-radius: 3px; background: #d2dcd4; }
.fd-prog i.on { background: var(--forest); }
.fd-mbar__sub { display: block; font-size: 12.5px; color: var(--ink-3); margin-top: 1px; }
.fd-mbar__t b { font-family: var(--display); }
.fd-sum { display: none; }

@media (max-width: 719px) {
  .fd-field { padding: 16px 14px 14px; margin: 6px 0 14px; border: 1px solid var(--rule); border-radius: 16px; background: var(--paper); }
  .fd-field__grid { grid-template-columns: repeat(auto-fill, minmax(6px, 1fr)); gap: 2px; }
  .fd .sq { border-radius: 1.5px; }
  .fd-field__legend { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 10px; margin-top: 14px; font-size: 12.5px; white-space: normal; overflow: visible; }
  .fd-field__legend li { gap: 6px; min-width: 0; }
  .fd-field__legend b { display: inline; margin-left: auto; }
  .fd-field__legend .sq { width: 8px; height: 8px; flex: none; }
  .fd-field__foot { margin-top: 0; padding-top: 0; border-top: 0; }
  .fd-field__off:not([hidden]) { margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--rule); width: 100%; }
  .fd-try { display: flex; flex-wrap: nowrap; overflow-x: auto; gap: 8px; margin: 10px -16px 0; padding: 0 16px 2px; scrollbar-width: none; }
  .fd-try::-webkit-scrollbar { display: none; }
  .fd .fd-try__b { flex: none; min-height: 36px; background: var(--paper); }
  .fd-sum { position: fixed; z-index: 45; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 48px; padding: 0 16px; background: var(--paper); border: 0; border-bottom: 1px solid var(--rule); box-shadow: 0 8px 20px -14px rgba(20, 35, 28, .35); font: inherit; text-align: left; cursor: pointer; }
  .fd-sum[hidden] { display: none; }
  .fd-sum.is-in { animation: fd-down .22s var(--ease); }
  .fd-sum__t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14.5px; font-weight: 600; color: var(--ink); display: flex; align-items: center; gap: 8px; }
  .fd-sum__t::before { content: ''; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--forest); }
  .fd-sum__e { flex: none; font-size: 14px; font-weight: 600; color: var(--forest); text-decoration: underline; text-underline-offset: 3px; }
}
@keyframes fd-down { from { transform: translateY(-100%); opacity: 0; } }

@media (max-width: 719px) {
  .fd-off-long { display: none; }
  .fd-seg { min-height: 48px; padding-top: 4px; padding-bottom: 4px; }
  .fd .fd-try__b { min-height: 34px; }
  .fd-try { margin-top: 8px; }
  .fd-field { padding-top: 14px; }
  .fd-field__legend { margin-top: 12px; gap: 6px 10px; }
  .fd-rhead { margin-bottom: 2px; }
}

.fd-pop:not(.is-wide) { width: 400px; }
.fd-field__legend { gap: 10px 20px; font-size: 13.5px; }
@media (max-width: 719px) { .fd-pop:not(.is-wide) { width: auto; } }
@media (min-width: 720px) {
  .fd-field__legend { display: grid; grid-template-columns: repeat(3, max-content); gap: 10px 40px; }
}
.fd-handoff[data-state="idle"] { display: none; }

/* ── production additions (2026-10-04) ── */
/* icons drawn by CSS, not repeated as inline SVG in ~880 rows */
.fd-where::before { content: ''; flex: none; width: 14px; height: 14px; background: var(--ink-4);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 21s-6.5-5.6-6.5-11a6.5 6.5 0 0 1 13 0c0 5.4-6.5 11-6.5 11Z'/%3E%3Ccircle cx='12' cy='10' r='2.3'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 21s-6.5-5.6-6.5-11a6.5 6.5 0 0 1 13 0c0 5.4-6.5 11-6.5 11Z'/%3E%3Ccircle cx='12' cy='10' r='2.3'/%3E%3C/svg%3E") center / contain no-repeat; }
.fd-row__go { width: 16px; height: 16px; position: relative; }
.fd-row__go::before { content: ''; position: absolute; left: 3px; top: 4px; width: 7px; height: 7px; border-right: 1.9px solid currentColor; border-top: 1.9px solid currentColor; transform: rotate(45deg); border-radius: 1px; }

/* who can apply: positive public evidence only (builder) */
.fd-row__who { margin-top: 6px; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fd-row__whok { color: var(--ink-3); }
.fd-row.is-off .fd-row__who, .fd-row.is-off .fd-row__who .fd-row__whok { color: var(--ink-3); }

/* route to the curated guide (desktop hero line; the about foot carries it on every width) */
.fd-guide { margin: 12px 0 0; font-size: 15px; color: var(--ink-3); }
.fd-guide a { color: var(--forest); font-weight: 600; }
@media (max-width: 719px) { .fd-guide { display: none; } }

/* letter groups (A to Z sort) are plain headings */
.fd-group[data-gs="3"] .fd-group__t { font-size: 20px; }

/* other directories */
.fd-dirs { margin-top: 18px; display: grid; gap: 10px; }
.fd-dirs .fd-h3 { margin: 0 0 2px; }
.fd-dirs__row { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.fd-dirs a, .fd-dirs [aria-current] { font-size: 14.5px; min-height: 24px; display: inline-flex; align-items: center; }
.fd-dirs [aria-current] { color: var(--ink); font-weight: 600; }
.fd-close__none { margin: 14px 0 0; font-size: 14.5px; color: var(--ink-3); }

/* phone: after narrowing, the switched-off squares fold into a compact heap so the list comes up sooner */
.fd-heap { display: none; }
@media (max-width: 719px) {
  .fd-field.is-narrow .fd-field__grid .sq:not(.on) { display: none; }
  .fd-field.is-narrow .fd-heap:not([hidden]) { display: block; margin: 10px 0 0; padding: 8px 0 0; border-top: 1px dashed var(--rule-2); }
  .fd-heap__t { display: flex; flex-wrap: wrap; gap: 1px; }
  .fd-heap__t i { width: 2px; height: 2px; background: #d6d3c8; }
  .fd-field.is-narrow { padding-top: 12px; padding-bottom: 8px; }
  .fd-field.is-narrow .fd-heap:not([hidden]) { margin-top: 8px; padding-top: 6px; }
  .fd-field.is-narrow .fd-field__legend { margin-top: 8px; row-gap: 4px; }
  .fd-field.is-narrow .fd-field__off:not([hidden]) { margin-top: 8px; padding-top: 6px; }
}

/* the sitewide verdict bar never renders here (body[data-no-verdict-bar]); belt and braces */
body.fd-body .verdict-bar { display: none !important; }

.fd-opt[aria-current="page"] { background: var(--forest-wash); font-weight: 600; }
.fd-opt[aria-current="page"] svg { visibility: visible; }
.fd-mbar__t [data-mk] { font-weight: 650; color: var(--ink); }

/* the per-group cap: "Show all N …" after the 12th row of a group (rows past it stay in the HTML) */
.fd-more { list-style: none; padding: 10px 0 0; }
.fd .fd-more__b { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 48px; padding: 8px 16px; border: 1px solid var(--rule-2); border-radius: 12px; background: var(--paper); font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--forest); text-align: center; transition: background-color .15s, border-color .15s; }
.fd .fd-more__b:hover { border-color: var(--forest); background: var(--forest-wash); }
.fd .fd-more__b svg { font-size: 17px; }
.fd-field__legend li[hidden] { display: none; }

/* switched-off rows: the reason is the strongest thing on the row (7A2E12 on FFF1E8, about 9:1) */
.fd-row.is-off .fd-row__why { background: #fff1e8; color: #7a2e12; font-weight: 600; font-size: 14px; box-shadow: inset 0 0 0 1px #f3d2bf; }

/* Switched-off rows are a diagnosis, not a second catalogue (2026-10-05 QA): one line each, the
   title plus the reason. No summary, no amount, no green "open" dot on a program that is not for you. */
.fd-row.is-off .fd-row__sum, .fd-row.is-off .fd-row__who, .fd-row.is-off .fd-row__meta,
.fd-row.is-off .fd-amt, .fd-row.is-off .fd-st { display: none; }
.fd-row.is-off .fd-row__hit { padding-top: 10px; padding-bottom: 10px; }
.fd-row.is-off .fd-row__why { margin-top: 6px; }
/* an amount with no figure ("Not published", "Varies by CFDC") is a note, not a number */
.fd-amt.fd-amt--text { font-weight: 400; color: var(--ink-3); }

/* ── province pages (2026-10-10): the place's own programs lead every number ── */
/* the count takes its own line: "173 Ontario programs  + 302 Canada-wide" (the second part jumps to the
   national block); the Open switch and the sort sit on the line under it */
.fd .fd-count.fd-count--place { flex: 1 0 100%; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.fd-count__main { display: inline-flex; align-items: baseline; gap: 8px; }
.fd .fd-count__plus { display: inline-flex; align-items: baseline; gap: 5px; min-height: 32px; padding: 3px 12px; border-radius: 999px; background: var(--field-2); font: 500 14.5px var(--ui); color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; transition: background-color .15s, color .15s; }
.fd .fd-count__plus b { font-weight: 650; color: var(--ink); }
.fd .fd-count__plus:hover { background: var(--forest-tint); color: var(--forest); }
.fd-rhead:has(.fd-count--place) { row-gap: 10px; }
/* the field: two clusters, each under its own label (position = place, colour = type). The counts are in the
   line above on a wide screen; a phone has no room for that line's second half, so the label carries it. */
.fd-field__split { display: grid; gap: 16px; }
.fd-field__cap { margin: 0 0 8px; font-size: 13.5px; font-weight: 500; color: var(--ink-2); line-height: 1.3; }
.fd-field__cap b { display: none; font-weight: 650; color: var(--ink); font-variant-numeric: tabular-nums; margin-right: 2px; }
/* the plain link a province page carries without JS (the script swaps it for the cap's own button) */
.fd .fd-more--rest a.fd-more__b { text-decoration: none; }
.fd-more.is-busy .fd-more__b { opacity: .6; pointer-events: none; }
@media (max-width: 719px) {
  .fd .fd-count.fd-count--place { flex: 1 1 0; min-width: 0; white-space: normal; flex-wrap: wrap; }
  .fd-count--place .fd-count__main { flex-wrap: wrap; column-gap: 6px; }
  .fd .fd-count__plus { display: none; }
  .fd-rhead:has(.fd-count--place) { flex-wrap: nowrap; }
  .fd-field__split { gap: 10px; }
  .fd-field__cap { font-size: 12.5px; margin-bottom: 5px; }
  .fd-field__part[data-part="nat"] .fd-field__cap b { display: inline; }
  /* the search suggestions are national names (IRAP, BDC): on a phone they sat between the visitor and the place's own list */
  .fd[data-place] .fd-try { display: none; }
}

/* review 2026-10-10: under "16 Nunavut programs" a legend reading "Grant 171" (every program, national included) looked like a
   contradiction, so a province page's legend is a colour key only; and the Canada-wide squares are drawn smaller than the
   place's own, so the place is the larger thing on the card */
.fd[data-place] .fd-field__legend b { display: none; }
.fd[data-place] .fd-field__part[data-part="nat"] .fd-field__grid { grid-template-columns: repeat(auto-fill, minmax(6px, 1fr)); gap: 2px; }
.fd[data-place] .fd-field__part[data-part="nat"] .sq { border-radius: 1.5px; }
@media (max-width: 719px) {
  .fd[data-place] .fd-field__legend { display: flex; flex-wrap: wrap; gap: 4px 14px; }
  .fd[data-place] .fd-field__part[data-part="nat"] .fd-field__grid { grid-template-columns: repeat(auto-fill, minmax(4px, 1fr)); gap: 1.5px; }
  .fd[data-place] .fd-field__part[data-part="nat"] .sq { border-radius: 1px; }
}

/* ══════════════════════════════════════════════════════════════════════════════════════════════════════════════
   The place band (province pages): the drawn map with coin stacks, the card beside it, the place chips.
   Built by dev-tools/build-grants-directory.js (placeBandHtml), driven by js/directory.js ("the place band"),
   drawn by js/gc-map.js + css/gc-map.css (fetched on demand). Design + reviews: dev-assets/map-redesign-2026-10-10/.
   ══════════════════════════════════════════════════════════════════════════════════════════════════════════════ */
.pv { padding: 8px 0 26px; }
.pv__in { display: grid; grid-template-columns: minmax(0, 1.62fr) minmax(0, 1fr); gap: 8px 36px; align-items: center; }
.pv__map { position: relative; min-width: 0; margin: 0 -14px; }
.pv__cap { margin: 4px 14px 0; display: flex; align-items: center; justify-content: space-between; gap: 6px 16px; flex-wrap: wrap; font-size: 13px; line-height: 1.45; color: var(--ink-3, #5c6862); }
/* the 3D view is an extra, so its switch is a quiet text control, never a rival to picking a place */
.pv__side { min-width: 0; background: var(--paper); border: 1px solid var(--rule); border-radius: 20px; padding: 24px 26px 22px; }
.pv__top { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.fd .pv__h { margin: 0; font-family: var(--display); font-weight: 600; font-size: 27px; line-height: 1.15; letter-spacing: -.012em; color: var(--forest); font-variation-settings: 'opsz' 60; }
.pv__p { margin: 8px 0 0; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.pv__p b { color: var(--ink); font-weight: 650; }
.fd .pv__bd { display: none; }
.pv__lead { display: none; margin: 6px 0 0; font-size: 14.5px; line-height: 1.45; color: var(--ink-2); }
.pv[data-picked] .pv__lead { display: none; }
/* the stack: what adds up where you are, most local on top */
.pv__stack { margin: 18px 0 0; padding: 0; list-style: none; }
.pv__row { display: grid; grid-template-columns: 54px minmax(0, 1fr); align-items: baseline; gap: 0 12px; padding: 9px 0; border-top: 1px solid var(--rule); }
.pv__row:first-child { border-top: 0; }
.pv__row b { font-family: var(--display); font-weight: 600; font-size: 22px; line-height: 1; text-align: right; color: var(--ink); font-variant-numeric: lining-nums tabular-nums; }
.pv__row span { font-size: 15px; color: var(--ink-2); }
.pv__row--spot b, .pv__row--spot span { color: var(--signal-ink, #8f3d1c); }
.pv__row--spot span { font-weight: 600; }
.pv__row--hint span { color: var(--ink); font-weight: 600; }
.pv__row.is-new { animation: pv-in .38s cubic-bezier(.2, .7, .2, 1); }
@keyframes pv-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.pv__sum { display: grid; grid-template-columns: 54px minmax(0, 1fr); align-items: baseline; gap: 0 12px; margin-top: 2px; padding: 12px 0 0; border-top: 2px solid var(--ink); }
.pv__sum b { font-family: var(--display); font-weight: 600; font-size: 30px; line-height: 1; text-align: right; color: var(--forest); font-variant-numeric: lining-nums tabular-nums; letter-spacing: -.01em; }
.pv__sum span { font-size: 15.5px; font-weight: 600; color: var(--ink); }
.pv__act { display: flex; align-items: center; gap: 8px 18px; flex-wrap: wrap; margin-top: 18px; }
.pv__act .fd-btn { flex: 1 1 auto; }
.fd .pv__clear { flex: none; font: 600 14.5px/1 var(--ui); color: var(--forest); text-decoration: underline; text-underline-offset: 3px; min-height: 40px; padding: 0 2px; }
body.pv-on-screen #fd-mbar { display: none !important; }
/* every place as a plain control: the keyboard and no-script path, and the phone's main control */
.pv__chips { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.fd .pv__chip { display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 0 14px; border: 1px solid var(--rule-2); border-radius: 999px; background: var(--paper); font: 500 14.5px/1 var(--ui); color: var(--ink); cursor: pointer; transition: border-color .15s, background-color .15s, color .15s; white-space: nowrap; }
.fd .pv__chip b { font-family: var(--display); font-weight: 600; font-size: 15px; color: var(--forest); font-variant-numeric: lining-nums; }
.fd .pv__chip:hover { border-color: var(--ink-4); }
/* the accent means one thing: the visitor's own place. "Anywhere" at rest is a quiet selected state */
.fd .pv__chip[aria-pressed="true"] { background: var(--signal, #b4532a); border-color: var(--signal, #b4532a); color: #fff; }
.fd .pv__chip[aria-pressed="true"] b { color: #fff; }
.fd .pv__chip[data-id=""][aria-pressed="true"] { background: var(--forest-tint, #e9f0eb); border-color: var(--forest, #1a3d2e); color: var(--forest, #1a3d2e); }
.pv:not(.is-allchips) .pv__chip-x { display: none; }
.fd .pv__morechips { color: var(--ink-2); } .fd .pv__morechips b { color: var(--ink-3); }
/* mock plumbing: rows the picked place cannot use */
@media (max-width: 1023px) {
  .pv__in { grid-template-columns: 1fr; gap: 14px; }
  .pv__map { margin: 0 -8px; }
  .pv__side { order: 1; }
  .pv__chips { order: 2; margin-top: 0; }
  .pv__map { order: 3; }
}
@media (max-width: 719px) {
  .pv { padding: 2px 0 14px; }
  .pv__side { padding: 18px 18px 16px; border-radius: 16px; }
  .fd .pv__h { font-size: 23px; }
  .pv__p { font-size: 14.5px; }
  .pv__chips { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 4px; scrollbar-width: none; }
  .pv__chips::-webkit-scrollbar { display: none; }
  .fd .pv__chip { flex: none; min-height: 44px; }
  .pv:not(.is-allchips) .pv__chip-x { display: block; } .pv__chips li:has(.pv__morechips) { display: none; }
  /* a phone shows the total until a place is picked; the breakdown opens with the pick */
  .pv:not([data-picked]) .pv__stack { display: none; }
  .pv:not([data-picked]) .pv__sum { border-top: 0; padding-top: 0; margin-top: 12px; }
  .pv:not([data-picked]) .pv__p { display: none; }
  /* after a pick the card stays short on a phone (the tapped chip and the map must not jump away): total first, rows on request */
  .pv[data-picked]:not(.is-bd) .pv__stack { display: none; }
  .pv[data-picked]:not(.is-bd) .pv__sum { border-top: 0; padding-top: 0; margin-top: 12px; }
  .fd .pv__bd:not([hidden]) { display: inline-block; margin-top: 8px; font: 600 14px/1 var(--ui); color: var(--forest); text-decoration: underline; text-underline-offset: 3px; min-height: 44px; }
  .pv[data-picked] .pv__sum { order: -1; }
  .pv__lead { display: block; }
  .pv__cap { margin: 0 8px; font-size: 12.5px; }
  .gm .gm-l { font-size: 12.5px; padding: 3px 8px; }
}

/* ── homepage: this week, on the map ── */
/* the directory's type and date rows sit under the map, in the same section (no second card) */
@media (max-width: 768px) {
}

/* the caption's key: a small coin beside "One coin is one program" */
.pv .pv__key, .tm .pv__key { white-space: nowrap; }
.fd .pv .pv__coin, .pv .pv__coin, .tm .pv__coin { display: inline-block; width: 20px; height: 15px; margin: 0 5px 0 2px; vertical-align: -3px; fill: initial; stroke: none; }

/* homepage: programs that belong to no single province, beside the map */

/* a place with almost nothing local: a short strip with a small map, not the full band */
.pv--compact .pv__in { grid-template-columns: 250px minmax(0, 1fr); gap: 2px 30px; align-items: center; }
.pv--compact .pv__map { margin: 0; grid-row: 1 / span 2; }
.pv--compact .pv__cap { margin: 2px 6px 0; font-size: 12px; }
@media (min-width: 720px) { .pv--compact .pv__side { background: none; border: 0; border-radius: 0; padding: 0; align-self: end; } }
.fd .pv--compact .pv__h { font-size: 23px; }
.pv--compact .pv__p { margin-top: 5px; }
.pv--compact:not(.is-bd) .pv__stack { display: none; }
.pv--compact .pv__sum { grid-template-columns: auto minmax(0, 1fr); border-top: 0; padding-top: 0; margin-top: 10px; }
.pv--compact.is-bd .pv__sum { border-top: 2px solid var(--ink); padding-top: 12px; }
.pv--compact .pv__sum b { font-size: 26px; text-align: left; }
.fd .pv--compact .pv__bd:not([hidden]) { display: inline-block; margin-top: 8px; font: 600 14px/1 var(--ui); color: var(--forest); text-decoration: underline; text-underline-offset: 3px; min-height: 40px; }
.pv--compact .pv__chips { grid-column: 2; align-self: start; margin-top: 10px; }
.pv--compact .pv__act { margin-top: 12px; } .pv--compact .pv__act .fd-btn { flex: 0 1 auto; }
@media (max-width: 1023px) { .pv--compact .pv__in { grid-template-columns: 200px minmax(0, 1fr); gap: 2px 20px; } .pv--compact .pv__side, .pv--compact .pv__chips, .pv--compact .pv__map { order: 0; } }
@media (max-width: 719px) { .pv--compact .pv__in { grid-template-columns: 1fr; gap: 12px; } .pv--compact .pv__map { display: none; } .pv--compact .pv__chips { grid-column: 1; margin: 0 -16px; } }

/* round 4 (after review 3): one number leads the card; the sum sits behind "See the breakdown" on every size; no second dark button */
.pv .pv__p { display: grid !important; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0 16px; margin-top: 14px; font-size: 15.5px; line-height: 1.5; color: var(--ink-2); }
.pv .pv__big { font-family: var(--display); font-weight: 600; font-size: 56px; line-height: .9; letter-spacing: -.02em; color: var(--forest); font-variant-numeric: lining-nums; font-variation-settings: 'opsz' 96; }
.pv[data-picked] .pv__big { color: var(--signal-ink, #8f3d1c); }
/* the breakdown is folded from the FIRST paint (it used to fold when the script started, which moved the band: layout shift 0.03 to 0.18
   on wide screens). A browser with scripting off never gets the button, so it shows the breakdown instead. */
.pv:not(.is-bd) .pv__stack, .pv:not(.is-bd) .pv__sum { display: none !important; }
@media (scripting: none) {
  .pv:not(.is-bd) .pv__stack { display: block !important; }
  .pv:not(.is-bd) .pv__sum { display: grid !important; }
  .fd .pv .pv__bd { display: none !important; }
}
.pv.is-bd .pv__stack { display: block !important; margin-top: 6px; }
.pv.is-bd .pv__sum { display: grid !important; border-top: 2px solid var(--ink) !important; padding-top: 12px !important; margin-top: 2px !important; order: 0 !important; }
.fd .pv .pv__bd:not([hidden]) { display: inline-block; margin-top: 12px; padding: 0; border: 0; background: none; box-shadow: none; font: 600 14px/1 var(--ui); color: var(--forest); text-decoration: underline; text-decoration-color: rgba(26, 61, 46, .35); text-underline-offset: 3px; min-height: 40px; cursor: pointer; }
.pv .pv__act { margin-top: 0; display: inline-flex; }
.pv .pv__act[hidden] { display: none; }
.fd .pv .pv__go { display: inline-flex; align-items: center; min-height: 40px; margin-left: 20px; font: 600 14px/1 var(--ui); color: var(--forest); text-decoration: underline; text-decoration-color: rgba(26, 61, 46, .35); text-underline-offset: 3px; }
.pv .pv__cap { justify-content: flex-start; gap: 4px 14px; }
.pv .pv__lead { display: none !important; }
@media (max-width: 719px) { .pv .pv__big { font-size: 46px; } .pv .pv__p { font-size: 14.5px; gap: 0 12px; margin-top: 10px; } .fd .pv .pv__bd:not([hidden]), .fd .pv .pv__go { min-height: 44px; } }
/* compact band, composed: words on the left, the picture on the right at a size that reads */
.pv--compact .pv__in { grid-template-columns: minmax(0, 1fr) 340px !important; gap: 4px 40px !important; align-items: center; }
.pv--compact .pv__map { grid-column: 2; grid-row: 1 / span 2 !important; order: 0; }
.pv--compact .pv__side { grid-column: 1; align-self: end; max-width: 680px; }
.pv--compact .pv__chips { grid-column: 1 !important; }
.pv--compact .pv__cap { justify-content: center; }
@media (max-width: 1023px) { .pv--compact .pv__in { grid-template-columns: minmax(0, 1fr) 240px !important; gap: 4px 20px !important; } }
@media (max-width: 719px) { .pv--compact .pv__in { grid-template-columns: 1fr !important; gap: 12px !important; } .pv--compact .pv__map { display: block !important; grid-column: 1; grid-row: auto !important; order: 3; max-width: 340px; margin: 0 auto; } .pv--compact .pv__side { order: 1; } .pv--compact .pv__chips { order: 2; } }

/* homepage, second version: the week as three lists (the earlier card), then the map as the way into the directory */
.tw.tw--low { padding-top: 3.5rem; }

.pv .pv__big { min-width: 2.1ch; text-align: left; font-variant-numeric: lining-nums tabular-nums; }
.pv[data-picked] .pv__big { color: var(--forest); }

/* card wording variants (?card=a|b|c) */
.pv .pv__p b:not(.pv__big) { color: var(--ink); font-weight: 650; }
.pv .pv__plain { grid-column: 1 / -1; font-size: 16px; line-height: 1.55; }
/* the box keeps the drawing's own shape from first paint (the builder writes both ratios), so the map arriving moves nothing */
.fd #pv-map { aspect-ratio: var(--pv-ar); }
@media (max-width: 719px) { .fd #pv-map { aspect-ratio: var(--pv-arp, var(--pv-ar)); } }
.pv.is-nomap .pv__map { display: none; }
/* a province page keeps only the "switched off for your answers" line where the squares used to be */
.fd .fd-field.fd-field--bare { margin: 0; padding: 0; border: 0; background: none; box-shadow: none; min-height: 0; }
.fd .fd-field.fd-field--bare .fd-field__foot { margin: 0; padding: 0; border: 0; min-height: 0; }
.fd .fd-field.fd-field--bare .fd-field__off:not([hidden]) { display: block; margin: 0 0 12px; }
/* a short strip stays short: a tall province (Manitoba, Saskatchewan, Yukon) is drawn at a fixed height, never at the column's width */
@media (min-width: 720px) {
  .pv--compact .pv__map { display: flex; flex-direction: column; align-items: center; }
  .fd .pv--compact #pv-map { width: auto; height: 200px; max-width: 100%; }
}
@media (min-width: 720px) { .fd .pv--still #pv-map { height: 150px; } }

/* ── rank in place ("Rank my list" ranks the list on the page, 2026-10-11; js/directory.src.js "rank in place") ──
   Nothing here is on screen until the visitor asks for a ranking: the card, the strip and the two list headings are hidden
   or not yet made at load, so none of it can move the page as it opens. */
/* the pop-over as a dialog: the rank questions and "Your answers". On a phone it is the same bottom sheet the filters use.
   ★ 2026-10-12 (the owner's walk: "the quiz modal gets easily cut-off on a regular screen"):
     · it sits in the space BELOW the sticky site header (--navh), never centred in the whole window, where its first
       50px ("Question 1 of 5") lay under the header;
     · the step, the question and the foot (Back, Skip, Continue) do not move: only the answers scroll;
     · a long list of answers (the eleven sectors and "Something else") is set in two columns, so it fits a 1366x768 screen. */
.fd-pop.is-modal > * { flex: none; }
.fd-pop.is-modal > .fd-pop__opts { flex: 0 1 auto; min-height: 0; }
@media (min-width: 720px) {
  .fd-pop.is-modal {
    inset: calc(var(--navh) + 16px) 0 16px 0; margin: auto; width: 440px; max-width: calc(100vw - 32px); height: fit-content;
    max-height: min(800px, calc(100vh - var(--navh) - 32px)); max-height: min(800px, calc(100dvh - var(--navh) - 32px));
    padding: 22px 16px 16px; transform-origin: center;
  }
  .fd-pop.is-modal.is-wide { width: 580px; }
  .fd-pop.is-modal.is-two { width: 720px; }
  .fd-pop.is-modal.is-two .fd-pop__opts { grid-template-columns: 1fr 1fr; column-gap: 6px; }
}
@media (max-width: 719px) {
  /* the sheet never climbs under the site header either (a short phone, or a long question) */
  .fd-pop, .fd-pop.is-wide { max-height: min(86vh, calc(100vh - var(--navh) - 8px)); max-height: min(86vh, calc(100dvh - var(--navh) - 8px)); }
}
.fd-pop.is-rank .fd-pop__foot { display: none; }
/* an answer whose label wraps (a narrow phone) keeps its own height: without this the option list, squeezed by the sheet's
   height, shrank every row to the minimum and a two-line label ran into the next answer (the filters' menus had it too) */
.fd-pop__opts { grid-auto-rows: max-content; }
.fd-pop__step { margin: 0 10px 12px; font-size: 13px; font-weight: 600; color: var(--forest-2); font-variant-numeric: tabular-nums; }
.fd-pop__step .fd-prog { margin: 8px 0 0; }
.fd-pop__step .fd-prog i { height: 4px; }
.fd-pop__sub { margin: -6px 10px 10px; font-size: 14px; line-height: 1.45; color: var(--ink-3); }
.fd-pop__rfoot { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; padding: 10px 6px 0 10px; border-top: 1px solid var(--rule); }
/* Back on the left, Skip and Continue on the right: Continue never moves when Skip comes or goes */
.fd-pop__rgo { display: flex; align-items: center; gap: 16px; margin-left: auto; }

.fd .fd-pop__skip { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; padding: 0 4px; font: 600 14.5px/1.2 var(--ui); color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.fd .fd-pop__skip:hover { color: var(--forest); }
/* Back is a step control, not a link: no underline, and it follows the Skip rule above so it can undo it */
.fd .fd-pop__skip.fd-pop__prev { gap: 2px; margin-left: -6px; padding: 0 10px 0 4px; border-radius: 10px; color: var(--forest); text-decoration: none; }
.fd .fd-pop__skip.fd-pop__prev:hover { background: var(--forest-wash); }
.fd-pop__prev svg { font-size: 18px; }
.fd-pop__rfoot .fd-btn[disabled] { opacity: .45; cursor: default; }
/* several answers can be true at once: a box, not the single-choice tick */
.fd-opt--check svg { visibility: visible; width: 20px; height: 20px; padding: 2px; border-radius: 6px; color: transparent; box-shadow: inset 0 0 0 1.5px var(--ink-4); }
.fd-opt--check[aria-checked="true"] svg { color: #fff; background: var(--forest); box-shadow: none; }

/* the ranked list: a number on each of the top rows, and at most one short reason */
.fd-row__fit { display: flex; align-items: center; gap: 8px; margin: 0 0 7px; font-size: 13px; font-weight: 600; line-height: 1.25; color: var(--forest-2); }
.fd-row__rk { flex: none; display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--forest); color: #fff; font: 700 13px/1 var(--ui); font-variant-numeric: tabular-nums lining-nums; }
.fd-row__because { min-width: 0; }

/* ── what a ranking says (2026-10-12) ──
   ONE place holds it, at every width: the strip that leads the list (#fd-rkbar): the count, one line, the answers as pills,
   "Change answers" and the one offer. The sign-up, the wait and its outcomes take the offer's place there, so the pills stay
   in view through all of them. Before, the result appeared in the side column while the eye was on the list, and the pills
   left as soon as a program was opened.
   The side card (#fd-rank, desktop) and the bottom bar (below it) only FOLLOW: they repeat the button while the strip's own
   is off screen (js: rk.slotSeen), so there are never two primary buttons at once. */
.fd-rkbar { margin: 0 0 8px; padding: 20px 22px 18px; border-radius: 18px; background: var(--forest-tint); border: 1px solid #cfdcd3; }
.fd .fd-rkbar__t { margin: 0; font-family: var(--display); font-weight: 600; font-size: 24px; line-height: 1.2; letter-spacing: -.012em; color: var(--forest); font-variation-settings: 'opsz' 48; font-variant-numeric: lining-nums; text-wrap: balance; }
.fd .fd-rkbar__t:focus { outline: 0; }   /* focused by the script so a screen reader lands on the result; it is not a control */
.fd-rkbar__p { margin: 6px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }
.fd-rkbar .fd-rk__edit { margin-top: 2px; }
.fd-rkbar__offer > .fd-btn, .fd-rkbar__offer > .fd-rk__auth, .fd-rkbar__offer > .fd-rk__wait, .fd-rkbar__offer > .fd-rk__note, .fd-rkbar__offer > .fd-rk__h { max-width: 440px; }
@media (min-width: 1280px) {
  /* room for two columns in the list's own column: what was ranked on the left, the offer (then the sign-up, then the wait) on the right */
  .fd-rkbar { display: grid; grid-template-columns: minmax(0, 1fr) 336px; column-gap: 26px; align-items: start; padding: 22px 24px; }
  .fd-rkbar .fd-rkbar__offer { margin-top: 0; padding: 2px 0 0 26px; border-top: 0; border-left: 1px solid #cfdcd3; align-self: stretch; }
}
@media (max-width: 719px) {
  .fd-rkbar { margin-bottom: 4px; padding: 16px 16px 14px; border-radius: 16px; }
  .fd .fd-rkbar__t { font-size: 21px; }
}
/* the "your business" step saved something: said plainly beside the wait */
.fd-rk__saved { display: flex; align-items: flex-start; gap: 8px; margin: 0 0 14px; padding: 10px 12px; border-radius: 12px; background: var(--paper); box-shadow: inset 0 0 0 1px #b9cdbf; font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--forest); }
.fd-rk__saved svg { font-size: 18px; stroke-width: 2.4; margin-top: 1px; }
.fd-rk__saved b { font-weight: 600; color: var(--ink); overflow-wrap: anywhere; }
@media (prefers-reduced-motion: no-preference) { .fd-rk__saved { animation: fd-pop-in .22s var(--ease); } }

/* the follower beside the list (desktop): the headline and the same one button, while the strip's own is off screen */
.fd-rk { flex: none; order: -1; border-radius: 20px; padding: 22px 24px 18px; background: var(--forest-tint); border: 1px solid #cfdcd3; max-height: calc(100vh - var(--navh) - var(--barh) - 36px); overflow: auto; scrollbar-width: thin; }
.fd-rk__eye { display: flex; align-items: center; gap: 7px; margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--forest-2); }
.fd-rk__eye::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #2f8a5a; }
.fd .fd-rk__t { margin: 0; font-family: var(--display); font-weight: 600; font-size: 23px; line-height: 1.2; letter-spacing: -.012em; color: var(--forest); font-variation-settings: 'opsz' 48; font-variant-numeric: lining-nums; outline: 0; }
.fd-rk__p { margin: 8px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }
.fd-rk__ans { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 0; padding: 0; }
.fd-rk__ans li { padding: 4px 10px; border-radius: 999px; background: var(--paper); box-shadow: inset 0 0 0 1px #cfdcd3; font-size: 13px; font-weight: 600; line-height: 1.35; color: var(--ink); }
.fd .fd-rk__edit, .fd .fd-rk__back, .fd .fd-rk__quiz { display: inline-flex; align-items: center; min-height: 44px; padding: 0; font: 600 14px/1.3 var(--ui); color: var(--forest); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.fd .fd-rk__edit:hover, .fd .fd-rk__back:hover, .fd .fd-rk__quiz:hover { text-decoration-thickness: 2px; }
.fd .fd-rk__quiz { font-weight: 500; color: var(--ink-2); }
.fd-rk__offer { margin-top: 2px; padding-top: 16px; border-top: 1px solid #cfdcd3; }
.fd-rk__offer:empty { display: none; }
.fd-rk__offer .fd-btn { text-align: center; line-height: 1.25; padding-top: 10px; padding-bottom: 10px; }
.fd-rk__note { margin: 10px 0 0; font-size: 13.5px; line-height: 1.5; color: var(--ink-2); }
.fd .fd-rk__h { margin: 0; font: 600 17px/1.3 var(--ui); color: var(--ink); }
.fd-rk__offer .fd-rk__note + .fd-btn { margin-top: 14px; }
.fd-rk__offer .fd-rk__quiz, .fd-rk__offer .fd-rk__back { margin-top: 4px; }
.fd-rk > .fd-rk__offer { margin-top: 14px; }
/* a program's details are open: the follower keeps its headline and its button, nothing else */
.fd-rk.is-compact { padding-top: 16px; padding-bottom: 16px; }
.fd-rk.is-compact .fd-rk__eye, .fd-rk.is-compact .fd-rk__p { display: none; }
.fd-rk.is-compact .fd-rk__t { font-size: 19px; }
.fd-rk.is-compact .fd-rk__offer { margin-top: 12px; padding-top: 12px; }

/* the sign-up in place (gc-signup.js renderInline, in this page's tokens) */
.fd-rk__auth { margin-top: 14px; }
.fd-rk__auth .gcs-google { width: 100%; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 16px; background: #fff; border: 1px solid var(--rule-2); border-radius: 12px; font: 600 15.5px/1.2 var(--ui); color: var(--ink); cursor: pointer; transition: background-color .15s, box-shadow .15s; }
.fd-rk__auth .gcs-google svg { width: 18px; height: 18px; stroke: none; fill: initial; }
.fd-rk__auth .gcs-google svg path { stroke: none; }
.fd-rk__auth .gcs-google:hover { background: #fafaf6; box-shadow: 0 2px 8px rgba(20, 35, 28, .08); }
.fd-rk__auth .gcs-google:disabled, .fd-rk__auth .gcs-email-btn:disabled { opacity: .55; cursor: default; }
.fd-rk__auth .gcs-or { display: flex; align-items: center; gap: 10px; margin: 12px 0; font-size: 13px; color: var(--ink-3); }
.fd-rk__auth .gcs-or::before, .fd-rk__auth .gcs-or::after { content: ''; flex: 1; height: 1px; background: var(--rule-2); }
.fd-rk__auth .gcs-form { display: flex; flex-direction: column; gap: 8px; }
.fd-rk__auth .gcs-name, .fd-rk__auth .gcs-email, .fd-rk__auth .gcs-pw { width: 100%; min-height: 46px; padding: 0 13px; border: 1px solid var(--rule-2); border-radius: 10px; background: #fff; font: 400 16px/1.2 var(--ui); color: var(--ink); }
.fd-rk__auth .gcs-name:focus, .fd-rk__auth .gcs-email:focus, .fd-rk__auth .gcs-pw:focus { outline: 2px solid var(--forest); outline-offset: -1px; border-color: var(--forest); }
.fd-rk__auth .gcs-email-btn { width: 100%; text-align: center; min-height: 48px; border-radius: 12px; background: var(--forest); color: #fff; font: 600 15.5px/1.2 var(--ui); cursor: pointer; }
.fd-rk__auth .gcs-email-btn:hover { background: #10291e; }
.fd-rk__auth .gcs-err { margin-top: 9px; font-size: 13.5px; line-height: 1.4; color: var(--signal-ink); }
.fd-rk__auth .gcs-err:empty { margin-top: 0; }
.fd-rk__auth .gcs-toggle { margin-top: 10px; font-size: 13.5px; color: var(--ink-3); text-align: center; }
.fd-rk__auth .gcs-signin-link, .fd-rk__auth .gcs-emaillink { display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; font: 600 14px/1.2 var(--ui); color: var(--forest); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.fd-rk__auth .gcs-signin-link { min-height: 44px; font-size: 13.5px; }   /* 44, not 32: a touch target in the expanded email form */
.fd-rk__auth .gcs-google:focus-visible, .fd-rk__auth .gcs-email-btn:focus-visible, .fd-rk__auth .gcs-signin-link:focus-visible, .fd-rk__auth .gcs-emaillink:focus-visible { outline: 2px solid var(--forest); outline-offset: 2px; }
.fd-rk__auth.gcs--collapsed .gcs-or, .fd-rk__auth.gcs--collapsed .gcs-form, .fd-rk__auth.gcs--collapsed .gcs-toggle { display: none; }
.fd-rk__emailrow { text-align: center; }
.fd-rk__wait { text-align: left; }
.fd-rk__spin { display: block; width: 26px; height: 26px; margin: 2px 0 12px; border-radius: 50%; border: 3px solid #cfdcd3; border-top-color: var(--forest); animation: fd-spin .9s linear infinite; }
@keyframes fd-spin { to { transform: rotate(360deg); } }
/* "Rank my list" while the rows and the scorer arrive */
.fd .fd-btn.is-busy { pointer-events: none; opacity: .8; }
.fd .fd-btn.is-busy::after { content: ''; width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; animation: fd-spin .8s linear infinite; }
@media (prefers-reduced-motion: reduce) { .fd-rk__spin, .fd .fd-btn.is-busy::after { animation-duration: 2.4s; } }

/* below desktop width the bottom bar follows with the offer (the strip over the list leads with it) */
@media (max-width: 1023px) {
  .fd-mbar [data-mb-rank] b { display: block; font: 600 15px/1.3 var(--ui); color: var(--ink); }
}
