/* Cart Sidebar Styles */
/* Cart Overlay */
.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(26, 18, 11, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 9998;
    backdrop-filter: blur(4px);
}

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

/* Cart Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 420px;
    max-width: 100vw;
    height: 100vh;
    background: #fdfcfb;
    z-index: 9999;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 40px rgba(26, 18, 11, 0.15);
}

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

/* Header */
.cart-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px;
    border-bottom: 1px solid rgba(212, 165, 116, 0.15);
    background: #fff;
}

.cart-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.cart-title svg {
    color: #5c3d2e;
}

.cart-title h2 {
    font-family: 'Libre Baskerville', serif;
    font-size: 20px;
    font-weight: 700;
    color: #1a120b;
    margin: 0;
}

.cart-badge {
    background: #d4a574;
    color: #1a120b;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
}

.cart-close-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: #f5ebe0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #5c3d2e;
}

.cart-close-btn:hover {
    background: #d4a574;
    color: #fff;
}

/* Content */
.cart-sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

/* Empty State */
.cart-empty {
    text-align: center;
    padding: 48px 24px;
}

.cart-empty-icon {
    width: 100px;
    height: 100px;
    background: #f5ebe0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    color: #8b5a3c;
}

.cart-empty h3 {
    font-family: 'Libre Baskerville', serif;
    font-size: 20px;
    color: #1a120b;
    margin-bottom: 8px;
}

.cart-empty p {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: #8b7355;
    margin-bottom: 24px;
}

.cart-browse-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #1a120b;
    color: #fff;
    padding: 14px 28px;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cart-browse-btn:hover {
    background: #3c2415;
    transform: translateY(-2px);
}

/* Cart Items */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.cart-item {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: #fff;
    border-radius: 16px;
    border: 1px solid rgba(212, 165, 116, 0.15);
    transition: all 0.3s ease;
}

.cart-item:hover {
    box-shadow: 0 4px 20px rgba(26, 18, 11, 0.08);
}

.cart-item-thumb {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f5ebe0;
}

.cart-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.cart-item-name {
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: #1a120b;
    text-decoration: none;
    line-height: 1.3;
}

.cart-item-name:hover {
    color: #8b5a3c;
}

.cart-item-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.cart-item-variation {
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    color: #8b7355;
    background: #f5ebe0;
    padding: 2px 8px;
    border-radius: 4px;
}

.cart-item-price {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #5c3d2e;
}

.cart-item-quantity-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
}

/* Quantity Control */
.quantity-control {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #f5ebe0;
    border-radius: 8px;
    padding: 4px;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border: none;
    background: #fff;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #5c3d2e;
}

.qty-btn:hover {
    background: #d4a574;
    color: #fff;
}

.cart-item-quantity {
    width: 40px;
    height: 28px;
    border: none;
    background: transparent;
    text-align: center;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #1a120b;
    -moz-appearance: textfield;
}

.cart-item-quantity::-webkit-outer-spin-button,
.cart-item-quantity::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.remove-cart-item {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #8b7355;
}

.remove-cart-item:hover {
    background: #fee2e2;
    color: #dc2626;
}

/* Footer */
.cart-sidebar-footer {
    padding: 24px;
    border-top: 1px solid rgba(212, 165, 116, 0.15);
    background: #fff;
}

/* Coupon */
.cart-coupon {
    margin-bottom: 20px;
}

.coupon-form {
    display: flex;
    gap: 8px;
}

.coupon-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid rgba(212, 165, 116, 0.3);
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: #1a120b;
    background: #fdfcfb;
}

.coupon-input:focus {
    outline: none;
    border-color: #d4a574;
}

.coupon-btn {
    padding: 12px 20px;
    border: none;
    background: #f5ebe0;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #5c3d2e;
    cursor: pointer;
    transition: all 0.3s ease;
}

.coupon-btn:hover {
    background: #d4a574;
    color: #fff;
}

/* Totals */
.cart-totals {
    margin-bottom: 20px;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: #5c4033;
    border-bottom: 1px solid rgba(212, 165, 116, 0.1);
}

.cart-total-row.discount span:last-child {
    color: #16a34a;
}

.cart-total-row.total {
    font-size: 18px;
    font-weight: 700;
    color: #1a120b;
    border-bottom: none;
    padding-top: 16px;
}

/* Actions */
.cart-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.cart-view-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px;
    border: 1px solid rgba(212, 165, 116, 0.4);
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: #5c3d2e;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cart-view-btn:hover {
    background: #f5ebe0;
    border-color: #d4a574;
}

.cart-checkout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px;
    background: #1a120b;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.cart-checkout-btn:hover {
    background: #3c2415;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(26, 18, 11, 0.2);
}

/* Secure Badge */
.cart-secure {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    color: #8b7355;
}

.cart-secure svg {
    color: #16a34a;
}

/* Responsive */
@media (max-width: 480px) {
    .cart-sidebar {
        width: 100vw;
    }
    
    .cart-sidebar-header {
        padding: 20px 16px;
    }
    
    .cart-sidebar-content {
        padding: 16px;
    }
    
    .cart-sidebar-footer {
        padding: 20px 16px;
    }
    
    .cart-item {
        padding: 12px;
    }
    
    .cart-item-thumb {
        width: 64px;
        height: 64px;
    }
}
