.backdrop {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: 100vw;
  background: var(--color-dark-blue);
  opacity: 0.8;
  z-index: 10;
}

.modal-window {
  position: fixed;
  z-index: 11;
  top: calc((100vh - 720px) / 2);
  top: calc((var(--vh, 1vh) * 100 - 720px) / 2);
  height: 720px;
  width: calc(100vw - 120px);
  align-self: center;
  padding: 0 40px;
  max-width: 1920px;
  display: flex;
  flex-direction: column;
  color: var(--color-grey);
  background-color: var(--color-dark-blue);
  box-shadow: rgba(0, 0, 0, 0.35) 0px 5px 15px;
  border-radius: 15px;
  border: 1px solid var(--color-violet);
  transition: all var(--main-animation);
  --input-height: 52px;
}

.btn-close {
  align-self: flex-end;
  margin-top: 25px;
}

.btn-close img {
  height: 28px;
  width: 28px;
}

.modal-window form {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 95px;
  margin-top: 40px;
}

.modal-window .inputs {
  width: 100%;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.modal-window .inputs input,
.modal-window .inputs textarea {
  width: 100%;
  height: 100%;
  font: var(--font-text-1);
  color: var(--color-black);
  padding: 20px;
  background-color: transparent;
  border: 1px solid var(--color-dark-grey);
  border-radius: 5px;
}

.modal-window .input {
  display: flex;
  flex-direction: column;
  position: relative;
}

.modal-window .inputs .input input {
  height: var(--input-height);
}

.modal-window .user-contacts-section {
  display: flex;
  gap: inherit;
}

.modal-window .user-contacts-section .input {
  width: calc((100% - 20px) / 2);
}

.modal-window .inputs textarea {
  height: 190px;
}

.modal-window .send-form {
  width: 200px;
}

.modal-window .send-form .btn-text-sending {
  display: none;
}

.modal-window .send-form.form-sending .btn-text-send {
  display: none;
}

.modal-window .send-form.form-sending .btn-text-sending {
  display: inline-block;
}

.err-text {
  top: var(--input-height);
  position: absolute;
  color: var(--color-red);
  opacity: 0.75;
  font: var(--font-text-2);
}

.form_sent {
  bottom: 40px;
  position: absolute;
  color: var(--color-black);
  opacity: 0.75;
  font: var(--font-text-2);
  text-align: center;
}

.modal-hidden {
  opacity: 0;
  left: -100vw;
}

@media screen and (max-width: 1024px) {
  .modal-window {
    top: calc((100vh - 640px) / 2);
    top: calc((var(--vh, 1vh) * 100 - 640px) / 2);
    width: calc(100vw - 40px);
    padding: 0 20px;
  }
  .btn-close {
    margin-top: 20px;
  }
  .modal-window .form_header {
    margin-top: 40px;
  }
  .modal-window form {
    margin-bottom: 50px;
  }
  .form_sent {
    bottom: 20px;
  }
}

@media screen and (max-width: 639px) {
  .modal-window {
    top: calc((100vh - 500px) / 2);
    top: calc((var(--vh, 1vh) * 100 - 500px) / 2);
    height: 500px;
    padding: 0 10px;
    width: 100vw;
    --input-height: 52px;
  }
  .btn-close {
    margin: 10px;
    height: 20px;
    width: 20px;
  }
  .modal-window .form_header {
    margin-top: 20px;
    font-size: 12px;
  }
  .modal-window form {
    margin-top: 20px;
    margin-bottom: 35px;
  }
  .modal-window .inputs input,
  .modal-window .inputs textarea {
    font: var(--font-text-2);
    padding: 20px 10px;
  }
  .modal-window .inputs {
    margin-bottom: 15px;
    gap: 15px;
  }
  .modal-window .user-contacts-section {
    flex-direction: column;
  }
  .modal-window .user-contacts-section .input {
    width: 100%;
  }
  .modal-window .inputs textarea {
    height: 120px;
  }
  .err-text {
    font-size: 10px;
  }
  .send-form.orange-btn {
    width: 100%;
    padding: 5px;
  }
  .form_sent {
    bottom: 10px;
    font-size: 12px;
  }
}
