@import '../../helper/config.scss';

body,
ul {
  margin: 0;
}

body {
  color: $text-color;
}

ul {
  list-style: none;
  padding: 0;
}

li {
  margin: 0 0 5px 20px;
  padding-left: 4px;
  font-size: 14px;
  line-height: 1.5;
  color: $text-color;
  font-family: $family;
  list-style-type: circle;
}

h1 {
  margin-top: 8px;
  margin-bottom: 20px;
  color: $text-color;
  font-weight: 500;
  font-size: 30px;
  font-family: $family;
  line-height: 38px;
}

h2,
h3,
h4,
h5,
h6 {
  clear: both;
  margin: 1.6em 0 0.6em;
  color: $text-color;
  font-weight: 500;
  line-height: 1.5;
  font-family: $family;
}

h2 {
  font-size: 24px;
}

h3 {
  font-size: 18px;
}

h4 {
  font-size: 16px;
}

h5 {
  font-size: 14px;
}

h6 {
  font-size: 12px;
}

p {
  margin: 1em 0;
  font-family: $family;
  font-weight: normal;
  font-size: 14px;
  line-height: 2;
}

code {
  margin: 0 1px;
  padding: 0.2em 0.4em;
  font-size: 0.9em;
  background: #f2f4f5;
  border: 1px solid $normal-border;
  border-radius: 3px;
}

table {
  min-width: 719px;
  margin: 2em 0;
  font-size: 14px;
  font-family: $family;
  line-height: 1.5;
  border-width: 0;
  width: 100%;
  empty-cells: show;
  border-collapse: collapse;
  border-spacing: 0;

  & th {
    background: #f5f5f5;
  }

  & td,
  & th {
    padding: 14px 16px;
    text-align: left;
    color: $text-color;
    border-bottom: 1px solid $normal-border;
    white-space: nowrap;
  }
}

.table-box {
  width: calc(100vw - 286px);
}

.link {
  color: #1996f9;
  text-decoration: none;
  cursor: pointer;
}

.layout {
  &-header {
    position: relative;
    z-index: 10;
    max-width: 100%;
    background: $normal-bg;
    -webkit-box-shadow: 0 2px 8px #f0f1f2;
    box-shadow: 0 2px 8px #f0f1f2;

    &-col {
      display: flex;
      align-items: center;
      justify-content: space-between;
    }
  }

  &-logo {
    font-family: $family;
    font-size: 20px;
    height: 64px;
    padding: 8px 40px;
    box-sizing: border-box;
    overflow: hidden;
    line-height: 64px;
    white-space: nowrap;
    text-decoration: none;

    &:focus {
      outline: none;
    }
  }

  &-main {
    position: relative;
    padding: 80px 0 0;
    background: $normal-bg;
  }

  &-mixin {
    font-family: $family;
    color: rgba(
      0,
      0,
      0,
      0.45
    );
    font-size: 14px;
    line-height: 1.5;
    transition: all 0.3s;
    padding: 8px 16px 8px 32px;
  }

  &-menu {
    overflow: auto;
    border-right: 1px solid #e8e8e8;
    position: fixed;
    z-index: 2;
    top: 80px;
    bottom: 0;

    &-sub {
      @extend .layout-mixin;
    }

    &-h2 {
      @extend .layout-mixin;
    }

    &-h3 {
      @extend .layout-mixin;

      padding-left: 48px;
    }

    &-item {
      @extend .layout-mixin;

      color: $text-color;
      overflow: hidden;
      line-height: 40px;
      text-overflow: ellipsis;
      padding: 0 16px 0 56px;
      margin-bottom: 8px;
      cursor: pointer;
      transition: color 0.15s;
      position: relative;

      &:last-child {
        margin-bottom: 0;
      }

      &::after {
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        border-right: 3px solid #1890ff;
        transform: scaleY(0.0001);
        opacity: 0;
        transition:
          transform 0.15s cubic-bezier(
            0.215,
            0.61,
            0.355,
            1
          ),
          opacity 0.15s cubic-bezier(
            0.215,
            0.61,
            0.355,
            1
          );
        content: '';
      }

      &:hover {
        color: $blue-6;
      }
    }

    &-link {
      @extend .layout-menu-item;

      padding-left: 32px;
      display: block;
      text-decoration: none;
    }

    &-on {
      background: #e6f7ff;
      color: $blue-6;

      &::after {
        transform: scaleY(1);
        opacity: 1;
      }
    }

    &-list {
      &:last-child {
        padding-bottom: 48px;
      }
    }
  } // menu end

  &-cantainer {
    position: relative;
    padding: 0 16px 16px 270px;
    background: $normal-bg;
    height: calc(100vh - 80px);
    box-sizing: border-box;
  }

  &-npm {
    padding-right: 40px;
  }

  &-wrap,
  &-body {
    width: 100%;
  }
}
