/* CHB frontend fixes — mixed content leftovers, mobile, product cards, popup vs chat */

html {
  overflow-x: clip;
}
body {
  overflow-x: hidden;
}

/* Hide shipping weight on catalog cards (e.g. "950 g" on liquid colloids). */
ul.products .product-unit,
ul.products .product-weight,
ul.products .product .weight,
.products .product-footer .product-weight,
.klb-product .product-weight,
.product-wrapper .product-weight,
.product-wrapper .product-unit,
.product-content .product-weight,
.product-type-variable .product-weight,
.woocommerce ul.products li.product .product-weight,
.woocommerce ul.products li.product .product-unit,
.product-unit {
  display: none !important;
}

/* Empty / broken social icons (Twitter href was blank). */
footer a[href=""],
footer a[href="#"],
.site-footer a[href=""],
.klb-social a[href=""],
.elementor-social-icon-twitter:not([href]),
.elementor-social-icon-twitter[href=""],
.elementor-social-icon-twitter[href="#"] {
  display: none !important;
}

/* Newsletter popup above LiveChat; chat sits below while popup is open. */
#chb-popup-root.is-open,
#chb-popup-root.is-open .chb-popup-backdrop,
#chb-popup-root.is-open .chb-popup-card {
  z-index: 2147483600 !important;
}
html.chb-popup-open #chat-widget-container,
html.chb-popup-open iframe[src*="livechat"],
html.chb-popup-open [id^="chat-widget"],
html.chb-mnav-open #chat-widget-container,
html.chb-mnav-open iframe[src*="livechat"],
html.chb-mnav-open iframe[title="LiveChat chat widget"],
html.chb-mnav-open #livechat-eye-catcher,
html.chb-mnav-open [id^="chat-widget"] {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
  opacity: 0 !important;
}

/* Hero slides off-canvas must not widen the page. */
#chb-temp-hero-root,
#chb-temp-hero-root .hero,
body.home .hero-slide {
  max-width: 100vw;
  overflow: hidden;
}

/* Mobile tap targets + readable type. */
@media (max-width: 767px) {
  .header-buttons a,
  .header-cart,
  .header-login,
  .header-search,
  button.menu-toggle,
  .mobile-nav-button,
  .elementor-menu-toggle {
    min-width: 44px;
    min-height: 44px;
  }

  #chb-popup-root .chb-popup-card {
    max-width: calc(100vw - 24px);
    margin: 12px auto;
  }

  #chb-popup-root .chb-popup-media {
    display: none;
  }
}

/* Prevent iOS from zooming only on focus while still allowing pinch-zoom. */
input, select, textarea {
  font-size: 16px;
}
