/* Radial Toolbar and Notes lessons (layout-ui.js). Other lessons never set these attributes. */
.workspace[data-tool-layout="radial"] #dock{display:none}
/* With no dock, selection actions sit at the bottom, below the wheel's lowest position. */
.workspace[data-tool-layout="radial"] #selection-strip{bottom:24px}
.embedded .workspace[data-tool-layout="radial"] #selection-strip{bottom:20px}

.radial-wheel{position:absolute;width:0;height:0;z-index:7;pointer-events:none}
.radial-disc{position:absolute;left:0;top:0;transform:translate(-50%,-50%) scale(var(--wheel-scale,1));transform-origin:center}
.radial-disc svg{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
.radial-face{fill:var(--white);stroke:var(--border);stroke-width:1;filter:drop-shadow(0 6px 18px #2521372e)}
.radial-sector{fill:var(--white);stroke:#d7cfe3a6;stroke-width:.7}
.radial-sector.active{fill:var(--lavender)}
.radial-caption{position:absolute;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:3px;max-width:72px;color:var(--ink);text-align:center;line-height:1.15}
.radial-caption .icon{width:24px;height:24px}
.radial-caption.active .icon{color:var(--violet)}
.radial-caption b{font-size:11px;font-weight:600}
.radial-caption small{font-size:8px;font-weight:500;color:var(--muted)}
.radial-caption.is-target{outline:2px solid var(--violet);outline-offset:4px;border-radius:8px}
.radial-hub{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);border-radius:50%;background:var(--violet);color:var(--paper);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px}
.radial-hub img,.radial-hub .icon{width:23px;height:23px}
.radial-hub b{font-size:11px;font-weight:700}
.radial-hub.is-target{outline:2px solid var(--violet);outline-offset:4px}

/* The app puts Tools to the right of Controls. */
.radial-toggle{position:absolute;right:15px;bottom:26px}
.radial-toggle .tile{width:44px;height:44px;border-radius:12px;display:grid;place-items:center;background:var(--neutral);color:var(--ink)}
.radial-toggle.active .tile{background:var(--violet);color:var(--paper)}
.radial-toggle.is-target .tile{outline:2px solid var(--violet);outline-offset:3px}
.workspace[data-tool-layout="radial"] #controls{right:70px}
.embedded .radial-toggle{right:5px;bottom:24px}
.embedded .radial-toggle .tile{width:30px;height:30px;border-radius:9px}
.embedded .radial-toggle .tile .icon{width:18px;height:18px}
.embedded .workspace[data-tool-layout="radial"] #controls{right:44px}

/* Notes: a panel at the right edge, beside the canvas. */
.notes-panel{position:absolute;right:9px;top:var(--notes-top,140px);bottom:70px;width:clamp(230px,32%,300px);z-index:8;display:flex;flex-direction:column;background:var(--white);border:1px solid #d7cfe399;border-radius:14px;box-shadow:0 2px 10px #00000014;color:var(--ink);overflow:hidden;font-size:12px}
/* The panel starts below the view cube; centered controls make room for it, as the app's do. */
.workspace[data-notes-open="true"] .canvas-hint{left:calc((100% - var(--notes-space,0px)) / 2 - 15px);max-width:min(480px,calc(100% - 244px - var(--notes-space,0px)))}
.workspace[data-notes-open="true"] #selection-strip,.workspace[data-notes-open="true"] #dock{left:calc((100% - var(--notes-space,0px)) / 2);max-width:calc(100% - 100px - var(--notes-space,0px))}
.notes-panel header{display:flex;align-items:center;gap:8px;padding:8px 12px;border-bottom:1px solid #d7cfe399;min-height:40px}
.notes-panel header>.icon{color:var(--violet)}
.notes-panel header strong{font-size:15px;flex:1}
.notes-panel header span{display:grid;place-items:center;width:28px;height:28px;color:var(--muted);border-radius:7px}
.notes-browser{background:var(--paper);padding:8px 10px;display:flex;flex-direction:column;gap:2px}
.notes-filter{display:flex;background:#7676801f;border-radius:8px;padding:2px;margin-bottom:4px}
.notes-filter span{flex:1;text-align:center;padding:4px 6px;border-radius:6px;font-size:11px;font-weight:500}
.notes-filter span.on{background:var(--white);box-shadow:0 1px 3px #0000001f;color:var(--violet)}
.notes-row{display:flex;align-items:center;gap:8px;padding:0 10px;min-height:34px;border-radius:8px;font-size:13px;font-weight:500}
.notes-row .icon{width:18px;height:18px;color:var(--violet)}
.notes-row.current{background:var(--lavender)}
.notes-browser em{font-size:11px;color:var(--muted);font-style:normal;padding:6px}
.notes-object{padding:8px 14px 0;font-size:13px;font-weight:600}
.notes-editor{flex:1;min-height:0;padding:10px 14px;font-size:13px;line-height:1.45;white-space:pre-wrap;overflow:hidden}
.notes-editor.empty{color:var(--muted)}
.notes-editor.editing{box-shadow:inset 2px 0 0 var(--violet)}
.notes-panel footer{padding:8px 12px;font-size:11px;color:var(--muted)}
.notes-panel .is-target{outline:2px solid var(--violet);outline-offset:2px;border-radius:7px}
.utility-rail #notes-toggle.active .tile{background:var(--lavender);color:var(--violet)}

.embedded .notes-panel{width:44%;max-width:250px;bottom:56px;border-radius:11px;font-size:10px}
.embedded .workspace[data-notes-open="true"] .canvas-hint{left:54px;right:calc(var(--notes-space,0px) + 2px);max-width:none}
.embedded .workspace[data-notes-open="true"] #dock{max-width:none}
/* A compact embed has no room for selection actions beside the panel; they return when it closes. */
.embedded .workspace[data-notes-open="true"] #selection-strip{display:none}
.embedded .notes-panel header{min-height:30px;padding:4px 8px;gap:6px}
.embedded .notes-panel header strong{font-size:12px}
.embedded .notes-panel header span{width:22px;height:22px}
.embedded .notes-panel .icon{width:15px;height:15px}
.embedded .notes-browser{padding:5px 7px}
.embedded .notes-filter span{font-size:9px;padding:3px 4px}
.embedded .notes-row{min-height:24px;font-size:10px;padding:0 7px;gap:6px}
.embedded .notes-object{font-size:10px;padding:5px 9px 0}
.embedded .notes-editor{font-size:10px;padding:6px 9px}
.embedded .notes-panel footer{font-size:8.5px;padding:5px 8px}

/* Phones: the panel spans the lower canvas, and centered controls keep their phone layout. */
@media(max-width:540px){.workspace .notes-panel{left:72px;right:8px;width:auto;top:auto;bottom:72px;height:min(56%,330px)}.workspace[data-notes-open="true"] .canvas-hint{left:68px;right:10px;max-width:none}.workspace[data-notes-open="true"] #dock{left:50%;max-width:none}.workspace[data-notes-open="true"] #selection-strip{display:none}}

/* Touch and hold a Model Tree row for its menu. */
.layout-overlay{position:absolute;inset:0;pointer-events:none;z-index:9}
.row-menu{position:absolute;min-width:150px;background:#fffffff7;border:1px solid var(--border);border-radius:12px;box-shadow:0 10px 30px #25213729;padding:5px;display:flex;flex-direction:column}
.row-menu span{display:flex;align-items:center;gap:9px;padding:7px 9px;border-radius:7px;font-size:12px}
.row-menu span.destructive{color:var(--coral)}
.row-menu .icon{width:17px;height:17px}
.row-menu-blank{width:17px;flex:none}
.embedded .row-menu-blank{width:13px}
.row-menu .is-target{outline:2px solid var(--violet);outline-offset:1px}
.embedded .row-menu{min-width:112px;padding:3px;border-radius:9px}
.embedded .row-menu span{font-size:9.5px;padding:4px 6px;gap:6px}
.embedded .row-menu .icon{width:13px;height:13px}
.tree-note{display:inline-grid;place-items:center;margin-left:auto;margin-right:4px;color:var(--violet)}
.tree-note .icon{width:15px;height:15px}
.tree-note.is-target{outline:2px solid var(--violet);outline-offset:2px;border-radius:6px}

/* Below 860 px the disabled Notes tile would bring the rail down onto Undo (v7 measured 7 px over at 800 px;
   v6 cleared it by 62 px), so it hides. The Notes lesson needs the tile and hides two unused ones instead. */
@media(max-height:860px){.utility-rail #notes-toggle:disabled{display:none}.workspace[data-notes-tutorial="true"] .utility-rail #section-toggle,.workspace[data-notes-tutorial="true"] .utility-rail #xray-toggle{display:none}}
@media(max-height:480px){.embedded .workspace[data-notes-tutorial="true"] .utility-rail #notes-toggle{display:flex}}
