@mixin get-involved-content-page {
  height: 100%;
  display: flex;
  flex-direction: column;
}

@mixin dropzone-overlay {
  @extend %body-text;
  font-weight: bold;
  display: none;
  position: absolute;
  background-color: transparentize($black, 0.4);
  height: 100%;
  width: 100%;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  padding: 4rem;
  color: $white;
  pointer-events: none;
  left: 0;
  top: 0;
}

.get-involved {
  width: 100%;

  & > .columns {
    margin: 0;
    width: 100%;
    height: 100%;
  }

  .left-image-container {
    background-image: url('../images/left-image.png');
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
  }

  .get-involved-container {
    padding-top: 5rem;
    padding-right: 2.444rem;
    padding-bottom: 2.222rem;
    padding-left: 0;
    @include until($desktop) {
      padding: 0;
      padding-bottom: 2.222rem;
    }
  }

  .image-uploader {
    @include get-involved-content-page;

    form {
      margin-top: 3.166rem;
      overflow: hidden;
      @include until($desktop) {
        width: 100%;
        max-width: 650px;
        margin-left: auto;
        margin-right: auto;
      }
      @include until($tablet) {
        margin-top: 1.666rem;
      }
    }

    .email-container {
      display: flex;
      flex-direction: column;

      &:hover {
        input[type="email"] {
          border-bottom-color: $white;
        }

        label {
          color: $white;
        }
      }
    }

    .left-column {
      @include until($tablet) {
        margin-bottom: 1.666rem;
        padding-bottom: 0;
      }

      @include from($tablet) {
        padding-right: 1rem;
      }

      .user-data-form {
        @include until($tablet) {
          width: 16rem;
          margin-left: auto;
          margin-right: auto;
        }

        > div:not(:last-child) {
          margin-bottom: 1.666rem;

          &:not(:first-child) {
            @include until($tablet) {
              margin-bottom: 0.888rem;
            }
          }
        }
      }

      .g-recaptcha {
        @include until($tablet) {
          transform: scale(0.955);
          -webkit-transform: scale(0.955);
          transform-origin: 0 0;
          -webkit-transform-origin: 0 0;
        }
      }
    }

    .right-column {
      @include until($tablet) {
        padding-top: 0;
      }

      @include from($tablet) {
        padding-left: 0;
      }
    }

    .email-input {
      position: relative;
      max-width: 16.8rem;

      @include until($tablet) {
        max-width: 16rem;
      }

      > i {
        position: absolute;
        right: 0;
        top: 0;
        display: none;
      }

      &.success > i.success {
        color: $green;
        display: block;
      }

      &.error {
        > input {
          border-color: $red;
        }

        > i.error {
          color: $red;
          display: block;
        }
      }

      .validation-message {
        color: $red;
        position: absolute;
        font-size: $font-size-small;
      }
    }

    input[type="email"],
    .recaptcha {
      width: 100%;
    }

    label {
      @extend %body-text-small;
      color: transparentize($white, 0.4);
    }

    .js-terms-and-conditions {
      padding: $font-size-body-text-small 0.444rem;
      background-color: $white;
      display: inline-flex;
      align-items: center;
      @include until($tablet) {
        width: 16rem;
      }
    }

    .button-container {
      display: flex;
      justify-content: flex-end;
      width: 100%;
      margin-left: auto;
      margin-right: auto;
      margin-top: auto;
      @include until($tablet) {
        width: 16rem;
        margin-left: auto;
        margin-right: auto;
      }

      @include until($desktop) {
        max-width: 650px;
      }
    }
  }

  .page-description {
    @extend %body-text;
  }

  .column-title {
    @extend %body-text-small;
    font-weight: bold;
    color: $white;
  }

  .column-description {
    @extend %body-text-small;
  }

  .column-link {
    @extend %body-text-small;
  }

  .image-downloader {
    @include get-involved-content-page;

    .columns {
      padding-top: 2.222rem;
    }

    .downloadable-image {
      margin-top: 1.125rem;
      width: 11.111rem;
      //height: 11.111rem;
      height: auto;
      display: block;
    }
  }

  .ami-button {
    > input[type="checkbox"] {
      display: none;

      &:checked + label::before {
        content: '\e800';
        font-family: "ami-icons";
        background-color: $dark-green;
        border-color: $dark-green;
        color: $white;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.8rem;
      }
    }

    > label {
      display: flex;
      align-items: center;
      color: #414141; // Missing color in the styleguide
      font-family: $font-tgn-condensed;
      font-size: $font-size-body-text;
      letter-spacing: 0.54px;

      &::before {
        content: '';
        border: 1px solid $grey-light;
        height: 1.125rem;
        width: 1.125rem;
        margin-right: 0.5rem;
      }
    }
  }

  .image-editting-column {
    width: 17.666rem;
    float: right;
    @include until($tablet) {
      width: 16rem;
      margin-left: auto;
      margin-right: auto;
      float: none;
    }

    @include until($desktop) {
      margin-left: auto;
    }
  }

  .dropzone-net {
    width: 17.666rem;
    height: 17.666rem;
    border: 2px dashed $white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;

    @include until($tablet) {
      width: 16rem;
      height: 16rem;
    }
  ;

    .dz-message {
      @extend %body-text-small;
      text-align: center;
    }

    .dz-preview {
      display: none;
    }

    .image-editor {
      max-width: 100%;
      max-height: 100%;
      height: 100%;

      img {
        width: 100%;
      }
    }

    .mobile-overlay {
      display: none;
    }

    &.dz-started .mobile-overlay {
      @include dropzone-overlay;
    }

    &:hover {
      .remove-image-desktop {
        color: $red;
        transition: color $transition-duration ease;
      }

      .drag-info-box {
        opacity: 0;
        transition: opacity $transition-duration ease;
      }

      @include until($desktop) {
        &.dz-started .mobile-overlay {
          display: flex;
        }
      }
    }

    @include until($desktop) {
      .for-desktop,
      .drag-info-box,
      .remove-image-desktop {
        display: none;
      }
    }

    @include from($desktop) {
      .for-mobile {
        display: none;
      }
    }
  }

  .zoom-controls {
    margin-top: 1rem;

    .zoom-label {
      @extend %body-text-small;
      color: $white;
    }

    @include until($desktop) {
      display: none;
    }
  }

  .remove-image-desktop {
    position: absolute;
    bottom: 0;
    left: 0;
    font-size: $font-size-big;
    background-color: transparentize($black, 0.4);
    z-index: 100;
  }

  .remove-image-mobile {
    @extend %body-text-small;
    color: $red;
    margin-top: 0.444rem;
    display: flex;
    align-items: center;
    cursor: pointer;

    > span::before {
      font-size: 1rem;
    }

    @include from($desktop) {
      display: none;
    }
  }

  .drag-info-box {
    @extend %body-text-small;
    color: $white;
    padding: 0.2rem;
    background-color: transparentize($black, 0.4);
    position: absolute;
    top: $font-size-body-text;
    right: $font-size-body-text;
    pointer-events: none;
    z-index: 100;
  }

  .banners {
    position: absolute;
    top: 0;
    left: 0;
    background-image: url('../images/banners.svg');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    width: 100%;
    height: 100%;
    pointer-events: none;
  }

  .email-required-message-overlay {
    @include dropzone-overlay;
    pointer-events: all;

    &.is-active {
      display: flex;
    }
  }
}

.loader-container {
  opacity: 0.5;
  background: $black;
  width: 100%;
  height: 100%;
  z-index: 10;
  top: 0;
  left: 0;
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;

  .loader {
    border-bottom-color: $yellow;
    border-left-color: $yellow;
    height: 3rem;
    width: 3rem;
  }
}
