@use '@vizality' as vz;

.vz-dashboard-content-sidebar {
  $base: &;
  margin: 0 0 0 60px;
  top: 40px;
  position: sticky;
  height: calc(100vh - 104px); /* titlebar height (24px) + top padding (40px) + bottom padding (40px) */
  box-sizing: border-box;
  display: flex;
  justify-content: flex-end;
  flex: 0;
  &-header {
    flex: 1 100%;
    &-wrapper {
      display: flex;
      justify-content: space-between;
      align-items: center;
      margin: 0 10px 10px;
    }
  }
  &-inner {
    @include vz.size(100%);
    opacity: 1;
    box-sizing: border-box;
  }
  &-item {
    margin: 15px;
    font-size: 16px;
    font-weight: 400;
  }
  &-item-wrapper {
    margin: 0;
  }
  &-collapser,
  &-expander {
    @include vz.size(30px);
    position: relative;
    margin: 0 auto;
    cursor: pointer;
    flex: 1 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    &::before {
      transform: rotate(0deg);
    }
    &::before,
    &::after {
      @include vz.size(14px, 3px);
      content: '';
      position: absolute;
      background-color: var(--channels-default);
      transition: background-color 0.2s;
    }
    &:hover {
      &::before,
      &::after {
        background-color: var(--header-primary);
      }
    }
  }
  &-expander {
    opacity: 0;
    width: 0;
    height: 0;
    transform: scale(0);
    transition: transform .15s;
    &::before,
    &::after {
      @include vz.size(20px, 4px);
    }
    &::before {
      transform: rotate(180deg);
    }
    &::after {
      opacity: 1;
      transform: rotate(-90deg);
    }
  }
  .textBadge-1fdDPJ {
    display: inline;
    margin-left: 7px;
    font-size: 10px;
    padding: 2px 6px;
  }
  &[vz-collapsed] {
    height: 50px !important;
    width: 50px;
    border-radius: 8px;
    overflow: hidden;
    align-items: center;
    justify-content: center;
    padding: 0;
    #{$base}-expander {
      @include vz.size(50px);
      opacity: 1;
      transform: scale(1);
    }
    #{$base}-inner {
      display: none;
    }
  }
}

