// Increased to account for chip height
$control-height: control-height() + .6rem;
$control-vertical-padding: (($control-height - control-height()) / 2);
$backdrop-horizontal-spacing: spacing(tighter) * 1.5;

// Lable Styling

.labelWrapper {
  transform: translate3D(0, 2rem, 0);
  margin-top: -.6rem !important;
 
  &.focused,
  &:not(.empty) {
    transform: translate3D(0,0.3rem,0);
    margin-top: auto !important;

    .labelStyle {
      @include text-style-body-small;
      color: theme-color(m-grey, 700);
    }  
  }
}

// Picker Styling

.textField {
  @include text-style-input;
  height: auto;
  min-height: $control-height;
  padding: $control-vertical-padding $backdrop-horizontal-spacing;
  transition: 0.3s all ease;

  &.focused {
    padding-top: calc((#{$control-vertical-padding} * 2) - 0.5rem + 1rem);
    padding-bottom: 0.5rem;

    > .backdrop {
      border-color: theme-color(m-blue, 300);
      box-shadow: 0 0 0 1px theme-color(m-blue, 300);
    }
  }

  &.hasValue {
    padding-top: calc((#{$control-vertical-padding} * 2) - 0.5rem + 1rem);
    padding-bottom: 0.5rem;
  }

  &.labelHidden {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }
}

.containerWrapper {

  &.empty {
    .input {
      &::placeholder {
        text-align: right;
      }
    }
  }
}

.input {
  @include text-style-input;
  min-height: control-height();
  padding-top: (control-vertical-padding() * 2) - 0.8rem; // total padding - padding-bottom
  padding-bottom: 0.8rem;

  &:disabled {
    color: theme-color(m-grey, 700);
  }

  &::placeholder {
    color: theme-color(m-grey, 500);
  }
}


.error {
  .backdrop {
    background-color: #fff;
    border-color: #E53935;
    // box-shadow:
    // inset shadow(transparent),
    // 0 0 0 1px theme-color(m-red, 600);
    &.focused {
      > .backdrop {
        border-color: #E53935;
        box-shadow: 0 0 0 1px #E53935;
      }
    }
  }
}