/* Estilo para el carrito de compras */
.carritoflotante {  
    position: fixed;  
    bottom: 20px;  
    right: 20px;  
    background-color: rgba(182, 182, 182, 0.9);  
    border-radius: 50%;  
    padding: 15px;  
    color: white;  
    font-size: 1.5rem;  
    display: flex;  
    align-items: center;  
    justify-content: center;  
    transition: transform 0.2s;  
    cursor: pointer;  
    z-index: 999;
}  

.carritoflotante:hover {  
    transform: scale(1.3);  
}

/* Animación de rebote en el carrito */
.carritoflotante.bounce {
    animation: bounce 0.6s ease-in-out;
}

@keyframes bounce {
    0% { transform: scale(1); }
    30% { transform: scale(1.2); }
    50% { transform: scale(1); }
    70% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* Estilo para el carrito lateral */
.cart-popup {
    position: fixed;
    left: 0;
    top: 0;
    width: 300px;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    display: none;
    flex-direction: column;
    padding: 20px;
    box-shadow: 5px 0 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    border-bottom: 1px solid #444;
    margin-bottom: 15px;
}

.close-btn {
    background-color: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    margin: 20px 0;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #444;
    align-items: center;
}

.cart-item button {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 3px 8px;
    border-radius: 3px;
    cursor: pointer;
}

.cart-footer {
    text-align: center;
    padding-top: 15px;
    border-top: 1px solid #444;
}

.cart-footer span {
    display: block;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.cart-footer button {
    background-color: #25af21;
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1.1rem;
    border-radius: 5px;
    width: 100%;
    transition: background 0.3s;
}

.cart-footer button:hover {
    background-color: #1f8e16;
}

/* Estilo para las alertas emergentes (toast) */
.toast-container {
    position: fixed;
    top: 10%;
    right: 10px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background-color: #333;
    color: white;
    border-radius: 5px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
    min-width: 250px;
}

.toast.hide {
    opacity: 0;
}

.toast.success {
    background-color: #28a745;
}

.toast.error {
    background-color: #dc3545;
}

