/* =========================================================
   GLOBAL LAYOUT STABILITY (CLS FIX)
   ========================================================= */
/* === CLS FIX: Reserve space for images === */
img {
  max-width: 100%;
  height: auto;
}

/* Lazyload safety */
/*img.lazyload,
img.lazyloaded {
  width: 100%;
  height: auto;
}*/

/* Prevent layout shift from images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Reserve space for lazy-loaded images */
img[loading="lazy"] {
  min-height: 1px;
}

/* Fix product images (grid & modules) */
.product-thumb img,
.products-list img,
.product-layout img {
  aspect-ratio: 1 / 1;
}

/* =========================================================
   SLIDER & BANNER CLS FIX (SO MALLON SPECIFIC)
   ========================================================= */

/* Homepage main slider */
.so-slideshow,
.sohomepage-slider,
.so-homeslider {
  min-height: 325px;
  overflow: hidden;
}

/* Mobile slider height */
@media (max-width: 768px) {
  .so-slideshow,
  .sohomepage-slider,
  .so-homeslider {
    min-height: 260px;
  }
}

/* Prevent slider content jumping */
.so-slideshow img,
.so-homeslider img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* =========================================================
   FONT RENDERING & TEXT SHIFT FIX
   ========================================================= */

/* Prevent invisible text during font load */
body {
  font-display: swap;
  text-rendering: optimizeLegibility;
}

/* =========================================================
   REDUCE FORCED REFLOW & MAIN THREAD BLOCKING
   ========================================================= */

/* Disable heavy animations causing reflow */
.so-animate,
.wow,
[data-wow-delay],
[data-wow-duration] {
  animation: none !important;
  transition: none !important;
}

/* Disable hover animations on mobile */
@media (hover: none) {
  * {
    transition: none !important;
  }
}

/* =========================================================
   PRODUCT BLOCK STABILITY
   ========================================================= */

/* Fix product title height to avoid shift */
/*.product-thumb h4,
.product-title {
  min-height: 48px;
  overflow: hidden;
}*/



/* =========================================================
   HEADER & MENU CLS FIX
   ========================================================= */

/* Fix header height to avoid jump */
header,
#header {
  min-height: 90px;
}

/* Mobile header */
@media (max-width: 768px) {
  header,
  #header {
    min-height: 80px;
  }
}

/* =========================================================
   REMOVE NON-COMPOSITED ANIMATIONS
   ========================================================= */

.carousel-inner,
.owl-carousel,
.swiper-wrapper {
  will-change: transform;
  transform: translateZ(0);
}

/* =========================================================
   AVOID DOM SHIFT FROM HIDDEN ELEMENTS
   ========================================================= */

.hidden,
[style*="display:none"] {
  visibility: hidden;
}

/* =========================================================
   PERFORMANCE SAFETY NET
   ========================================================= */

/* Prevent content jump from dynamic elements */
/*.module,
.module h3,
.module-content {
  contain: layout style paint;
}*/

/* =========================================================
   END PERFORMANCE FIX CSS
   ========================================================= */

@font-face {
  font-family: 'FontAwesome';
  font-display: swap;
}
@font-face {
  font-family: 'Ionicons';
  font-display: swap;
}
@font-face {
  font-family: 'Material Design Icons';
  font-display: swap;
}
body {
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

html {
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}
/* ICON FALLBACK + CLS PREVENTION */
[class^="pe-7s-"],
[class*=" pe-7s-"],
[class^="icon-"],
[class*=" icon-"] {
    font-family: FontAwesome !important;
    font-style: normal;
    font-weight: normal;
}

.fa,
[class^="icon-"],
[class^="pe-7s-"] {
    width: 1em;
    height: 1em;
    display: inline-block;
    vertical-align: middle;
}

/* === CLS FIX: Extra Slider === */
.extraslider-inner,
.products-list.owl2-carousel {
  min-height: 150px;
  overflow: hidden;
}

.so-homeslider img {
  aspect-ratio: 1170 / 405;
  width: 100%;
  height: auto;
}
/* === CLS FIX: Sticky sidebar === */
#so-groups {
  min-height: 210px;
}

/* Homepage main slider height lock */
.common-home .slideshow,
.common-home .slideshow img {
  width: 100%;
  aspect-ratio: 1170 / 405;
  min-height: 405px;
  display: block;
}
/* Prevent product slider jump */
.extraslider-inner,
.owl-carousel {
  min-height: 380px;
}

.cookie-banner,
#cookie-consent {
  position: fixed;
  bottom: 0;
  width: 100%;
}
/* Reserve header space – prevents CLS */
.site-logo {
  display: inline-block;
  width: 144px;
  height: 40px;
}

.site-logo img {
  width: 100%;
  height: auto;
  display: block;
}
/* Product image wrapper MUST reserve space */
.product-image-container,
.left-block {
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

/* Product images */
.product-image-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* =====================================================
   CRITICAL CLS FIX – SO MALLON EXTRA SLIDER
   ===================================================== */

/* Reserve space BEFORE owl init */
.extraslider-inner,
.products-list.owl2-carousel {
  min-height: 380px;   /* desktop */
  overflow: hidden;
}

@media (max-width: 768px) {
  .extraslider-inner,
  .products-list.owl2-carousel {
    min-height: 260px; /* mobile */
  }
}

/* Prevent owl height jump */
.owl-stage-outer {
  min-height: inherit;
}

/* Lock product image container height */
.product-image-container {
  aspect-ratio: 1 / 1;
  width: 100%;
}

/* =====================================================
   CONTENT WRAPPER STABILITY
   ===================================================== */

#content.content-main {
  min-height: 1200px;
  overflow-anchor: none;
}

@media (max-width: 991px) {
  #content.content-main {
    min-height: 1600px;
    overflow-anchor: none;
  }
}
.autosearch-input {
  height: 38px;
  line-height: 38px;
}
/* HARD STOP: hide everything before Owl loads */
.so-homeslider .owl-item,
.so-homeslider .item {
  display: none !important;
}

/* Allow only first REAL slide */
.so-homeslider .item:first-child {
  display: block !important;
}

/* When Owl is ready, let it control layout */
.so-homeslider.owl-loaded .owl-item {
  display: block !important;
}
.so-homeslider {
  height: 405px;
  overflow: hidden;
}

@media (max-width: 768px) {
  .so-homeslider {
    height: 260px;
  }
}

/* Reserve height for Best Selling Products slider */
.so-extraslider,
.so-listing-tabs,
.module.so-extraslider {
  min-height: 380px;
}

/* Mobile */
@media (max-width: 768px) {
  .so-extraslider,
  .so-listing-tabs,
  .module.so-extraslider {
    min-height: 420px;
  }
}
.so-extraslider .products-list {
  display: flex;
  flex-wrap: nowrap;
  overflow: hidden;
}
.so-extraslider .product-item-container {
  min-height: 178px;
}