body.modal-open {
    overflow: hidden;
}

#cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#cart-modal {
    background: white;
    border-radius: 10px;
    width: 90vw;
    height: 90vh;
    padding: 0 20px;
    position: relative;
    display: flex;
    flex-direction: column;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

#cart-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #333;
    transition: transform 0.2s ease, color 0.2s ease;
}

#cart-close:hover {
    color: #e6494d;
    transform: scale(1.2);
}

/* --- Contenu principal --- */
#cart-content {
    display: flex;
    height: 100%;
    gap: 30px;
}

#cart-left {
    flex: 1;
    overflow-y: auto;
    padding-right: 50px;
    border-right: 1px solid #ccc;
}

#cart-right {
    width: 330px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    max-height: 100%;
    overflow-y: auto;
}

#cart-right .cart-title {
    display: flex;
    justify-content: flex-end;
    font-size: 1.8em;
    margin: 0 0 20px 0;
    font-weight: bold;
}

/* --- Items Panier --- */
.cart-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 15px 0 0 10px;
    padding: 16px 20px;
    background-color: #f4efef;
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.24);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.cart-item-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.cart-item-info img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    background: #ffffff;
    border-radius: 3px;
    flex-shrink: 0;
}

.cart-item-name {
    font-weight: bold;
    margin-bottom: 6px;
}

.cart-item-garbage {
    margin-top: 10px;
    cursor: pointer;
}

.cart-item-garbage img {
    width: 18px;
    height: 18px;
    background: none;
}

.cart-item-garbage img:hover {
    transform: translateY(-.1px) scale(1.1);
}

.cart-price-qty-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 150px;
}

.cart-qty-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-price {
    display: flex;
    justify-content: center;
    font-weight: bold;
    font-size: 1.1em;
    color: #333;
    white-space: nowrap;
    margin: 0 0 10px 10px;
    width: 100%;
}

.cart-item-qty {
    font-size: 0.85em;
    color: #555;
}

.cart-item-qty-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-top: 6px;
}

.cart-qty-btn{
    width: 18px;
    height: 18px;
    border: 0;
    border-radius: 999px;
    text-align: center;
    padding: 0;
    line-height: 1;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0,0,0,.06);
    cursor: pointer;
    font-size: 18px;
    transition: transform .12s ease;
}

#cart-summary {
    display: flex;
    flex-direction: column;
    align-items: end;
    font-size: 16px;
    line-height: 1.5em;
    margin: 4px 0 25px 0;
}

.cart-summary div strong {
    font-size: 18px;
}

.cart-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cart-actions .btn-check {
    background: var(--primary-yellow);
    color: black;
    padding: 10px 17px 14px 14px;
    font-weight: bold;
    border-radius: 25px;
    border: none;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

.cart-actions .btn-check:hover {
    transform: translateY(-1px) scale(1.01);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

.cart-actions .btn-check:active {
    transform: scale(0.98);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.cart-actions .btn-check img {
    position: relative;
    top: 4px;
    width: 20px;
    height: 20px;
}

.cart-actions .btn-quote {
    position: relative;
    right: 5px;
    display: flex;
    justify-content: center;
    color: black;
    width: 80%;
    padding: 14px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.cart-actions .btn-quote img {
    width: 18px;
    height: 18px;
    margin-right: 8px;
}

.cart-actions .btn-quote:hover {
    text-decoration: underline;
}

.cart-actions .btn-quote:active {
    transform: scale(0.98);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.cart-actions-first {
    margin-bottom: 20px;
}

.date-range {
    background: #f4fbf9;
    border: 1px solid #d9f0e9;
    border-radius: 16px;
    padding: 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,.06);
}

.date-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    margin: 0 0 10px 0;
}

.date-title img {
    width: 18px;
    height: 18px;
    position: relative;
    top: 2px;
}

.date-fields {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.date-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.date-field span {
    font-size: 12px;
    font-weight: 600;
    color: #444;
    text-transform: uppercase;
    letter-spacing: .02em;
}

.date-field input[type="date"] {
    height: 42px;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid #cfd8dc;
    background: #fff;
    font-size: 14px;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.date-field input[type="date"]:focus {
    outline: none;
    border-color: #00b894;
    box-shadow: 0 0 0 3px rgba(0,184,148,.2);
}

.date-field input[type="date"].is-invalid {
    border-color: #e6494d;
    box-shadow: 0 0 0 3px rgba(230,73,77,.18);
}

.date-help {
    margin: 8px 0 0 0;
    font-size: 12px;
    color: #555;
}

@media (max-width: 480px) {
    .date-fields {
        grid-template-columns: 1fr;
    }
}

.cart-actions-second {
    width: 100%;
    display: flex;
    justify-content: center;
}

/* --- Transport --- */
.transport-options {
    margin-top: 40px;
    padding-top: 20px;
}

.transport-options label input {
    margin-bottom: 20px;
    cursor: pointer;
}

.transport-options h3 {
    font-size: 16px;
    margin-bottom: 10px;
    font-weight: bold;
}

.category-title {
    font-weight: bold;
    font-size: 1em;
    border-bottom: 1px solid #aaa;
    padding: 20px 0 10px 0;
    text-transform: uppercase;
    color: #222;
}

.cart-actions-third {
    display: flex;
    width: 100%;
    justify-content: center;
}

/* --- Animation suppression item --- */
.cart-item-remove {
    animation: fadeOutSlideUp 0.8s ease forwards;
}

/*-- Panier vide --*/
#cart-left.empty {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-weight: 700;
    color: #222;
    font-size: clamp(20px, 2.6vw, 28px);
    letter-spacing: 0.2px;
    text-align: center;
    animation: cartEmptyPop 240ms ease-out;
    user-select: none;
}

#cart-modal.is-empty #cart-right {
    display: none;
}

/* Petite animation d'apparition, douce */
@keyframes cartEmptyPop {
    from { opacity: 0; transform: translateY(6px) scale(0.99); }
    to   { opacity: 1; transform: translateY(0)   scale(1); }
}


@keyframes fadeOutSlideUp {
    0% {
        opacity: 1;
        transform: translateY(0);
        height: auto;
        margin: 15px 0;
    }
    100% {
        opacity: 0;
        transform: translateY(-20px);
        height: 0;
        margin: 0;
        padding: 0;
    }
}