body {
    font-family: "Poppins", sans-serif !important;
    font-weight: 300 !important;
    font-size: 13px;
}

.fw-medium, .card, .h1, .h2, .h3, .h4, .h5, .h6, h1, h2, h3, h4, h5, h6 {
    font-family: "Poppins", sans-serif !important;
    font-weight: 400 !important;
}

.fw-bold {
    font-family: "Poppins", sans-serif !important;
    font-weight: 600 !important;
}

.select-profile a {
    font-size: 14px;
}

.auth-page-wrapper {
    background-size: cover;
}

.frame_rhid {
    height: 100vh;
}

.table tr {
    vertical-align: baseline;
}

.no-results-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.no-results-icon {
    font-size: 3rem; /* Tamanho do ícone */
    color: #c0c0c0; /* Cor do ícone (vermelho no exemplo) */
}

.no-results-text {
    font-size: 18px;
    font-weight: bold;
    text-transform: uppercase;
    color: #c0c0c0;
}

.btn-cad-gradient {
    background: linear-gradient(to right, #0c524e 0%, #149189 100%);
    color: #fff !important;
}

.btn-cad, .nav-link.active, .form-switch .form-check-input:checked {
    background-color: #0c524e !important;
    border: none;
    color: #fff !important;
}

.btn-soft-cad {
    background-color: #eef1f4;
}

.btn-soft-cad:hover {
    background: linear-gradient(to right, #0c524e 0%, #149189 100%);
    color: #fff;
}

.btn-outline-cad {
    border-color: #149189;
    color: #149189;
    border: 3px solid;
}

.btn-outline-cad:hover {
    background-color: #149189;
    border-color: #149189;
    color: #fff;
}

.avatar-title {
    background-color: #149189 !important;
}

.arrow-navtabs .nav-item .nav-link.active:before {
    border-top-color: #0c524e;
}

.nav-link:hover {
    color: #0c524e;
}

.active > .page-link, .page-link.active {
    background-color: #0c524e !important;
    border-color: #0c524e !important;
}

div:where(.swal2-container) button:where(.swal2-styled).swal2-confirm {
    background: linear-gradient(to right, #0c524e 0%, #149189 100%) !important;
}

.text-cad {
    color: #0c524e;
    font-size: 18px;
}

.text-cad-2 {
    color: #149189;
    font-size: 18px;
}

.dashboard-title {
    color: #149189;
}

.bg-cad {
    background-color: #666683 !important;
}

.navbar-menu,
.navbar-menu .navbar-nav .nav-link[data-bs-toggle=collapse][aria-expanded=true],
.navbar-menu .navbar-nav .nav-sm .nav-link.active {
    background-color: #2c2e3e !important;
}

.auth-one-bg .bg-overlay, .profile-wid-bg::before {
    background: linear-gradient(to right, #0c524e 0%, #149189 100%) !important;
}

.accordion-fill-secondary .accordion-item .accordion-button:not(.collapsed) {
    background-color: #0c524e !important;
    color: #fff !important;
}

.total-alert,
.total-alert-reports {
    position: absolute;
    top: 6px;
    left: 25px;
    transform: translateX(-50%);
    width: 17px;
    height: 16px;
    font-size: 10px;
    font-weight: 700;
    color: white;
    background-color: #fa896b;
    border-radius: 100%;
    text-align: center;
    vertical-align: middle;
    line-height: 15px;
    z-index: 1;
}

.select2-container--default .select2-selection--multiple {
    padding: 0.2rem 2.7rem 0.5rem 0.9rem !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: #0c524e !important;
    border-color: #0c524e !important;
}

.spinner-border-modal {
    width: 9rem !important;
    height: 9rem !important;
    border-width: 0.5em !important;
}

.apexcharts-svg {
    overflow: visible;
}

.chart-container {
    padding: 2rem;
    padding-right: 2.7rem;
}

#attendanceTabs {
    white-space: nowrap;
    scrollbar-width: thin;
    flex-wrap: unset;
    overflow-x: auto;
    overflow-y: hidden;
}

.select2-results__option--selected {
    display: none;
}

.dataTables_wrapper {
    min-height: 250px;
}

select {
    border: 1px solid #ced4da;
    border-radius: 0.25rem;
    outline: none;
}

/* Fix sidebar scrolling when submenus are expanded */
.app-menu {
    height: 100vh;
    overflow: hidden;
}

.app-menu .navbar-brand-box {
    flex-shrink: 0;
}

#scrollbar {
    height: calc(100vh - 80px) !important;
    overflow: hidden !important;
}

#scrollbar .container-fluid {
    height: auto !important;
    min-height: 100%;
    padding-bottom: 20px;
    display: flex !important;
    flex-direction: column !important;
}

#navbar-nav {
    height: auto !important;
    min-height: 100%;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
}

/* Ensure submenus don't cause overflow issues */
.menu-dropdown {
    max-height: none;
    flex-shrink: 0 !important;
}

.menu-dropdown .nav-sm {
    max-height: none;
}

/* Custom scrollbar styling for better UX */
#scrollbar::-webkit-scrollbar {
    width: 6px;
}

#scrollbar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

#scrollbar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

#scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Ensure proper spacing at the bottom of the menu */
#navbar-nav::after {
    content: '';
    display: block;
    height: 20px;
    flex-shrink: 0;
}

/* Fix for hover states when scrolling */
.navbar-menu:hover #scrollbar {
    overflow-y: auto !important;
}

/* Ensure menu items are always accessible */
.navbar-nav .nav-item {
    position: relative;
    flex-shrink: 0 !important;
}

.menu-dropdown {
    position: relative;
    z-index: 1;
}

/* Additional responsive fixes for sidebar scrolling */
@media (max-width: 991.98px) {
    #scrollbar {
        height: calc(100vh - 70px) !important;
    }
}

@media (max-width: 767.98px) {
    #scrollbar {
        height: calc(100vh - 60px) !important;
    }
}

/* Ensure proper scrolling on touch devices */
@media (hover: none) and (pointer: coarse) {
    #scrollbar {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
}

/* Fix for Firefox scrollbar */
#scrollbar {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.1);
}

/* Ensure submenu items are properly spaced */
.menu-dropdown .nav-sm .nav-item {
    margin-bottom: 2px;
}

.menu-dropdown .nav-sm .nav-link {
    padding: 8px 15px 8px 45px;
    font-size: 12px;
}

/* Prevent menu from being cut off at bottom */
.app-menu .navbar-nav {
    margin-bottom: 0;
}

/* Ensure proper z-index for expanded menus */
.navbar-nav .nav-item.show .menu-dropdown {
    z-index: 10;
}

/* Smooth transitions for menu expansions */
.menu-dropdown {
    transition: all 0.3s ease;
}

/* Ensure scrollbar is always visible when needed */
#scrollbar {
    overflow-y: scroll !important;
}

/* Hide scrollbar when not needed but keep functionality */
#scrollbar:not(:hover)::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
}

/* Ensure proper height calculation for different sidebar states */
[data-sidebar-size="sm-hover"] #scrollbar {
    height: calc(100vh - 80px) !important;
}

[data-sidebar-size="lg"] #scrollbar {
    height: calc(100vh - 80px) !important;
}

[data-sidebar-size="md"] #scrollbar {
    height: calc(100vh - 80px) !important;
}

[data-sidebar-size="sm"] #scrollbar {
    height: calc(100vh - 80px) !important;
}

/* SimpleBar specific fixes for sidebar scrolling */
[data-simplebar] {
    height: 100% !important;
}

[data-simplebar] .simplebar-content-wrapper {
    height: 100% !important;
    overflow-y: auto !important;
}

[data-simplebar] .simplebar-content {
    height: auto !important;
    min-height: 100% !important;
}

/* Ensure SimpleBar scrollbar is visible when needed */
[data-simplebar] .simplebar-scrollbar {
    background: rgba(255, 255, 255, 0.3) !important;
    border-radius: 3px !important;
}

[data-simplebar] .simplebar-scrollbar.simplebar-visible:before {
    opacity: 0.5 !important;
}

/* Fix for SimpleBar track */
[data-simplebar] .simplebar-track.simplebar-vertical {
    width: 6px !important;
    background: rgba(255, 255, 255, 0.1) !important;
}

/* Ensure menu content doesn't get cut off */
#scrollbar[data-simplebar] .simplebar-content {
    padding-bottom: 20px !important;
}

/* Force SimpleBar to recalculate when menus expand */
.menu-dropdown.show {
    position: relative !important;
    z-index: 1 !important;
}

/* Ensure proper scrolling behavior with SimpleBar */
#scrollbar[data-simplebar] {
    overflow: hidden !important;
}

#scrollbar[data-simplebar] .simplebar-content-wrapper {
    overflow-y: scroll !important;
    overflow-x: hidden !important;
}

/* Fix for nested submenus */
.menu-dropdown .menu-dropdown {
    position: relative !important;
    z-index: 2 !important;
}

/* Ensure all menu items are accessible */
#navbar-nav .nav-item {
    position: relative !important;
}

/* Force SimpleBar to show scrollbar when content overflows */
#scrollbar[data-simplebar]:hover .simplebar-scrollbar {
    opacity: 1 !important;
}

/* Ensure proper height calculation for SimpleBar */
#scrollbar[data-simplebar] .simplebar-content-wrapper {
    height: calc(100vh - 80px) !important;
}

/* Fix for mobile devices with SimpleBar */
@media (max-width: 767.98px) {
    #scrollbar[data-simplebar] .simplebar-content-wrapper {
        height: calc(100vh - 60px) !important;
    }
}

/* Ensure SimpleBar works with touch devices */
@media (hover: none) and (pointer: coarse) {
    #scrollbar[data-simplebar] .simplebar-content-wrapper {
        -webkit-overflow-scrolling: touch !important;
    }
}

/* Fix scrollbar visibility and scrolling issues */
#scrollbar {
    height: calc(100vh - 80px) !important;
    overflow: hidden !important;
}

#scrollbar .container-fluid {
    height: auto !important;
    min-height: 100%;
    padding-bottom: 20px;
}

#navbar-nav {
    height: auto !important;
    min-height: 100%;
}

/* Hide scrollbar when not needed */
#scrollbar:not(:hover) .simplebar-scrollbar {
    opacity: 0 !important;
}

/* Show scrollbar only when hovering and content overflows */
#scrollbar:hover .simplebar-scrollbar.simplebar-visible {
    opacity: 1 !important;
}

/* Ensure proper content height calculation */
#scrollbar .simplebar-content {
    height: auto !important;
    min-height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
}

#navbar-nav {
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Fix for menu items spacing */
.navbar-nav .nav-item {
    flex-shrink: 0 !important;
}

/* Ensure submenus don't cause layout issues */
.menu-dropdown {
    flex-shrink: 0 !important;
}

/* Force SimpleBar to recalculate properly */
#scrollbar[data-simplebar] {
    position: relative !important;
}

#scrollbar[data-simplebar] .simplebar-content-wrapper {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    height: 100% !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

#scrollbar[data-simplebar] .simplebar-content-wrapper::-webkit-scrollbar {
    display: none !important;
}

/* Ensure content is properly sized */
#scrollbar[data-simplebar] .simplebar-content {
    width: 100% !important;
    height: auto !important;
    min-height: 100% !important;
    padding-bottom: 20px !important;
}

/* Additional fixes for scrollbar behavior */
.simplebar-track.simplebar-vertical {
    right: 0 !important;
    top: 0 !important;
    bottom: 0 !important;
    width: 6px !important;
    background: rgba(255, 255, 255, 0.1) !important;
}

.simplebar-scrollbar {
    right: 0 !important;
    width: 6px !important;
    min-height: 10px !important;
    background: rgba(255, 255, 255, 0.3) !important;
    border-radius: 3px !important;
    opacity: 0 !important;
    transition: opacity 0.2s ease !important;
}

.simplebar-scrollbar.simplebar-visible:before {
    opacity: 0.5 !important;
}

/* Show scrollbar only when hovering and content actually overflows */
#scrollbar:hover .simplebar-scrollbar.simplebar-visible {
    opacity: 1 !important;
}

/* Ensure proper spacing at the bottom */
#navbar-nav::after {
    content: '';
    display: block;
    height: 20px;
    flex-shrink: 0;
}

/* Fix for menu title spacing */
.menu-title {
    flex-shrink: 0 !important;
    margin-bottom: 10px !important;
}

/* Ensure proper z-index for expanded menus */
.navbar-nav .nav-item.show .menu-dropdown {
    z-index: 10 !important;
}

/* Fix for nested submenus */
.menu-dropdown .menu-dropdown {
    position: relative !important;
    z-index: 2 !important;
}
