.yandex-captcha {
  background: #e5e7ed;
  position: relative;
  transform: none;
  width: min(100%, 300px);
}

.yandex-captcha__container {
  min-height: 100px;
}

.yandex-captcha__error {
  color: #e55;
  font-size: 14px;
  line-height: normal;
  margin-top: 8px;
}

.yandex-captcha__error:empty {
  display: none;
}

.yandex-captcha.isLoading {
  opacity: 0.7;
}

.yandex-captcha.isVisible {
  background: transparent;
}

.yandex-captcha.isVisible.isInvalid {
  animation: yandex-captcha-shake .25s ease-in-out 2;
}

.yandex-captcha:not(.isVisible) {
  cursor: wait;
  border-radius: 24px;
}

.yandex-captcha:not(.isVisible)::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 30px;
  height: 30px;
  margin-top: -15px;
  margin-left: -15px;
  border: 3px solid #fff;
  border-top-color: transparent;
  border-radius: 50%;
  z-index: 2;
  animation: yandex-captcha-spin .8s linear infinite;
}

.yandex-captcha:not(.isVisible) * {
  pointer-events: none;
}

@keyframes yandex-captcha-shake {
  0%,
  100% {
    transform: translateX(0);
  }
  
  25% {
    transform: translateX(-4px);
  }
  
  75% {
    transform: translateX(4px);
  }
}

@keyframes yandex-captcha-spin {
  to {
    transform: rotate(360deg);
  }
}
