/* ============================================================
   SISTM — CSS GLOBAL
============================================================ */

/* ============================
   CONTAINERS PRINCIPAIS
============================ */
/* CADASTRAR */
.sistm-cadastro-container {
    max-width: 600px;
    margin: 20px auto;
    background: #ffffff;
    padding: 20px;
    border-radius: 10px;
    box-sizing: border-box;
    border: 2px solid #0057A6;
}

/* ============================
   INPUTS GLOBAIS
============================ */
.sistm-form-group {
    width: 100%;
    margin-bottom: 8px;
}

.sistm-form-group label {
    margin-bottom: 4px; /* deixa o rótulo mais próximo do input */
}


/* .sistm-cadastro-container input, */
/* .sistm-form-container input, */
/* .sistm-edit-container input, */
.sistm-form select,
.sistm-form input,
.sistm-form input[type="time"],
.sistm-form input[type="text"],
.sistm-form input[type="email"],
.sistm-form input[type="tel"],
.sistm-form input[type="password"],
.sistm-filtros-form select,
.sistm-editar-form select,
.sistm-editar-form input,
.sistm-editar-form input[type="time"],
.sistm-editar-form input[type="text"] {
    width: 100%;
    max-width: 100%;
    padding: 10px;
    height: 42px;
    font-size: 15px;
    color: #333;
    background: #F6F2F2 ;
border: 1px solid #005bbb; /* altera as bordas dos select dos container cadastrar, gerenciar e editar e dos campos 
    iof, valor indiv e vlr total do cadastrar */
    border-radius: 8px ; /* altera as bordas dos select dos container cadastrar, gerenciar e editar 
    e dos campos iof, valor indiv e vlr total do cadastrar*/
    box-sizing: border-box;
    outline: none;
}

.sistm-editar-form input:focus,
.sistm-filtros-form input:focus {
    border-color: #005bbb;
    box-shadow: 0 0 0 2px rgba(0,91,187,0.25);
}    

/* ============================
   BOTÕES altera editar, cadastrar, menu usario externo, login
============================ */
.sistm-form-submit,
.sistm-btn-buscar,
.sistm-btn-add,
.sistm-login-btn,
.sistm-popup-ok,
.modulo-btn {
    background: #E9E5E5 !important;
    color: #0057A6 !important;
    border: 1px solid #0057A6 !important;
    border-radius: 8px;
    padding: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s ease;
    text-align: center;
}

.sistm-form-submit:hover,
.sistm-btn-buscar:hover,
.sistm-btn-add:hover,
.sistm-login-btn:hover,
.sistm-popup-ok:hover,
.modulo-btn:hover {
    background: #0057A6 !important;
    color: #ffffff !important;
    transform: translateY(-2px);
}
.sistm-usuario-externo .sistm-form-submit {
    width: auto !important;        /* remove o 100% do sistm.php */
    display: block !important;     /* permite centralizar */
    margin: 20px auto !important;  /* centraliza */
    padding: 12px 50px !important; /* deixa mais bonito */
}

/* ============================
   BOTÕES ALINHADOS — DESKTOP
============================ */
.sistm-buttons-row {
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
}

.sistm-buttons-row button,
.sistm-buttons-row .sistm-form-submit,
.sistm-buttons-row .sistm-btn-buscar,
.sistm-buttons-row .sistm-btn-add,
.sistm-buttons-row .sistm-login-btn {
    flex: 1;
    min-width: 160px;
    max-width: none;
    width: auto;
    white-space: nowrap;   /* ← impede quebra de linha */
}

/* ============================
   LOGIN — PADRÃO SISTM
============================ */

.sistm-login-container { /* FUNCIONANDO PERFEITAMENTE */
    width: 70%;
    max-width: 380px;
    margin: 40px auto;
    padding: 25px 25px 30px 25px;
    background: #ffffff;
    border: 3px solid #0057A6;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.12);
}

.sistm-login-title {
    font-family: 'Roboto';
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    color: #0057A6;
    margin-bottom: 25px;
}

.sistm-login-container label {
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
    display: block;
}

.sistm-login-container input {
    width: 100%;
    padding: 12px;
    border: 1px solid #0057A6 !important;
    border-radius: 8px !important;
    margin-bottom: 18px;
    font-size: 15px;
}

.sistm-login-btn {
    width: 100%;
    
}

.sistm-login-btn:hover {
    background: #00498c;
}

/* MANTENHA-ME CONECTADO + ESQUECI MINHA SENHA */
.sistm-login-opcoes {
    display: flex;
    align-items: center;
    margin: 10px 0 5px 0;
}

/* LABEL DO MANTENHA-ME CONECTADO */
.sistm-lembrar {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #0057A6 !important; /* cor da fonte */
    white-space: nowrap !important;
}

/* CHECKBOX */
.sistm-lembrar input[type="checkbox"] {
    width: 16px;   /* ajuste aqui */
    height: 16px;  /* ajuste aqui */
    border: 1px solid #0057A6 !important;
    border-radius: 1px !important;
    margin: 0 6px 0 0;
    position: relative;
    box-sizing: border-box;
    background: #ffffff !important;
}

/* Link "Esqueci minha senha" */
.sistm-esqueci-senha {
    display: block !important;
    text-align: center !important;
    margin-top: 18px !important;
    font-size: 14px !important;
    color: #0057A6 !important;
    font-weight: 400 !important;
    text-decoration: none !important;
}

.sistm-esqueci-senha:hover {
    text-decoration: underline !important;
}

.sistm-form-title {
    font-family: 'Roboto';
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    color: #0057A6;
    margin-bottom: 25px;
}

/* ============================
   TÍTULOS
============================ */
.sistm-global-title { /* Controla o título SISTM - Sistema de Controle ... */
    font-family: 'Roboto';
    font-size: 21px;
    font-weight: 600;
    color: #0057A6;
    text-align: center;
    margin-top: 30px;
    margin-bottom: 5px;
}

.sistm-form-title { /* Controla o título do form dos filtros */
    font-family: 'Roboto';
    font-size: 24px;
    font-weight: 500;
    margin-bottom: 20px;
    color: #0057A6;
    text-align: center;
}

.sistm-form-subtitle {
    font-family: 'Roboto';
    font-size: 18px;
    font-weight: 400;
    color: #0057A6;
    margin-bottom: 20px;
    text-align: center;
}

.sistm-notas-titulo {
    font-size: 16px;
    font-weight: 700;
    font-style: italic; 
    margin: 0 0 10px 0;
    margin-bottom: 4px;
    text-align: left;
    color: #0057A6;
}

/* ============================
   CONFIGURAÇÃO DOS CHECKBOX NA PÁGINA CADASTRO DE USUÁRIOS
============================ */
.sistm-checkbox {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin: 0;
}


.sistm-checkbox input[type="checkbox"] {
    transform: scale(1.2); /* opcional: deixa o checkbox mais bonito */
}

.sistm-form-group.full {
    width: 100%;
    display: block;
    text-align: left;
}

.sistm-checkbox input[type="checkbox"] {
    width: 16px !important;
    height: 16px !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: scale(1) !important;
}


.sistm-form {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.sistm-form-group.half {
    width: calc(50% - 10px);
}

.sistm-form-group.full .sistm-form-submit {
    display: block;
    margin: 0 auto;
}

.sistm-form-group.half label {
    margin-bottom: 0;
    
}

.sistm-form-group.half {
    margin-bottom: 4px; /* ou 0, se quiser bem colado */
}

/* ============================================================
   BLOCO — MENU DO USUÁRIO EXTERNO FUNCIONANDO PERFEITAMENTE
 * ============================================================ */

/* ------------------------------
   CONTAINER DO MENU
------------------------------ */
.sistm-menu-container {
    max-width: 900px;
    margin: 10px auto;
    padding: 20px;
    text-align: center;
}

/* ------------------------------
   GRID DOS MÓDULOS
------------------------------ */
.sistm-modulos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-top: 10px;
    padding: 40px;
}
.sistm-menu-externo{
    border: 1px solid #005bbb;
    border-radius: 10px;
}

.sistm-modulos-grid .sistm-form-subtitle {
    grid-column: 1 / -1; /* ocupa todas as colunas */
    text-align: center;
    margin: 0 0 10px 0; /* remove margem superior */
    padding-top: 0;     /* garante que não tenha padding */
    margin-top: -10px;
    
}

/* ------------------------------
   BOTÃO DE SAIR
------------------------------ */
.sistm-menu-container .sair-btn {
    display: inline-block;
    margin-top: 30px;
    padding: 12px 24px;

    background: #0057A6 !important;
    color: #fff !important;

    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    transition: 0.25s ease;

    grid-column: 1 / -1 !important;
    justify-self: center !important;
    width: 100% !important;
    max-width: 275px !important;
}

.sistm-menu-container .sair-btn:hover {
    background: #E82222 !important;
    transform: translateY(-2px);
}



/* ============================================================
   CORREÇÃO FINAL — FORÇA O MENU A FUNCIONAR NO MOBILE
============================================================ */
@media (max-width: 768px) {

    /* O Elementor está aplicando FLEX no container do shortcode.
       Isso destrói o grid. Então removemos. */
    .elementor-widget-container {
        display: block !important;
    }

    /* Agora o grid funciona */
    .sistm-modulos-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 15px !important;
        padding: 20px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        
    }

    /* Botões ocupam 100% */
    .sistm-modulos-grid .modulo-btn,
    .sistm-menu-container .sair-btn {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        box-sizing: border-box !important;
    }
   
}
/* ============================================================
   CONFIGURAÇÃO DOS POPUP
============================================================ */
/* Fundo escuro do popup */
.sistm-popup {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);

    /* centralização */
    justify-content: center;
    align-items: center;
}


/* Caixa branca do popup */
.sistm-popup-content {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    width: 350px;
    max-width: 90%;
    text-align: center;
    position: relative;
    animation: fadeIn 0.2s ease-in-out;
}

/* Botão de fechar */
.sistm-close {
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 22px;
    cursor: pointer;
}

/* Botões internos */
#sistm-popup-buttons a {
    display: block;
    margin: 10px 0;
    padding: 10px;
    background: #0073aa;
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
}

#sistm-popup-buttons a:hover {
    background: #005f8d;
}

/* Animação */
@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.95); }
    to   { opacity: 1; transform: scale(1); }
}

