:root{--blue:#007aff;--text:#111114;--muted:#81818a;--line:#e5e5ea;--surface:#f2f2f7;--bg:#fff;--red:#e74740;--tg-safe-top:0px;--tg-safe-bottom:0px;color-scheme:light}
*{box-sizing:border-box}
html,body{margin:0;min-height:100%;background:var(--bg);color:var(--text);font-family:-apple-system,BlinkMacSystemFont,"Helvetica Neue",Arial,sans-serif;-webkit-font-smoothing:antialiased;overscroll-behavior-y:none}
button{font:inherit;-webkit-tap-highlight-color:transparent;touch-action:manipulation;cursor:pointer}
button:focus-visible{outline:3px solid #88baff;outline-offset:3px}
button:disabled{cursor:default}
[hidden]{display:none!important}
.app{max-width:440px;min-height:100svh;min-height:var(--tg-viewport-stable-height,100svh);margin:0 auto;padding:calc(18px + max(env(safe-area-inset-top),var(--tg-safe-top))) 24px calc(24px + max(env(safe-area-inset-bottom),var(--tg-safe-bottom)));display:flex;flex-direction:column}
.group{height:24px;color:var(--muted);font-size:13px;line-height:24px;display:flex;align-items:center;justify-content:center;gap:6px;white-space:nowrap;letter-spacing:-.1px;flex-shrink:0}
.group svg{width:12px;height:12px;stroke:currentColor;fill:none;stroke-width:1.8}
.scene{flex:1;display:flex;flex-direction:column;text-align:center}
.scene-heading{margin-top:20px}
.mascot{width:250px;height:250px;margin:0 auto;contain:layout style;isolation:isolate;position:relative}
.mascot-stage{position:absolute;inset:0;width:100%;height:100%}
.mascot svg{display:block;width:100%;height:100%;overflow:visible}
h1{font-size:27px;line-height:33px;letter-spacing:-.75px;font-weight:700;margin:12px 0 0;text-wrap:balance}
.heading-copy p{font-size:16px;line-height:23px;color:var(--muted);margin:12px auto 0;letter-spacing:-.16px;text-wrap:balance}
.bottom{margin-top:auto;padding-top:32px}
.primary{width:100%;min-height:50px;padding:12px 16px;border:0;background:var(--blue);border-radius:12px;color:#fff;font-size:17px;font-weight:600;letter-spacing:-.25px;display:flex;align-items:center;justify-content:center;gap:9px;transition:background .15s,transform .12s}
.primary:active:not(:disabled){transform:scale(.985)}
.primary:disabled{background:color-mix(in srgb,var(--blue) 35%,var(--bg))}
.primary.loading:before{content:"";width:17px;height:17px;border:2px solid #ffffff60;border-top-color:white;border-radius:50%;animation:spin .8s linear infinite}
.captcha .scene-heading,.wrong .scene-heading,.checking .scene-heading{display:flex;align-items:center;justify-content:center;gap:7px;text-align:left;margin-top:4px;min-height:128px}
.captcha .mascot,.wrong .mascot,.checking .mascot{width:128px;height:128px;margin:0;flex-shrink:0}
.captcha h1,.wrong h1,.checking h1{font-size:25px;line-height:31px;margin:0}
.captcha .heading-copy p,.wrong .heading-copy p,.checking .heading-copy p{font-size:14px;line-height:19px;max-width:215px;margin-top:5px;text-wrap:wrap}
.captcha-image{display:block;width:100%;height:100px;object-fit:contain;background:#f5f5f9;border-radius:12px;margin-top:4px;user-select:none}
.digits{display:flex;gap:10px;justify-content:center;margin-top:16px}
.digit{width:60px;height:52px;border:1px solid var(--line);background:var(--surface);border-radius:10px;display:flex;align-items:center;justify-content:center;font-size:28px;font-weight:500;font-variant-numeric:tabular-nums;line-height:1}
.digit.empty:after{content:"";width:17px;height:2px;background:#c8c8d1;border-radius:2px}
.digit.active{border:1.5px solid var(--blue);background:var(--bg)}
.feedback{min-height:18px;line-height:18px;text-align:center;margin:6px 0 0;font-size:12px;color:var(--muted);letter-spacing:-.07px}
.wrong .digit{border-color:#edaaa8;background:color-mix(in srgb,var(--red) 5%,var(--bg))}
.wrong .feedback{color:var(--red)}
.refresh{margin:3px 0 0;width:100%;min-height:38px;border:0;background:transparent;color:var(--blue);font-size:14px;letter-spacing:-.15px;display:flex;gap:5px;align-items:center;justify-content:center}
.refresh:disabled{opacity:.5}
.refresh svg{width:15px;height:15px;stroke:currentColor;fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.keypad{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;margin-top:4px}
.key{border:0;min-height:44px;border-radius:9px;font-size:24px;font-weight:400;color:var(--text);background:var(--surface);display:flex;align-items:center;justify-content:center;transition:background .1s}
.key:active:not(:disabled){background:color-mix(in srgb,var(--blue) 16%,var(--surface))}
.key.delete{background:transparent}
.key svg{width:23px;height:23px;stroke:currentColor;fill:none;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.captcha .bottom,.wrong .bottom,.checking .bottom{padding-top:16px}
.saved{margin-top:28px;border-radius:14px;background:var(--surface);padding:16px;text-align:center}
.saved span{color:var(--muted);font-size:13px;line-height:19px}
.saved strong{display:block;font-size:26px;letter-spacing:12px;padding-left:12px;font-weight:500;margin-top:6px}
.success .scene-heading{margin-top:35px}
.success .mascot{width:250px;height:250px}
.offline h1{font-size:25px}
@keyframes spin{to{transform:rotate(360deg)}}
@media(max-width:350px){.app{padding-left:18px;padding-right:18px}.captcha h1,.wrong h1,.checking h1{font-size:23px}.captcha .heading-copy p,.wrong .heading-copy p,.checking .heading-copy p{font-size:12px}h1{font-size:25px}}
@media(max-height:650px){.scene-heading{margin-top:6px}.mascot{width:200px;height:200px}.success .scene-heading{margin-top:15px}.success .mascot{width:210px;height:210px}.app{padding-top:12px;padding-bottom:16px}.captcha-image{height:86px}.captcha .scene-heading,.wrong .scene-heading,.checking .scene-heading{min-height:104px}.captcha .mascot,.wrong .mascot,.checking .mascot{width:104px;height:104px}.digits{margin-top:10px}.digit{height:48px}.key{min-height:42px}.captcha .bottom,.wrong .bottom,.checking .bottom{padding-top:12px}}
@media(prefers-reduced-motion:reduce){*,*:before{transition:none!important;animation-duration:2s!important}}
