@import './../mixins/reset.scss';

@mixin tab-active {
  background-color: rgba(82, 108, 253, 0.3);

  &::before {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-left: 2px solid #526cfd;
    content: '';
  }
}

.amos-category-tab {
  @include reset-component2;

  position: relative;
  overflow: hidden;
  color: white;

  .nav-tab-all {
    position: absolute;
    top: 1em;
    left: 0;
    width: 10em;
    overflow: hidden;
    outline: none;

    .tab-item {
      position: relative;
      width: 100%;
      height: 3em;
      padding: 0.5em 0.8em;
      cursor: pointer;
      border-bottom: 1px solid rgba(213, 208, 215, 0.2);

      &:hover {
        @include tab-active;
      }

      .tab-name {
        display: block;
        float: left;
        width: 6em;
        text-align: left;
      }

      .tab-count {
        position: absolute;
        right: 0.8em;
      }
    }
  }

  .nav-tab-content {
    position: absolute;
    top: 1em;
    left: 10em;
    overflow: hidden;
    outline: none;

    .tab-content-item {
      position: relative;
      height: 3em;
      padding: 0.2em 0 0.2em 1em;
      margin-bottom: 0;
      line-height: 3em;
      cursor: pointer;

      img {
        float: left;
        width: 2em;
        height: 2em;
      }

      h5 {
        display: inline-block;
        width: calc(100% - 6em);
        height: 2em;
        padding-right: 3em;
        padding-left: 0.6em;
        margin: 0;
        font-size: 12px;
        font-weight: normal;
        line-height: 2em;
        color: white;
        text-align: left;
      }

      i[class*='icon'] + i[class*='icon'] {
        margin-left: 0.5em;
      }

      i[class*='icon'].favorite {
        color: red;
      }

      .extra-icon {
        display: none;
      }

      &:hover {
        background-color: rgba(82, 108, 253, 0.3);

        .extra-icon {
          display: inline-block;
        }
      }
    }
  }
}

.tab-active {
  background-color: rgba(82, 108, 253, 0.3);

  &::before {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-left: 2px solid #526cfd;
    content: '';
  }
}
