/* Model workspace: independent of camera controls and presentation colours. */
.model-panel{left:12px;right:auto;top:88px;bottom:12px;width:310px;max-height:none;padding:0;overflow:hidden;border-radius:14px;flex-direction:column}
.workspace-heading{display:flex;align-items:center;justify-content:space-between;padding:13px 15px 4px;font-size:13px;font-weight:650;color:var(--ui-text)}
.workspace-tabs{display:flex;gap:4px;padding:0 12px;border-bottom:1px solid var(--ui-line);flex:none}
.workspace-tabs button{flex:1;background:none;border:0;border-bottom:2px solid transparent;border-radius:0;padding:13px 3px;color:#9ca9a1;font:600 11px system-ui}
.workspace-tabs button[aria-selected=true]{color:#f0e7d2;border-bottom-color:#c4b48b}
.workspace-content{padding:16px 14px;overflow:auto;min-height:0;overscroll-behavior:contain}
.workspace-stats{display:grid;grid-template-columns:1.25fr 1fr;gap:8px;margin:0 0 14px}
.workspace-stats>div{padding:12px 10px;border:1px solid var(--ui-line);border-radius:10px;background:#ffffff03}
.workspace-stats strong{display:block;font-size:23px;letter-spacing:-.055em;font-weight:650;color:var(--ui-text);font-variant-numeric:tabular-nums;white-space:nowrap}
.workspace-stats span{display:block;font-size:10px;line-height:1.4;margin-top:5px;color:#9ca9a1}
.workspace-card{border:1px solid var(--ui-line);border-radius:12px;padding:14px 12px;margin-bottom:12px}
.workspace-card h3{font-size:12px;margin:0 0 14px;color:var(--ui-text);font-weight:650}
.workspace-bars{display:flex;height:5px;gap:2px;border-radius:4px;overflow:hidden;margin-bottom:12px;background:#ffffff08}
.workspace-bars i{height:100%;min-width:0}
.workspace-row{display:flex;align-items:center;gap:8px;width:100%;padding:9px 0;border:0;background:none;color:var(--ui-text);font:500 11px system-ui;text-align:left}
.workspace-row:hover{color:#e4cfa6}.workspace-row i{width:7px;height:7px;border-radius:50%;flex:none}.workspace-row span{flex:1}.workspace-row b{font-size:11px;font-variant-numeric:tabular-nums;white-space:nowrap}
.workspace-row[aria-pressed=false]{opacity:.55}.workspace-row[aria-pressed=true]{color:#e4cfa6}
.workspace-category{margin-top:8px}.workspace-category .workspace-row{padding-bottom:6px}.workspace-category>div{height:3px;background:#ffffff0a;border-radius:3px;overflow:hidden}.workspace-category>div>i{display:block;height:100%;background:#b6a581}
.workspace-search{display:flex;align-items:center;gap:8px;border:1px solid var(--ui-line);border-radius:9px;padding:9px 10px;background:#ffffff03}.workspace-search svg{width:16px;height:16px;flex:none}.workspace-search input{width:100%;min-width:0;background:none;border:0;color:var(--ui-text);font:12px system-ui;outline:none}.workspace-search:focus-within{outline:2px solid #c4b48b;outline-offset:2px}
.workspace-list-head{display:flex;align-items:center;justify-content:space-between;font-size:10px;color:#9ca9a1;margin:16px 0 8px}.workspace-list-head button,.workspace-reset{background:none;border:1px solid var(--ui-line);border-radius:7px;color:var(--ui-text);padding:6px 9px;font:11px system-ui}
#workspace-types label,.workspace-models label{display:flex;align-items:center;gap:9px;min-height:40px;border-bottom:1px solid #ffffff09;padding:8px 2px;font-size:11px;color:var(--ui-text);cursor:pointer}
#workspace-types label span,.workspace-models label span{flex:1}#workspace-types label small,.workspace-models label small{font-variant-numeric:tabular-nums;color:#a8b1a9;font-size:10px}.workspace-models label{min-height:52px}.workspace-empty{font-size:11px;line-height:1.5;color:#a8b1a9}
.workspace-reset{width:100%;min-height:36px}.model-panel .header-filters,.model-panel #workspace-models>.section-title:first-of-type{display:none}.workspace-models{margin-bottom:16px}
.workspace-open #model-legend{display:none}.workspace-tabs button:focus-visible,.workspace-content button:focus-visible{outline:2px solid #c4b48b;outline-offset:2px}
@media(min-width:901px){body.workspace-open .viewtools{left:calc(50% + 167px);max-width:calc(100% - 358px);width:max-content;flex-wrap:wrap;justify-content:center;height:auto}.model-panel.open{display:flex}}
@media(max-width:900px){.model-panel{top:82px;bottom:160px;left:8px;right:8px;width:min(370px,calc(100% - 16px));max-height:none;z-index:7}.workspace-content{padding:12px}.workspace-tabs button{min-height:44px}.workspace-heading{padding-top:9px}.workspace-models label,#workspace-types label{min-height:44px}}
@media(max-width:700px){.model-panel{top:66px;bottom:calc(132px + env(safe-area-inset-bottom));width:auto}.workspace-stats{margin-bottom:10px}.workspace-stats strong{font-size:23px}.workspace-card{padding:12px;margin-bottom:10px}}

#section-panel{width:220px;padding:12px}#section-panel .tool-panel-head{margin-bottom:5px}#section-panel .tool-reset{margin-top:4px}@media(max-width:700px){#section-panel{width:auto;left:auto;right:8px;bottom:calc(132px + env(safe-area-inset-bottom));min-width:190px}}
/* Scroll areas retain their native behaviour; the scene itself has no gutter. */
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models){scrollbar-width:thin;scrollbar-color:#817b69 #202823}
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models):hover{scrollbar-color:#a59879 #202823}
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models)::-webkit-scrollbar{width:8px;height:8px}
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models)::-webkit-scrollbar-track{background:#202823;border-radius:8px}
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models)::-webkit-scrollbar-thumb{background:#817b69;border:2px solid #202823;border-radius:8px}
:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models)::-webkit-scrollbar-thumb:hover{background:#b0a17d}
@media(min-width:701px){.workspace-content,.types-list,.section-options{scrollbar-gutter:stable}}
/* Category groups and bulk actions remain real controls with keyboard focus. */
.type-actions,.type-group-actions{display:flex;align-items:center;flex-wrap:wrap;gap:6px}
.type-actions button,.type-group-actions button{min-height:32px;padding:6px 10px;border:1px solid var(--ui-line);border-radius:7px;background:var(--ui-surface);color:var(--ui-text);font:600 10px system-ui;cursor:pointer}
.type-actions button:hover,.type-group-actions button:hover{background:#353d36;border-color:#bbae907a;color:#f7f2e4}
.type-actions button:focus-visible,.type-group-actions button:focus-visible,.type-group summary:focus-visible{outline:2px solid #d7c8a3;outline-offset:2px}
.type-actions button:disabled,.type-group-actions button:disabled{opacity:.45;cursor:not-allowed}
.type-group{margin:6px 0;border:1px solid var(--ui-line);border-radius:9px;background:#ffffff03;overflow:hidden}
.type-group summary{display:flex;align-items:center;gap:8px;min-height:40px;padding:8px 10px;color:var(--ui-text);font:600 11px system-ui;cursor:pointer;list-style:none}
.type-group summary::-webkit-details-marker{display:none}
.type-group summary::before{content:"";width:7px;height:7px;flex:none;border-right:1.5px solid #c8b893;border-bottom:1.5px solid #c8b893;transform:rotate(-45deg);transition:transform .15s}
.type-group[open] summary::before{transform:rotate(45deg)}
.type-group summary:hover{background:#ffffff08}
.type-group-actions{padding:2px 10px 8px}
.type-group>div:not(.type-group-actions){padding:0 10px 5px}
@media(max-width:700px){.type-actions button,.type-group-actions button{min-height:36px}.type-group summary{min-height:44px}}
@media(prefers-reduced-motion:reduce){.type-group summary::before{transition:none}}
@media(forced-colors:active){:is(.workspace-content,.model-panel,.tool-panel,.types-list,.section-options,#guide,#workspace-types,.workspace-models){scrollbar-color:auto}.type-group summary::before{border-color:CanvasText}}
#types-panel{display:flex;flex-direction:column;max-height:calc(100dvh - 180px);overflow:hidden}
#types-panel .tool-panel-head{flex:none}
#types-panel .types-list{display:block;min-height:0;max-height:55vh;overflow:auto;flex:1}
.type-actions{flex:none;flex-wrap:nowrap;padding-top:8px}
.type-actions>.tool-reset{flex:1;width:auto;min-width:0;margin:0}
.type-group>label{padding-inline:10px}
.type-group summary span{flex:1}.type-group-count{color:var(--ui-muted,#a8b1a9);font-size:10px;font-variant-numeric:tabular-nums;white-space:nowrap}
@media(max-width:700px){#types-panel{max-height:calc(100dvh - 220px)}#types-panel .types-list{max-height:none}.viewtools{grid-template-columns:repeat(3,minmax(0,1fr))}}
/* Keep the canvas stationary when controls receive focus in a narrow desktop pane. */
main{overflow:clip;min-width:0}
.viewtools{max-width:calc(100% - 24px);width:max-content;flex-wrap:wrap;justify-content:center;height:auto}
@media(min-width:701px) and (max-width:900px){.viewtools{left:12px;right:12px;width:auto;transform:none;bottom:12px}}
@media(max-width:700px){.viewtools{width:auto;max-width:none}}
