/* 
 * Sidebar Fix for DreamTalk
 * Ensures proper sidebar toggle functionality
 */

/* Ensure the layout wrapper has proper positioning */
.layout-wrapper {
    position: relative;
}

/* Ensure the layout container has proper display */
.layout-container {
    display: flex;
    min-height: 100vh;
}

/* Ensure the layout menu has proper positioning */
.layout-menu {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 260px;
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Ensure the layout page has proper margin */
.layout-page {
    flex: 1;
    margin-left: 260px;
    transition: all 0.3s ease;
}

/* Collapsed state */
.layout-menu-collapsed .layout-menu {
    width: 0;
    overflow: hidden;
}

.layout-menu-collapsed .layout-page {
    margin-left: 0;
}

/* Mobile responsive */
@media (max-width: 1199.98px) {
    .layout-menu {
        transform: translateX(-100%);
    }
    
    .layout-menu-expanded .layout-menu {
        transform: translateX(0);
    }
    
    .layout-page {
        margin-left: 0;
    }
    
    .layout-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 999;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    
    .layout-menu-expanded .layout-overlay {
        opacity: 1;
        visibility: visible;
    }
}

/* Desktop responsive */
@media (min-width: 1200px) {
    .layout-menu {
        transform: none;
    }
    
    .layout-overlay {
        display: none;
    }
}

/* Fix container padding to provide proper spacing */
.content-wrapper .container-xxl {
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
}

/* Ensure proper spacing for content within the container */
.content-wrapper .container-xxl .row {
    margin-left: -0.75rem;
    margin-right: -0.75rem;
}

.content-wrapper .container-xxl .row > * {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

/* Additional layout fixes */
.layout-page {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Ensure content has proper spacing */
.content-wrapper {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Additional improvements for better layout */
.layout-wrapper {
    min-height: 100vh;
}

/* Ensure proper spacing for cards and content */
.card {
    margin-bottom: 1.5rem;
}

/* Fix for navbar positioning */
.layout-navbar {
    position: relative;
    z-index: 1001;
}

/* Ensure proper z-index for sidebar */
.layout-menu {
    z-index: 1000;
}

/* Better spacing for table content */
.table-responsive {
    border-radius: 0.375rem;
}

/* Ensure proper spacing for alerts */
.alert {
    margin-bottom: 1rem;
}
