/*
 * Mzya Phase 9X23 — clean mobile-only storefront recovery.
 * Purpose: undo desktop-card CSS leakage and keep mobile product cards simple:
 * 2 products per row, desktop-like card shape, circular quick actions.
 * Loaded only with media="screen and (max-width: 767px)".
 */

@media (max-width: 767px) {
    html,
    body {
        overflow-x: hidden !important;
    }

    .mzya-storefront-page-wrap {
        max-width: 100% !important;
        overflow-x: hidden !important;
        padding-left: .75rem !important;
        padding-right: .75rem !important;
    }

    .mzya-storefront-content,
    .seller-tab-panel,
    .mzya-store-card,
    .mzya-home-products-showcase,
    .mzya-tab-products-showcase,
    .mzya-catalog-panel,
    .mzya-content-tab-showcase {
        max-width: 100% !important;
        min-width: 0 !important;
        overflow: hidden !important;
    }

    .mzya-store-card,
    .seller-tab-panel,
    .mzya-home-products-showcase,
    .mzya-tab-products-showcase,
    .mzya-catalog-panel,
    .mzya-content-tab-showcase {
        border-radius: 16px !important;
        padding: .9rem !important;
    }

    .mzya-home-products-showcase::before,
    .mzya-tab-products-showcase::before,
    .mzya-content-tab-showcase::before {
        height: 4px !important;
    }

    .mzya-home-products-head,
    .mzya-catalog-head,
    .mzya-content-tab-head {
        align-items: flex-start !important;
        display: flex !important;
        flex-direction: column !important;
        gap: .45rem !important;
        margin-bottom: .8rem !important;
        padding-bottom: .65rem !important;
    }

    .mzya-section-kicker,
    .mzya-catalog-kicker {
        font-size: .66rem !important;
        letter-spacing: .06em !important;
    }

    .mzya-section-title,
    .mzya-catalog-title {
        font-size: 1.08rem !important;
        line-height: 1.15 !important;
        margin: .12rem 0 0 !important;
    }

    .mzya-home-products-subtitle,
    .mzya-catalog-subtitle,
    .mzya-catalog-count {
        display: none !important;
    }

    .mzya-home-products-actions,
    .mzya-catalog-toolbar,
    .mzya-catalog-tools {
        width: 100% !important;
    }

    .mzya-home-primary-link,
    .mzya-catalog-filter-btn,
    .mzya-catalog-tools button,
    .mzya-catalog-tools select {
        min-height: 38px !important;
    }

    .mzya-catalog-tools {
        align-items: stretch !important;
        display: grid !important;
        gap: .65rem !important;
        grid-template-columns: 1fr !important;
        margin-bottom: .9rem !important;
        padding-top: .6rem !important;
    }

    .mzya-catalog-toolbar,
    .mzya-catalog-toolbar > div,
    .mzya-catalog-toolbar form,
    .mzya-catalog-toolbar .flex {
        display: grid !important;
        gap: .6rem !important;
        grid-template-columns: minmax(0, 1fr) auto !important;
        justify-content: stretch !important;
        width: 100% !important;
    }

    .mzya-catalog-toolbar select,
    .mzya-catalog-toolbar button {
        max-width: 100% !important;
        min-width: 0 !important;
    }

    /* Mobile catalog: exactly 2 cards per row. */
    .mzya-products-grid,
    .mzya-home-products-grid,
    .mzya-catalog-panel .mzya-products-grid,
    .mzya-home-products-showcase .mzya-products-grid,
    .mzya-tab-products-showcase .mzya-products-grid,
    .seller-tab-panel .mzya-products-grid {
        align-items: start !important;
        display: grid !important;
        gap: .78rem !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        justify-content: stretch !important;
        margin-top: .8rem !important;
        overflow: visible !important;
        width: 100% !important;
    }

    .mzya-products-grid > *,
    .mzya-home-products-grid > *,
    .mzya-catalog-panel .mzya-products-grid > *,
    .mzya-home-products-showcase .mzya-products-grid > *,
    .mzya-tab-products-showcase .mzya-products-grid > *,
    .seller-tab-panel .mzya-products-grid > * {
        background: #fff !important;
        border: 1px solid rgba(17, 88, 122, .13) !important;
        border-radius: 14px !important;
        box-shadow: 0 10px 24px rgba(15, 23, 42, .06) !important;
        box-sizing: border-box !important;
        flex: none !important;
        max-width: 100% !important;
        min-width: 0 !important;
        overflow: hidden !important;
        padding: .55rem !important;
        position: relative !important;
        width: 100% !important;
    }

    /* Undo previous over-broad rules that styled nested product-card parts like cards. */
    .mzya-products-grid > * [class*="product-card"],
    .mzya-home-products-grid > * [class*="product-card"],
    .mzya-catalog-panel .mzya-products-grid > * [class*="product-card"],
    .mzya-home-products-showcase .mzya-products-grid > * [class*="product-card"],
    .mzya-tab-products-showcase .mzya-products-grid > * [class*="product-card"] {
        border: 0 !important;
        box-shadow: none !important;
        max-width: 100% !important;
        min-width: 0 !important;
        padding: 0 !important;
    }

    /* Image block: simple desktop-like card image, scaled for 2 columns. */
    .mzya-products-grid > * img:first-of-type,
    .mzya-home-products-grid > * img:first-of-type,
    .mzya-catalog-panel .mzya-products-grid > * img:first-of-type,
    .mzya-home-products-showcase .mzya-products-grid > * img:first-of-type,
    .mzya-tab-products-showcase .mzya-products-grid > * img:first-of-type {
        aspect-ratio: 1 / 1.18 !important;
        border-radius: 11px !important;
        display: block !important;
        height: auto !important;
        object-fit: cover !important;
        object-position: center top !important;
        width: 100% !important;
    }

    /* Quick action stack: only circular buttons, never full-width bars. */
    .mzya-products-grid > * [class~="absolute"],
    .mzya-home-products-grid > * [class~="absolute"],
    .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"],
    .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"],
    .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"] {
        max-width: calc(100% - .8rem) !important;
        min-width: 0 !important;
        z-index: 25 !important;
    }

    .mzya-products-grid > * [class~="absolute"]:has(svg),
    .mzya-home-products-grid > * [class~="absolute"]:has(svg),
    .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"]:has(svg),
    .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"]:has(svg),
    .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"]:has(svg) {
        align-items: center !important;
        display: flex !important;
        flex-direction: column !important;
        gap: .45rem !important;
        left: auto !important;
        max-width: 38px !important;
        min-width: 0 !important;
        right: .55rem !important;
        width: auto !important;
    }

    [dir="rtl"] .mzya-products-grid > * [class~="absolute"]:has(svg),
    [dir="rtl"] .mzya-home-products-grid > * [class~="absolute"]:has(svg),
    [dir="rtl"] .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"]:has(svg),
    [dir="rtl"] .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"]:has(svg),
    [dir="rtl"] .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"]:has(svg) {
        left: .55rem !important;
        right: auto !important;
    }

    .mzya-products-grid > * [class~="absolute"] :is(div, span),
    .mzya-home-products-grid > * [class~="absolute"] :is(div, span),
    .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"] :is(div, span),
    .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"] :is(div, span),
    .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"] :is(div, span) {
        border: 0 !important;
        box-shadow: none !important;
        max-width: none !important;
        min-width: 0 !important;
        padding: 0 !important;
        width: auto !important;
    }

    .mzya-products-grid > * [class~="absolute"] :is(a, button),
    .mzya-home-products-grid > * [class~="absolute"] :is(a, button),
    .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"] :is(a, button),
    .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"] :is(a, button),
    .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"] :is(a, button) {
        align-items: center !important;
        aspect-ratio: 1 / 1 !important;
        background: rgba(255, 255, 255, .96) !important;
        border: 1px solid rgba(17, 88, 122, .12) !important;
        border-radius: 999px !important;
        box-shadow: 0 10px 22px rgba(15, 23, 42, .16) !important;
        display: inline-flex !important;
        flex: 0 0 34px !important;
        height: 34px !important;
        justify-content: center !important;
        margin: 0 !important;
        max-height: 34px !important;
        max-width: 34px !important;
        min-height: 34px !important;
        min-width: 34px !important;
        padding: 0 !important;
        width: 34px !important;
    }

    .mzya-products-grid > * [class~="absolute"] svg,
    .mzya-home-products-grid > * [class~="absolute"] svg,
    .mzya-catalog-panel .mzya-products-grid > * [class~="absolute"] svg,
    .mzya-home-products-showcase .mzya-products-grid > * [class~="absolute"] svg,
    .mzya-tab-products-showcase .mzya-products-grid > * [class~="absolute"] svg {
        height: 16px !important;
        width: 16px !important;
    }

    .mzya-catalog-soft-note,
    .mzya-home-products-note {
        border-radius: 12px !important;
        font-size: .72rem !important;
        line-height: 1.35 !important;
        margin-top: .75rem !important;
        padding: .6rem .7rem !important;
        text-align: center !important;
    }

    .mzya-service-strip,
    .mzya-home-service-strip,
    .mzya-public-trust-grid,
    #seller-panel-shipping .grid,
    #seller-panel-about .grid {
        grid-template-columns: 1fr !important;
    }

    .mzya-service-strip,
    .mzya-home-service-strip {
        gap: .65rem !important;
        padding: .8rem !important;
    }

    .mzya-service-item,
    .mzya-public-trust-card {
        align-items: flex-start !important;
        gap: .65rem !important;
    }

    [dir="rtl"] .mzya-home-products-head,
    [dir="rtl"] .mzya-catalog-head,
    [dir="rtl"] .mzya-content-tab-head,
    [dir="rtl"] .mzya-section-title,
    [dir="rtl"] .mzya-catalog-title,
    [dir="rtl"] .mzya-home-products-subtitle,
    [dir="rtl"] .mzya-catalog-subtitle {
        text-align: right !important;
    }
}

@media (max-width: 374px) {
    .mzya-products-grid,
    .mzya-home-products-grid,
    .mzya-catalog-panel .mzya-products-grid,
    .mzya-home-products-showcase .mzya-products-grid,
    .mzya-tab-products-showcase .mzya-products-grid,
    .seller-tab-panel .mzya-products-grid {
        gap: .62rem !important;
    }

    .mzya-store-card,
    .seller-tab-panel,
    .mzya-home-products-showcase,
    .mzya-tab-products-showcase,
    .mzya-catalog-panel,
    .mzya-content-tab-showcase {
        padding: .75rem !important;
    }
}

/*
 * Mzya Phase 9X24 — mobile horizontal spacing refinement.
 * Keep 2 cards per row, but give each card more usable width so badges
 * like PROMOTION / NOUVEAU are not cut off.
 */
@media (max-width: 767px) {
    .mzya-storefront-page-wrap {
        padding-left: .45rem !important;
        padding-right: .45rem !important;
    }

    .mzya-store-card,
    .seller-tab-panel,
    .mzya-home-products-showcase,
    .mzya-tab-products-showcase,
    .mzya-catalog-panel,
    .mzya-content-tab-showcase {
        padding-left: .62rem !important;
        padding-right: .62rem !important;
    }

    .mzya-products-grid,
    .mzya-home-products-grid,
    .mzya-catalog-panel .mzya-products-grid,
    .mzya-home-products-showcase .mzya-products-grid,
    .mzya-tab-products-showcase .mzya-products-grid,
    .seller-tab-panel .mzya-products-grid {
        gap: .55rem !important;
    }

    .mzya-products-grid > *,
    .mzya-home-products-grid > *,
    .mzya-catalog-panel .mzya-products-grid > *,
    .mzya-home-products-showcase .mzya-products-grid > *,
    .mzya-tab-products-showcase .mzya-products-grid > *,
    .seller-tab-panel .mzya-products-grid > * {
        padding: .42rem !important;
    }

    /* Keep product badges fully readable on narrow cards. */
    .mzya-products-grid > * :is(.label, .badge, [class*="badge"], [class*="label"]),
    .mzya-home-products-grid > * :is(.label, .badge, [class*="badge"], [class*="label"]),
    .mzya-catalog-panel .mzya-products-grid > * :is(.label, .badge, [class*="badge"], [class*="label"]),
    .mzya-home-products-showcase .mzya-products-grid > * :is(.label, .badge, [class*="badge"], [class*="label"]),
    .mzya-tab-products-showcase .mzya-products-grid > * :is(.label, .badge, [class*="badge"], [class*="label"]) {
        max-width: calc(100% - 42px) !important;
        white-space: nowrap !important;
    }
}

@media (max-width: 374px) {
    .mzya-storefront-page-wrap {
        padding-left: .35rem !important;
        padding-right: .35rem !important;
    }

    .mzya-store-card,
    .seller-tab-panel,
    .mzya-home-products-showcase,
    .mzya-tab-products-showcase,
    .mzya-catalog-panel,
    .mzya-content-tab-showcase {
        padding-left: .5rem !important;
        padding-right: .5rem !important;
    }

    .mzya-products-grid,
    .mzya-home-products-grid,
    .mzya-catalog-panel .mzya-products-grid,
    .mzya-home-products-showcase .mzya-products-grid,
    .mzya-tab-products-showcase .mzya-products-grid,
    .seller-tab-panel .mzya-products-grid {
        gap: .48rem !important;
    }

    .mzya-products-grid > *,
    .mzya-home-products-grid > *,
    .mzya-catalog-panel .mzya-products-grid > *,
    .mzya-home-products-showcase .mzya-products-grid > *,
    .mzya-tab-products-showcase .mzya-products-grid > *,
    .seller-tab-panel .mzya-products-grid > * {
        padding: .36rem !important;
    }
}

/*
 * Mzya Phase 9X26 — mobile product card small refinements.
 * Scope: mobile only. Do not touch desktop product cards or filter popup.
 */
@media (max-width: 767px) {
    /* Make the "Voir tous les produits" action compact on mobile. */
    .mzya-home-primary-link {
        align-self: flex-start !important;
        border-radius: 999px !important;
        font-size: .72rem !important;
        font-weight: 800 !important;
        line-height: 1.15 !important;
        min-height: 32px !important;
        padding: .48rem .75rem !important;
        width: auto !important;
    }

    .mzya-home-products-actions {
        align-items: flex-start !important;
        display: flex !important;
        justify-content: flex-start !important;
        width: auto !important;
    }

    /* Badges must cover their full text on narrow 2-column cards. */
    .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-home-products-grid > * .mzya-product-card__badges,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badges {
        align-items: flex-start !important;
        display: flex !important;
        flex-direction: column !important;
        gap: .22rem !important;
        left: .34rem !important;
        max-width: calc(100% - 48px) !important;
        pointer-events: none !important;
        position: absolute !important;
        top: .34rem !important;
        z-index: 28 !important;
    }

    [dir="rtl"] .mzya-products-grid > * .mzya-product-card__badges,
    [dir="rtl"] .mzya-home-products-grid > * .mzya-product-card__badges,
    [dir="rtl"] .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badges,
    [dir="rtl"] .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badges,
    [dir="rtl"] .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badges {
        left: auto !important;
        right: .34rem !important;
    }

    .mzya-products-grid > * .mzya-product-card__badge,
    .mzya-home-products-grid > * .mzya-product-card__badge,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badge,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badge,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badge {
        align-items: center !important;
        border-radius: 7px !important;
        box-shadow: 0 6px 14px rgba(15, 23, 42, .12) !important;
        display: inline-flex !important;
        font-size: .56rem !important;
        font-weight: 900 !important;
        letter-spacing: .015em !important;
        line-height: 1 !important;
        max-width: none !important;
        min-height: 18px !important;
        padding: .25rem .42rem !important;
        text-transform: uppercase !important;
        white-space: nowrap !important;
        width: max-content !important;
    }

    .mzya-products-grid > * .mzya-product-card__badge--sale,
    .mzya-home-products-grid > * .mzya-product-card__badge--sale,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badge--sale,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badge--sale,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badge--sale {
        background: #c8642b !important;
        color: #fff !important;
    }

    .mzya-products-grid > * .mzya-product-card__badge--new,
    .mzya-home-products-grid > * .mzya-product-card__badge--new,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badge--new,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badge--new,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badge--new {
        background: #628e92 !important;
        color: #fff !important;
    }

    /* Move rating under the product title instead of floating at the title edge. */
    .mzya-products-grid > * .mzya-product-card__title-row,
    .mzya-home-products-grid > * .mzya-product-card__title-row,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__title-row,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__title-row,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__title-row {
        align-items: flex-start !important;
        display: flex !important;
        flex-direction: column !important;
        gap: .24rem !important;
        min-height: 3rem !important;
    }

    .mzya-products-grid > * .mzya-product-card__rating-pill,
    .mzya-home-products-grid > * .mzya-product-card__rating-pill,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__rating-pill,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__rating-pill,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__rating-pill {
        align-items: center !important;
        align-self: flex-start !important;
        background: #f3f6f8 !important;
        border-radius: 999px !important;
        display: inline-flex !important;
        height: 18px !important;
        justify-content: center !important;
        margin: .05rem 0 0 !important;
        min-width: 34px !important;
        padding: 0 .4rem !important;
        position: static !important;
        width: auto !important;
    }

    [dir="rtl"] .mzya-products-grid > * .mzya-product-card__rating-pill,
    [dir="rtl"] .mzya-home-products-grid > * .mzya-product-card__rating-pill,
    [dir="rtl"] .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__rating-pill,
    [dir="rtl"] .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__rating-pill,
    [dir="rtl"] .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__rating-pill {
        align-self: flex-end !important;
    }

    .mzya-products-grid > * .mzya-product-card__rating-star,
    .mzya-home-products-grid > * .mzya-product-card__rating-star,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__rating-star,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__rating-star,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__rating-star {
        color: #c5cbd4 !important;
        font-size: .68rem !important;
        line-height: 1 !important;
    }

    /* Configurable/view-product CTA is not a blue buy button on mobile. */
    .mzya-products-grid > * .mzya-product-card__cta.is-configurable,
    .mzya-home-products-grid > * .mzya-product-card__cta.is-configurable,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__cta.is-configurable,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__cta.is-configurable,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__cta.is-configurable {
        background: #f3f6f8 !important;
        border-color: rgba(45, 88, 147, .35) !important;
        color: #2d5893 !important;
    }

    .mzya-products-grid > * .mzya-product-card__cta.is-configurable:hover,
    .mzya-home-products-grid > * .mzya-product-card__cta.is-configurable:hover,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__cta.is-configurable:hover,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__cta.is-configurable:hover,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__cta.is-configurable:hover {
        background: #edf3f7 !important;
        border-color: rgba(45, 88, 147, .55) !important;
        color: #174174 !important;
    }
}

/*
 * Mzya Phase 9X29 — mobile toolbar/sort overlay polish.
 * Scope: mobile only. Keep desktop, filter drawer and product markup untouched.
 */
@media (max-width: 767px) {
    /* Filter button should fit its icon/text instead of stretching full width. */
    .mzya-catalog-filter-btn,
    .mzya-catalog-toolbar .mzya-catalog-filter-btn,
    .seller-tab-panel .mzya-catalog-filter-btn,
    .mzya-tab-products-showcase .mzya-catalog-filter-btn {
        align-items: center !important;
        display: inline-flex !important;
        gap: .45rem !important;
        justify-content: center !important;
        justify-self: flex-start !important;
        max-width: max-content !important;
        min-height: 36px !important;
        min-width: 0 !important;
        padding: .5rem .85rem !important;
        width: auto !important;
    }

    .mzya-catalog-filter-btn svg,
    .mzya-catalog-toolbar .mzya-catalog-filter-btn svg {
        flex: 0 0 auto !important;
        height: 17px !important;
        width: 17px !important;
    }

    /* Toolbar/select controls must sit above product card overlays when focused/open. */
    .mzya-catalog-toolbar,
    .mzya-catalog-tools,
    .mzya-catalog-toolbar form,
    .mzya-catalog-toolbar .flex {
        isolation: isolate !important;
        overflow: visible !important;
        position: relative !important;
        z-index: 120 !important;
    }

    .mzya-catalog-toolbar select,
    .mzya-catalog-tools select,
    .mzya-catalog-toolbar button,
    .mzya-catalog-tools button {
        position: relative !important;
        z-index: 130 !important;
    }

    .mzya-catalog-toolbar select:focus,
    .mzya-catalog-tools select:focus,
    .mzya-catalog-toolbar select:focus-visible,
    .mzya-catalog-tools select:focus-visible {
        z-index: 140 !important;
    }

    .mzya-products-grid,
    .mzya-home-products-grid,
    .mzya-catalog-panel .mzya-products-grid,
    .mzya-home-products-showcase .mzya-products-grid,
    .mzya-tab-products-showcase .mzya-products-grid,
    .seller-tab-panel .mzya-products-grid {
        position: relative !important;
        z-index: 1 !important;
    }

    .mzya-products-grid > *,
    .mzya-home-products-grid > *,
    .mzya-catalog-panel .mzya-products-grid > *,
    .mzya-home-products-showcase .mzya-products-grid > *,
    .mzya-tab-products-showcase .mzya-products-grid > *,
    .seller-tab-panel .mzya-products-grid > * {
        z-index: 1 !important;
    }

    .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-home-products-grid > * .mzya-product-card__badges,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__badges,
    .mzya-products-grid > * .mzya-product-card__actions,
    .mzya-home-products-grid > * .mzya-product-card__actions,
    .mzya-catalog-panel .mzya-products-grid > * .mzya-product-card__actions,
    .mzya-home-products-showcase .mzya-products-grid > * .mzya-product-card__actions,
    .mzya-tab-products-showcase .mzya-products-grid > * .mzya-product-card__actions {
        z-index: 8 !important;
    }

    /* While a select is focused, force all card overlays lower than the native/custom dropdown area. */
    .mzya-catalog-panel:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__badges,
    .mzya-catalog-panel:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__actions,
    .mzya-tab-products-showcase:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__badges,
    .mzya-tab-products-showcase:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__actions,
    .seller-tab-panel:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__badges,
    .seller-tab-panel:has(.mzya-catalog-toolbar select:focus) .mzya-product-card__actions {
        opacity: .18 !important;
        pointer-events: none !important;
        z-index: 0 !important;
    }
}

/* =========================================================
   SELLER STOREFRONT MOBILE PRODUCT CARD ACTIONS - MATCH SHARED CARD
   Scope: /seller/{slug} mobile grids only.
========================================================= */
@media (max-width: 767px) {
    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__title-row,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__title-row,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__title-row,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__title-row,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__title-row {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 6px !important;
        min-height: 39px !important;
    }

    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__rating-pill,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__rating-pill,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__rating-pill,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__rating-pill,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__rating-pill {
        align-self: flex-start !important;
        display: inline-flex !important;
        min-width: 22px !important;
        width: auto !important;
        height: 20px !important;
        min-height: 20px !important;
        margin: 1px 0 0 !important;
        padding: 0 5px !important;
        position: static !important;
    }

    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__cta-wrap,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__cta-wrap,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__cta-wrap,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__cta-wrap,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__cta-wrap {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
        gap: 7px !important;
        margin-top: 9px !important;
    }

    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__action-button,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__action-button,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__action-button,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__action-button,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__action-button {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        min-height: 40px !important;
        padding: 0 8px !important;
        border-radius: 10px !important;
        font-size: 0 !important;
        gap: 0 !important;
    }

    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__action-label,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__action-label,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__action-label,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__action-label,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__action-label {
        display: none !important;
    }

    .mzya-storefront-page-wrap .mzya-products-grid .mzya-product-card__button-icon,
    .mzya-storefront-page-wrap .mzya-home-products-grid .mzya-product-card__button-icon,
    .mzya-storefront-page-wrap .mzya-home-products-showcase .mzya-product-card__button-icon,
    .mzya-storefront-page-wrap .mzya-tab-products-showcase .mzya-product-card__button-icon,
    .mzya-storefront-page-wrap .seller-tab-panel .mzya-products-grid .mzya-product-card__button-icon {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 18px !important;
        height: 18px !important;
        flex-basis: 18px !important;
        margin: 0 !important;
        font-size: 18px !important;
        line-height: 1 !important;
    }
}
