// Form control focus state
//
// Generate a customized focus state and for any input with the specified color,
// which defaults to the `$input-focus-border-color` variable.
//
// We highly encourage you to not customize the default value, but instead use
// this to tweak colors on an as-needed basis. This aesthetic change is based on
// WebKit's default styles, but applicable to a wider range of browsers. Its
// usability and accessibility should be taken into account with any change.
//
// Example usage: change the default blue border and shadow to white for better
// contrast against a dark gray background.

@mixin input-variant($color) {
  $border: $color;
  $color-hover: $color;
  $hover-background: $color;
  $hover-border: $color;
  $active-border: mix($black, $border, 12.5%);
  $focus-box-shadow: 0 0 0 2px lighten($color, 25%) !default;

  background-color: transparent;
  background-image: none;
  border-color: $border;

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

  &:focus,
  &:active {
    box-shadow: $focus-box-shadow;
    border-color: $active-border;
  }
}
