/* Acessibilidade - sem mudanca visual, apenas suporte a leitor de tela */
.sr-only, .visually-hidden {
    position:absolute !important;
    width:1px !important;
    height:1px !important;
    padding:0 !important;
    margin:-1px !important;
    overflow:hidden !important;
    clip:rect(0,0,0,0) !important;
    white-space:nowrap !important;
    border:0 !important;
}
/* Reduzir icones gigantes do editor de texto rico (Quill) no mobile */
@media (max-width: 768px){
    .ql-toolbar.ql-snow .ql-formats { margin-right: 8px !important; }
    .ql-toolbar.ql-snow button {
        width: 28px !important;
        height: 28px !important;
        padding: 3px !important;
    }
    .ql-toolbar.ql-snow button svg {
        width: 18px !important;
        height: 18px !important;
    }
}

/* ============================================================
 * Autofill mobile fix — impede o navegador de pintar inputs
 * de branco quando sugere autopreenchimento. Cobre todos os
 * inputs/textarea/select do painel em light e dark mode.
 * ============================================================ */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus,
textarea:-webkit-autofill:active,
select:-webkit-autofill,
select:-webkit-autofill:hover,
select:-webkit-autofill:focus,
select:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
    box-shadow: 0 0 0 1000px #fff inset !important;
    -webkit-text-fill-color: #495057 !important;
    caret-color: #495057 !important;
    transition: background-color 99999s ease-in-out 0s, color 99999s ease-in-out 0s !important;
}

.dark-mode input:-webkit-autofill,
.dark-mode input:-webkit-autofill:hover,
.dark-mode input:-webkit-autofill:focus,
.dark-mode input:-webkit-autofill:active,
.dark-mode textarea:-webkit-autofill,
.dark-mode textarea:-webkit-autofill:hover,
.dark-mode textarea:-webkit-autofill:focus,
.dark-mode textarea:-webkit-autofill:active,
.dark-mode select:-webkit-autofill,
.dark-mode select:-webkit-autofill:hover,
.dark-mode select:-webkit-autofill:focus,
.dark-mode select:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #343a40 inset !important;
    box-shadow: 0 0 0 1000px #343a40 inset !important;
    -webkit-text-fill-color: #fff !important;
    caret-color: #fff !important;
    transition: background-color 99999s ease-in-out 0s, color 99999s ease-in-out 0s !important;
}

/* Cobre tambem o padrao moderno (sem prefixo) usado por Safari/Firefox novos */
input:autofill, textarea:autofill, select:autofill {
    box-shadow: 0 0 0 1000px #fff inset !important;
    -webkit-text-fill-color: #495057 !important;
}
.dark-mode input:autofill,
.dark-mode textarea:autofill,
.dark-mode select:autofill {
    box-shadow: 0 0 0 1000px #343a40 inset !important;
    -webkit-text-fill-color: #fff !important;
}

/* === BOOTBOX_MODAL_CENTER_v2 === Centraliza modais bootbox/bootstrap em qualquer tela */
.modal.show,
.modal.in {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}
.modal.show .modal-dialog,
.modal.in .modal-dialog,
.bootbox.modal .modal-dialog {
    margin: 0.5rem auto !important;
    width: calc(100% - 1rem) !important;
    max-width: 500px !important;
    pointer-events: auto !important;
}
@media (min-width: 576px) {
    .modal.show .modal-dialog,
    .modal.in .modal-dialog,
    .bootbox.modal .modal-dialog {
        margin: 1.75rem auto !important;
        width: auto !important;
    }
}
