.vd-dashboard :is(.app-layout, .main-content, .content-body, .tab-pane, .panel-card) {
    min-width: 0;
    min-height: 0;
}

.vd-dashboard :is(.content-body, .sidebar) {
    scrollbar-width: thin;
}

.vd-dashboard .app-layout .content-body {
    height: auto;
    flex: 1 1 auto;
}

.vd-dashboard :is(.header, .exec-header, .header-actions, .panel-title) {
    flex-wrap: wrap;
    gap: 8px;
}

.vd-dashboard :is(.data-table-container, .table-scroll) {
    max-width: 100%;
    overflow: auto;
    isolation: isolate;
}

.vd-dashboard :is(.data-table, .table-scroll table) {
    table-layout: auto;
    border-collapse: separate;
    border-spacing: 0;
    font-size: .8125rem;
    line-height: 1.55;
}

.vd-dashboard :is(.data-table, .table-scroll table) :is(th, td) {
    padding: 9px 12px;
    text-align: start;
    vertical-align: middle;
}

.vd-dashboard :is(.data-table, .table-scroll table) th {
    min-width: 5rem;
    position: sticky;
    inset-block-start: 0;
    z-index: 2;
}

.vd-dashboard :is(.data-table, .table-scroll table) td {
    overflow-wrap: anywhere;
    white-space: normal;
}

.vd-dashboard .sidebar > :is(div, footer):has(> a[href="index.html"]) {
    position: sticky;
    inset-block-end: 0;
    flex-shrink: 0;
    padding-block-end: 6px;
    background: var(--sidebar-bg);
    z-index: 3;
}

.vd-dashboard :is(.header, .exec-header, .sidebar) a[href="index.html"] {
    min-height: 36px;
    align-content: center;
    flex-shrink: 0;
}

@media (max-width: 992px) {
    .vd-dashboard .app-layout,
    .vd-dashboard .app-layout .main-content {
        height: auto;
        overflow: visible;
    }

    .vd-dashboard .app-layout .sidebar {
        max-height: min(43dvh, 340px);
        overflow: auto;
    }
}

.vd-dashboard .login-container:has(#portalSelectionCard[style*="display: flex"]),
.vd-dashboard .login-container:has(#portalSelectionCard[style*="display: block"]) {
    max-width: min(920px, 100%);
}

.vd-dashboard .vd-portal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr));
    gap: 10px;
}

.vd-dashboard .vd-portal-grid .portal-option-btn {
    min-height: 52px;
    margin: 0;
    align-content: center;
}

@media (min-width: 993px) {
    .vd-dashboard:has(> .app-layout) { overflow: hidden; }
    .vd-dashboard > .app-layout { height: 100dvh; max-height: 100dvh; }
    .vd-dashboard > .app-layout > :is(.main-content, .sidebar) { height: 100%; box-sizing: border-box; }
    .vd-dashboard > .app-layout > .sidebar { overflow-y: auto; overscroll-behavior: contain; }
    .vd-dashboard .content-body { overflow: auto; overscroll-behavior: contain; }
    .vd-dashboard .tab-pane.active > .panel-card:has(.data-table-container) { min-height: calc(100dvh - 155px); box-sizing: border-box; }
    .vd-dashboard .tab-pane.active > .panel-card .data-table-container { max-height: calc(100dvh - 215px) !important; }
}

.vd-dashboard .sidebar > :is(div, footer):has(> a[href="index.html"]) {
    margin-block-start: auto;
    padding-block: 8px;
}

.vd-section-page .app-layout {
    display: grid;
    grid-template-columns: minmax(190px, 240px) minmax(0, 1fr);
    height: 100dvh;
}

.vd-section-page .sidebar { display: flex; flex-direction: column; gap: 12px; padding: 16px; }
.vd-section-page main { margin: 0; width: auto; max-width: none; min-width: 0; overflow: auto; padding: 24px; }
@media (max-width: 700px) {
    .vd-section-page .app-layout { height: auto; grid-template-columns: 1fr; }
    .vd-section-page main { padding: 16px; }
}
