* { box-sizing: border-box; }
body {
    margin: 0;
    min-height: 100vh;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #f8fafc;
    background: radial-gradient(circle at 50% 18%, rgba(99,102,241,.28), transparent 34%), linear-gradient(145deg, #0f172a, #1e1b4b);
}
.challenge-container {
    width: 100%;
    max-width: 480px;
    padding: 38px;
    text-align: center;
    background: rgba(30,41,59,.88);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 22px;
    box-shadow: 0 24px 60px rgba(0,0,0,.38);
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 25px;
    color: #c7d2fe;
    font-size: 14px;
    font-weight: 700;
}
.brand-shield {
    width: 27px;
    height: 27px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    color: #fff;
    background: #4f46e5;
}
.status-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a5b4fc;
    font-size: 42px;
}
.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(165,180,252,.18);
    border-top-color: #818cf8;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
.status-icon.ready {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    color: #052e16;
    background: #6ee7b7;
    font-size: 34px;
    font-weight: 800;
}
h1 { margin: 0 0 11px; font-size: 25px; line-height: 1.25; }
.message { margin: 0 auto 24px; color: #cbd5e1; font-size: 15px; line-height: 1.65; }
.progress-track {
    width: 100%;
    height: 8px;
    margin: 0 0 14px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(148,163,184,.18);
}
.progress-track span {
    display: block;
    width: 6%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #6366f1, #a5b4fc);
    transition: width .18s ease;
}
.progress-track span.failed { width: 100% !important; background: #ef4444; }
.status-text { min-height: 21px; margin: 0 0 18px; color: #94a3b8; font-size: 13px; }
.btn-verify {
    width: 100%;
    min-height: 48px;
    padding: 13px 22px;
    border: 0;
    border-radius: 11px;
    color: #fff;
    background: linear-gradient(135deg, #4f46e5, #3730a3);
    box-shadow: 0 6px 18px rgba(79,70,229,.32);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}
.btn-verify:hover:not(:disabled) { background: linear-gradient(135deg, #6366f1, #4338ca); }
.btn-verify:focus-visible { outline: 3px solid #c7d2fe; outline-offset: 3px; }
.btn-verify:disabled { color: #94a3b8; background: rgba(71,85,105,.72); box-shadow: none; cursor: wait; }
.turnstile-wrap { display: flex; justify-content: center; margin: 0 0 16px; }
.expiry-text { margin: 14px 0 0; color: #94a3b8; font-size: 12px; line-height: 1.5; }
.alert { margin: 0 0 18px; padding: 12px 14px; border-radius: 9px; font-size: 13px; line-height: 1.5; }
.alert-error { color: #fecaca; background: rgba(127,29,29,.42); border: 1px solid rgba(248,113,113,.45); }
.footer-text { margin-top: 25px; color: #64748b; font-size: 12px; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 520px) {
    body { padding: 12px; }
    .challenge-container { padding: 28px 20px; border-radius: 17px; }
}
@media (prefers-reduced-motion: reduce) {
    .spinner { animation: none; }
    .progress-track span { transition: none; }
}
