/**
 * Product Swiper Widget CSS
 * Premium aesthetic matching clean product card design
 */

.mct-product-swiper-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 0px 2px 0px 2px;
}

.mct-product-swiper {
    width: 100%;
    height: 100%;
}

/* Instant CSS Layout before Swiper JS initializes */
.mct-product-swiper:not(.swiper-initialized) .swiper-wrapper {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    overflow-x: auto;
    scrollbar-width: none;
}

.mct-product-swiper:not(.swiper-initialized) .swiper-wrapper::-webkit-scrollbar {
    display: none;
}

.mct-product-swiper:not(.swiper-initialized) .swiper-slide {
    flex: 0 0 calc(25% - 15px);
    min-width: 220px;
}

/* Product Card Styling (Matching Shop Grid & Filters widget card) */
.mct-product-card {
    position: relative;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    transition: all 0.25s ease;
    text-decoration: none;
    color: inherit;
}

.mct-product-card:hover {
    border-color: #cbd5e1;
    text-decoration: none;
}

.mct-product-card__image-wrapper {
    position: relative;
    width: 100%;
    height: 175px;
    background: #f8fafc;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
    border-radius: 0;
}

.mct-product-card__image-wrapper a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.mct-product-card__image {
    width: 100%;
    height: 100% !important;
    object-fit: cover !important;
    padding: 0 !important;
    border-radius: 0;
    transition: transform 0.35s ease;
    display: block;
}

.mct-product-card:hover .mct-product-card__image {
    transform: scale(1.04);
}

.mct-product-card__content {
    padding: 10px 14px 14px 14px;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    text-align: left;
}

.mct-product-card__title {
    font-size: 13px;
    font-weight: 700;
    color: #18181b;
    margin: 0 0 4px 0;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mct-product-card__title a {
    color: #18181b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.mct-product-card__title a:hover {
    color: #dc2626;
}

.mct-product-card__meta {
    font-size: 11px;
    color: #71717a !important;
    margin-bottom: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mct-product-card__price {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 700;
    margin-top: auto;
}

.mct-product-card__price .mct-old-price {
    color: #71717a;
    text-decoration: line-through;
    font-weight: 500;
    font-size: 12px;
}

.mct-product-card__price .mct-current-price {
    color: #dc2626;
    font-weight: 700;
    font-size: 14px;
}

/* Swiper Navigation & Pagination */
.mct-swiper-button-prev,
.mct-swiper-button-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transition: all 0.25s ease;
}

.mct-swiper-button-prev {
    left: 10px;
}

.mct-swiper-button-next {
    right: 10px;
}

.mct-swiper-button-prev:hover,
.mct-swiper-button-next:hover {
    background-color: #ffffff;
    color: #e11d48;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
    transform: translateY(-50%) scale(1.08);
}

.mct-swiper-button-prev::after,
.mct-swiper-button-next::after {
    font-size: 16px;
    font-weight: bold;
}

.mct-swiper-pagination {
    position: relative;
    margin-top: 18px;
    bottom: 0 !important;
}

.mct-swiper-pagination .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background-color: #cbd5e1;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.mct-swiper-pagination .swiper-pagination-bullet-active {
    width: 24px;
    border-radius: 4px;
    background-color: #e11d48;
    opacity: 1;
}

/* ==========================================================================
   Similar Products Header Styling
   ========================================================================== */
.mct-similar-products-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    gap: 12px;
}

.mct-similar-products-title {
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
    line-height: 1.3;
}

.mct-similar-products-link {
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    text-decoration: none;
    transition: color 0.2s ease;
}

.mct-similar-products-link:hover {
    color: #dc2626;
    text-decoration: underline;
}
