.el-select,
.el-date-editor {
  width: 100%;
}
.el-pagination {
  font-weight: normal;
}
.el-autocomplete {
  display: block;
}
.el-textarea__inner:focus,
.el-input__inner:focus {
  background-color: #fffacd;
}
.el-input--prefix .el-input__inner {
  padding-left: 20px;
}
.el-button {
  border-radius: $--border-radius-base;
}

.el-button--large {
  min-height: 36px;
  padding: 0 10px;
}
.el-button--default:hover {
  background: #fff;
  border-color: $--color-primary;
  color: $--color-primary;
}
.el-button--default:active {
  background: #fff;
  border-color: $--color-primary-active;
  color: $--color-primary-active;
}
.el-button--default:focus {
  background: #fff;
  border-color: $--border-color;
  color: $--color-text-1;
}
.el-button--primary:hover {
  background: $--color-primary-hover;
  color: $--color-white;
}
.el-button--primary:focus {
  background: $--color-primary;
  color: $--color-white;
}
.el-button--primary:active {
  background: $--color-primary-active;
  color: $--color-white;
}
.el-button--danger:hover {
  background: $--color-danger-hover;
}
.el-button--danger:focus {
  background: $--color-danger;
}
.el-button--primary.is-plain,
.el-button--primary.is-plain:focus {
  background: #fff;
  border-color: $--color-primary;
  color: $--color-primary;
}
.el-button--primary.is-plain:active {
  background: $--color-primary-active;
  color: #fff;
}

.el-select__popper,
.el-autocomplete__popper {
  .el-popper__arrow {
    display: none;
  }
}
.el-select__popper[data-popper-placement="top-start"],
.el-autocomplete__popper[data-popper-placement="top-start"] {
  margin-top: 10px !important;
}
.el-select__popper[data-popper-placement="bottom-start"],
.el-autocomplete__popper[data-popper-placement="bottom-start"] {
  margin-top: -10px !important;
}
.el-select__popper[data-popper-placement="right"],
.el-autocomplete__popper[data-popper-placement="right"] {
  margin-left: -10px !important;
}
.el-select__popper[data-popper-placement="left"],
.el-autocomplete__popper[data-popper-placement="left"] {
  margin-left: 10px !important;
}
.el-select-dropdown__list {
  list-style: none;
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}
.el-select-dropdown__item {
  padding: 0 10px;
  color: #333;
  line-height: 26px;
  height: 26px;
  &.selected {
    color: #409eff;
    font-weight: 700;
  }
  &.hover,
  &:hover {
    background-color: $--color-primary;
    color: $--color-white;
  }
}
.el-input {
  .el-input__icon {
    width: 14px;
  }
}
.el-pagination {
  &.mini {
    transform: scale(0.9);
  }
  li {
    background: none;
    margin: 0 3px;
    min-width: 22px;
    &.active {
      background: $--color-primary;
      color: $--color-white;
      border-radius: $--border-radius-base;
    }
  }

  .btn-prev,
  .btn-next,
  button:disabled {
    background: none;
  }
}
.el-message {
  min-height: 50px;
  .el-message__icon {
    font-size: 20px;
    color: $--color-white;
    margin-right: 5px;
    vertical-align: middle;
  }
  .el-message__content,
  .el-message__closeBtn {
    color: $--color-white;
  }
}
.el-message--info {
  background: $--color-primary;
  border-color: $--color-primary;
}
.el-message--success {
  background: $--color-success;
  border-color: $--color-success;
}
.el-message--warning {
  background: $--color-warning;
  border-color: $--color-warning;
}
.el-message--error {
  background: $--color-danger;
  border-color: $--color-danger;
}
.el-message-box__status {
  top: 11px;
  font-size: 24px !important;
  & + .el-message-box__message {
    padding-left: 34px;
  }
}
.el-message-box__status.el-icon-info {
  color: $--color-primary;
}
.el-message-box__btns {
  text-align: center;
  display: flex;
  flex-direction: row-reverse;
  justify-content: center;
  .el-button {
    min-height: 30px;
    padding: 5px 8px;
  }
  .el-button + .el-button {
    margin-right: 15px;
  }
}
.el-dialog {
  border-radius: 4px;
}
.el-dialog__header {
  background: $--color-primary;
  text-align: left;
  height: 45px;
  padding: 0px 20px;
  line-height: 45px;
  border-radius: 4px 4px 0 0;
}
.el-dialog__title {
  color: $--color-white;
}

.el-dialog__headerbtn {
  font-size: 20px;
  top: 10px;
  .el-dialog__close {
    color: $--color-white;
    &:hover {
      color: $--color-gray;
    }
  }
}

.el-dialog__footer {
  text-align: center;
  .el-button {
    height: 30px;
  }
  .el-button + .el-button {
    margin-left: 15px;
  }
}
.el-popper {
  padding: 5px;
  border-radius: $--border-radius-base;
}
.el-form-item__content:hover {
  > .el-form-item__error,
  > .el-form-item__error.el-form-item__error--inline {
    opacity: 1;
  }
}
.el-form-item__error,
.el-form-item__error.el-form-item__error--inline {
  color: #fff;
  font-size: 12px;
  line-height: 2em;
  position: absolute;
  top: calc(100% + 6px);
  left: 0px;
  margin-left: 0px;
  z-index: 111;
  background: #f9605c;
  padding: 3px 10px;
  border-radius: 2px;
  display: block !important;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.5s;
  white-space: normal;
  &:after {
    content: "";
    display: block;
    position: absolute;
    top: -14px;
    left: 10px;
    /* left: calc(50% - 10px); */
    border-style: solid;
    border-width: 7px;
    border-color: transparent transparent #f9605c;
  }
}
/*日期组件*/

.el-picker__popper.el-popper[role="tooltip"] {
  margin-top: -10px !important;
}
.el-picker-panel {
  color: #606266;
  background: #fff;
  border-radius: 4px;
  line-height: 30px;
  margin: 5px 0px;

  .el-date-table td {
    width: 32px;
    height: 20px;
    line-height: 20px;
    padding: 3px 0;
    text-align: center;
    cursor: pointer;
    position: relative;
  }
  .el-date-table td div {
    height: 20px;
    padding: 0;
  }
  .el-date-picker__header {
    margin: 12px;
    text-align: center;
  }
  .el-date-table th {
    padding: 5px;
    color: #606266;
    font-weight: 400;
    border-bottom: solid 1px #ebeef5;
  }
  .el-date-table td span {
    font-weight: normal;
    border-radius: $--border-radius-base;
    width: 18px;
    height: 18px;
    line-height: 16px;
  }
  .el-date-picker .el-picker-panel__content {
    width: 292px;
  }
  .el-date-table td.current:not(.disabled) span {
    color: #fff;
    background-color: $--color-primary;
  }
  // .el-date-table td.today span {
  //   border: 1px solid $--color-primary;
  //   color: $--color-primary;
  // }
  & + .el-popper__arrow {
    display: none;
  }
  .el-date-table td.start-date div {
    border-top-left-radius: 4px;
    border-bottom-left-radius: 4px;
    border-radius: 4px;
    margin-left: 10px;
  }
  .el-date-table td.end-date div {
    margin-right: 10px;
    border-top-right-radius: 4px;
    border-bottom-right-radius: 4px;
  }
}
.el-date-editor {
  &.el-input__inner {
    padding: 0 5px;
  }
  .el-range__icon,
  .el-range-separator {
    line-height: $--input-height;
  }
  .el-range-separator {
    padding: 0;
  }
  .el-range__close-icon {
    line-height: $--input-height;
    position: absolute;
    right: 0;
  }
}
.el-picker-panel__sidebar {
  width: 92%;
  height: 42px;
  overflow: hidden;
  bottom: 0;
  top: auto;
  padding: 10px 0;
  margin: 0 4%;
  border: 0;
  border-top: 1px solid $--border-color;
  position: absolute;
  .el-picker-panel__shortcut {
    border: 1px solid $--color-primary;
    border-radius: 2px;
    padding: 0 5px;
    line-height: 20px;
    font-size: 12px;
    color: $--color-primary;
    display: inline-block;
    margin-left: 5px;
    vertical-align: top;
    width: auto;
  }

  & + .el-picker-panel__body {
    margin: 0;
    padding-bottom: 42px;
    max-width: 498px;
    min-width: 0;
  }
}
.el-date-range-picker__header div {
  font-size: 12px;
}
.el-date-range-picker.has-sidebar {
  max-width: 500px;
  width: 100%;
}
.el-date-range-picker__content.is-left {
  border-right: 0;
}

.el-date-range-picker .el-picker-panel__content {
  padding: 20px 4% 10px 4%;
}
.el-date-range-picker__content.is-right {
  padding-left: 2%;
}

.el-table {
  th {
    text-align: center;
  }
  tr {
    background: #fff;
  }
  .cell {
    height: 28px;
  }
  // th:first-child .cell,
  // td:first-child .cell {
  //   text-align: center;
  //   padding: 0;
  // }
}
.el-input,
.el-date-editor {
  .el-icon-circle-close {
    color: $--color-danger !important;
    font-weight: bolder;
  }
}

.bo-input-select__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  // padding: 0 15px;

  .left {
    flex: 1;
    overflow: hidden;
    word-break: break-all;
    text-overflow: ellipsis;
  }
  .right {
    text-align: right;
    width: 20%;
  }
  span {
    width: 12%;
    flex: none;
    overflow: hidden;
    word-break: break-all;
    text-overflow: ellipsis;
  }
}

.bo-input-select-nodata {
  padding: 20px;
  text-align: center;
}
.bo-input-select-loading {
  text-align: center;
  height: 100px;
  line-height: 100px;
  font-size: 20px;
  color: #999;
}
.font16 {
  font-size: 16px;
}
.font28 {
  font-size: 28px;
}
.mt10 {
  margin-top: 10px;
}

//颜色暴露，为后期主题颜色做处理
$colors_names: primary, warning, success, danger;
$colors_vars: $--color-primary, $--color-warning, $--color-success,
  $--color-danger;
@each $color in $colors_vars {
  $i: index($colors_vars, $color);
  .bg-#{nth($colors_names,$i)} {
    background-color: $color !important;
    color: #fff;
  }
  .fc-#{nth($colors_names,$i)} {
    color: $color !important;
  }
}

//字体颜色
$fc_vars: $--color-text-1, $--color-text-2, $--color-text-3;
@each $color in $fc_vars {
  $i: index($fc_vars, $color);
  .fc-#{$i} {
    color: $color !important;
  }
}

//背景色
.bg-gray {
  background-color: $--bg-gray !important;
}
.bg-gray-1 {
  background-color: $--bg-gray-1 !important;
}
.bg-gray-2 {
  background-color: $--bg-gray-2 !important;
}

//bo-confirm-dialog
.bo-confirm-dialog {
  .el-dialog__header {
    background: transparent;
    height: 0;
    padding: 10px;
  }
  .el-dialog__headerbtn .el-dialog__close {
    color: $--color-text-3;
  }
}
.dialog-header-white {
  .el-dialog__title {
    color: $--color-text;
  }
  .el-dialog__header {
    background: #fff;
  }
  .el-dialog__headerbtn .el-dialog__close {
    color: $--color-text-3;
  }
}
.el-tabs__nav {
  padding-left: 10px;
}
.el-tabs--card {
  > .el-tabs__header .el-tabs__nav {
    padding-left: 0px;
    border-radius: 0;
    border-top: none;
    border-left: none;
    border-right: none;
  }
  > .el-tabs__header .el-tabs__item {
    border-left: none;
  }
  > .el-tabs__header .el-tabs__item.is-active {
    border-top: 1px solid $--color-primary;
    border-right: 1px solid $--border-color;
    border-left: 1px solid $--border-color;
    &:after {
      content: "";
      position: absolute;
      bottom: -2px;
      height: 2px;
      background: #fff;
      width: 100%;
      left: 0;
    }
  }
}
.el-tabs--border-card {
  box-shadow: none;
  border: none;
  > .el-tabs__header {
    background-color: transparent;
    border: none;
  }
  > .el-tabs__header .el-tabs__item {
    border: none;
    &::after {
      background: transparent;
      border: 1px solid $--border-color;
      border-top-width: 2px;
      content: "";
      position: absolute;
      width: 100%;
      height: 29px;
      left: 0;
      box-sizing: border-box;
      z-index: 20;
      top: 0px;
    }
  }
  > .el-tabs__header .el-tabs__item.is-active {
    &::after {
      border-color: $--color-primary;
      z-index: 21;
    }
  }
}
.el-drawer-overlay {
  background: transparent;
}
.el-drawer.rtl {
  padding-left: 20px;
}
.el-drawer__header {
  color: #333;
  padding-bottom: 15px;
  padding-right: 10px;
  padding-left: 0;
  border-bottom: 1px solid #e6e6e6;
  margin-bottom: 0;
  .el-drawer__close-btn {
    color: #c2c2c2;
  }
}
