/* Cart Page Styles */
.cart-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 120px 20px 40px;
}

.page-title {
    font-size: 24px;
    margin-bottom: 20px;
    text-align: center;
}

/* Empty Cart Styles */
.empty-cart {
    text-align: center;
    padding: 40px 20px;
    background-color: #f9f9f9;
    border-radius: 8px;
    margin-bottom: 20px;
}

.empty-cart p {
    margin-bottom: 20px;
    color: #666;
}

.continue-shopping {
    display: inline-block;
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
}

/* Cart Content Styles */
.cart-content {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.cart-items {
    flex: 2;
    min-width: 300px;
}

.cart-item {
    display: flex;
    background-color: #fff;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border: 1px solid #eee;
    transition: all 0.3s ease;
}

.cart-item:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.item-image {
    flex: 0 0 80px;
    margin-right: 15px;
}

.item-image img {
    max-width: 100%;
    border-radius: 4px;
    height: auto;
}

.item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.item-name {
    font-size: 16px;
    margin: 0 0 5px;
    color: #333;
}

.item-price {
    font-size: 14px;
    color: #666;
}

.item-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Quantity Controls */
.quantity-control {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

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

.quantity-btn:hover {
    background: #e9e9e9;
}

.quantity-input {
    width: 40px;
    text-align: center;
    border: none;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    height: 30px;
}

.item-subtotal {
    font-weight: 600;
    font-size: 16px;
    min-width: 80px;
    text-align: right;
}

.remove-btn {
    background: none;
    border: none;
    color: #f44336;
    cursor: pointer;
    font-size: 16px;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.remove-btn:hover {
    color: #d32f2f;
}

/* Cart Summary Styles */
.cart-summary {
    flex: 1;
    min-width: 250px;
    background-color: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    border: 1px solid #eee;
    align-self: flex-start;
    position: sticky;
    top: 120px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.summary-row.total {
    font-weight: 700;
    font-size: 18px;
    margin-top: 15px;
    border-bottom: none;
    padding-top: 15px;
    border-top: 2px solid #ddd;
}

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

.btn {
    display: block;
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.checkout-btn {
    background-color: #4CAF50;
    color: white;
}

.checkout-btn:hover {
    background-color: #45a049;
}

.continue-shopping {
    background-color: #2196F3;
    color: white;
}

.continue-shopping:hover {
    background-color: #0b7dda;
}

.clear-cart {
    background-color: #f44336;
    color: white;
}

.clear-cart:hover {
    background-color: #d32f2f;
}

/* Debug Panel */
.debug-section {
    margin-top: 40px;
    border-radius: 8px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cart-page {
        padding-top: 100px; /* Adjusted for mobile header height */
    }
    
    .cart-content {
        flex-direction: column;
    }
    
    .cart-item {
        flex-wrap: wrap;
    }
    
    .item-controls {
        width: 100%;
        margin-top: 15px;
        justify-content: space-between;
    }
    
    .cart-summary {
        position: static;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .cart-page {
        padding-top: 80px; /* Further reduced for very small screens */
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .page-title {
        font-size: 20px;
    }
    
    .cart-item {
        padding: 10px;
    }
    
    .item-image {
        flex: 0 0 60px;
    }
    
    .item-name {
        font-size: 14px;
    }
    
    .quantity-btn, .quantity-input {
        height: 28px;
    }
    
    .quantity-input {
        width: 30px;
    }
    
    .remove-btn {
        font-size: 14px;
    }
} 