.apply-modal {
  z-index: 3;
  width: 100vw;
  height: 100vh;
  position: fixed;
  top: 0;
  background-color: rgba(0, 0, 0, 30%);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  opacity: 1;
  pointer-events: all;
  transition: opacity 300ms;

  .questions-form {
    width: 85%;
    max-width: 1440px;
    background-color: var(--white-primary);
    margin: 0;
    position: relative;
    overflow-y: auto;
    padding: 24px 32px;
  }

  .questions-form__title {
    h1,
    h2 {
      color: var(--dark-80);
    }
  }

  .form-field {
    border-bottom: 1px solid var(--dark-80);

    label {
      color: #000000b2;
    }

    input,
    textarea {
      color: var(--dark-100);
    }

    &:hover {
      border-color: #00af4c;

      input,
      textarea {
        + label {
          color: var(--dark-100);
        }
      }
    }

    &:has(input:focus, textarea:focus) {
      border-color: #00af4c;
    }
  }

  .form-file {
    label {
      color: var(--dark-50);
    }
  }

  .form-file__delete-btn {
    &::after {
      filter: none;
    }
  }

  .form-privacy {
    p,
    label {
      color: var(--dark-50);
    }
  }

  .btn-default {
    margin-inline: 0 auto;
  }

  .questions-form.hidden {
    display: none;
  }

  .btn-close {
    background-color: transparent;
    border: none;
    cursor: pointer;
    position: absolute;
    top: 58px;
    right: 58px;
    z-index: 1;

    img {
      width: 16px;
      height: 16px;
      transition: transform 300ms, filter 300ms;
      filter: grayscale(1) brightness(0);
    }

    &:hover {
      img {
        transform: rotate(90deg);
        filter: none;
      }
    }
  }

  &.hidden {
    opacity: 0;
    pointer-events: none;
  }
}

.apply-modal__success {
  width: 40%;
  max-width: 1440px;
  display: none;
  justify-content: center;
  position: relative;
  gap: 24px;

  .questions-form {
    width: 100%;
  }

  .questions-form__title {
    flex-direction: column;
    align-items: baseline;
  }

  p {
    width: 100%;
    font-family: "Inter", sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 22.4px;
    color: var(--dark-50);
  }

  &.active {
    display: flex;
  }
}

@media (max-width: 768px), (max-height: 770px) {
  .apply-modal {
    .questions-form {
      width: 100%;
      height: 100%;
      padding: 48px;
    }

    .questions-form__title {
      h1, h2 {
        margin-top: 15px;
      }
    }
  }

  .apply-modal__success {
    width: 100%;
    height: 100%;

    .questions-form {
      p {
        width: 100%;
      }
    }
  }

  .btn-close {
    top: 48px;
    right: 48px;
  }
}

@media ((min-height: 771px) and (max-height: 900px) and (min-width: 768px)) {
  .apply-modal {
    .questions-form {
      top: 40px;
    }
  }
}
