/* Global background color */
body {
    background: #F5F7FB !important;
}

/* Utility Classes */
.text-20px { font-size: 20px !important; }
.text-19px { font-size: 19px !important; }
.text-18px { font-size: 18px !important; }
.text-17px { font-size: 17px !important; }
.text-16px { font-size: 16px !important; }
.text-15px { font-size: 15px !important; }
.text-14px { font-size: 14px !important; }
.text-13px { font-size: 13px !important; }
.text-12px { font-size: 12px !important; }
.text-11px { font-size: 11px !important; }
.text-10px { font-size: 10px !important; }

.mt-10px { margin-top: 10px !important; }
.mt-20px { margin-top: 20px !important; }
.mt-30px { margin-top: 30px !important; }
.mt-40px { margin-top: 40px !important; }
.mt-50px { margin-top: 50px !important; }
.mt-80px { margin-top: 80px !important; }

.mb-10px { margin-bottom: 10px !important; }
.mb-20px { margin-bottom: 20px !important; }
.mb-30px { margin-bottom: 30px !important; }

/* Sidebar toggle button styling */
#sidebar-toggle-btn {
    position: absolute;
    right: -12px;
    top: 20px;
    width: 24px;
    height: 24px;
    background: #0EA5A4;
    border: none;
    border-radius: 50%;
    color: #ffffff !important;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 101;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(15, 23, 42, 0.18);
    padding: 0;
    opacity: 1 !important;
}

#sidebar-toggle-btn span,
#sidebar-toggle-btn span::before {
    color: #ffffff !important;
    opacity: 1 !important;
}

/* Global admin sidebar theme */
.ol-sidebar,
.sidebar-logo-area.custom-logo-area {
    /* background: linear-gradient(180deg, #1E293B 0%, #334155 100%) !important; */
    border-right: 1px solid #f7f7f721;
}

.sidebar-title {
    color: rgba(248, 250, 252, 0.7) !important;
}

.sidebar-first-li > a .icon {
    color: rgba(248, 250, 252, 0.7) !important;
}

.sidebar-first-li > a .text,
.collapsed-logo {
    color: rgba(248, 250, 252, 0.8) !important;
}

.first-sub-menu-title,
.sidebar-second-li > a,
.sidebar-third-li > a {
    color: #F8FAFC !important;
}

.sidebar-first-li:hover > a,
.sidebar-first-li.active > a {
    background: linear-gradient(135deg, #5B3DF5 0%, #6C7CFF 100%) !important;
    color: #F8FAFC !important;
}

.sidebar-first-li:hover > a .icon,
.sidebar-first-li.active > a .icon,
.sidebar-first-li:hover > a .icon::before,
.sidebar-first-li.active > a .icon::before {
    color: #F8FAFC !important;
}

.sidebar-second-li > a::after,
.sidebar-third-li > a::after {
    background: #93C5FD !important;
}

.sidebar-second-li.active > a,
.sidebar-second-li:hover > a,
.sidebar-third-li.active > a,
.sidebar-third-li:hover > a {
    color: #93C5FD !important;
}

.sidebar-second-li.active > a::after,
.sidebar-second-li:hover > a::after,
.sidebar-third-li.active > a::after,
.sidebar-third-li:hover > a::after {
    background: #93C5FD !important;
}

/* Arrow rotation when collapsed */
.ol-sidebar.hide #sidebar-toggle-btn span {
    transform: rotate(180deg);
}

/* Logo toggle */
.ol-sidebar.hide .full-logo,
.ol-sidebar.hide .logo-tagline {
    display: none !important;
}

.ol-sidebar:not(.hide) .collapsed-logo {
    display: none !important;
}

.ol-sidebar.hide .collapsed-logo {
    background: transparent;
    color: #F8FAFC;
    padding: 0;
    border-radius: 0;
    font-size: 13px;
    font-weight: 800;
    display: block !important;
    box-shadow: none;
    text-align: center;
    width: auto;
    margin: 0 auto;
}

.ol-sidebar.hide .logo-text-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ol-sidebar.hide .custom-logo-area {
    padding: 20px 0;
    justify-content: center;
    min-height: 72px;
}

/* Sidebar width and transition */
.ol-sidebar {
    transition: width 0.3s ease, left 0.3s ease !important;
    display: flex !important;
    flex-direction: column !important;
}

.sidebar-logo-area {
    flex-shrink: 0 !important;
}

.sidebar-nav-area {
    flex-grow: 1 !important;
    height: auto !important;
    overflow-y: auto !important;
}

.ol-sidebar-content {
    transition: left 0.3s ease, width 0.3s ease !important;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.ol-body-content {
    flex-grow: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.ol-body-content > .container-fluid {
    padding-bottom: 40px !important;
    flex: 1 0 auto !important; /* Fill space to push footer down */
    display: flex;
    flex-direction: column;
}

/* Global Footer Styling */
.main-footer {
    background: #fff;
    padding: 16px 30px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #64748b;
    font-weight: 500;
}

.main-footer a {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
}

.main-footer a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .main-footer {
        flex-direction: column;
        gap: 8px;
        text-align: center;
        padding: 15px;
    }
}


/* Icon colors: linear gbadient(135deg, #5B3DF5 0%,ck6C7CFF 10g%) when collapsed */
.ol-sidebar.hide .sidebar-nav .icon {
    color: #F8FAFC !important;
}

/* Active state in collapsed mode */
.ol-sidebar.hide .sidebar-first-li.active > a,
.ol-sidebar.hide .sidebar-first-li:hover > a {
    background-color: #0EA5A4 !important;
    border-radius: 8px;
    margin: 0;
}

.ol-sidebar.hide .sidebar-first-li.active > a .icon {
    color: #fff !important;
}

/* Sidebar Nav Scrollbar styling */
.sidebar-nav-area::-webkit-scrollbar {
    width: 4px;
}
.sidebar-nav-area::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.1);
	border-radius: 10px;
}
.sidebar-nav-area:hover::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
}

/* Category Card Enhancement */
.category-card {
    border: 1px solid #E5E7EB !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06) !important;
    transition: all 0.3s ease-in-out !important;
    background: #ffffff !important;
}

.category-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06) !important;
    border-color: #D1D5DB !important;
}

/* Global Table Header Standardization */
.table thead th,
.tm-table thead th,
.ol-table thead th,
table thead th {
    color: #000 !important;
    font-weight: 700 !important;
}
/* Fix Select2 dropdown positioning and interaction within all modals */
.select2-container--open {
    z-index: 9999999 !important;
}

.modal .modal-body,
.modal .modal-content {
    overflow: visible !important;
}

/* Ensure the modal container itself handles the scroll reliably */
.modal {
    overflow-y: auto !important;
}
