/**
 * Car Products Slider - Styles
 * Version: 1.0.0
 */

/* ============================================
   WRAPPER STYLES
============================================= */
.cps-products-slider-wrapper {
    position: relative;
    padding: 0 50px;
}

.cps-products-slider-wrapper .cps-products-swiper {
    overflow: hidden;
    padding-bottom: 50px;
}

/* ============================================
   SOLD BADGE
============================================= */
.cps-related-card.cps-is-sold::before {
    content: "";
    background-image: url('https://dev.thriftdeals.in/wp-content/uploads/2026/01/booked.webp');
    z-index: 999;
    border-radius: 5px;
    position: absolute;
    top: 0px;
    left: -5px;
    width: 110px;
    background-size: contain;
    background-repeat: no-repeat;
    height: auto;
    color: #fff;
    padding: 23px 30px;
    font-weight: bold;
    font-size: 16px;
    letter-spacing: 1px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.cps-related-card.cps-is-sold .cps-btn-whatsapp {
    pointer-events: none;
    opacity: 0.3;
}

/* ============================================
   CARD STYLES
============================================= */
.cps-related-card {
    position: relative;
    background-color: #232323;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.cps-related-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
}

.cps-related-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.cps-related-card-link:hover {
    color: inherit;
}

/* ============================================
   REGISTRATION BADGE
============================================= */
.cps-reg-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    z-index: 10;
}

/* ============================================
   CARD IMAGE SLIDER (SWIPER NESTED)
============================================= */
.cps-card-image-slider {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.cps-card-swiper {
    width: 100%;
    height: 100%;
}

.cps-card-swiper .swiper-slide {
    width: 100%;
    height: 100%;
}

.cps-card-swiper .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Card Slider Navigation */
.cps-card-slider-prev,
.cps-card-slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 35px;
    height: 35px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 5;
    line-height: 1;
}

.cps-related-card:hover .cps-card-slider-prev,
.cps-related-card:hover .cps-card-slider-next {
    opacity: 1;
}

.cps-card-slider-prev:hover,
.cps-card-slider-next:hover {
    background: rgba(0, 0, 0, 0.9);
}

.cps-card-slider-prev {
    left: 10px;
}

.cps-card-slider-next {
    right: 10px;
}

/* Card Slider Pagination */
.cps-card-slider-pagination {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

.cps-card-slider-pagination .swiper-pagination-bullet {
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 1;
    margin: 0 3px;
}

.cps-card-slider-pagination .swiper-pagination-bullet-active {
    background: #fff;
}

/* ============================================
   CARD HEADER INFO
============================================= */
.cps-card-header-info {
    padding: 15px;
    background: #232323;
}

.cps-card-header-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
}

h3.cps-car-name,
.cps-car-name {
    font-size: 26px;
    font-weight: 700;
    margin: 0;
    line-height: 1.3;
    color: #fff;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    text-transform: unset !important;
}

/* ============================================
   WHATSAPP BUTTON
============================================= */
.cps-btn-whatsapp {
    width: 40px;
    height: 40px;
    min-width: 40px;
    padding: 0;
    background: #25D366;
    border: none;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.cps-btn-whatsapp:hover {
    background: #128C7E;
    transform: scale(1.1);
}

.cps-btn-whatsapp svg {
    width: 22px;
    height: 22px;
    color: #fff;
}

/* ============================================
   PRICE
============================================= */
.cps-card-header-info .cps-car-price {
    font-size: 20px;
    font-weight: 700;
    color: #ea0a0b;
    margin: 8px 0 0;
}

/* ============================================
   CARD SPECS
============================================= */
.cps-card-specs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: rgba(255, 255, 255, 0.1);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cps-card-specs .cps-spec {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px 10px;
    background: #232323;
    text-align: center;
}

.cps-card-specs .cps-spec svg {
    width: 24px;
    height: 24px;
    margin-bottom: 6px;
    opacity: 0.7;
    color: #fff;
}

.cps-card-specs .cps-spec .cps-label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.cps-card-specs .cps-spec .cps-value {
    font-size: 12px;
    font-weight: 600;
    color: #fff;
}

/* ============================================
   MAIN SLIDER NAVIGATION
============================================= */
.cps-swiper-button-prev,
.cps-swiper-button-next {
    width: 45px;
    height: 45px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    color: #fff;
    transition: all 0.3s ease;
}

.cps-swiper-button-prev:hover,
.cps-swiper-button-next:hover {
    background: rgba(0, 0, 0, 0.9);
}

.cps-swiper-button-prev::after,
.cps-swiper-button-next::after {
    font-size: 18px;
    font-weight: bold;
}

.cps-swiper-button-prev {
    left: 0;
}

.cps-swiper-button-next {
    right: 0;
}

/* ============================================
   MAIN SLIDER PAGINATION
============================================= */
.cps-swiper-pagination {
    position: relative;
    margin-top: 20px;
    bottom: auto !important;
}

.cps-swiper-pagination .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.3);
    opacity: 1;
    margin: 0 5px;
    transition: all 0.3s ease;
}

.cps-swiper-pagination .swiper-pagination-bullet-active {
    background: #ea0a0b;
    transform: scale(1.2);
}

/* ============================================
   NO PRODUCTS MESSAGE
============================================= */
.cps-no-products {
    text-align: center;
    padding: 40px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
}

/* ============================================
   EDITOR PLACEHOLDER
============================================= */
.cps-editor-placeholder {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 60px 40px;
    text-align: center;
    color: #fff;
}

.cps-editor-placeholder .cps-editor-icon {
    margin-bottom: 20px;
    color: #ea0a0b;
}

.cps-editor-placeholder h3 {
    margin: 0 0 10px;
    font-size: 24px;
    font-weight: 600;
}

.cps-editor-placeholder p {
    margin: 0;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

/* ============================================
   TOAST NOTIFICATIONS
============================================= */
.cps-toast-notification {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 15px 25px;
    background: #333;
    color: #fff;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    z-index: 99999;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.cps-toast-notification.cps-show {
    transform: translateY(0);
    opacity: 1;
}

.cps-toast-notification.cps-success {
    background: linear-gradient(135deg, #10b981, #059669);
}

.cps-toast-notification.cps-error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.cps-toast-notification.cps-info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

/* ============================================
   RESPONSIVE STYLES
============================================= */
@media (max-width: 1024px) {
    .cps-products-slider-wrapper {
        padding: 0 40px;
    }

    h3.cps-car-name,
    .cps-car-name {
        font-size: 22px;
    }

}

@media (max-width: 768px) {
    .cps-products-slider-wrapper {
        padding: 0 15px;
    }

    .cps-swiper-button-prev,
    .cps-swiper-button-next {
        display: none;
    }

    h3.cps-car-name,
    .cps-car-name {
        font-size: 20px;
    }

    .cps-card-header-info .cps-car-price {
        font-size: 18px;
    }

    .cps-card-image-slider {
        height: 200px;
    }

    .cps-card-slider-prev,
    .cps-card-slider-next {
        width: 30px;
        height: 30px;
        font-size: 16px;
        opacity: 1;
    }
}

@media (max-width: 480px) {
    h3.cps-car-name,
    .cps-car-name {
        font-size: 18px;
    }

    .cps-card-header-info {
        padding: 12px;
    }

    .cps-card-specs .cps-spec {
        padding: 12px 8px;
    }

    .cps-card-specs .cps-spec svg {
        width: 20px;
        height: 20px;
    }

    .cps-card-specs .cps-spec .cps-label {
        font-size: 9px;
    }

    .cps-card-specs .cps-spec .cps-value {
        font-size: 11px;
    }
}