/* Desktop listings share one grid; card width is controlled by admin settings. */
@media (min-width: 769px) {
    .product-list-grid {
        display: grid !important;
        grid-template-columns: repeat(auto-fill, minmax(0, min(100%, var(--desktop-product-card-width, 280px)))) !important;
        gap: var(--desktop-product-card-gap, 16px) !important;
        justify-content: start !important;
        align-items: stretch !important;
        min-width: 0;
        margin: 0 !important;
    }
    .product-list-grid > [class*="col-"] {
        display: flex;
        width: auto !important;
        min-width: 0;
        max-width: 100%;
        padding: 0 !important;
        margin: 0 !important;
    }
    .product-list-grid .product-card-std:not(.is-home-card):not(.is-related-card) {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
    }
}

    /* ===== تگ‌های روی تصویر محصول ===== */
    .product-badges-container {
        position: absolute !important;
        top: calc(6px + var(--card-tag-radius, 12px) * .3) !important;
        right: calc(6px + var(--card-tag-radius, 12px) * .3) !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 4px !important;
        z-index: 10 !important;
        pointer-events: none;
    }

    .product-badge-item {
        font-size: 9px !important;
        padding: 2px 6px !important;
        border-radius: 4px !important;
        font-weight: bold !important;
        color: white !important;
        box-shadow: none !important;
        white-space: nowrap !important;
        line-height: 1.2 !important;
    }

    .product-badge-campaign {
        background: var(--campaign-badge-background, #7C3AED) !important;
        color: var(--campaign-badge-text, #FFFFFF) !important;
        font-size: var(--campaign-badge-font-desktop, 9px) !important;
        border-radius: var(--campaign-badge-radius-desktop, 4px) !important;
    }

    @media (max-width: 768px) {
        .product-badge-campaign {
            font-size: var(--campaign-badge-font-mobile, 9px) !important;
            border-radius: var(--campaign-badge-radius-mobile, 4px) !important;
        }
    }

    /* ===== نشانگرهای وضعیت فروش در جایگاه قیمت ===== */
    .out-of-stock-tag {
        display: inline-block !important;
        background-color: var(--tag-out-of-stock-color) !important;
        color: var(--tag-out-of-stock-text) !important;
        font-size: var(--tag-out-of-stock-font-size, 11px) !important;
        font-weight: bold !important;
        padding: 3px 8px !important;
        border-radius: var(--tag-out-of-stock-radius, 4px) !important;
        line-height: 1.2 !important;
    }
    .out-of-stock-tag.sales-hold-tag {
        background-color: var(--tag-sales-hold-color) !important;
        color: var(--tag-sales-hold-text) !important;
        font-size: var(--tag-sales-hold-font-size, 11px) !important;
        border-radius: var(--tag-sales-hold-radius, 4px) !important;
    }

    /* ===== استایل پایه کارت ===== */
    .product-card-std {
        display: flex !important;
        background: var(--product-info-background, #ffffff) !important;
        border: 1px solid rgba(0,0,0,0.06) !important;
        border-radius: 12px !important;
        overflow: hidden !important;
        box-shadow: none !important;
        text-decoration: none !important;
        color: inherit !important;
        position: relative !important;
        box-sizing: border-box !important;
        margin: 0 !important;
    }

    /* ===== ۱) کارت‌های صفحه اصلی؛ اندازه‌ها از پنل ادمین می‌آیند ===== */
    .product-card-std.is-home-card {
        flex-direction: column !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
    }

    /* ===== ۲) کارت فهرست در دسکتاپ ===== */
    @media (min-width: 769px) {

        .product-card-std.is-home-card {
            width: var(--home-desktop-card-width, 220px) !important;
            min-width: var(--home-desktop-card-width, 220px) !important;
            max-width: var(--home-desktop-card-width, 220px) !important;
            border-radius: var(--home-desktop-card-radius, 12px) !important;
        --card-tag-radius: var(--home-desktop-card-radius, 12px);
        }
        .product-card-std.is-home-card .std-img-wrapper {
            width: 100% !important;
            height: auto !important;
            aspect-ratio: var(--home-desktop-image-ratio, 1) !important;
        }
        .product-card-std.is-home-card .std-card-body {
            width: 100% !important;
            height: auto !important;
            min-height: var(--home-desktop-info-min-height, 96px) !important;
            padding: 10px 12px !important;
        }
        .product-card-std.is-home-card .std-product-name {
            font-size: var(--home-desktop-name-size, 14px) !important;
            line-height: 1.45 !important;
        }
        .product-card-std.is-home-card .std-price-main {
            font-size: var(--home-desktop-price-size, 15px) !important;
        }
        .product-card-std.is-home-card .std-price-old {
            font-size: var(--home-desktop-old-price-size, 11px) !important;
        }

        .product-card-std:not(.is-home-card) {
            flex-direction: column !important;
            width: var(--desktop-product-card-width, 280px) !important;
            min-width: var(--desktop-product-card-width, 280px) !important;
            max-width: var(--desktop-product-card-width, 280px) !important;
            height: auto !important;
            min-height: 0 !important;
            max-height: none !important;
            border-radius: var(--desktop-product-card-radius, 12px) !important;
        --card-tag-radius: var(--desktop-product-card-radius, 12px);
        }
        .product-card-std:not(.is-home-card) .std-img-wrapper {
            width: 100% !important;
            height: auto !important;
            aspect-ratio: var(--desktop-product-image-ratio, 1) !important;
        }
        .product-card-std:not(.is-home-card) .std-card-body {
            width: 100% !important;
            height: auto !important;
            min-height: var(--desktop-product-info-min-height, 104px) !important;
            padding: 12px 14px !important;
        }
        .product-card-std:not(.is-home-card) .std-product-name {
            font-size: var(--desktop-product-name-size, 15px) !important;
            line-height: 1.45 !important;
        }
        .product-card-std:not(.is-home-card) .std-price-main {
            font-size: var(--desktop-product-price-size, 16px) !important;
        }
        .product-card-std:not(.is-home-card) .std-price-old {
            font-size: var(--desktop-product-old-price-size, 12px) !important;
        }
        .product-card-std:not(.is-home-card) .out-of-stock-tag {
            font-size: 13px !important;
            padding: 4px 10px !important;
        }
    }

    /* ===== ۳) موبایل: شبکه دو ستونه، تصویر بالا و نام/قیمت زیر ===== */
    @media (max-width: 768px) {
        .product-card-std.is-home-card {
            width: var(--home-mobile-card-width, 160px) !important;
            min-width: var(--home-mobile-card-width, 160px) !important;
            max-width: var(--home-mobile-card-width, 160px) !important;
            border-radius: var(--home-mobile-card-radius, 12px) !important;
        --card-tag-radius: var(--home-mobile-card-radius, 12px);
        }
        .product-card-std.is-home-card .std-img-wrapper {
            width: 100% !important;
            height: auto !important;
            aspect-ratio: var(--home-mobile-image-ratio, 1) !important;
        }
        .product-card-std.is-home-card .std-card-body {
            width: 100% !important;
            height: auto !important;
            min-height: var(--home-mobile-info-min-height, 88px) !important;
            padding: 8px 10px !important;
        }
        .product-card-std.is-home-card .std-product-name {
            font-size: var(--home-mobile-name-size, 12px) !important;
            line-height: 1.45 !important;
        }
        .product-card-std.is-home-card .std-price-main {
            font-size: var(--home-mobile-price-size, 13px) !important;
        }
        .product-card-std.is-home-card .std-price-old {
            font-size: var(--home-mobile-old-price-size, 10px) !important;
        }

        .products-grid-container[data-mobile-showcase-feed],
        .products-list-wrapper[data-mobile-showcase-feed],
        .row[data-mobile-showcase-feed],
        .products-grid-container[data-mobile-card-feed],
        .products-list-wrapper[data-mobile-card-feed],
        .row[data-mobile-card-feed] {
            --bs-gutter-x: 0 !important;
            --bs-gutter-y: 0 !important;
            display: grid !important;
            grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
            column-gap: var(--mobile-product-column-gap) !important;
            row-gap: var(--mobile-product-row-gap) !important;
            align-items: stretch !important;
            width: 100vw !important;
            max-width: 100vw !important;
            margin-top: 0 !important;
            margin-left: calc(50% - 50vw) !important;
            margin-right: calc(50% - 50vw) !important;
            padding-left: var(--mobile-product-page-gutter) !important;
            padding-right: var(--mobile-product-page-gutter) !important;
            box-sizing: border-box !important;
        }

        .row[data-mobile-showcase-feed] > [class*="col-"],
        .row[data-mobile-card-feed] > [class*="col-"] {
            width: auto !important;
            max-width: none !important;
            flex: none !important;
            padding-left: 0 !important;
            padding-right: 0 !important;
            margin-top: 0 !important;
            display: flex !important;
            align-self: stretch !important;
        }

        .row[data-mobile-showcase-feed] > [class*="col-"] > .product-card-std:not(.is-home-card),
        .row[data-mobile-card-feed] > [class*="col-"] > .product-card-std:not(.is-home-card) {
            height: 100% !important;
        }

        .product-card-std:not(.is-home-card) {
            flex-direction: column !important;
            width: 100% !important;
            min-width: 0 !important;
            max-width: none !important;
            height: auto !important;
            min-height: 0 !important;
            max-height: none !important;
            direction: rtl !important;
            margin: 0 !important;
            border-color: var(--mobile-product-card-border-color) !important;
            border-radius: var(--mobile-product-card-radius) !important;
        --card-tag-radius: var(--mobile-product-card-radius);
            background: var(--mobile-product-card-background) !important;
        }

        .product-card-std:not(.is-home-card) .std-img-wrapper {
            width: 100% !important;
            min-width: 0 !important;
            max-width: none !important;
            height: auto !important;
            aspect-ratio: var(--mobile-product-image-ratio) !important;
        }

        .product-card-std:not(.is-home-card) .std-card-body {
            width: 100% !important;
            height: auto !important;
            min-height: var(--mobile-product-info-min-height) !important;
            padding: 0 8px !important;
            justify-content: space-evenly !important;
            gap: 0 !important;
            flex: 1 1 auto !important;
            background: var(--mobile-product-card-background) !important;
        }

        .product-card-std:not(.is-home-card) .std-product-name {
            font-size: var(--mobile-product-name-size) !important;
            line-height: 1.45 !important;
            min-height: 0 !important;
            text-align: var(--mobile-product-name-align) !important;
            display: -webkit-box !important;
            -webkit-line-clamp: 2 !important;
            -webkit-box-orient: vertical !important;
            overflow: hidden !important;
            text-overflow: ellipsis !important;
            word-break: normal !important;
            overflow-wrap: break-word !important;
        }

        .product-card-std:not(.is-home-card) .std-price-block {
            margin-top: 0 !important;
            text-align: var(--mobile-product-price-align) !important;
        }

        .product-card-std:not(.is-home-card) .std-price-main {
            font-size: var(--mobile-product-price-size) !important;
            color: var(--mobile-product-current-price-color) !important;
        }

        .product-card-std:not(.is-home-card) .std-price-old {
            font-size: var(--mobile-product-old-price-size) !important;
            color: var(--mobile-product-old-price-color) !important;
            text-decoration-color: var(--mobile-product-old-price-strike-color) !important;
        }

        .product-card-std:not(.is-home-card) .std-price-final-row {
            gap: 4px !important;
            justify-content: var(--mobile-product-price-justify) !important;
        }

        .product-card-std:not(.is-home-card) .std-discount-percent {
            min-width: 26px !important;
            height: 18px !important;
            padding: 1px 4px !important;
            font-size: var(--mobile-product-discount-badge-font-size) !important;
            border-radius: var(--mobile-product-discount-badge-radius) !important;
            background: var(--mobile-product-discount-badge-bg) !important;
            color: var(--mobile-product-discount-badge-text) !important;
        }

        .product-card-std:not(.is-home-card) .out-of-stock-tag {
            font-size: 10px !important;
            padding: 3px 6px !important;
        }
    }

    /* ===== استایل‌های ثابت تصویر و محتوا ===== */
    .std-img-wrapper {
        position: relative !important;
        overflow: hidden !important;
        background: var(--product-image-background, #ffffff) !important;
        margin: 0 !important;
        padding: 0 !important;
        flex-shrink: 0 !important;
        aspect-ratio: 1 / 1 !important;
    }

    .std-img-wrapper img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        display: block !important;
        border: none !important;
    }

    .std-card-body {
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
        text-align: right !important;
        box-sizing: border-box !important;
        background: var(--product-info-background, #ffffff) !important;
    }

    .std-product-name {
        font-weight: bold !important;
        color: #222222 !important;
        margin: 0 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }


    .std-price-main {
        font-weight: bold !important;
        color: #111111 !important;
        line-height: 1.2 !important;
        white-space: nowrap !important;
    }

    .std-price-old {
        font-size: 10px !important;
        color: #a0a0a0 !important;
        text-decoration: line-through !important;
        line-height: 1.2 !important;
    }

    /* Discount row: percentage stays on the visual right of the final price. */
    .std-price-final-row {
        display: flex !important;
        flex-direction: row !important;
        direction: rtl !important;
        justify-content: flex-start !important;
        align-items: center !important;
        gap: 6px !important;
        margin-top: 2px !important;
    }

    .std-discount-percent {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 30px !important;
        padding: 1px 6px !important;
        border-radius: 999px !important;
        background: var(--semantic-danger) !important;
        color: #ffffff !important;
        /* Use the exact same Persian UI font inherited by the card/site. */
        font-family: inherit !important;
        font-size: 14px !important;
        font-weight: 700 !important;
        line-height: 1 !important;
        height: 22px !important;
        box-sizing: border-box !important;
        white-space: nowrap !important;
        text-align: center !important;
        /* Keep Persian percent sign visually on the RIGHT of the digits. */
        direction: ltr !important;
        unicode-bidi: isolate !important;
        gap: 1px !important;
    }

/* ===== Mobile Product Showcase Card ===== */
.std-card-standard {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    min-width: 0;
}

.mobile-showcase-card,
.mobile-horizon-card {
    display: none;
}

@media (max-width: 768px) {
    /* Bootstrap row surfaces wrap each card in .col-*; let selected Showcase cards own one full row. */
    .row > div:has(> .product-card-std.has-mobile-full-card) {
        flex: 0 0 100% !important;
        width: 100% !important;
        max-width: 100% !important;
        grid-column: 1 / -1 !important;
    }
    .products-grid-container > .product-card-std.has-mobile-full-card,
    .products-list-wrapper > .product-card-std.has-mobile-full-card {
        grid-column: 1 / -1 !important;
    }

    .product-card-std.has-mobile-showcase:not(.is-home-card) {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: hidden !important;
        border-color: var(--mobile-showcase-border-color) !important;
        border-radius: var(--mobile-showcase-radius) !important;
        --card-tag-radius: var(--mobile-showcase-radius);
    }
    .product-card-std.has-mobile-showcase:not(.is-home-card) > .std-card-standard {
        display: none !important;
    }
    .product-card-std.has-mobile-showcase:not(.is-home-card) > .mobile-showcase-card {
        display: block !important;
        width: 100%;
        background: var(--mobile-product-card-background);
    }
    .mobile-showcase-card__media-wrap {
        position: relative;
        width: 100%;
        aspect-ratio: var(--showcase-media-ratio, 1.9 / 1);
        overflow: hidden;
        background: var(--product-image-background, #ffffff);
    }
    .mobile-showcase-card__video {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: cover;
        background: #111;
    }
    .mobile-showcase-card__media-image {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: cover;
        background: var(--product-image-background, #ffffff);
    }
    .mobile-showcase-card__toggle {
        position: absolute;
        top: 12px;
        left: 12px;
        z-index: 3;
        width: 42px;
        height: 42px;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: rgba(20,20,20,.56);
        color: #fff;
        border: 1px solid rgba(255,255,255,.26);
        font-size: 17px;
        line-height: 1;
        cursor: pointer;
        user-select: none;
        backdrop-filter: blur(4px);
    }
    .mobile-showcase-card__toggle:focus-visible {
        outline: 2px solid #fff;
        outline-offset: 2px;
    }
    .mobile-showcase-card__bottom {
        position: relative;
        width: 100%;
        min-width: 0;
        min-height: var(--showcase-info-min-height, 140px);
        background: transparent;
        overflow: visible;
        --showcase-product-footprint-width: 0px;
        --showcase-bottom-stage-height: var(--showcase-info-min-height, 140px);
    }
    .showcase-bottom-stage {
        position: absolute;
        z-index: 1;
        left: 0;
        bottom: 0;
        width: 100%;
        height: var(--showcase-bottom-stage-height, var(--showcase-info-min-height, 140px));
        display: block;
        overflow: visible;
        pointer-events: none;
    }
    .showcase-bottom-stage [data-showcase-bottom-surface-path] {
        fill: var(--mobile-product-card-background);
    }
    .mobile-showcase-card__info {
        position: relative;
        z-index: 3;
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        min-height: var(--showcase-info-min-height, 140px);
        padding: 0 14px;
        padding-right: calc(var(--showcase-product-footprint-width) + 14px);
        display: flex;
        flex-direction: column;
        justify-content: space-evenly;
        gap: 0;
        text-align: var(--mobile-showcase-name-align);
    }
    .mobile-showcase-card__name {
        margin: 0;
        color: #222;
        font-size: var(--mobile-product-name-size);
        font-weight: 700;
        line-height: 1.8;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    .mobile-showcase-card__price {
        min-width: 0;
        text-align: var(--mobile-showcase-price-align);
    }
    .mobile-showcase-card__price .std-price-main {
        font-size: var(--mobile-product-price-size) !important;
        color: var(--mobile-product-current-price-color) !important;
    }
    .mobile-showcase-card__price .std-price-old {
        font-size: var(--mobile-product-old-price-size) !important;
        color: var(--mobile-product-old-price-color) !important;
        text-decoration-color: var(--mobile-product-old-price-strike-color) !important;
    }
    .mobile-showcase-card__price .std-price-final-row {
        justify-content: var(--mobile-showcase-price-justify) !important;
    }
    .mobile-showcase-card__price .std-discount-percent {
        background: var(--mobile-product-discount-badge-bg) !important;
        color: var(--mobile-product-discount-badge-text) !important;
        border-radius: var(--mobile-product-discount-badge-radius) !important;
        font-size: var(--mobile-product-discount-badge-font-size) !important;
    }

    /* ===== Horizon: full-width, two optional media rows + one info row ===== */
    .product-card-std.has-mobile-horizon:not(.is-home-card) {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: auto !important;
        min-height: 0 !important;
        overflow: hidden !important;
        border-color: var(--mobile-horizon-border-color, var(--mobile-product-card-border-color)) !important;
        border-radius: var(--mobile-horizon-radius, var(--mobile-product-card-radius)) !important;
        --card-tag-radius: var(--mobile-horizon-radius, var(--mobile-product-card-radius));
    }
    .product-card-std.has-mobile-horizon:not(.is-home-card) > .std-card-standard {
        display: none !important;
    }
    .product-card-std.has-mobile-horizon:not(.is-home-card) > .mobile-horizon-card {
        display: block !important;
        width: 100%;
        background: var(--mobile-product-card-background);
    }
    .mobile-horizon-card__media-row {
        position: relative;
        width: 100%;
        aspect-ratio: var(--horizon-row-ratio, 2 / 1);
        overflow: hidden;
        background: var(--product-image-background, #ffffff);
    }
    .mobile-horizon-card__image,
    .mobile-horizon-card__video {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
        background: var(--product-image-background, #ffffff);
    }
    .mobile-horizon-card__video { background: #111; }
    .mobile-horizon-card__toggle {
        position: absolute;
        top: 12px;
        left: 12px;
        z-index: 3;
        width: 42px;
        height: 42px;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: rgba(20,20,20,.56);
        color: #fff;
        border: 1px solid rgba(255,255,255,.26);
        font-size: 17px;
        line-height: 1;
        cursor: pointer;
        user-select: none;
        backdrop-filter: blur(4px);
    }
    .mobile-horizon-card__info {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        direction: ltr;
        align-items: center;
        gap: 12px;
        width: 100%;
        min-width: 0;
        min-height: var(--mobile-horizon-info-min-height, 48px);
        box-sizing: border-box;
        padding: 12px 14px;
        background: var(--mobile-product-card-background);
    }
    .mobile-horizon-card__name {
        grid-column: 2;
        grid-row: 1;
        min-width: 0;
        margin: 0;
        direction: rtl;
        text-align: var(--mobile-horizon-name-align);
        color: #222;
        font-size: var(--mobile-product-name-size);
        font-weight: 700;
        line-height: 1.7;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: normal;
        word-break: normal;
        overflow-wrap: break-word;
    }
    .mobile-horizon-card__price {
        grid-column: 1;
        grid-row: 1;
        min-width: 0;
        text-align: var(--mobile-horizon-price-align);
        direction: rtl;
    }
    .mobile-horizon-card__price .std-price-main {
        font-size: var(--mobile-product-price-size) !important;
        color: var(--mobile-product-current-price-color) !important;
        white-space: nowrap;
    }
    .mobile-horizon-card__price .std-price-old {
        font-size: var(--mobile-product-old-price-size) !important;
        color: var(--mobile-product-old-price-color) !important;
        text-decoration-color: var(--mobile-product-old-price-strike-color) !important;
        text-align: var(--mobile-horizon-price-align) !important;
    }
    .mobile-horizon-card__price .std-price-final-row {
        justify-content: var(--mobile-horizon-price-justify) !important;
        flex-wrap: nowrap !important;
    }
    .mobile-horizon-card__price .std-discount-percent {
        background: var(--mobile-product-discount-badge-bg) !important;
        color: var(--mobile-product-discount-badge-text) !important;
        border-radius: var(--mobile-product-discount-badge-radius) !important;
        font-size: var(--mobile-product-discount-badge-font-size) !important;
    }
}

/* Final related-card overrides follow every list/showcase rule deliberately. */
.product-card-std.is-related-card {
    flex-direction: column !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    border-radius: var(--related-card-radius, 12px) !important;
        --card-tag-radius: var(--related-card-radius, 12px);
}
.product-card-std.is-related-card .std-img-wrapper {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: var(--related-card-image-ratio, 1) !important;
}
.product-card-std.is-related-card .std-card-body {
    min-height: var(--related-card-info-min-height, 88px) !important;
}
.product-card-std.is-related-card .std-product-name {
    font-size: var(--related-card-name-size, 14px) !important;
}
.product-card-std.is-related-card .std-price-main {
    font-size: var(--related-card-price-size, 16px) !important;
}

/* A single grid track stretches every related card to the tallest content. */
#related-products .related-products {display:grid!important;grid-auto-flow:column;grid-template-columns:none!important;grid-auto-columns:var(--related-card-width-desktop);gap:var(--related-card-gap)!important;align-items:stretch;overflow-x:auto;margin:0;padding:0 0 8px;}
#related-products .related-products > div {display:flex!important;width:auto!important;max-width:none!important;min-width:0;padding:0!important;margin:0!important;}
#related-products .product-card-std.is-related-card {width:100%!important;min-width:0!important;max-width:100%!important;height:100%!important;flex:1;}
#related-products .std-card-standard {flex:1;height:auto;}
#related-products .std-card-body {flex:1;}
@media(max-width:768px){#related-products{--related-card-gap:var(--related-mobile-gap);--related-card-image-ratio:var(--related-mobile-image_aspect_ratio);--related-card-info-min-height:var(--related-mobile-info_min_height);--related-card-radius:var(--related-mobile-border_radius);--related-card-name-size:var(--related-mobile-name_font_size);--related-card-price-size:var(--related-mobile-price_font_size);}#related-products .related-products{grid-auto-columns:var(--related-card-width-mobile);}}

/* Shared name color and per-surface alignment. */
.product-card-std .std-product-name,.product-card-std .mobile-showcase-card__name,.product-card-std .mobile-horizon-card__name{color:var(--product-card-name-color,#222222)!important;}
@media (max-width:768px){
.product-card-std.is-home-card .std-product-name{text-align:var(--home-mobile-name-align,right)!important;}
.product-card-std.is-home-card .std-price-block,.product-card-std.is-home-card .std-price-old{text-align:var(--home-mobile-price-align,right)!important;}
.product-card-std.is-home-card .std-price-final-row{justify-content:var(--home-mobile-price-justify,flex-start)!important;}
}
@media (min-width:769px){
.product-card-std.is-home-card .std-product-name{text-align:var(--home-desktop-name-align,right)!important;}
.product-card-std.is-home-card .std-price-block,.product-card-std.is-home-card .std-price-old{text-align:var(--home-desktop-price-align,right)!important;}
.product-card-std.is-home-card .std-price-final-row{justify-content:var(--home-desktop-price-justify,flex-start)!important;}
}
@media (min-width:769px){
.product-card-std:not(.is-home-card):not(.is-related-card) .std-product-name{text-align:var(--listing-desktop-name-align,right)!important;}
.product-card-std:not(.is-home-card):not(.is-related-card) .std-price-block,.product-card-std:not(.is-home-card):not(.is-related-card) .std-price-old{text-align:var(--listing-desktop-price-align,right)!important;}
.product-card-std:not(.is-home-card):not(.is-related-card) .std-price-final-row{justify-content:var(--listing-desktop-price-justify,flex-start)!important;}
}
@media (max-width:768px){
.product-card-std.is-related-card .std-product-name{text-align:var(--related-mobile-name-align,right)!important;}
.product-card-std.is-related-card .std-price-block,.product-card-std.is-related-card .std-price-old{text-align:var(--related-mobile-price-align,right)!important;}
.product-card-std.is-related-card .std-price-final-row{justify-content:var(--related-mobile-price-justify,flex-start)!important;}
}
@media (min-width:769px){
.product-card-std.is-related-card .std-product-name{text-align:var(--related-desktop-name-align,right)!important;}
.product-card-std.is-related-card .std-price-block,.product-card-std.is-related-card .std-price-old{text-align:var(--related-desktop-price-align,right)!important;}
.product-card-std.is-related-card .std-price-final-row{justify-content:var(--related-desktop-price-justify,flex-start)!important;}
}
