input[type='email'],
input[type='number'],
input[type='password'],
input[type='search'],
input[type='tel'],
input[type='text'],
input[type='url'],
input[type='file'],
textarea,
select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font-family: 'Yantramanav', sans-serif;

  &:focus {
    box-shadow: none;
    outline: none;
  }

}

.fields {
  margin-bottom: $spacing-lg;
}
.fields.are-inline {
  display: flex;
  align-items: flex-end;
  margin-bottom: 0;

  .field {
    float: none;
  }

  .field__input {
    margin-bottom: 0;
  }

  @include media($small) {
    flex-wrap: wrap;
  }

}
.fields.are-gapped {
  margin-left: -$spacing-md;
  margin-right: -$spacing-md;

  .field {
    padding: 0 $spacing-md;
  }

}
.fields.are-gridded {
  .field__label {
    float: none;
  }
  .field__input {
    margin-top: 0;
    margin-bottom: $spacing-lg;
  }
  .field__help {
    float: none;
  }
}


.field {
  margin-bottom: $spacing-md;
  float: left;
  width: 100%;
  position: relative;
  @include clearfix;
}
.field__label {
  font-weight: 600;
}
.field__input {
  border: .1rem solid $ghost-black;
  height: 4rem;
  width: 100%;
  padding: 0 $spacing-md;
  margin: $spacing-sm 0;
  clear: both;
}
.field__select {
  @extend .field__input;
  padding: 0;
  position: relative;

  &:after {
    position: absolute;
    right: $spacing-md;
    top: 50%;
    transform: translateY(-50%);
    @include fa-icon('\f0d7');
  }

  select {
    padding: 0 $spacing-md;
    width: 100%;
    height: 100%;
  }

}

.field__multi {
  @extend .field__input;
  height: 10rem;
  padding: 0;

  select {
    width: 100%;
    height: 100%;
  }
  option {
    padding: $spacing-sm $spacing-md;
    ::selection {
      background: red !important;
    }
  }

}

.field__file {
  @extend .field__input;
  border: 0;
  padding: 0;
  height: auto;
}

.field__textarea {
  @extend .field__input;
  padding: $spacing-md;
  height: 10rem;
  resize: vertical;
}

.field__radio,
.field__checkbox {

  position: relative;
  display: block;
  margin-bottom: $spacing-sm;
  float: left;
  padding-left: 2rem + $spacing-md;

  input {
    display: block;
    position: absolute;
    left: 0;
    top: 12.5%;
    vertical-align: bottom;
    width: 2rem;
    height: 2rem;
    margin-right:$spacing-md;
  }

}
.field__radio.is-custom,
.field__checkbox.is-custom {

  input {
    -webkit-appearance: none;
    position: absolute;
    top: 0;
    left: 0;
    outline: 0;

    &:hover {
      cursor: pointer;
    }

    &:focus {
      color: $blue;
    }

    &:after {
      @include fa-icon('\f10c');
      display: block;
      font-size: 2rem;
      padding-left: 1px; // Fix font-awesome alignment
    }

    &:checked:after {
      content: '\f192'
    }

  }
}
.field__checkbox.is-custom input {
  text-align: left;
  &:after {
    content: '\f096'
  }
  &:checked:after {
    content: '\f046'
  }
}
.field__help {
  @extend .text.is-shy;
  @extend .text.is-tiny;
  float: right;
  clear: right;
}
.field__alert {
  @extend .text.is-tiny;
  position: absolute;
  color: $red;
  font-weight: bold;
  right: 0;
}
.field__alert.is-animated {

  @keyframes appear {
    0% {
      transform: translateX(-12.5%);
      opacity: 0;
    }
    100% {
      transform: translateX(0);
      opacity: 1;
    }
  }
  animation: appear .25s ease-in-out;
}
.field.is-disabled,
.field__radio.is-disabled {
  opacity: .5;
}
.field__input.is-error,
.field__textarea.is-error {
  border-color: $red;
}
.field__input.is-success,
.field__textarea.is-success {
  border-color: $green;
}