/**
 * Bestsellers redesign — Local/smb theme only
 * Resets Argento "squama" listing + Swissup float columns that collapse card width.
 */

.block.widget.smb-bestsellers,
.smb-bestsellers {
    position: relative;
    box-sizing: border-box;
    width: 100% !important;
    max-width: 100% !important;
    margin-bottom: 40px!important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    overflow: visible !important;
    margin-top:0;
}

.smb-bestsellers .smb-bestsellers__header {
    display: flex !important;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 24px !important;
    padding: 0 !important;
    text-align: left !important;
    background: none !important;
    height: auto !important;
    overflow: visible !important;
    border: 0 !important;
    box-shadow: none !important;
}

.smb-bestsellers .smb-bestsellers__header::before,
.smb-bestsellers .smb-bestsellers__header::after,
.smb-bestsellers .block-title-background {
    display: none !important;
    content: none !important;
}

.smb-bestsellers .smb-bestsellers__title {
    display: block;
    margin: 0;
    color: #111 !important;
    font-size: clamp(1.75rem, 2.5vw, 2.25rem);
    font-weight: 700;
    font-style: italic;
    line-height: 1.1;
    text-transform: uppercase;
}

.smb-bestsellers .smb-bestsellers__subtitle {
    margin: 8px 0 0;
    color: #666;
    font-size: 15px;
    font-weight: 400;
    font-style: normal;
    line-height: 1.4;
}

.smb-bestsellers .smb-bestsellers__nav {
    display: flex !important;
    gap: 8px;
    flex-shrink: 0;
    align-items: center;
    position: relative;
    z-index: 10;
}

.smb-bestsellers .block-content {
    position: relative;
    width: 100%;
    padding: 0 !important;
    overflow: visible;
}

.smb-bestsellers .swiper-container {
    position: relative;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

.smb-bestsellers .swiper-wrapper {
    display: flex !important;
}

.smb-bestsellers .swiper-slide {
    width: 100% !important;
    max-width: 100% !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

/* Arrows in header (not clipped by swiper overflow) */
.smb-bestsellers .smb-bestsellers__nav-btn.swiper-button-prev,
.smb-bestsellers .smb-bestsellers__nav-btn.swiper-button-next,
.smb-bestsellers .smb-bestsellers__nav-btn {
    position: static !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 34px !important;
    height: 34px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #cfd4dc !important;
    border-radius: 2px !important;
    background: #fff !important;
    color: #111 !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    opacity: 1 !important;
    z-index: 5;
    cursor: pointer;
    box-shadow: none !important;
}

.smb-bestsellers .smb-bestsellers__nav-btn--next,
.smb-bestsellers .smb-bestsellers__nav-btn.swiper-button-next {
    background: #0b5f86 !important;
    border-color: #0b5f86 !important;
    color: #fff !important;
}

.smb-bestsellers .smb-bestsellers__nav-btn::after {
    font-size: 14px !important;
    font-weight: 700;
    color: inherit !important;
}

.smb-bestsellers .smb-bestsellers__nav-btn:hover:not(.swiper-button-disabled) {
    background: #0b5f86 !important;
    border-color: #0b5f86 !important;
    color: #fff !important;
}

.smb-bestsellers .smb-bestsellers__nav-btn.swiper-button-disabled {
    opacity: 0.35 !important;
    background: #fff !important;
    border-color: #cfd4dc !important;
    color: #111 !important;
    pointer-events: none;
}

/* -------- Product grid: reset Argento squama + Swissup floats -------- */
.page-layout-1column .block.widget.smb-bestsellers .products-grid .product-items,
.block.widget.smb-bestsellers .products-grid .product-items,
.smb-bestsellers .smb-bestsellers-grid .product-items,
.smb-bestsellers .products-grid .product-items {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(220px, 1fr)) !important;
    gap: 16px !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.page-layout-1column .block.widget.smb-bestsellers .products-grid .product-item,
.page-layout-1column .block.widget.smb-bestsellers .products-grid .product-item:nth-child(n),
.block.widget.smb-bestsellers .products-grid .product-item,
.block.widget.smb-bestsellers .products-grid .product-item:nth-child(n),
.smb-bestsellers .products-grid .product-item,
.smb-bestsellers .products-grid .product-item:nth-child(n) {
    /* Argento squama reset */
    position: relative !important;
    float: none !important;
    clear: none !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    border: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

.smb-bestsellers .products-grid .product-item::before,
.smb-bestsellers .products-grid .product-item::after {
    display: none !important;
    content: none !important;
}

/* Kill absolute hover expansion from squama */
.smb-bestsellers .products-grid .product-item:hover,
.smb-bestsellers .products-grid .product-item:hover .product-item-info,
.smb-bestsellers .products-grid .product-item .product-item-info {
    position: relative !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    height: auto !important;
    overflow: visible !important;
    box-shadow: none !important;
    background: #fff !important;
    padding: 0 !important;
    z-index: auto !important;
    width: 100% !important;
    max-width: 100% !important;
}

.smb-bestsellers .products.wrapper,
.smb-bestsellers .products-grid,
.smb-bestsellers .smb-bestsellers-grid {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
}

/* -------- Card -------- */
.smb-bestsellers-card,
.smb-bestsellers .product-item-info.smb-bestsellers-card {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #d8dde5 !important;
    background: #fff !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    box-shadow: none !important;
}
.smb-bestsellers-card__media {
    position: relative;
    width: 100%;
    padding: 16px 16px 0;
    box-sizing: border-box;
    overflow: hidden;
}
.smb-bestsellers-card__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 3;
    padding: 4px 8px;
    background: #c6002d;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
}
.smb-bestsellers .prolabels-wrapper .prolabel,
.smb-bestsellers .swissup-prolabels,
.smb-bestsellers .prolabel {
    display: none !important;
}
.smb-bestsellers-card__secondary {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 3;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.smb-bestsellers-card__icon-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 28px !important;
    height: 28px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #d8dde5 !important;
    border-radius: 2px !important;
    background: #fff !important;
    background-image: none !important;
    box-shadow: none !important;
}
.smb-bestsellers-card__icon-btn span {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
}
.smb-bestsellers-card__icon-btn.towishlist::before,
.smb-bestsellers-card__icon-btn.tocompare::before {
    content: "" !important;
    display: block;
    width: 14px;
    height: 14px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}
.smb-bestsellers-card__icon-btn.towishlist::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='1.8'%3E%3Cpath d='M12 20.25s-6.75-4.2-8.6-8.05C2.1 9.45 3.55 6.75 6.4 6.75c1.7 0 3.05.95 3.85 2.2.8-1.25 2.15-2.2 3.85-2.2 2.85 0 4.3 2.7 3 5.45-1.85 3.85-8.1 8.05-8.1 8.05z'/%3E%3C/svg%3E");
}
.smb-bestsellers-card__icon-btn.tocompare::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 7H3v4M17 17h4v-4M3 11l4-4M21 13l-4 4'/%3E%3C/svg%3E");
}
.smb-bestsellers-card__media .product-item-photo {
    display: block !important;
    width: 100% !important;
}
.smb-bestsellers-card__media .product-image-container,
.smb-bestsellers-card__media [class*="product-image-container"] {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    aspect-ratio: 1 / 1 !important;
    margin: 0 auto !important;
}
.smb-bestsellers-card__media .product-image-wrapper {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    padding: 0 !important;
}
.smb-bestsellers-card__media img {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    object-fit: contain;
}
.smb-bestsellers-card__body,
.smb-bestsellers .product-item-details.smb-bestsellers-card__body {
    display: flex !important;
    flex-direction: column !important;
    flex: 1 1 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding: 14px 16px 18px !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: normal !important;
}
.smb-bestsellers-card__body .product-item-name {
    order: 2;
    display: block !important;
    width: 100% !important;
    margin: 0 0 12px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
}
.smb-bestsellers-card__body .product-item-name a {
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #111;
    text-decoration: none;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: anywhere;
}
.smb-bestsellers-card__body .product-item-name a:hover {
    color: #4aa3df;
}
.smb-bestsellers-card__stock {
    order: 1;
    width: 100% !important;
    margin: 0 0 8px !important;
}
.smb-bestsellers-card__body .product-item-name {
    order: 2;
}
.smb-bestsellers-card__body > *:not(.smb-bestsellers-card__stock):not(.product-item-name):not(.smb-bestsellers-card__meta) {
    order: 3;
    width: 100% !important;
    max-width: 100% !important;
    white-space: normal !important;
}
.smb-bestsellers-card__meta {
    order: 4;
    display: flex !important;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    width: 100% !important;
    margin-top: auto;
}
.smb-bestsellers-card__stock .amstockstatus-category,
.smb-bestsellers-card__stock .amstockstatus-status-container,
.smb-bestsellers .amasty_stock_status,
.smb-bestsellers .amstockstatus,
.smb-bestsellers .stock.status,
.smb-bestsellers [class*="stockstatus"],
.smb-bestsellers .product-item-details .stock,
.smb-bestsellers .product-item-details .availability {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    white-space: normal !important;
    word-break: normal !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.35 !important;
}
.smb-bestsellers-card__price-wrap {
    flex: 1 1 auto;
    min-width: 0;
    width: auto !important;
    white-space: normal !important;
}
.smb-bestsellers-card__price-wrap .price-box {
    margin: 0 0 6px;
    white-space: normal !important;
}
.smb-bestsellers-card__price-wrap .price {
    font-size: 15px;
    font-weight: 700;
    color: #4aa3df;
    white-space: nowrap;
}
.smb-bestsellers-card__price-wrap .price-label {
    color: #4aa3df;
    font-weight: 400;
    white-space: normal !important;
}
.smb-bestsellers-card__price-wrap .old-price .price {
    color: #888;
    font-weight: 400;
    text-decoration: line-through;
}
.smb-bestsellers-card__price-wrap .special-price .price {
    color: #c6002d;
}
.smb-bestsellers-card__price-wrap .product-reviews-summary {
    margin: 0;
}
.smb-bestsellers-card__cta {
    flex-shrink: 0;
}
.smb-bestsellers-card__addtocart {
    min-width: 118px;
    height: auto !important;
    padding: 10px 14px !important;
    border: 0 !important;
    border-radius: 2px !important;
    background: #4aa3df !important;
    background-image: none !important;
    box-shadow: none !important;
    color: #fff !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    white-space: nowrap !important;
}
.smb-bestsellers-card__addtocart::before {
    display: none !important;
    content: none !important;
}
.smb-bestsellers-card__addtocart span {
    display: inline !important;
    position: static !important;
    width: auto !important;
    height: auto !important;
    overflow: visible !important;
    clip: auto !important;
    color: #fff !important;
    white-space: nowrap !important;
}
.smb-bestsellers-card__subscribe {
    display: inline-block;
    max-width: 140px;
    color: #0b5f86;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-decoration: none;
    line-height: 1.3;
    white-space: normal !important;
}
.smb-bestsellers .swatch-attribute,
.smb-bestsellers .swatch-opt-wrap,
.smb-bestsellers .toolbar,
.smb-bestsellers .pages {
    display: none !important;
}
@media (max-width: 1199px) {
    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-items,
    .block.widget.smb-bestsellers .products-grid .product-items,
    .smb-bestsellers .products-grid .product-items {
        grid-template-columns: repeat(3, minmax(180px, 1fr)) !important;
    }
}
/* ================================
   Tablet + Mobile Horizontal Scroll
   ================================ */
@media (max-width: 1023px) {

    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-items,
    .block.widget.smb-bestsellers .products-grid .product-items,
    .smb-bestsellers .products-grid .product-items {
        display: flex !important;
        flex-wrap: nowrap !important;
        grid-template-columns: none !important;
        gap: 16px !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        padding: 0 0 10px !important;
        margin: 0 !important;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    /* Hide scrollbar - Chrome / Edge / Safari */
    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-items::-webkit-scrollbar,
    .block.widget.smb-bestsellers .products-grid .product-items::-webkit-scrollbar,
    .smb-bestsellers .products-grid .product-items::-webkit-scrollbar {
        display: none;
    }
    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-item,
    .block.widget.smb-bestsellers .products-grid .product-item,
    .smb-bestsellers .products-grid .product-item {
        flex: 0 0 calc((100% - 16px) / 2) !important;
        width: calc((100% - 16px) / 2) !important;
        max-width: calc((100% - 16px) / 2) !important;
        min-width: 0 !important;
    }
}


@media (max-width: 767px) {
    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-items,
    .block.widget.smb-bestsellers .products-grid .product-items,
    .smb-bestsellers .products-grid .product-items {
        gap: 12px !important;
        padding-bottom: 8px !important;
    }
    .page-layout-1column .block.widget.smb-bestsellers .products-grid .product-item,
    .block.widget.smb-bestsellers .products-grid .product-item,
    .smb-bestsellers .products-grid .product-item {
        flex: 0 0 calc(85% - 6px) !important;
        width: calc(85% - 6px) !important;
        max-width: calc(85% - 6px) !important;
    }
    .smb-bestsellers .smb-bestsellers__header {
        flex-wrap: wrap;
    }
    .smb-bestsellers .smb-bestsellers__nav {
        margin-left: auto;
    }
    .smb-bestsellers-card__meta {
        flex-direction: column;
        align-items: flex-start;
    }
    .smb-bestsellers-card__addtocart {
        width: 100%;
    }
    .block-highlight.highlight-carousel .slide.loading.show-button:after{
        display:none;
    }
}