/* Category template 6982, products widget bf48ae7 only.
 * Keep existing 4 / 3 / 2 columns and gaps. Unlike 1fr's auto minimum,
 * minmax(0, 1fr) lets columns fit their actual container.
 */
body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 ul.products {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1024px) {
    body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 ul.products {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 ul.products {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 ul.products > li.product {
    min-width: 0;
    overflow-wrap: anywhere;
}

/* Keep the usable size of the native JupiterX spinner. When the row is too
 * narrow, move the add-to-cart button below it rather than squeezing controls.
 * Native DOM, values and event handlers are unchanged (including AJAX results).
 */
body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 li.product form.cart {
    /* Override the legacy high-specificity :not(...):not(...) nowrap rule. */
    flex-wrap: wrap !important;
    row-gap: 8px;
}

body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 li.product form.cart > .quantity {
    flex-shrink: 0;
}

body.tax-product_cat .elementor-6982 .elementor-element-bf48ae7 li.product form.cart > .button {
    flex-shrink: 0;
    overflow-wrap: normal;
}
