@use '../../../scss/main_screen/_navbar';

.chatAndNavbar {
  display: flex;
  flex-direction: column;

  .chatNavbar {
    @include navbar.navbar;
    display: flex;
    align-items: center;
    padding: 0px;

    .chatNavbarHeadingWrapper {
      // Otherwise it will refuse to truncate the chat name
      // and will make the parent overflow instead.
      width: 0;
      flex-grow: 1;
    }
    :global(.navbar-heading) {
      position: relative;

      width: fit-content;
      // See `.chatNavbarHeadingWrapper`.
      max-width: 100%;

      display: flex;
      align-items: center;
      padding-inline-start: 5px;
      margin-inline-end: 0px;
      overflow-x: hidden;
      white-space: nowrap;
      text-overflow: ellipsis;
      font-size: 18px;
      font-weight: bold;
      overflow: hidden;

      h1,
      h2,
      h3,
      h4,
      h5,
      h6 {
        font-size: inherit;
        font-weight: inherit;
        display: block;
        margin: 0;
      }
    }
    :global(.navbar-heading-chat-info-button) {
      // Fill the parent, overlay the siblings.
      position: absolute;
      inset: 0;
      background-color: transparent;
      border: none;
    }

    :global(.views) {
      display: flex;
      align-items: center;
      min-height: 26px;
    }

    .navbarButton {
      padding: 0;
      width: 22px;
      height: 22px;
      border-radius: 0;
      margin-inline-end: 12px;
      align-items: center;
      justify-content: center;
      &:hover {
        background-color: var(--navBarButtonHover);
      }
    }

    .appsGroup {
      display: flex;
      align-items: center;
      gap: 10px;
      margin-inline-end: 24px;

      .navbarButton {
        margin-inline-end: 0;
      }
    }

    .messageMultiselectCounter {
      font-size: large;
      font-weight: bold;
      line-height: normal;
      margin: 0.5rem 1rem;
    }
  }
}

.webxdcIcons {
  line-height: 0;
  img.webxdcIcon {
    width: 22px;
    height: 22px;
    cursor: pointer;
    border-radius: 3px;
  }
}

.webxdcIconButton {
  display: inline-block !important;
  margin: 0;
  margin-inline-end: 10px;
  padding: 0 !important;
  border-radius: 0 !important;
  line-height: 0;
  &:last-child {
    margin-inline-end: 0;
  }
}
