/* Renewly Premium Cart Styling */

/* Animation voor toevoegen aan winkelwagen */
.add-to-cart-animation {
    position: fixed;
    width: 20px;
    height: 20px;
    background-color: #00A896;
    border-radius: 50%;
    opacity: 0.9;
    z-index: 1100;
    pointer-events: none;
}

/* Animatie voor winkelwagen teller */
.cart-count {
    transition: transform 0.3s;
}

.cart-count.animated {
    transform: scale(1.5);
    color: #00A896;
}

.cart-sidebar {
    position: fixed;
    width: 400px;
    height: 100%;
    top: 0;
    right: -450px; /* Start offscreen */
    background-color: #ffffff;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    z-index: 1050;
    transition: right 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.cart-sidebar.active {
    right: 0;
}

.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.cart-overlay.active {
    visibility: visible;
    opacity: 1;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #f2f2f2;
}

.cart-title {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-title i {
    color: #00A896;
}

.cart-close {
    background: none;
    border: none;
    font-size: 22px;
    color: #333;
    cursor: pointer;
    transition: transform 0.2s;
}

.cart-close:hover {
    transform: rotate(90deg);
    color: #00A896;
}

.cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    height: 100%;
}

.cart-empty i {
    font-size: 60px;
    color: #e0e0e0;
    margin-bottom: 20px;
}

.cart-empty-text {
    font-size: 18px;
    color: #777;
    margin-bottom: 25px;
}

.cart-browse-btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: #00A896;
    color: white;
    text-decoration: none;
    font-weight: 600;
    border-radius: 6px;
    transition: background-color 0.2s;
}

.cart-browse-btn:hover {
    background-color: #008b7d;
}

.cart-items {
    flex-grow: 1;
    overflow-y: auto;
    padding: 10px 0;
}

.cart-item {
    display: flex;
    align-items: center;
    padding: 15px 25px;
    border-bottom: 1px solid #f2f2f2;
    position: relative;
}

.cart-item:hover {
    background-color: #f9f9f9;
}

.cart-item-img-link {
    display: block;
    position: relative;
    transition: transform 0.2s;
}

.cart-item-img-link:hover {
    transform: scale(1.05);
}

.cart-item-img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    margin-right: 10px;
    border: 1px solid #eee;
}

.cart-item-details {
    flex-grow: 1;
    margin-left: 15px;
}

.cart-item-title {
    font-size: 14px;
    line-height: 1.3;
    margin: 0;
    margin-bottom: 3px;
    font-weight: 600;
}

.cart-item-review {
    font-size: 12px;
    display: flex;
    align-items: center;
    margin-bottom: 3px;
}

.cart-item-review .stars {
    color: #ffc107;
    margin-right: 4px;
}

.cart-item-review .review-count {
    color: #666;
    font-size: 11px;
}

.cart-item-stock {
    font-size: 12px;
    color: #e74c3c;
    margin-bottom: 3px;
    font-weight: 500;
}

.cart-item-stock i {
    margin-right: 3px;
}

.cart-item-delivery {
    font-size: 11px;
    color: #2ecc71;
    margin-bottom: 3px;
}

.cart-item-delivery i {
    margin-right: 3px;
}

.cart-item-savings {
    font-size: 12px;
    color: #e74c3c;
    font-weight: 500;
    margin-top: 3px;
}

.cart-item-price-qty {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-item-price {
    font-weight: 600;
    color: #00A896;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.qty-btn {
    border: none;
    background: #f5f5f5;
    color: #333;
    width: 28px;
    height: 28px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
}

.qty-btn:hover {
    background: #e0e0e0;
}

.qty-input {
    width: 36px;
    text-align: center;
    border: none;
    height: 28px;
    padding: 0;
    font-size: 14px;
    outline: none;
}

.cart-item-remove {
    position: absolute;
    top: 10px;
    right: 15px;
    border: none;
    background: none;
    color: #999;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s;
}

.cart-item-remove:hover {
    color: #e53935;
}

.cart-footer {
    padding: 20px 25px;
    background-color: #fcfcfc;
    border-top: 1px solid #f2f2f2;
}

.guarantee-banner {
    background-color: #f8f9fa;
    border-radius: 6px;
    padding: 12px 15px;
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.guarantee-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #555;
}

.guarantee-item i {
    color: #00A896;
    font-size: 14px;
}

.cart-trust-badges {
    margin: 15px 0;
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.trust-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.trust-badge i {
    font-size: 18px;
    color: #555;
}

.trust-badge span {
    font-size: 10px;
    color: #777;
    text-align: center;
}

.cart-subtotal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.subtotal-label {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.subtotal-value {
    font-weight: 700;
    color: #333;
    font-size: 18px;
}

.cart-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-checkout {
    background-color: #00d1b2;
    color: white;
    width: 100%;
    padding: 12px;
    text-align: center;
    border-radius: 5px;
    margin-top: 10px;
    font-weight: 600;
    font-size: 16px;
    transition: background-color 0.3s;
    text-decoration: none;
    display: block;
}

.btn-checkout:hover {
    background-color: #00b49b;
}

.btn-continue {
    display: block;
    width: 100%;
    padding: 14px 0;
    background-color: white;
    color: #333;
    font-weight: 600;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.btn-continue:hover {
    background-color: #f5f5f5;
    border-color: #ccc;
}

.cart-promo {
    background-color: #f5faff;
    border: 1px dashed #a8d5ff;
    border-radius: 6px;
    padding: 12px 15px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-promo i {
    color: #4a98ff;
    font-size: 20px;
}

.cart-promo-text {
    font-size: 13px;
    color: #666;
}

.cart-promo-text strong {
    color: #333;
}

/* Shipping info met contrasting color */
.cart-delivery-info {
    background-color: #edf7f0;
    border: 1px solid #d1e9d9;
    border-radius: 6px;
    padding: 12px 15px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
}

.cart-delivery-info::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 5px;
    height: 100%;
    background-color: #27ae60;
}

.cart-delivery-info i {
    color: #27ae60;
    font-size: 20px;
}

.cart-delivery-info-text {
    font-size: 13px;
    color: #333;
    font-weight: 500;
    line-height: 1.3;
}

.delivery-time {
    font-size: 11px;
    color: #27ae60;
    margin-top: 2px;
}

/* Express checkout verwijderd op verzoek */

/* Mobile Styles */
@media (max-width: 576px) {
    .cart-sidebar {
        width: 100%;
        right: -100%;
        max-width: 100%;
    }
    
    .cart-item {
        padding: 12px 15px;
        position: relative;
    }
    
    .cart-item-img {
        width: 70px;
        height: 70px;
    }
    
    .cart-item-details {
        width: calc(100% - 90px);
    }
    
    .cart-footer {
        padding: 15px;
        position: sticky;
        bottom: 0;
        background: white;
        border-top: 1px solid #eee;
        box-shadow: 0 -5px 10px rgba(0, 0, 0, 0.05);
        z-index: 100;
    }
    
    .cart-items {
        max-height: calc(100vh - 240px);
        padding-bottom: 10px;
    }
    
    .cart-item-title {
        font-size: 14px;
        padding-right: 25px; /* Ruimte voor verwijder knop */
    }
    
    .cart-header {
        padding: 15px;
        position: sticky;
        top: 0;
        background: white;
        z-index: 10;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    }
    
    .cart-item-remove {
        top: 5px;
        right: 5px;
    }
    
    /* Compacte knoppen */
    .cart-actions {
        gap: 8px;
    }
    
    .btn-checkout, .btn-continue {
        padding: 12px 5px;
        font-size: 15px;
    }
    
    /* Compactere promo banners */
    .cart-promo, .cart-delivery-info, .guarantee-banner {
        padding: 10px 12px;
        margin-bottom: 10px;
    }
    
    .cart-subtotal {
        margin-bottom: 15px;
    }
    
    /* Verbeterde touch targets */
    .cart-item-qty {
        height: 32px;
    }
    
    .qty-btn {
        width: 32px;
        height: 32px;
    }
}

/* Small mobile phones */
@media (max-width: 350px) {
    .cart-item-img {
        width: 55px;
        height: 55px;
    }
    
    .cart-item-details {
        width: calc(100% - 70px);
    }
}

/* Cart Notification Badge Animation */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

.cart-count.animated {
    animation: pulse 0.5s;
}

/* Adding to cart animation */
.add-to-cart-animation {
    position: fixed;
    width: 20px;
    height: 20px;
    background-color: #00A896;
    border-radius: 50%;
    z-index: 1100;
    pointer-events: none;
}
