/* ================================================================
   custom.css — Totem / principal / login
   ================================================================ */

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: Arial, sans-serif;
    background: #e9f5ec;
    color: #333;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* ── Sistema de telas (SPA) ── */
.tela          { display: none; width: 100%; }
.tela.ativa    { display: flex; flex-direction: column; align-items: center; }

/* ── Tela de aviso ── */
.aviso-container {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(0,0,0,0.12);
    padding: 48px 40px;
    max-width: 760px;
    width: 100%;
    text-align: center;
}
.aviso-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 10px;
}
.aviso-logo-img  { height: 80px; width: auto; margin-bottom: 16px; }
.aviso-simbolo   { font-size: 3rem; margin-bottom: 8px; }
.aviso-titulo    { font-size: 1.8rem; font-weight: 900; color: #003366; margin-bottom: 16px; }
.aviso-texto {
    font-size: 1.15rem;
    line-height: 1.8;
    color: #444;
    margin: 18px 0 34px;
}
.botao-aviso {
    background: #006400;
    color: #fff;
    border: none;
    border-radius: 14px;
    padding: 130px;
    font-size: 3rem;
    font-weight: 700;
    cursor: pointer;
    min-width: 380px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    transition: filter 0.15s, transform 0.12s;
}
.botao-aviso:hover  { filter: brightness(1.12); transform: scale(1.02); }
.botao-aviso:active { transform: scale(0.98); }

/* ── Layout da tela de escolha ── */
.escolha-layout {
    display: flex;
    align-items: flex-start;
    gap: 60px;
    justify-content: center;
    width: 100%;
}

.grupo-botoes {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.totem-titulo {
    font-size: 2.6rem;
    font-weight: 900;
    color: #003366;
    text-align: left;
    margin-bottom: 28px;
    letter-spacing: 0.02em;
}

/* ── Botões totem — design card ── */
.totem-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.card-totem {
    border-radius: 22px;
    padding: 36px 24px 28px;
    width: 320px;
    height: 320px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
    transition: filter 0.15s, transform 0.12s;
}
.card-totem:hover  { filter: brightness(1.1); transform: scale(1.02); }
.card-totem:active { transform: scale(0.98); }

.card-totem.verde      { background: #006400; }
.card-totem.verde-pref { background: #1b5e20; }
.card-totem.azul       { background: #003366; }
.card-totem.azul-pref  { background: #0a2744; }

.card-totem-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    background: rgba(255,255,255,0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 2.4rem;
    color: #fff;
}
.card-totem h3 {
    color: #fff;
    font-size: 1.3rem;
    font-weight: 900;
    margin: 0 0 10px;
    line-height: 1.2;
}
.card-totem p {
    color: rgba(255,255,255,0.75);
    font-size: 0.88rem;
    margin: 0;
    line-height: 1.5;
}
.card-totem-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #ffd700;
    color: #7a5e00;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 5px 12px;
    border-radius: 20px;
    letter-spacing: 0.05em;
}

/* ── Painel "Quem tem direito?" ── */
.painel-pref {
    min-width: 260px;
    max-width: 300px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 12px;
    box-sizing: border-box;
    /* empurra para baixo igual ao espaço do título */
    margin-top: calc(2.6rem * 1.35 + 28px);
    background: #fff;
    border-radius: 16px;
    border: 3px solid #ffd700;
    padding: 20px 18px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.painel-pref-titulo {
    font-size: 1.1rem;
    font-weight: 800;
    color: #003366;
    margin-bottom: 4px;
}
.painel-pref-lista {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.painel-pref-lista li {
    font-size: 0.92rem;
    color: #333;
    padding: 5px 0;
    border-bottom: 1px solid #f0f0f0;
}
.painel-pref-lista li:last-child { border-bottom: none; }
.painel-pref-rodape {
    font-size: 0.72rem;
    color: #aaa;
    margin-top: 4px;
    font-style: italic;
}

/* ── Popup ── */
.popup {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.popup-content {
    background: #fff;
    border-radius: 18px;
    padding: 48px 54px;
    text-align: center;
    max-width: 680px;
    width: 92%;
    box-shadow: 0 10px 38px rgba(0,0,0,0.25);
}
.senha-gerada {
    font-size: 5rem;
    font-weight: 900;
    color: #b71c1c;
    margin: 18px 0 12px;
    letter-spacing: 6px;
}
.sucesso-msg { color: #155724; font-size: 2rem; font-weight: 700; line-height: 1.4; }
.erro-msg    { color: #721c24; font-size: 1.75rem; font-weight: 700; line-height: 1.4; }
#popupDataHora { font-size: 1.3rem; color: #444; margin-top: 10px; }
#popupTimer    { margin-top: 18px; color: #666; font-size: 1.15rem !important; }

/* ── Login ── */
.login-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.1);
    padding: 40px 36px;
    width: 100%;
    max-width: 380px;
    text-align: center;
}
.login-logo  { font-size: 3rem; margin-bottom: 8px; }
.login-card h1 { font-size: 1rem; color: #006400; margin-bottom: 4px; }
.login-card h2 { font-size: 0.9rem; color: #555; font-weight: 400; margin-bottom: 22px; }
.form-group { text-align: left; margin-bottom: 14px; }
.form-group label { display: block; font-size: 0.85rem; color: #444; font-weight: 600; margin-bottom: 5px; }
.form-group input { width: 100%; padding: 10px 12px; border: 1px solid #ccc; border-radius: 7px; font-size: 1rem; }
.btn-login {
    width: 100%; padding: 12px;
    background: #006400; color: #fff;
    border: none; border-radius: 7px;
    font-size: 1rem; font-weight: 700;
    cursor: pointer; margin-top: 6px;
}

/* ── Menu principal ── */
.menu-principal { display: flex; flex-direction: column; align-items: center; width: 100%; max-width: 700px; }
.menu-principal h2 { color: #006400; font-size: 1.8rem; margin-bottom: 8px; }
.menu-principal .subtitulo { color: #555; font-size: 1rem; margin-bottom: 32px; text-align: center; }
.menu-botoes { display: flex; flex-direction: column; gap: 16px; width: 100%; }
.botao-menu {
    display: flex; align-items: center; gap: 14px;
    padding: 22px 28px; border: none; border-radius: 12px;
    font-size: 1.15rem; font-weight: 700; cursor: pointer;
    text-decoration: none; color: #fff; width: 100%;
}
.botao-menu .icone { font-size: 1.6rem; }
.botao-menu .desc  { font-size: 0.82rem; font-weight: 400; opacity: 0.9; }
.botao-menu .texto { display: flex; flex-direction: column; text-align: left; }
.botao-verde   { background: #006400; }
.botao-azul    { background: #1565c0; }
.botao-laranja { background: #e65100; }
.botao-cinza   { background: #424242; }
.info-operador { text-align: center; margin-bottom: 24px; font-size: 0.9rem; color: #555; }
.info-operador strong { color: #006400; }
.link-sair { margin-top: 20px; font-size: 0.9rem; color: #b71c1c; text-decoration: none; }
