/*
Theme Name: Hello Poostina Child
Description: چایلدتم ماژولار پوستینا برای Elementor و WooCommerce با صفحات فروشگاهی، محصول، سبد خرید و تسویه‌حساب.
Author: Poostina
Template: hello-elementor
Version: 0.37.13
Requires at least: 6.8
Requires PHP: 8.1
Text Domain: hello-poostina-child
*/


:root {
  --pst-z-dropdown: 100000;
  --pst-z-sticky: 110000;
  --pst-z-drawer: 130000;
  --pst-z-modal: 140000;
  --pst-z-toast: 150000;
}

/* Poostina 0.15.25: redesigned OTP administration dashboard.
 * Previous footer update: responsive visibility controls and Peyda typography for Elementor footer. */
.elementor-widget-loop-carousel .swiper-slide,
.elementor-widget-loop-carousel .e-loop-item,
.elementor-widget-loop-carousel .product {
  -webkit-tap-highlight-color: transparent;
}

.elementor-widget-loop-carousel .poostina-cart-control,
.elementor-widget-loop-carousel .poostina-cart-control button {
  touch-action: manipulation;
}


/* 0.15.31 — prevent page/footer sections from covering sticky Elementor header */
.elementor-location-header,
[data-elementor-type="header"],
header.site-header,
#masthead,
.elementor-location-header .elementor-sticky,
[data-elementor-type="header"] .elementor-sticky,
.elementor-location-header .elementor-sticky--active,
[data-elementor-type="header"] .elementor-sticky--active {
  z-index: var(--pst-z-sticky) !important;
}
.elementor-location-footer,
.poostina-footer,
footer.site-footer {
  position: relative;
  z-index: 0;
}

/* =========================================================
   0.20.0 — event-scoped horizontal viewport containment
   The root is clipped only while a transient mobile commerce layer is active.
   This avoids a permanent scroll/positioning side effect on normal pages while
   retaining the Android overflow safeguard for overlays, detached carts and toasts.
========================================================= */
@media (max-width: 767px) {
  body > .poostina-cart-request-overlay,
  body > .poostina-slide-cart-portal-root,
  body > .poostina-slide-cart-toast-root,
  body > .poostina-product-toast-root,
  body > .poostina-list-toast-root {
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }
}

/* Android Chrome can expose one wide compositor frame while a Woo notice or
 * detached cart layer is inserted. `clip` prevents a page-level horizontal
 * scroll range without creating the scrolling ancestor that `hidden` does, so
 * sticky/fixed Elementor sections remain stable. Horizontal carousels keep
 * their own scoped overflow containers. */
@media (max-width: 767px) {
  html,
  body {
    max-width: 100%;
    overflow-x: clip;
  }
}

/* Keep the same invariant during mixed CDN-cache deployments. */
html.poostina-transient-layer-active,
body.poostina-transient-layer-active {
  max-width: 100% !important;
  overflow-x: clip !important;
  overscroll-behavior-x: none;
}

/* =========================================================
   0.35.1 — Android-safe containment for dynamic Woo notices.
   Some add-to-cart paths can inject a native WooCommerce notice outside the
   dedicated Poostina toast layer. These rules keep that notice inside the
   layout viewport without globally hiding horizontal overflow.
========================================================= */
@media (max-width: 767px) {
  body .woocommerce-notices-wrapper,
  body .woocommerce-NoticeGroup,
  body .woocommerce-message,
  body .woocommerce-error,
  body .woocommerce-info {
    box-sizing: border-box !important;
    min-width: 0 !important;
    max-width: 100% !important;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  body .woocommerce-message > *,
  body .woocommerce-error > *,
  body .woocommerce-info > *,
  body .woocommerce-message a,
  body .woocommerce-error a,
  body .woocommerce-info a,
  body .woocommerce-message .button,
  body .woocommerce-error .button,
  body .woocommerce-info .button {
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
}

/* =========================================================
   0.37.0 — safe performance CSS (merged from a separate request)
========================================================= */
.elementor-widget-loop-carousel .swiper-slide,
.elementor-widget-nested-carousel .swiper-slide,
.elementor-widget-image-carousel .swiper-slide {
  -webkit-user-select: none;
  user-select: none;
}

.elementor-widget-loop-carousel img,
.elementor-widget-image-carousel img {
  display: block;
  max-width: 100%;
}

html body .poostina-product-toast,
html body .poostina-product-toast *,
html body .poostina-list-toast,
html body .poostina-list-toast *,
html body .poostina-slide-cart-toast,
html body .poostina-slide-cart-toast * {
  font-family: "peyda-reg", Tahoma, Arial, sans-serif !important;
}

@media (max-width: 767px) {
  html body .poostina-product-toast-root,
  html body .poostina-list-toast-root,
  html body .poostina-slide-cart-toast-root {
    min-width: 0 !important;
    margin-inline: 0 !important;
    box-sizing: border-box !important;
  }

  .poostina-product-toast,
  .poostina-list-toast,
  .poostina-slide-cart-toast {
    will-change: auto !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

@supports (content-visibility: auto) {
  body.poostina-single-performance .elementor-widget-poostina-single-highlights,
  body.poostina-single-performance .elementor-widget-poostina-single-quick-specs,
  body.poostina-single-performance .elementor-widget-poostina-single-trust-badges,
  body.poostina-single-performance .elementor-widget-poostina-single-product-tabs {
    content-visibility: auto;
    contain-intrinsic-size: auto 420px;
  }
}
