/* softtech editor v19 — bottom tab bar layout (v20: black & white pro look) */
.screen.tab{padding-bottom:calc(64px + env(safe-area-inset-bottom))}
.stTabs{position:absolute;left:0;right:0;bottom:0;z-index:20;height:calc(64px + env(safe-area-inset-bottom));padding:0 4px env(safe-area-inset-bottom);display:none;background:rgba(14,14,18,.97);border-top:1px solid var(--line);backdrop-filter:blur(12px)}
body.tabsOn .stTabs{display:flex}
.stTabs button{flex:1;border:0;background:none;color:var(--mu);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;font:600 11px Heebo,system-ui,sans-serif;padding:6px 0 4px;position:relative;-webkit-tap-highlight-color:transparent}
.stTabs button i{display:grid;place-items:center;width:44px;height:28px;border-radius:14px;transition:background .15s}
.stTabs button i svg{width:23px;height:23px}
.stTabs button.on{color:#fff}
.stTabs button.on i{background:rgba(255,255,255,.16);color:var(--ac2)}
.stTabs button:active i{transform:scale(.92)}
.tabTtl{display:flex;flex-direction:column;line-height:1.15}.tabTtl b{font-size:19px;font-weight:800;letter-spacing:-.3px}.tabTtl small{font-size:12px;color:var(--mu)}
.screen.tab .scroll{padding-bottom:16px}
/* Home: one screen */
.homeBody{display:flex;flex-direction:column;overflow-y:auto}
.homeBody .hero{padding-top:4px}
.homeBody .newProj{padding:18px 16px}
.hTiles{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:12px}
.hT{display:flex;align-items:center;gap:10px;text-align:left;border:1px solid var(--line);background:var(--s1);border-radius:16px;padding:12px 10px;color:var(--tx);min-height:64px}
.hT:active{transform:scale(.98);background:var(--s2)}
.hT i{flex:0 0 auto;width:40px;height:40px;border-radius:12px;display:grid;place-items:center}
.hT i svg{width:23px;height:23px}
.hT b{display:block;font-size:14px;font-weight:700;line-height:1.2}.hT small{display:block;font-size:11.5px;color:var(--mu);margin-top:1px;line-height:1.25}
.hT.t1 i{background:rgba(255,255,255,.18);color:#c9c9ce}.hT.t2 i{background:rgba(255,255,255,.16);color:var(--ac2)}.hT.t3 i{background:rgba(255,255,255,.16);color:#e6e6ea}.hT.t4 i{background:rgba(62,207,142,.15);color:#3ecf8e}
.hHead{display:flex;align-items:baseline;justify-content:space-between;margin:18px 0 10px}.hHead .sec{margin:0}
.seeAll{border:0;background:none;color:var(--ac2);font:600 13.5px Heebo,system-ui,sans-serif;padding:4px 0}
.projEmpty{width:100%;border:1px dashed #34343f;background:var(--s1);border-radius:14px;padding:18px 14px;color:var(--tx);text-align:left}
.projEmpty b{display:block;font-size:14px}.projEmpty small{display:block;color:var(--mu);font-size:12.5px;margin-top:3px}
.homeBody #vtWrap .sec{margin:18px 0 10px}
.homeBody #vtWrap.slim .vtCard canvas{width:92px;height:164px}.homeBody #vtWrap.slim .vtCard{width:92px}
.projIt .projDel{position:absolute;top:5px;right:5px;width:26px;height:26px;border-radius:50%;border:0;background:rgba(0,0,0,.6);color:#fff;font-size:12px}
/* Projects tab */
.projGrid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-top:14px}
.projGrid .projIt{width:auto}.projGrid .projTh{width:100%;height:auto;aspect-ratio:3/4}
.projNone{grid-column:1/-1;text-align:center;padding:48px 16px;color:var(--mu);display:flex;flex-direction:column;align-items:center;gap:6px}
.projNone div{font-size:46px}.projNone b{color:var(--tx);font-size:17px}.projNone .btn{margin-top:14px}
#tProj .topbar .btn.sm{padding:8px 14px;min-height:36px;border-radius:99px;font-weight:700}
/* AI tab */
.aiTabGrid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:16px}
.aiTab{display:flex;flex-direction:column;align-items:flex-start;gap:4px;text-align:left;border:1px solid #2c2c36;background:linear-gradient(160deg,#1d1d25,#15151b);border-radius:20px;padding:16px 14px 14px;color:var(--tx);min-height:170px;position:relative;overflow:hidden}
.aiTab:after{content:"";position:absolute;right:-30px;top:-30px;width:90px;height:90px;border-radius:50%;background:rgba(255,255,255,.08)}
.aiTab i{font-style:normal;font-size:26px;width:50px;height:50px;border-radius:15px;display:grid;place-items:center;background:rgba(255,255,255,.14);margin-bottom:8px}
.aiTab b{font-size:15.5px;font-weight:800;line-height:1.2}.aiTab small{font-size:12px;color:var(--mu);line-height:1.3}
.aiTab .aiPick{margin-top:auto;padding-top:10px;font-size:12.5px;font-weight:700;color:var(--ac2)}
.aiTab:active{transform:scale(.98)}
.aiTabNote{color:var(--mu);font-size:12.5px;line-height:1.45;margin:16px 2px 0}
/* Templates tab */
#tlib.tab #tlibBack{display:none}
#tlib.tab .topbar .tbmid{justify-content:flex-start}

/* v19 template songs (music tab of the template filler) */
.stSongH{display:flex;align-items:baseline;gap:8px;margin:6px 0 8px}.stSongH b{font-size:14.5px}.stSongH small{color:var(--mu);font-size:12px}
.stSongs{display:flex;flex-direction:column;gap:8px;margin-bottom:12px}
.stSong{display:flex;align-items:center;gap:10px;width:100%;text-align:left;border:1px solid var(--line);background:var(--s1);border-radius:14px;padding:9px 10px;color:var(--tx)}
.stSong i{font-style:normal;font-size:22px;width:40px;height:40px;border-radius:12px;display:grid;place-items:center;background:rgba(255,255,255,.12);flex:0 0 auto}
.stSong span{flex:1;min-width:0}.stSong b{display:block;font-size:14px}.stSong small{display:block;font-size:11.5px;color:var(--mu)}
.stSong em{font-style:normal;font-weight:700;font-size:13px;color:#0c0c0f;background:var(--ac);border-radius:99px;padding:6px 13px}
.stSong.on{border-color:var(--ac)}.stSong.on em{background:none;color:var(--ac2);padding:6px 4px}
#vtChangeSong b{font-weight:700}

#home .brand span{white-space:nowrap}
#home .tbr{gap:6px}
#home .installBtn{padding:7px 11px;font-size:12.5px}
.projRow .projEmpty{flex:1 0 100%}

/* ===== v20: fit the VISIBLE screen height on every phone (Android URL bar, small screens, big font) ===== */
html,body{height:100%;overflow:hidden;overscroll-behavior:none}
body{position:fixed;left:0;right:0;top:0;bottom:0;-webkit-text-size-adjust:100%;text-size-adjust:100%}
#app{height:100%;max-height:100%;overflow:hidden}
@supports (height:100dvh){#app{height:100dvh;max-height:100dvh}}
html.vvh #app{height:var(--app-h);max-height:var(--app-h)}
.screen{min-height:0;overflow:hidden}
.screen>.scroll,.screen .tlibScroll,.homeBody{flex:1 1 auto;min-height:0}
.homeBody>*{flex-shrink:0}
.stTabs{position:absolute;bottom:0}
.sheet{max-height:72vh}.sheet.tall{max-height:88vh}
@supports (height:100dvh){.sheet{max-height:72dvh}.sheet.tall{max-height:88dvh}.vpane{max-height:38dvh}.vtPanel .vpane{max-height:34dvh}.exportPrev{max-height:40dvh}.vtResult{max-height:52dvh}}
html.vvh .sheet{max-height:calc(var(--app-h) * .72)}html.vvh .sheet.tall{max-height:calc(var(--app-h) * .88)}
html.vvh .vpane{max-height:calc(var(--app-h) * .38)}html.vvh .vtPanel .vpane{max-height:calc(var(--app-h) * .34)}
html.vvh .exportPrev{max-height:calc(var(--app-h) * .40)}html.vvh .vtResult{max-height:calc(var(--app-h) * .50)}
/* video editor: the preview shrinks, the timeline + tool bar always stay on screen */
.tlStage{min-height:0;flex:1 1 0;overflow:hidden}
#tlCv{max-width:100%;max-height:100%}
.tlPanel{max-height:55%}
.tlPanelB{min-height:0}
@media (max-height:760px){
  .topbar{min-height:50px;padding-top:7px;padding-bottom:7px}
  .tlTop{padding-top:max(5px,env(safe-area-inset-top));padding-bottom:4px}.tlTop .ib{width:38px;height:38px}
  .tlCtl{padding:2px 12px}.tlPlay{width:38px;height:38px}
  .tlTW{height:176px}
  .tlBar{min-height:62px;padding-top:3px;padding-bottom:calc(3px + var(--safe-b))}.tlBar button{gap:3px;padding:5px 4px}
  .screen.tab{padding-bottom:calc(58px + env(safe-area-inset-bottom))}
  .stTabs{height:calc(58px + env(safe-area-inset-bottom))}
  .hero h1{margin-top:12px}
  .newProj{padding:16px 16px}.homeBody .newProj{padding:14px 14px}
  .hTiles{margin-top:10px;gap:8px}.hT{min-height:58px;padding:9px 10px}
  .hHead{margin:14px 0 8px}
}
@media (max-height:660px){
  .tlTW{height:150px}
  .tlRow{height:48px}.tlClip{height:48px}
  .tlBar{min-height:56px}.tlBar button svg{width:22px;height:22px}
  .tlTop .ib{width:36px;height:36px}.tlExp{padding:7px 12px}
  .newProj b{font-size:19px}.newProj .np{width:46px;height:46px}
  .aiTab{min-height:150px}
}
@media (max-height:580px){
  .tlTW{height:128px}
  .tlBar{min-height:52px}.tlBar button{font-size:10px}
}

/* v21 social stickers picker (video + photo editor) */
.tlSoc{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;padding:4px 0 8px}
.tlSoc button{border:1px solid #2a2a33;background:#1b1b22;border-radius:14px;padding:8px 5px 6px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-height:84px;color:var(--tx)}
.tlSoc button small{font-size:10.5px;line-height:1.15;color:var(--mu);text-align:center}
.tlSoc button:active{transform:scale(.96);background:#24242c}
.tlSoc canvas{max-width:100%;max-height:56px;width:auto;height:auto;display:block;margin:auto 0}
.stkTabs{position:sticky;top:0;z-index:2;background:inherit;padding-top:2px}
.stkPick{min-height:0}

.homeBody #vtWrap.xslim .vtCard canvas{width:calc(var(--vtH,121px) * .5625);height:var(--vtH,121px)}.homeBody #vtWrap.xslim .vtCard{width:calc(var(--vtH,121px) * .5625)}.homeBody #vtWrap.xslim .sec{margin:12px 0 8px}
.homeBody #vtWrap.slim .vtAllIn{height:164px!important;width:92px}.homeBody #vtWrap.xslim .vtAllIn{height:var(--vtH,121px)!important;width:76px;font-size:11px!important}.homeBody #vtWrap.xslim .vtAllIn b{font-size:15px!important}
.homeBody #vtWrap.slim .vtCard small,.homeBody #vtWrap.xslim .vtCard small{display:none}.homeBody #vtWrap.slim .vtCard b,.homeBody #vtWrap.xslim .vtCard b{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:11.5px}

/* v23 template editing */
.vtTip{background:#16161b;border:1px solid #26262f;border-radius:10px;padding:8px 10px;margin:2px 0 10px}
.vtTxRow{border:1px solid #23232b;border-radius:14px;padding:8px 10px 10px;margin:0 0 10px;background:#121217}
.vtTxRow.sel{border-color:#fff;box-shadow:0 0 0 1px #fff inset}
.vtTxRow .vtLbl{margin-top:0}
.vtTools{display:flex;flex-wrap:wrap;gap:6px 8px;align-items:center;margin:8px 0 4px}
.vtTools .btn.sm{padding:6px 10px;min-height:32px;font-size:12.5px}
.vtSl{display:flex;align-items:center;gap:6px;flex:1 1 140px;min-width:120px}.vtSl b{font-size:12px;color:var(--mu);font-weight:600}.vtSl input{flex:1;accent-color:#fff}
.vtSel{background:#1b1b22;color:var(--tx);border:1px solid #2c2c36;border-radius:9px;padding:6px 8px;font:inherit;font-size:12.5px;max-width:150px}
.vtSw{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}
.vtSwB{width:26px;height:26px;border-radius:50%;border:2px solid #2c2c36;padding:0;position:relative;overflow:hidden;display:grid;place-items:center;color:#fff;font-size:14px;background:#1b1b22}
.vtSwB.on{border-color:#fff;box-shadow:0 0 0 2px #0c0c0f inset}
.vtSwB.any input{position:absolute;inset:0;opacity:0;width:100%;height:100%;cursor:pointer}
.vtTa{resize:none;min-height:42px;font-family:inherit}
.vtH{margin:14px 0 8px;font-size:14px}
.vtColRow{border:1px solid #23232b;border-radius:12px;margin:0 0 8px;background:#121217;padding:6px 8px}
.vtColHead{display:flex;align-items:center;gap:10px;width:100%;background:none;border:0;color:var(--tx);padding:4px 2px;text-align:left}
.vtColHead i{width:30px;height:30px;border-radius:50%;border:2px solid #3a3a44;flex:0 0 auto}.vtColHead span{flex:1;font-weight:600;font-size:14px}.vtColHead small{color:var(--mu);font-size:11.5px}
#vtTabs button{font-size:13px}
#vt .vplay{pointer-events:none}
#vt .vplay{width:54px;height:54px;font-size:22px;opacity:.7}#vt .vplay.playing{opacity:0}
