@import '../../../styles/app';

.headerLink {
  width: 100%;
  overflow-x: hidden;

  @media (min-width: map_get($grid-breakpoints, lg))
  and (min-height: $screen-lg-height), (max-width: map_get($grid-breakpoints, md) - 1px) {
    font-size: 13px;
  }

  a {
    display: block;
    color: var(--sidebar-color);
    text-decoration: none;
    cursor: pointer;
  }

  &:last-child > a {
    border-bottom: 1px solid $sidebar-item-border-color;
  }

  > a,
  > div a {
    align-items: center;
    position: relative;
    padding-left: 64px;
    line-height: 58px;
    border-top: 1px solid $sidebar-item-border-color;
    font-size: 14px;
    font-weight: $font-weight-normal;

    &:hover {
      background-color: var(--sidebar-item-hover-bg-color);
    }

    > i {
      margin-right: 7px;
    }
  }

  .icon {
    font-size: $font-size-larger;
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 10px;
    left: 16px;
    width: 32px;
    height: 32px;
    line-height: 28px;
    text-align: center;

    @media (min-width: map_get($grid-breakpoints, lg))
    and (min-height: $screen-lg-height), (max-width: map_get($grid-breakpoints, md) - 1px) {
      top: 12px;
    }
  }

  .badge {
    float: right;
    line-height: 10px;
    margin-top: 20px;
    margin-right: 20px;
    font-size: 0.875em;
    background: var(--sidebar-badge-bg);

    @media (min-width: map_get($grid-breakpoints, lg)) and (min-height: $screen-lg-height), (max-width: map_get($grid-breakpoints, md) - 1px) {
      margin-top: 16px;
    }
  }
  .collapse > ul > li a {
    padding-left: 50px;
  }
  #collapsemenu > ul > li a {
    padding-bottom: 14px;
  }
}

.headerLabel {
  font-weight: 600;
}

.caretWrapper {
  display: flex;
  align-items: center;
  margin-left: auto;
  margin-right: 22px;
  color: var(--sidebar-color);

  i {
    @include transition(transform 0.3s ease-in-out);
  }
}

.caretWrapper i {
  font-size: $font-size-larger;
}
.carretActive i {
  transform: rotate(90deg);
}

div a.router-link-active {
  color: var(--sidebar-item-active);
  font-size: $font-size-larger;
  font-weight: $font-weight-semi-bold;

  .icon {
    border-radius: 50%;
    background-color: var(--sidebar-item-active-bg);

    i {
      color: var(--sidebar-icon-active);
    }
  }
}

.collapse,
.collapsing {
  border: none;
  box-shadow: none;
  margin: 0;
  border-radius: 0;

  a {
    line-height: 20px !important;

    &.router-link-active {
      font-weight: $font-weight-semi-bold;
      color: var(--sidebar-item-active);
    }
  }

  ul {
    background: var(--sidebar-action-bg);
    padding: $spacer;

    li {
      list-style: none;
    }

    a {
      padding: 10px 20px 10px 26px;
      font-size: $font-size-mini;

      &:hover {
        background-color: var(--sidebar-item-hover-bg-color);
      }
    }
  }
}
