@import "common/var";

.zte-menu {
  width: 150px;
  height: 100%;
  background-color: #fff;
  display: flex;
  flex-direction: column;
  transition: 0.3s width ease-in-out;
  &.is-collapse {
    width: 65px;
    .el-submenu__title {
      text-align: center;
    }
  }
  .menu-title {
    flex: 0 0 40px;
    height: 40px;
    font-size: 18px;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    color: $theme;
    color: var(--theme);
    cursor: pointer;

    .title {
      margin-right: 10px;
    }

    .el-cascader {
      width: 150px;
      transition: width .3s ease-in-out;

      .el-input__inner {
        border: 0;
      }
    }

    .svg-icon {
      width: 30px;
      height: 30px;
      line-height: 30px;
      color: $theme;
      color: var(--theme);
    }
  }
  .el-scrollbar {
    flex: 1 1 100%;
    width: 100%;
    height: 100%;
    .el-scrollbar__wrap {
      overflow-x: hidden;
    }
    .menu-vertical {
      background-color: #fff;
      border: 0;

      &.el-menu--collapse {
        .el-submenu.is-active .svg-icon{
          color: $theme;
          color: var(--theme);
        }
      }

      &:not(.el-menu--collapse) {
        width: 100%;
      }
      .el-submenu__title {
        padding: 0 10px !important;
      }
      .el-menu-item {
        padding-right: 0;
        min-width: auto;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }
      .el-submenu__title,
      .el-menu-item {
        color: #333;
        background-color: #fff;
        height: 40px;
        line-height: 40px;
        font-size: 13px;
        .svg-icon {
          margin: 0 5px;
          width: 14px;
          height: 14px;
        }

        i {
          color: inherit;
        }

        &:hover,
        &:focus {
          background-color: $light;
          background-color: var(--light);
          color: #fff;
        }
      }
      .el-submenu .el-menu-item {
        height: 40px;
        line-height: 40px;
      }
      .el-submenu .el-menu-item:not(:hover):not(:focus):not(.is-active) {
        color: #999;
      }

      .el-menu-item.is-active,
      .el-submenu.is-opened {
        background-color: $light;
        background-color: var(--light);
        color: #fff;

        .el-menu {
          background-color: $theme;
          background-color: var(--light);
        }
      }
    }
  }
}