/* human-check.css — the download check (assets/js/human-check.js), in the site's colours */
.hc-open, .hc-open body { overflow: hidden; }

.hc-overlay {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(10, 12, 14, 0.62);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .2s ease;
}
.hc-overlay--in { opacity: 1; }
.hc-modal {
  width: 100%; max-width: 380px;
  transform: translateY(12px) scale(.98); transition: transform .25s cubic-bezier(.2, .8, .2, 1);
}
.hc-overlay--in .hc-modal { transform: none; }
.hc-modal:focus { outline: none; }

.hc-page { display: flex; justify-content: center; padding: 24px 0 48px; }
.hc-page .hc { max-width: 380px; width: 100%; }
.hc-noscript { color: var(--text-2, #8a92aa); text-align: center; }

.hc {
  position: relative;
  background: linear-gradient(180deg, var(--bg-card-alt, #444a52) 0%, var(--bg-card, #3c4046) 100%);
  border: 1px solid var(--border-glow, rgba(0, 213, 255, .25));
  border-radius: var(--radius-lg, 16px);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .03) inset, var(--shadow-glow, 0 0 20px rgba(0, 213, 255, .12));
  padding: 18px 18px 14px;
  color: var(--text-1, #e2e5ef);
  font-family: var(--font-ui, 'Outfit', sans-serif);
  user-select: none; -webkit-user-select: none;
}

.hc__head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.hc__badge {
  flex: none; width: 38px; height: 38px; border-radius: 12px;
  display: grid; place-items: center;
  color: #06222a; font-size: 17px;
  background: linear-gradient(135deg, var(--accent, #00d5ff), #6ef0ff);
  box-shadow: 0 4px 14px rgba(0, 213, 255, .35);
}
.hc__titles { flex: 1; min-width: 0; }
.hc__title { margin: 1px 0 3px; font-size: 1.06rem; font-weight: 600; line-height: 1.25; color: var(--text-1, #e2e5ef); }
.hc__lead { margin: 0; font-size: .84rem; line-height: 1.4; color: var(--text-2, #8a92aa); }
.hc__close {
  flex: none; width: 32px; height: 32px; margin: -4px -6px 0 0; border: 0; border-radius: 50%;
  background: transparent; color: var(--text-2, #8a92aa); cursor: pointer; font-size: 16px;
  transition: background .15s, color .15s;
}
.hc__close:hover, .hc__close:focus-visible { background: var(--bg-hover, #4a5058); color: var(--text-1, #e2e5ef); outline: none; }

/* the picture */
.hc__stage {
  position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden;
  border-radius: 12px; background: var(--bg-input, #2c2e2e);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .06) inset;
}
.hc__bg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; transition: opacity .25s; }
.hc__piece {
  position: absolute; left: 0; top: 0; width: 52px; height: 52px; display: block;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, .55)) drop-shadow(0 0 1px rgba(255, 255, 255, .7));
  will-change: transform; transition: opacity .25s;
}
.hc__veil {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: var(--bg-input, #2c2e2e); opacity: 0; pointer-events: none; transition: opacity .2s;
}
.hc--loading .hc__veil { opacity: 1; }
.hc--loading .hc__piece { opacity: 0; }
.hc__spin {
  width: 26px; height: 26px; border-radius: 50%;
  border: 3px solid rgba(0, 213, 255, .2); border-top-color: var(--accent, #00d5ff);
  animation: hc-spin .8s linear infinite;
}
@keyframes hc-spin { to { transform: rotate(360deg); } }
.hc__again {
  position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 50%; border: 0;
  background: rgba(20, 22, 24, .55); color: #fff; font-size: 13px; cursor: pointer;
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  transition: background .15s, transform .3s;
}
.hc__again:hover, .hc__again:focus-visible { background: rgba(20, 22, 24, .8); transform: rotate(90deg); outline: none; }

.hc__done {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none;
  background: rgba(10, 30, 20, .45); opacity: 0; transition: opacity .25s;
}
.hc__tick {
  width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center;
  font-size: 26px; color: #fff; background: var(--success, #22c55e);
  box-shadow: 0 6px 22px rgba(34, 197, 94, .5);
  transform: scale(.4); transition: transform .35s cubic-bezier(.2, 1.4, .4, 1);
}
.hc--ok .hc__done { opacity: 1; }
.hc--ok .hc__tick { transform: scale(1); }
.hc--miss .hc__stage { animation: hc-shake .4s ease; }
@keyframes hc-shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

/* the slider */
.hc__track {
  position: relative; height: 46px; margin-top: 12px; border-radius: 23px;
  background: var(--bg-input, #2c2e2e); box-shadow: 0 0 0 1px var(--border, #505860) inset;
  overflow: hidden; touch-action: none;
}
.hc__fill {
  position: absolute; left: 0; top: 0; bottom: 0; width: 23px; border-radius: 23px;
  background: linear-gradient(90deg, rgba(0, 213, 255, .08), rgba(0, 213, 255, .28));
}
.hc--ok .hc__fill { background: linear-gradient(90deg, rgba(34, 197, 94, .1), rgba(34, 197, 94, .35)); }
.hc__hint {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding-left: 40px;
  font-size: .86rem; color: var(--text-2, #8a92aa); letter-spacing: .01em; pointer-events: none;
  transition: opacity .2s;
  background: linear-gradient(90deg, var(--text-2, #8a92aa) 0%, var(--text-2, #8a92aa) 40%, #e2f9ff 50%, var(--text-2, #8a92aa) 60%, var(--text-2, #8a92aa) 100%);
  background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  animation: hc-shimmer 2.6s linear infinite;
}
@keyframes hc-shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
.hc__knob {
  position: absolute; left: 0; top: 0; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; font-size: 17px; color: #06222a; cursor: grab;
  background: linear-gradient(135deg, var(--accent, #00d5ff), #6ef0ff);
  box-shadow: 0 3px 10px rgba(0, 213, 255, .45), 0 0 0 3px rgba(0, 0, 0, .15);
  will-change: transform; touch-action: none; outline: none;
  transition: box-shadow .15s;
}
.hc__knob:focus-visible { box-shadow: 0 3px 10px rgba(0, 213, 255, .45), 0 0 0 3px #fff; }
.hc__knob--held { cursor: grabbing; box-shadow: 0 5px 16px rgba(0, 213, 255, .6), 0 0 0 5px rgba(0, 213, 255, .18); }
.hc--ok .hc__knob { background: var(--success, #22c55e); color: #fff; }

.hc__status { min-height: 1.3em; margin: 10px 2px 0; font-size: .84rem; text-align: center; color: var(--text-2, #8a92aa); }
.hc__status--good { color: var(--success, #22c55e); }
.hc__status--bad { color: #ff8a8a; }

.hc__hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

@media (prefers-reduced-motion: reduce) {
  .hc__hint, .hc__spin { animation: none; }
  .hc-overlay, .hc-modal, .hc__tick { transition: none; }
}
