/**
 * Mobile: hide the existing dashboard sidebar until Menu is tapped.
 * Does not change the desktop menu structure.
 */

.dashboard__content-wrap:has(.studio-ia-page-actions) {
    overflow: visible;
}

.dashboard__content-title {
    gap: 0.75rem;
    min-width: 0;
}

.dashboard__content-title .title {
    min-width: 0;
}

.dashboard__content-title .studio-ia-page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    min-width: 0;
    max-width: 100%;
}

.dashboard__content-title .studio-ia-page-actions .btn-hight-basic,
.dashboard__content-title .studio-ia-page-actions .btn {
    height: auto !important;
    min-height: 44px;
    white-space: normal;
    line-height: 1.3 !important;
    min-width: 0 !important;
    max-width: 100%;
    overflow: visible;
    padding-top: 10px;
    padding-bottom: 10px;
}

.studio-ia-simulations-empty .btn-hight-basic {
    height: auto !important;
    min-height: 44px;
    white-space: normal;
    overflow: visible;
}

.main-area.fix:has(.dashboard__area) {
    overflow: visible;
}

.dashboard-mobile-nav__toggle {
    height: auto !important;
    min-height: 44px;
    padding: 12px 16px;
    overflow: visible;
}

.dashboard-mobile-nav__chevron {
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.dashboard-sidebar-column.is-open .dashboard-mobile-nav__toggle .dashboard-mobile-nav__chevron {
    transform: rotate(180deg);
}

@media (max-width: 1199.98px) {
    .dashboard__content-title.d-flex {
        flex-direction: column;
        align-items: stretch !important;
    }

    .dashboard__content-title .studio-ia-page-actions {
        flex: 1 1 auto !important;
        width: 100%;
    }

    .dashboard__content-title .studio-ia-page-actions .btn {
        width: 100%;
        justify-content: center;
        text-align: center;
    }
}

@media (min-width: 992px) {
    .dashboard-sidebar-panel {
        display: block !important;
    }
}

@media (max-width: 991.98px) {
    .dashboard-mobile-nav {
        position: sticky;
        top: 12px;
        z-index: 30;
    }

    .dashboard-sidebar-panel {
        display: none;
    }

    .dashboard-sidebar-column.is-open .dashboard-sidebar-panel {
        display: block;
    }

    .dashboard__sidebar-wrap {
        position: relative;
        top: auto;
        max-height: min(70vh, 32rem);
        overflow-y: auto;
        margin-bottom: 16px;
    }
}
