/*
 * @Author: Michael 
 * @Date: 2017-09-08 17:38:18 
 * @Last Modified by: chenshu
 * @Last Modified time: 2020-08-31 14:55:30
 */
@import "./variables.less";

@active-color: #2966ff;

// 消息提示框
.ant-message {
  & > span {
    display: block !important;
  }
}

.ant-drawer-content {
  .ant-drawer-title {
    font-weight: normal;
  }
}

.ant-steps-item .ant-steps-item-icon > .ant-steps-icon {
  top: -6%;
}

.ant-calendar-month-panel {
  .ant-calendar-month-panel-header {
    .ant-calendar-month-panel-next-year-btn,
    .ant-calendar-month-panel-prev-year-btn {
      height: auto;
    }
  }
}

.ant-form-item-children {
  display: block;
}

.ant-switch-small:after {
  top: 0.3px;
}

.ant-pagination {
  display: inline !important;

  .ant-pagination-jump-next {
    color: #f3f3f3 !important;
  }

  .ant-pagination-jump-next:after {
    display: inherit !important;
  }

  .ant-pagination-jump-prev {
    color: #f3f3f3 !important;
  }

  .ant-pagination-jump-prev:after {
    display: inherit !important;
  }
}

.ant-form-item {
  margin-bottom: 16px !important;
}

.ant-form-item-margin0 {
  margin-bottom: 0 !important;
}

.ant-radio {
  // .ant-radio-inner {
  //   width: 14px !important;
  //   height: 14px !important;
  // }

  .ant-radio-inner:after {
    height: 8px !important;
    width: 8px !important;
    left: 3px !important;
    top: 3px !important;
  }
}

.ant-dropdown-link {
  color: #5d5d5e !important;
}

.ant-table-fixed-header {
  .ant-table-scroll {
    .ant-table-header {
      // padding-bottom: 0 !important;
    }
  }
}

.ant-table-bordered {
  .ant-table-thead {
    tr {
      th {
        border-bottom: none;
        border-right: none !important;
      }
    }
  }

  .ant-table-tbody {
    tr {
      td {
        border-bottom: none;
        border-right: none !important;
      }

      td:last-child {
        &.table-no-right-border {
          border-right: none !important;
        }
      }
    }

    tr:last-child {
      border-bottom: 1px solid #e8e8e8 !important;
    }
  }
}

.ant-input {
  font-size: 14px !important;
  border-color: #d9d9d9;
}

.ant-input[disabled] {
  background-color: #f0f2f5 !important;
}

.ant-dropdown-link {
  line-height: 20px !important;
}

.ant-table-thead {
  tr {
    .center {
      text-align: center !important;
    }
  }
}

.ant-time-picker-panel-select-option-disabled {
  display: none;
}

.ant-select-auto-complete.ant-select .ant-select-selection--single {
  height: 32px !important;
}

.ant-table {
  tr {
    th {
      background: @xm-table-header;
      color: @xm-table-head-color;
    }
  }

  tbody {
    .ant-table-row-hover {
      td {
        background: @xm-table-body-active !important;
      }
    }

    tr {
      background: transparent;

      td {
        color: @xm-table-tbody-color;
      }

      &:nth-child(even) {
        background: @xm-table-body-even;
      }

      &:hover {
        td {
          background: @xm-table-body-active !important;
        }
      }
    }
  }
}

.ant-table-bordered {
  .ant-table-body {
    border: 1px solid #e8e8e8;
  }
  .ant-table-header > table,
  .ant-table-body > table {
    border: none !important;
    border-radius: 3px;
    .icon {
      color: #bfbfbf;
    }
  }
}
.ant-table-body {
  overflow-y: auto !important;
}

.ant-table-fixed-right .ant-table-fixed {
  border-left: none !important;
  border-right: 1px solid #e8e8e8 !important;
}

.ant-input-search-button {
  height: 32px !important;
}

.ant-avatar {
  width: 35px;
  height: 35px;
  line-height: 35px;
  border-radius: 25px;
}

/* tab选择 */
.ant-tabs-nav .ant-tabs-tab {
  padding: 8px 20px 12px !important;
  font-size: 16px !important;

  > span {
    font-size: 16px !important;
  }
}

.ant-tabs-nav .ant-tabs-tab-active {
  color: @active-color !important;
}

.ant-tabs-nav.ant-tabs-nav-animated {
  .ant-tabs-tab {
    &:hover {
      color: @active-color !important;
    }
  }
}

.ant-tabs-ink-bar.ant-tabs-ink-bar-animated {
  background-color: inherit !important;
}

// 修改ant tab 底部滚动条
.ant-tabs-bottom .ant-tabs-ink-bar-animated,
.ant-tabs-top .ant-tabs-ink-bar-animated {
  //display: none!important;

  &:after {
    content: "";
    display: inline-block;
    position: absolute;
    width: 30px;
    height: 4px;
    background: #2966ff !important;
    left: 50%;
    transform: translateX(-50%);
  }
}

// 当只有一个tab的时候特殊处理
.ant-tabs.single-tab {
  .ant-tabs-ink-bar {
    width: 100% !important;
  }
}

.ant-checkbox-wrapper + .ant-checkbox-wrapper {
  margin-left: 0 !important;
}
.ant-checkbox-inner {
  border-radius: 2px !important;
}

.ant-menu {
  .iconfont {
    transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
  }
}

.ant-menu-inline,
.ant-menu-vertical {
  border-right: none;
}

.ant-menu-inline .ant-menu-item:after,
.ant-menu-vertical .ant-menu-item:after {
  display: none;
}

.ant-menu-inline .ant-menu-item,
.ant-menu-vertical .ant-menu-item {
  left: 0px;
}

.ml16 {
  margin-left: 16px !important;
}

.mr16 {
  margin-right: 16px !important;
}

ml0 {
  margin-left: 0 !important;
}

mr0 {
  margin-right: 0 !important;
}

// 下拉框颜色
.ant-dropdown-menu-item-active.ant-dropdown-menu-item:hover {
  background-color: @xm-select-item-hover !important;
}

// ant badge改小
.ant-badge {
  transform: translate(-8px, -8px) scale(0.7) !important;
}

.ant-select-selection {
  border-color: @xm-color-border !important;
}

.ant-select-dropdown-menu-item-active:not(.ant-select-dropdown-menu-item-disabled) {
  background: #f3f6fa;

  .ant-select-selected-icon {
    color: #2966ff !important;
  }
}

.ant-select-dropdown-menu-item-selected {
  background: none;
  font-weight: 400 !important;
  color: #2966ff;
}

.ant-select-open .ant-select-selection {
  box-shadow: none;
}

.ant-tabs-bar {
  border-color: @xm-color-border !important;
}

// 日历今天不要加粗
.ant-calendar-today .ant-calendar-date {
  font-weight: normal !important;
}

.ant-modal-wrap {
  display: flex;
  align-items: center;

  .ant-modal {
    padding-bottom: 0;
    height: auto;
    top: auto;

    .ant-modal-body {
      max-height: 70vh;
      overflow-y: auto;
      padding: 24px;
    }
  }
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
  display: block;
}

::-webkit-scrollbar-thumb {
  /*滚动条里面小方块*/
  border-radius: 3px; //  background:rgba(204,204,204,1);
  background: rgba(204, 204, 204, 1);
}

.ant-avatar {
  background: #e8e8e8;
}

.ant-table-small {
  border-radius: 0 !important;
}

.ant-table-small > .ant-table-content > .ant-table-body {
  margin: 0px;
}

.ant-table-filter-dropdown .ant-dropdown-menu-without-submenu {
  max-height: 300px;
  overflow-x: hidden;
}

.ant-table-body {
  position: relative;

  .list {
    padding: 24px;
    box-sizing: content-box;
    display: flex;

    .item {
      margin-right: 24px;
    }
  }
}

.no-scrollbar {
  .ant-table-body {
    &::-webkit-scrollbar {
      display: none;
    }
  }
}

.table-no-scrollbar {
  ::-webkit-scrollbar {
    width: 0;
  }
}

.ant-table-small > .ant-table-content > .ant-table-body {
  margin: 0 0px !important;
}

.right-container,
.ant-modal {
  .ant-input {
    &:focus {
      border: 1px solid #2966ff !important;
    }
  }
}

.ant-dropdown:before {
  display: none !important;
}

.ant-calendar-picker-container {
  .ant-calendar-footer-extra {
    .ant-tag-blue {
      background: #fff;
      color: #2966ff;
      border-color: #2966ff;
    }
  }
}

.ant-table-filter-dropdown {
  .ant-dropdown-menu-item-selected {
    background: #f3f6fa;
  }
}

.ant-select-selection__rendered {
  margin: 0 12px;
}

.ant-modal-confirm-info .ant-modal-confirm-body > .anticon {
  color: #2966ff !important;
}

.ant-breadcrumb > span:last-child .ant-breadcrumb-separator {
  display: none;
}
.ant-input-affix-wrapper .ant-input:not(:last-child) {
  padding-right: 30px !important;
}

.ant-input-affix-wrapper .ant-input:not(:first-child) {
  padding-left: 24px !important;
}

.ant-input-affix-wrapper .ant-input {
  min-height: 100% !important;
  position: relative !important;
  text-align: inherit !important;
}

.ant-modal-confirm-info .ant-modal-confirm-body > .anticon {
  color: #ffbb54 !important;
}

.ant-modal-confirm-info .ant-modal-confirm-body > .default-confirm-icon {
  font-size: 22px !important;
  line-height: 22px !important;
  float: left !important;
  color: #2966ff !important;
  margin-right: 16px !important;
  &.blue {
    color: #5cbaff !important;
  }
}

// 气泡
.ant-tooltip {
  .ant-tooltip-content {
    .ant-tooltip-inner {
      padding: 6px 12px !important;
    }
  }
}

// confirm弹窗自定义图标 相关样式调整
.ant-modal-body .ant-modal-confirm-body-wrapper .ant-modal-confirm-body {
  > .solid-icon {
    color: #faad14;
    font-size: 22px;
    line-height: 22px;
    float: left;
    margin-right: 16px;
  }
  > .confirm-icon {
    color: #2966ff;
  }
  .ant-modal-confirm-content {
    margin-left: 38px;
    > .solid-icon-content {
      margin-left: 40px;
    }
  }
}

.take-name-modal {
  .ant-modal-body {
    padding: 20px 24px !important;
    .ant-form-item {
      margin-bottom: 16px !important;
    }
  }
}

.ant-select-selection__clear {
  width: 16px;
  height: 16px;
}
.ant-select-dropdown--empty .ant-select-dropdown-menu-item-disabled {
  cursor: default !important;
}
.batch-class-list {
  .ant-modal-body {
    padding: 16px 24px !important;
  }
}

.row-dragging {
  background: #fafafa;
  border: 1px solid #ccc;
}

.row-dragging td {
  padding: 16px;
  visibility: hidden;
}

.row-dragging .drag-visible {
  visibility: visible;
}

//滚动条的公共样式处理
.ant-select-dropdown .rc-virtual-list-scrollbar .rc-virtual-list-scrollbar-thumb {
  background: #d6d6d6 !important;
  width: 6px !important;
  height: 80px !important;
}
.ant-select-dropdown .rc-virtual-list-scrollbar .rc-virtual-list-scrollbar-thumb:hover {
  background: #adadad !important;
}

//table的公共的样式的处理
.ant-table.ant-table-bordered > .ant-table-container > .ant-table-content > table > thead > tr > .ant-table-cell-fix-right-first::after,
.ant-table.ant-table-bordered > .ant-table-container > .ant-table-content > table > tbody > tr > .ant-table-cell-fix-right-first::after {
  border-right: none !important;
}

// .ant-table tbody tr:nth-child(2n) td{
//   background: #FAFAFA !important;
// }

.ant-table-thead > tr > th {
  font-weight: bold !important;
  color: #333 !important;
}
td.ant-table-column-sort {
  background: none;
}
.ant-modal-content .ant-table-thead > tr > th {
  padding: 9px 24px;
}

.ant-modal-content tr > td {
  padding: 14px 24px !important;
}
//弹框里的table样式的处理

//按钮的样式的公共处理
.ant-btn-loading {
  padding-left: 18px !important;
}

.ant-input,
.ant-btn {
  border-color: @xm-color-border;
}

//普通按钮样式
.ant-btn {
  height: 28px !important;
  font-weight: normal !important;
  border: 1px solid #e8e8e8;
  box-shadow: none !important;
  padding: 0px 12px !important;
  color: #666 !important;
  .span {
    line-height: 1;
  }
  &:hover {
    border: 1px solid rgba(232, 232, 232, 1) !important;
    opacity: 0.7;
  }
  &:focus,
  &:active {
    color: #666 !important;
    border: 1px solid #c6c6c6 !important;
  }
}

//主要按钮样式
.ant-btn-primary.ant-btn {
  text-shadow: none !important;
  box-shadow: none !important;
  i {
    color: #fff !important;
  }

  span {
    color: #fff !important;
  }
  background-color: @xm-color-text-select-primary !important;
  border-color: @xm-color-text-select-primary !important;
  border: none !important;
  &:hover {
    background-color: #2966ff !important;
    opacity: 0.8 !important;
  }
  &:active{
    background-color:#5C8AFF !important;
  }
}

//警示按钮样式
.ant-btn-dangerous {
  background: rgba(255, 79, 79, 1) !important;
  color: #fff !important;
  border: none !important;
}
.ant-btn-dangerous:hover {
  background: rgba(255, 79, 79, 0.7) !important;
  color: #fff !important;
  border: none !important;
}
.ant-btn-dangerous:focus,
.ant-btn-dangerous:active {
  background: rgba(255, 79, 79, 1) !important;
  color: #fff !important;
  border: none !important;
}

//disabled的按钮的样式
.ant-btn-primary[disabled],
.ant-btn-primary[disabled]:hover,
.ant-btn-primary[disabled]:focus,
.ant-btn-primary[disabled]:active {
  background: #f7f8f9 !important;
  border: 1px solid #e8e8e8 !important;
  color: #cccccc !important;
  span {
    color: #cccccc !important;
  }
}
//时间选择器后的按钮样式
.ant-picker-ok {
  .ant-btn {
    padding: 0 8px !important;
  }
}

//搜索框后面的按钮样式
.ant-input-search-button {
  height: 32px !important;
}
.ant-input-search > .ant-input-group > .ant-input-group-addon:last-child .ant-input-search-button {
  background: #fff !important;
  border-top: 1px solid #dfdfdf !important;
  border-right: 1px solid #dfdfdf !important;
  border-bottom: 1px solid #dfdfdf !important;
}
.ant-input-search .ant-input:hover,
.ant-input-search .ant-input:focus {
  border-color: #ffcb3d;
  border: 1px solid #d9d9d9 !important;
  box-shadow: none !important;
  border-right: 0px !important;
}

.ant-input-search > .ant-input-group > .ant-input-group-addon:last-child .ant-input-search-button span {
  color: #bfbfbf !important;
  font-size: 12px;
}

.ant-modal-footer {
  .ant-btn {
    font-weight: 400 !important;
  }
}

//模态框的样式的公共处理

//删除模态框的样式的的处理
.ant-modal-confirm {
  .ant-modal-body {
    padding: 32px 32px 24px 32px !important;
    .ant-modal-confirm-title {
      color: rgba(0, 0, 0, 0.85);
    }
    .ant-modal-confirm-content {
      min-height: 44px;
      color: rgba(0, 0, 0, 0.65);
    }
  }
}

//普通模态框的样式的处理
.ant-modal {
  .ant-modal-title {
    color: #333;
    font-weight: 400;
  }
  .ant-modal-close-x {
    .modal-close-icon {
      color: #999;
      font-size: 12px;
      margin-right: 6px;
      font-weight: 400;
    }
  }
  .ant-modal-footer {
    padding: 10px 24px;
  }
}

// 排序小三角
.ant-table-column-sorter {
  margin-left: 2px !important;
}
.ant-table-column-sorter-full {
  margin-top: -0.32rem !important;
}
