/* SED Hub v730 final contrast patch — 2026-11-04; loaded after legacy and v11 style rules. */
/* Readability uses explicit theme tokens; avoid covering image-backed feature panels. */
html[data-theme="light"] { color-scheme:light; }
html[data-theme="dark"] { color-scheme:dark; }
html[data-theme="light"] body,html[data-theme="light"] main{color:#182943}
html[data-theme="dark"] body,html[data-theme="dark"] main{color:#ecf2ff}
html[data-theme="light"] main :is(.section-head,.page-hero,.policy,.info-card,.project-card,.programme-card,.fl-card-copy,.fl-panel,.fl-form,.fl-register-form) :is(h1,h2,h3,h4,p,li,small,label){color:#172a48}
html[data-theme="dark"] main :is(.section-head,.page-hero,.policy,.info-card,.project-card,.programme-card,.fl-card-copy,.fl-panel,.fl-form,.fl-register-form) :is(h1,h2,h3,h4,p,li,small,label){color:#f0f5ff}
html[data-theme="light"] main :is(.section-head,.page-hero,.policy) p{color:#334760}
html[data-theme="dark"] main :is(.section-head,.page-hero,.policy) p{color:#d9e6fc}
/* Projects, Interactive Science Zone, and general text links */
html[data-theme="light"] main :is(.policy,.project-card,.info-card,.interactive-zone,.science-zone) a:not(.btn):not(.fl-btn){color:#064c9d;text-decoration:underline;text-underline-offset:2px}
html[data-theme="dark"] main :is(.policy,.project-card,.info-card,.interactive-zone,.science-zone) a:not(.btn):not(.fl-btn){color:#9dd9ff;text-decoration:underline;text-underline-offset:2px}
html[data-theme="light"] main :is(.btn,.fl-btn,button[type="submit"]){color:#fff;background-color:#104f93;border-color:#104f93}
html[data-theme="dark"] main :is(.btn,.fl-btn,button[type="submit"]){color:#071b37;background-color:#c7e6ff;border-color:#c7e6ff}
main :is(.btn,.fl-btn,button,a,input,select,textarea):focus-visible{outline:3px solid #ffb11c;outline-offset:3px}
/* Footer and WhatsApp links must remain visible on their respective backdrops. */
html[data-theme="light"] footer :is(a,p,small,li),html[data-theme="light"] .fl-footer :is(a,p,small,li){color:#183b60}
html[data-theme="dark"] footer :is(a,p,small,li),html[data-theme="dark"] .fl-footer :is(a,p,small,li){color:#e7efff}
footer a:hover,.fl-footer a:hover{text-decoration:underline}
html[data-theme="light"] .fl-footer{background:#e8f1ff}
html[data-theme="dark"] .fl-footer{background:#071933}
html[data-theme="light"] .futurelab-site :is(.fl-form,.fl-register-form) label{color:#183450}
html[data-theme="dark"] .futurelab-site :is(.fl-form,.fl-register-form) label{color:#ebf3ff}
html[data-theme="light"] main :is(input,select,textarea){color:#142c48;background-color:#fff}
html[data-theme="dark"] main :is(input,select,textarea){color:#f4f8ff;background-color:#101f3a}
/* Preserve high-contrast text on media-backed dark panels and explicit inverse buttons. */
main :is(.hero-image-panel,.v8-camp-flow,.photo-overlay,.fl-register-hero) .fl-btn-light{color:#142b47;background:#fff}
@media(forced-colors:active){main :is(.btn,.fl-btn,a,button){forced-color-adjust:auto}}

/* Footer accessibility hotfix — explicit contrast, independent of selected theme. */
html[data-theme="light"] footer.footer,html[data-theme="dark"] footer.footer,footer.footer {
  background: #09182e !important; color:#ecf3ff !important; border-top:1px solid #274666 !important;
}
html[data-theme="light"] footer.footer :is(p,small,li,h3,a:not(.footer-wa)),
html[data-theme="dark"] footer.footer :is(p,small,li,h3,a:not(.footer-wa)),
footer.footer :is(p,small,li,h3,a:not(.footer-wa)) { color:#e1ecff !important; }
html[data-theme="light"] footer.footer a.footer-wa,
html[data-theme="dark"] footer.footer a.footer-wa,
footer.footer a.footer-wa {
  display:inline-block; padding:12px 18px; border-radius:10px;
  background:#bdefff !important; color:#082440 !important;
  font-weight:800; text-decoration:none; line-height:1.45;
  border:2px solid #bdefff; box-shadow:0 2px 0 #0e3658;
}
footer.footer a.footer-wa:hover { background:#ffffff !important;color:#06233d !important;text-decoration:underline; }
footer.footer a:focus-visible { outline:3px solid #ffc857 !important;outline-offset:3px; }
footer.footer .brand-sed,footer.footer .brand-hub { opacity:1; }

/* Chiswick footer + registration CTA accessibility fix (4 November 2026).
   These are deliberately scoped to FutureLab, to preserve all other site layouts. */
html[data-theme="light"] .futurelab-site .fl-footer,
html[data-theme="dark"] .futurelab-site .fl-footer,
.futurelab-site .fl-footer {
  background: #09182e !important;
  color: #edf5ff !important;
}
.futurelab-site .fl-footer .fl-brand-footer,
.futurelab-site .fl-footer .fl-brand-footer span,
.futurelab-site .fl-footer .fl-brand-footer span:not(b) {
  color: #ffffff !important;
  opacity: 1 !important;
}
.futurelab-site .fl-footer .fl-brand-footer b { color: #ff65ce !important; }
.futurelab-site .fl-footer .fl-brand-footer small { color: #b8eaff !important; }
.futurelab-site .fl-footer :is(p,li,a:not(.fl-brand),.fl-footer-bottom) {
  color: #e1edff !important;
}
.futurelab-site .fl-footer h3 { color: #a4e8ff !important; }
.futurelab-site .fl-footer a:hover { color: #ffffff !important; text-decoration: underline; }
/* White text on the royal blue registration button in either theme. */
html[data-theme="light"] .futurelab-site .fl-cta a.fl-btn.fl-btn-light,
html[data-theme="dark"] .futurelab-site .fl-cta a.fl-btn.fl-btn-light,
.futurelab-site .fl-cta a.fl-btn.fl-btn-light {
  background: #104b9b !important;
  background-image: none !important;
  color: #ffffff !important;
  border: 2px solid #ffffff !important;
  text-shadow: none !important;
  font-weight: 800 !important;
}
.futurelab-site .fl-cta a.fl-btn.fl-btn-light:hover,
.futurelab-site .fl-cta a.fl-btn.fl-btn-light:focus-visible {
  background: #082d67 !important;
  color: #ffffff !important;
  outline-offset: 3px;
}
