/* Custom styles for mobile sidebar */

@media (min-width: 1199px) {
    .navbar-toggle {
        display: none;
    }
}

@media (max-width: 1199px) {

    .navbar-toggle {
        display: block !important;
    }

    /* Make the sidebar full width on mobile */
    .col-sm-2.col-lg-2 {
        position: fixed;
        top: 50px;
        left: 0;
        width: 250px;
        height: calc(100% - 50px);
        z-index: 1000;
        -webkit-transform: translate3d(-250px, 0, 0);
        transform: translate3d(-250px, 0, 0);
        -webkit-transition: all 0.3s ease-in-out;
        transition: all 0.3s ease-in-out;
        overflow-y: auto;
        padding: 0;
    }

    /* Show sidebar when active */
    .col-sm-2.col-lg-2.in {
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
    }

    /* Add overlay when sidebar is open */
    .sidebar-overlay {
        position: fixed;
        top: 50px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        display: none;
    }

    /* Adjust content when sidebar is open */
    .col-sm-10.col-lg-10,
    .col-sm-10.col-lg-10 {
        width: 100%;
        -webkit-transition: all 0.3s ease-in-out;
        transition: all 0.3s ease-in-out;
    }

    /* Ensure proper stacking context */
    .ch-container {
        position: relative;
    }

    .sidebar-nav {
        padding: 10px 0 0 0;
        height: 100%;
        overflow-y: auto;
    }
}