.control-layout-toolbar { display:flex; align-items:center; flex-wrap:wrap; gap:8px 14px; margin:0 0 12px; }
.control-layout-toolbar strong { font-size:13px; }
.control-layout-toolbar .layout-status { flex:1; font-size:12px; color:var(--muted); margin:0; }
.layout-instructions { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
.control-panel-layout { position:relative; display:grid; grid-template-columns:repeat(12,minmax(0,1fr)); column-gap:18px; row-gap:0; align-items:start; }
.control-panel-layout.layout-receiving-drop { padding-bottom:100px; }
.layout-insertion-marker { position:absolute; z-index:6; left:0; right:0; height:36px; transform:translateY(-50%); pointer-events:none; display:grid; place-items:center; border:2px dashed var(--teal); border-radius:8px; background:var(--mint); color:var(--teal-dark); font-size:12px; font-weight:650; }
.layout-insertion-marker[hidden] { display:none; }
.layout-empty-drop-zones { position:absolute; inset:0; z-index:6; pointer-events:none; }
.layout-empty-drop-zone { position:absolute; display:grid; place-items:center; padding:18px; border:2px dashed var(--teal); border-radius:var(--radius); background:#e6f3eead; color:var(--teal-dark); text-align:center; font-size:14px; font-weight:650; box-sizing:border-box; }
.layout-empty-drop-zone>span { max-width:28em; padding:10px 14px; border-radius:8px; background:#ffffffdf; overflow-wrap:anywhere; }
.layout-empty-drop-zone.active { border:3px solid var(--teal); background:#cce7de; box-shadow:inset 0 0 0 3px #ffffffa8; }
.layout-empty-drop-zone.active>span { color:white; background:var(--teal); }
.layout-empty-drop-zone.compact { padding:6px; font-size:12px; }
.layout-empty-drop-zone.compact>span { padding:6px 4px; }
.layout-empty-drop-zone[data-zone="stack"] { min-height:42px; padding:10px; }
.layout-target-hints { display:none; position:absolute; inset:4px; z-index:6; pointer-events:none; }
.layout-dragging .layout-item:not(.layout-drag-source)>.layout-target-hints { display:block; }
.layout-target-hints>span { position:absolute; display:grid; place-items:center; padding:4px; border:2px dashed #63978b; border-radius:8px; color:var(--teal-dark); background:#f3faf6e8; font-size:12px; font-weight:650; box-sizing:border-box; }
.layout-target-hints>[data-zone="top"] { inset:0 25% auto; height:40px; }
.layout-target-hints>[data-zone="bottom"] { inset:auto 25% 0; height:40px; }
.layout-target-hints>[data-zone="left"] { inset:44px 75% 44px 0; }
.layout-target-hints>[data-zone="right"] { inset:44px 0 44px 75%; }
.layout-item { grid-column:span var(--panel-span,12); min-width:0; min-height:220px; position:relative; display:flex; flex-direction:column; border:1px solid var(--line); border-radius:var(--radius); background:var(--paper); box-shadow:0 3px 14px #244b3505; scroll-margin-top:160px; }
.layout-item[data-layout-id="joints"] { background:transparent; border:0; border-radius:0; box-shadow:none; }
.layout-item[data-layout-id="joints"]:not([data-fixed-height="true"])>.layout-item-body { overflow:visible; border-radius:0; }
.joint-layout-actions { display:inline-flex; align-items:center; flex:none; gap:4px; }
.joint-layout-actions .layout-move-handle { min-width:28px; padding-inline:4px; color:#627b6f; }
.joint-layout-actions .layout-fit-height { white-space:nowrap; }
.layout-item[data-layout-id="favorites"]:has(.sequence-library:not([open])) { min-height:0; height:auto!important; }
.layout-item[data-library-collapsed="true"]>.layout-resize-height,
.layout-item[data-library-collapsed="true"]>.layout-resize-both { display:none; }
.layout-item-tools { flex:none; min-height:32px; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:3px 12px; border-bottom:1px solid #e7ece8; border-radius:var(--radius) var(--radius) 0 0; background:var(--canvas); }
.layout-item-tools-clickable { cursor:pointer; }
.layout-item-tools-clickable:hover { background:var(--mint); }
.layout-move-handle,.layout-fit-height { min-height:32px; border:0; border-radius:4px; background:transparent; color:var(--muted); font-size:12px; padding:4px 6px; }
.layout-move-handle { touch-action:none; cursor:grab; }
.layout-move-handle:hover,.layout-fit-height:hover { background:var(--mint); color:var(--teal-dark); }
.layout-move-handle:focus-visible,.layout-fit-height:focus-visible,.layout-resize-handle:focus-visible { outline:2px solid var(--teal); outline-offset:2px; }
.layout-item-body { flex:1; min-width:0; min-height:0; overflow:auto; border-radius:0 0 var(--radius) var(--radius); }
.layout-item-body>.panel { border:0; border-radius:0; box-shadow:none; margin:0; overflow:visible; }
.layout-resize-handle { position:absolute; z-index:5; border:0; padding:0; background:transparent; touch-action:none; color:#74968a; }
.layout-resize-width { top:42px; bottom:30px; right:-8px; width:16px; cursor:ew-resize; }
.layout-resize-height { left:14px; right:30px; bottom:-8px; height:16px; cursor:ns-resize; }
.layout-resize-both { bottom:1px; right:1px; width:32px; height:32px; border-radius:0 0 var(--radius) 0; cursor:nwse-resize; background:transparent; }
.layout-resize-both::before { content:''; position:absolute; right:5px; bottom:5px; width:10px; height:10px; background:repeating-linear-gradient(135deg,transparent 0 3px,currentColor 3px 4px); clip-path:polygon(100% 0,100% 100%,0 100%); opacity:.7; }
.layout-resize-both:hover { background:#14776e12; color:var(--teal); }
.layout-resize-both:hover::before,.layout-resize-both:focus-visible::before { opacity:1; }
.layout-resize-width:hover,.layout-resize-height:hover { background:#14776e28; }
.layout-dragging,.layout-resizing { user-select:none; }
.layout-dragging .layout-move-handle { cursor:grabbing; }
.layout-drag-source { opacity:.5; }
.layout-drag-ghost { position:fixed; z-index:100; pointer-events:none; padding:10px 16px; border-radius:8px; color:white; background:var(--teal); box-shadow:0 6px 24px #152d3933; font-size:13px; }
.layout-item[data-drop-zone]::after { content:attr(data-drop-label); display:grid; place-items:center; padding:12px; text-align:center; font-size:13px; font-weight:650; color:var(--teal-dark); position:absolute; z-index:7; pointer-events:none; border:3px solid var(--teal); border-radius:8px; background:#d3eadeeb; }
.layout-item[data-drop-zone="left"]::after { inset:4px 50% 4px 4px; }
.layout-item[data-drop-zone="right"]::after { inset:4px 4px 4px 50%; }
.layout-item[data-drop-zone="top"]::after { inset:4px 4px 78% 4px; }
.layout-item[data-drop-zone="bottom"]::after { inset:78% 4px 4px 4px; }
.layout-item[data-drop-zone="stack"]::after { inset:78% 4px 4px 4px; }
/* Contents respond to their panel width, including when the screen stays wide. */
.layout-item .servo-grid,.layout-item .servo-grid[data-filter="arms"] { grid-template-columns:repeat(auto-fit,minmax(min(230px,100%),1fr)); padding:14px 18px 20px; }
.layout-item .joint-toolbar,.layout-item .robot3d-toolbar { flex-wrap:wrap; }
.layout-item .joint-control-options { margin-left:auto; }
.layout-item .position-catalog .position-picker-group,.layout-item .position-catalog .position-picker-group-items:not(.sequence-user-groups) { grid-template-columns:repeat(auto-fill,minmax(min(116px,100%),1fr)); }
.layout-item .dance-choices { grid-template-columns:repeat(auto-fit,minmax(min(240px,100%),1fr)); }
.layout-item[data-fixed-height="true"]>.layout-item-body>.sequence-panel { display:flex; flex-direction:column; min-height:100%; height:100%; }
.layout-item[data-fixed-height="true"]>.layout-item-body>.sequence-panel>.table-scroller { flex:1 0 150px; min-height:150px; max-height:none; }
/* The library's two scroll areas share the manually resized panel's free height. */
.layout-item[data-layout-id="favorites"][data-fixed-height="true"]>.layout-item-body>.quick-poses-panel { display:flex; flex-direction:column; height:100%; min-height:100%; box-sizing:border-box; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .gallery-persistence { flex:none; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .position-catalog,
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .position-picker-popup,
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .position-picker-list,
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .sequence-library[open] { display:flex; flex-direction:column; flex:1; min-height:0; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .position-picker-popup { overflow:visible; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .sequence-library[open]::details-content { display:contents; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .sequence-library-heading,
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .sequence-favorites { flex:none; }
.layout-item[data-layout-id="favorites"][data-fixed-height="true"] .sequence-library-browser { flex:1 0 120px; min-height:120px; height:auto; }
.layout-item .sequence-panel>.panel-heading,.layout-item .sequence-title-row,.layout-item .heading-actions,.layout-item .playback-footer,.layout-item .playback-buttons { flex-wrap:wrap; }
.layout-item .sequence-panel>.panel-heading,.layout-item .sequence-title-row,.layout-item .sequence-actions,.layout-item .playback-footer { padding-inline:18px; }
.layout-item .table-hint { overflow-wrap:anywhere; }
.layout-item .empty-state { min-height:200px; padding:24px 18px; }
.layout-item .sequence-panel>.table-scroller:has(#emptySequence:not([hidden])) { display:flex; flex-direction:column; }
.layout-item .empty-state { flex:1; }
.layout-item[data-fixed-height="true"] .joint-panel { min-height:100%; height:100%; display:flex; flex-direction:column; }
.layout-item[data-fixed-height="true"] .joint-dual-view { flex:1; min-height:0; align-items:stretch; }
.layout-item[data-fixed-height="true"] #graphicalJointView:not([hidden]):not(.expanded) { display:flex; flex-direction:column; flex:1; }
.layout-item[data-fixed-height="true"] #graphicalJointView:not(.expanded) .robot3d-viewport { flex:1 0 420px; height:auto; }
.layout-item:not([data-panel-width="large"]) .joint-panel>.joint-panel-heading { grid-template-columns:1fr auto; gap:12px; padding:18px; }
.layout-item:not([data-panel-width="large"]) .joint-panel-heading>h2 { grid-column:1; grid-row:1; }
.layout-item:not([data-panel-width="large"]) .joint-panel-heading>.joint-transition-time { grid-column:2; grid-row:1; }
.layout-item:not([data-panel-width="large"]) .joint-panel-heading>.joint-view-tabs { grid-column:1/-1; grid-row:2; }
.layout-item:not([data-panel-width="large"]) .joint-toolbar { padding:0 18px 12px; }
.layout-item:not([data-panel-width="large"]) .position-catalog .position-picker-favorites>.position-catalog-toolbar { position:static; justify-content:flex-end; flex-wrap:wrap; padding-bottom:8px; }
.layout-item:not([data-panel-width="large"]) .position-catalog .position-picker-favorites>.position-picker-disclosure>summary { min-height:38px; line-height:1.5; padding-right:0; }
.layout-item:not([data-panel-width="large"]) .position-visual-picker.position-catalog { margin-inline:8px; }
.layout-item:not([data-panel-width="large"]) .factory-dances { margin-inline:18px; }
.layout-item[data-panel-width="small"] .joint-panel>.joint-panel-heading { grid-template-columns:1fr; }
.layout-item[data-panel-width="small"] .joint-panel-heading>.joint-transition-time { grid-column:1; grid-row:2; justify-self:start; }
.layout-item[data-panel-width="small"] .joint-toolbar,.layout-item[data-panel-width="small"] .joint-control-options { justify-content:flex-start; margin-left:0; }
.layout-item[data-panel-width="small"] .sequence-title-row>span { white-space:normal; }
.layout-item[data-panel-width="small"] .robot3d-joint-control { gap:12px; padding:14px; }
@media(max-width:650px) {
  .control-panel-layout { column-gap:16px; }
  .layout-item:not([data-panel-width="large"]) .position-visual-picker.position-catalog { margin-inline:8px; }
  .layout-item { scroll-margin-top:235px; }
  .control-layout-toolbar .layout-status { flex-basis:100%; order:3; }
}
.servo-card { position:relative; }
.servo-card-top>.servo-title { flex:1; }
.joint-card-move { flex:none; width:28px; min-height:28px; padding:0; border-radius:4px; background:transparent; color:var(--muted); cursor:grab; touch-action:none; font-size:15px; }
.joint-card-move:hover,.joint-card-move:focus-visible { color:white; background:var(--teal); }
.joint-card-dragging-page { user-select:none; }
.joint-card-dragging .joint-card-move { cursor:grabbing; }
.joint-card-drag-source { opacity:.4; }
.joint-card-dragging .servo-card:not(.joint-card-drag-source) { outline:1px dashed #82b4a6; outline-offset:2px; }
.servo-card[data-joint-drop]::after { position:absolute; z-index:8; display:grid; place-items:center; pointer-events:none; padding:6px; border:3px solid var(--teal); border-radius:8px; color:var(--teal-dark); background:#d3eadeeb; font-size:12px; font-weight:650; text-align:center; }
.servo-card[data-joint-drop="before"]::after { content:'Place before'; inset:0 50% 0 0; }
.servo-card[data-joint-drop="after"]::after { content:'Place after'; inset:0 0 0 50%; }

/* Collapsible panels: the title bar names the panel and folds it away. */
.layout-item-actions { display:flex; align-items:center; gap:4px; margin-left:auto; }
.layout-move-handle { font-weight:600; color:var(--ink); }
.layout-collapse { display:grid; place-items:center; width:26px; height:24px; padding:0; border:0; border-radius:4px; background:transparent; color:var(--muted); font-size:14px; line-height:1; cursor:pointer; }
.layout-collapse:hover { background:var(--mint); color:var(--teal-dark); }
.layout-collapse:focus-visible { outline:2px solid var(--teal); outline-offset:2px; }
.layout-item[data-collapsed="true"] { height:auto !important; min-height:0; }
.layout-item[data-collapsed="true"] .layout-item-tools { border-bottom:0; border-radius:var(--radius); }
.layout-item[data-collapsed="true"] .layout-resize-handle { display:none; }

/* A larger, easy-to-hit collapse control. */
.layout-collapse { width:78px; height:32px; font-size:20px; border-radius:8px; }
@media(pointer:coarse),(max-width:650px) {
  .layout-move-handle,.layout-fit-height,.layout-collapse { min-height:44px; }
  .joint-card-move,.joint-sliders-pane .joint-card-move { width:44px; height:44px; min-height:44px; }
  .layout-resize-width { right:-12px; width:24px; }
  .layout-resize-height { bottom:-12px; height:24px; }
  .layout-resize-both { width:44px; height:44px; }
}

/* ---- Control and Poses as an editor: favorites on top, library left, simulator centre, timeline below ---- */
.editor { --editor-gap:10px; --editor-top:70px; position:relative; display:grid; gap:var(--editor-gap);
  grid-template-columns:minmax(230px,290px) minmax(0,1fr) minmax(210px,250px);
  grid-template-rows:var(--editor-top) clamp(380px,calc(100dvh - 470px),680px) auto;
  grid-template-areas:"favorites favorites favorites" "library viewer properties" "timeline timeline timeline"; }
.editor ~ .control-layout { display:none !important; }
.editor-favorites, .editor-library, .editor-viewer, .editor-properties, .editor-timeline { min-width:0; min-height:0; border:1px solid var(--line); border-radius:10px; background:var(--paper); }
.editor-region-title { font-size:11px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }

/* Favorites: the library draws the strip; it is laid over this reserved row so its own scripts keep working. */
.editor-favorites { grid-area:favorites; display:flex; align-items:center; padding:0 14px; }
.editor-library { grid-area:library; overflow:auto; scrollbar-gutter:stable; }
.editor-library :is(.quick-poses-panel, #visualPositionPicker, .position-picker-popup, .position-picker-list) { position:static; overflow:visible; max-height:none; margin:0; padding:0; border:0; border-radius:0; background:transparent; box-shadow:none; transform:none; contain:none; }
.editor .sequence-favorites { position:absolute; top:0; left:104px; right:8px; height:var(--editor-top); margin:0; padding:7px 4px; display:flex; flex-wrap:nowrap; align-items:center; gap:8px; overflow-x:auto; overflow-y:hidden; scrollbar-width:thin; }
.editor .sequence-favorites:has(details[open]) { overflow:visible; }
.editor .sequence-favorites > .position-picker-empty { margin:0; font-size:13px; color:var(--muted); }

.editor-viewer { grid-area:viewer; display:flex; flex-direction:column; overflow:hidden; }
.editor-modes { display:flex; align-items:center; gap:4px; padding:7px 10px; border-bottom:1px solid var(--line); background:#f6f9f6; }
.editor-modes::before { content:"Edit position"; margin-right:6px; font-size:11px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }
.editor-mode { min-height:32px; padding:5px 12px; border:1px solid transparent; border-radius:7px; background:transparent; color:var(--ink); font-size:13px; font-weight:650; cursor:pointer; }
.editor-mode:hover { background:var(--mint); }
.editor-mode[aria-selected="true"] { background:var(--navy); color:#fff; }
.editor-stage { position:relative; flex:1; min-height:0; display:grid; grid-template-columns:minmax(0,1fr); grid-template-rows:minmax(0,1fr); }
.editor-stage > #graphicalJointView { min-width:0; min-height:0; }
.editor-servos, .editor-teach { display:none; min-width:0; min-height:0; }

/* All servos: the right-hand joints sit left of the model and the left-hand joints right of it, as you face it. */
.editor-stage[data-mode="servos"] { grid-template-columns:minmax(168px,230px) minmax(0,1fr) minmax(168px,230px); grid-template-rows:auto repeat(9,minmax(0,1fr)); gap:4px 10px; padding:6px 10px 8px; overflow:auto; }
.editor-stage[data-mode="servos"] > #graphicalJointView { grid-column:2; grid-row:2 / -1; }
.editor-stage[data-mode="servos"] :is(.editor-servos, #jointSlidersPanel, #servoGrid) { display:contents; }
.editor-stage[data-mode="servos"] #jointSlidersPanel > :not(#servoGrid) { grid-column:1 / -1; grid-row:1; margin:0; }
.editor-stage[data-mode="servos"] #jointSlidersPanel > :is(.draft-explainer, #liveHint, h3) { display:none; }
.editor-stage[data-mode="servos"] .servo-group-label { display:none; }
.editor-stage[data-mode="servos"] .servo-card { grid-column:2; grid-row:var(--servo-row,auto); align-self:center; margin:0; padding:5px 8px; border-radius:8px; }
.editor-stage[data-mode="servos"] .servo-card[data-side="right"] { grid-column:1; }
.editor-stage[data-mode="servos"] .servo-card[data-side="left"] { grid-column:3; }

/* Ragdoll: the teach-by-hand controls sit beside the model. */
.editor-stage[data-mode="ragdoll"] { grid-template-columns:minmax(0,1fr) minmax(230px,300px); }
.editor-stage[data-mode="ragdoll"] .editor-teach { display:block; overflow:auto; border-left:1px solid var(--line); }
.editor-teach #ragdolModePanel { margin:0; border:0; border-radius:0; box-shadow:none; }

.editor-properties { grid-area:properties; padding:12px; overflow:auto; display:flex; flex-direction:column; gap:10px; }
.editor-timeline { grid-area:timeline; padding:8px 10px; }
.editor-timeline #sequenceEditor { margin:0; padding:0; border:0; background:transparent; box-shadow:none; }

/* While the real robot is moving, the whole viewer becomes the stop control. */
.editor-stop { position:absolute; inset:0; z-index:6; display:grid; place-content:center; justify-items:center; gap:14px; border:0; border-radius:0; background:#3a0d06b8; cursor:pointer; }
.editor-stop-sign { display:grid; place-items:center; width:min(46%,260px); min-width:150px; aspect-ratio:1; clip-path:polygon(30% 0,70% 0,100% 30%,100% 70%,70% 100%,30% 100%,0 70%,0 30%); background:#c62f1c; color:#fff; font-size:clamp(34px,6vw,64px); font-weight:800; letter-spacing:.04em; box-shadow:inset 0 0 0 7px #fff, inset 0 0 0 11px #c62f1c; }
.editor-stop-note { max-width:36ch; padding:6px 12px; border-radius:8px; background:#fff; color:#7a1c10; font-size:14px; font-weight:650; text-align:center; }
.editor-stop:hover .editor-stop-sign, .editor-stop:focus-visible .editor-stop-sign { background:#a92514; }

@media (max-width:1040px) {
  .editor { grid-template-columns:minmax(0,1fr); grid-template-rows:var(--editor-top) minmax(420px,62dvh) auto minmax(220px,40dvh) auto; grid-template-areas:"favorites" "viewer" "timeline" "library" "properties"; }
}
/* Favorites as compact chips: sketch, name, then Play and Load. */
.editor .sequence-favorites .position-picker-card { flex:none; display:flex; align-items:center; gap:6px; width:auto; min-width:0; height:54px; margin:0; padding:4px 6px 4px 4px; border:1px solid var(--line); border-radius:9px; background:#fff; box-shadow:none; }
.editor .sequence-favorites .position-picker-option { display:flex; align-items:center; gap:7px; min-width:0; min-height:0; padding:0; border:0; background:transparent; }
.editor .sequence-favorites .position-picker-thumbnail { flex:none; width:40px; height:44px; overflow:hidden; }
.editor .sequence-favorites .position-picker-caption { min-width:0; max-width:150px; font-size:12px; line-height:1.3; }
.editor .sequence-favorites .position-picker-card-actions { position:static; display:flex; gap:4px; margin:0; padding:0; border:0; background:transparent; }
.editor .sequence-favorites .position-picker-card-actions button { min-height:30px; padding:3px 9px; font-size:12px; }
.editor .sequence-favorites .position-picker-item-menu { position:relative; inset:auto; }

/* Library as one narrow column: folders as chips across the top, sequences as a list under them. */
.editor-library .gallery-persistence { padding:8px 12px 0; font-size:11px; color:var(--muted); }
.editor-library .sequence-library { margin:0; border:0; }
.editor-library .sequence-library-heading { position:sticky; top:0; z-index:2; padding:8px 12px; background:var(--paper); border-bottom:1px solid var(--line); pointer-events:none; list-style:none; }
.editor-library .sequence-library-heading::-webkit-details-marker { display:none; }
.editor-library .sequence-library-browser { display:block; height:auto; min-height:0; }
.editor-library .sequence-folder-pane { display:flex; flex-wrap:wrap; gap:4px; width:auto !important; max-width:none; height:auto; padding:8px 10px 2px; border:0; overflow:visible; }
.editor-library .sequence-library-splitter { display:none; }
.editor-library .sequence-content-pane { width:auto !important; height:auto; padding:4px 10px 10px; overflow:visible; }
.editor-library .sequence-content-pane .position-picker-group-items { display:grid; grid-template-columns:minmax(0,1fr); gap:6px; }
.editor-library .sequence-content-pane .position-picker-card { width:auto; max-width:none; }

/* The model fills whatever room the stage has. */
.editor-stage > #graphicalJointView { display:flex; flex-direction:column; height:100%; margin:0; border:0; border-radius:0; background:transparent; }
.editor-stage .robot3d-view-heading { flex:none; margin:0; padding:5px 10px; }
.editor-stage .joint-view-heading { display:none; }
.editor-stage .robot3d-viewport { flex:1 1 auto; height:auto; min-height:180px; }

/* Playback sits under the picture. */
.editor-viewer > .sequence-playback-controls { flex:none; display:flex; justify-content:center; margin:0; padding:6px 10px; border:0; border-top:1px solid var(--line); border-radius:0; background:#f6f9f6; }

/* Timeline: one row of file and edit actions, then the track, the audio lane and the rest. */
.editor-timeline #sequenceEditor { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:6px 10px; align-items:center; }
.editor-timeline :is(#sequenceTools, .sequence-timeline-editor) { display:contents; }
.editor-timeline #sequenceEditor > *, .editor-timeline #sequenceTools > *, .editor-timeline .sequence-timeline-editor > * { grid-column:1 / -1; min-width:0; margin:0; }
.editor-timeline .sequence-actions { grid-column:1; grid-row:1; padding:0; }
.editor-timeline .sequence-file-actions { grid-column:2; grid-row:1; padding:0; }
.editor-timeline .sequence-timeline { min-height:74px; padding:6px; border:1px solid var(--line); border-radius:8px; background:#f6f9f6; }
.editor-timeline .sequence-editing-details > summary { padding:6px 10px; }
.editor-timeline .sequence-editing-details > .sequence-clipboard-toolbar { padding:0 10px 8px; }
/* One screen where there is room: the simulator takes what the favorites row and the timeline leave. */
.editor { --editor-top:60px; height:max(640px,calc(100dvh - 190px)); grid-template-rows:var(--editor-top) minmax(300px,1fr) auto; }
.editor-timeline { max-height:44dvh; overflow:auto; }
.editor-timeline :is(#sequenceTools, .sequence-timeline-editor) { display:contents !important; }
.editor-timeline .sequence-file-actions { grid-column:2 !important; grid-row:1 !important; justify-self:end; }
.editor-timeline .sequence-actions { grid-column:1 !important; grid-row:1 !important; }
.editor-stage .robot3d-view-heading { min-height:0; padding:3px 10px; gap:8px; }
.editor-stage .robot3d-view-heading .button { min-height:30px; padding-block:3px; }
.editor-viewer > .sequence-playback-controls { padding:4px 10px; }
.editor-viewer > .sequence-playback-controls .sequence-transport { flex-wrap:nowrap; margin:0; padding:0; border:0; background:transparent; box-shadow:none; }
.editor-library .sequence-content-pane .position-picker-card { display:grid; grid-template-columns:minmax(0,1fr) auto; width:100% !important; }
.editor .sequence-favorites .position-picker-card { height:48px; }
.editor .sequence-favorites .position-picker-thumbnail { height:40px; }
/* The bar above the picture holds the edit modes and the viewer's own controls. */
.editor-viewer-bar { flex:none; display:flex; flex-wrap:wrap; align-items:center; gap:6px 12px; padding:6px 10px; border-bottom:1px solid var(--line); background:#f6f9f6; }
.editor-viewer-bar .editor-modes { padding:0; border:0; background:transparent; }
.editor-viewer-bar .robot3d-view-heading { display:flex; align-items:center; gap:8px; margin:0 0 0 auto; padding:0; min-height:0; border:0; background:transparent; }
.editor-viewer-bar .robot3d-view-heading .joint-view-heading { display:none; }
.editor-viewer-bar .robot3d-view-heading .button { min-height:30px; padding-block:3px; }
.editor .sequence-favorites .position-picker-card { flex-direction:row; }
.editor .sequence-favorites .position-picker-item-menu { order:3; }

/* A slim timeline, so the picture keeps most of the height. */
.editor-timeline { padding:6px 10px; }
.editor-timeline .sequence-actions, .editor-timeline .sequence-file-actions { min-height:0; gap:6px; }
.editor-timeline :is(.sequence-actions, .sequence-file-actions) :is(input, button) { min-height:32px; padding-block:3px; }
.editor-timeline .sequence-timeline { min-height:66px; padding:4px 6px; }
.editor-timeline #sequenceAudio summary, .editor-timeline .sequence-editing-details > summary { min-height:0; padding:4px 10px; }
.editor-timeline #sequenceRecoveryStatus { font-size:11px; }
.editor-timeline #sequenceRecoveryStatus:empty { display:none; }.editor-viewer-bar { flex-wrap:nowrap; }
.editor-viewer-bar .editor-modes { flex:none; }
.editor-viewer-bar .robot3d-view-heading { display:flex !important; flex-wrap:nowrap; min-width:0; }
.editor-viewer-bar .robot3d-view-heading > * { position:static; margin:0; }
.editor-timeline .sequence-actions { padding:0 !important; min-height:0 !important; border:0 !important; }
.editor-timeline .sequence-editing-details { border-radius:8px; }
.editor-timeline .sequence-editing-details > summary { min-height:0 !important; padding:4px 10px !important; font-size:12px; }
.editor-timeline #sequenceAudio summary { min-height:0 !important; padding-block:3px !important; }
/* Selected position */
.editor-properties .editor-selection { margin:0; font-size:13px; line-height:1.45; color:var(--ink); }
.editor-properties .sequence-pose-namebar { display:grid; gap:6px; margin:0; padding:0; border:0; background:transparent; }
.editor-properties .sequence-pose-namebar input { width:100%; min-width:0; }
.editor-properties #editorSendPose { width:100%; }
.editor-properties .microcopy { margin:0; }

/* The preview window floats over the editor and can be dragged by its title bar or resized from its corner. */
.preview-window { position:fixed; top:120px; right:28px; z-index:40; display:flex; flex-direction:column; width:min(560px,calc(100vw - 24px)); height:min(560px,calc(100dvh - 140px)); min-width:320px; min-height:320px; resize:both; overflow:hidden; border:1px solid var(--navy); border-radius:12px; background:var(--paper); box-shadow:0 18px 50px #0b1f2a59; }
.preview-window-bar { flex:none; display:flex; align-items:center; gap:10px; padding:7px 8px 7px 14px; background:var(--navy); color:#fff; cursor:move; touch-action:none; user-select:none; }
.preview-window-bar strong { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:14px; }
.preview-window-facts { flex:1; font-size:12px; color:#c9d8de; white-space:nowrap; }
.preview-window-close { min-width:32px; min-height:32px; border:0; border-radius:7px; background:transparent; color:#fff; font-size:15px; cursor:pointer; }
.preview-window-close:hover { background:#ffffff26; }
.preview-window-stage { position:relative; flex:1; min-height:0; display:grid; grid-template:minmax(0,1fr) / minmax(0,1fr); }
.preview-window-stage > #graphicalJointView { display:flex; flex-direction:column; min-width:0; min-height:0; margin:0; border:0; border-radius:0; }
.preview-window-stage .robot3d-viewport { flex:1 1 auto; height:auto; min-height:160px; }
.preview-window-controls { flex:none; display:flex; align-items:center; gap:8px; padding:8px 10px; border-top:1px solid var(--line); background:#f6f9f6; }
.preview-window-controls input[type="range"] { flex:1; min-width:60px; accent-color:var(--teal); }
.preview-window.robot-target .transport-target button.on { background:#fde6d8; color:#8a3f15; }
/* While the model is in the preview window, say where it went. */
.editor-stage:not(:has(#graphicalJointView))::before { content:"The simulator is in the preview window. Close the window to bring it back."; align-self:center; justify-self:center; max-width:34ch; padding:16px; color:var(--muted); font-size:13px; text-align:center; }

/* All servos: compact controls, with the step buttons and number beside each slider. */
.editor-stage[data-mode="servos"] .joint-toolbar [data-joint-filter] { display:none; }
.editor-stage[data-mode="servos"] .servo-card { min-width:0; box-shadow:none; }
.editor-stage[data-mode="servos"] .servo-card-top { margin:0 0 2px; gap:6px; }
.editor-stage[data-mode="servos"] .servo-title { font-size:12px; }
.editor-stage[data-mode="servos"] .robot3d-viewport { min-height:240px; }
/* All servos, compact: name and id, then slider, number and step buttons. The model stays put while the list scrolls. */
.editor-stage[data-mode="servos"] { grid-template-columns:minmax(150px,1fr) minmax(170px,1.15fr) minmax(150px,1fr); grid-template-rows:auto repeat(9,auto); align-content:start; }
.editor-stage[data-mode="servos"] > #graphicalJointView { position:sticky; top:0; align-self:start; height:calc(var(--stage-height,360px) - 62px); min-height:200px; }
.editor-stage[data-mode="servos"] .robot3d-camera-actions > :not(#editorPoseMenu), .editor-stage[data-mode="servos"] #robot3dRestPosition { display:none; }
.editor-stage[data-mode="servos"] .robot3d-viewport { min-height:0; }
.editor-stage[data-mode="servos"] .servo-card { display:grid; grid-template-columns:minmax(0,1fr) auto; grid-template-areas:"top top" "range number" "footer footer"; gap:1px 6px; padding:4px 8px; align-self:start; }
.editor-stage[data-mode="servos"] .servo-card-top { grid-area:top; min-height:0; }
.editor-stage[data-mode="servos"] .servo-target { display:contents; }
.editor-stage[data-mode="servos"] .servo-range { grid-area:range; width:100%; min-width:0; margin:0; }
.editor-stage[data-mode="servos"] .servo-number-control { grid-area:number; }
.editor-stage[data-mode="servos"] .servo-number { width:54px; min-height:28px; padding:2px 4px; }
.editor-stage[data-mode="servos"] .servo-number-step { min-height:14px; height:14px; padding:0 5px; font-size:8px; line-height:1; }
.editor-stage[data-mode="servos"] .servo-card-footer { grid-area:footer; min-height:0; margin:0; padding:0; border:0; font-size:10px; }
.editor-stage[data-mode="servos"] .joint-card-move { display:none; }
.editor[data-connected="false"] .editor-stage[data-mode="servos"] .servo-card-footer { display:none; }
.editor-properties #editorAddPose { width:100%; }.editor { height:max(720px,calc(100dvh - 190px)); }
.editor-viewer-bar .robot3d-view-heading label, .editor-viewer-bar .robot3d-view-heading .switch-label, .editor-viewer-bar .robot3d-view-heading span { white-space:nowrap; }
.editor-viewer-bar .editor-modes::before { display:none; }

/* Proportions: the picture gets the room. The timeline is a strip of a set height that scrolls, and the line
   above it drags. */
.editor { --editor-top:50px; --editor-timeline:262px; height:max(700px,calc(100dvh - 176px)); grid-template-rows:var(--editor-top) minmax(0,1fr) var(--editor-timeline); }
.editor-timeline { max-height:none; overflow:auto; scrollbar-gutter:stable; }
.editor-splitter { grid-area:timeline; align-self:start; z-index:5; height:10px; margin-top:calc(-1 * var(--editor-gap)); cursor:row-resize; touch-action:none; }
.editor-splitter::before { content:""; display:block; width:48px; height:4px; margin:3px auto 0; border-radius:4px; background:#b9c9c0; }
.editor-splitter:hover::before, .editor-splitter:focus-visible::before { background:var(--teal); }
.editor-splitter:focus-visible { outline:none; }
.editor .sequence-favorites .position-picker-card { height:40px; }
.editor .sequence-favorites .position-picker-thumbnail { width:30px; height:32px; }
.editor .sequence-favorites { padding-block:4px; }
/* Play under the picture already previews in the simulator, so the timeline needs no second preview button. */
.editor-timeline .sequence-tools-toolbar { display:none; }
.editor-timeline .sequence-pose-card { height:88px; aspect-ratio:auto; padding:4px 6px; }
.editor-timeline .sequence-pose-card > svg { height:34px; }
.editor-timeline #sequenceRecoveryStatus { grid-column:1 / -1; justify-self:start; }
/* The viewer's own controls sit on one line beside the modes. */
.editor-viewer-bar { min-height:44px; padding-block:5px; }
.editor-viewer-bar .robot3d-read-pose { flex:0 1 auto; order:0; margin:0; }
.editor-viewer-bar .robot3d-motion-actions { flex:none; min-width:max-content; margin:0; }
.editor-viewer-bar .robot3d-motion-actions #robot3dBodyFeetToggle { flex:none; min-height:30px; max-width:none; white-space:nowrap; }
.editor-stage .robot3d-sequence-status { flex:none; padding:4px 12px; }
.editor-stage:not([data-mode="servos"]) .robot3d-viewport { min-height:0; }
@media (max-width:1040px) {
  .editor { height:auto; grid-template-rows:var(--editor-top) minmax(420px,62dvh) auto minmax(220px,40dvh) auto; }
  .editor-splitter { display:none; }
}
/* Library cards: one row each, with a star that keeps the sequence in the Favorites bar. */
.editor-library .position-picker-card { position:relative; }
.editor-library .position-picker-star { position:absolute; top:3px; right:3px; z-index:3; display:grid; place-items:center; width:26px; height:26px; padding:0; border:0; border-radius:6px; background:transparent; color:#8aa39a; font-size:17px; line-height:1; cursor:pointer; }
.editor-library .position-picker-star:hover:not(:disabled) { background:var(--mint); color:var(--teal-dark); }
.editor-library .position-picker-star[aria-pressed="true"] { color:#d4930f; }
.editor-library .position-picker-star:disabled { opacity:.45; cursor:default; }
.editor-library .sequence-content-pane .position-picker-group-items { grid-template-columns:minmax(0,1fr) !important; }
.editor-library .sequence-content-pane .position-picker-card { grid-template-columns:minmax(0,1fr) !important; width:auto !important; max-width:none !important; }
.editor-library .position-picker-card .position-picker-name-row { padding-right:24px; }
/* A library sequence previewing in the main viewer: what it is, where it is, and Stop. */
.editor-now-playing { flex:none; display:flex; align-items:center; gap:8px; padding:4px 10px; border-top:1px solid var(--line); background:#eaf4ee; font-size:12px; }
.editor-now-playing[hidden] { display:none; }
.editor-now-playing strong { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.editor-now-playing input[type="range"] { flex:1; min-width:60px; accent-color:var(--teal); }
.editor-now-playing .transport-button { min-width:32px; min-height:28px; }

/* An imported robot in the viewer: its own picture and joint controls take the place of TonyPi's. */
.editor-robot-button { flex:none; max-width:200px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.imported-robot { display:none; min-width:0; min-height:0; }
.editor-stage[data-robot="imported"] { grid-template-columns:minmax(0,1fr); grid-template-rows:minmax(0,1fr); gap:0; padding:0; overflow:hidden; }
.editor-stage[data-robot="imported"] > :is(#graphicalJointView, .editor-servos, .editor-teach) { display:none !important; }
.editor-stage[data-robot="imported"]::before { display:none !important; }
.editor-stage[data-robot="imported"] > .imported-robot { display:grid; grid-column:1 / -1; grid-row:1 / -1; grid-template-columns:minmax(0,1fr); grid-template-rows:minmax(0,1fr); }
.imported-view { position:relative; min-width:0; min-height:0; overflow:hidden; background:linear-gradient(#f5f9f6,#e4eee8); }
.robot-view-canvas { position:absolute; inset:0; display:block; width:100%; height:100%; outline:none; cursor:grab; touch-action:none; }
.robot-view-canvas:active { cursor:grabbing; }
.robot-view-canvas:focus-visible { box-shadow:inset 0 0 0 2px var(--teal); }
.robot-view-note { margin:auto; padding:16px; max-width:36ch; color:var(--muted); font-size:13px; text-align:center; }
.imported-hint { position:absolute; left:10px; bottom:8px; z-index:2; max-width:calc(100% - 150px); margin:0; padding:4px 9px; border-radius:7px; background:#ffffffd9; color:var(--muted); font-size:11px; pointer-events:none; }
.imported-view-tools { position:absolute; right:10px; bottom:8px; z-index:2; display:flex; gap:4px; }
.imported-view-tools .button { min-width:32px; min-height:30px; padding:2px 8px; }
.imported-joints, .imported-teach { display:none; min-width:0; min-height:0; overflow:auto; padding:8px 10px; background:var(--paper); }
.editor-stage[data-robot="imported"][data-mode="servos"] > .imported-robot { grid-template-columns:minmax(280px,40%) minmax(0,1fr); }
.editor-stage[data-robot="imported"][data-mode="servos"] .imported-joints { display:grid; align-content:start; gap:6px; border-right:1px solid var(--line); }
.editor-stage[data-robot="imported"][data-mode="ragdoll"] > .imported-robot { grid-template-columns:minmax(0,1fr) minmax(230px,300px); }
.editor-stage[data-robot="imported"][data-mode="ragdoll"] .imported-view { grid-column:1; grid-row:1; }
.editor-stage[data-robot="imported"][data-mode="ragdoll"] .imported-teach { display:grid; align-content:start; gap:8px; grid-column:2; grid-row:1; border-left:1px solid var(--line); }
.imported-teach h3 { margin:0; font-size:14px; }
.imported-teach .microcopy { margin:0; }
.imported-joint { padding:6px 8px; border:1px solid var(--line); border-radius:9px; background:#fff; }
.imported-joint.selected { border-color:var(--teal); box-shadow:0 0 0 2px #1f8a7c26; }
.imported-joint-head { display:flex; align-items:center; gap:6px; margin-bottom:4px; }
.imported-joint-name { flex:0 1 auto; min-width:0; padding:0; border:0; background:transparent; color:var(--ink); font:inherit; font-size:13px; font-weight:700; text-align:left; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; cursor:pointer; }
.imported-joint-chip { flex:none; padding:1px 7px; border-radius:999px; background:var(--mint); color:var(--teal-dark); font-size:10px; font-weight:700; }
.imported-joint-controls { display:grid; grid-template-columns:26px minmax(0,1fr) 26px; align-items:center; gap:6px; }
.imported-joint-value { flex:none; display:flex; align-items:center; gap:3px; margin-left:auto; }
.imported-joint-value .imported-joint-number { width:62px; }
/* TonyPi's own viewer controls (read pose, free move, grippers) do not apply to an imported robot. */
.editor-viewer:has(.editor-stage[data-robot="imported"]) .robot3d-view-heading { display:none !important; }
.imported-joint-range { width:100%; min-width:0; margin:0; accent-color:var(--teal); }
.imported-joint-number { width:100%; min-width:0; min-height:28px; padding:2px 5px; border:1px solid var(--line); border-radius:6px; background:#fff; color:var(--ink); font:inherit; font-size:12px; text-align:right; }
.imported-joint-unit { min-width:18px; font-size:11px; color:var(--muted); }
.imported-joint-step { width:26px; height:26px; padding:0; border:1px solid var(--line); border-radius:6px; background:#f6f9f6; color:var(--ink); font-size:14px; line-height:1; cursor:pointer; }
.imported-joint-step:hover { background:var(--mint); }
.imported-joint-zero { font-size:11px; font-weight:700; }
/* The Robots dialog: choose the robot in the viewer, import a file, and say which servo moves which joint. */
.robots-dialog { width:min(780px,calc(100vw - 24px)); max-height:calc(100dvh - 40px); padding:0; border:1px solid var(--line); border-radius:14px; background:var(--paper); color:var(--ink); box-shadow:0 20px 60px #0b1f2a59; }
.robots-dialog[open] { display:grid; grid-template-rows:auto minmax(0,1fr); }
.robots-dialog::backdrop { background:#0b1f2a66; }
.robots-dialog.dropping { outline:3px dashed var(--teal); outline-offset:-6px; }
.robots-dialog-head { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:12px 16px; border-bottom:1px solid var(--line); }
.robots-dialog-head h2 { margin:0; font-size:18px; }
.robots-dialog-body { display:grid; align-content:start; gap:14px; min-height:0; padding:14px 16px 18px; overflow:auto; }
.robots-dialog .microcopy { margin:0; }
.robots-list { display:grid; gap:6px; }
.robots-row { display:flex; align-items:center; justify-content:space-between; gap:10px; padding:8px 10px; border:1px solid var(--line); border-radius:9px; background:#fff; }
.robots-choice { display:flex; align-items:center; gap:10px; min-width:0; cursor:pointer; }
.robots-choice-text { display:grid; min-width:0; }
.robots-import { display:grid; gap:6px; justify-items:start; }
.robots-status { margin:0; font-size:13px; }
.robots-status:empty { display:none; }
.robots-status[data-kind="error"] { color:#a12a17; font-weight:650; }
.robots-detail { display:grid; gap:8px; padding-top:12px; border-top:1px solid var(--line); justify-items:start; }
.robots-detail[hidden] { display:none; }
.robots-detail h3 { margin:0; font-size:14px; }
.robots-detail .table-scroller { justify-self:stretch; }
.robots-warnings { margin:0; padding-left:18px; font-size:12px; color:#7a4a12; }
.robots-warnings:empty { display:none; }
.robots-map { width:100%; border-collapse:collapse; font-size:12px; }
.robots-map :is(th,td) { padding:5px 8px; border-bottom:1px solid var(--line); text-align:left; white-space:nowrap; }
.robots-map input[type="number"] { width:76px; min-height:28px; }
.robots-map select { min-height:28px; }
.robots-drive { font-weight:650; }
.imported-joints { overflow-x:hidden; }
.imported-joint { min-width:0; }
.editor-stage[data-robot="imported"][data-mode="servos"] > .imported-robot { grid-template-columns:minmax(300px,44%) minmax(0,1fr); }
.editor-stage[data-robot="imported"][data-mode="servos"] .imported-hint { display:none; }
/* Timeline cards draw TonyPi's stick figure, which says nothing about another robot: show number and time only. */
.editor:has(.editor-stage[data-robot="imported"]) .editor-timeline .sequence-pose-card > svg { display:none; }
.editor:has(.editor-stage[data-robot="imported"]) .editor-timeline .sequence-pose-card { height:64px; justify-content:center; gap:6px; }
.editor:has(.editor-stage[data-robot="imported"]) .editor-timeline .sequence-pose-label { font-size:15px; font-weight:700; }
.imported-teach-servos { display:flex; flex-wrap:wrap; gap:6px; }
/* With the robot chooser in the bar, a narrow viewer lets the bar take a second line instead of cutting controls off. */
.editor-viewer-bar { flex-wrap:wrap; gap:4px 8px; }
.editor-viewer-bar .editor-mode { padding-inline:10px; }
/* The STOP sign sits above everything in the viewer, including the camera controls, and sizes itself to the
   room it has so the word is never cut off. */
.editor-stop { z-index:30; container-type:size; }
.editor-stop-sign { width:auto; min-width:0; height:min(68cqh,280px); font-size:min(17cqh,66px); }
.editor-stop-note { font-size:13px; }
/* The quick Resting / Standing tile is not shown over the viewer: the pose is one click away in Favorites. */
.editor #robot3dRestPosition { display:none !important; }

/* Favorites: one pill per sequence. Click it to play; Load and Remove appear at its end on hover or focus. */
.editor .sequence-favorites { display:none !important; }
.editor-favorites { gap:12px; overflow:hidden; }
.favorite-chips { flex:1; min-width:0; display:flex; align-items:center; gap:8px; padding:6px 2px; overflow-x:auto; overflow-y:hidden; scrollbar-width:thin; }
.favorite-chip { position:relative; flex:none; display:flex; align-items:center; height:34px; border:1px solid var(--line); border-radius:999px; background:#fff; box-shadow:0 1px 2px #0b1f2a0f; overflow:hidden; transition:border-color .12s, box-shadow .12s; }
.favorite-chip:hover, .favorite-chip:focus-within { border-color:var(--teal); box-shadow:0 2px 8px #0b1f2a1f; }
.favorite-chip-run { display:flex; align-items:center; gap:8px; height:100%; padding:0 6px 0 5px; border:0; background:transparent; color:var(--ink); font:inherit; font-size:13px; font-weight:650; white-space:nowrap; cursor:pointer; }
.favorite-chip-run { cursor:grab; touch-action:pan-y; user-select:none; }
.favorite-chip-play { cursor:pointer; }
.favorite-chip[data-favorite-dragging] { opacity:.45; }
.favorite-chip[data-favorite-dragging] .favorite-chip-run { cursor:grabbing; }
.favorite-chip[data-favorite-drop]::after { content:''; position:absolute; inset-block:4px; width:3px; border-radius:3px; background:var(--teal); z-index:1; pointer-events:none; }
.favorite-chip[data-favorite-drop="before"]::after { left:4px; }
.favorite-chip[data-favorite-drop="after"]::after { right:4px; }
.favorite-chip-play { display:grid; place-items:center; width:24px; height:24px; padding-left:2px; border-radius:50%; background:var(--teal); color:#fff; font-size:9px; line-height:1; }
.favorite-chip-run:hover .favorite-chip-play { background:var(--teal-dark); }
.favorite-chip-music { color:#b06a12; font-size:12px; }
.favorite-chip-more { display:grid; place-items:center; width:28px; height:28px; margin-left:auto; margin-right:3px; padding:0; border:0; border-radius:999px; background:transparent; color:var(--ink); font-size:18px; font-weight:700; line-height:1; cursor:pointer; }
.favorite-chip-more:hover, .favorite-chip:has(> .favorite-chip-menu:popover-open) > .favorite-chip-more { background:var(--mint); color:var(--teal-dark); }
.favorite-chip-more:focus-visible { outline-offset:-2px; }
.favorite-chip-menu { position:fixed; inset:auto; width:max-content; margin:0; padding:4px; border:1px solid var(--line); border-radius:8px; background:#fff; color:var(--ink); box-shadow:0 3px 12px #17394426; }
.favorite-chip-menu:popover-open { display:grid; gap:2px; }
.favorite-chip-menu button { padding:7px 10px; min-height:34px; border:0; border-radius:5px; background:transparent; color:inherit; font:inherit; font-size:13px; text-align:left; cursor:pointer; }
.favorite-chip-menu button:hover:not(:disabled), .favorite-chip-menu button:focus-visible { background:var(--mint); }
.favorite-chip-menu button:disabled { opacity:.5; cursor:default; }
.favorite-chips-empty { margin:0; font-size:13px; color:var(--muted); }
@media (hover:none) {
  .favorite-chip-menu button { min-height:44px; }
}

/* Library: folders and files. Click a file for Play and Load; the picker's own tiles sit behind Manage. */
.editor-library { display:flex; flex-direction:column; overflow:hidden; scrollbar-gutter:auto; }
.editor-library[data-view="files"] > :is(.quick-poses-panel, .library-files-back) { display:none !important; }
.editor-library[data-view="manage"] { overflow:auto; }
.editor-library[data-view="manage"] > .library-files { display:none; }
.library-files-back { align-self:flex-start; margin:8px 10px 0; }
.library-files { flex:1; min-height:0; display:flex; flex-direction:column; }
.library-files-head { display:flex; align-items:center; gap:8px; padding:9px 10px 6px 12px; }
.library-files-head strong { font-size:13px; }
.library-files-count { flex:1; min-width:0; font-size:11px; color:var(--muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.library-files-search { flex:none; margin:0 10px 8px; min-height:32px; padding:4px 10px; border:1px solid var(--line); border-radius:8px; background:#fff; color:var(--ink); font:inherit; font-size:13px; }
.library-files-tree { flex:1; min-height:0; overflow:auto; padding:0 6px 10px; }
.library-files-empty { margin:10px 8px; font-size:13px; color:var(--muted); }
.library-folder, .library-file { display:flex; align-items:center; width:100%; border:0; border-radius:7px; background:transparent; color:var(--ink); font:inherit; font-size:13px; text-align:left; cursor:pointer; }
.library-folder { gap:6px; min-height:30px; padding:3px 8px 3px 2px; font-weight:700; }
.library-folder:hover, .library-file:hover { background:#eef4f0; }
.library-folder-arrow { flex:none; width:14px; color:var(--muted); font-size:11px; text-align:center; }
.library-folder-icon { position:relative; flex:none; width:17px; height:12px; margin-top:3px; border-radius:1px 3px 3px 3px; background:#e2b257; }
.library-folder-icon::before { content:""; position:absolute; left:0; top:-3px; width:8px; height:4px; border-radius:2px 2px 0 0; background:#e2b257; }
.library-folder[aria-expanded="true"] .library-folder-icon, .library-folder[aria-expanded="true"] .library-folder-icon::before { background:#efc876; }
.library-folder-name, .library-file-name { flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.library-folder-count { flex:none; font-size:11px; font-weight:600; color:var(--muted); }
.library-folder-files { margin:0 0 4px 9px; padding-left:7px; border-left:1px solid var(--line); }
.library-file { gap:7px; min-height:28px; padding:3px 8px 3px 6px; }
.library-file.selected { background:var(--mint); font-weight:650; }
.library-file-icon { flex:none; display:grid; place-items:center; width:13px; height:16px; border:1.5px solid #9db3a8; border-radius:2px; background:#fff; color:#9a4005; font-size:9px; line-height:1; }
.library-file-icon.pose { height:13px; border-radius:50%; }
.library-file-icon.music { border-color:#dfb78c; background:#fff0d9; }
.library-file-facts { flex:none; font-size:11px; font-weight:500; color:var(--muted); }
.library-file-star { flex:none; color:#d4930f; font-size:11px; }
.library-file-actions { display:flex; flex-wrap:wrap; align-items:center; gap:6px; margin:2px 0 6px; padding:8px; border:1px solid var(--line); border-radius:9px; background:#fff; }
.library-file-actions .button { min-height:30px; padding:4px 10px; font-size:12px; }
.library-file-starbutton { width:30px; height:30px; padding:0; border:1px solid var(--line); border-radius:7px; background:#fff; color:#8aa39a; font-size:15px; line-height:1; cursor:pointer; }
.library-file-starbutton[aria-pressed="true"] { color:#d4930f; }
.library-file-starbutton:disabled { cursor:default; opacity:.7; }
.library-file-detail { flex:1 1 100%; font-size:11px; color:var(--muted); }

/* Favorites stands apart from the panels around it: a warm shelf with a gold star, the colour the library
   uses for a starred sequence. */
.editor-favorites { border-color:#e2bd5c; background:linear-gradient(180deg,#fffaea,#fcedc4); box-shadow:inset 0 1px 0 #fff, 0 1px 3px #7a52001f; }
.editor-favorites .editor-region-title { flex:none; display:flex; align-items:center; gap:7px; color:#7a5200; }
.editor-favorites .editor-region-title::before { content:"★"; display:grid; place-items:center; width:22px; height:22px; border-radius:50%; background:#dd9d15; color:#fff; font-size:12px; letter-spacing:0; box-shadow:0 1px 2px #7a520040; }
.editor-favorites .favorite-chips { scrollbar-color:#d8b765 transparent; }
.editor-favorites .favorite-chip { border-color:#e1c988; box-shadow:0 1px 2px #7a520024; }
.editor-favorites .favorite-chip:hover, .editor-favorites .favorite-chip:focus-within { border-color:#c4860a; box-shadow:0 2px 8px #7a520033; }
.editor-favorites .favorite-chip-play { background:var(--navy); }
.editor-favorites .favorite-chip-run:hover .favorite-chip-play { background:#c4860a; }
.editor-favorites .favorite-chip:has(> .favorite-chip-run[aria-pressed="true"]) { background:var(--mint); border-color:var(--teal); box-shadow:0 0 0 1px var(--teal); }
.editor-favorites .favorite-chip-run[aria-pressed="true"] .favorite-chip-play { background:var(--teal-dark); }
.editor-favorites .favorite-chips-empty { color:#7a5200; }
.robots-active { flex:none; padding:1px 8px; border-radius:999px; background:var(--mint); color:var(--teal-dark); font-size:11px; font-weight:700; }
.robots-choice { cursor:default; }
/* The header's robot menu also lists imported robots, so it may need more room than "Auto". */
.connected-robot-profile { max-width:210px; text-overflow:ellipsis; }

/* ---- Simplified editor ---- */
/* One Add pose button (in the side panel). The viewer keeps only a small camera cluster in its corner; its
   Add and Replace buttons are not shown, since edits save to the selected pose on their own. */
.editor-stage .robot3d-orbit-hint, .editor-stage .robot3d-frame-actions, .editor-stage .robot3d-control-label { display:none !important; }
.editor-stage .robot3d-viewport > .robot3d-camera-dock { inset:auto 8px 6px auto; width:auto; max-height:calc(100% - 12px); overflow:auto; border-radius:10px; }
.editor-stage .robot3d-camera-actions { display:flex; flex-direction:column; align-items:stretch; gap:5px; padding:4px; border:1px solid var(--line); border-radius:inherit; background:#ffffffe6; }
.editor-stage .robot3d-camera-actions :is(.robot3d-camera-mode, .robot3d-zoom-controls) { display:flex; align-items:center; gap:0; margin:0; padding:0; }
.editor-stage .robot3d-camera-actions .button { min-height:28px; min-width:28px; padding:2px 8px; font-size:12px; }
.robot3d-camera-actions .robot3d-pose-options { display:grid; place-items:center; }
.robot3d-pose-options svg { width:18px; height:18px; }
.editor-stage .robot3d-camera-actions output { min-width:40px; min-height:28px; font-size:11px; }
.editor-stage .robot3d-camera-actions .robot3d-zoom-stepper { grid-template-columns:1fr; width:100%; height:auto; }
.editor-stage .robot3d-camera-actions .robot3d-zoom-stepper .button { width:100%; height:24px; min-height:24px; border-radius:6px 6px 0 0; }
.editor-stage .robot3d-camera-actions .robot3d-zoom-stepper .button:last-child { border-radius:0 0 6px 6px; }
.editor-stage .robot3d-camera-actions .robot3d-zoom-stepper output { height:24px; min-height:24px; border-inline:0; border-block:1px solid var(--mint); }
/* "?" in the viewer bar. */
.editor-help { position:relative; flex:none; }
.editor-help > summary { display:grid; place-items:center; width:28px; height:28px; border:1px solid var(--line); border-radius:50%; background:#fff; color:var(--muted); font-size:13px; font-weight:700; list-style:none; cursor:pointer; }
.editor-help > summary::-webkit-details-marker { display:none; }
.editor-help[open] > summary, .editor-help > summary:hover { border-color:var(--teal); color:var(--teal-dark); }
.editor-help-body { position:absolute; top:34px; right:0; z-index:20; width:min(320px,70vw); padding:10px 12px; border:1px solid var(--line); border-radius:10px; background:#fff; box-shadow:0 10px 30px #0b1f2a2e; }
.editor-help-body p { margin:0 0 6px; font-size:12px; line-height:1.45; color:var(--ink); }
.editor-help-body p:last-child { margin-bottom:0; }
/* The library's Load already opens a sequence in the timeline. */
.editor-timeline #openSequenceButton { display:none !important; }
.editor-properties #editorSendPose { margin-top:2px; }
@media (min-width:1041px) {
  body:has(#controlWorkspace:not([hidden])) .editor { height:max(700px,calc(100dvh - 142px)); }
}
/* "?" stays on the first line of the viewer bar, right after the modes. */
.editor-viewer-bar .editor-modes { order:1; }
.editor-viewer-bar .editor-help { order:2; }
.editor-viewer-bar .robot3d-view-heading { order:3; }
/* The camera cluster's two groups sit side by side in their own small box. */
.editor-stage .robot3d-viewport > .robot3d-camera-dock { width:max-content; container-type:normal; contain:none; }
.editor-stage .robot3d-camera-actions { width:max-content; min-height:0; }
.editor-stage .robot3d-camera-actions :is(.robot3d-camera-mode, .robot3d-zoom-controls) { position:static !important; inset:auto; transform:none; flex:none; width:auto !important; }

/* ---- No side panel: library, viewer, timeline. Add pose and Send pose sit with the playback controls. ---- */
.editor { grid-template-columns:minmax(240px,290px) minmax(0,1fr); grid-template-areas:"favorites favorites" "library viewer" "timeline timeline"; }
.editor-properties { display:none !important; }
.editor-viewer > .sequence-playback-controls { align-items:center; justify-content:space-between; flex-wrap:nowrap; gap:5px; padding-inline:8px; overflow-x:auto; scrollbar-width:thin; }
.editor-viewer > .sequence-playback-controls .sequence-transport { flex:1 1 auto; min-width:min-content; gap:4px; }
.editor-viewer .sequence-transport > :not(.transport-counter) { flex:none; }
.editor-viewer .sequence-transport .transport-target button { padding-inline:8px; }
.editor-viewer .sequence-transport .transport-button { min-width:34px; padding-inline:8px; }
.editor-viewer .sequence-transport .transport-button.main { min-width:40px; }
.editor-viewer .sequence-transport .transport-counter { flex:1 1 auto; min-width:9ch; contain:inline-size; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.editor-pose-actions { flex:none; display:flex; align-items:center; gap:4px; margin-left:auto; }
.editor-pose-actions .button { min-height:32px; padding-inline:9px; white-space:nowrap; }
.editor-pose-history { display:inline-flex; align-items:center; gap:2px; margin-right:2px; }
.editor-pose-history .r3d-history-button { min-width:32px; padding:4px; font-size:20px; line-height:1; }
@media (max-width:650px) {
  .editor-viewer > .sequence-playback-controls { flex-wrap:wrap; }
  .editor-pose-actions { flex:1 1 100%; flex-wrap:wrap; justify-content:flex-end; }
}
@media (max-width:1040px) {
  .editor { grid-template-columns:minmax(0,1fr); grid-template-rows:var(--editor-top) minmax(420px,62dvh) auto minmax(220px,40dvh); grid-template-areas:"favorites" "viewer" "timeline" "library"; }
}

/* ---- All servos: small inputs down each side of the robot, each joined to its joint by a line. No scrolling. ---- */
.servo-leaders { position:absolute; inset:0; z-index:4; width:100%; height:100%; overflow:visible; pointer-events:none; }
.servo-leaders path { fill:none; stroke:#7fa59a; stroke-width:1.2; opacity:.75; }
.servo-leaders circle { fill:#177a6e; stroke:#fff; stroke-width:1.5; }
.servo-leaders .hot { stroke:#e07a1f; stroke-width:2.2; opacity:1; }
.servo-leaders circle.hot { fill:#e07a1f; stroke:#fff; stroke-width:1.5; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) { grid-template-columns:minmax(178px,232px) minmax(0,1fr) minmax(178px,232px); grid-template-rows:auto repeat(9,minmax(0,1fr)); gap:2px 0; padding:4px 8px 6px; overflow:hidden; align-content:stretch; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) > #graphicalJointView { position:static; grid-column:2; grid-row:2 / -1; align-self:stretch; height:auto; min-height:0; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) #jointSlidersPanel > :not(#servoGrid) { grid-column:1 / -1; grid-row:1; margin:0; padding:0; min-height:0; font-size:11px; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-card { z-index:5; display:grid; grid-template-columns:minmax(0,1fr) auto; grid-template-areas:"top number" "range number"; align-items:center; align-self:center; gap:0 8px; min-width:0; min-height:0; margin:0; padding:2px 7px; border-radius:8px; background:#fffffff2; box-shadow:none; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-card:is(:hover, :focus-within) { border-color:#e07a1f; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-card-top { grid-area:top; display:flex; align-items:baseline; gap:5px; min-width:0; min-height:0; margin:0; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-title { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:11px; line-height:1.25; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-id { flex:none; padding:0 3px; font-size:9px; font-weight:600; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-range { grid-area:range; width:100%; min-width:0; height:14px; margin:0; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-number-control { grid-area:number; align-self:center; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-number { width:50px; min-height:26px; height:26px; padding:1px 3px; font-size:12px; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-number-step { min-height:13px; height:13px; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-card-footer { display:none !important; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .servo-card.servo-feedback-warning {
  grid-template-areas:"top number" "range number" "feedback feedback";
  border-color:#bd554d;
  background:#fff0ef;
}
.servo-feedback-note { grid-area:feedback; color:#972b22; font-size:10px; font-weight:650; line-height:1.25; }
.servo-feedback-note:focus-visible { outline:2px solid currentColor; outline-offset:1px; border-radius:2px; }
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .robot3d-viewport { min-height:0; }
/* A short name ("Bow") must still leave the play button clear of the tools that appear on hover. */
.favorite-chip { min-width:112px; }
/* All servos shows only the servo controls, on every robot. TonyPi2's calibration tools (readings table,
   camera links, shoulder steps, tilt estimate) belong to Connect & Setup and the classic layout, not this view. */
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) #jointSlidersPanel > :not(#servoGrid, .joint-toolbar),
.editor-stage[data-mode="servos"]:not([data-robot="imported"]) .r3d-mapped-caption { display:none !important; }
/* The editor sends pending 3D edits with Send pose to robot, so the viewer's own Apply button is a duplicate.
   Hidden with CSS, not [hidden], so Send pose keeps reading its ready state. */
.editor-stage #robot3dApplyPending { display:none !important; }
/* The divider under the viewer sets the viewer's height; the timeline keeps its natural height and the page grows. */
@media (min-width:1041px) {
  .editor, body:has(#controlWorkspace:not([hidden])) .editor { height:auto; grid-template-rows:var(--editor-top) var(--editor-viewer, max(340px, calc(100dvh - 474px))) auto; }
  .editor-timeline { max-height:none; overflow:visible; }
}
/* Durations × above the timeline. */
.duration-scale { display:inline-flex; align-items:center; gap:6px; margin:0 0 0 6px; font-size:12px; font-weight:650; color:var(--ink); white-space:nowrap; }
.duration-scale input { width:64px; min-height:30px; padding:2px 6px; border:1px solid var(--line); border-radius:7px; font:inherit; }
.duration-scale input[aria-invalid="true"] { border-color:#c0392b; }
.duration-scale { gap:4px; }
.duration-scale > span:first-child { margin-right:2px; }
.duration-scale-step { width:26px; min-height:30px; padding:0; border:1px solid var(--line); border-radius:7px; background:#fff; color:var(--ink); font-size:15px; font-weight:700; line-height:1; cursor:pointer; }
.duration-scale-step:hover:not(:disabled) { border-color:var(--teal); color:var(--teal); }
.duration-scale-step:disabled { opacity:.4; cursor:default; }
.duration-scale input { width:58px; text-align:center; }
.duration-scale-note { min-width:78px; font-size:11px; font-weight:600; color:var(--muted); }
.duration-scale-note[data-direction="faster"] { color:#b45309; }
.duration-scale-note[data-direction="slower"] { color:var(--teal); }
.sequence-actions .timeline-loop { flex:none; min-height:32px; margin:0 0 0 6px; white-space:nowrap; }
.editor-timeline .sequence-actions .timeline-loop input { min-height:0; padding:0; }
/* Timeline stop point: a red bar after the pose where playback stops, and a chip to clear it. */
.sequence-pose-card.has-stop { box-shadow:inset 0 0 0 2px #c0392b; }
.sequence-pose-card.has-stop::after { content:"■ stop"; position:absolute; top:2px; left:4px; padding:0 4px; border-radius:4px; background:#c0392b; color:#fff; font-size:9px; font-weight:700; line-height:14px; pointer-events:none; }
.sequence-pose-card { position:relative; }
.timeline-stop-chip { display:inline-flex; align-items:center; gap:4px; margin-left:8px; padding:2px 4px 2px 9px; border:1px solid #e3a59d; border-radius:999px; background:#fdecea; color:#922b21; font-size:12px; font-weight:650; white-space:nowrap; }
.timeline-stop-chip[hidden] { display:none; }
.timeline-stop-chip button { width:20px; height:20px; padding:0; border:0; border-radius:50%; background:transparent; color:inherit; font-size:14px; line-height:1; cursor:pointer; }
.timeline-stop-chip button:hover { background:#f5c6c0; }
/* Right-click menu on a pose. */
.pose-menu { position:fixed; z-index:1000; min-width:min(300px, calc(100vw - 16px)); max-width:min(420px, calc(100vw - 16px)); max-height:calc(100dvh - 16px); overflow:auto; padding:6px; border:1px solid var(--line); border-radius:10px; background:#fff; box-shadow:0 10px 30px #0b1f2a33; font-size:13px; }
.pose-menu-heading { margin:6px 8px 4px; font-size:11px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--muted); }
.pose-menu > button { display:block; width:100%; padding:7px 10px; border:0; border-radius:7px; background:transparent; color:var(--ink); font:inherit; text-align:left; cursor:pointer; }
.pose-menu button:hover, .pose-menu button:focus-visible { background:var(--mint); outline:none; }
.pose-menu-viewer { width:min(420px, calc(100% - 16px)); min-width:0; max-width:none; overscroll-behavior:contain; }
.pose-menu-viewer > .pose-menu-copy { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
.pose-menu-row { display:grid; grid-template-columns:minmax(0, 1fr) repeat(4, auto); align-items:center; gap:4px; padding:3px 6px 3px 10px; }
.pose-menu-row button { padding:4px 8px; border:1px solid var(--line); border-radius:6px; background:#fff; color:var(--ink); font:inherit; font-size:12px; cursor:pointer; }
.pose-menu > button:disabled { opacity:.45; cursor:default; background:transparent; }
.pose-menu-range { display:flex; align-items:center; gap:6px; padding:4px 6px 4px 10px; font-size:13px; }
.pose-menu-range input { width:56px; min-height:28px; padding:2px 6px; border:1px solid var(--line); border-radius:6px; font:inherit; }
.pose-menu-range button { padding:4px 10px; border:1px solid var(--teal); border-radius:6px; background:var(--teal); color:#fff; font:inherit; font-size:12px; font-weight:650; cursor:pointer; }
/* Camera angle buttons beside the zoom. */
.robot3d-view-buttons { display:flex; flex-direction:column; align-items:stretch; gap:3px; }
.editor-stage .robot3d-camera-actions .robot3d-view-buttons .button { min-width:0; padding:2px 7px; }
@media (max-height:780px) {
  .editor-stage .robot3d-camera-actions { gap:3px; padding:3px; }
  .editor-stage .robot3d-view-buttons { gap:2px; }
  .editor-stage .robot3d-camera-actions .robot3d-view-buttons .button { min-height:22px; padding-block:0; }
  .editor-stage .robot3d-camera-actions .robot3d-zoom-stepper :is(.button, output) { height:18px; min-height:18px; }
}
/* Pose menu title bar: drag by it, Realtime switch, close. */
.pose-menu { padding-top:0; }
.pose-menu-bar { display:flex; align-items:center; gap:8px; margin:0 -6px 4px; padding:6px 6px 6px 10px; border-bottom:1px solid var(--line); border-radius:10px 10px 0 0; background:#f6f9f6; cursor:move; user-select:none; touch-action:none; }
.pose-menu-viewer .pose-menu-bar { position:sticky; top:0; z-index:1; cursor:grab; }
.pose-menu-viewer .pose-menu-bar.dragging { cursor:grabbing; }
.pose-menu.realtime .pose-menu-bar { background:#fff4e5; }
.pose-menu-grip { color:var(--muted); font-size:13px; }
.pose-menu-bar strong { flex:1; font-size:13px; }
.pose-menu-live { display:inline-flex; align-items:center; gap:4px; font-size:12px; font-weight:650; color:var(--ink); cursor:pointer; }
.pose-menu.realtime .pose-menu-live { color:#b45309; }
.pose-menu .pose-menu-close { width:26px; height:26px; padding:0; border:0; border-radius:6px; background:transparent; color:var(--ink); font-size:18px; line-height:1; cursor:pointer; }
.pose-menu .pose-menu-close:hover { background:#f5c6c0; }
.pose-menu-note { margin:6px 4px 2px; padding:6px 8px; border-radius:6px; background:var(--mint); font-size:12px; }
.pose-menu-note[hidden] { display:none; }
@media (max-height:600px) {
  .pose-menu-viewer .pose-menu-heading { margin-block:4px 2px; }
  .pose-menu-viewer .pose-menu-row { padding-block:1px; }
  .pose-menu-viewer > button { padding-block:4px; }
}
/* The viewer's "Select a joint" button is removed in the editor; click a joint on the model to select it. */
.editor-stage .r3d-joint-opener { display:none !important; }
/* Live search status under Search for my TonyPi. */
.robot-search-bar { display:block; width:100%; max-width:420px; height:8px; margin:6px auto 0; accent-color:var(--teal); }
.robot-search-found { margin:6px 0 0; font-size:13px; font-weight:650; color:var(--teal); }
.robot-search-summary { margin:0 0 10px; font-size:12px; color:var(--muted); text-align:center; }
/* Library: choose a sequence for a Move Pad move on this robot type. */
.library-movepad-use { max-width:100%; min-height:28px; padding:2px 6px; border:1px solid var(--line); border-radius:7px; background:#fff; font:inherit; font-size:12px; }
