/* Xemry v3.9.14 — responsive CSS re-scoped for native WooCommerce and XLP product routes. */
/**
 * Xemry v3.9.12 — Product-page responsive overflow repair.
 * RTL/LTR-neutral and strictly scoped to single product pages.
 * Preserve gallery controls, purchase actions, product data and theme layout.
 */

/* Grid/flex items must be allowed to shrink below their content's intrinsic width.
   A translated label, supplier image or long URL must never widen the whole page. */
body.xm-product-responsive :is(
  .site-main, .luania-main, .woocommerce, .woocommerce div.product,
  .luania-product-main, .woocommerce-product-gallery, .summary.entry-summary,
  .xm-product-details, .xm-product-accordions, .xm-accordion-body,
  .xm-product-reviews, .xm-review-inner, .xm-product-category-sections,
  .xm-cat-body, .xm-products-grid, .xm-admin-arabic-copy,
  .xm-full-description-content, .woocommerce-Tabs-panel--description,
  .woocommerce-product-details__short-description
) {
  min-inline-size: 0 !important;
  max-inline-size: 100%;
  box-sizing: border-box;
}
body.xm-product-responsive .woocommerce div.product,
body.xm-product-responsive .luania-product-main {
  inline-size: 100%;
}
body.xm-product-responsive .luania-product-main {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr) !important;
}
body.xm-product-responsive .luania-product-main > :is(.woocommerce-product-gallery, .summary.entry-summary) {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
}

/* Both description render paths (theme accordion and normal WooCommerce tabs),
   including content saved in Products > Arabic Product Descriptions. */
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) {
  inline-size: 100%;
  max-inline-size: 100%;
  min-inline-size: 0;
  overflow-wrap: anywhere;
  word-break: normal;
}
/* Imported supplier HTML can set `style="width: 900px"` on nested wrappers.
   Bound rich-content blocks, not interactive gallery/variation components. */
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) :is(div, section, article, p, ul, ol, dl, blockquote, figure, table) {
  max-inline-size: 100% !important;
  min-inline-size: 0;
  box-sizing: border-box;
}
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) :is(figure, .wp-block-image, .wp-block-gallery, .wp-block-columns, .wp-block-column) {
  max-inline-size: 100% !important;
  min-inline-size: 0;
}
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) :is(img, video, iframe, embed, object) {
  max-inline-size: 100% !important;
  box-sizing: border-box;
}
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) img {
  block-size: auto !important;
}
/* Scroll an oversized comparison table or code sample *within its own area*;
   do not hide/clamp the entire viewport or interfere with image sliders. */
body.xm-product-responsive :is(
  .xm-admin-arabic-copy, .xm-full-description-content,
  .woocommerce-Tabs-panel--description, .woocommerce-product-details__short-description
) :is(table, pre) {
  display: block;
  max-inline-size: 100% !important;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Supplier galleries and review media: permit their outer grid to shrink. */
body.xm-product-responsive .woocommerce-product-gallery,
body.xm-product-responsive .woocommerce-product-gallery .flex-viewport,
body.xm-product-responsive .woocommerce-product-gallery__wrapper,
body.xm-product-responsive .woocommerce-product-gallery__image,
body.xm-product-responsive .woocommerce-product-gallery__image a,
body.xm-product-responsive .woocommerce-product-gallery .flex-control-thumbs {
  max-inline-size: 100% !important;
  min-inline-size: 0;
}
body.xm-product-responsive .woocommerce-product-gallery__image img {
  max-inline-size: 100% !important;
  block-size: auto;
  object-fit: contain;
}
body.xm-product-responsive .xm-review-inner :is(img, input, textarea, select) {
  max-inline-size: 100%;
}
body.xm-product-responsive .xm-products-grid {
  min-inline-size: 0;
  max-inline-size: 100%;
}
body.xm-product-responsive .xm-products-grid > * {
  min-inline-size: 0;
  max-inline-size: 100%;
}

/* Variable-product labels and swatches can become much longer in Arabic. */
body.xm-product-responsive .summary :is(
  form.cart, .variations_form, .variations, .single_variation_wrap,
  .woocommerce-variation-add-to-cart, .luania-option-buttons,
  .variable-items-wrapper, .luania-variation-options, .luania-variation-values
) {
  max-inline-size: 100% !important;
  min-inline-size: 0;
}
body.xm-product-responsive .summary :is(
  .luania-option-buttons, .variable-items-wrapper,
  .luania-variation-options, .luania-variation-values
) {
  flex-wrap: wrap;
}
body.xm-product-responsive .summary :is(select, input, button) {
  max-inline-size: 100%;
  box-sizing: border-box;
}
body.xm-product-responsive .summary :is(.luania-option-button, .variable-item, .luania-option) {
  max-inline-size: 100%;
  overflow-wrap: anywhere;
}

@media (max-width: 760px) {
  /* A one-column product is mandatory on narrow screens, even if the parent
     WooCommerce theme sets a fixed two-column min-width at tablet sizes. */
  body.xm-product-responsive .luania-product-main {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    grid-template-columns: minmax(0, 1fr) !important;
    min-inline-size: 0 !important;
    max-inline-size: 100% !important;
    inline-size: 100% !important;
    box-sizing: border-box;
  }
  body.xm-product-responsive .luania-product-main > :is(.woocommerce-product-gallery, .summary.entry-summary) {
    flex: 0 1 auto !important;
    inline-size: 100% !important;
    min-inline-size: 0 !important;
    margin-inline: 0 !important;
  }
  body.xm-product-responsive .summary :is(table.variations, .variations select) {
    inline-size: 100%;
    max-inline-size: 100%;
  }
  body.xm-product-responsive .summary table.variations :is(tbody, tr, th, td) {
    box-sizing: border-box;
    max-inline-size: 100%;
  }
  body.xm-product-responsive .summary table.variations :is(th,td) {
    display: block;
    inline-size: 100%;
    text-align: start;
    padding-inline: 0;
  }
  body.xm-product-responsive .summary .woocommerce-variation-add-to-cart {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
  }
  body.xm-product-responsive .summary :is(.single_add_to_cart_button, .button, .quantity) {
    max-inline-size: 100%;
  }
  body.xm-product-responsive .xm-products-grid,
  body.xm-product-responsive .woocommerce ul.products {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}
@media (max-width: 360px) {
  body.xm-product-responsive .xm-products-grid,
  body.xm-product-responsive .woocommerce ul.products {
    gap: 8px;
  }
  body.xm-product-responsive .xm-product-accordions summary,
  body.xm-product-responsive .xm-category-accordion > summary {
    min-inline-size: 0;
    overflow-wrap: anywhere;
  }
}

/**
 * Xemry v3.9.13 — single-product viewport overflow containment.
 * Fixes the missing Xemry Landing Product Pages + Elementor paths that the
 * v3.9.12 description-only patch did not cover.  No global theme changes.
 */

/* Safe last line of defense. `clip` does not create a new scroll container,
   unlike `overflow: hidden`, so sticky and vertical page scrolling survive.
   The actual content-width fixes below run first. */
html:has(> body.xm-product-responsive) {
  overflow-x: clip !important;
  max-width: 100%;
}
body.xm-product-responsive {
  margin-inline: 0 !important;
  width: 100%;
  max-width: 100%;
  overflow-x: clip !important;
}

/* Standard WooCommerce, parent Luania, this child theme, Elementor containers.
   Allow flex and grid children to shrink rather than honor min-content widths. */
body.xm-product-responsive :is(
  #page, .site, .site-content, #content, .content-area,
  .site-main, main, .luania-main, .shell, .content-wide,
  .woocommerce, .woocommerce div.product, .product.type-product,
  .luania-product-main, .woocommerce-product-gallery,
  .summary.entry-summary, .xm-product-details, .xm-product-reviews,
  .xm-product-category-sections, .xm-products-grid, .xm-cat-body,
  .elementor, .elementor-section, .elementor-container,
  .elementor-column, .elementor-widget-wrap, .elementor-widget,
  .elementor-widget-container, .e-con, .e-con-inner,
  .wp-block-group, .wp-block-columns, .wp-block-column
) {
  box-sizing: border-box;
  min-inline-size: 0 !important;
  max-inline-size: 100%;
}

/* Companion landing plugin can use xlp-* classes not present in the theme's
   ordinary .luania-product-main markup. Exclude moving slider tracks/slides. */
body.xm-product-responsive [class*="xlp-"]:not([class*="track"]):not([class*="slide"]):not([class*="carousel"]):not([class*="rail"]):not([class*="marquee"]) {
  box-sizing: border-box;
  min-inline-size: 0 !important;
  max-inline-size: 100%;
}
body.xm-product-responsive :is(
  .luania-product-main, .xlp-product-main, .xlp-product-layout,
  .xlp-product-grid, .xlp-product-container,
  .elementor-container, .e-con-inner
) > * {
  min-inline-size: 0;
  box-sizing: border-box;
}

/* Preserve desktop two-column presentation but permit both columns to shrink.
   Fix the upstream 350px minimum in product-bundle.css at intermediate widths. */
@media (min-width: 901px) {
  body.xm-refined.single-product .luania-product-main {
    grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr) !important;
  }
  body.xm-product-responsive :is(.xlp-product-layout, .xlp-product-main) {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  }
}
@media (max-width: 900px) {
  body.xm-refined.single-product .luania-product-main {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    grid-template-columns: minmax(0,1fr) !important;
    inline-size: 100%;
    min-inline-size: 0 !important;
  }
  body.xm-refined.single-product .luania-product-main > :is(.woocommerce-product-gallery, .summary.entry-summary) {
    flex: 0 1 auto !important;
    min-inline-size: 0 !important;
    max-inline-size: 100% !important;
    inline-size: 100% !important;
    margin-inline: 0 !important;
  }
  body.xm-product-responsive :is(.xlp-product-main, .xlp-product-layout, .xlp-product-grid) {
    grid-template-columns: minmax(0,1fr) !important;
  }
}

/* Never allow fixed-width supplier markup or text to expand the viewport. */
body.xm-product-responsive :is(
  .entry-content, .woocommerce-product-details__short-description,
  .woocommerce-Tabs-panel, .woocommerce-Tabs-panel--description,
  .xm-full-description-content, .xm-admin-arabic-copy,
  .xm-accordion-body, .xlp-description, .xlp-tab-content,
  .xlp-product-description, .product-description,
  .elementor-widget-text-editor, .wp-block-post-content
) {
  min-inline-size: 0 !important;
  max-inline-size: 100%;
  overflow-wrap: anywhere;
  word-break: normal;
}
body.xm-product-responsive :is(
  .entry-content, .woocommerce-product-details__short-description,
  .woocommerce-Tabs-panel, .xm-full-description-content,
  .xm-admin-arabic-copy, .xm-accordion-body,
  .xlp-description, .xlp-tab-content, .xlp-product-description,
  .elementor-widget-text-editor
) :is(div, section, article, figure, p, ul, ol, dl, blockquote) {
  box-sizing: border-box;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  overflow-wrap: anywhere;
}
body.xm-product-responsive :is(main, .site-main, #content) :is(img, video, iframe, embed, object) {
  box-sizing: border-box;
  max-inline-size: 100% !important;
}
body.xm-product-responsive :is(main, .site-main, #content) img {
  block-size: auto;
}
/* Elementor HTML/widgets can nest a fixed pixel width directly below the
   widget container without a WooCommerce description class. */
body.xm-product-responsive .elementor-widget-container > :not(.swiper-wrapper):not(.slick-track):not(.splide__list),
body.xm-product-responsive .elementor-widget-html :is(div, section, article, figure),
body.xm-product-responsive .elementor-widget-text-editor :is(div, section, article, figure) {
  max-inline-size: 100% !important;
  min-inline-size: 0 !important;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}
body.xm-product-responsive :is(.wp-block-embed, .wp-block-video, .wp-block-image, .wp-block-gallery) {
  max-inline-size: 100%;
  min-inline-size: 0;
}

/* HTML descriptions: fit content instead of creating a second horizontal
   scrollbar. Tables remain tables (headers/column relationships preserved). */
body.xm-product-responsive :is(
  .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .entry-content, .xlp-description,
  .xlp-product-description, .elementor-widget-text-editor
) :is(table, pre) {
  max-inline-size: 100% !important;
  min-inline-size: 0 !important;
}
body.xm-product-responsive :is(
  .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .entry-content, .xlp-description,
  .xlp-product-description, .elementor-widget-text-editor
) table {
  display: table;
  inline-size: 100% !important;
  table-layout: fixed;
  border-collapse: collapse;
}
body.xm-product-responsive :is(
  .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .entry-content, .xlp-description,
  .xlp-product-description, .elementor-widget-text-editor
) :is(td, th) {
  min-inline-size: 0 !important;
  overflow-wrap: anywhere;
  white-space: normal;
}
body.xm-product-responsive :is(
  .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .entry-content, .xlp-description,
  .xlp-product-description, .elementor-widget-text-editor
) pre {
  white-space: pre-wrap !important;
  overflow-wrap: anywhere;
}

/* Details, attribute selectors, reviews, image galleries, upsells and cards. */
body.xm-product-responsive :is(
  .woocommerce-product-gallery, .woocommerce-product-gallery .flex-viewport,
  .woocommerce-product-gallery__wrapper, .woocommerce-product-gallery__image,
  .xlp-gallery, .xlp-gallery-main, .xlp-gallery-thumbs,
  .xlp-product-summary, .xm-review-inner, .woocommerce-Reviews,
  form.cart, .variations_form, .single_variation_wrap,
  .woocommerce-variation-add-to-cart, .xm-product-accordions,
  .woocommerce .related, .woocommerce .upsells,
  .woocommerce ul.products, .xm-products-grid
) {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  box-sizing: border-box;
}
body.xm-product-responsive :is(form.cart, .variations_form, .single_variation_wrap, .woocommerce-variation-add-to-cart) :is(input, select, textarea, button) {
  min-inline-size: 0;
  max-inline-size: 100%;
  box-sizing: border-box;
}
body.xm-product-responsive :is(.woocommerce-product-gallery, .xlp-gallery, .xlp-gallery-main) :is(.flex-viewport, .swiper, .swiper-container, .slick-list, .splide__track) {
  max-inline-size: 100%;
  overflow: hidden;
}
/* Do NOT limit the dimensions of .slick-track/.swiper-wrapper/flexslider slides;
   their oversize inner tracks are necessary for touch/swipe animations. */
body.xm-product-responsive :is(.woocommerce ul.products, .xm-products-grid, .xlp-products-grid) > li,
body.xm-product-responsive :is(.woocommerce ul.products, .xm-products-grid, .xlp-products-grid) > div {
  min-inline-size: 0;
  max-inline-size: 100%;
}

/* Site header must not stretch just because product-specific JS/widgets load. */
@media(max-width: 720px) {
  body.xm-product-responsive .xm-header-shell { min-inline-size: 0; max-inline-size: 100%; }
  body.xm-product-responsive .xm-header-actions { min-inline-size: 0; }
  body.xm-product-responsive .woocommerce ul.products,
  body.xm-product-responsive .xm-products-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  body.xm-product-responsive :is(.summary.entry-summary, .xm-accordion-body, .xm-cat-body) {
    min-inline-size: 0;
    max-inline-size: 100%;
  }
}



/** Xemry v3.9.14 — responsive scope for XLP custom product routes.
 * The theme detects XLP pages with xlp_is_enabled_product(); they are not
 * guaranteed to have WordPress's .single-product body class. All rules below
 * use the explicit .xm-product-responsive class added by functions.php.
 */
html:has(> body.xm-product-responsive) {
  inline-size: 100%;
  max-inline-size: 100%;
  overflow-x: clip !important;
}
body.xm-product-responsive {
  inline-size: 100% !important;
  max-inline-size: 100% !important;
  margin-inline: 0 !important;
  overflow-x: clip !important;
}
body.xm-product-responsive :is(
  #page, .site, .site-content, #content, .content-area, .site-main, main,
  .shell, .content-wide, .woocommerce, .product, .product.type-product,
  .xlp, [class*="xlp-product"], [class*="xlp-page"],
  .elementor, .elementor-section, .elementor-container, .elementor-column,
  .elementor-widget-wrap, .elementor-widget, .elementor-widget-container,
  .e-con, .e-con-inner, .wp-block-group, .wp-block-columns, .wp-block-column
) {
  box-sizing: border-box !important;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
}
/* Landing-page layout wrappers: shrink columns before they can widen the page. */
body.xm-product-responsive :is(
  .xlp-product-page, .xlp-product-shell, .xlp-product-wrapper,
  .xlp-product-container, .xlp-product-layout, .xlp-product-main,
  .xlp-product-grid, .xlp-product-content, .xlp-product-body,
  .luania-product-main, .woocommerce div.product
) {
  inline-size: 100% !important;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  box-sizing: border-box !important;
}
body.xm-product-responsive :is(
  .xlp-product-page, .xlp-product-shell, .xlp-product-wrapper,
  .xlp-product-container, .xlp-product-layout, .xlp-product-main,
  .xlp-product-grid, .luania-product-main
) > * {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  box-sizing: border-box !important;
}
/* Preserve two-column product presentation on wide screens. */
@media (min-width: 1025px) {
  body.xm-product-responsive :is(.xlp-product-layout, .xlp-product-main, .luania-product-main) {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  }
}
/* Tablets and phones use a single product column; purchase controls can wrap. */
@media (max-width: 1024px) {
  body.xm-product-responsive :is(.xlp-product-layout, .xlp-product-main, .luania-product-main) {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    inline-size: 100% !important;
    min-inline-size: 0 !important;
    max-inline-size: 100% !important;
    gap: clamp(14px, 3vw, 24px) !important;
  }
  body.xm-product-responsive :is(
    .xlp-product-gallery, .xlp-gallery, .xlp-gallery-main,
    .xlp-product-summary, .xlp-product-info, .xlp-product-details,
    .woocommerce-product-gallery, .summary.entry-summary
  ) {
    flex: 0 1 auto !important;
    inline-size: 100% !important;
    min-inline-size: 0 !important;
    max-inline-size: 100% !important;
    margin-inline: 0 !important;
  }
}
/* Media and images must fit their containing column, including inline widths. */
body.xm-product-responsive :is(
  main, #content, .site-main, .xlp-product-page, .xlp-product-content,
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .elementor-widget-container, .entry-content, .xm-full-description-content
) :is(img, picture, video, iframe, embed, object, canvas) {
  box-sizing: border-box !important;
  max-inline-size: 100% !important;
}
body.xm-product-responsive :is(img, picture, video, iframe, embed, object, canvas) {
  max-inline-size: 100% !important;
}
body.xm-product-responsive :is(img, picture img) {
  block-size: auto;
}
/* Text, rich content, imported HTML, and Arabic copy must not impose min-content width. */
body.xm-product-responsive :is(
  h1, h2, h3, h4, p, li, a, span, strong, small, label, dt, dd,
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .xlp-product-title, .product_title, .entry-content,
  .woocommerce-product-details__short-description,
  .xm-full-description-content, .xm-admin-arabic-copy
) {
  min-inline-size: 0;
  max-inline-size: 100%;
  overflow-wrap: anywhere;
}
/* Wide tables and code stay inside the description instead of widening the page. */
body.xm-product-responsive :is(
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .entry-content, .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .elementor-widget-text-editor
) :is(table, pre) {
  display: block;
  inline-size: 100% !important;
  max-inline-size: 100% !important;
  min-inline-size: 0 !important;
  box-sizing: border-box;
}
body.xm-product-responsive :is(
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .entry-content, .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .elementor-widget-text-editor
) table {
  table-layout: fixed !important;
  border-collapse: collapse;
}
body.xm-product-responsive :is(
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .entry-content, .xm-full-description-content, .xm-admin-arabic-copy,
  .woocommerce-Tabs-panel, .elementor-widget-text-editor
) :is(td, th) {
  min-inline-size: 0 !important;
  white-space: normal !important;
  overflow-wrap: anywhere;
}
body.xm-product-responsive :is(
  .xlp-description, .xlp-product-description, .xlp-tab-content,
  .entry-content, .xm-full-description-content, .xm-admin-arabic-copy
) pre {
  white-space: pre-wrap !important;
  overflow-wrap: anywhere;
}
/* Swatches and purchase forms may wrap; their values and controls stay interactive. */
body.xm-product-responsive :is(
  form.cart, .variations_form, .variations, .single_variation_wrap,
  .woocommerce-variation-add-to-cart, .xlp-variations, .xlp-variation-options,
  .xlp-swatches, .variable-items-wrapper, .luania-option-buttons
) {
  box-sizing: border-box;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  flex-wrap: wrap;
}
body.xm-product-responsive :is(
  form.cart, .variations_form, .single_variation_wrap,
  .woocommerce-variation-add-to-cart, .xlp-variations, .xlp-variation-options
) :is(input, select, textarea, button) {
  box-sizing: border-box;
  min-inline-size: 0;
  max-inline-size: 100%;
}
/* Keep carousel tracks free to animate, but constrain their viewports. */
body.xm-product-responsive :is(
  .woocommerce-product-gallery, .xlp-gallery, .xlp-gallery-main,
  .xlp-gallery-thumbs, .xlp-carousel, .xlp-slider, .swiper, .swiper-container,
  .slick-list, .splide__track, .flex-viewport
) {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  overflow: hidden;
  box-sizing: border-box;
}
body.xm-product-responsive :is(
  .swiper-wrapper, .slick-track, .splide__list, .flickity-slider,
  .flex-control-nav, .swiper-slide, .slick-slide, .splide__slide
) {
  /* Intentionally do not clamp moving track widths or slide widths. */
  min-inline-size: initial;
}
/* Related-product cards: keep the card grid inside the page at every breakpoint. */
body.xm-product-responsive :is(.xm-products-grid, .xlp-products-grid, .woocommerce ul.products) {
  inline-size: 100% !important;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}
body.xm-product-responsive :is(.xm-products-grid, .xlp-products-grid, .woocommerce ul.products) > * {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
}
@media (max-width: 380px) {
  body.xm-product-responsive :is(.xm-products-grid, .xlp-products-grid, .woocommerce ul.products) {
    gap: 8px !important;
  }
  body.xm-product-responsive :is(.xm-product-accordions summary, .xlp-accordion summary) {
    min-inline-size: 0;
    overflow-wrap: anywhere;
  }
}

/* Responsive product recommendations and related-product cards. */
body.xm-product-responsive :is(
  .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
  .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
  .woocommerce ul.products
) {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: clamp(8px, 1.6vw, 18px) !important;
  inline-size: 100% !important;
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
}
body.xm-product-responsive :is(
  .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
  .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
  .woocommerce ul.products
) > * {
  min-inline-size: 0 !important;
  max-inline-size: 100% !important;
  inline-size: auto !important;
}
body.xm-product-responsive :is(
  .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
  .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
  .woocommerce ul.products
) img {
  display: block;
  inline-size: 100% !important;
  max-inline-size: 100% !important;
  block-size: auto;
  object-fit: contain;
}
@media (max-width: 900px) {
  body.xm-product-responsive :is(
    .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
    .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
    .woocommerce ul.products
  ) {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}
@media (max-width: 640px) {
  body.xm-product-responsive :is(
    .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
    .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
    .woocommerce ul.products
  ) {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  body.xm-product-responsive :is(.xlp-product-title, .xlp-product-summary h1, .product_title) {
    font-size: clamp(1.35rem, 5.2vw, 2rem) !important;
    line-height: 1.2 !important;
    letter-spacing: normal;
  }
  body.xm-product-responsive :is(.xlp-product-summary, .summary.entry-summary) form.cart {
    display: flex;
    flex-wrap: wrap !important;
    align-items: center;
    gap: 10px;
  }
  body.xm-product-responsive :is(.xlp-product-summary, .summary.entry-summary) form.cart :is(.quantity, input.qty, button, .single_add_to_cart_button) {
    max-inline-size: 100% !important;
  }
}
@media (max-width: 360px) {
  body.xm-product-responsive :is(
    .xlp-related-grid, .xlp-related-products, .xlp-related-products-grid,
    .xlp-upsells-grid, .xlp-cross-sells-grid, .xm-products-grid,
    .woocommerce ul.products
  ) {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}
