$menuBgColor: #3D4A5B;
$subMenuBgColor: #293448;
$menuBorderColor: #50647c;
$textColor: #f3f3ff;
$subMenuTextColor: #6d8cb3;

@mixin mx-menu-switcher-arrow {
  display: inline-block;
  content: ' ';
  border: 2px solid #ccc;
  transform: rotate(45deg);
  width: 6px;
  height: 6px;
}
.menu-mini {
  color: $textColor;
  list-style: none;
  height: 100%;
  margin-bottom: -50px;
  background: $menuBgColor;
  width: 50px;
  cursor: pointer;
  margin: 0;
  padding: 0;
  .menu-switcher {
    position: absolute;
    left: 17px;
    bottom: 7px;
    &:before {
      @include mx-menu-switcher-arrow;
      border-left-width: 0;
      border-bottom-width: 0;
    }
    &:after {
      @include mx-menu-switcher-arrow;
      border-left-width: 0;
      border-bottom-width: 0;
    }
  }
  .menu-item {
    background: $menuBgColor;
    border-bottom: 1px solid $menuBorderColor;
    padding: 0 20px 0 10px;
    line-height: 50px;
    &:hover,
    &.active {
      background: $subMenuBgColor;
    }
    &:hover {
      .sub-menu {
        display: block;
      }
    }
    .label-name {
      display: block;
      color: $textColor;
      text-decoration: none;
      /*
      &:after {
        content: ' ';
        display: inline-block;
        width: 8px;
        height: 8px;
        border-top: 2px solid $textColor;
        border-right: 2px solid $textColor;
        transform: rotate(45deg);
        float: right;
        margin-top: 21px;
      }
      */

      .label-txt {
        display: none;
      }
    }
    &.active {
      &::before {
        display: inline-block;
        float: right;
        content: ' ';
        width: 0;
        height: 0;
        margin-top: 24px;
        margin-right: -24px;
        border-color: transparent;
        border-left: 6px solid transparent;
        border-right: 6px solid transparent;
        border-bottom: 6px solid $textColor;
        transform: rotate(-90deg);
      }
      .label-name{
        &.active {
          color: $textColor;
        }
        &:after {
          transform: rotate(135deg);
        }
      }
    }
    .sub-menu {
      list-style: none;
      border-top: 1px solid $menuBorderColor;
      position: absolute;
      left: 50px;
      top: 0;
      margin: 0;
      width: 160px;
      z-index: 101;
      padding: 0;
      display: none;
      .sub-menu-item {
        line-height: 50px;
        .label-name {
          color: $subMenuTextColor;
          &:hover,&:active {
            color: $textColor;
          }
          &.active {
            color: $textColor;
          }
          &:after {
            display: none;
          }
        }
        padding: 0 10px;
        background: $subMenuBgColor;
      }
    }
  }
  &.with-icon {
    .menu-item {
      position: relative;

      .item-icon {
        position: relative;
        width: 20px;
        height: 20px;
        margin-left: 5px;
        top: 5px;
      }
    }
  }
}

