/* Small overrides applied on top of the captured Astra/Elementor/LiteSpeed
   inline CSS. Goal: keep the original look, only fix what's broken in static
   serving and add the AI Strategic Assessment CTA styling. */

/* Highlight the new "Get an Assessment" nav item */
li.ebi-assessment-cta a,
li.ebi-assessment-cta .menu-link {
  background: #4169e1 !important;
  color: #ffffff !important;
  border-radius: 4px;
  padding: 6px 16px !important;
}
li.ebi-assessment-cta a:hover,
li.ebi-assessment-cta .menu-link:hover {
  background: #191970 !important;
  color: #ffffff !important;
}

/* Hide the "Submit / Loading" button states from the contact form widget on
   pages where the form will mailto: instead of post AJAX */
.wpforms-submit-spinner { display: none !important; }

/* If any image failed to swap to a local src, hide rather than break layout */
img[src=""], img:not([src]) { display: none; }

/* Drop residual cookie/admin bars even if class was missed */
#wpadminbar, .cli-modal, .cli-bar-container, .cli-window { display: none !important; }
html { margin-top: 0 !important; }

/* Make sure forms posting via mailto have the right cursor */
form[action^="mailto:"] button[type=submit] { cursor: pointer; }

/* Mobile menu — Astra normally toggles via JS. We replicate via body class. */
@media (max-width: 921px) {
  /* Make sure the toggle button is visible & styled */
  .menu-toggle,
  .main-header-menu-toggle,
  .ast-mobile-menu-trigger-outline {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    padding: 8px 12px;
    cursor: pointer;
    color: #0a2540;
    font-size: 22px;
    line-height: 1;
  }
  /* Hide the desktop primary menu by default */
  ul.main-header-menu { display: none; }
  /* When body has our toggle class, slide menu in as a column block */
  body.ebi-mobile-menu-open ul.main-header-menu {
    display: flex !important;
    flex-direction: column;
    gap: 0;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    padding: 14px 24px 22px;
    border-bottom: 1px solid #e2e6ec;
    box-shadow: 0 8px 18px rgba(0,0,0,0.08);
    z-index: 999;
  }
  body.ebi-mobile-menu-open ul.main-header-menu li {
    display: block;
    border-bottom: 1px solid #f0f3f8;
  }
  body.ebi-mobile-menu-open ul.main-header-menu li:last-child { border-bottom: 0; }
  body.ebi-mobile-menu-open ul.main-header-menu a {
    display: block;
    padding: 12px 0;
    color: #0a2540;
  }
  /* Hide the secondary navigation duplicate that ships with Astra so mobile
     doesn't show two copies. */
  #primary-site-navigation-mobile { display: none !important; }
}

/* Form spinner — our inline SVG replacement */
.ebi-form-spinner {
  width: 26px;
  height: 26px;
  display: inline-block;
  vertical-align: middle;
  margin-left: 8px;
}

/* Tool icon fallbacks (Simple Icons CDN delivers monochrome SVGs).
   Tint them via filter so they sit alongside other logos visually. */
img[data-ebi-tool-icon] {
  height: 60px;
  width: auto;
  max-width: 140px;
  filter: invert(13%) sepia(31%) saturate(2280%) hue-rotate(196deg) brightness(94%) contrast(93%);
  /* That filter approximates the Soma navy #0a2540 — close enough for badge use */
  opacity: 0.85;
}

/* Toast for mailto submit feedback (script appends an inline div, this only
   defines the class if the script ever uses one) */
.ebi-mailto-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: #0a2540;
  color: #ffffff;
  padding: 14px 24px;
  border-radius: 8px;
  font-size: 14px;
  z-index: 9999;
  box-shadow: 0 4px 24px rgba(0,0,0,0.25);
}
