.form-row {
  @include make-row;
  margin-bottom: 20px;

  &__label {
    @include make-col-ready;
    @include heading-5;
    display: block;
    margin-bottom: 10px;
  }

  &__field {
    @include make-col-ready;
  }

  &__info,
  &__error {
    @include make-col-ready;
    @include additional-text;
  }

  &__info {
    margin-bottom: 8px;
    margin-top: -8px;
  }

  &__error {
    color: $red;
    margin-top: 8px;
  }

  &_validation-error {
    .tbx,
    .ddn > select {
      @include field-error;
    }
  }

  .icon-info {
    position: absolute;
    right: -15px;
    top: 50%;
    transform: translateY(-50%);

    @include media-breakpoint-down(md) {
      right: 20px;
    }
  }
}

.form-bg {
  .form-row_btn {
    .form-row__col-btn {
      position: relative;
      width: 100%;
      min-height: 1px;
      padding-right: 15px;
      padding-left: 15px;
    }
  }
}

@include media-breakpoint-down(sm) {
  .form-row__col-btn {
    flex: 0 0 100%;
    max-width: 100%;
    padding-right: 5px;
    padding-left: 5px;
  }

  .form-row {
    padding-right: 15px;
    padding-left: 15px;
  }
}

@include media-breakpoint-up(md) {
  .form-bg {
    .form-row_btn {
      .form-row__col-btn {
        margin-left: 8.33333%;
        flex: 0 0 25%;
        max-width: 25%;
      }
    }
  }
}

@include media-breakpoint-only(md) {
  .form-bg {
    .form-row_btn {
      .form-row__col-btn {
        margin-left: 8%;
        flex: 0 0 25%;
        max-width: 25%;
      }
    }
  }
}

.form-row__action {
  position: relative;
  margin-top: 30px;
  margin-bottom: 0;
  padding-top: 30px;

  &::before {
    content: '';
    background: $gray;
    position: absolute;
    top: 0;
    left: 15px;
    right: 15px;
    height: 1px;
  }

  &.no-border {
    margin-top: 10px;
    padding-top: 10px;

    &::before {
      content: none;
    }
  }

  .form-row__col-btn {
    @include make-col-ready;

    @include media-breakpoint-only(md) {
      @include make-col(4);
    }

    @include media-breakpoint-up(lg) {
      @include make-col(6);
    }
  }
}

.tbx {
  @include inputfield;

  &_small {
    height: 34px;
  }

  &_quantity {
    padding-right: 0;
    padding-left: 0;
    width: 40px;
    text-align: center;
  }

  &_textarea {
    height: auto;
    resize: none;
  }
}

.ddn {
  @include dropdown;

  &_small {
    select {
      @include dropdown-small;
    }
  }
}

.form-wrapper, //todo: delete .form-bg after forms refactoring
.form-bg {
  background: $gray-bg;
  padding: 40px 15px;
}

.rbn {
  @include radiobutton;
}

.chb {
  @include checkbox;

  &-new {
    @include checkbox-new;
  }
}
