/* Google Sorry-style captcha page — match https://www.google.com/recaptcha/api2/demo
   Checkbox: grey border → spinning ring → green check */

:root { color-scheme: light; }

.recaptcha-wrap {
  margin: 0 0 10px;
  display: block;
}

.recaptcha-wrap .rc-anchor {
  border-radius: 3px;
  border: 1px solid #d3d3d3;
  box-shadow: none;
  display: inline-block;
}

.recaptcha-wrap .rc-anchor-normal {
  height: 74px;
  width: 300px;
}

.recaptcha-wrap .rc-anchor-light {
  background: #f9f9f9;
  color: #000;
}

.recaptcha-wrap .rc-anchor-checkbox-label {
  font-family: Roboto, arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: normal;
  color: #000;
}

/* ========== Loading spinner (Google-style rotating arc) ========== */
.recaptcha-checkbox-loading .recaptcha-checkbox-border,
.recaptcha-checkbox-loading .recaptcha-checkbox-borderAnimation {
  opacity: 0 !important;
  visibility: hidden !important;
}

.recaptcha-checkbox-loading .recaptcha-checkbox-spinner {
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  position: absolute !important;
  left: 1px !important;
  top: 1px !important;
  width: 26px !important;
  height: 26px !important;
  box-sizing: border-box !important;
  border-radius: 50% !important;
  background: transparent !important;
  /* Arc like Google: thick green/blue stroke with gap */
  border: 3px solid transparent !important;
  border-top-color: #1a73e8 !important;
  border-right-color: #1a73e8 !important;
  border-bottom-color: rgba(26, 115, 232, 0.15) !important;
  border-left-color: transparent !important;
  animation: rc-spinner-spin 0.75s linear infinite !important;
  animation-play-state: running !important;
  -webkit-animation: rc-spinner-spin 0.75s linear infinite !important;
  -webkit-animation-play-state: running !important;
  transform-origin: 50% 50% !important;
  transition: opacity 0.12s ease !important;
}

.recaptcha-checkbox-loading .recaptcha-checkbox-spinner-overlay {
  display: none !important;
}

.recaptcha-checkbox-loading .recaptcha-checkbox-checkmark {
  opacity: 0 !important;
  visibility: hidden !important;
}

@keyframes rc-spinner-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
@-webkit-keyframes rc-spinner-spin {
  0% { -webkit-transform: rotate(0deg); transform: rotate(0deg); }
  100% { -webkit-transform: rotate(360deg); transform: rotate(360deg); }
}

/* ========== Verified green checkmark (Google #0f9d58) ========== */
.recaptcha-checkbox-checked .recaptcha-checkbox-border,
.recaptcha-checkbox-checked .recaptcha-checkbox-borderAnimation,
.recaptcha-checkbox-checked .recaptcha-checkbox-spinner {
  opacity: 0 !important;
  visibility: hidden !important;
  display: none !important;
}

.recaptcha-checkbox-checked .recaptcha-checkbox-checkmark {
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
  background-image: none !important;
  background: transparent !important;
  width: 28px !important;
  height: 28px !important;
  left: 0 !important;
  top: 0 !important;
  position: absolute !important;
  overflow: visible !important;
  animation: rc-check-pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

/* Classic Google green tick */
.recaptcha-checkbox-checked .recaptcha-checkbox-checkmark::before {
  content: "" !important;
  position: absolute !important;
  left: 8px !important;
  top: 3px !important;
  width: 8px !important;
  height: 16px !important;
  border-style: solid !important;
  border-color: #0f9d58 !important;
  border-width: 0 3.5px 3.5px 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-sizing: border-box !important;
  transform: rotate(45deg) !important;
  transform-origin: center !important;
  animation: rc-check-draw 0.32s ease-out 0.04s both !important;
}

@keyframes rc-check-pop {
  0% { transform: scale(0.2); opacity: 0; }
  70% { transform: scale(1.12); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes rc-check-draw {
  0% {
    height: 0;
    width: 0;
    opacity: 0;
    border-color: #0f9d58;
  }
  40% {
    width: 8px;
    height: 0;
    opacity: 1;
  }
  100% {
    width: 8px;
    height: 16px;
    opacity: 1;
  }
}

/* Mobile — widget stays 300x74 as Google's does */
@media (max-width: 480px) {
  body {
    padding: 15px !important;
  }
  .recaptcha-wrap {
    max-width: 100%;
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  .recaptcha-wrap .rc-anchor { transition: none; }
  .recaptcha-checkbox-loading .recaptcha-checkbox-spinner {
    animation: none !important;
    border-top-color: #1a73e8 !important;
    border-right-color: #1a73e8 !important;
  }
  .recaptcha-checkbox-checked .recaptcha-checkbox-checkmark,
  .recaptcha-checkbox-checked .recaptcha-checkbox-checkmark::before {
    animation: none !important;
  }
}
