/* reset */
body,
div,
ul,
ol,
li,
h1,
h2,
h3,
h4,
h5,
h6,
input,
p,
tr,
th,
td,
span,
a,
header,
footer,
i {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: rgba(255, 255, 255, 0);
}
li {
  list-style: none;
}
em,
i,
u {
  font-style: normal;
}
input {
  outline: none;
  border: none;
  background: rgba(245, 245, 245, 1);
  font-family: $--font-family;
}
input::-webkit-input-placeholder,
input::-moz-placeholder,
input:-ms-input-placeholder,
input:-moz-placeholder {
  font-size: 12px;
  font-weight: bold;
  color: $--color-text-gray-4;
}
button,
textarea {
  font-family: $--font-family;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: 100%;
}
fieldset,
img {
  border: 0;
}
abbr {
  border: 0;
  font-variant: normal;
}
a {
  text-decoration: none;
  color: inherit;
  *color: $--color-text-gray-3;
}
img {
  vertical-align: middle;
}

/* common-style */
input:-webkit-autofill {
  box-shadow: 0 0 0 1000px white inset;
}
input[type="text"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
textarea:focus {
  box-shadow: 0 0 0 1000px white inset;
}

/* browse style */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
  background: transparent;
}
::-webkit-scrollbar-button {
  display: none;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: #666;
}
::-webkit-scrollbar-corner {
  background: transparent;
}
::-webkit-scrollbar-resizer {
  background: transparent;
}

body {
  font-family: $--font-family;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: $--font-size-base;
  color: $--color-text-dark-1;
}

/* part */
.part-box {
  margin-bottom: 20px;
  background-color: #fff;
  border-radius: $--border-radius;

  &-border {
    border: 1px solid $--color-border;
  }
  &-border-bold {
    border: 1px solid $--color-border-bold;
  }
  &-pad {
    padding: 20px;
  }

  &-filter {
    padding: 20px;

    .el-form-item {
      margin-bottom: 15px;
    }
    .el-form-item__label {
      display: none;
    }
  }
  &-gray {
    background-color: $--color-text-gray-7;
  }

  &-flex {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    padding: 20px 20px 5px 20px;
  }

  &-action {
    padding-bottom: 15px;
    white-space: nowrap;
    display: flex;
    align-items: flex-end;
  }
  &-tips {
    font-size: 16px;
    line-height: 25px;
    color: $--color-text-dark-1;
    margin-bottom: 15px;
  }

  &-head {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    min-height: 30px;
    margin: 0 0 10px;
    color: $--color-text-dark;

    > h3 {
      font-size: 16px;
      font-weight: 600;
    }
    .el-icon-question {
      margin-left: 10px;
      font-size: 16px;
      color: $--color-text-gray-5;
      cursor: pointer;

      &:hover {
        color: #fe8652;
      }
    }
  }
}
.part-title {
  font-size: 16px;
  font-weight: bold;
  line-height: 30px;
  overflow: hidden;

  h2 {
    float: left;
  }
  &-infos {
    float: right;
  }
}
.part-body {
  padding: 25px;
}
.part-page {
  margin-top: 15px;
  text-align: right;
}
.part-none {
  padding: 100px;
  font-size: 20px;
  color: $--color-text-gray-3;
  text-align: center;
}
// box-justify
.box-justify {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.box-grow {
  flex-grow: 2;
}
.box-static {
  flex-grow: 0;
  flex-shrink: 0;
}

// page-head
.page-head {
  margin-bottom: 20px;
  color: $--color-text-dark;
  &-flex {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
  }

  > h2 {
    font-size: 20px;
  }
  .el-icon-question {
    margin-left: 10px;
    font-size: 16px;
    color: $--color-text-gray-5;
    cursor: pointer;

    &:hover {
      color: #fe8652;
    }
  }
}

/* table */
.table {
  width: 100%;
  border-spacing: 0;
  border-collapse: collapse;
  text-align: left;

  &.table-white {
    background-color: #fff;
  }

  th {
    padding: 12px;
    line-height: 1.2;
    letter-spacing: 1px;
    color: $--color-text-gray-2;
    border: 1px solid $--color-border;
  }
  td {
    padding: 14px;
    line-height: 1.2;
    color: $--color-text-dark;
    border: 1px solid $--color-border;

    &.td-link {
      span {
        cursor: pointer;
        &:hover {
          color: $--color-text-gray;
        }
      }
    }
  }
  .td-th {
    font-weight: 600;
    color: $--color-text-gray;
  }
  .td-bg {
    background-color: #f5f7fa;
  }

  &--border {
    border: 1px solid $--color-border;
    border-radius: 10px;
    th {
      background-color: #fcfcfd;
      border: none;
      border-bottom: 1px solid $--color-border;
    }
    td {
      border: none;
      border-bottom: 1px solid $--color-border;
    }
  }

  &-tiny {
    th,
    td {
      padding: 6px 10px;
    }
  }

  // action-column
  td.action-column {
    padding-left: 10px;
    padding-right: 10px;
    .el-button--text {
      padding: 0;
      margin: 0 5px;
      border: none !important;
      outline: none !important;
      &:not(.is-disabled):hover {
        transform: scale(1.1);
      }
    }
  }
}

/* list */
.list-lr-right {
  float: right;
  width: 300px;
}
.list-lr-left {
  margin-right: 320px;
}

.vlcode {
  height: 36px;
}
.vlcode-left {
  margin-right: 135px;
}
.vlcode-right {
  float: right;
  width: 120px;
}

// color
.color-primary {
  color: $--color-primary;
}
.color-success {
  color: $--color-success;
}
.color-warning {
  color: $--color-warning;
}
.color-danger {
  color: $--color-danger;
}
.color-info {
  color: $--color-text-gray-1;
}
.color-dark {
  color: $--color-dark;
}
.color-gray {
  color: $--color-text-gray;
}
.color-gray-1 {
  color: $--color-text-gray-1;
}
.color-gray-2 {
  color: $--color-text-gray-2;
}
.color-gray-3 {
  color: $--color-text-gray-3;
}
.color-gray-4 {
  color: $--color-text-gray-4;
}
.color-white {
  color: #fff;
}

// text
.text-center {
  text-align: center;
}
.text-left {
  text-align: left;
}
.text-right {
  text-align: right;
}
.text-prewrap {
  white-space: pre-wrap;
}

// other
.btn-danger {
  &.el-button--text:not(.is-disabled) {
    color: $--color-danger !important;

    &:hover {
      font-weight: 600;
      color: mix(#000, $--color-danger, 20%) !important;
    }
  }
  &.is-disabled {
    color: $--color-text-gray-4;
  }
}
.btn-primary {
  &.el-button--text:not(.is-disabled) {
    color: $--color-primary !important;
    &:hover {
      font-weight: 600;
      color: mix(#000, $--color-primary, 20%) !important;
    }
  }
}
.btn-success {
  &.el-button--text:not(.is-disabled) {
    color: $--color-success !important;
    &:hover {
      font-weight: 600;
      color: mix(#000, $--color-success, 20%) !important;
    }
  }
}
.btn-icon {
  &.el-button--text {
    font-size: 20px !important;
    padding: 5px 0;

    > i {
      display: inline;
    }
  }
}
.btn-link {
  position: relative;
  color: $--color-primary;
  display: inline-block;
  vertical-align: middle;
  line-height: 20px;
  margin-top: -2px;
  padding: 8px 0;

  &::after {
    content: "";
    display: block;
    position: absolute;
    width: 100%;
    bottom: 4px;
    left: 0;
    border-bottom: 1px solid $--color-primary;
  }

  &:hover {
    color: mix(#000, $--color-primary, 20%);
    &::after {
      border-color: mix(#000, $--color-primary, 20%);
    }
  }
}

.btn-back.el-button {
  height: 30px;
  padding: 4px 10px;
  line-height: 20px;
  background: none;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #606266;

  &:hover {
    color: $--color-danger;
    border-color: $--color-danger;
  }
}

.btn-white {
  background-color: #fff !important;
  color: #999 !important;
}
.font-bold {
  font-weight: bold;
}
.table-head-bg {
  th {
    background-color: #f6f6f6;
    color: $--color-text-gray;
  }
}

.tab-btns {
  height: 36px;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;

  .el-button {
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 0;

    &:first-child {
      border-bottom-left-radius: 8px;
    }

    &:last-child {
      border-bottom-right-radius: 8px;
    }
  }

  .el-button + .el-button {
    margin-left: 10px;
  }
}
.big-btns {
  display: flex;
  justify-content: space-between;
  align-content: center;

  .el-button {
    padding: 40px;
    font-size: 30px;
    min-width: 200px;
  }
}
.cont-link {
  color: $--color-primary;
  cursor: pointer;
  &:hover {
    opacity: 0.8;
  }
}
.ml-1 {
  margin-left: 5px;
}
.ml-2 {
  margin-left: 10px;
}
.ml-4 {
  margin-left: 20px;
}
.mr-1 {
  margin-right: 5px;
}
.mr-2 {
  margin-right: 10px;
}
.mr-4 {
  margin-right: 20px;
}
.mt-1 {
  margin-top: 5px;
}
.mt-2 {
  margin-top: 10px;
}
.mb-0 {
  margin-bottom: 0;
}
.mb-1 {
  margin-bottom: 5px;
}
.mb-2 {
  margin-bottom: 10px;
}
.mb-4 {
  margin-bottom: 20px;
}
.mlr-1 {
  margin-left: 5px;
  margin-right: 5px;
}
.width-full {
  width: 100%;
}
.width-400 {
  width: 400px;
}
.width-80 {
  width: 80px;
}
.width-50 {
  width: 50px;
}
.width-200 {
  width: 200px;
}
.width-100 {
  width: 100px;
}
.tooltip-area {
  max-width: 600px;
  max-height: 400px;
  line-height: 20px;
  overflow: auto;
}

// other
.tips-info {
  font-size: 14px;
  line-height: 20px;
  color: $--color-text-gray-1;

  > i {
    margin-right: 2px;
  }
}
.tips-dark {
  color: $--color-text-gray;
}
.tips-error {
  color: $--color-danger;
}
.tips-success {
  color: $--color-success;
}
.tips-markedness {
  font-size: 14px;
  line-height: 20px;
  color: $--color-danger;
  font-weight: bold;
}
.tips-icon {
  display: inline-block;
  vertical-align: middle;
  color: $--color-text-gray-3;
  font-size: 18px;
  margin: 0 10px;
  cursor: pointer;
}
.form-item-content {
  color: $--color-text-gray-2;
}
.inline-block {
  display: inline-block;
  vertical-align: top;
}
.custom-tree-node {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  padding-right: 8px;

  > span:nth-of-type(1) {
    display: block;
    flex-grow: 2;
    word-wrap: break-word;
    white-space: normal;
  }
  .el-checkbox {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
  }
  .el-checkbox__input {
    margin-top: 4px;
  }

  .el-checkbox__label {
    word-wrap: break-word;
    white-space: normal;
    word-break: break-all;
  }

  .org-edit {
    flex-grow: 0;
    flex-shrink: 0;
  }
}
.custom-common-node {
  white-space: normal;
  word-break: break-all;
}

.tooltip-info-icon {
  color: $--color-text-gray-3;
  cursor: pointer;

  &:hover {
    color: $--color-dark;
  }
}
