.richtext div {
  text-wrap: wrap; !important
}

.richtext a {
  color: black;
  text-decoration: underline;
}

.custom-form-wrapper a {
  color: black;
  text-decoration: underline;
}

.hs_recaptcha.hs-recaptcha.field.hs-form-field {
  display: none;
}

.legal-consent-container {
  margin-bottom: 5%;
}

form.hs-form fieldset {
  max-width: 100% !important;
  
}

form.hs-form fieldset.form-columns-2,
form.hs-form fieldset.form-columns-3 {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

form.hs-form fieldset.form-columns-2 .hs-form-field,
form.hs-form fieldset.form-columns-3 .hs-form-field {
  flex: 1 1 calc(50% - 10px); 
}

form.hs-form fieldset.form-columns-3 .hs-form-field {
  flex: 1 1 calc(33.33% - 10px);
}


form.hs-form fieldset.form-columns-1 .hs-input:not([type="checkbox"]):not([type="radio"]) {
  width: 100% !important;
}

.custom-form-wrapper {
  max-width: 100%;
  margin-top: 5%;
  margin-bottom: 5%;
  font-family: "Liberation Sans", sans-serif;
  color: gray;
  width: 100% !important;
}

.custom-form-wrapper .hs-form-field {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 1.5rem;
}

.custom-form-wrapper .hs-form-field.hs-fieldtype-booleancheckbox {
  margin-bottom: 0.75rem;
}

.custom-form-wrapper label {
  min-width: 150px;
  text-align: left;
  white-space: nowrap;
  display: block;
  margin-bottom: 0.35rem;
}

.custom-form-wrapper label .hs-form-required {
  color: red;
}

.custom-form-wrapper .input {
  width: 100%;
  box-sizing: border-box;
}

.custom-form-wrapper .input input,
.custom-form-wrapper .input select,
.custom-form-wrapper .input textarea {
  width: 100%;
  height: 50px;
  padding: 5px;
  border: 1px solid #ccc;
  border-radius: 8px;
  transition: border-color 0.3s;
  box-sizing: border-box;
}

/* fix of radio and checkbox sizes by sey*/
.custom-form-wrapper .input .hs-form-radio input, 
.custom-form-wrapper .input .inputs-list input {
  width: auto;
}

/* reducing the space between first radio button and label */
.custom-form-wrapper .hs-form-field.hs-fieldtype-radio label {
  margin-bottom: 0rem;
}

.custom-form-wrapper .input textarea {
  height: 120px;
  padding: 10px 15px; 
}

.custom-form-wrapper .input input:focus,
.custom-form-wrapper .input textarea:focus,
.custom-form-wrapper .input select:focus {
  border-color: rgb(236, 102, 7);
  outline: none;
}

/* Checkbox and radio buttons */
.custom-form-wrapper .inputs-list {
  padding: 0;
  margin: 0;
  list-style: none;
}

.custom-form-wrapper .inputs-list * {
  margin: 0;
  padding: 0;
}

.custom-form-wrapper .inputs-list > li {
  display: block;
  margin: 0;
}

.custom-form-wrapper .inputs-list input,
.custom-form-wrapper .inputs-list span {
  vertical-align: middle;
}

.custom-form-wrapper input[type='checkbox'],
.custom-form-wrapper input[type='radio'] {
  margin-right: 0.35rem;
  cursor: pointer;
}

/* selections */
.custom-form-wrapper select.hs-input {
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg width='24' height='25' viewBox='0 0 24 25' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10.9407 19.5595C11.5267 20.1454 12.4782 20.1454 13.0642 19.5595L22.0642 10.5595C22.6501 9.97354 22.6501 9.02197 22.0642 8.43604C21.4782 7.8501 20.5267 7.8501 19.9407 8.43604L12.0001 16.3767L4.05947 8.44072C3.47354 7.85478 2.52197 7.85478 1.93604 8.44072C1.3501 9.02666 1.3501 9.97822 1.93604 10.5642L10.936 19.5642L10.9407 19.5595Z' fill='%2309152B'/%3E%3C/svg%3E%0A");
  background-position: right 16px center;
  background-repeat: no-repeat;
  background-size: 16px;
}

/* submit button */
.custom-form-wrapper input[type="submit"] {
  background-color: rgb(236, 102, 7);
  display: block;
  margin: 0 auto;
  width: 100%;
  color: black;
  border: none;
  cursor: pointer;
  padding: 20px;
  border-radius: 100px;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.custom-form-wrapper input[type="submit"]:hover {
  background-color: #d95c00;
  border-radius: 10px;
}

/* error messages */
.custom-form-wrapper .hs-form-required {
  color: #ef6b51;
}

.custom-form-wrapper .hs-input.error {
  border-color: #ef6b51;
}

.custom-form-wrapper .hs-error-msg,
.custom-form-wrapper .hs-error-msgs {
  margin-top: 0.35rem;
  color: #ef6b51;
}

/* Responsive */
@media (max-width: 800px) {
  .custom-form-wrapper .hs-form-field {
    flex-direction: column;
    align-items: flex-start;
  }

  .custom-form-wrapper label {
    text-align: left;
    min-width: auto;
    width: 100%;
  }

  .custom-form-wrapper input[type="submit"] {
    width: 100%;
    margin-top: 5%;
  }

  .custom-form-wrapper {
    width: 80%;
    padding-left: 0em;
    margin-top: 5%;
    margin-bottom: 5%;
  }
}
