
/* Veridian Health 2.6.57
   Header background repair.
   The two desktop header rows were floated, which caused the outer rounded
   header shell to collapse to zero height. That is why the ivy showed
   directly behind the logo/search/cart/menu even though a background had
   already been assigned to the shell.
*/

@media (min-width: 768px) {
  #header .vh-reference-header-shell {
    display: flow-root !important;
    position: relative !important;
    min-height: 138px !important;
    background: rgba(249, 248, 241, 0.96) !important;
    background-color: rgba(249, 248, 241, 0.96) !important;
    background-image:
      linear-gradient(rgba(249, 248, 241, 0.82), rgba(249, 248, 241, 0.82)),
      url('../img/veridian-ivy-wallpaper-2649.png') !important;
    background-size: auto, 760px auto !important;
    background-position: center, center !important;
    background-repeat: no-repeat, repeat !important;
    border: 1px solid rgba(214, 216, 197, 0.96) !important;
    border-radius: 16px !important;
    box-shadow: 0 10px 28px rgba(24, 43, 16, 0.18) !important;
    overflow: visible !important;
    isolation: isolate !important;
  }

  /* Explicitly keep both rows in normal flow so the shell always wraps them. */
  #header .vh-reference-header-shell > .header-top,
  #header .vh-reference-header-shell > .header-navfullwidth {
    float: none !important;
    clear: both !important;
    display: block !important;
    width: 100% !important;
  }

  /* Thin divider like the supplied reference. */
  #header .vh-reference-header-shell > .header-navfullwidth {
    border-top: 1px solid rgba(55, 74, 30, 0.10) !important;
  }

  /* Keep header controls visually on top of the panel. */
  #header .vh-reference-header-shell .container,
  #header .vh-reference-header-shell .row,
  #header .vh-reference-header-shell .vh-reference-header-main,
  #header .vh-reference-header-shell .vh-reference-nav-row {
    position: relative !important;
    z-index: 2 !important;
  }

  /* Match the intended reference order: logo | search | account | cart. */
  #header .vh-reference-display-top #search_widget {
    order: 1 !important;
  }

  #header .vh-reference-account-slot {
    order: 2 !important;
  }

  #header .vh-reference-display-top #_desktop_cart,
  #header .vh-reference-display-top .vh-reference-cart {
    order: 3 !important;
  }

  /* The displayTop wrapper contains search + cart; allow the search to occupy
     the centre while the cart stays at the far right. */
  #header .vh-reference-display-top {
    display: flex !important;
    align-items: center !important;
  }

  #header .vh-reference-display-top #search_widget {
    flex: 1 1 520px !important;
  }

  #header .vh-reference-display-top #_desktop_cart,
  #header .vh-reference-display-top .vh-reference-cart {
    flex: 0 0 auto !important;
  }
}

/* Keep mobile clean and readable with a solid light header background. */
@media (max-width: 767.98px) {
  #header .vh-reference-header-shell,
  #header .header-nav,
  #header .header-top {
    background: rgba(249, 248, 241, 0.98) !important;
    background-color: rgba(249, 248, 241, 0.98) !important;
  }
}
