:global {
  .contact_form {
    > div {
      margin: 3.2rem auto;

      @include min(tablet) {
        margin: 4rem auto;
      }
    }
  }
}

.formComponent {
  padding: 2.4rem;
  width: 100%;
  box-shadow: 0px 4px 6px -2px rgba(27, 27, 28, 0.02), 0px 12px 16px -4px rgba(27, 27, 28, 0.05);
  border-radius: 16px;
  background: #f4f4f4;
  gap: 2.4rem;
  @include flex-direction(column);
  
  @include min(tablet) {
    padding: 2.4rem;
  }

  h2 {
    font-size: 2.4rem;
    line-height: 3.2rem;
    font-weight: 700;
    text-transform: capitalize; 
    margin: 0;
    color: #1b1b1c;

    @include min(tablet) {
      font-size: 3.2rem;
      line-height: 4rem;
    } 
  }

  form {
    width: 100%;
  }

  input,
  textarea,
  select {
    background: var(--color-4);
    font-size: 1.4rem;
    line-height: 2.1rem;
    padding: 1.6rem;
    width: 100%;
    max-width: 100%;
    outline: none;
    border-radius: 0.8rem;
    border: 1.5px solid #F4F4F4;


    &:invalid,
    &.invalid {
      border: 1px solid var(--color-39);
      color: var(--color-39);
    }
  }

  input {
    height: 4.4rem;
  }

  input[type="file"] {
    height: auto;
  }

  input[type="color"],
  input[type="range"] {
    padding: 0;
  }

  input[type="checkbox"],
  input[type="radio"] {
    width: auto;
    height: auto;
  }

  textarea {
    height: 12rem;
    display: block;
    resize: vertical;
    resize: none;
    height: 20.8rem;
    padding: 1.2rem;
  }

  label {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 2.7rem;
    color: #262629;

    span {
      color: red;
    }

    &:invalid,
    &.invalid {
      color: var(--color-39);
    }
  }


  button{
    text-align: start;
  }

}

.formGroup {
  width: 100%;
  @include flex-direction(column);
  gap: 0.4rem;
}

.radioGroup,
.checkboxGroup,
.textareaGroup {
  @include flex-direction(column);

  > div {
    @include flex-align(center, flex-start);
    gap: 0.8rem;
    font-weight: normal;
  }

  label {
    font-weight: 400;
    color: #3c3c40;

    > a {
      color: #165af8;
      text-decoration: underline;
      font-weight: 500;
    }
  }
}

.textareaGroup {
  @include flex-align(flex-end, flex-start);

  > span {
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 2.2rem;
  }
}

.rangeValues {
  @include flex-align(center, space-between);
   
  .invalid {
    color: var(--color-39);
  }
}


.formAlerts {
  display: inline-block;
  grid-column: span 2 / span 2;
  order: -1;

  @include min(tablet) {
    width: calc(100% - 18rem);
    order: unset;
  }

  @include min(desktop) {
    display: inline-block;
  }

  div {
    border-radius: 0.4rem;
    border-width: 1px;
    border-style: solid;
    font-size: 1.4rem;
    font-weight: 400;
    width: 100%;
    height: 4.4rem;
    padding: 1rem 1.6rem;
  }
}


.alertSuccess {
  border-color: var(--color-44);
  color: var(--color-44) ;
}

.alertDanger {
  border-color: var(--color-11);
  color: var(--color-11);
}

.alertWarning {
  border-color: var(--color-39);
  color: var(--color-39);
}

.alertWarningMessage {
  @include flex-align(center, flex-start);
  gap: 0.5rem;
  background: var(--color-39);
  border-radius: 0.4rem;
  color: var(--color-4);
  margin-top: 0.8rem;
  padding: 8px;
}

.twoCol {
  @include flex-direction(column);
  gap: 2.4rem;

  @include min(tablet) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 4.8rem;
    row-gap: 1.6rem;
  }

  button {
    width: 100%;
  }
}

.singleCol {
  @include flex-direction(column);
  gap: 2.4rem;
}

.fullWidth {
  grid-column: span 2 / span 2;
}

.formButton {
  grid-column: span 2 / span 2;
  button {
    width: auto;
  }
}

.recaptcha {
  overflow: hidden;

  &.invalid {
    border: 1px solid var(--color-39);
    color: var(--color-39);
  }
  
  // override overflowing styles
  > div > div > div {
    width: 100% !important;

    iframe {
      width: 100%;
    }

    @include min(tablet) {
      width: 304px !important;

      iframe {
        width: 304px;
      }
    }
  }
}