:root{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#f3f5f6;background:#101820;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-optical-sizing:auto;font-size:16px;--surface: #1a252e;--surface-raised: #23313c;--accent: #b7ed42;--muted: #9ba9b3}*{box-sizing:border-box}body{margin:0;min-width:320px;min-height:100vh;min-height:100dvh}button{font:inherit}.remote-shell{--pad-size: min( calc(69vw + 46px) , 31dvh, 316px);width:min(100%,440px);min-height:100vh;min-height:100dvh;margin:0 auto;padding:max(16px,env(safe-area-inset-top)) 26px max(16px,env(safe-area-inset-bottom))}.device-header{margin:0 0 14px}.device-tabs{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;padding:3px 2px 8px}.device-tab{display:inline-flex;flex:0 0 auto;align-items:center;gap:9px;min-height:42px;max-width:80vw;padding:0 15px;border:1px solid #30404b;border-radius:999px;background:#151f27;color:#c4cdd2;font:inherit;font-size:.88rem;font-weight:700;cursor:pointer;touch-action:manipulation;transition:transform .08s ease,background .12s ease,border-color .12s ease,color .12s ease}.device-tab:hover{border-color:#536673;background:var(--surface-raised)}.device-tab:active{transform:scale(.96)}.device-tab:focus-visible{outline:3px solid var(--accent);outline-offset:2px}.device-tab.selected{border-color:var(--accent);background:#26343e;color:#f7f8f8}.device-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.device-dot{width:8px;height:8px;flex:0 0 auto;border-radius:50%;background:#66747d}.device-dot.online{background:#71d9a6;box-shadow:0 0 8px #71d9a655}.device-empty{display:inline-flex;align-items:center;min-height:42px;padding:0 4px;color:var(--muted);font-size:.85rem}.status{min-height:40px;display:flex;align-items:center;gap:10px;margin:0 0 14px;padding:0 14px;border:1px solid #30404b;border-radius:12px;color:#c4cdd2;font-size:.83rem}.status-dot{width:8px;height:8px;flex:0 0 auto;border-radius:50%;background:var(--accent)}.status-busy .status-dot{background:#f1bd58;animation:pulse 1s infinite alternate}.status-success .status-dot{background:#71d9a6}.status-error{color:#ffc2b9;border-color:#74463f}.status-error .status-dot{background:#ff7967}@keyframes pulse{to{opacity:.35}}.record-button{grid-area:1 / 3;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-width:0;min-height:0;padding:4px;border:1px solid #b64b4b;border-radius:19px;background:#762f35;color:#fff4f3;font:inherit;font-size:.82rem;font-weight:750;cursor:pointer;touch-action:manipulation;transition:transform .08s ease,background .12s ease,border-color .12s ease}.record-button:hover{border-color:#fa7777;background:#913a42}.record-button:active{transform:scale(.96)}.record-button:focus-visible{outline:3px solid #ff9292;outline-offset:3px}.record-button.is-recording{border-color:#ff7272;background:#a9343d}.record-dot{width:9px;height:9px;flex:0 0 auto;border-radius:50%;background:#ff6b6b;box-shadow:0 0 8px #ff6b6b77}.is-recording .record-dot{animation:record-pulse 1s infinite alternate}.recording-count{max-width:100%;overflow:hidden;color:#f3c5c5;font-size:.62rem;font-weight:600;text-overflow:ellipsis;white-space:nowrap}@keyframes record-pulse{to{opacity:.35;transform:scale(.82)}}.controls{display:grid;gap:8px}.pad-switcher{display:grid;gap:4px}.pad-heading{display:flex;align-items:center;justify-content:space-between;min-height:30px}.pad-heading h2{margin:0 0 0 2px}.pad-toggle{display:inline-flex;align-items:center;gap:6px;min-height:34px;padding:0 12px;border:1px solid #34444f;border-radius:999px;background:var(--surface);color:#e7ecef;font:inherit;font-size:.8rem;font-weight:700;cursor:pointer;touch-action:manipulation}.pad-toggle:hover{background:var(--surface-raised);border-color:#536673}.pad-toggle:active{transform:scale(.96);background:#2a3a45}.pad-toggle:focus-visible{outline:3px solid var(--accent);outline-offset:3px}.pad-toggle span{color:var(--accent);font-size:1.15rem;line-height:1}.direction-pad{display:grid;grid-template-columns:repeat(3,1fr);grid-template-rows:repeat(3,1fr);gap:9px;padding:14px;border:1px solid #293640;border-radius:28px;background:#151f27}.direction-pad,.shared-pad{height:var(--pad-size)}.shared-pad{grid-template-rows:repeat(4,1fr)}.remote-button{display:flex;align-items:center;justify-content:center;min-width:0;border:1px solid #34444f;border-radius:19px;background:var(--surface);color:#f7f8f8;font-family:inherit;font-weight:700;cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;transition:transform .08s ease,background .12s ease,border-color .12s ease}.remote-button:hover{background:var(--surface-raised);border-color:#536673}.remote-button:active{transform:scale(.95);background:#2a3a45}.remote-button:disabled{cursor:default;opacity:.52}.remote-button:disabled:active{transform:none;background:var(--surface)}.remote-button:focus-visible{outline:3px solid var(--accent);outline-offset:3px}.direction{font-size:2rem}.direction.up{grid-area:1 / 2}.direction.left{grid-area:2 / 1}.direction.center{grid-area:2 / 2;border-color:var(--accent);background:var(--accent);color:#16200d;font-size:1rem}.direction.center:hover{border-color:#cff77e;background:#cff77e}.direction.right{grid-area:2 / 3}.direction.down{grid-area:3 / 2}.back-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.back-button{min-width:0;min-height:44px;gap:6px;padding:0 6px;border-radius:15px;background:#26343e;font-size:.95rem}.xiaomi-back-button{min-height:38px;border-style:dashed;color:#c4cdd2;font-size:.85rem}.back-symbol{color:var(--accent);font-size:1.25rem}h2{margin:0 0 12px 2px;color:#aeb9c0;font-size:.74rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase}.number-pad{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;padding:14px;border:1px solid #293640;border-radius:28px;background:#151f27}.number-button{min-height:0;font-size:1.15rem}.number-spacer{min-height:0}.happy-section{display:flex;width:100%;justify-content:center;margin-top:4px}.happy-button{position:relative;display:grid;width:min(100%,max(0px,calc(100dvh - 15rem - var(--pad-size))));aspect-ratio:1;place-items:center;overflow:hidden;border:2px solid #34444f;border-radius:50%;background:#1a252e;color:inherit;cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;transition:transform .08s ease,background .12s ease,border-color .12s ease}.happy-button:hover{border-color:#536673;background:#202d37}.happy-button:active{transform:scale(.96);background:#2a3a45}.happy-button:disabled{cursor:default}.happy-button:disabled:active{transform:none}.happy-button:focus-visible{outline:3px solid var(--accent);outline-offset:3px}.happy-button img{display:block;width:88%;height:88%;object-fit:contain;object-position:center}.happy-timer{position:absolute;top:0;right:0;bottom:0;left:0;display:grid;place-items:center;background:#0b1718a8}.happy-timer svg{position:absolute;top:8%;right:8%;bottom:8%;left:8%;width:84%;height:84%;overflow:visible;transform:rotate(-90deg)}.timer-track,.timer-progress{fill:none;stroke-width:5}.timer-track{stroke:#b9ef4266}.timer-progress{stroke:#b7ed42;stroke-linecap:round;stroke-dasharray:283;filter:drop-shadow(0 0 5px #b7ed42aa)}.timer-label{display:grid;width:30%;aspect-ratio:1;place-items:center;border:2px solid #b7ed42;border-radius:50%;background:#101820ed;color:#d5ff7b;font-size:clamp(1.1rem,7vw,2rem);font-variant-numeric:tabular-nums;font-weight:800}.confirm-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:10;display:grid;place-items:center;padding:24px;background:#050b10c9}.confirm-dialog{width:min(100%,360px);padding:24px;border:1px solid #34444f;border-radius:24px;background:#1a252e;box-shadow:0 18px 60px #0009;text-align:center}.confirm-dialog h2{margin:0 0 12px;color:#f3f5f6;font-size:1.25rem;font-weight:750;letter-spacing:normal;text-transform:none}.confirm-title-image{display:block;width:100%;max-height:180px;margin:0 auto;object-fit:contain}.confirm-dialog p{margin:0;color:#c4cdd2;line-height:1.5}.confirm-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:22px}.confirm-actions button{min-height:48px;padding:0 12px;border:1px solid #34444f;border-radius:14px;background:#23313c;color:#f3f5f6;font:inherit;font-weight:700;cursor:pointer;touch-action:manipulation;transition:transform .08s ease,background .12s ease,border-color .12s ease}.confirm-actions button:hover{border-color:#536673;background:#2b3a45}.confirm-actions button:active{transform:scale(.96)}.confirm-actions button:focus-visible{outline:3px solid var(--accent);outline-offset:3px}.confirm-actions .confirm-yes{border-color:var(--accent);background:var(--accent);color:#16200d}.confirm-actions .confirm-yes:hover{border-color:#cff77e;background:#cff77e}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.01ms!important;transition-duration:.01ms!important}}@media(max-width:360px){.remote-shell{padding-right:16px;padding-left:16px}.xiaomi-back-button{font-size:.76rem}}
