/* Essential: make the theme-only images actually swap */
body.theme-dark .light-theme-only {
  display: none !important;
}
body.theme-dark .dark-theme-only {
  display: block !important;
}

body.theme-light .dark-theme-only {
  display: none !important;
}
body.theme-light .light-theme-only {
  display: block !important;
}

/* Optional but recommended: base body colors so theme toggle feels real */
body.theme-dark {
  background: #0d0d0d;
  color: #ffffff;
}
body.theme-light {
  background: #ffffff;
  color: #1a1a1a;
}
/* ------------------------------------------------------------------
   1) Make theme classes authoritative (theme.light.css has global body styles)
------------------------------------------------------------------ */
body.theme-dark {
  background: #0d0d0d !important;
  color: #ffffff !important;
}

body.theme-light {
  background: #f2f2f2 !important;
  color: #1a1a1a !important;
}

/* Ensure asset swapping is always correct */
body.theme-dark .light-theme-only {
  display: none !important;
}
body.theme-dark .dark-theme-only {
  display: block !important;
}

body.theme-light .dark-theme-only {
  display: none !important;
}
body.theme-light .light-theme-only {
  display: block !important;
}

/* ------------------------------------------------------------------
   2) Services mega menu is a LIGHT panel → force DARK text when open
   This fixes your screenshot: header links + descriptions become readable
------------------------------------------------------------------ */
body.is-services-open #desktop-services-menu {
  background: #f2f2f2 !important;
}

body.is-services-open #desktop-services-menu .menu-title a,
body.is-services-open #desktop-services-menu .menu-desc {
  color: #1a1a1a !important;
}

/* Header links over the open Services panel */
body.is-services-open #header nav ul.menu > .menu-item > a {
  color: #1a1a1a !important;
}

body.is-services-open #header nav ul.menu > .menu-item > a:after {
  background: #1a1a1a !important;
}

/* Hamburger over the open Services panel */
body.is-services-open .hamburger-inner,
body.is-services-open .hamburger-inner::before,
body.is-services-open .hamburger-inner::after {
  background-color: #1a1a1a !important;
}

/* Switch logo to dark variant while Services panel is open */
body.is-services-open #header .dark-theme-only {
  display: none !important;
}
body.is-services-open #header .light-theme-only {
  display: block !important;
}
