:root {
    /*  Padrão  */
    --template1: #5cb7d3;
    /* Painel lateral */
    --template2: #0090c4;
    /* cor hover */
    --template3: #0086bb;
}
.field-icon {
  float: right;
  margin-left: -25px;
  margin-top: -25px;
  position: relative;
  z-index: 2;
  margin-right: 8px;
  cursor: pointer;
}
#mensagem-recuperar{
  color: var(--template1) !important;
  font-size: 13px;

}

.select2-selection__rendered {
    font-weight: 500;
    line-height: 36px !important;
    border-radius: 7px !important;
    border: 1px solid #c9c7c7;
}
.select2-container .select2-selection--single {
    height: 39px !important;
}
.select2-selection__arrow {
    height: 38px !important;
}


hr.separador {
  border: 1px dotted #666;
  border-radius: 5px;
}

.select2-selection__rendered {
    line-height: 35px !important;
}
.select2-container .select2-selection--single {
    height: 39px !important;
}
.select2-selection__arrow {
    height: 38px !important;
}
hr.separador {
  border: 1px dotted #666;
  border-radius: 5px;
}
.text-verde{
  color:#0e9e29;
}
.ocultar{
  display:none;
}
.textareag{
    width:1000px;
    height:550px;
}
.side-menu .slide .side-menu__item:hover {
    background-color: var(--template2);

}
.main-sidemenu {
    background-color: #2A2E3F;
}
.app-sidebar {
    background-color: #2A2E3F;
}

.slide-menu {
    border-left: 4px solid #de7b53;
    background-color: #2a2e3f !important;
    color: #ffffff;
}
.side-menu__item a{
    background-color: var(--template2);
    color: #ffffff;
}

.side-menu__item:hover .side-menu__icon,
.side-menu__item:hover .side-menu__label,
.side-menu__item:hover .angle {
    color: #ffffff !important;
    fill: #ffffff !important;

}
.slide-item.active,
.slide-item:hover,
.slide-item:focus {
    text-decoration: none;
    color: var(--template1) !important;

}
.app-sidebar .side-item.side-item-category {
    color: #7660a7;
}
.main-sidebar-header {
    background: #2A2E3F !important;
}
.main-header {
    background-color: #2A2E3F !important;
}

/*
 * Cabeçalho responsivo dos três painéis.
 * Mantém ações essenciais em uma única linha e elimina sobreposições em telas
 * estreitas sem alterar o comportamento do cabeçalho no desktop.
 */
.main-header > .main-container,
.main-header-left,
.main-header-right,
.main-header-right .responsive-navbar,
.main-header-right .responsive-navbar > div,
.main-header-right .header-icons {
    min-width: 0;
}

.main-header-right {
    flex: 0 1 auto;
    margin-left: auto;
}

.main-header-right .header-icons {
    align-items: center;
    flex-wrap: nowrap;
}

@media (max-width: 992px) {
    .main-header > .main-container {
        gap: 4px;
        padding-inline: 8px;
    }

    .main-header-left {
        flex: 1 1 auto;
        overflow: hidden;
    }

    .main-header-left .app-sidebar__toggle {
        flex: 0 0 42px;
        height: 42px;
        margin: 0;
        order: -1;
        width: 42px;
    }

    .main-header-left .responsive-logo {
        display: block;
        flex: 0 1 112px;
        min-width: 0;
    }

    .main-header-left .responsive-logo .header-logo {
        align-items: center;
        display: flex;
        height: 44px;
        justify-content: flex-start;
        max-width: 112px;
        position: static;
        width: 100%;
    }

    .main-header-left .responsive-logo .erp-header-logo {
        display: block;
        height: 40px;
        margin: 0 !important;
        max-width: 100%;
        object-fit: contain;
        width: auto !important;
    }

    .main-header-right .responsive-navbar {
        top: 0;
    }

    .main-header-right .header-icons .new.nav-link,
    .main-header-right .main-profile-menu.nav-link {
        align-items: center;
        display: flex;
        height: 42px;
        justify-content: center;
        margin: 0 1px !important;
        width: 42px;
    }

    .main-header-right .main-profile-menu.nav-link {
        padding: 0 !important;
    }

    .main-header-right .esc {
        display: none !important;
    }

    /* O Modo Expandido substitui a tela cheia nativa e permanece acessível no mobile. */
    .main-header-right .fullscreen-button {
        display: list-item !important;
    }

    .main-header-right .dropdown-menu {
        left: auto !important;
        max-width: calc(100vw - 16px);
        right: 8px !important;
    }
}

@media (max-width: 479.98px) {
    .main-header-left .responsive-logo {
        flex-basis: 92px;
    }

    .main-header-left .responsive-logo .header-logo {
        max-width: 92px;
    }

    .main-header-right .theme-layout {
        display: none !important;
    }
}

@media (max-width: 359.98px) {
    .main-header > .main-container {
        gap: 0;
        padding-inline: 4px;
    }

    .main-header-left .responsive-logo {
        flex-basis: 78px;
    }

    .main-header-left .responsive-logo .header-logo {
        max-width: 78px;
    }

    .main-header-right .header-icons .new.nav-link,
    .main-header-right .main-profile-menu.nav-link {
        margin: 0 !important;
        width: 40px;
    }
}

/*
 * Menu lateral responsivo.
 * Em telas estreitas a barra funciona como um painel temporário: o fundo
 * bloqueia a página, oferece fechamento por toque e impede ações por trás.
 */
.erp-sidebar-backdrop,
.erp-sidebar-mobile-header {
    display: none;
}

@media (max-width: 991.98px) {
    .erp-sidebar-backdrop {
        background: rgba(16, 24, 40, 0.58);
        border: 0;
        cursor: default;
        display: block;
        inset: 0;
        opacity: 0;
        padding: 0;
        pointer-events: none;
        position: fixed;
        transition: opacity 180ms ease, visibility 180ms ease;
        visibility: hidden;
        width: 100%;
        z-index: 1023;
    }

    body.erp-menu-lateral-aberto {
        overflow: hidden;
    }

    body.erp-menu-lateral-aberto .erp-sidebar-backdrop {
        opacity: 1;
        pointer-events: auto;
        visibility: visible;
    }

    body.erp-menu-lateral-aberto .app-sidebar {
        box-shadow: 10px 0 28px rgba(16, 24, 40, 0.34);
        z-index: 1024;
    }

    .app-sidebar.erp-menu-lateral-modal .erp-sidebar-mobile-header {
        align-items: center;
        background: #2a2e3f;
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
        color: #fff;
        display: flex;
        justify-content: space-between;
        min-height: 56px;
        padding: 6px 12px 6px 20px;
        position: sticky;
        top: 0;
        z-index: 3;
    }

    .erp-sidebar-mobile-title {
        font-size: 1rem;
        letter-spacing: 0.01em;
    }

    .erp-sidebar-mobile-close {
        align-items: center;
        background: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.22);
        border-radius: 0.5rem;
        color: #fff;
        display: inline-flex;
        font-size: 1.35rem;
        height: 44px;
        justify-content: center;
        padding: 0;
        width: 44px;
    }

    .erp-sidebar-mobile-close:hover,
    .erp-sidebar-mobile-close:focus-visible {
        background: rgba(255, 255, 255, 0.2);
        color: #fff;
        outline: 2px solid #fff;
        outline-offset: -3px;
    }

    .app-sidebar.erp-menu-lateral-modal .main-sidemenu {
        margin-top: 0 !important;
        padding-bottom: max(1rem, env(safe-area-inset-bottom));
    }
}

@media (prefers-reduced-motion: reduce) {
    .erp-sidebar-backdrop {
        transition: none;
    }
}

/*
 * DataTables no celular: o plugin Responsive mantém somente as colunas que
 * cabem e apresenta as demais no detalhe da linha. Estas regras atuam apenas
 * no detalhe e nos controles; nunca forçam colunas ocultas nem comprimem as
 * células da tabela principal.
 */
table.dataTable > tbody > tr.child > td.child {
    box-sizing: border-box;
    padding: 0.75rem !important;
    white-space: normal !important;
}

table.dataTable > tbody > tr.child ul.dtr-details {
    display: block !important;
    margin: 0;
    width: 100% !important;
}

table.dataTable > tbody > tr.child ul.dtr-details > li {
    align-items: start;
    display: grid;
    gap: 0.5rem 0.75rem;
    grid-template-columns: minmax(7.5rem, 32%) minmax(0, 1fr);
    padding: 0.65rem 0 !important;
}

table.dataTable > tbody > tr.child span.dtr-title,
table.dataTable > tbody > tr.child span.dtr-data {
    min-width: 0;
    white-space: normal !important;
    word-break: normal;
}

table.dataTable > tbody > tr.child span.dtr-title {
    display: block;
}

table.dataTable > tbody > tr.child span.dtr-data {
    display: block;
    max-width: 100%;
    overflow-wrap: anywhere;
}

table.dataTable > tbody > tr.child span.dtr-data > * {
    max-width: 100%;
}

table.dataTable > tbody > tr.child span.dtr-data .btn {
    flex: 0 0 auto;
    margin: 0 !important;
}

@media (max-width: 991.98px) {
    div.dataTables_wrapper div.dataTables_info,
    div.dataTables_wrapper div.dataTables_paginate {
        text-align: center;
        white-space: normal;
    }

    div.dataTables_wrapper div.dataTables_paginate ul.pagination {
        flex-wrap: wrap;
        justify-content: center !important;
        row-gap: 0.35rem;
    }
}

@media (max-width: 767.98px) {
    table.dataTable.dtr-inline.collapsed > thead > tr > th.erp-dt-coluna-principal,
    table.dataTable.dtr-inline.collapsed > tbody > tr > td.erp-dt-coluna-principal {
        min-width: 0;
        overflow-wrap: break-word;
        white-space: normal !important;
        word-break: normal;
    }

    div.dataTables_wrapper div.dataTables_length,
    div.dataTables_wrapper div.dataTables_filter {
        margin-bottom: 0.75rem;
        text-align: left;
        width: 100%;
    }

    div.dataTables_wrapper div.dataTables_length label,
    div.dataTables_wrapper div.dataTables_filter label {
        align-items: center;
        display: flex;
        gap: 0.5rem;
        margin: 0;
        min-width: 0;
        width: 100%;
    }

    div.dataTables_wrapper div.dataTables_length select {
        flex: 0 0 auto;
        margin: 0 !important;
        width: auto;
    }

    div.dataTables_wrapper div.dataTables_filter input {
        flex: 1 1 10rem;
        margin: 0 !important;
        min-width: 0;
        width: auto !important;
    }
}

@media (max-width: 700px),
       (orientation: landscape) and (max-width: 1024px) and (max-height: 600px) {
    table.dataTable.erp-dt-cartoes-mobile {
        background: transparent !important;
        border: 0 !important;
        display: block;
        width: 100% !important;
    }

    table.dataTable.erp-dt-cartoes-mobile > thead {
        display: none !important;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody {
        display: block;
        width: 100%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr:not(.child) {
        border: 1px solid #e3e8ef;
        border-radius: 0.75rem;
        box-shadow: 0 0.2rem 0.7rem rgba(31, 42, 68, 0.08);
        display: block !important;
        margin-top: 0.75rem;
        overflow: hidden;
        position: relative;
        width: 100%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr:not(.child) > td {
        display: none !important;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr:not(.child) > td.erp-dt-coluna-principal,
    table.dataTable.erp-dt-cartoes-mobile > tbody > tr:not(.child) > td.dataTables_empty {
        background: inherit;
        border: 0 !important;
        display: block !important;
        font-size: 0.95rem;
        font-weight: 600;
        line-height: 1.35;
        min-height: 3.25rem;
        overflow-wrap: break-word;
        padding: 0.9rem 1rem 0.9rem 3.25rem !important;
        white-space: normal !important;
        width: auto !important;
    }

    table.dataTable.erp-dt-cartoes-mobile.dtr-inline.collapsed > tbody > tr > td.dtr-control::before {
        left: 1rem;
        margin-top: -0.6rem;
        top: 50%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.parent {
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child {
        display: block !important;
        margin-bottom: 0.75rem;
        width: 100%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child > td.child {
        background: #fff;
        border: 1px solid #e3e8ef !important;
        border-radius: 0 0 0.75rem 0.75rem;
        border-top: 0 !important;
        box-shadow: 0 0.35rem 0.7rem rgba(31, 42, 68, 0.08);
        display: block !important;
        padding: 0.25rem 1rem 0.75rem !important;
        width: auto !important;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child ul.dtr-details > li {
        align-items: center;
        box-sizing: border-box;
        gap: 0.5rem 0.75rem;
        grid-template-columns: minmax(7rem, 38%) minmax(0, 1fr);
        padding: 0.7rem 0 !important;
        width: 100%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child span.dtr-title {
        color: #344054;
        font-size: 0.82rem;
        line-height: 1.3;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child span.dtr-data {
        color: #101828;
        display: block;
        font-size: 0.9rem;
        max-width: 100%;
        overflow-wrap: anywhere;
        width: 100%;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child li.erp-dt-coluna-acoes {
        display: block;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child li.erp-dt-coluna-acoes > .dtr-title {
        margin-bottom: 0.55rem;
    }

    table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child li.erp-dt-coluna-acoes > .dtr-data {
        align-items: center;
        display: flex;
        flex-wrap: wrap;
        gap: 0.45rem;
        justify-content: flex-start;
    }

    @supports selector(li:has(> span.dtr-data:empty)) {
        table.dataTable.erp-dt-cartoes-mobile > tbody > tr.child ul.dtr-details > li:has(> span.dtr-data:empty) {
            display: none;
        }
    }
}

.slide-item .app-sidebar .slide-menu .slide-item:before:hover {
    color: var(--template1) !important;
}
.slide.is-expanded .slide-menu a:hover:before {
   color: var(--template1) !important;
}
.slide:hover .side-menu__label,
.slide:hover .angle {
    color: #fff !important;
    fill: #fff !important;
}
.header-icon-svgs {
    color: #ffffff;
    fill: #ffffff;
}
.font-size-11{
    font-size: 11px !important;
}

#calendar {
    max-width: 1320px;
    margin: 0 auto;
}

/* Configurações administrativas do SaaS. */
#modalConfig .erp-config-saas-modal {
    max-height: calc(100vh - 2rem);
    overflow: hidden;
}

#modalConfig .erp-config-saas-nav {
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.75rem 1rem 0;
    scrollbar-width: thin;
}

#modalConfig .erp-config-saas-nav .nav-tabs {
    border-bottom: 0;
    min-width: max-content;
}

#modalConfig .erp-config-saas-nav .nav-link {
    align-items: center;
    display: inline-flex;
    min-height: 2.75rem;
    white-space: nowrap;
}

#modalConfig .erp-config-saas-content {
    background: #f7f8fa;
    min-width: 0;
    padding: 1rem;
}

#modalConfig .erp-config-saas-section {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    box-shadow: 0 0.2rem 0.55rem rgba(31, 42, 68, 0.04);
    min-width: 0;
    padding: 1.15rem;
}

#modalConfig .erp-config-saas-section h5 {
    margin-bottom: 0.25rem;
}

#modalConfig .erp-config-saas-code,
#modalConfig .erp-config-saas-code code {
    max-width: 100%;
    overflow-wrap: anywhere;
    white-space: normal;
}

#modalConfig .erp-config-saas-upload {
    align-items: center;
    border: 1px solid #e5e7eb;
    border-radius: 0.65rem;
    display: flex;
    gap: 1rem;
    min-width: 0;
    padding: 1rem;
}

#modalConfig .erp-config-saas-upload img {
    flex: 0 0 auto;
    height: auto;
    max-height: 5rem;
    max-width: 7.5rem;
    object-fit: contain;
}

#modalConfig .modal-footer #msg-config:not(:empty) {
    flex: 1 0 100%;
    order: -1;
    text-align: left;
}

@media (max-width: 767.98px) {
    #modalConfig .modal-dialog {
        margin: 0.5rem;
        max-width: calc(100% - 1rem);
    }

    #modalConfig .erp-config-saas-modal {
        max-height: calc(100dvh - 1rem);
    }

    #modalConfig .modal-header,
    #modalConfig .modal-footer {
        padding: 0.85rem;
    }

    #modalConfig .erp-config-saas-nav {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    #modalConfig .erp-config-saas-content {
        padding: 0.75rem;
    }

    #modalConfig .erp-config-saas-section {
        padding: 0.9rem;
    }

    #modalConfig .erp-config-saas-upload {
        align-items: stretch;
        flex-direction: column;
    }

    #modalConfig .erp-config-saas-upload img {
        align-self: center;
        max-width: 100%;
    }

    #modalConfig .modal-footer .btn {
        flex: 1 1 10rem;
    }
}
