.occasions-container {
    padding: 20px 0 30px;
}

.occasions-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));   
    row-gap: 50px;
    column-gap: 20px;
}

.car-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
    transition: transform 0.28s ease, box-shadow 0.28s ease;       
    height: 100%;
    display: flex;
    flex-direction: column;
    margin-bottom: 15px; 
}

.car-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.12);
}

.car-image {
    display: block;
    position: relative;
    overflow: hidden;
    background: #f3f5f8;
    height: 200px;
}

.car-image img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: transform 0.45s ease, filter 0.35s ease;
}

.car-card:hover .car-image img {
    transform: scale(1.06);
    filter: brightness(1.03);
}

.car-body {
    padding: 18px 20px 18px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.car-title {
    font-size: 16px;
    line-height: 1.2;
    margin: 0 0 8px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #1f2a37;
}

.car-model {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 16px;
    min-height: 42px;
    line-height: 1.45;
}

.car-specs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 18px;
    margin-bottom: 14px;
}

.car-specs span {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
    font-size: 13px;
    color: #4b5563;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.car-specs i {
    color: #1c63b8;
    font-size: 13px;
    flex: 0 0 auto;
}

.tva {
    min-height: 18px;
    font-size: 12px;
    color: #e3342f;
    margin-bottom: 10px;
}

.car-footer {
    margin-top: auto;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
    padding-top: 4px;
}

.price {
    font-size: 18px;
    line-height: 1.2;
    font-weight: 800;
    color: #1c63b8;
}

.sold-text {
    color: #9ca3af;
}

.btn-details {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    height: 42px;
    padding: 0 16px;
    border-radius: 8px;
    background: #1c63b8;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 6px 14px rgba(28, 99, 184, 0.18);
}

.btn-details:hover {
    background: #15539a;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(28, 99, 184, 0.24);
}

/* Badge */
.badge-sold {
    position: absolute;
    top: 15px;
    left: -40px;
    width: 140px;
    text-align: center;
    background: #e3342f;
    color: #fff;  
    transform: rotate(-45deg);
    z-index: 4;
    font-size: 11px;
    padding: 5px 10px;
    letter-spacing: 0.08em;
    font-weight: bold;    
    
}

/* Overlay léger */
.overlay-sold {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.25);
    z-index: 2;
}

/* Désactive le zoom sur les voitures vendues */
.car-card:has(.badge-sold):hover .car-image img {
    transform: none;
}

@media (max-width: 1199px) {
    .occasions-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .occasions-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .car-image img {
        height: 210px;
    }
}

@media (max-width: 575px) {
    .occasions-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .car-image img {
        height: 220px;
    }
}