@import "../../style/themes/default";
@import "../../style/mixins/index";

// == when focus or actived
.active(@color: @outline-color) {
  border-color: ~`colorPalette("@{color}", 5)`;
  outline: 0;
}

// == when hoverd
.hover(@color: @input-hover-border-color) {
  border-color: ~`colorPalette("@{color}", 5)`;
  border-right-width: 1px !important;
}

.disabled() {
  background-color: @input-disabled-bg;
  opacity: 1;
  cursor: not-allowed;
  color: @disabled-color;
  &:hover {
    .hover(@input-border-color);
  }
}

.selection__clear() {
  display: inline-block;
  font-style: normal;
  vertical-align: baseline;
  text-align: center;
  text-transform: none;
  text-rendering: auto;
  opacity: 0;
  position: absolute;
  right: @control-padding-horizontal - 1px;
  z-index: 1;
  background: @component-background;
  top: 50%;
  font-size: @font-size-sm;
  color: @disabled-color;
  width: 12px;
  height: 12px;
  margin-top: -6px;
  line-height: 12px;
  cursor: pointer;
  transition: color 0.3s ease, opacity 0.15s ease;
  &:before {
    display: block;
    .iconfont-font("\e62e");
  }
  &:hover {
    color: @text-color-secondary;
  }
}
