/* Estilos para el contenedor del traductor */
.translate-container {
    position: fixed;
    bottom: 140px; /* Se posiciona justo encima del entertainment-toggle */
    left: 20px; /* Alineado al lado izquierdo */
    z-index: 1000;
}

.translate-toggle {
    background: #3a25f7;
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.translate-toggle:hover {
    background: #3a5a9f;
    transform: scale(1.1);
}

/* Estilos para el modal del traductor */
.translate-modal {
    position: fixed;
    bottom: 200px; /* El modal se abre encima del botón traducir */
    left: 20px; /* Alineado al lado izquierdo igual que el botón */
    width: 350px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    display: none;
    z-index: 1001;
    overflow: hidden;
}

.translate-modal.show {
    display: block;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.translate-header {
    background: #3a25f7;
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.translate-header h3 {
    margin: 0;
    font-size: 18px;
}

.translate-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.translate-body {
    padding: 15px;
}

.language-selectors {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    gap: 10px;
}

.language-select {
    flex: 1;
    padding: 8px;
    border-radius: 5px;
    border: 1px solid #ddd;
    background: white;
    font-size: 14px;
}

.swap-btn {
    background: #f0f0f0;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.swap-btn:hover {
    background: #e0e0e0;
}

.translate-input-container,
.translate-output-container {
    position: relative;
    margin-bottom: 15px;
}

.translate-input,
.translate-output {
    width: 100%;
    min-height: 100px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    resize: none;
    font-size: 14px;
    color: #000; /* Color negro para ambos */
}

.translate-output {
    background: #f9f9f9;
    min-height: 100px;
    overflow-y: auto;
    color: #000; /* Asegura que el texto traducido también sea negro */
}

.translate-action-btn {
    background: #3a25f7;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    margin-top: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.translate-action-btn:hover {
    background: #3a5a9f;
}

/* Responsive */
@media (max-width: 768px) {
    .translate-modal {
        width: 300px;
        left: 10px; /* Modal se ajusta al lado izquierdo */
    }
}

@media (max-width: 480px) {
    .translate-container {
        bottom: 120px; /* Ajusta la posición del botón traducir en pantallas pequeñas */
    }
    
    .translate-modal {
        width: calc(100% - 20px);
        left: 10px; /* Modal sigue alineado al lado izquierdo */
        bottom: 180px;
    }
}