/* File browsing uses compact rows for folders and non-media documents. */
.studio-pro-workspace .studio-menu details>div{background:#14333d!important;border:0!important;border-radius:8px!important;box-shadow:0 12px 32px #0006!important;padding:7px!important}
.studio-pro-workspace .studio-menu details>div>button{border:0!important;border-radius:5px!important;background:transparent!important;padding:9px 11px!important;font-size:12px;line-height:1.4}
.studio-pro-workspace .studio-menu details>div>button:hover,.studio-pro-workspace .studio-menu details>div>button:focus-visible{background:#20454e!important}
.studio-pro-workspace .fm-card.fm-file-row{grid-column:1/-1;display:flex;align-items:center;gap:8px;min-height:40px;padding:6px 8px;box-sizing:border-box}
.studio-pro-workspace .fm-file-row .thumb{width:24px;height:24px;flex:none;background:transparent}
.studio-pro-workspace .fm-file-row p{flex:1;margin:0;font-size:12px}.studio-pro-workspace .fm-file-row small{margin:0;font-size:10px}
.studio-pro-workspace .fm-file-row .studio-icon{width:20px;height:20px}.fm-unsupported{opacity:.48;cursor:default!important}.fm-other-heading{grid-column:1/-1;border-top:1px solid #34515b;padding:10px 0 2px;margin-top:6px;font-size:10px;color:#9ab1bc}
.fm-other-files{grid-column:1/-1;border-top:1px solid #34515b;margin-top:6px;padding-top:5px}.fm-other-files>summary{font-size:11px;color:#9ab1bc;padding:7px 0;cursor:pointer}.fm-other-files .fm-file-row{margin-top:4px}
#mobile-library-toggle,#mobile-layer-toggle,#mobile-editor-more,#mobile-timeline-more,.mobile-drawer-shade{display:none}
#mobile-editor-more,#mobile-timeline-more{background:#18343f;color:#dceeea;border:0;border-radius:7px;font-weight:700;letter-spacing:1px}
#mobile-overflow{inset:auto 8px 8px auto;max-width:min(380px,calc(100vw - 16px));max-height:70dvh;overflow:auto;background:#112631;color:#dceeea;border:1px solid #38585f;border-radius:12px;padding:10px;box-shadow:0 14px 50px #0009}
#mobile-overflow:popover-open{display:flex;flex-wrap:wrap;align-items:center;gap:8px}#mobile-overflow>*{max-width:100%;margin:0!important}#mobile-overflow button{min-width:40px;min-height:40px}#mobile-overflow .timeline-zoom-controls{flex-wrap:wrap}#mobile-overflow .canvas-zoom-controls{width:100%;justify-content:center}
.project-switch-actions{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap}.project-switch-actions button{margin:0!important}.project-switch-error{color:#ffaca8!important}
@media(max-width:900px),(pointer:coarse) and (max-width:1200px),(max-height:500px) and (max-width:1100px){
 html.mobile-editor,html.mobile-editor body{height:100dvh;width:100%;min-width:0!important;overflow:hidden!important}
 .mobile-editor body.studio-pro-workspace{display:flex;flex-direction:column;padding:0!important;--studio-menu-height:30px;--mobile-header:44px}
 .mobile-editor .studio-menu{height:30px!important;min-height:30px;padding:0 4px;gap:0;flex-shrink:0;z-index:10020}
 .mobile-editor .studio-menu summary{font-size:11px;padding:7px 9px}.mobile-editor .studio-menu details>div{max-height:70dvh;overflow:auto;width:205px}.mobile-editor .studio-menu details:nth-last-child(-n+2)>div{left:auto;right:0}
 .mobile-editor .top-bar{display:flex!important;align-items:center;flex-wrap:nowrap!important;gap:4px!important;padding:3px 6px!important;min-height:44px!important;height:44px!important;box-sizing:border-box;flex:none!important;overflow:visible!important}
 .mobile-editor .top-bar>div:first-of-type{font-size:11px!important;white-space:nowrap;flex:1;overflow:hidden;text-overflow:ellipsis;min-width:0}
 .mobile-editor .top-bar>.toolbar-group{display:flex!important;gap:2px!important;flex:none}.mobile-editor .top-bar>.toolbar-group:last-of-type{display:none!important}
 .mobile-editor .top-bar .studio-mode-toggle,.mobile-editor .top-bar .toolbar-group>div[style*="width: 1px"]{display:none!important}
 .mobile-editor .top-bar button{height:36px!important;min-height:36px!important;min-width:34px!important;padding:7px!important;margin:0!important}
 .mobile-editor #mobile-library-toggle,.mobile-editor #mobile-layer-toggle,.mobile-editor #mobile-editor-more,.mobile-editor #mobile-timeline-more{display:inline-flex!important;align-items:center;justify-content:center;flex:none}
 .mobile-editor button.mobile-drawer-toggle{background:linear-gradient(145deg,#f775b5,#cc4e94)!important;color:#301123!important;border:1px solid #ffacda!important;border-radius:11px!important;box-shadow:0 2px 8px #e764a52b;min-width:36px!important}
 .mobile-editor button.mobile-drawer-toggle:disabled{opacity:.45}.pink-lines{display:grid;gap:4px;width:18px}.pink-lines i{display:block;height:2px;border-radius:3px;background:currentColor;transition:transform .18s,width .18s;transform-origin:center}.pink-lines i:nth-child(2){width:13px}.mobile-drawer-toggle[aria-expanded=true] .pink-lines i:first-child{transform:translateY(6px) rotate(45deg)}.mobile-drawer-toggle[aria-expanded=true] .pink-lines i:nth-child(2){opacity:0}.mobile-drawer-toggle[aria-expanded=true] .pink-lines i:last-child{transform:translateY(-6px) rotate(-45deg)}
 .mobile-editor .workspace{flex:1 1 0!important;min-height:70px!important;min-width:0!important;overflow:hidden!important}
 .mobile-editor #main-canvas-area{width:100%!important;min-width:0!important;min-height:0!important;padding:28px 12px 22px!important;overflow:hidden!important;touch-action:none}
 .mobile-editor #viewport-status{height:22px!important;font-size:9px!important;line-height:22px!important;padding:0 8px!important}
 .mobile-editor .viewport-timecodes{height:22px!important;min-height:22px!important;font-size:9px!important;padding:3px 7px!important;box-sizing:border-box;flex:none}
 .mobile-editor #timeline-editor{height:40dvh!important;min-height:150px!important;max-height:none!important;flex:none!important;margin:0!important;width:100%!important;box-sizing:border-box;padding-bottom:env(safe-area-inset-bottom)}
 .mobile-editor #timeline-resizer{display:none!important}.mobile-editor .timeline-controls{height:42px!important;min-height:42px!important;flex:none;box-sizing:border-box;padding:3px 7px!important;gap:6px!important;flex-wrap:nowrap!important;overflow:visible!important}
 .mobile-editor .timeline-controls button{min-width:36px!important;min-height:36px!important;width:36px;height:36px;padding:7px!important}.mobile-editor .timeline-controls #timeline-edit-status,.mobile-editor .timeline-controls #time-display{display:none!important}.mobile-editor #mobile-timeline-more{margin-left:auto!important}
 .mobile-editor #timeline-scroll-area{min-height:0;flex:1;overflow:auto!important;touch-action:pan-x pan-y;overscroll-behavior:contain}.mobile-editor .tl-block{touch-action:none}.mobile-editor .tl-edge{width:16px!important;touch-action:none}.mobile-editor #selection-box .sel-handle{min-width:8px;min-height:8px;width:8px!important;height:8px!important;touch-action:none;box-sizing:border-box}.mobile-editor #selection-box .sel-handle::after{content:"";position:absolute;inset:-7px;border-radius:50%;}
 .mobile-editor .vertical-nav{display:none!important;position:fixed;top:74px;left:0;width:min(360px,calc(100vw - 38px));height:52px;box-sizing:border-box;padding:4px;gap:2px;z-index:10012;overflow-x:auto;overflow-y:hidden!important;background:#142732}
 .mobile-editor body.drawer-left .vertical-nav{display:flex!important;flex-direction:row}.mobile-editor .vertical-nav .nav-btn{min-width:48px!important;width:auto!important;height:44px!important;min-height:44px!important;max-height:44px!important;padding:3px!important;flex:1 0 48px;font-size:9px!important;line-height:11px!important;gap:2px;white-space:nowrap;box-sizing:border-box;overflow:hidden}.mobile-editor .vertical-nav .nav-btn svg{width:17px;height:17px}
 .mobile-editor .sidebar-panel{display:none!important;position:fixed!important;top:126px!important;bottom:env(safe-area-inset-bottom)!important;left:0;width:min(360px,calc(100vw - 38px))!important;min-width:0!important;max-width:none!important;height:auto!important;z-index:10012;overflow:auto!important;overscroll-behavior:contain;box-sizing:border-box;padding:12px!important;background:#10232d!important;box-shadow:10px 0 30px #0005}
 .mobile-editor body.drawer-left .sidebar-panel.active{display:block!important;animation:drawer-left-in .18s ease-out}
 .mobile-editor #corner-radius-panel.inspector-v8{display:none!important;position:fixed!important;top:74px!important;right:0!important;bottom:env(safe-area-inset-bottom)!important;width:min(340px,calc(100vw - 38px))!important;max-width:none!important;max-height:none!important;height:auto!important;z-index:10012;overflow:auto!important;overscroll-behavior:contain;background:#10232d!important}
 .mobile-editor body.drawer-right #corner-radius-panel:not([hidden]){display:block!important;animation:drawer-right-in .18s ease-out}
 .mobile-editor body:is(.drawer-left,.drawer-right) .mobile-drawer-shade{display:block;position:fixed;inset:74px 0 0;width:100%;height:auto;z-index:10011;background:#03091277;border:0;border-radius:0;margin:0;padding:0}
 .mobile-editor .studio-panel-max{inset:74px 0 0!important;max-height:none!important;margin:0!important}.mobile-editor #timeline-editor.studio-panel-max{height:auto!important}
 .mobile-editor dialog{max-width:calc(100vw - 20px)!important;max-height:calc(100dvh - 20px)!important;overflow:auto;box-sizing:border-box}.mobile-editor input,.mobile-editor select,.mobile-editor textarea{max-width:100%;box-sizing:border-box}.mobile-editor .export-box{width:calc(100vw - 20px)!important}
 @media(max-height:500px){.mobile-editor #timeline-editor{height:50dvh!important;min-height:140px!important}.mobile-editor #main-canvas-area{padding:24px 12px 18px!important}.mobile-editor .timeline-controls{height:36px!important;min-height:36px!important}.mobile-editor .timeline-controls button{height:30px!important;min-height:30px!important}.mobile-editor .viewport-timecodes{height:18px!important;min-height:18px!important}}
}
@keyframes drawer-left-in{from{transform:translateX(-100%)}to{transform:translateX(0)}}@keyframes drawer-right-in{from{transform:translateX(100%)}to{transform:translateX(0)}}
@media(min-width:600px) and (max-width:1100px) and (max-height:500px){
 .mobile-editor body.studio-pro-workspace{display:grid!important;grid-template-columns:42% minmax(0,1fr);grid-template-rows:30px 44px minmax(0,1fr) 20px}
 .mobile-editor .studio-menu{grid-column:1/-1;grid-row:1}.mobile-editor .top-bar{grid-column:1/-1;grid-row:2}
 .mobile-editor .workspace{grid-column:1;grid-row:3;min-height:0!important}.mobile-editor .viewport-timecodes{grid-column:1;grid-row:4;overflow:hidden;min-width:0}
 .mobile-editor #timeline-editor{grid-column:2;grid-row:3/5;height:100%!important;min-height:0!important;border-left:1px solid #29434b}
}
@media(prefers-reduced-motion:reduce){.pink-lines i{transition:none}.mobile-editor .sidebar-panel,.mobile-editor #corner-radius-panel{animation:none!important}}
.mobile-editor button.mobile-drawer-toggle{background:#302133!important;color:#f6a6d0!important;border:1px solid #65405b!important;border-radius:9px!important;box-shadow:0 2px 5px #0003!important}
.mobile-editor button.mobile-drawer-toggle:hover{background:#422b44!important}.mobile-editor button.mobile-drawer-toggle[aria-expanded=true]{background:#ed9bc9!important;color:#352032!important;border-color:transparent!important}
.pink-lines{width:17px;gap:4px}.pink-lines i{height:1.8px}.pink-lines i:nth-child(2){width:12px}.pink-lines i:last-child{width:15px}.mobile-drawer-toggle[aria-expanded=true] .pink-lines i{width:17px}
.mobile-editor body:not(.mobile-clip-levels) .clip-envelope,.mobile-editor body:not(.mobile-clip-levels) .clip-envelope *{pointer-events:none!important}
.mobile-editor .studio-focused{outline:0!important}.mobile-editor #studio-focus-outline{display:none!important}.mobile-editor #corner-radius-panel.inspector-v8{border:0!important;border-radius:10px 0 0 10px!important;box-shadow:-10px 0 30px #0005}
#mobile-overflow button[aria-pressed=true]{background:var(--accent)!important;color:#082b2b!important}

/* Compact dialogs retain full controls at phone widths and short landscape heights. */
.mobile-editor dialog{font-size:12px!important;padding:14px!important;border:0!important;border-radius:10px!important;overflow-wrap:anywhere}
.mobile-editor dialog h2{font-size:17px!important;margin:0 0 12px!important;padding-bottom:10px!important}
.mobile-editor dialog :is(p,label,button,input,select,textarea,summary){font-size:12px!important}
.mobile-editor dialog small{font-size:10px!important;line-height:1.45!important}
.mobile-editor dialog :is(input,select,textarea){min-width:0!important}
.mobile-editor dialog button{padding:7px 10px!important;min-height:32px}
.mobile-editor .export-box.export-config{padding:14px!important;width:calc(100vw - 20px)!important}
.mobile-editor .export-workspace{grid-template-columns:minmax(0,1fr)!important;gap:16px!important}
.mobile-editor .export-settings{border:0!important;padding:0!important;min-width:0}
.mobile-editor .export-box label{grid-template-columns:86px minmax(0,1fr);gap:8px;margin:9px 0}
.mobile-editor .export-box .preview-toolbar{flex-wrap:wrap;gap:8px;margin:10px 0}
.mobile-editor .preview-toolbar label{flex:1 1 100%;min-width:0}
.mobile-editor .preview-toolbar input[type=range]{min-width:60px;flex:1;touch-action:pan-y}
.mobile-editor .preview-toolbar select{max-width:100%}
.mobile-editor .preview-pair{gap:6px}.mobile-editor .preview-image{height:130px}
.mobile-editor .preview-heading{gap:8px;flex-wrap:wrap}.mobile-editor .preview-heading span{font-size:10px}
.mobile-editor .preview-stats{gap:6px;margin:10px 0}.mobile-editor .preview-stats>div{padding:8px}.mobile-editor .preview-stats strong{font-size:16px}
.mobile-editor .export-actions{flex-wrap:wrap;gap:6px;margin-top:12px!important;padding-top:10px!important}
.mobile-editor .export-meta{gap:8px;flex-wrap:wrap}
#mobile-overflow #mobile-clip-levels{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:38px;padding:8px 12px!important;border:1px solid #375b64!important;border-radius:8px!important;background:#193b44;color:#dceeea;font-family:inherit;font-size:12px;font-weight:600;line-height:1.2;box-shadow:0 2px 5px #0003;cursor:pointer}
#mobile-overflow #mobile-clip-levels .studio-icon{width:18px;height:18px;margin:0;flex:none}
#mobile-overflow #mobile-clip-levels[aria-pressed=true]{background:var(--accent)!important;color:#082b2b!important;border-color:transparent!important}

.mobile-editor #mobile-editor-more{display:none!important}
