.editor-app-header{display:flex;align-items:center;gap:16px;min-height:58px;padding:10px 18px;border-bottom:1px solid #444750;background:#191a1e}.editor-app-header>.system-brand{font-size:22px;text-decoration:none;white-space:nowrap}.editor-app-label{font-size:12px;color:#a4a8b3}.editor-app-links{margin-left:auto;display:flex;align-items:center;gap:18px}.editor-app-links>a{text-decoration:none;font-size:13px}.editor-app-links label{display:flex;align-items:center;gap:8px;margin:0}.editor-app-links select{width:auto;font-size:12px;min-height:38px}.editor-app-links #editor-connection{font-size:12px;color:#a4a8b3}
html[data-theme] body.standalone-editor{max-width:none;padding:0}.standalone-editor main{padding:12px}.standalone-editor .editor-app-header{margin:0;padding:10px 18px}.standalone-editor .editor-standalone-heading{padding:0 4px!important}.standalone-editor .editor-standalone-heading h2{font-size:15px!important}.standalone-editor .editor-standalone-heading .hint{display:none}
html[data-theme] #tab-pieces .editor-webapp{border-radius:6px;background:#444750}.editor-library-toggle{min-height:36px!important;padding:7px 12px!important;font-size:12px!important}.editor-open-app{text-decoration:none;font-size:12px!important}.creative-document-bar .editor-library-toggle{flex:none}
@media(min-width:1101px){html[data-theme] #tab-pieces .editor-webapp.editor-library-open{grid-template-columns:220px minmax(0,1fr) 320px;grid-template-areas:'assets monitor inspector'}.editor-webapp.editor-library-open .creative-library-drawer{grid-area:assets;position:sticky;top:12px;border-radius:0;max-height:calc(100vh - 90px);overflow:auto}.editor-webapp.editor-library-open .creative-library-drawer>summary{background:#25272e;border-bottom:1px solid #444750}.editor-webapp.editor-library-open .creative-library-drawer .piece-library-list,.editor-webapp.editor-library-open .creative-library-drawer .piece-template-grid{grid-template-columns:minmax(0,1fr)!important}.editor-webapp.editor-library-open .creative-library-drawer .piece-library-toolbar{flex-direction:column!important}.editor-webapp.editor-library-open .creative-library-drawer .piece-library-toolbar select{flex:auto}.editor-webapp.editor-library-open .creative-library-drawer .piece-library-footer{flex-direction:column}.editor-webapp.editor-library-open .creative-library-drawer .piece-library-actions .btn{font-size:11px;padding:8px}.editor-webapp.editor-library-open .studio-inspector{position:sticky;top:12px}}
html[data-theme] #tab-pieces .composition-selection-opacity{display:flex!important;align-items:center;gap:8px;flex-basis:100%;font-size:12px;color:#c7cfdc;margin:10px 0 0}.composition-selection-opacity input{width:86px;min-height:44px}.composition-quick-position{display:flex!important;align-items:center;gap:8px;flex-wrap:wrap;flex-basis:100%;font-size:12px;margin:8px 0}.composition-quick-position select{flex:1;min-width:140px}.composition-quick-position input{width:70px;min-height:44px}.composition-bounds-warnings{display:flex;align-items:center;gap:6px;flex-wrap:wrap;padding:10px;border:1px solid #aa793a;background:#593d222e;font-size:12px;color:#f4c97c;margin:8px 0}.composition-bounds-warnings .btn{background:transparent!important;color:#f4c97c!important;min-height:36px!important;padding:5px 8px!important;font-size:12px!important}
@media(max-width:800px){.editor-app-header{flex-wrap:wrap;gap:10px}.editor-app-links{margin-left:0;width:100%;justify-content:space-between;gap:8px}.standalone-editor main{padding:8px}.editor-app-links label{font-size:11px}.editor-app-links select{max-width:140px}.creative-document-bar{flex-wrap:wrap}.editor-app-label{font-size:11px}}

.composition-bounds-warnings[hidden]{display:none!important}

/* Compact web workspace: document, tools, canvas and one docked panel. */
html[data-theme] #tab-pieces{--editor-active:#98f82822;--editor-accent:#98f828}
.editor-panel-tabs{display:flex;gap:0;border-bottom:1px solid var(--editor-line);background:#24262b;position:sticky;top:0;z-index:3}
html[data-theme] #tab-pieces .editor-panel-tabs button{flex:1;background:transparent;color:var(--editor-muted);border:0;border-bottom:2px solid transparent;font-size:12px;font-weight:500;padding:12px;min-height:42px;cursor:pointer}
html[data-theme] #tab-pieces .editor-panel-tabs button[aria-selected=true]{color:var(--editor-text);border-bottom-color:#98f828;background:#ffffff05}
html[data-theme] #tab-pieces .editor-panel-inactive{display:none!important}
html[data-theme] #tab-pieces .editor-compact .studio-inspector{background:var(--editor-panel);min-width:0;overflow:visible}
html[data-theme] #tab-pieces .editor-compact .studio-inspector>.card{border:0;margin:0;border-radius:0;box-shadow:none}
html[data-theme] #tab-pieces .editor-compact .studio-layer-panel{border:0}
html[data-theme] #tab-pieces .editor-compact .studio-panel-title{display:none}
html[data-theme] #tab-pieces .editor-focus-toggle{font-size:11px;min-height:34px;padding:6px 10px;white-space:nowrap;flex:none}
html[data-theme] #tab-pieces.editor-focus-mode .editor-webapp{grid-template-columns:minmax(0,1fr)!important;grid-template-areas:'monitor'!important}
#tab-pieces.editor-focus-mode .studio-inspector,#tab-pieces.editor-focus-mode .creative-library-drawer,#tab-pieces.editor-focus-mode .pieces-heading,#tab-pieces.editor-focus-mode #program-package-host{display:none!important}
#tab-pieces.editor-focus-mode .editor-library-toggle{display:none!important}
@media(min-width:801px){
 html[data-theme=macos-dark] #tab-pieces .editor-compact{grid-template-columns:minmax(0,1fr) 294px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact.editor-library-open{grid-template-columns:204px minmax(0,1fr) 294px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-monitor{grid-template-columns:46px minmax(0,1fr)}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-document-bar{min-height:42px;padding:5px 10px;gap:10px;border-radius:0}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-menu summary{min-height:32px;padding:8px 10px;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-context{min-height:44px;padding:5px 10px;gap:9px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-context input{min-height:30px;height:30px;padding:4px 6px;width:58px;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-canvas-panel.card{padding:10px 12px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-toolrail{padding:7px 4px;gap:4px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-toolrail .btn{width:36px;min-width:36px;height:38px;min-height:38px;padding:6px;border-radius:3px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-inspector>.card{padding:12px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-property-group summary{min-height:34px;padding:8px 0;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-property-fields{gap:8px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-property-fields input:not([type=checkbox]),html[data-theme=macos-dark] #tab-pieces .editor-compact .studio-property-fields select{min-height:32px;padding:6px;font-size:11px;border-radius:3px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composer-layer{min-height:42px;padding:2px 5px;grid-template-columns:30px minmax(0,1fr) 30px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composer-layer .creative-layer-name,html[data-theme=macos-dark] #tab-pieces .editor-compact .composer-layer .creative-layer-toggle{min-height:36px;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-layer-thumb{width:26px;height:24px;flex-basis:26px;font-size:16px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-document-actions{padding:8px 12px;gap:6px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .creative-document-actions .btn{min-height:34px;padding:7px 10px;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact #studio-composer-actions{padding:10px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact #studio-composer-actions>.btn{min-height:32px;padding:6px 8px;font-size:11px}
 html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-selection-opacity input,html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-quick-position input,html[data-theme=macos-dark] #tab-pieces .editor-compact .composition-quick-position select{min-height:32px;padding:6px;font-size:11px}
 .standalone-editor main{padding:6px}.standalone-editor .editor-app-header{min-height:44px;padding:5px 12px}.standalone-editor .editor-app-header>.system-brand{font-size:19px}.standalone-editor .editor-app-links select{min-height:30px;padding:4px 8px}.standalone-editor .system-footer{padding:8px}
}
@media(min-width:801px) and (max-width:1100px){html[data-theme=macos-dark] #tab-pieces .editor-compact.editor-library-open{grid-template-columns:minmax(0,1fr) 294px;grid-template-areas:'monitor inspector' 'library library'}}
@media(max-width:800px){.editor-panel-tabs{position:static}.creative-document-bar{gap:8px}.creative-document-bar>span{white-space:normal}.editor-focus-toggle{min-height:44px!important}}

html[data-theme=touch] #tab-pieces .editor-panel-tabs button{min-height:44px}

/* /editor is a window-sized application; scrolling belongs to its panels. */
html:has(body.standalone-editor){height:100%;overflow:hidden}
html[data-theme] body.standalone-editor{height:100dvh;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.standalone-editor>main{flex:1;min-height:0;display:flex;padding:0!important}
.standalone-editor>main>#tab-pieces{flex:1;min-height:0;display:flex;flex-direction:column;overflow:hidden}
.standalone-editor #tab-pieces>.pieces-heading,.standalone-editor>#program-package-host,.standalone-editor>.editor-app-header{display:none!important}
html[data-theme] .standalone-editor #tab-pieces>.editor-webapp{flex:1;min-height:0;grid-template-rows:minmax(0,1fr);grid-template-areas:'monitor inspector';border-radius:0;overflow:hidden;align-items:stretch}
html[data-theme] .standalone-editor #tab-pieces>.editor-webapp.editor-library-open{grid-template-areas:'assets monitor inspector'}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor{min-height:0;grid-template-areas:'menus menus' 'document document' 'context context' 'tools canvas' 'actions actions' 'program program';grid-template-rows:auto auto auto minmax(0,1fr) auto auto;overflow:hidden}
html[data-theme] .standalone-editor #tab-pieces .composition-canvas-panel.card{display:flex;flex-direction:column;min-height:0;overflow:hidden;padding:8px}
html[data-theme] .standalone-editor #tab-pieces .piece-preview-header{display:none}
html[data-theme] .standalone-editor #tab-pieces #piece-preview-wrap,html[data-theme] .standalone-editor #tab-pieces #piece-preview-wrap:not([data-zoom=fit]){flex:1;height:auto!important;min-height:0;max-height:none;aspect-ratio:auto;margin:0 0 6px;overflow:auto}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings{flex:none;flex-wrap:wrap;gap:6px 10px;margin:0;padding:4px 0;font-size:10px;justify-content:flex-start}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings>span:not(.editor-tool-status){display:none}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings select{min-height:28px;padding:4px;font-size:10px;max-width:110px}
html[data-theme] .standalone-editor #tab-pieces .creative-program-status{padding:4px 10px;min-height:24px}
html[data-theme] .standalone-editor #tab-pieces .creative-program-status .hint{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html[data-theme] .standalone-editor #tab-pieces .creative-document-actions{padding:4px 8px}
html[data-theme] .standalone-editor #tab-pieces .creative-document-actions .btn{min-height:30px;font-size:10px;padding:5px 8px}
html[data-theme] .standalone-editor #tab-pieces .studio-inspector{position:relative;top:auto;min-height:0;display:flex;flex-direction:column;overflow:hidden;border-radius:0}
html[data-theme] .standalone-editor #tab-pieces .studio-inspector>.card,html[data-theme] .standalone-editor #tab-pieces .studio-layer-panel{flex:1;min-height:0;max-height:none;overflow:auto}
html[data-theme] .standalone-editor #tab-pieces .creative-library-drawer{position:relative;top:auto;min-height:0;height:100%;max-height:none;overflow:auto;border-radius:0}
html[data-theme] .standalone-editor #tab-pieces .composer-layers{max-height:none}
html[data-theme] .standalone-editor #tab-pieces .composition-toolrail{height:100%;min-height:0;overflow-y:auto;overflow-x:hidden;box-sizing:border-box;gap:3px}
html[data-theme] .standalone-editor .system-footer{flex:none;margin:0;padding:3px 10px;min-height:20px;font-size:10px;border-top:1px solid #444750}
.editor-app-menu{margin-left:auto;position:relative}
html[data-theme] #tab-pieces .editor-app-menu>.composition-menu-content{right:0;left:auto;min-width:300px;width:min(420px,90vw);max-height:75dvh;overflow:auto;z-index:300}
html[data-theme] #tab-pieces .editor-app-menu .editor-app-header{display:flex;flex-wrap:wrap;position:static;min-height:0;margin:0;padding:10px;background:transparent;border:0}
.editor-app-menu .editor-app-label{display:none}.editor-app-menu .editor-app-links{margin:0;flex-wrap:wrap;gap:10px}.editor-app-menu .editor-app-links label{margin:0}
.editor-app-menu .program-package-bar{flex-wrap:wrap;padding:8px;margin:0}.editor-app-menu .program-package-resources{max-height:300px;overflow:auto}.editor-app-menu .creative-document-settings{margin:8px 0}
.editor-command-row{display:flex;gap:6px;flex-wrap:wrap;padding:8px 0}
.editor-drawing-color input{width:30px!important;height:28px!important;min-height:28px!important;padding:2px!important;cursor:pointer}.editor-drawing-color{margin:4px 0!important}
html[data-theme] #tab-pieces .composition-toolrail>input[type=number]{width:36px;min-height:28px;font-size:10px;padding:3px}
html[data-theme] #tab-pieces .composition-toolrail .btn[aria-pressed=true]{background:#98f82826;color:#98f828;border-color:#98f82877}
.editor-tool-status{margin-left:auto;color:#98f828;font-size:10px}.editor-side-toggle{display:none}
@media(max-width:1100px) and (min-width:801px){html[data-theme] .standalone-editor #tab-pieces>.editor-webapp.editor-library-open{grid-template-columns:180px minmax(0,1fr) 250px}}
@media(max-width:800px){
 html[data-theme] .standalone-editor #tab-pieces>.editor-webapp,html[data-theme] .standalone-editor #tab-pieces>.editor-webapp.editor-library-open{grid-template-columns:minmax(0,1fr);grid-template-areas:'monitor';position:relative}
 html[data-theme] .standalone-editor #tab-pieces .studio-inspector{display:none;position:absolute;top:100px;bottom:0;right:0;width:min(300px,85vw);z-index:150;border-left:1px solid #444750}
 html[data-theme] .standalone-editor #tab-pieces.editor-mobile-panel .studio-inspector{display:flex}
 html[data-theme] .standalone-editor #tab-pieces .creative-library-drawer{display:none;position:absolute;top:100px;bottom:0;left:0;width:min(300px,85vw);height:auto;z-index:150}
 html[data-theme] .standalone-editor #tab-pieces .editor-library-open .creative-library-drawer{display:block}
 .standalone-editor .editor-side-toggle{display:block}.standalone-editor .creative-context label{font-size:10px}.standalone-editor .creative-context input{width:44px!important}.standalone-editor .creative-context>strong{display:none}
 html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings .inline-check{display:none}
}

html[data-theme] .standalone-editor #tab-pieces .studio-monitor{overflow:hidden!important}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings{flex-direction:row;align-items:center}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings .inline-check{min-height:28px;font-size:10px}
html[data-theme] .standalone-editor #tab-pieces .studio-monitor-settings input[type=checkbox]{width:14px;height:14px}
html[data-theme] #tab-pieces .editor-app-menu summary:focus-visible{outline:2px solid #98f828}

html[data-theme] .standalone-editor #tab-pieces .editor-webapp:not(.editor-library-open) .creative-library-drawer{display:none!important}
html[data-theme] .standalone-editor #tab-pieces .creative-library-drawer{grid-area:assets}
html[data-theme] .standalone-editor #tab-pieces .composition-bounds-warnings{flex:none;max-height:56px;overflow:auto;padding:5px;margin:3px 0}
