/* 1. Change the sidebar to use flexbox layout */
#sidebar {
    position: relative;        /* Remove absolute positioning */
    top: auto;                 /* Remove top offset */
    min-height: auto;          /* Remove min-height */
    z-index: auto;            /* Remove z-index */
    width: 180px;             /* Fixed width for the sidebar */
    flex: 0 0 auto;           /* Prevent it from shrinking */
    background: #fafafa;
    border-right: 1px solid rgba(0, 0, 0, 0.05);
    padding: 16px;
    overflow-y: auto;
    height: 100vh;            /* Full height */
}

/* 2. Ensure the main row uses flexbox properly */
#mainrow {
    display: flex;
    flex-wrap: nowrap;
    flex-direction: row;
    flex: 1 1 auto;
    overflow: hidden;
    height: 100%;             /* Ensure it takes full height */
}

/* 3. Make the content area fill remaining space */
#content {
    flex: 1 1 auto;           /* Takes remaining width */
    overflow: auto;
    position: relative;
    order: 50;
}