/* Mobile workflow only. Original desktop arrangement is restored by JS. */
#mobileWorkflow[hidden],.mw-pane[hidden]{display:none!important}
@media(max-width:900px){
 body.mobile-steps{overflow-x:hidden}
 .mobile-steps .shell{display:block!important;width:100%;max-width:100%}
 .mobile-steps .top{padding:10px!important;min-height:0;flex-wrap:wrap;gap:8px}
 .mobile-steps .logo{font-size:25px}.mobile-steps .brand h1{font-size:18px!important}
 .mobile-steps .brand p{display:none}.mobile-steps .head-actions{width:100%;display:flex;gap:5px;flex-wrap:wrap}
 .mobile-steps .head-actions button,.mobile-steps .topbtn{min-height:42px;font-size:12px;padding:8px!important;flex:1 1 auto;text-align:center}
 .mobile-steps .sidebar{min-height:0!important;display:flex!important;flex-direction:row!important;overflow:auto;gap:5px;padding:6px;border-right:0;border-bottom:1px solid var(--line,#555)}
 .mobile-steps .sidebar .side{flex:1 0 65px;min-height:52px;font-size:21px!important;padding:5px 3px!important;border-radius:6px}
 .mobile-steps .sidebar .side span{font-size:10px!important;white-space:nowrap}
 .mobile-steps .workspace{padding:8px!important;width:100%;max-width:100%;min-width:0}
 .mobile-steps .workspace>.upper:empty{display:none!important}
 .mobile-steps .workspace>.upper{display:none!important}
 .mobile-steps .workspace>.media{width:100%;padding:10px;margin-bottom:8px}
 .mobile-steps .media h2{font-size:15px;white-space:normal}
 .mobile-steps .media-grid{max-height:174px!important;min-height:90px;grid-template-columns:repeat(3,minmax(0,1fr))}
 .mobile-steps .media-card small{font-size:10px}
 .mobile-steps .library-insert-bar{position:static;gap:6px}
 .mobile-steps .library-insert-bar button{min-height:42px;white-space:normal;font-size:12px;padding:8px}
 .mobile-steps .upload-row .btn{min-height:46px;font-size:14px}
 .mobile-steps input,.mobile-steps select,.mobile-steps textarea{font-size:16px!important;max-width:100%}
 .mobile-steps input[type=checkbox]{width:20px;height:20px;flex:none}
 .mw-intro{font-size:12px;line-height:1.5;margin:8px 2px;color:var(--ink,#ddd)}
 .mw-tabs{position:sticky;top:0;z-index:65;display:flex;gap:5px;overflow-x:auto;overscroll-behavior-x:contain;background:var(--dark,#202020);padding:8px 5px;border-radius:8px;scroll-margin-top:8px}
 .mw-tabs button{flex:0 0 auto;min-height:46px;background:var(--dt-raised,#594037);color:#fff;border:1px solid var(--line,#777);border-radius:7px;padding:10px 13px;font-size:13px;font-weight:700}
 .mw-tabs button[aria-selected=true]{background:var(--gold,#00c4cc);color:#142526;border-color:transparent}
 .mw-tabs button:focus-visible{outline:2px solid var(--gold,#00c4cc);outline-offset:-3px}
 .mw-pane{padding-top:8px;min-width:0}.mw-help{font-size:12px;line-height:1.6;margin:0 3px 8px;color:var(--ink,#ddd)}
 .mw-pane>.panel,.mw-pane>.timeline-panel{width:100%;max-width:100%;margin:0;padding:9px;min-width:0}
 .mw-pane .panel h2{white-space:normal;font-size:14px}
 .mw-pane .timeline-panel h2{font-size:14px;white-space:normal}
 .mobile-steps .timeline-scroll{overflow-x:auto!important;overflow-y:hidden;-webkit-overflow-scrolling:touch;max-width:100%;touch-action:pan-x}
 .mobile-steps #timelineContent{overflow:visible!important;max-width:none;touch-action:pan-x}
 .mobile-steps .tl-editor-tools{gap:5px}
 .mobile-steps .tl-editor-tools button{min-height:44px;padding:8px;font-size:12px}
 .mobile-steps .tools{gap:5px}.mobile-steps .tools button,.mobile-steps .tool-upload{min-height:44px}
 .mobile-steps .timeline-bottom{flex-direction:column;gap:4px}
 .mobile-steps .v14-move{display:grid;grid-template-columns:1fr 1fr;gap:6px}
 .mobile-steps .v14-move button{min-height:44px;font-size:12px}
 .mobile-steps .v14-move span{grid-column:1/-1;font-size:11px}
 .mobile-steps .mw-pane .preview{display:flex!important}
 .mobile-steps .screen{max-width:100%!important;max-height:52svh}
 .mobile-steps .transport button{min-width:46px;min-height:46px}
 .mobile-steps .player-bottom{padding:9px}.mobile-steps .player-bottom>input{min-height:35px}
 .mobile-steps .v18-audio-panel{width:100%!important;max-width:100%!important;margin:0!important;padding:12px!important}
 .mobile-steps .v18-audio-controls{display:flex;flex-direction:column;align-items:stretch;padding:0;gap:12px}
 .mobile-steps .v18-audio-controls>label{min-height:44px;flex-wrap:wrap}
 .mobile-steps .v18-audio-controls button{min-height:44px}
 .mobile-steps .v18-audio-head{padding:0}.mobile-steps .v18-audio-controls input[type=range]{flex:1;width:auto;min-width:90px;min-height:30px}
 .mobile-steps .prop-tabs{display:grid;grid-template-columns:1fr 1fr;gap:5px}
 .mobile-steps .prop-tabs button{min-height:44px;font-size:12px;border-radius:6px}
 .mobile-steps .prop-body label{line-height:1.6}
 .mobile-steps .prop-body button{min-height:42px}
 .mobile-steps #stickerList{max-height:170px;overflow:auto}
 .mobile-steps #stickerControls .two{gap:8px}
 .mobile-steps .v14-export{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px;border-radius:8px;margin:0;padding:12px;background:var(--cream,#262626);color:var(--ink,#eee)}
 .mobile-steps .v14-export label{min-width:0;display:flex;flex-direction:column;gap:6px}
 .mobile-steps .v14-export select{width:100%;min-height:46px}
 .mobile-steps .v14-export-slot{grid-column:1/-1;min-width:0;flex-wrap:wrap}
 .mobile-steps #exportBtn{min-height:50px!important;font-size:16px!important;width:100%;margin:0!important}
 .mobile-steps .status-panel{padding:10px 0;display:block;overflow-wrap:anywhere}
 .mobile-steps .status-line{display:flex;flex-direction:column;gap:7px}
 .mobile-steps .exports-drawer{max-width:100%}
 .mobile-steps .v14-library.v14-open{left:8px;right:8px;top:5vh;max-height:88svh}
 .mw-advanced{margin-top:10px}.mw-advanced>summary{min-height:44px;padding:10px;cursor:pointer}
 .mw-next{display:flex;justify-content:space-between;gap:12px;margin:14px 0;padding-bottom:env(safe-area-inset-bottom,0px)}
 .mw-next button{min-height:46px;border-radius:7px;padding:10px 14px;background:var(--gold,#00c4cc);color:#142526;font-weight:700}
 .mw-next button:disabled{opacity:.35}
 .mobile-steps dialog{max-width:calc(100vw - 16px)!important;max-height:90svh!important;padding:0!important}
 .mobile-steps #stickerGrid{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;padding:8px}
 .mobile-steps #stickerGrid img{height:80px;max-width:100%;object-fit:contain}
 .mobile-steps .fx-filterbar{gap:5px;padding:8px;flex-wrap:wrap}
 .mobile-steps .fx-filterbar button{min-height:42px;font-size:12px;padding:8px}
 .mobile-steps .creative-fx .fx-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
 .mobile-steps .creative-fx .fx-actions{flex-wrap:wrap}
 .mobile-steps #directTextEditor{position:fixed;left:8px;right:8px;bottom:12px;top:auto;width:auto;max-width:none;z-index:120}
}
@media(max-width:360px){.mobile-steps .media-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.mobile-steps #stickerGrid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:900px){
 .mw-toolbox{margin-top:12px;border-top:1px solid var(--line,#555);padding-top:7px}
 .mw-toolbox>summary{min-height:46px;cursor:pointer;padding:12px 5px;font-weight:600}
 .mobile-steps .mw-toolbox .tools{margin-top:7px}
 .mobile-steps .v14-move button{background:var(--dt-raised,#f4c66e);color:var(--ink,#eee);border-color:var(--line,#777)}
 .mobile-steps .v14-move span{color:var(--ink,#ddd)}
}
@media(max-width:900px){
 .mobile-steps .sidebar{position:static!important;inset:auto!important;transform:none!important;width:auto!important;z-index:auto!important;box-shadow:none!important}
 .mobile-steps .head-actions{flex-wrap:nowrap!important;overflow-x:auto;max-width:100%;padding-bottom:3px}
 .mobile-steps .head-actions button,.mobile-steps .head-actions .topbtn{flex:0 0 auto;white-space:nowrap}
 .mobile-steps .workspace{padding-bottom:12px!important}
}
@media(max-width:900px){
 .mw-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));overflow:visible;gap:5px}
 .mw-tabs button{min-width:0;padding:9px 4px;font-size:12px;white-space:normal;line-height:1.25}
}
