:root{font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#142238;background:#f6f8fb;font-synthesis:none}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:wait}a{text-decoration:none;color:inherit}h1,h2,h3,p{margin-top:0}h1{letter-spacing:-.045em}h2{letter-spacing:-.035em}h3{font-size:1.1rem}.eyebrow{font-size:.68rem;letter-spacing:.15em;font-weight:750;color:#2387bf}.auth-shell{min-height:100vh;display:grid;grid-template-columns:1fr 440px;align-items:center;gap:5vw;padding:6vw;background:radial-gradient(ellipse at 12% 0%,#214f7d,transparent 57%),linear-gradient(130deg,#091c38,#0c3155 64%,#05172e);color:#fff}.hero-copy{max-width:650px}.hero-copy h1{font-size:clamp(2.9rem,5.5vw,5.5rem);font-weight:760;line-height:1.08;margin:22px 0}.hero-copy em{font-style:normal;color:#69cdfa}.hero-copy p{font-size:1.06rem;line-height:1.75;color:#bed2e5;max-width:450px}.pill{display:inline-block;margin-top:12px;padding:9px 16px;border:1px solid #487398;border-radius:22px;color:#bfe2fa;font-size:.8rem}.login-card{background:#fff;border-radius:24px;box-shadow:0 30px 80px #03112650;padding:35px;color:#142238}.mark,.logo{display:grid;place-items:center;color:#fff;font-size:22px;font-weight:800;background:linear-gradient(145deg,#167edc,#36bad8);width:44px;height:44px;border-radius:13px}.login-card h2{font-size:1.6rem;margin:24px 0 8px}.login-card p,.login-card small{color:#6e7e93;line-height:1.5}.login-card small{font-size:.73rem;display:block;margin-top:20px}.login-card label{margin-top:18px}label{display:flex;flex-direction:column;gap:8px;color:#43516a;font-size:.82rem;font-weight:660;margin-bottom:15px}input:not([type="checkbox"]):not([type="file"]),select{width:100%;border:1px solid #d7e0ea;border-radius:10px;padding:13px 14px;background:#fff;color:#15253b;outline:none;min-width:0}input:focus,select:focus{border-color:#2789cf;box-shadow:0 0 0 3px #b9e2fc65}.primary,.ghost,.white-button{padding:12px 18px;border-radius:10px;font-weight:700;transition:background .2s;border:0}.primary{background:#1164c7;color:#fff}.primary:hover{background:#094faa}.ghost{background:#edf3fa;color:#275681}.white-button{background:#fff;color:#174470}.text-btn{background:none;border:0;color:#aad1fb;padding:0;font-size:.82rem;text-align:left}.login-card .primary{width:100%;margin-top:5px}.notice{color:#3b587c;font-size:.82rem;padding:10px 0;min-height:25px}.notice.error,.global-message.error{color:#b72d3b}.global-message{padding:12px 16px;background:#e8f4fd;border:1px solid #b1d5f2;border-radius:10px;margin-bottom:18px}#panel{display:grid;grid-template-columns:238px minmax(0,1fr);min-height:100vh}.sidebar{background:#112742;color:#eff6fb;display:flex;flex-direction:column;padding:28px 16px;position:sticky;top:0;height:100vh}.brand{display:flex;align-items:center;gap:12px;margin:0 10px 36px;font-weight:800;font-size:1.1rem}.brand small{font-size:.65rem;color:#91bddd;display:block;font-weight:550}.logo{width:38px;height:38px;font-size:19px;border-radius:11px}.side-label{font-size:.64rem;color:#799fbd;letter-spacing:.14em;margin:14px 14px 10px;font-weight:750}.nav{border:0;border-radius:9px;background:transparent;color:#a9c6df;text-align:left;padding:12px 14px;display:flex;gap:13px;align-items:center;font-size:.87rem;margin:2px 0}.nav:hover{background:#1a3758}.nav.current{background:#1a4e81;color:#fff}.side-foot{margin-top:auto;border-top:1px solid #2c4966;padding:20px 12px 4px;font-size:.8rem;color:#dfebf6}.side-foot button{margin-top:9px}.main{padding:35px clamp(20px,5vw,76px) 28px;max-width:1530px;width:100%;margin:0 auto}.topbar{display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #e6ecf2;padding-bottom:22px;margin-bottom:28px}.topbar h1{font-size:2rem;margin:7px 0 0}.user-identity{font-size:.76rem;padding:9px 13px;border:1px solid #dce5ee;border-radius:30px;color:#476984;background:#fff}.intro-banner{background:linear-gradient(110deg,#164b82,#1679b3);border-radius:18px;padding:34px;color:#fff;display:flex;justify-content:space-between;align-items:center;gap:20px}.intro-banner .eyebrow{color:#92d8ff}.intro-banner h2{font-size:1.7rem;margin:10px 0}.intro-banner p{color:#bfddf2;margin:0;line-height:1.5}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:18px;margin:20px 0}.stats article,.panel-card{border:1px solid #e3eaf1;background:#fff;border-radius:16px;padding:24px}.stats article small{display:block;color:#78899f}.stats strong{font-size:2rem;display:block;margin-top:12px}.panel-card{margin-bottom:20px}.panel-card p{color:#63738b;line-height:1.6}.steps{display:grid;gap:12px;margin-top:20px}.steps div{border:1px solid #edf1f6;border-radius:10px;padding:16px;display:flex;align-items:center;gap:12px}.steps b{background:#e6f4ff;border-radius:9px;color:#1382ce;padding:9px}.footnote{font-size:.74rem;color:#8492a7!important;margin:12px 0 0}.view>h2,.heading-line h2{font-size:1.5rem;margin-bottom:5px}.heading-line{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:22px}.heading-line p,.description{color:#6c7d91;margin-bottom:0;font-size:.89rem}.upload-target{padding:40px 15px;text-align:center;background:#f8fbfe;border:2px dashed #c9dced;border-radius:15px;cursor:pointer;align-items:center}.upload-target span{font-size:.78rem;color:#7790a6;font-weight:450}.upload-target .upload-emoji{color:#1978c8;font-size:40px}.upload-target input{margin:10px auto 0;max-width:290px}.upload-card .primary{margin-top:12px}.upload-progress{display:flex;gap:10px;align-items:center;margin:15px 0}.meter{height:9px;background:#e2ebf5;flex:1;border-radius:99px;overflow:hidden}.meter i{display:block;width:0;height:100%;background:#1678ce;transition:width .2s}.video-list{display:grid;gap:7px}.video-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;border-bottom:1px solid #edf1f4;padding:14px 0}.video-row b{font-size:.9rem;overflow-wrap:anywhere}.video-row small{display:block;color:#78879c;margin-top:5px}.status{display:inline-block;border-radius:99px;padding:6px 10px;font-size:.73rem;background:#edf3f9;color:#536982}.status.ready{background:#e2f7e9;color:#137d43}.status.processing{background:#e8f3ff;color:#1c70b4}.status.failed{background:#ffe8ea;color:#a02934}.phone-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:14px;margin:18px 0}.phone-card{border-radius:16px;padding:26px;background:linear-gradient(145deg,#1b365e,#0b2445);color:#fff}.phone-card small{display:block;color:#a5bdd7;margin-top:9px}.check-row{flex-direction:row;align-items:center}.button-row{display:flex;gap:9px;flex-wrap:wrap}.admin-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:17px;margin:22px 0}.empty{color:#9babbc;padding:25px;text-align:center}.footer{color:#97a4b3;font-size:.68rem;padding:28px 0}@media(max-width:920px){.auth-shell{grid-template-columns:1fr;padding:32px 20px}.hero-copy h1{font-size:2.8rem}.login-card{max-width:480px}.sidebar{position:relative;height:auto;padding:16px;flex-direction:row;gap:8px;overflow-x:auto;align-items:center}.side-label,.side-foot,.brand small{display:none}.brand{margin:0 10px 0 0}.nav{white-space:nowrap}.nav span{display:none}#panel{display:block}.main{padding:18px}.intro-banner{align-items:flex-start;flex-direction:column}.stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.stats article{padding:15px}.stats strong{font-size:1.5rem}.admin-grid{grid-template-columns:1fr}.topbar h1{font-size:1.5rem}}@media(max-width:470px){.stats{grid-template-columns:1fr}.topbar .user-identity{display:none}}

/* Respeita o atributo hidden nos blocos com display:grid/flex */
[hidden] { display: none !important; }

.auto-refresh-note{font-size:.73rem!important;color:#788ba3!important;margin:4px 0 0!important}
.video-row-actions{display:flex;align-items:center;gap:10px;justify-content:flex-end;flex-wrap:wrap}
.ghost.small{padding:8px 12px;font-size:.78rem}
.conversion-progress{height:8px;width:min(420px,100%);overflow:hidden;border-radius:10px;background:#e1eaf6;margin-top:11px}
.conversion-progress i{display:block;height:100%;background:#2084d7;transition:width .6s linear}
.preview-dialog{width:min(95vw,630px);max-height:94vh;overflow-y:auto;padding:22px;border:1px solid #dce5ef;border-radius:18px;box-shadow:0 30px 85px #001b4380;background:#fff}
.preview-dialog::backdrop{background:#02162baf}
.preview-head{display:flex;align-items:center;justify-content:space-between;gap:16px}
.preview-head h3{margin:0;overflow-wrap:anywhere}
.preview-dialog video{width:100%;max-height:65vh;display:block;border-radius:12px;background:#101d2d}
@media(max-width:500px){.video-row{grid-template-columns:minmax(0,1fr)}.video-row-actions{justify-content:flex-start}.preview-dialog{padding:14px}}

/* Controle remoto Web H5 SDK */
.remote-layout{max-width:850px}.remote-panel{padding:22px}.remote-toolbar{display:flex;align-items:end;justify-content:space-between;gap:14px;flex-wrap:wrap}.remote-toolbar label{min-width:230px;flex:1;margin:0}.remote-toolbar .button-row{flex:1}.remote-status{font-size:.84rem;color:#315f89;background:#edf6ff;padding:12px 14px;border-radius:11px;margin:16px 0}.remote-status.error{color:#ad2435;background:#fff1f2}.remote-frame{border-radius:19px;background:#0b172b;padding:14px;display:flex;justify-content:center;min-height:460px}.remote-screen{background:#10151f;width:min(100%,440px);height:min(75vh,720px);min-height:460px;overflow:hidden;touch-action:none;border-radius:12px;position:relative}.remote-screen video,.remote-screen canvas{max-width:100%;}.remote-controls{display:flex;gap:10px;justify-content:center;flex-wrap:wrap;margin:16px 0}.remote-controls button{background:#eaf1fa;border:0;border-radius:9px;padding:12px 18px;font-weight:700;color:#1b507e}.remote-controls button:disabled{opacity:.5;cursor:not-allowed}.remote-input-label{margin-top:10px}.remote-input-row{display:flex;gap:9px}.remote-input-row input{flex:1}.remote-input-row button{white-space:nowrap}@media(max-width:620px){.remote-frame{padding:6px}.remote-screen{height:66vh;min-height:380px}.remote-toolbar{display:block}.remote-toolbar .button-row{margin-top:14px}}

/* Nuvem SaaS: contas com varios celulares e uma sessao ativa */
#panel{display:block;min-height:100vh;background:#f4f7fb}
.app-header{position:sticky;top:0;z-index:15;display:flex;justify-content:space-between;align-items:center;gap:20px;flex-wrap:wrap;background:#fff;border-bottom:1px solid #e3eaf3;padding:13px clamp(20px,3.5vw,58px);box-shadow:0 2px 12px #163b5908}
.app-brand{display:flex;align-items:center;gap:10px;white-space:nowrap;color:#142c46}.app-brand .logo{width:42px;height:42px}.app-brand strong{display:block;font-size:1.07rem}.app-brand small{display:block;color:#7d90a5;font-size:.73rem}
.app-nav{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.app-nav .nav{color:#506886;padding:11px 16px;border-radius:10px;background:#fff;margin:0;font-weight:700;white-space:nowrap}.app-nav .nav.current{color:#0b63b8;background:#eaf5ff}.app-nav .nav:hover{color:#076abf;background:#edf5fc}
.app-account{display:flex;align-items:center;gap:14px;white-space:nowrap;color:#56718b;font-size:.73rem}.app-account .ghost{padding:9px 14px}
.main{padding:35px clamp(16px,4vw,70px);max-width:1540px}.topbar{margin-bottom:22px}.topbar h1{font-size:1.7rem}
.home-heading{display:flex;gap:20px;align-items:center;justify-content:space-between;margin:12px 0 16px}.home-heading h2{font-size:2rem;margin:5px 0}.home-heading p{font-size:.88rem;color:#647e96;margin:0}
.account-stats{display:flex;gap:12px;margin:15px 0 26px;flex-wrap:wrap}.account-stats div{padding:13px 20px;background:#fff;border:1px solid #e3eaf3;border-radius:14px;display:flex;align-items:center;gap:16px}.account-stats small{color:#7b8ea3;font-size:.75rem}.account-stats strong{font-size:1.3rem;color:#153c65}
.phones-home{display:grid;grid-template-columns:repeat(auto-fill,minmax(190px,1fr));gap:18px}.phone-tile{display:flex;flex-direction:column;gap:5px;align-items:center;background:white;border:1px solid #dae5f1;border-radius:19px;padding:22px 14px 19px;text-align:center;color:#1a354f;transition:transform .15s,box-shadow .15s;min-height:375px;box-shadow:0 6px 18px #102c4906}.phone-tile:hover{transform:translateY(-3px);box-shadow:0 15px 25px #173c5c15}
.tile-phone{background:#0a1423;border-radius:21px;padding:9px 8px 10px;width:141px;height:263px;display:flex;align-items:center;flex-direction:column;box-shadow:0 8px 20px #121d2a26}.tile-earpiece{height:5px;width:30px;border-radius:10px;background:#5b6371;margin:1px 0 6px}.tile-screen{flex:1;overflow:hidden;background:linear-gradient(140deg,#6eb2f6,#bedbff);width:100%;border-radius:5px;display:grid;place-items:center}.tile-screen img{height:100%;width:100%;object-fit:contain}.tile-bottom{font-size:.73rem;color:#bcc8d5;letter-spacing:2px;margin-top:6px}.phone-tile strong{margin-top:6px;font-size:.96rem}.phone-tile small{color:#8493a6;font-size:.68rem}.tile-cta{background:#ecf5ff;border-radius:99px;color:#0d69bd;font-weight:700;font-size:.75rem;padding:8px 16px;margin-top:6px}.no-snapshot{display:flex;align-items:center;justify-content:center;flex-direction:column;padding:12px;gap:8px;color:#275e90;line-height:1.4}.no-snapshot span{font-size:2rem}.no-snapshot small{color:#315779;font-size:.68rem}.home-hint{color:#7890a4;font-size:.8rem;margin:20px 0}
.device-top{display:flex;align-items:center;gap:18px;margin-bottom:24px;flex-wrap:wrap}.device-top h2{font-size:1.55rem;margin:4px 0}.device-live-hint{margin-left:auto;font-size:.75rem;color:#4c7b92;background:#e6f5f9;border-radius:99px;padding:9px 14px}.online-dot{width:7px;height:7px;border-radius:50%;background:#34ad99;display:inline-block;margin-right:5px}
.device-workspace{display:grid;grid-template-columns:minmax(340px,520px) minmax(320px,1fr);gap:20px;align-items:start}.device-left,.device-tools,.future-comments{background:#fff;border:1px solid #e3ebf4;border-radius:18px;padding:20px}.device-left{display:flex;flex-direction:column;align-items:center}.device-connection{width:100%;max-width:410px}.remote-status{font-size:.75rem;margin:0 0 10px;padding:10px 12px}.device-connection .button-row{justify-content:center;margin-bottom:13px}
.phone-shell{background:#0a111d;padding:14px 9px 6px;border:5px solid #1c2c40;box-shadow:inset 0 0 0 1px #435369,0 15px 38px #081a3555;border-radius:34px;width:fit-content;max-width:100%;display:flex;align-items:center;flex-direction:column}.phone-top{width:100%;height:18px;display:flex;justify-content:center;align-items:center;gap:10px}.speaker{width:55px;height:5px;background:#526174;border-radius:10px}.front-camera{width:9px;height:9px;background:#203956;border:2px solid #54657a;border-radius:50%}
.phone-shell #remote-screen{width:min(100%,310px);height:550px;min-height:0;overflow:hidden;border-radius:6px;background:#0b121f;position:relative;touch-action:none}.phone-shell #remote-screen video,.phone-shell #remote-screen canvas{max-width:100%;max-height:100%;object-fit:contain}.phone-wait{color:#94aac2;font-size:.8rem;text-align:center;padding-top:45%}
.android-keys{height:47px;width:100%;display:flex;justify-content:space-evenly;align-items:center}.android-keys button{width:52px;height:43px;color:#ecf4fc;background:transparent;border:0;display:flex;align-items:center;justify-content:center;font-size:28px}.android-keys button:disabled{opacity:.38}.android-circle{width:19px;height:19px;border:2px solid #eef2fa;border-radius:50%}.android-square{width:17px;height:17px;border:2px solid #eef2fa;border-radius:3px}
.device-right{display:grid;gap:16px}.device-tools h3,.future-comments h3{margin:6px 0}.card-heading p{font-size:.79rem;color:#78899b;line-height:1.6;margin-bottom:16px}.device-tools .button-row{margin:8px 0}.device-tools .check-row{margin:14px 0}.small-link{background:none;border:0;color:#0765b0;padding:8px 0;font-weight:700;text-decoration:underline;text-align:left}.device-tools input[type="file"]{width:100%;font-size:.76rem;margin:3px 0 14px}.future-comments{background:#f8fbfe;border-style:dashed}.future-comments p{margin:0;color:#8594a3;font-size:.79rem}.detail-progress{height:12px;background:#e8f1fa;border-radius:99px;margin:10px 0 14px;position:relative;overflow:visible}.detail-progress i{height:100%;width:0;background:#1684c9;display:block;border-radius:99px}.detail-progress span{position:absolute;right:0;top:-20px;font-size:.67rem;color:#2b7094}
@media(max-width:920px){.app-header{position:relative;display:grid;grid-template-columns:1fr;gap:12px}.app-nav{overflow-x:auto;flex-wrap:nowrap}.app-account{justify-content:space-between}.device-workspace{grid-template-columns:1fr}.device-left{max-width:100%}.phone-shell #remote-screen{height:520px}.home-heading{align-items:flex-start;flex-direction:column}}
@media(max-width:480px){.phones-home{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.phone-tile{padding:10px 5px;min-height:310px}.tile-phone{width:120px;height:224px}.home-heading h2{font-size:1.6rem}.account-stats div{flex:1 1 100%;justify-content:space-between}.phone-shell #remote-screen{height:490px}.device-left{padding:14px}.app-nav .nav{padding:10px;font-size:.78rem}}

/* Ajuste do stream do Android: preservar a proporcao V04 sem cortar a tela */
.phone-shell{padding:10px 7px 4px;border-width:4px;border-radius:27px;max-width:100%;}
.phone-shell .phone-top{height:16px}
.phone-shell #remote-screen{width:min(100%,245px);height:auto;aspect-ratio:9 / 20;min-height:0;max-height:none;border-radius:5px;flex:none;display:block;overflow:hidden;position:relative;background:#0c1728}
.phone-shell #remote-screen>div:not(.phone-wait){width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;box-sizing:border-box}
.phone-shell #remote-screen video,.phone-shell #remote-screen canvas{display:block;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;object-fit:contain!important;box-sizing:border-box}
.phone-shell .android-keys{height:43px}
.camera-state{display:flex;align-items:center;gap:9px;background:#eef4fa;color:#506d88;border-radius:10px;padding:11px 13px;font-size:.8rem;font-weight:650;margin:10px 0 14px}
.camera-state-dot{width:9px;height:9px;background:#8ca4bb;border-radius:50%;flex:none}
.camera-state[data-state="live"]{background:#e8f8ef;color:#1c7647}.camera-state[data-state="live"] .camera-state-dot{background:#20ac66;box-shadow:0 0 0 3px #20ac661f}
.camera-state[data-state="offline"]{background:#eff3f8;color:#52677f}
.camera-state[data-state="timeout"]{background:#fff5e6;color:#946323}
@media(max-width:920px){.phone-shell #remote-screen{width:min(100%,245px);height:auto;max-height:none}}
@media(max-width:480px){.phone-shell #remote-screen{width:min(100%,225px);height:auto;max-height:none}}

/* Corrige a tela espelhada deslocada: placeholder não participa do fluxo do player. */
.phone-shell #remote-screen .phone-wait{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;padding:0!important;pointer-events:none;z-index:1;}
.phone-shell #remote-screen>div:not(.phone-wait){margin-top:0!important;}

/* Interface compacta: apenas uma transmissão ativa e loading direto dentro do Android */
.device-workspace{grid-template-columns:minmax(270px,405px) minmax(0,1fr)}
.phone-shell{padding:10px 7px 4px;border-radius:27px}
.phone-shell #remote-screen{width:min(100%,210px);height:auto;aspect-ratio:9 / 20;min-height:0;max-height:none}
.device-connection[hidden]{display:none!important}
.remote-loading{position:absolute;inset:0;z-index:8;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:13px;background:linear-gradient(160deg,#122743,#091829);color:#eef6ff;text-align:center;padding:20px;pointer-events:none}
.remote-loading[hidden]{display:none!important}
.remote-loading strong{font-size:.81rem;line-height:1.6;font-weight:600;max-width:190px}
.remote-spinner{width:35px;height:35px;border:3px solid #719ec44a;border-top-color:#80d3ff;border-radius:50%;animation:spin-vmos 900ms linear infinite}
.remote-loading[data-error="true"] .remote-spinner{display:none}
.remote-retry{pointer-events:auto;border:1px solid #6ba6d8;background:#184673;color:#fff;border-radius:9px;padding:9px 13px;font-size:.78rem;font-weight:700}
.remote-retry[hidden]{display:none!important}
@keyframes spin-vmos{to{transform:rotate(360deg)}}
.camera-state[data-state="pending"]{background:#e8f4ff;color:#14568a}
.camera-state[data-state="pending"] .camera-state-dot{width:15px;height:15px;border:2px solid #b9d5ed;border-top-color:#0c7fbe;background:transparent;animation:spin-vmos 800ms linear infinite}
@media(max-width:920px){.device-workspace{grid-template-columns:1fr}.phone-shell #remote-screen{width:min(100%,210px);height:auto}}
@media(max-width:480px){.phone-shell #remote-screen{width:min(100%,198px);height:auto}}

/* Tela do V04: proporção útil do Android sem faixas verticais excedentes */
.phone-shell #remote-screen{width:min(100%,210px);aspect-ratio:9 / 16;height:auto;min-height:0;max-height:none}
@media(max-width:920px){.phone-shell #remote-screen{aspect-ratio:9 / 16;height:auto}}
@media(max-width:480px){.phone-shell #remote-screen{width:min(100%,198px);aspect-ratio:9 / 16;height:auto}}
/* Estado inicial: aguarda dados reais da VMOS antes de permitir comandos */
.camera-loading{display:flex;align-items:center;gap:14px;background:#eef5fc;border:1px solid #d9e8f6;border-radius:13px;padding:23px 20px;margin:16px 0;color:#1e5c8f;min-height:112px}
.camera-loading[hidden],#camera-controls[hidden]{display:none!important}
.camera-loading-spinner{width:27px;height:27px;border:3px solid #bad5ee;border-top-color:#1678ce;border-radius:50%;flex:none;animation:spin-vmos .85s linear infinite}
.camera-loading strong{display:block;font-size:.9rem;line-height:1.45}
.camera-loading small{display:block;margin-top:6px;font-size:.76rem;color:#6589a6;line-height:1.5}

/* Area de aparelho: video à esquerda, telefone centralizado, direita livre para futuros recursos */
@media (min-width:1181px){
 .device-workspace{display:grid;grid-template-columns:minmax(280px,1fr) minmax(360px,410px) minmax(280px,1fr);column-gap:22px;align-items:start;width:100%}
 .device-workspace>.device-left{grid-column:2;grid-row:1;justify-self:center;width:100%}
 .device-workspace>.device-right{grid-column:1;grid-row:1;min-width:0;width:100%}
}
@media (min-width:801px) and (max-width:1180px){
 .device-workspace{display:grid;grid-template-columns:minmax(260px,1fr) minmax(350px,1fr);gap:18px;align-items:start}
 .device-workspace>.device-left{grid-column:2;grid-row:1;min-width:0}
 .device-workspace>.device-right{grid-column:1;grid-row:1;min-width:0}
}
.device-workspace>.device-left{display:flex;flex-direction:column;align-items:center}
.device-workspace .phone-shell{margin-inline:auto;width:fit-content}
.device-workspace .phone-shell #remote-screen{width:min(100%,300px);aspect-ratio:9 / 16;height:auto;min-height:0;max-height:none}
.device-workspace .device-right{display:block}
.device-workspace .device-right .device-tools{width:100%}
@media(max-width:800px){
 .device-workspace{display:flex;flex-direction:column;align-items:stretch;gap:17px}
 .device-workspace>.device-left{order:1;width:100%}
 .device-workspace>.device-right{order:2;width:100%}
}
@media(max-width:480px){
 .device-workspace .phone-shell #remote-screen{width:min(100%,255px);aspect-ratio:9 / 16;height:auto}
}

/* Captura toques/clicks na superfície do Android, não no mockup nem nos botões. */
/* O SDK da VMOS recebe toque diretamente no player; sem camada interceptadora. */
.phone-shell #remote-screen .remote-loading{z-index:8}
.install-button{padding:9px 14px;border:1px solid #b9d9ee;background:#e9f5fc;color:#115a91;border-radius:10px;font-weight:700;white-space:nowrap}
.install-button[hidden]{display:none!important}
.login-card .install-button{margin-top:12px;width:100%}

/* Boot do PWA: evita exibir login por instantes enquanto restaura a sessão */
.boot-screen{position:fixed;inset:0;z-index:999;background:linear-gradient(145deg,#0b2341,#153f68);display:flex;align-items:center;justify-content:center;padding:24px;color:#fff}
.boot-screen[hidden]{display:none!important}
.boot-center{display:flex;flex-direction:column;align-items:center;text-align:center;gap:12px}
.boot-logo{width:58px;height:58px;border-radius:19px;background:linear-gradient(135deg,#1179c8,#58c5ea);display:grid;place-items:center;font-weight:800;font-size:28px;box-shadow:0 12px 30px #06172a40}
.boot-spinner{border-radius:50%;width:26px;height:26px;border:3px solid #ffffff3b;border-top-color:#fff;animation:boot-spin .8s linear infinite;margin:10px 0}
.boot-center strong{font-size:1rem;font-weight:700}.boot-center span{font-size:.8rem;color:#c5def3}
@keyframes boot-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.boot-spinner{animation:none;border-top-color:#ffffffb3}}

/* Apenas Android/mobile: controle por coordenadas CSS locais, sem afetar mouse no computador. */
.phone-shell #remote-screen .mobile-touch-zone{position:absolute;inset:0;z-index:7;background:transparent;touch-action:none;pointer-events:auto;user-select:none;-webkit-user-select:none}
.phone-shell #remote-screen .remote-loading{z-index:8}

/* Selecao ordenada e bloqueio da fila */
.queue-title{display:flex;justify-content:space-between;gap:12px;align-items:center;margin:13px 0 9px}
.queue-title strong{font-size:.87rem}.queue-title span{font-size:.72rem;color:#6a87a2}
.queue-list{display:flex;flex-direction:column;gap:7px;max-height:315px;overflow:auto;padding:2px}
.queue-row{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px;border:1px solid #dfe8f0;border-radius:10px;background:#fff}
.queue-row.selected{border-color:#88b9df;background:#eff7fe}
.queue-row>label{display:flex;align-items:flex-start;gap:8px;flex:1;min-width:0;margin:0;cursor:pointer}
.queue-row>label input{flex:none;margin-top:4px;accent-color:#087bce}
.queue-row>label span{overflow-wrap:anywhere;min-width:0;font-size:.76rem;font-weight:650}
.queue-row>label span small{display:block;font-weight:400;color:#738aa0;font-size:.67rem;margin-top:3px}
.queue-move{display:flex;gap:3px;align-items:center;flex:none}
.queue-move b{font-size:.72rem;color:#3974a0}
.queue-move button{border:0;border-radius:6px;width:26px;height:28px;background:#e5eef7;color:#1a608f;cursor:pointer}
.queue-move button:disabled{opacity:.3;cursor:not-allowed}
.queue-lock{font-size:.74rem;color:#285b89;background:#eff5fa;padding:9px 12px;border-radius:8px}
.queue-lock[hidden]{display:none!important}
.queue-offset{display:flex;flex-direction:column;gap:7px;font-size:.8rem;margin:13px 0 6px;font-weight:650}
.queue-offset input{max-width:150px;font-size:.88rem;font-variant-numeric:tabular-nums}
.queue-help{font-size:.71rem;color:#647d96;line-height:1.5;display:block;margin:0 0 13px}
.queue-help[data-state="unavailable"],.queue-help[data-state="invalid"]{color:#97622a}

/* Estado da resposta ao toque: só aparece no aparelho físico (coarse pointer). */
.mobile-touch-speed{display:flex;align-items:center;justify-content:center;gap:8px;flex-wrap:wrap;font-size:.72rem;color:#48627e;text-align:center;padding:8px 3px 0}
.mobile-touch-speed[hidden],#mobile-touch-toggle[hidden]{display:none!important}
.mobile-touch-indicator{height:7px;width:7px;border-radius:50%;background:#44a7d4;flex:none}
#mobile-touch-toggle{border:0;background:transparent;color:#075d9f;text-decoration:underline;font-size:.72rem;cursor:pointer;padding:4px 3px}
@media(pointer:fine){.mobile-touch-speed{display:none!important}}

/* Exclusão confirmada de arquivo: biblioteca pessoal, inclusive uploads pendentes. */
.video-delete-btn{padding:7px 11px;background:#fff3f3;border:1px solid #edcaca;border-radius:8px;color:#aa2631;font-weight:700;font-size:.73rem;cursor:pointer;white-space:nowrap}
.video-delete-btn:hover{background:#ffe5e6}
.video-delete-btn:disabled{opacity:.55;cursor:wait}
@media(max-width:620px){.video-row-actions{flex-wrap:wrap;gap:6px}.video-delete-btn{min-height:32px}}

/* Prévia independente da sequência; a câmera conserva a estimativa existente. */
.queue-preview-panel{margin:12px 0 17px;padding:14px 13px 12px;border:1px solid #deebf6;background:#f7fbff;border-radius:12px}
.queue-preview-heading{display:flex;gap:8px;align-items:center;justify-content:space-between;flex-wrap:wrap;margin-bottom:12px}
.queue-preview-heading strong{font-size:.8rem;color:#244c72}
.queue-preview-heading span{font-size:.77rem;white-space:nowrap;color:#0c609a;font-variant-numeric:tabular-nums;font-weight:750}
.queue-preview{display:block;width:min(100%,240px);max-height:275px;aspect-ratio:9 / 16;object-fit:contain;background:#08121e;margin:12px auto 6px;border-radius:9px}
.queue-preview[hidden]{display:none!important}
.queue-preview-note{display:block;text-align:center;font-size:.7rem;color:#647f98;line-height:1.45;margin:8px 0}
.queue-help{display:block;margin-top:8px}
.queue-playing{margin:12px 0 17px;padding:13px;border:1px solid #b8dce8;background:#f3fafc;border-radius:11px}
.queue-playing[hidden]{display:none!important}
.queue-playing-head{display:flex;gap:8px;align-items:center;justify-content:space-between;margin-bottom:10px}
.queue-playing-head strong{font-size:.84rem}
.queue-playing-tag{font-size:.64rem;letter-spacing:.06em;font-weight:800;background:#d3e9f5;color:#266383;border-radius:5px;padding:3px 7px}
#queue-playing-title{display:block;font-size:.78rem;overflow-wrap:anywhere;margin:4px 0 8px}
.queue-playing-time{text-align:right;color:#25638c;font-size:.79rem;font-variant-numeric:tabular-nums;font-weight:750}
.queue-playing progress{display:block;width:100%;height:11px;accent-color:#1689c9;margin:7px 0 9px}
.queue-playing small{display:block;font-size:.71rem;line-height:1.5;color:#567f95}

/* Diagnóstico passivo do retorno WebRTC (não confundir com LIVE TikTok). */
.diag-panel{background:#fff;border:1px solid #deebf5;border-radius:16px;margin-top:16px;padding:16px;box-shadow:0 5px 18px #0e284910}
.diag-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:8px;flex-wrap:wrap}
.diag-head h3{font-size:1rem;margin:3px 0 0;color:#143c65}
.diag-status{font-size:.7rem;padding:6px 9px;border-radius:20px;background:#edf1f5;color:#53708a;font-weight:750}
.diag-status[data-state="connected"]{background:#e5f8ed;color:#24794c}
.diag-intro{font-size:.74rem;color:#61788b;line-height:1.6;margin:5px 0 13px}
.diag-kpis{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.diag-kpis>div{min-width:0;border:1px solid #edf2f7;background:#f8fbfe;padding:9px;border-radius:9px}
.diag-kpis small{display:block;font-size:.65rem;color:#627f9a;margin-bottom:6px;line-height:1.3}
.diag-kpis strong{display:block;font-size:1rem;color:#143d65;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
.diag-state{border:1px solid #e0edf6;border-radius:10px;background:#f8fbff;padding:10px;margin:12px 0;display:flex;flex-direction:column;gap:5px}
#diag-quality{font-size:.75rem;line-height:1.5;color:#28577c}
#diag-last{font-size:.68rem;color:#6685a0}
.diag-bars-head{display:flex;justify-content:space-between;gap:8px;align-items:center;font-size:.73rem;color:#2e5d83;margin:13px 0 8px}
#diag-bars-label{font-size:.67rem;color:#728ba0}
.diag-fps-bars{height:55px;background:linear-gradient(to bottom,#f5f9fc,#eef5fb);border:1px solid #e3edf5;border-radius:8px;padding:4px;display:flex;align-items:flex-end;gap:2px;overflow:hidden}
.diag-fps-bars span{display:block;flex:1;min-width:2px;max-width:14px;background:#45a0d3;border-radius:2px 2px 0 0}
.diag-fps-bars span[data-state="alert"]{background:#db9e4b}
.diag-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}
.diag-actions button{font-size:.72rem;min-height:34px;white-space:normal;text-align:center}
.diag-details{font-size:.73rem;margin-top:14px;color:#647b90}
.diag-details summary{cursor:pointer;color:#226a9f;font-weight:700}
.diag-details p{line-height:1.55;margin:9px 0}
.diag-history{display:flex;flex-direction:column;gap:5px;max-height:140px;overflow:auto;margin:9px 0}
.diag-history>div{padding:7px;background:#f4f8fc;border-radius:5px;color:#476b86;font-size:.7rem}
#diag-feedback{margin-top:10px}
@media(max-width:450px){.diag-panel{padding:12px}.diag-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.diag-kpis strong{font-size:.94rem}}

/* Planejamento e envio do original; a preparação acontece no conversor. */
.converter-status{padding:16px 18px;margin-bottom:18px;border:1px solid #c9ddec;border-radius:12px;background:#f2f8fd;color:#244c72}
.converter-status strong{display:block;font-size:.9rem}.converter-status p{margin:6px 0 0;font-size:.8rem;line-height:1.55;color:inherit}
.converter-status[data-state="ready"]{background:#edf8f1;border-color:#bedfca;color:#246440}
.converter-status[data-state="pending"]{background:#fff8e9;border-color:#edd9a5;color:#795618}
.converter-status[data-state="error"]{background:#fff1f1;border-color:#ecc5c5;color:#962e38}
.upload-transfer{padding:15px;background:#f3f8fe;border:1px solid #dce9f4;border-radius:12px;margin:16px 0}
.upload-transfer>strong{display:block;overflow-wrap:anywhere;font-size:.86rem}.upload-transfer .upload-progress{margin:12px 0}
.upload-transfer-note{font-size:.8rem;margin:8px 0 12px!important;line-height:1.5}.upload-transfer[data-state="failed"]{border-color:#e4bbc0;background:#fff6f6}
.upload-card .button-row{align-items:center;gap:10px}.upload-card .button-row .primary{margin:0}.upload-card input:disabled{cursor:not-allowed}
.converter-uploads{display:grid;gap:12px}.converter-upload{border:1px solid #dfe9f1;border-radius:12px;padding:16px;background:#fbfdff}
.converter-upload-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.converter-upload-head strong{font-size:.9rem;overflow-wrap:anywhere;min-width:0}.converter-upload-head .status{flex-shrink:0}
.converter-upload-meta,.converter-upload-note{font-size:.78rem;line-height:1.55;color:#62768c;margin:7px 0 0!important}
.converter-upload .button-row{margin-top:12px}.converter-upload .button-row button{padding:9px 13px;font-size:.78rem}
.converter-upload .conversion-progress{width:100%}.converter-upload-error{font-size:.78rem;color:#a12d3c;margin:9px 0 0;overflow-wrap:anywhere}
.converter-part-summary{font-size:.78rem;margin-top:10px;color:#38647b}.converter-part-summary summary{cursor:pointer;font-weight:650}
.converter-part-summary ol{padding-left:22px;margin:9px 0 0}.converter-part-summary li{margin:7px 0;overflow-wrap:anywhere;line-height:1.5}
.converter-part-badge{display:inline-block;font-size:.68rem;font-weight:700;background:#e6f3fb;border-radius:5px;padding:3px 6px;color:#236385;margin:0 0 5px}
.status.awaiting-plan{background:#fff1d3;color:#795415}.status.cancelled{background:#edf0f3;color:#5c6978}
.upload-plan-dialog{width:min(95vw,640px);max-height:92vh;overflow-y:auto;padding:26px;border:1px solid #d6e3ee;border-radius:20px;background:#fff;color:#18334f;box-shadow:0 30px 85px #001b4380}
.upload-plan-dialog::backdrop{background:#02162bb0}.upload-plan-dialog h3{margin:0}.upload-plan-dialog #upload-plan-intro{font-size:.86rem;line-height:1.5;color:#5f748b}
.upload-plan-facts{display:grid;grid-template-columns:1fr 1fr;gap:14px;background:#f5f9fd;border:1px solid #e2edf6;padding:16px;border-radius:12px;margin:18px 0}
.upload-plan-facts .plan-file{grid-column:1/-1}.upload-plan-facts dt{font-size:.72rem;color:#6c8298;margin-bottom:5px}.upload-plan-facts dd{margin:0;font-size:.9rem;font-weight:650;overflow-wrap:anywhere}
#upload-plan-choice label{margin:0;max-width:240px}#upload-plan-choice input{font-size:1.1rem;font-weight:700;max-width:140px}#upload-plan-choice .footnote{line-height:1.5;margin:9px 0 2px}
.upload-plan-estimates{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:16px 0}.upload-plan-estimates>div{padding:13px;background:#edf6fc;border-radius:10px}
.upload-plan-estimates small{display:block;font-size:.72rem;line-height:1.4;color:#58778e;margin-bottom:8px}.upload-plan-estimates strong{font-size:1.05rem;font-variant-numeric:tabular-nums;color:#245a7a}
.plan-explanation{font-size:.79rem;line-height:1.6;color:#5c7488;background:#f6f8fb;border-left:3px solid #a6c8df;padding:12px 14px;border-radius:5px;margin:14px 0}
.plan-actions{margin-top:14px}.plan-actions .primary{flex:1}.upload-plan-dialog button:disabled,.upload-card button:disabled{cursor:not-allowed}
@media(max-width:520px){.upload-plan-dialog{padding:18px}.upload-plan-facts,.upload-plan-estimates{gap:10px}.converter-upload{padding:13px}.converter-upload-head{flex-direction:column;gap:8px}.plan-actions{flex-direction:column}.plan-actions button{width:100%}.upload-card .button-row{align-items:stretch;flex-direction:column}.upload-target{padding:25px 12px}}
/* Organização da biblioteca: os filtros não alteram a sequência da câmera. */
.library-toolbar{display:flex;gap:12px;align-items:flex-end;flex-wrap:wrap}
.library-toolbar>label{margin:0;min-width:180px;flex:1;font-size:.82rem}
.library-toolbar>.library-search{flex:1.6}
.library-toolbar>button{flex:none;margin-bottom:0;min-height:44px}
.library-toolbar input,.library-toolbar select{margin-top:6px}
.library-folder-line{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin:8px 0 14px}
.library-folder-line p{margin:0;font-size:.76rem}
.library-folder-line .button-row{gap:13px}
.library-folder-line .small-link{font-size:.75rem;padding:5px 0}
.library-selection-bar{display:flex;align-items:center;gap:10px 15px;flex-wrap:wrap;padding:12px 14px;background:#f4f8fc;border:1px solid #e0eaf3;border-radius:10px;margin:0 0 8px}
.library-selection-bar .check-row{margin:0;font-size:.77rem;white-space:nowrap}
.library-selection-bar>span{font-size:.75rem;color:#546f8a}
.library-selection-bar>.button-row{margin-left:auto;align-items:center}
.library-selection-bar .small-link{font-size:.75rem}
.library-video-main{display:flex;gap:12px;align-items:flex-start;min-width:0}
.library-video-main>input{width:17px;height:17px;flex:none;margin-top:4px;accent-color:#087bce;cursor:pointer}
.library-video-copy{min-width:0;flex:1}
.library-video-copy .library-original-name{font-size:.7rem;overflow-wrap:anywhere;color:#7c8fa2}
.library-folder-badge{display:inline-block!important;width:fit-content;color:#397096!important;background:#edf5fb;border-radius:5px;padding:3px 7px;margin-top:7px!important;font-size:.67rem!important}
.video-row.is-library-selected{background:#f5faff;border-radius:8px;padding-left:10px;padding-right:10px}
.library-saved{margin-top:20px;border-top:1px solid #e3eaf1;padding-top:17px}
.library-saved>summary{cursor:pointer;font-size:.87rem;font-weight:750;color:#244c72}
.library-saved>summary span{display:inline-flex;align-items:center;justify-content:center;min-width:22px;height:22px;border-radius:11px;background:#eaf3fa;font-size:.72rem;margin-left:6px}
.library-saved>.footnote{font-size:.75rem;margin:9px 0 14px}
.library-playlists{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,250px),1fr));gap:11px}
.library-playlist{padding:14px;border:1px solid #e0eaf3;border-radius:11px;background:#f9fcff;min-width:0}
.library-playlist strong{font-size:.85rem;overflow-wrap:anywhere}
.library-playlist ol{padding-left:20px;margin:10px 0 13px;color:#5c738b;font-size:.74rem;line-height:1.6}
.library-playlist li{overflow-wrap:anywhere}
.library-playlist .button-row{gap:12px}
.library-playlist .small-link{padding:3px 0;font-size:.73rem}
.queue-organizer{padding:11px;border:1px solid #e0eaf3;border-radius:10px;background:#f9fcff;margin-top:15px}
.queue-folder-tools,.queue-playlist-tools{display:flex;gap:8px;align-items:flex-end}
.queue-organizer label{font-size:.73rem;margin:0;flex:1;min-width:0}
.queue-organizer select,.queue-organizer input{font-size:.76rem;min-width:0;width:100%;padding:9px 10px;margin-top:5px;min-height:37px}
.queue-organizer button{padding:10px 11px;white-space:nowrap;font-size:.72rem;min-height:37px;flex:none}
.queue-search{display:block;margin:8px 0 12px!important}
.queue-save-row{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;margin:9px 0 0}
.queue-save-row .small-link{font-size:.72rem;padding:6px 0}
.queue-save-row small{color:#738aa0;font-size:.66rem;line-height:1.45}
.queue-organizer .notice{font-size:.72rem;margin:10px 0 0;line-height:1.5}
.queue-filter-caption{color:#698199;font-size:.7rem;margin:5px 2px 2px}
.library-dialog{border:1px solid #dce7f0;border-radius:17px;box-shadow:0 25px 80px #10243b33;padding:23px;width:min(580px,calc(100vw - 28px));max-height:calc(100dvh - 36px);overflow:auto;color:#20374e}
.library-dialog::backdrop{background:#152b4670;backdrop-filter:blur(3px)}
.library-dialog form{margin:0}
.library-dialog .preview-head{gap:12px;align-items:flex-start}
.library-dialog .preview-head h3{font-size:1.1rem;line-height:1.35;margin:0}
.library-dialog .preview-head button{padding:8px 12px;flex:none;font-size:.77rem}
.library-dialog-description{font-size:.85rem;color:#647b92;line-height:1.6;margin:15px 0}
.library-dialog>form>label{font-size:.83rem;margin:15px 0}
.library-dialog input[type=text],.library-dialog select{margin-top:6px}
.library-dialog-items{display:grid;gap:7px;margin:15px 0;max-height:300px;overflow:auto}
.library-dialog-item{display:flex;align-items:center;gap:10px;padding:9px 11px;border:1px solid #e1eaf2;border-radius:9px;background:#f8fbfe}
.library-dialog-item>span{flex:1;min-width:0;font-size:.8rem;overflow-wrap:anywhere}
.library-dialog-item>span>small{display:block;margin-top:4px;font-size:.7rem;color:#74899e}
.library-dialog-item>b{flex:none;color:#3974a0;font-size:.78rem;min-width:17px}
.library-dialog-item .queue-move{gap:4px}
.library-dialog-item .queue-move button{width:31px;height:32px}
.library-dialog .notice{font-size:.8rem;line-height:1.6}
.library-dialog-actions{justify-content:flex-end;margin-top:20px}
.library-dialog-actions button{min-height:43px}
.library-dialog [hidden],.library-card [hidden],.queue-organizer [hidden]{display:none!important}
.visually-hidden{position:absolute!important;width:1px!important;height:1px!important;margin:-1px!important;padding:0!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
@media(max-width:650px){
 .library-toolbar>label{min-width:140px}.library-toolbar>.library-search{flex-basis:100%;order:3}
 .library-toolbar>button{min-height:44px;padding:11px 13px}
 .library-selection-bar{padding:11px;gap:10px}.library-selection-bar>.button-row{margin-left:0;flex-basis:100%}
 .library-selection-bar>.button-row button{font-size:.73rem}.library-video-main{gap:9px}
 .library-card .video-row-actions{padding-left:26px}.library-card .video-row-actions button{min-height:38px}
 .library-dialog{padding:18px}.library-dialog-actions button{flex:1}.library-dialog .preview-head h3{font-size:1rem}
}
@media(max-width:370px){.queue-folder-tools,.queue-playlist-tools{flex-wrap:wrap}.queue-organizer label{flex-basis:100%}.queue-organizer button{width:100%}.queue-move button{width:28px;height:32px}}
