/* Cart Page Styles */
.cart-page {
    padding: 2rem 0;
}

.cart-page h1 {
    margin-bottom: 2rem;
    color: #333;
    font-size: 2rem;
    text-align: center;
}

/* Cart Items Container */
.cart-items {
    margin-bottom: 2rem;
}

/* Individual Cart Item */
.cart-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: box-shadow 0.3s ease;
}

.cart-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Item Image */
.item-image {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    border-radius: 4px;
    overflow: hidden;
    background-color: #f8f8f8;
}

.item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Item Details */
.item-details {
    flex-grow: 1;
}

.item-details h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.2rem;
    color: #333;
}

.item-details p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

/* Item Actions */
.item-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1rem;
    min-width: 200px;
}

.item-price {
    font-size: 1.3rem;
    font-weight: bold;
    color: #333;
}

/* Quantity Controls */
.item-quantity {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.quantity-controls {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.quantity-btn {
    background-color: #f8f8f8;
    border: none;
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.quantity-btn:hover {
    background-color: #e0e0e0;
}

.quantity-controls input[type="number"] {
    width: 50px;
    text-align: center;
    border: none;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    padding: 0.5rem;
    -moz-appearance: textfield;
}

.quantity-controls input[type="number"]::-webkit-outer-spin-button,
.quantity-controls input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Remove Item Button */
.remove-item-btn {
    background-color: #ff4444;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.remove-item-btn:hover {
    background-color: #cc0000;
}

/* Cart Summary */
.cart-summary {
    background-color: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 2rem;
}

.total-info {
    text-align: right;
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    color: #333;
}

.cart-summary-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

/* Buttons */
.btn-checkout {
    background-color: #4CAF50;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-checkout:hover {
    background-color: #45a049;
}

.btn-clear-cart {
    background-color: #f44336;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-clear-cart:hover {
    background-color: #d32f2f;
}

/* Empty Cart State */
.empty-cart {
    text-align: center;
    padding: 3rem 0;
}

.empty-cart p {
    color: #666;
    margin-bottom: 1.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cart-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .item-image {
        width: 100%;
        height: 200px;
    }

    .item-actions {
        width: 100%;
        align-items: flex-start;
    }

    .cart-summary-actions {
        flex-direction: column;
    }

    .btn-checkout,
    .btn-clear-cart {
        width: 100%;
    }
}

/* Loading State */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Success Message */
.alert-success {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    padding: 1rem;
    background-color: #4CAF50;
    color: white;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
} 