/**
Include icons in scss/css.
Usage: 
 @include icon(close);
*/
/*
Media query mixin.
Usage: 
@include media($bp-l, min)
*/
/*
Mixin to add loading spinner to button/element.
Usage: 
@include loading()
*/
input.form-element,
select.form-element,
textarea.form-element,
.cf-field input,
custom-select.form-element select ~ div {
  font-size: 0.875rem;
  line-height: 140%;
  font-weight: 500;
  font-family: inherit;
  border: 1px solid #a6a6a6;
  padding: 1rem 1.5rem;
  background-color: transparent;
  width: 100%;
  outline: transparent;
  appearance: none;
  border-radius: 2.0625rem;
  box-sizing: border-box;
  text-overflow: ellipsis;
  color: #1a1a1a;
}
input.form-element::placeholder,
select.form-element::placeholder,
textarea.form-element::placeholder,
.cf-field input::placeholder,
custom-select.form-element select ~ div::placeholder {
  color: #595959;
}
input.form-element[aria-invalid=true], input.form-element--error,
select.form-element[aria-invalid=true],
select.form-element--error,
textarea.form-element[aria-invalid=true],
textarea.form-element--error,
.cf-field input[aria-invalid=true],
.cf-field input--error,
custom-select.form-element select ~ div[aria-invalid=true],
custom-select.form-element select ~ div--error {
  border-color: #b50808;
}
input.form-element:focus,
select.form-element:focus,
textarea.form-element:focus,
.cf-field input:focus,
custom-select.form-element select ~ div:focus {
  border-color: currentcolor;
}
input.form-element:-webkit-autofill, input.form-element:-webkit-autofill:hover, input.form-element:-webkit-autofill:focus, input.form-element:-webkit-autofill:active, input.form-element:-internal-autofill-selected,
select.form-element:-webkit-autofill,
select.form-element:-webkit-autofill:hover,
select.form-element:-webkit-autofill:focus,
select.form-element:-webkit-autofill:active,
select.form-element:-internal-autofill-selected,
textarea.form-element:-webkit-autofill,
textarea.form-element:-webkit-autofill:hover,
textarea.form-element:-webkit-autofill:focus,
textarea.form-element:-webkit-autofill:active,
textarea.form-element:-internal-autofill-selected,
.cf-field input:-webkit-autofill,
.cf-field input:-webkit-autofill:hover,
.cf-field input:-webkit-autofill:focus,
.cf-field input:-webkit-autofill:active,
.cf-field input:-internal-autofill-selected,
custom-select.form-element select ~ div:-webkit-autofill,
custom-select.form-element select ~ div:-webkit-autofill:hover,
custom-select.form-element select ~ div:-webkit-autofill:focus,
custom-select.form-element select ~ div:-webkit-autofill:active,
custom-select.form-element select ~ div:-internal-autofill-selected {
  font-size: 0.875rem;
  line-height: 140%;
  font-weight: 500;
  box-shadow: 0 0 0 1000px #fff inset !important;
  border-color: currentcolor;
}

select.form-element {
  background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 5L8 11L14 5' stroke='%23000000' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
  background-position: center right 1.5rem;
  background-size: 1rem;
  background-repeat: no-repeat;
  padding-right: 3rem;
}

custom-select.form-element {
  display: block;
  position: relative;
}
custom-select.form-element select + div {
  padding-right: 3rem;
  position: relative;
}
custom-select.form-element select + div::after {
  background-image: url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 5L8 11L14 5' stroke='%23000000' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
  content: "";
  position: absolute;
  right: 1.5rem;
  top: 0;
  bottom: 0;
  width: 1rem;
  background-position: center;
  background-size: 1rem;
  background-repeat: no-repeat;
  transition: transform 0.15s;
}
custom-select.form-element ul {
  min-width: 15rem;
  position: absolute;
  left: 0;
  width: 100%;
  z-index: 5;
  background-color: #949494;
  transform: scaleY(0.7);
  transition: all 0.15s;
  opacity: 0;
  visibility: hidden;
  transform-origin: top;
  max-height: 26rem;
  overflow-y: auto;
  border-radius: 0.5rem;
  margin-top: 1px;
}
custom-select.form-element ul li {
  font-size: 1rem;
  line-height: 140%;
  font-weight: 500;
  text-transform: none;
  letter-spacing: normal;
  padding: 0.5rem 1.5rem;
  background-color: transparent;
  transition: all 0.15s;
  cursor: pointer;
}
custom-select.form-element ul li[disabled] {
  opacity: 0.3;
  pointer-events: none;
  text-decoration: none;
}
custom-select.form-element ul li.blurred {
  opacity: 0.3;
  text-decoration: none;
}
custom-select.form-element ul li.hidden {
  display: none;
}
custom-select.form-element ul li:hover, custom-select.form-element ul li:focus-visible {
  background-color: black;
  color: white;
}
custom-select.form-element[open] ul {
  transform: scaleY(1);
  visibility: visible;
  opacity: 1;
}
custom-select.form-element[open] select + div::after {
  transform: scaleY(-1);
}

label.form-element,
.cf-field label {
  font-size: 0.875rem;
  line-height: 140%;
  font-weight: 500;
  display: block;
  margin-bottom: 0.5rem;
}
label.form-element--error,
.cf-field label--error {
  color: #b50808;
}

small.form-element {
  font-size: 0.75rem;
  line-height: 160%;
  font-weight: 500;
  display: block;
  margin-top: 0.5rem;
}
small.form-element--error {
  color: #b50808;
}

.form-element--bool {
  width: 100%;
}
.form-element--bool label,
.form-element--bool input + span {
  font-size: 0.875rem;
  line-height: 140%;
  font-weight: 500;
  display: flex;
  align-items: flex-start;
}
.form-element--bool label::before,
.form-element--bool input + span::before {
  content: "";
  display: inline-block;
  width: 1rem;
  height: 1rem;
  border: 1px solid #bebebe;
  margin: 0.0625rem 0.5rem 0 0;
  background-position: center;
  background-size: contain;
  background-repeat: no-repeat;
  box-sizing: border-box;
}
.form-element--bool label small,
.form-element--bool input + span small {
  font-size: 0.75rem;
  line-height: 160%;
  font-weight: 500;
  vertical-align: baseline;
  color: #6b6b6b;
  margin-left: 0.25rem;
}
.form-element--bool input {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.form-element--bool input[type=checkbox] + label::before, .form-element--bool input[type=checkbox] + span::before {
  border-radius: 0.125rem;
}
.form-element--bool input[type=checkbox]:checked + label::before, .form-element--bool input[type=checkbox]:checked + span::before {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='10' viewBox='0 0 12 10' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M3.86663 7.60001L1.06663 4.80001L0.133301 5.73334L3.86663 9.46667L11.8666 1.46667L10.9333 0.53334L3.86663 7.60001Z' fill='%23FFFFFF'/%3E%3C/svg%3E%0A");
  background-size: 80%;
  background-position: center;
  background-repeat: no-repeat;
}
.form-element--bool input[type=radio] + label::before, .form-element--bool input[type=radio] + span::before {
  border-radius: 100%;
}
.form-element--bool input[type=radio]:checked + label::before, .form-element--bool input[type=radio]:checked + span::before {
  background-image: url("data:image/svg+xml,%3Csvg width='6' height='6' viewBox='0 0 6 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='3' cy='3' r='3' fill='%23EFEFEF'/%3E%3C/svg%3E%0A");
  background-size: 45%;
  background-position: center;
  background-repeat: no-repeat;
}
.form-element--bool input:checked + label::before, .form-element--bool input:checked + span::before {
  background-color: #054040;
  border-color: #054040;
}
.form-element--bool input[disabled] + label::before, .form-element--bool input[disabled] + span::before {
  border-color: #bebebe;
  background-color: #dcdcdc;
}
.form-element--bool + .form-element--bool {
  margin-top: 0.75rem;
}
