@import url("variables.ba7d9d3a96a8.css");

:root {
    --topbar-height: 70px;
}

/* ==========================================================================
   Body
   ========================================================================== */
body {
    padding-top: 0px;
    font-family: 'Nunito', sans-serif;
    font-size: 1.0rem;
    overflow-x: hidden;
    overflow-y: hidden;
    display: flex;
    flex-direction: column;
    height: 100dvh;
    min-height: 80dvh;
    /* position: relative; */
    background: #F5F7FD;
    background-size: cover;
    background-attachment: fixed;
    background-repeat: no-repeat;
    /* Prevent iOS overscroll bounce */
    overscroll-behavior-y: none;
    touch-action: pan-x pan-y;
}


/* ==========================================================================
   Sidebar
   ========================================================================== */
.sidebar {
    width: 240px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    padding: 0.5rem 0.25rem;
    border-right: 3px solid var(--primary-100);
    background-color: #ffffff;
    transition: width 0.3s, padding 0.3s;
    white-space: nowrap;
    overflow-y: auto;
    z-index: 1035; /*Between topbar (1030) and offcanvas (1040) */
    /* box-shadow: 0 0 15px rgba(0, 0, 0, 0.2); */
}
.sidebar-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}
.sidebar-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 1.3s ease, width 1.3s ease, visibility 1s;
    max-width: 100%;
    overflow: hidden;
}
.sidebar-toggle {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}
.sidebar-collapsed-init .sidebar,
.sidebar.collapsed {
    width: 0px;
    padding-left: 0px !important;
    padding-right: 0px !important;
    overflow-y: hidden; 
}
.sidebar.collapsed .sidebar-button {
    display: flex;
    justify-content: center;
    display: block !important;
}
.sidebar.collapsed .sidebar-header {
    display: flex;
    justify-content: center;
    padding-bottom: 5px;
    border-bottom: none;
    padding: 0px !important;
}
.sidebar.collapsed .sidebar-logo {
    width: 0;
    opacity: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
    transition: width 1s ease;
}
.sidebar .nav-header,
.sidebar .nav-link,
.sidebar .collapse-item {
    display: flex;
    align-items: center;
    padding: 5px;
    transition: padding 0.3s;
}
.sidebar.collapsed .nav-header,
.sidebar.collapsed .nav-link,
.sidebar.collapsed .collapse-item {
    padding: 5px; 
}
.sidebar .nav-header {
    font-weight: bold;
    color: #9c9b9b;
    font-size: 0.8125rem;
    text-transform: uppercase;
}
.sidebar .nav-link {
    color: #595959; 
    border-radius: 5px;
    font-size: 0.875rem;
    padding: 5px;
    margin-bottom: 5px;
    margin-bottom: 0;
}
.nav-link.collapse-item {
    margin-bottom: 0;
    padding-left: 1.75rem;
    padding-right: 0.75rem;
}
.sidebar .has-chevron {
    justify-content: left;
}
.sidebar .nav-link i:first-child {
    width: 20px;
    text-align: center;
}
.sidebar .nav-link span {
    margin-left: 10px;
}
.sidebar .nav-link:not(.nav-group):hover {
    background-color: var(--primary-100) !important;
    color: var(--primary-600) !important;
    font-weight: bold;
}
.sidebar .nav-link:not(.nav-group).active {
    background-color: var(--primary-200) !important;
    color: var(--primary-600) !important;
    font-weight: bold;
}
.sidebar .nav-link:not(.nav-group):active {
    background-color: var(--primary-200) !important;
    font-weight: bold;
}
.sidebar .rotatable {
    transform: rotate(0deg); /* Default rotation */
    transition: transform 0.3s; /* Smooth transition for rotation */
}
.sidebar .rotatable.rotate-down {
    transform: rotate(90deg); /* Rotated state */
}



/* ==========================================================================
   Top bar
   ========================================================================== */

.topbar {
    background-color: #ffffff;
    border-bottom: 3px solid var(--primary-100);
    /* box-shadow: 2px 4px 8px 0px rgba(69, 65, 78, 0.05); */
    overflow-y: visible;
    height: var(--topbar-height);
    font-size: 1.0rem;
    align-items: center;
    display: flex;
    z-index: 1000;
    justify-content:  start;
    padding: 0.5rem 0.5rem;
    position: fixed; 
    top: 0;
    left: 240px; /* Match sidebar width */
    right: 0;
    transition: left 0s ease 0.0s; /* Match main-content transition */
}
.topbar.collapsed {
    left: 0px !important;
}

.topbar-menu {
    display: flex;
    flex-shrink: 0;
    align-items: center;
}
.topbar-body {
    display: flex;
    flex-shrink: 1;
    min-width: 0;
    flex-grow: 1;
}

/* For smaller screens, always collapsed */
@media (max-width: 960px) {
    .topbar {
        left: 0px;
    }
}
/* Vertical spacer for topbar elements */
.vertical-spacer {
    border-left: 2px solid var(--secondary-200); /* Light gray border; adjust variable if needed */
    height: 30px;
}


/* ==========================================================================
   Main content
   ========================================================================== */

.main-content {
    flex: 1;
    min-height: 0;
    box-sizing: border-box;
    margin-top: var(--topbar-height); /* Changed from 0px to account for fixed topbar */
    margin-left: 240px;
    padding: 0px;
    margin-right: 0px !important;
    margin-bottom: 0px;
    transition: margin-left 0s ease 0.0s; 
    /* overflow-y: hidden;  */
    overflow-y: auto;
    overflow-x: hidden;
    height: calc(100dvh - var(--topbar-height)); /* Added from inline styles */
    display: flex; /* Added from inline styles */
    flex-direction: column; /* Added from inline styles */
    /* Prevent iOS overscroll bounce */
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
    /* position: relative; */
}
.main-content.collapsed {
    margin-left: 0px;
    margin-right: 0px;
    padding: 0px;
}
/* For smaller screens, always collapsed */
@media (max-width: 960px) {
    .main-content {
        margin-left: 0px;
    }
}

/* .content-area {
    flex: 1 1 0;
    min-height: 0;
    padding: 0 !important;
    height: 100%;
} */

.no-padding {
    padding: 0 !important;
    margin: 0 !important;
}


.content-body-container {
    height: max(100%, 400px);
}

.content-body {
    flex: 1;
    padding: 0.25rem 1.0rem;
}

/* ==========================================================================
   Utility Classes
   ========================================================================== */
/* Force content height */
.content-height {
    height: calc(100dvh - var(--topbar-height));
    min-height: 400px;
}

.col-flex {
    flex: 1;
    min-width: 0;
}
.scrollspy-container {
    position: relative;
    height: 100%;
    overflow-y: auto;
    padding: 0rem 0.75rem;
}




/* ==========================================================================
   Panels
   ========================================================================== */
/* Content area panel */
.panel {
    background-color: #ffffff;
    border-color: var(--primary-100);
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    height: 100%;
}


.panel.overflow-hidden {
    overflow-x: hidden;
    overflow-y: visible;
}

.panel-header {
    border-bottom: 2px solid var(--primary-100);
    background-color: transparent;
    padding: 0.5rem 1.0rem;
    overflow: visible !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-heading {
    background-color: transparent;
    padding: 1.0rem 2.0rem;
    overflow: visible !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
@media (max-width: 576px) { 
  .panel-heading {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
}

@media (max-width: 576px) { 
  .panel-header {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
  }
}

.panel-body {
    flex: 1 1 auto;
    overflow-y: auto !important;
    padding: 0.5rem 1.0rem;
}


/* ==========================================================================
   Offcanvas
   ========================================================================== */
.offcanvas {
    font-size: 0.875rem;
    min-height: 400px;
    overflow-x: hidden;
}
.offcanvas .offcanvas-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.25rem 1rem;
    height: var(--topbar-height);
    overflow-y: visible;
    overflow-x: hidden;
}
.offcanvas .offcanvas-body {
    padding: 0.5rem 1rem;
    overflow-x: hidden;
}


