@import '../../Input/style/index.scss';
@import '../../Form/style/common.scss';

.checkbox-select-wrap {
  cursor: pointer;
  display: inline-block;
  .disabled {
    .checkbox-select-result {
      @include disabledStyle;
    }
  }
}

.checkbox-select-result {
  @extend .input;
  // min-width: 230px;
  background-color: #fff;
  display: flex;
  padding-right: 0;

  .close-icon {
    fill: #a53c3c;
    margin-top: 8px;
    cursor: pointer;
    width: 10px;
    height: 10px;
  }
  .arrow-zone {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    width: 32px;
    justify-content: center;
  }
  .drop-down-icon {
    fill: none;
    stroke: #979797;
    width: 10px;
  }
}
.mini {
  &.checkbox-select-result {
    font-size: 12px;
    height: 26px;
    line-height: 24px;
  }
}
.open {
  & > .checkbox-select-result {
    border-color: #3a7eea;
    box-shadow: 0 0 0 2px #cadfff;
    .drop-down-icon {
      stroke: $primaryBlueColor;
    }
  }
}
.can-delete {
  .checkbox-select-result::after {
    right: 10px;
  }
}
.checkbox-select-result-label {
  margin-right: 10px;
  color: #3d3e52;
  white-space: nowrap;
}
.checkbox-select-result-value {
  max-width: 140px;
  margin: 0;
  padding: 0;
  color: $primaryBlueColor;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.checkbox-select-content {
  min-width: 200px;
  padding: 10px;

  &.sortable {
    .checked + .checkbox-label:not(.checked) {
      border-top: 1px solid $borderColor;
      padding-top: 5px;
    }
  }
}

.checkbox-select-content-title {
  font-size: 16px;
  font-weight: bold;
  color: $primaryBlueColor;
  margin-bottom: 14px;
  margin-top: -6px;
}
.checkbox-select-search-input {
  margin-bottom: 5px;
}
.checkbox-select-content-checkbox {
  max-height: 210px;
  overflow-y: auto;
  .checkbox-label {
    display: flex;
    & + .checkbox-label {
      margin-top: 5px;
    }
  }
}
.checkbox-select-button-wrap {
  text-align: right;
  margin-top: 10px;

  .cancel {
    margin-right: 10px;
    margin-left: auto;
  }
  .confirm {
  }
}
.link {
  border-radius: 2px;
  .close-icon {
    margin-left: 5px;
    fill: #a4a4ae;
    width: 14px;
    height: 14px;
    &:hover {
      fill: #6d6d75;
    }
  }
  .dropdown {
    flex: 1;
  }
  .checkbox-select-result {
    background-color: transparent;
    border: none;
    height: 26px;
    line-height: 26px;
    border-radius: 2px;
    padding-right: 0px;
    padding-left: 5px;
    &:after {
      display: none;
    }
  }
  .arrow-icon {
    width: 10px;
    margin-top: 6px;
    flex-shrink: 0;
    margin-left: 5px;
    margin-right: 5px;
  }
  .checkbox-select-result-value {
    color: #3a7eea;
    flex: unset;
  }
  .dropdown {
    &:hover {
      background: #f1f1f7;
    }
  }
}
