html[data-theme="dark"]{--wp--preset--color--surface:#061b36;--wp--preset--color--surface-alt:#092849;--wp--preset--color--text:#f4f7fb;--wp--preset--color--muted:#afbdd0;--wp--preset--color--border:#264665;--wp--preset--color--navy-light:#8bbbe9;color-scheme:dark}

/* Light editorial surfaces use fixed colours in brand.css. Re-map them in
 * dark mode so inherited light text never lands on a pale background. */
html[data-theme="dark"] .hfbd-proof,
html[data-theme="dark"] .hfbd-section--manifesto{background:#061b36;color:#f4f7fb}
html[data-theme="dark"] .hfbd-proof p strong{color:#8bbbe9}
html[data-theme="dark"] .hfbd-proof__seal,
html[data-theme="dark"] .hfbd-proof__index{color:#dfc17c}
html[data-theme="dark"] .hfbd-proof__index i{background:#c6a75d}
html[data-theme="dark"] .hfbd-section--manifesto:after{color:rgba(139,187,233,.10)}
html[data-theme="dark"] .hfbd-values{background:rgba(139,187,233,.32);border-color:rgba(139,187,233,.32)}
html[data-theme="dark"] .hfbd-value{background:#0b294b;color:#f4f7fb}
html[data-theme="dark"] .hfbd-value:hover{background:#103a69}
html[data-theme="dark"] .hfbd-value strong{color:#dfc17c}
html[data-theme="dark"] .hfbd-text-link{color:#f4f7fb}
html[data-theme="dark"] .hfbd-partners{background:#061b36;color:#f4f7fb}
html[data-theme="dark"] .hfbd-sponsor{background:#0b294b;color:#f4f7fb;border-color:#264665}
html[data-theme="dark"] .hfbd-sponsor img{filter:none}
html[data-theme="dark"] .hfbd-sponsor-empty a{color:#f4f7fb}
html[data-theme="dark"] body{background:#020b16;color:#f4f7fb}
html[data-theme="dark"] .hfbd-header{background:rgba(2,11,22,.94);border-bottom-color:transparent}
html[data-theme="dark"] .hfbd-header::after{content:"";position:absolute;z-index:2;right:0;bottom:-4px;left:0;height:4px;background:#ffed00;box-shadow:0 1px 0 rgba(4,23,47,.14)}
/* Dark surfaces must never inherit the dark-on-light token. */
html[data-theme="dark"] :is(.hfbd-hero,.hfbd-section--navy){color:#f4f7fb}
html[data-theme="dark"] :is(.hfbd-hero,.hfbd-section--navy) :is(h1,h2,h3,p,a,time){color:#f4f7fb}
html[data-theme="dark"] :is(.hfbd-hero,.hfbd-section--navy) .hfbd-eyebrow,
html[data-theme="dark"] :is(.hfbd-hero,.hfbd-section--navy) .hfbd-highlight__tag{color:#ffed00}
html[data-theme="dark"] .hfbd-section--tint{background:#071b31}
html[data-theme="dark"] .hfbd-partners{background:#010914;border-block:1px solid #234462}
html[data-theme="dark"] .hfbd-partners .hfbd-sponsor-cta--row{color:#f4f7fb}
html[data-theme="dark"] .hfbd-partners .hfbd-sponsor-cta--row:hover,
html[data-theme="dark"] .hfbd-partners .hfbd-sponsor-cta--row:focus-visible{border-bottom-color:#f4f7fb;color:#f4f7fb}
html[data-theme="dark"] .hfbd-partners .hfbd-sponsor-cta--row span{color:#ffed00}
html[data-theme="dark"] .hfbd-news-card{background:#0b294b;border-color:#315779;box-shadow:none}
html[data-theme="dark"] .hfbd-news-card>a{color:#f4f7fb}
html[data-theme="dark"] .hfbd-news-card p{color:#c4d0df}
html[data-theme="dark"] .hfbd-association-card{border-color:#315779;color:#f4f7fb}
html[data-theme="dark"] .hfbd-association-card__copy small{color:#c4d0df}
html[data-theme="dark"] .hfbd-association-card__arrow{color:#ffed00!important}
html[data-theme="dark"] .hfbd-association-hub__intro p{color:#c4d0df}
html[data-theme="dark"] .hfbd-news-pagination{border-color:#315779;color:#c4d0df}
html[data-theme="dark"] .hfbd-news-pagination a{color:#ffed00;text-decoration-color:#ffed00}
html[data-theme="dark"] .hfbd-footer__grid>div:first-child>p{color:#b9c9dc}
html[data-theme="dark"] .hfbd-sponsor-page__hero h1,
html[data-theme="dark"] .hfbd-sponsor-page__form-area h2,
html[data-theme="dark"] .hfbd-sponsor-page__benefits h2{color:#f4f7fb}
html[data-theme="dark"] .hfbd-sponsor-page__hero p,
html[data-theme="dark"] .hfbd-sponsor-page__benefits p,
html[data-theme="dark"] .hfbd-sponsor-page__form-area p{color:#c4d0df}
html[data-theme="dark"] .hfbd-sponsor-page__benefits{border-color:#315779;background:#0b294b}
html[data-theme="dark"] .hfbd-sponsor-page__benefits article{border-color:#315779}
html[data-theme="dark"] .hfbd-sponsor-page__showcase{background:#061b36}
html[data-theme="dark"] .hfbd-sponsor-page__showcase h2{color:#f4f7fb}
html[data-theme="dark"] .hfbd-sponsor-page__showcase .hfbd-eyebrow{color:#ffed00}
html[data-theme="dark"] .hfbd-sponsor-page__form-area{border-color:#315779}
html[data-theme="dark"] .hfbd-sponsor-page__form .hfbd-form{background:#0b294b;box-shadow:none}
html[data-theme="dark"] .hfbd-sponsor-page__form input,
html[data-theme="dark"] .hfbd-sponsor-page__form select,
html[data-theme="dark"] .hfbd-sponsor-page__form textarea{border-color:#46698e;background:#061b36;color:#f4f7fb}
html[data-theme="dark"] .hfbd-sponsor-page__form label{color:#f4f7fb}
html[data-theme="dark"] .hfbd-association-detail__hero{border-color:#315779;background:linear-gradient(135deg,#0b294b,#071b31)}
html[data-theme="dark"] .hfbd-association-detail__hero :is(h1,p){color:#f4f7fb}
html[data-theme="dark"] .hfbd-association-detail__hero .hfbd-association-detail__back{color:#c4d0df}
html[data-theme="dark"] .hfbd-association-detail__principles,html[data-theme="dark"] .hfbd-association-detail__mission-grid{border-color:#315779}
html[data-theme="dark"] .hfbd-association-detail__principles article,html[data-theme="dark"] .hfbd-association-detail__mission-grid article,html[data-theme="dark"] .hfbd-association-detail__founders article,html[data-theme="dark"] .hfbd-association-detail__council{border-color:#315779;background:#0b294b}
html[data-theme="dark"] .hfbd-association-detail :is(h2,h3),html[data-theme="dark"] .hfbd-association-detail__roster li,html[data-theme="dark"] .hfbd-association-detail__founders li,html[data-theme="dark"] .hfbd-association-detail__council li{color:#f4f7fb}
html[data-theme="dark"] .hfbd-association-detail :is(p,.hfbd-association-detail__council p){color:#c4d0df}
html[data-theme="dark"] .hfbd-association-detail__journey > div:last-child,html[data-theme="dark"] .hfbd-association-detail__journey article,html[data-theme="dark"] .hfbd-association-detail__roster,html[data-theme="dark"] .hfbd-association-detail__roster ol,html[data-theme="dark"] .hfbd-association-detail__roster li,html[data-theme="dark"] .hfbd-association-detail__founders li{border-color:#315779}
html[data-theme="dark"] .hfbd-association-detail__closing{border-color:#315779;background:linear-gradient(135deg,#0b294b,#102f53)}

/* The divider belongs to the header in both colour modes. Keep it explicit
   here because this stylesheet loads after every component stylesheet. */
html[data-theme="light"] .hfbd-header,
html:not([data-theme]) .hfbd-header{position:sticky;border-bottom-color:transparent}
html[data-theme="light"] .hfbd-header::after,
html:not([data-theme]) .hfbd-header::after{content:"";position:absolute;z-index:2;right:0;bottom:-4px;left:0;height:4px;background:#ffed00;box-shadow:0 1px 0 rgba(4,23,47,.14)}

/* Contrast contract: component-level text rules must never override a button's
   own foreground colour. This covers the home hero as well as every form CTA. */
html[data-theme="dark"] :is(.hfbd-button,.wp-element-button,.hfbd-login input[type="submit"]){background:#ffed00!important;color:#04172f!important;text-decoration-color:#04172f!important}
html[data-theme="dark"] :is(.hfbd-hero,.hfbd-section--navy) :is(.hfbd-button,.wp-element-button,.hfbd-login input[type="submit"]),
html[data-theme="dark"] :is(.hfbd-button,.wp-element-button) :is(span,strong){color:#04172f!important}
html[data-theme="dark"] :is(.hfbd-button--ghost,.hfbd-hero .hfbd-button--ghost){border-color:#f4f7fb!important;background:transparent!important;color:#f4f7fb!important;text-decoration-color:#ffed00!important}
html[data-theme="dark"] :is(.hfbd-button--ghost,.hfbd-hero .hfbd-button--ghost) :is(span,strong){color:#f4f7fb!important}
html[data-theme="dark"] :is(.hfbd-card,.hfbd-notice,.hfbd-field,.hfbd-fixture,.hfbd-match,.hfbd-membership-process) :is(h1,h2,h3,p,label,small,span){color:inherit}
html[data-theme="dark"] :is(.hfbd-card,.hfbd-notice,.hfbd-fixture,.hfbd-match,.hfbd-membership-process){color:#f4f7fb}
html[data-theme="dark"] :is(.hfbd-card,.hfbd-notice,.hfbd-fixture,.hfbd-match,.hfbd-membership-process) :is(p,small,time){color:#c4d0df}

html[data-theme="dark"] .hfbd-news-card__meta{color:#ffed00}

/* The hero secondary CTA intentionally mirrors its light-mode treatment: transparent surface, white label and a restrained white outline. */
html[data-theme="dark"] .hfbd-hero .hfbd-actions > a.hfbd-button.hfbd-button--ghost{border-color:rgba(255,255,255,.62)!important;background:transparent!important;color:#f4f7fb!important;box-shadow:none!important}
html[data-theme="dark"] .hfbd-hero .hfbd-actions > a.hfbd-button.hfbd-button--ghost:hover,html[data-theme="dark"] .hfbd-hero .hfbd-actions > a.hfbd-button.hfbd-button--ghost:focus-visible{border-color:#f4f7fb!important;background:rgba(255,255,255,.08)!important;color:#f4f7fb!important}
