/*
 * Return the rem of a pixel's value
 *
 * Sample: pxToRem(50)
 * Result: 3.125rem
 */
/*
 * Return the percent ratio from width and height
 *
 * Sample: ratio(16, 9)
 * Result: 56.25%
 */
/*
 * Return the rem of a pixel's value
 *
 * Sample: pxToRem(50)
 * Result: 3.125rem
 */
/*
 * Return the percent ratio from width and height
 *
 * Sample: ratio(16, 9)
 * Result: 56.25%
 */
.text-field {
  display: inline-flex;
  flex-direction: column;
  position: relative; }
  .text-field .input {
    display: inline-flex;
    align-items: center;
    height: 3.0625rem;
    padding: 0.5rem 1.25rem;
    box-sizing: border-box;
    border: 0.0625rem solid #cecece;
    background-color: white;
    border-radius: 0.3125rem; }
    .text-field .input .icon {
      margin-right: 0.5rem; }
      .text-field .input .icon svg {
        width: 1.25rem;
        height: 1.25rem; }
      .text-field .input .icon.text-field__validation-tick {
        position: absolute;
        top: 0.9375rem;
        right: 0.8125rem;
        z-index: 1; }
        .text-field .input .icon.text-field__validation-tick svg {
          width: 0.8125rem;
          height: 0.5625rem; }
    .text-field .input:focus-within {
      box-shadow: 0 0 0.0625rem 0.0625rem #757575 inset; }
    .text-field .input textarea,
    .text-field .input input {
      border: 0;
      font-size: 0.9375rem;
      width: 100%;
      box-sizing: border-box;
      background-color: transparent;
      outline: none; }
    .text-field .input textarea {
      height: 90%;
      align-self: flex-end;
      overflow: auto;
      resize: none; }
  .text-field.has-error .input {
    border: 0.0625rem solid #d70000; }
  .text-field--black-bordered .input {
    border-color: #000000; }
  .text-field.placeholder-with-label .input {
    padding: 1rem 1.25rem 0; }
    .text-field.placeholder-with-label .input textarea::-webkit-input-placeholder, .text-field.placeholder-with-label .input input::-webkit-input-placeholder {
      opacity: 0; }
    .text-field.placeholder-with-label .input textarea::-moz-placeholder, .text-field.placeholder-with-label .input input::-moz-placeholder {
      opacity: 0; }
    .text-field.placeholder-with-label .input textarea:-ms-input-placeholder, .text-field.placeholder-with-label .input input:-ms-input-placeholder {
      opacity: 0; }
    .text-field.placeholder-with-label .input textarea::-ms-input-placeholder, .text-field.placeholder-with-label .input input::-ms-input-placeholder {
      opacity: 0; }
    .text-field.placeholder-with-label .input textarea::placeholder,
    .text-field.placeholder-with-label .input input::placeholder {
      opacity: 0; }
    .text-field.placeholder-with-label .input textarea::-webkit-input-placeholder, .text-field.placeholder-with-label .input input.focus-visible::-webkit-input-placeholder {
      opacity: 1;
      background-color: white;
      font-size: 0.8125rem; }
    .text-field.placeholder-with-label .input textarea::-moz-placeholder, .text-field.placeholder-with-label .input input.focus-visible::-moz-placeholder {
      opacity: 1;
      background-color: white;
      font-size: 0.8125rem; }
    .text-field.placeholder-with-label .input textarea:-ms-input-placeholder, .text-field.placeholder-with-label .input input.focus-visible:-ms-input-placeholder {
      opacity: 1;
      background-color: white;
      font-size: 0.8125rem; }
    .text-field.placeholder-with-label .input textarea::-ms-input-placeholder, .text-field.placeholder-with-label .input input.focus-visible::-ms-input-placeholder {
      opacity: 1;
      background-color: white;
      font-size: 0.8125rem; }
    .text-field.placeholder-with-label .input textarea::placeholder,
    .text-field.placeholder-with-label .input input.focus-visible::placeholder {
      opacity: 1;
      background-color: white;
      font-size: 0.8125rem; }
  .text-field .error-text {
    margin-top: 0.1875rem;
    text-align: right;
    font-size: 0.8125rem;
    line-height: 0.8125rem;
    min-height: 0.8125rem;
    color: #d70000; }
  .text-field.floating-label label {
    position: absolute;
    left: 1.25rem;
    top: 1.125rem;
    transition: font-size 200ms cubic-bezier(0, 0, 0.2, 1) 0ms, top 200ms cubic-bezier(0, 0, 0.2, 1) 0ms;
    color: #757575;
    font-size: 0.8125rem;
    max-width: calc( 100% - 2.5rem);
    text-overflow: ellipsis;
    height: 0.9375rem;
    overflow: hidden;
    white-space: nowrap; }
  .text-field.floating-label input {
    margin-left: -0.3125rem; }
  .text-field.floating-label .input:focus-within {
    box-shadow: 0 0 0.0625rem 0.0625rem #757575 inset;
    padding: 1rem 1.25rem 0; }
    .text-field.floating-label .input:focus-within ~ label {
      font-size: 0.6875rem;
      top: 0.625rem; }
  .text-field.floating-label.has-value label, .text-field.floating-label.date-field label {
    font-size: 0.6875rem;
    top: 0.625rem; }
  .text-field.floating-label.has-value .input, .text-field.floating-label.date-field .input {
    padding: 1rem 1.25rem 0; }
  @supports (-ms-ime-align: auto) {
    .text-field.floating-label {
      /* EDGE CSS styles go here */ }
      .text-field.floating-label.placeholder-with-label input::-ms-input-placeholder {
        opacity: 1; }
      .text-field.floating-label.placeholder-with-label input.focus-visible::-ms-input-placeholder {
        opacity: 0; }
      .text-field.floating-label label {
        top: 0.625rem;
        font-size: 0.6875rem; } }
  @media all and (-ms-high-contrast: none), (-ms-high-contrast: active) {
    .text-field.floating-label {
      /* IE10+ CSS styles go here */ }
      .text-field.floating-label.placeholder-with-label input::-ms-input-placeholder {
        opacity: 1; }
      .text-field.floating-label.placeholder-with-label input.focus-visible::-ms-input-placeholder {
        opacity: 0; }
      .text-field.floating-label label {
        top: 0.625rem;
        font-size: 0.6875rem; } }
  .text-field.floating-label.has-error label {
    color: #d70000; }
  .text-field.disabled {
    color: #757575; }
    .text-field.disabled .input {
      background-color: #f6f6f6; }
      .text-field.disabled .input input {
        background-color: #f6f6f6;
        color: #757575; }

