.portalHeaderRight {
  align-items: center;
  display: flex;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  gap: 14px;
  justify-content: flex-end;
  line-height: 1;
  min-height: 36px;
  white-space: nowrap;
}

.portalHeaderRight .authStatus {
  align-items: center;
  display: inline-flex;
  flex: 0 0 auto;
  justify-content: center;
  line-height: 1;
  margin: 0;
  min-height: 36px;
}

.portalHeaderRight .authStatus strong,
.portalHeaderRight > .textButton,
.portalHeaderRight > .iconButton {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  line-height: 1;
}

.portalHeaderRight > .textButton,
.portalHeaderRight > .iconButton {
  flex: 0 0 auto;
}

.portalHeaderRight > .textButton[hidden],
.portalHeaderRight > .iconButton[hidden],
.portalHeaderRight > .authStatus[hidden],
.portalHeaderRight > .platformAdminMenu[hidden] {
  display: none;
}

.portalHeaderRight .platformAdminMenu {
  flex: 0 0 auto;
  position: relative;
}

/* Preserve the menu slot when no module commands are available.
   Visibility also removes the empty trigger from keyboard focus and accessibility. */
.portalHeaderRight .platformAdminMenu:not(:has(.platformAdminMenuPanel > :is(button, a):not([hidden]))) {
  visibility: hidden;
  pointer-events: none;
}

@media (max-width: 900px) {
  .portalHeaderRight {
    flex-wrap: wrap;
    height: auto;
    min-height: 36px;
  }
}
