* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    user-select: none; 
}

body {
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background-color: #1a1a1a;
}

/* Zonas de Toque */
.zona-jogador {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Empurra o placar pras pontas */
    align-items: center;
    transition: background-color 0.2s, opacity 0.3s;
    opacity: 0.5;
    pointer-events: none;
    padding: 20px;
}

.zona-j1 { background-color: #dc2626; color: white; transform: rotate(180deg); }
.zona-j2 { background-color: #2563eb; color: white; }

.zona-jogador.ativo { opacity: 1; pointer-events: auto; cursor: pointer; }
.zona-jogador.bloqueado { opacity: 0.2; pointer-events: none; }

.placar { font-size: 1.5rem; font-weight: bold; width: 100%; text-align: center; }
.status-texto { font-size: 2rem; font-weight: 900; margin: auto; }

/* Painel Central */
.painel-central {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    background-color: #fff;
    color: #000;
    text-align: center;
    z-index: 10;
    height: 140px; /* Altura fixa para caber as duas perguntas */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

#container-perguntas { width: 100%; }

.pergunta-dupla {
    font-size: 1.1rem;
    padding: 10px;
    width: 100%;
}

.pergunta-j1 { transform: rotate(180deg); color: #dc2626; }
.pergunta-j2 { color: #2563eb; }
.linha-divisoria { width: 100%; height: 2px; background-color: #e5e7eb; }

/* Botões e Úteis */
.hidden { display: none !important; }

button {
    padding: 15px;
    font-size: 1.1rem;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin: 5px;
    width: 220px;
}

.btn-iniciar { background-color: #10b981; color: white; padding: 15px 30px; position: absolute;}
.btn-correto { background-color: #10b981; color: white; }
.btn-errado { background-color: #ef4444; color: white; }

.area-botoes, .area-validacao {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: auto;
}

.tempo-resposta {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 10px;
    background: rgba(0,0,0,0.3);
    padding: 0 20px;
    border-radius: 10px;
}

.cronometro-central { font-size: 3rem; font-weight: bold; position: absolute;}
.resposta-correta { font-size: 1.2rem; background: rgba(0,0,0,0.4); padding: 10px; border-radius: 6px; margin-bottom: 10px; }

/* TELA SETUP */
.painel-setup {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: #1a1a1a;
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    z-index: 100;
}

.titulo-setup {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: #10b981;
}

.form-grupo {
    width: 100%;
    max-width: 350px;
    margin-bottom: 20px;
}

.form-grupo label {
    display: block;
    font-size: 0.9rem;
    font-weight: bold;
    margin-bottom: 8px;
    color: #9ca3af;
}

.form-grupo input, .form-grupo select {
    width: 100%;
    padding: 12px;
    font-size: 1.1rem;
    border-radius: 8px;
    border: 2px solid #374151;
    background-color: #374151;
    color: white;
}

.btn-start {
    width: 100%;
    max-width: 350px;
    padding: 15px;
    font-size: 1.2rem;
    background-color: #10b981;
    margin-top: 10px;
}

/* TELA MÚLTIPLA ESCOLHA */
.tela-multipla {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background-color: #f3f4f6;
    display: flex;
    flex-direction: column;
    z-index: 50;
}

.cabecalho-multipla {
    background-color: #1f2937;
    color: white;
    padding: 20px;
    text-align: center;
    font-size: 1.5rem;
}

.pergunta-container {
    padding: 40px 20px;
    text-align: center;
    font-size: 1.5rem;
    color: #111827;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.grid-opcoes {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
    padding: 20px;
    margin-bottom: 20px;
}

.btn-opcao {
    background-color: #fff;
    color: #1f2937;
    border: 2px solid #d1d5db;
    padding: 20px;
    font-size: 1.2rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* CENTRALIZAÇÃO DAS RESPOSTAS */
.grid-opcoes {
    display: flex;
    flex-direction: column;
    align-items: center; /* Centraliza no eixo horizontal */
    gap: 15px;
    padding: 20px;
    margin-bottom: 20px;
    width: 100%;
}

.btn-opcao {
    width: 90%;
    max-width: 400px; /* Limita a largura em telas grandes */
    background-color: #fff;
    color: #1f2937;
    border: 2px solid #d1d5db;
    padding: 18px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-align: center; /* Garante o texto no meio do botão */
    transition: transform 0.1s, background-color 0.2s;
}

.btn-opcao:active {
    transform: scale(0.95); /* Efeito de afundar ao clicar */
    background-color: #e5e7eb;
}

/* SISTEMA DE MODAL */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
}

.modal-conteudo {
    background: #fff;
    color: #111827;
    padding: 30px;
    border-radius: 16px;
    text-align: center;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    animation: zoomIn 0.3s ease;
}

.modal-conteudo h2 { color: #10b981; margin-bottom: 15px; }
.modal-conteudo p { font-size: 1.2rem; margin-bottom: 25px; line-height: 1.5; white-space: pre-line; }

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* RANKING (Setup) */
.ranking-container {
    width: 100%;
    max-width: 350px;
    background: #374151;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    text-align: center;
}

.ranking-container h3 { color: #f59e0b; margin-bottom: 10px; font-size: 1.1rem; }

#lista-ranking {
    list-style: none;
    margin-bottom: 15px;
    text-align: left;
}

#lista-ranking li {
    display: flex;
    justify-content: space-between;
    padding: 5px 0;
    border-bottom: 1px solid #4b5563;
}

.btn-limpar-ranking {
    background: #ef4444; color: white; border: none;
    padding: 8px 15px; border-radius: 6px; cursor: pointer;
    font-size: 0.9rem;
}