* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, #111827, #1f2937, #0f172a);
    color: #fff;
    position: relative;
    overflow-x: hidden;
}

.bg {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(99,102,241,0.25), transparent 25%),
        radial-gradient(circle at 80% 30%, rgba(16,185,129,0.20), transparent 25%),
        radial-gradient(circle at 50% 80%, rgba(239,68,68,0.18), transparent 25%);
    pointer-events: none;
}

.container {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
}

.card {
    width: 100%;
    max-width: 950px;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.35);
}

.topo {
    margin-bottom: 24px;
    text-align: center;
}

.topo h1 {
    font-size: 36px;
    margin-bottom: 10px;
}

.topo p {
    color: #d1d5db;
}

.bloco {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.hidden {
    display: none !important;
}

input {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    border: none;
    outline: none;
    font-size: 16px;
}

button {
    border: none;
    border-radius: 14px;
    padding: 14px 18px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: .2s ease;
    background: #4f46e5;
    color: white;
}

button:hover {
    transform: translateY(-1px);
    opacity: .95;
}

button:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

button.secundario {
    background: #0ea5e9;
}

button.perigo {
    background: #ef4444;
}

button.pronto-ativo {
    background: #22c55e;
}

.acoes-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.caixa-form {
    margin-top: 8px;
    background: rgba(255,255,255,0.05);
    padding: 16px;
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.linha-topo-sala {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.subinfo {
    color: #d1d5db;
    margin-top: 6px;
}

.painel {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 16px;
}

.painel-bloco {
    background: rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 18px;
    margin-top: 16px;
}

.painel-bloco h3 {
    margin-bottom: 12px;
}

.lista-jogadores {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.jogador-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: rgba(255,255,255,0.06);
    border-radius: 14px;
    padding: 12px 14px;
}

.jogador-nome {
    font-weight: bold;
    word-break: break-word;
}

.badge {
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: bold;
}

.badge.pronto {
    background: rgba(34,197,94,0.2);
    color: #86efac;
}

.badge.aguardando {
    background: rgba(234,179,8,0.18);
    color: #fde68a;
}

.info-box {
    margin-top: 14px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(255,255,255,0.06);
    color: #e5e7eb;
}

.alerta {
    margin-bottom: 16px;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(239,68,68,0.16);
    color: #fecaca;
}

.sorteio {
    margin-top: 18px;
}

.sorteio-box,
.resultado-box {
    background: rgba(255,255,255,0.06);
    border-radius: 20px;
    padding: 28px;
    text-align: center;
}

.spinner {
    width: 70px;
    height: 70px;
    border: 6px solid rgba(255,255,255,0.15);
    border-top: 6px solid #a78bfa;
    border-radius: 50%;
    margin: 0 auto 16px;
    animation: girar 0.8s linear infinite;
}

@keyframes girar {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.resultado-box h2 {
    font-size: 32px;
    margin-bottom: 12px;
}

.resultado-box p {
    font-size: 22px;
    font-weight: bold;
    color: #f9fafb;
}

.lista-votacao {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@media (max-width: 768px) {
    .topo h1 {
        font-size: 28px;
    }

    .acoes-grid,
    .painel {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 18px;
        border-radius: 18px;
    }

    .resultado-box p {
        font-size: 18px;
    }
}