/* Layout Geral */
.content { height: 100vh; overflow: hidden; display: flex; flex-direction: column; padding: 5px 15px; background-color: #f0f2f5; }
.header-main { display: flex; justify-content: space-between; align-items: center; margin-bottom: 5px; flex-shrink: 0; }
.header-main h1 { font-size: 1.6rem; color: #000; font-weight: bold; margin: 0; }

.filtros-top-global { display: flex; gap: 8px; align-items: center; }
.filtro-pill { background: black; color: white; padding: 4px 12px; border-radius: 20px; display: flex; align-items: center; gap: 6px; height: 26px; box-shadow: 0 2px 4px rgba(0,0,0,0.2); }
.filtro-pill label { font-weight: 800; font-size: 0.5rem; color: white ; margin: 0; }
.filtro-pill select { background: black; color: white; border: none; font-weight: bold; font-size: 0.7rem; outline: none; cursor: pointer; }

.sorteio-layout { display: grid; grid-template-columns: 280px 1fr; gap: 10px; flex-grow: 1; overflow: hidden; }

/* Coluna Participantes */
.col-selecao { background: white; border-radius: 8px; padding: 8px; display: flex; flex-direction: column; box-shadow: 0 2px 4px rgba(0,0,0,0.05); }
.card-header-acoes-central { margin-bottom: 5px; text-align: center; }
.card-header-acoes-central h3 { font-size: 0.8rem; color: #2c3e50; font-weight: 800; margin-bottom: 3px; }
.grupo-btns-selecao { display: flex; gap: 5px; justify-content: center; margin-bottom: 5px;}
.btn-util-lista { padding: 1px 8px; font-size: 0.55rem; font-weight: bold; border-radius: 4px; border: 1px solid #ddd; cursor: pointer; background: #f8f9fa; }
.btn-danger { color: #e74c3c; border-color: #fadbd8; }

.lista-checks { flex-grow: 1; overflow-y: auto; border: 1px solid #eee; border-radius: 6px; }
.item-check { display: flex; align-items: center; gap: 6px; padding: 2px 6px; border-bottom: 1px solid #f8f9fa; font-size: 0.6rem; cursor: pointer; }
.item-check:hover { background: #f0f7ff; }
.participant-name { flex-grow: 1; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.label-special-flag { font-size: 0.48rem; font-weight: 900; color: #2c3e50; background: #f1c40f; padding: 1px 3px; border-radius: 3px; cursor: pointer; display: flex; align-items: center; gap: 2px; }

/* Resultados */
.col-resultados { background: white; border-radius: 8px; padding: 10px; overflow: hidden; border: 1px solid #eee; display: flex; flex-direction: column; }
.header-secao-flex { display: flex; justify-content: center; align-items: center; border-bottom: 2px solid #27ae60; padding-bottom: 3px; margin-bottom: 5px; position: relative;}
.titulo-5s { color: #2c3e50; font-weight: 900; margin: 0; font-size: 0.85rem; text-transform: uppercase; }
.btn-limpar-sorteio { position: absolute; right: 0; background: none; border: none; font-size: 0.6rem; cursor: pointer; color: black; font-weight: bold; }

/* Cargos em 3 Colunas */
.cargos-individuais-container { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.cargo-item label { font-size: 1rem; font-weight: 800; color: #2c3e50; text-transform: uppercase; margin-bottom: 2px; text-align: center; display: block; }
.campo-com-botao { display: flex; gap: 4px; align-items: center; }
.resultado-nome { flex-grow: 1; background: #fdfdfd; border: 1px solid #3498db; padding: 4px; border-radius: 5px; font-weight: bold; font-size: 0.75rem; min-height: 28px; display: flex; align-items: center; justify-content: center; text-align: center; line-height: 1.1; }
.btn-sortear-unico { width: 28px; height: 28px; background: #27ae60; color: white; border: none; border-radius: 5px; cursor: pointer; font-size: 0.7rem; flex-shrink: 0; }

/* Bloco Baias */
.header-com-botao-linha { border-left: 4px solid #3498db; background: #f1f7fe; padding: 4px 10px; margin-top: 5px; display: flex; justify-content: space-between; align-items: center; height: 35px; }
.titulo-baias { font-size: 0.75rem; color: #2c3e50; font-weight: 900; margin: 0; }
.controles-distribuicao-unica-linha { display: flex; align-items: center; gap: 5px; }
.filtro-trimestre-box { display: flex; gap: 2px; background: white; padding: 2px; border-radius: 4px; border: 1px solid #ddd; height: 24px; align-items: center; }
.filtro-trimestre-box select, .filtro-trimestre-box input { border: none; font-size: 0.65rem; font-weight: bold; outline: none; background: transparent; }
.filtro-trimestre-box input { width: 50px; text-align: center; border-left: 1px solid #eee; }
.btn-baias { width: 24px; height: 24px; border-radius: 4px; border: none; color: white; cursor: pointer; font-size: 0.65rem; }

/* MAPA GEOMÉTRICO (Fiel à imagem) */
.geometric-map-container { display: flex; flex-direction: row-reverse; justify-content: center; align-items: flex-start; padding: 5px 0; gap: 8px; flex-grow: 1; }
.bloco-coluna { display: flex; flex-direction: column; gap: 3px; }
.col-dupla { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; border-left: 1px solid #eee; padding-left: 5px; }

.baia-box { 
    display: flex; align-items: center; background: #fff; border: 1px solid #ddd; 
    padding: 2px 4px; border-radius: 4px; width: 140px; height: 42px;
}
.baia-box b { background: #2c3e50; color: white; width: 15px; height: 15px; display: flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 0.45rem; flex-shrink: 0; margin-right: 4px; }

.baia-nome { 
    font-weight: 800; color: #27ae60; font-size: 0.62rem; 
    line-height: 1.1; text-align: center; flex-grow: 1;
    white-space: normal; word-wrap: break-word; overflow-wrap: break-word;
    display: flex; align-items: center; justify-content: center; height: 100%;
}

.baia-especial { background: #fcf3cf !important; border-color: #f1c40f !important; }
.baia-especial .baia-nome { color: #d68910 !important; }

/* Cores Botões */
.btn-distribuir { background: #3498db; }
.btn-limpar-mapa { background: black; }
.btn-salvar { background: #27ae60; }
.btn-consultar { background: #f39c12; }