/* ARQUIVO: style.css */
:root {
    --bg-color: #121212; --caixa-bg: rgba(255, 255, 255, 0.1); --text-color: #ffffff;
    --primary-color: #fd0041; --hover-color: #c90033; --border-color: #ffffff;
    --sucesso: #00ffaa; 
}

[data-theme="light"] {
    --bg-color: #f0f0f0; --caixa-bg: #ffffff; --text-color: #333333;
    --primary-color: #fd0041; --hover-color: #c90033; --border-color: #cccccc;
    --sucesso: #00cc88;
}

body {
    background-color: var(--bg-color); color: var(--text-color);
    font-family: "Anta", sans-serif; font-weight: 400;
    margin: 0; display: flex; justify-content: center; align-items: center;
    height: 100vh; transition: background-color 0.3s, color 0.3s; overflow: hidden; 
}

button, select, input { font-family: "Anta", sans-serif; }

.tela {
    display: none; flex-direction: column; align-items: center;
    background-color: var(--caixa-bg); padding: 40px; border-radius: 15px;
    border: 2px solid var(--border-color); box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    width: 95%; max-width: 700px; text-align: center; z-index: 10; 
}

.tela.ativa { display: flex; }

.logo-principal {
    max-width: 250px; height: auto; margin-bottom: 20px; display: block; drop-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

h1 { margin-top: 0; font-size: 32px; margin-bottom: 30px; color: var(--text-color); }
h2 { margin-top: 0; color: var(--primary-color); }
#tela-menu h1 { color: var(--primary-color); }

button {
    background-color: var(--primary-color); color: white; border: none;
    padding: 15px 30px; font-size: 18px; font-weight: bold; border-radius: 8px;
    cursor: pointer; width: 100%; margin-bottom: 15px; transition: 0.2s;
}
button:hover { background-color: var(--hover-color); transform: scale(1.02); }
.btn-voltar { background-color: #555; }
.btn-voltar:hover { background-color: #333; }
.btn-teste { background-color: var(--sucesso); color: #121212; margin-top: 10px; }
.btn-teste:hover { background-color: #00cc88; }

label { display: block; text-align: left; margin-bottom: 5px; font-weight: bold; width: 100%; color: var(--text-color); }

select, input[type="number"], input[type="text"] {
    width: 100%; padding: 12px 15px; margin-bottom: 20px;
    border-radius: 8px; border: 2px solid var(--primary-color);
    background-color: var(--caixa-bg); color: var(--text-color);
    font-size: 16px; font-weight: bold; box-sizing: border-box;
    cursor: pointer; outline: none; transition: border-color 0.3s, box-shadow 0.3s;
    appearance: none; -webkit-appearance: none; -moz-appearance: none;
}

select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fd0041' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat; background-position: right 15px center; background-size: 18px;
    padding-right: 40px;
}
select option { background-color: var(--bg-color); color: var(--text-color); font-weight: bold; }
select:focus, input[type="number"]:focus, input[type="text"]:focus { border-color: var(--sucesso); box-shadow: 0 0 10px rgba(0, 255, 170, 0.4); }

.opcao-toggle { display: flex; justify-content: space-between; align-items: center; width: 100%; margin-bottom: 20px; font-size: 18px; font-weight: bold; }
.caixa-bonus { background: rgba(255, 204, 0, 0.1); border: 1px solid #ffcc00; padding: 15px; border-radius: 8px; margin-bottom: 10px; width: 100%; box-sizing: border-box; }

#aviso-total, #aviso-total-single {
    font-size: 18px; color: var(--sucesso); font-weight: bold; margin-bottom: 20px;
    background-color: rgba(0, 255, 170, 0.1); padding: 10px; border-radius: 8px; width: 100%; box-sizing: border-box;
}

.redes-sociais { display: flex; gap: 20px; margin-top: 20px; }
.icon-box {
    display: flex; justify-content: center; align-items: center; width: 50px; height: 50px;
    background-color: var(--caixa-bg); border: 2px solid var(--border-color); border-radius: 10px;
    font-size: 24px; color: var(--text-color); text-decoration: none; transition: 0.2s;
}
.icon-box:hover { background-color: var(--primary-color); color: white; border-color: var(--primary-color); transform: translateY(-5px); }

.pergunta-box { background: rgba(0, 0, 0, 0.3); border: 2px solid var(--primary-color); border-radius: 10px; padding: 20px; width: 100%; box-sizing: border-box; margin-bottom: 25px; box-shadow: 0 4px 15px rgba(253, 0, 65, 0.2); }
.pergunta-texto { font-size: 24px; font-weight: bold; color: #fff; transition: color 0.3s; margin: 0;}
.alternativas-container { width: 100%; display: flex; flex-direction: column; gap: 10px; }

.alternativa-card {
    background: rgba(255, 255, 255, 0.05); border: 2px solid var(--border-color); border-radius: 8px;
    padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; transition: all 0.3s ease;
}

/* CLASSES DINÂMICAS PARA SINGLEPLAYER */
.alternativa-card.clicavel { cursor: pointer; }
.alternativa-card.clicavel:hover { border-color: var(--primary-color); transform: scale(1.02); background: rgba(255, 255, 255, 0.1); }
.alternativa-card.selecionada { border-color: #ffcc00 !important; box-shadow: 0 0 15px rgba(255, 204, 0, 0.4) !important; background: rgba(255, 204, 0, 0.15) !important; }

.alt-letra { font-weight: bold; color: var(--primary-color); font-size: 22px; margin-right: 10px; }
.alt-texto { font-size: 20px; text-align: left; flex-grow: 1; }

.votos-badge {
    background: rgba(0, 0, 0, 0.5); border: 1px solid var(--primary-color); padding: 5px 15px;
    border-radius: 20px; font-size: 18px; font-weight: bold; color: var(--sucesso); min-width: 60px; text-align: center;
}

.alternativa-card.resposta-certa { background: rgba(0, 255, 170, 0.2) !important; border-color: var(--sucesso) !important; transform: scale(1.05) !important; box-shadow: 0 0 20px rgba(0, 255, 170, 0.4) !important; z-index: 10; }
.alternativa-card.resposta-certa .alt-letra { color: var(--sucesso); }
.alternativa-card.resposta-certa .votos-badge { background: var(--sucesso); color: #121212; border-color: var(--sucesso); }
.alternativa-card.resposta-errada { background: rgba(253, 0, 65, 0.1); border-color: var(--primary-color); opacity: 0.5; transform: scale(0.98); }

.justificativa-card {
    background: rgba(255, 255, 255, 0.1); border-left: 5px solid var(--sucesso); border-radius: 8px; padding: 15px; margin-top: 20px;
    text-align: left; width: 100%; box-sizing: border-box; animation: slideDown 0.5s ease-out; display: none;
}
.justi-header { color: var(--sucesso); font-weight: bold; font-size: 18px; margin-bottom: 8px; }
#justificativa-texto { font-size: 16px; line-height: 1.5; margin: 0; color: #eee; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

.tempo-container { width: 100%; margin-top: 25px; }
#timer-text { font-size: 22px; font-weight: bold; color: var(--text-color); margin-bottom: 5px; }
.barra-tempo-fundo { width: 100%; height: 20px; background: rgba(0, 0, 0, 0.5); border-radius: 10px; overflow: hidden; border: 1px solid var(--border-color); }
#barra-tempo-fill { height: 100%; width: 100%; background: var(--primary-color); transition: width 1s linear, background-color 0.3s; }

.caixa-resultado { margin-top: 20px; padding: 15px; border-radius: 10px; width: 100%; box-sizing: border-box; font-size: 22px; font-weight: bold; display: none; line-height: 1.4; }
.resultado-sucesso { background: rgba(0, 255, 170, 0.2); border: 2px solid var(--sucesso); color: var(--sucesso); }
.resultado-falha { background: rgba(253, 0, 65, 0.2); border: 2px solid var(--primary-color); color: #fff; }
#dica-teclado { font-size: 14px; color: #888; margin-top: 20px; font-style: italic; }

.chat-bubbles-container {
    position: fixed; bottom: 20px; left: 30px; display: flex; flex-direction: column; gap: 12px; pointer-events: none; z-index: 9999; max-height: 80vh; justify-content: flex-end; overflow: hidden; width: 400px; 
}
.chat-bubble { display: flex; align-items: flex-end; gap: 10px; animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards, fadeOut 0.4s ease-in 3.5s forwards; }
.chat-avatar { width: 45px; height: 45px; border-radius: 50%; border: 2px solid var(--primary-color); background-color: var(--caixa-bg); object-fit: cover; flex-shrink: 0; }
.chat-text { background: rgba(0, 0, 0, 0.85); border: 1px solid var(--primary-color); padding: 8px 15px; border-radius: 18px; border-bottom-left-radius: 0; color: #fff; font-size: 18px; box-shadow: 0 4px 10px rgba(0,0,0,0.5); word-break: break-word; }
.chat-text b { color: var(--primary-color); margin-right: 5px; }

@keyframes popIn { from { opacity: 0; transform: translateX(-30px) scale(0.8); } to { opacity: 1; transform: translateX(0) scale(1); } }
@keyframes fadeOut { from { opacity: 1; transform: scale(1); } to { opacity: 0; transform: scale(0.8); } }

.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.8); z-index: 10000;
    display: none; justify-content: center; align-items: center;
}
.modal-overlay.ativo { display: flex; animation: fadeIn 0.3s ease; }
.modal-box {
    background: var(--bg-color); border: 2px solid var(--primary-color);
    border-radius: 15px; padding: 30px; max-width: 400px; text-align: center;
    box-shadow: 0 10px 30px rgba(253, 0, 65, 0.3);
    animation: slideDownModal 0.3s ease;
}
.modal-icon { font-size: 50px; color: #ffcc00; margin-bottom: 15px; }
.modal-box p { font-size: 18px; line-height: 1.5; margin-bottom: 25px; color: var(--text-color); }
.modal-box button { margin-bottom: 0; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideDownModal { from { transform: translateY(-50px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }