pmx-canvas 0.4.7 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/.github/extensions/pmx-canvas/extension.mjs +154 -5
  2. package/.github/extensions/pmx-canvas/steering-delivery.mjs +79 -0
  3. package/CHANGELOG.md +156 -0
  4. package/Readme.md +72 -23
  5. package/dist/canvas/global.css +3069 -796
  6. package/dist/canvas/index.js +104 -104
  7. package/dist/json-render/index.css +1 -1
  8. package/dist/types/cli/agent.d.ts +1 -0
  9. package/dist/types/cli/commands/pump.d.ts +9 -0
  10. package/dist/types/client/App.d.ts +1 -1
  11. package/dist/types/client/canvas/AgentPresenceLayer.d.ts +11 -0
  12. package/dist/types/client/canvas/BarHint.d.ts +22 -0
  13. package/dist/types/client/canvas/CanvasNode.d.ts +5 -0
  14. package/dist/types/client/canvas/CanvasViewport.d.ts +4 -4
  15. package/dist/types/client/canvas/CommandBar.d.ts +10 -0
  16. package/dist/types/client/canvas/ConnectionBanner.d.ts +13 -0
  17. package/dist/types/client/canvas/ContextMenu.d.ts +6 -0
  18. package/dist/types/client/canvas/EdgeLayer.d.ts +2 -1
  19. package/dist/types/client/canvas/EmptyState.d.ts +11 -0
  20. package/dist/types/client/canvas/ExternalWriters.d.ts +5 -0
  21. package/dist/types/client/canvas/HumanPresenceLayer.d.ts +8 -0
  22. package/dist/types/client/canvas/Minimap.d.ts +12 -1
  23. package/dist/types/client/canvas/ScopeFenceLayer.d.ts +8 -0
  24. package/dist/types/client/canvas/SelectionBar.d.ts +6 -0
  25. package/dist/types/client/canvas/SessionPanel.d.ts +1 -0
  26. package/dist/types/client/canvas/SessionReceipt.d.ts +17 -0
  27. package/dist/types/client/canvas/TextPrompt.d.ts +25 -0
  28. package/dist/types/client/canvas/ToolRail.d.ts +21 -0
  29. package/dist/types/client/canvas/TopBar.d.ts +7 -0
  30. package/dist/types/client/canvas/canvas-area.d.ts +25 -0
  31. package/dist/types/client/canvas/create-in-view.d.ts +18 -0
  32. package/dist/types/client/canvas/import-files.d.ts +8 -0
  33. package/dist/types/client/canvas/kind-colors.d.ts +3 -0
  34. package/dist/types/client/canvas/use-focus-trap.d.ts +14 -0
  35. package/dist/types/client/canvas/use-now.d.ts +6 -0
  36. package/dist/types/client/icons.d.ts +11 -4
  37. package/dist/types/client/nodes/ExtAppFrame.d.ts +32 -0
  38. package/dist/types/client/nodes/GroupNode.d.ts +6 -1
  39. package/dist/types/client/nodes/MarkdownNode.d.ts +2 -0
  40. package/dist/types/client/nodes/inline-editor-commands.d.ts +3 -4
  41. package/dist/types/client/state/canvas-store.d.ts +49 -5
  42. package/dist/types/client/state/human-store.d.ts +26 -0
  43. package/dist/types/client/state/iframe-mode.d.ts +1 -0
  44. package/dist/types/client/state/intent-bridge.d.ts +37 -5
  45. package/dist/types/client/state/node-factory.d.ts +0 -1
  46. package/dist/types/client/state/presence-store.d.ts +78 -0
  47. package/dist/types/client/state/session-store.d.ts +176 -0
  48. package/dist/types/client/types.d.ts +2 -1
  49. package/dist/types/client/utils/platform.d.ts +2 -0
  50. package/dist/types/server/agent-presence.d.ts +192 -0
  51. package/dist/types/server/ax-gate-ttl.d.ts +6 -0
  52. package/dist/types/server/ax-interaction.d.ts +4 -10
  53. package/dist/types/server/ax-state-manager.d.ts +21 -2
  54. package/dist/types/server/ax-state.d.ts +49 -3
  55. package/dist/types/server/ax-wait.d.ts +13 -0
  56. package/dist/types/server/canvas-db.d.ts +23 -1
  57. package/dist/types/server/canvas-operations.d.ts +1 -0
  58. package/dist/types/server/canvas-state.d.ts +27 -13
  59. package/dist/types/server/canvas-validation.d.ts +0 -14
  60. package/dist/types/server/html-surface.d.ts +1 -1
  61. package/dist/types/server/human-presence.d.ts +40 -0
  62. package/dist/types/server/index.d.ts +29 -3
  63. package/dist/types/server/intent-registry.d.ts +7 -0
  64. package/dist/types/server/mutation-history.d.ts +15 -2
  65. package/dist/types/server/operations/invoker.d.ts +13 -2
  66. package/dist/types/server/operations/ops/ax-presence.d.ts +2 -0
  67. package/dist/types/server/operations/ops/human-presence.d.ts +3 -0
  68. package/dist/types/server/operations/registry.d.ts +11 -0
  69. package/dist/types/server/operations/types.d.ts +1 -1
  70. package/dist/types/server/scope-fence.d.ts +62 -0
  71. package/dist/types/server/server.d.ts +0 -12
  72. package/dist/types/shared/agent-presence.d.ts +130 -0
  73. package/dist/types/shared/approval-gates.d.ts +19 -0
  74. package/dist/types/shared/auto-arrange.d.ts +0 -1
  75. package/dist/types/shared/ax-kinds.d.ts +11 -0
  76. package/dist/types/shared/human-presence.d.ts +31 -0
  77. package/dist/types/shared/iframe-probe.d.ts +8 -0
  78. package/dist/types/shared/scope-fence.d.ts +21 -0
  79. package/docs/RELEASE.md +54 -0
  80. package/docs/ax-host-adapter-contract.md +30 -14
  81. package/docs/cli.md +37 -1
  82. package/docs/environment.md +3 -0
  83. package/docs/http-api.md +222 -5
  84. package/docs/mcp.md +6 -5
  85. package/docs/node-types.md +3 -1
  86. package/docs/plans/plan-009-tech-debt-backlog.md +13 -0
  87. package/docs/screenshot.png +0 -0
  88. package/docs/screenshots/multi-agent-live.png +0 -0
  89. package/docs/screenshots/workbench-live-dark.png +0 -0
  90. package/docs/screenshots/workbench-live-light.png +0 -0
  91. package/docs/sdk.md +1 -1
  92. package/package.json +1 -1
  93. package/skills/pmx-canvas/SKILL.md +109 -18
  94. package/skills/pmx-canvas/references/codex-app-adapter.md +28 -0
  95. package/skills/pmx-canvas/references/full-reference.md +55 -16
  96. package/skills/pmx-canvas/references/github-copilot-app-adapter.md +41 -24
  97. package/skills/pmx-canvas-orchestration/SKILL.md +56 -2
  98. package/skills/pmx-canvas-testing/SKILL.md +57 -0
  99. package/src/cli/agent.ts +1 -0
  100. package/src/cli/commands/copilot.ts +15 -8
  101. package/src/cli/commands/nodes.ts +1 -19
  102. package/src/cli/commands/pump.ts +252 -0
  103. package/src/cli/index.ts +1 -5
  104. package/src/cli/shared.ts +1 -1
  105. package/src/client/App.tsx +209 -585
  106. package/src/client/canvas/AgentPresenceLayer.tsx +74 -0
  107. package/src/client/canvas/AttentionHistory.tsx +0 -10
  108. package/src/client/canvas/BarHint.tsx +49 -0
  109. package/src/client/canvas/CanvasNode.tsx +488 -136
  110. package/src/client/canvas/CanvasViewport.tsx +190 -94
  111. package/src/client/canvas/CommandBar.tsx +140 -0
  112. package/src/client/canvas/CommandPalette.tsx +133 -58
  113. package/src/client/canvas/ConnectionBanner.tsx +65 -0
  114. package/src/client/canvas/ContextMenu.tsx +88 -27
  115. package/src/client/canvas/ContextPinBar.tsx +2 -2
  116. package/src/client/canvas/EdgeLayer.tsx +121 -38
  117. package/src/client/canvas/EmptyState.tsx +93 -0
  118. package/src/client/canvas/ExpandedNodeOverlay.tsx +64 -118
  119. package/src/client/canvas/ExternalWriters.tsx +308 -0
  120. package/src/client/canvas/FocusFieldLayer.tsx +12 -1
  121. package/src/client/canvas/HumanPresenceLayer.tsx +45 -0
  122. package/src/client/canvas/IntentLayer.tsx +1 -1
  123. package/src/client/canvas/Minimap.tsx +117 -190
  124. package/src/client/canvas/ScopeFenceLayer.tsx +38 -0
  125. package/src/client/canvas/SelectionBar.tsx +175 -23
  126. package/src/client/canvas/SessionPanel.tsx +481 -0
  127. package/src/client/canvas/SessionReceipt.tsx +141 -0
  128. package/src/client/canvas/ShortcutOverlay.tsx +21 -6
  129. package/src/client/canvas/SnapshotPanel.tsx +166 -80
  130. package/src/client/canvas/TextPrompt.tsx +128 -0
  131. package/src/client/canvas/ToolRail.tsx +447 -0
  132. package/src/client/canvas/TopBar.tsx +308 -0
  133. package/src/client/canvas/auto-fit.ts +1 -5
  134. package/src/client/canvas/canvas-area.ts +41 -0
  135. package/src/client/canvas/create-in-view.ts +48 -0
  136. package/src/client/canvas/import-files.ts +64 -0
  137. package/src/client/canvas/kind-colors.ts +22 -0
  138. package/src/client/canvas/snap-guides.ts +1 -1
  139. package/src/client/canvas/use-focus-trap.ts +54 -0
  140. package/src/client/canvas/use-now.ts +17 -0
  141. package/src/client/canvas/use-pan-zoom.ts +13 -2
  142. package/src/client/icons.tsx +57 -18
  143. package/src/client/nodes/ExtAppFrame.tsx +79 -2
  144. package/src/client/nodes/GroupNode.tsx +9 -28
  145. package/src/client/nodes/InlineFormatBar.tsx +4 -3
  146. package/src/client/nodes/InlineMarkdownEditor.tsx +27 -0
  147. package/src/client/nodes/MarkdownNode.tsx +59 -24
  148. package/src/client/nodes/MdFormatBar.tsx +2 -4
  149. package/src/client/nodes/inline-editor-commands.ts +17 -6
  150. package/src/client/nodes/use-surface-frame.ts +3 -1
  151. package/src/client/state/attention-bridge.ts +3 -0
  152. package/src/client/state/canvas-store.ts +273 -84
  153. package/src/client/state/human-store.ts +175 -0
  154. package/src/client/state/iframe-mode.ts +33 -9
  155. package/src/client/state/intent-bridge.ts +75 -13
  156. package/src/client/state/node-factory.ts +2 -8
  157. package/src/client/state/presence-store.ts +168 -0
  158. package/src/client/state/session-store.ts +419 -0
  159. package/src/client/state/sse-bridge.ts +93 -30
  160. package/src/client/theme/global.css +3069 -796
  161. package/src/client/types.ts +3 -1
  162. package/src/client/utils/platform.ts +6 -1
  163. package/src/mcp/canvas-access.ts +2 -2
  164. package/src/server/agent-presence.ts +755 -0
  165. package/src/server/ax-context.ts +45 -0
  166. package/src/server/ax-gate-ttl.ts +61 -0
  167. package/src/server/ax-interaction.ts +29 -1
  168. package/src/server/ax-state-manager.ts +78 -6
  169. package/src/server/ax-state.ts +82 -15
  170. package/src/server/ax-wait.ts +33 -0
  171. package/src/server/canvas-db.ts +237 -61
  172. package/src/server/canvas-operations.ts +17 -8
  173. package/src/server/canvas-state.ts +131 -58
  174. package/src/server/canvas-validation.ts +3 -53
  175. package/src/server/demo-state.json +2 -70
  176. package/src/server/html-surface.ts +11 -2
  177. package/src/server/human-presence.ts +160 -0
  178. package/src/server/index.ts +107 -4
  179. package/src/server/intent-registry.ts +13 -0
  180. package/src/server/mutation-history.ts +47 -2
  181. package/src/server/operations/composites.ts +6 -3
  182. package/src/server/operations/http.ts +10 -1
  183. package/src/server/operations/index.ts +4 -0
  184. package/src/server/operations/invoker.ts +33 -6
  185. package/src/server/operations/ops/ax-presence.ts +62 -0
  186. package/src/server/operations/ops/ax-read.ts +8 -0
  187. package/src/server/operations/ops/ax-state.ts +106 -1
  188. package/src/server/operations/ops/ax-timeline.ts +54 -5
  189. package/src/server/operations/ops/ax-work.ts +46 -0
  190. package/src/server/operations/ops/batch.ts +3 -1
  191. package/src/server/operations/ops/edges.ts +88 -2
  192. package/src/server/operations/ops/groups.ts +4 -3
  193. package/src/server/operations/ops/human-presence.ts +35 -0
  194. package/src/server/operations/ops/json-render.ts +11 -1
  195. package/src/server/operations/ops/nodes.ts +65 -16
  196. package/src/server/operations/ops/query.ts +1 -0
  197. package/src/server/operations/ops/snapshots.ts +16 -0
  198. package/src/server/operations/registry.ts +196 -1
  199. package/src/server/operations/types.ts +1 -1
  200. package/src/server/scope-fence.ts +207 -0
  201. package/src/server/server.ts +177 -79
  202. package/src/server/trace-manager.ts +0 -2
  203. package/src/server/web-artifacts.ts +0 -1
  204. package/src/shared/agent-presence.ts +162 -0
  205. package/src/shared/approval-gates.ts +35 -0
  206. package/src/shared/auto-arrange.ts +121 -13
  207. package/src/shared/ax-kinds.ts +23 -0
  208. package/src/shared/human-presence.ts +30 -0
  209. package/src/shared/iframe-probe.ts +8 -0
  210. package/src/shared/scope-fence.ts +31 -0
  211. package/dist/types/client/canvas/DockedNode.d.ts +0 -4
  212. package/src/client/canvas/DockedNode.tsx +0 -165
@@ -56,9 +56,7 @@
56
56
  --mono: "IBM Plex Mono", "SF Mono", "Fira Code", monospace;
57
57
  --radius: 10px;
58
58
  --radius-sm: 6px;
59
- /* Shared height for the top HUD row so the toolbar and the collapsed docked
60
- status/context widgets that flank it line up to the same height. Matches the
61
- toolbar's natural content height (icon buttons at 6px padding). */
59
+ /* Shared height of the top bar and the session panel header. */
62
60
  --hud-bar-height: 44px;
63
61
  }
64
62
 
@@ -546,9 +544,11 @@ body,
546
544
  /* Node card shared styles */
547
545
  .canvas-node {
548
546
  position: absolute;
547
+ /* Standard card shell (rail-chrome-v2): node surface, 12px radius, soft
548
+ shadow. Every node kind shares it; the kind shows in the icon color. */
549
549
  background: var(--c-panel);
550
550
  border: 1px solid var(--c-line);
551
- border-radius: var(--radius);
551
+ border-radius: 12px;
552
552
  box-shadow: 0 4px 24px var(--c-shadow);
553
553
  display: flex;
554
554
  flex-direction: column;
@@ -623,7 +623,7 @@ body,
623
623
  display: flex;
624
624
  align-items: center;
625
625
  gap: calc(8px * var(--node-chrome-scale, 1));
626
- padding: calc(8px * var(--node-chrome-scale, 1)) calc(12px * var(--node-chrome-scale, 1));
626
+ padding: calc(7px * var(--node-chrome-scale, 1)) calc(12px * var(--node-chrome-scale, 1));
627
627
  background: var(--c-panel-overlay);
628
628
  border-bottom: 1px solid var(--c-line);
629
629
  cursor: grab;
@@ -638,7 +638,7 @@ body,
638
638
  .canvas-node .node-title {
639
639
  font-size: calc(12px * var(--node-chrome-scale, 1));
640
640
  font-weight: 600;
641
- color: var(--c-muted);
641
+ color: var(--c-text-soft);
642
642
  white-space: nowrap;
643
643
  overflow: hidden;
644
644
  text-overflow: ellipsis;
@@ -654,14 +654,28 @@ body,
654
654
  display: inline-flex;
655
655
  align-items: center;
656
656
  justify-content: center;
657
- width: calc(18px * var(--node-chrome-scale, 1));
658
- height: calc(18px * var(--node-chrome-scale, 1));
659
- border-radius: calc(4px * var(--node-chrome-scale, 1));
660
- color: var(--c-accent);
661
- background: var(--c-accent-10);
657
+ width: calc(14px * var(--node-chrome-scale, 1));
658
+ height: calc(14px * var(--node-chrome-scale, 1));
659
+ color: var(--kind-accent, var(--c-accent));
662
660
  flex-shrink: 0;
663
661
  }
664
662
 
663
+ /* Node kind accents (rail-chrome-v2): the icon carries the kind. */
664
+ .canvas-node[data-node-type='image'],
665
+ .canvas-node[data-node-type='mermaid'] {
666
+ --kind-accent: var(--c-warn);
667
+ }
668
+ .canvas-node[data-node-type='webpage'],
669
+ .canvas-node[data-node-type='status'],
670
+ .canvas-node[data-node-type='trace'] {
671
+ --kind-accent: var(--c-ok);
672
+ }
673
+ .canvas-node[data-node-type='context'],
674
+ .canvas-node[data-node-type='prompt'],
675
+ .canvas-node[data-node-type='response'] {
676
+ --kind-accent: var(--c-purple);
677
+ }
678
+
665
679
  .canvas-node .node-type-badge {
666
680
  font-size: calc(10px * var(--node-chrome-scale, 1));
667
681
  padding: calc(1px * var(--node-chrome-scale, 1)) calc(6px * var(--node-chrome-scale, 1));
@@ -713,7 +727,7 @@ body,
713
727
  .canvas-node .node-controls button {
714
728
  background: none;
715
729
  border: none;
716
- color: var(--c-muted);
730
+ color: var(--c-dim);
717
731
  cursor: pointer;
718
732
  display: inline-flex;
719
733
  align-items: center;
@@ -734,8 +748,11 @@ body,
734
748
  .canvas-node .node-body {
735
749
  flex: 1;
736
750
  overflow: auto;
737
- padding: 12px;
751
+ padding: 10px 14px;
738
752
  min-height: 0;
753
+ font-size: 11px;
754
+ line-height: 1.6;
755
+ color: var(--c-text-soft);
739
756
  }
740
757
 
741
758
  /* Markdown rendered content inside nodes */
@@ -761,16 +778,62 @@ body,
761
778
  color: var(--c-muted);
762
779
  }
763
780
 
781
+ /* GFM task lists: custom-drawn checkboxes — native inputs are an 11px target
782
+ at typical zoom and render inconsistently (or not at all) in embedding
783
+ apps — and no double marker (• plus box) on task rows. */
784
+ .canvas-node .node-body li:has(> input[type='checkbox']),
785
+ .md-reader-content li:has(> input[type='checkbox']) {
786
+ list-style: none;
787
+ /* Reclaim the bullet gutter, then indent the whole item past the box — the
788
+ box sits OUT of the text flow so wrapped lines align under the first. */
789
+ margin-left: -1.3em;
790
+ padding-left: 1.65em;
791
+ position: relative;
792
+ }
793
+ .canvas-node .node-body li > input[type='checkbox'],
794
+ .md-reader-content li > input[type='checkbox'] {
795
+ appearance: none;
796
+ -webkit-appearance: none;
797
+ position: absolute;
798
+ left: 0;
799
+ top: 0.22em;
800
+ width: 15px;
801
+ height: 15px;
802
+ margin: 0;
803
+ border: 1.5px solid var(--c-muted);
804
+ border-radius: 4px;
805
+ background: var(--c-panel);
806
+ cursor: pointer;
807
+ /* Embedding webviews (Copilot app) force color schemes on form controls —
808
+ this box is fully custom-drawn, keep its colors ours. */
809
+ forced-color-adjust: none;
810
+ color-scheme: light;
811
+ }
812
+ .canvas-node .node-body li > input[type='checkbox']:hover,
813
+ .md-reader-content li > input[type='checkbox']:hover {
814
+ border-color: var(--c-accent);
815
+ }
816
+ .canvas-node .node-body li > input[type='checkbox']:checked,
817
+ .md-reader-content li > input[type='checkbox']:checked {
818
+ border-color: var(--c-accent);
819
+ background-color: var(--c-accent);
820
+ background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='8'%3E%3Cpath d='M1 4l2.6 2.6L9 1' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
821
+ background-repeat: no-repeat;
822
+ background-position: center;
823
+ }
824
+
825
+ /* Hanging indent: with `inside`, a wrapped line falls back to the card edge
826
+ under the marker instead of aligning with its own first line. */
764
827
  .canvas-node .node-body ul,
765
828
  .canvas-node .node-body ol {
766
829
  margin: 0.4em 0;
767
- padding-left: 0.25em;
768
- list-style-position: inside;
830
+ padding-left: 1.3em;
831
+ list-style-position: outside;
769
832
  }
770
833
 
771
834
  .canvas-node .node-body li {
772
835
  margin: 0.2em 0;
773
- padding-left: 0.15em;
836
+ padding-left: 0.1em;
774
837
  }
775
838
 
776
839
  .canvas-node .node-body a {
@@ -821,225 +884,2223 @@ body,
821
884
  font-weight: 600;
822
885
  }
823
886
 
824
- /* HUD layer — [left-dock] [toolbar] [right-dock]. Wraps onto multiple rows in a
825
- narrow embedding panel (e.g. the Copilot side panel) instead of clipping. */
826
- .hud-layer {
827
- position: fixed;
828
- top: 12px;
829
- left: 12px;
830
- right: 12px;
831
- display: flex;
832
- flex-wrap: wrap;
833
- align-items: flex-start;
834
- justify-content: center;
835
- gap: 8px;
836
- z-index: 9999;
837
- pointer-events: none;
838
- }
839
- .hud-layer > * {
840
- pointer-events: auto;
841
- }
842
- .hud-left,
843
- .hud-right {
887
+ /* ── App shell: rail + top bar + canvas region (rail-chrome-v2) ── */
888
+ .app-shell {
844
889
  display: flex;
845
- flex-wrap: wrap;
846
- gap: 8px;
890
+ width: 100%;
891
+ height: 100%;
892
+ overflow: hidden;
893
+ background: var(--c-bg);
847
894
  }
848
895
 
849
- /* Toolbar */
850
- .canvas-toolbar {
896
+ .tool-rail {
897
+ width: 52px;
898
+ flex-shrink: 0;
851
899
  display: flex;
852
- flex-wrap: wrap;
900
+ flex-direction: column;
853
901
  align-items: center;
854
- gap: 6px;
855
- padding: 6px 10px;
856
- min-height: var(--hud-bar-height);
857
- max-width: 100%;
858
- box-sizing: border-box;
859
- background: var(--c-panel-glass);
860
- backdrop-filter: blur(12px);
861
- border: 1px solid var(--c-line);
862
- border-radius: var(--radius);
902
+ gap: 4px;
903
+ padding: 10px 0;
904
+ background: var(--c-panel-soft);
905
+ border-right: 1px solid var(--c-line);
906
+ overflow-y: auto;
907
+ scrollbar-width: none;
908
+ /* The rail is a stacking context: its popovers can only win against the
909
+ canvas region's overlays (annotation capture layer at 9996) if the rail
910
+ ITSELF stacks above them — a child's z-index never escapes this context. */
911
+ z-index: 9999;
912
+ }
913
+ .tool-rail::-webkit-scrollbar {
914
+ display: none;
863
915
  }
864
916
 
865
- .toolbar-tooltip-anchor {
866
- position: relative;
917
+ .rail-brand {
867
918
  display: inline-flex;
868
919
  align-items: center;
920
+ justify-content: center;
921
+ width: 36px;
922
+ height: 36px;
923
+ color: var(--c-accent);
924
+ flex-shrink: 0;
869
925
  }
870
926
 
871
- .toolbar-tooltip-anchor-start .toolbar-tooltip {
872
- left: 0;
873
- transform: translateX(0) translateY(6px);
927
+ .rail-btn {
928
+ display: inline-flex;
929
+ align-items: center;
930
+ justify-content: center;
931
+ width: 36px;
932
+ height: 36px;
933
+ border-radius: 8px;
934
+ border: 1px solid transparent;
935
+ background: none;
936
+ color: var(--c-muted);
937
+ cursor: pointer;
938
+ flex-shrink: 0;
874
939
  }
875
-
876
- .toolbar-tooltip-anchor-end .toolbar-tooltip {
877
- left: auto;
878
- right: 0;
879
- transform: translateX(0) translateY(6px);
940
+ .rail-btn svg {
941
+ display: block;
880
942
  }
881
-
882
- .toolbar-tooltip {
883
- position: absolute;
884
- left: 50%;
885
- top: calc(100% + 10px);
886
- transform: translateX(-50%) translateY(6px);
887
- display: flex;
888
- flex-direction: column;
889
- gap: 4px;
890
- min-width: 168px;
891
- max-width: 240px;
892
- padding: 10px 12px;
893
- background: color-mix(in srgb, var(--c-panel) 92%, black 8%);
894
- border: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
895
- border-radius: 10px;
896
- box-shadow: 0 14px 36px var(--c-shadow-heavy), 0 0 0 1px var(--c-accent-8);
897
- backdrop-filter: blur(14px);
943
+ .rail-btn:hover {
944
+ background: var(--c-surface-hover);
898
945
  color: var(--c-text);
899
- font-size: 12px;
900
- line-height: 1.35;
901
- white-space: normal;
902
- opacity: 0;
903
- pointer-events: none;
904
- z-index: 10010;
905
- transition: opacity 0.14s ease, transform 0.14s ease;
906
946
  }
907
-
908
- .toolbar-tooltip::after {
909
- content: '';
910
- position: absolute;
911
- left: 50%;
912
- top: -5px;
913
- width: 10px;
914
- height: 10px;
915
- background: inherit;
916
- border-top: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
917
- border-left: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
918
- transform: translateX(-50%) rotate(45deg);
947
+ .rail-btn.active {
948
+ background: var(--c-accent-10);
949
+ border-color: var(--c-accent-25);
950
+ color: var(--c-accent);
951
+ }
952
+ .rail-btn.active:hover {
953
+ background: var(--c-accent-15, var(--c-accent-10));
919
954
  }
920
955
 
921
- .toolbar-tooltip-anchor-start .toolbar-tooltip::after {
922
- left: 18px;
923
- transform: rotate(45deg);
956
+ .rail-divider {
957
+ width: 24px;
958
+ height: 1px;
959
+ background: var(--c-line);
960
+ flex-shrink: 0;
961
+ margin: 3px 0;
924
962
  }
925
963
 
926
- .toolbar-tooltip-anchor-end .toolbar-tooltip::after {
927
- left: auto;
928
- right: 18px;
929
- transform: rotate(45deg);
964
+ .rail-spacer {
965
+ flex: 1;
966
+ min-height: 8px;
930
967
  }
931
968
 
932
- .toolbar-tooltip-anchor:hover .toolbar-tooltip,
933
- .toolbar-tooltip-anchor > :focus-visible + .toolbar-tooltip {
934
- opacity: 1;
935
- transform: translateX(-50%) translateY(0);
969
+ .app-main {
970
+ flex: 1;
971
+ min-width: 0;
972
+ display: flex;
973
+ flex-direction: column;
936
974
  }
937
975
 
938
- .toolbar-tooltip-anchor-start:hover .toolbar-tooltip,
939
- .toolbar-tooltip-anchor-start > :focus-visible + .toolbar-tooltip,
940
- .toolbar-tooltip-anchor-end:hover .toolbar-tooltip,
941
- .toolbar-tooltip-anchor-end > :focus-visible + .toolbar-tooltip {
942
- transform: translateX(0) translateY(0);
976
+ .top-bar {
977
+ height: var(--hud-bar-height);
978
+ flex-shrink: 0;
979
+ display: flex;
980
+ align-items: center;
981
+ gap: 12px;
982
+ padding: 0 14px;
983
+ background: color-mix(in srgb, var(--c-panel-soft) 92%, transparent);
984
+ backdrop-filter: blur(12px);
985
+ border-bottom: 1px solid var(--c-line);
986
+ /* NOT overflow:hidden — the BarHint tooltips hang below the bar and were
987
+ clipped invisible for everyone (the e2e asserted opacity, which cannot
988
+ see ancestor clipping). Children ellipsize themselves; the narrow-screen
989
+ collapse is media-query display, not clipping. */
990
+ min-width: 0;
991
+ z-index: 9998;
943
992
  }
944
993
 
945
- .toolbar-tooltip-label {
994
+ .top-bar-title {
946
995
  font-size: 13px;
947
996
  font-weight: 600;
948
- letter-spacing: 0.01em;
949
997
  color: var(--c-text);
998
+ white-space: nowrap;
999
+ overflow: hidden;
1000
+ text-overflow: ellipsis;
1001
+ min-width: 60px;
1002
+ flex-shrink: 1;
950
1003
  }
951
1004
 
952
- .toolbar-tooltip-meta {
953
- display: flex;
954
- align-items: center;
955
- justify-content: space-between;
956
- gap: 10px;
957
- color: var(--c-text-soft);
1005
+ .top-bar-meta {
1006
+ font: 11px var(--mono);
1007
+ color: var(--c-dim);
1008
+ white-space: nowrap;
1009
+ flex-shrink: 0;
958
1010
  }
959
1011
 
960
- .toolbar-tooltip-shortcut {
1012
+ .top-bar-spacer {
1013
+ flex: 1;
1014
+ min-width: 0;
1015
+ }
1016
+
1017
+ .top-bar-sep {
1018
+ width: 1px;
1019
+ height: 20px;
1020
+ background: var(--c-line);
1021
+ flex-shrink: 0;
1022
+ }
1023
+
1024
+ .top-bar-btn {
961
1025
  display: inline-flex;
962
1026
  align-items: center;
963
1027
  justify-content: center;
964
- min-height: 20px;
965
- padding: 2px 7px;
966
- border-radius: 999px;
967
- border: 1px solid var(--c-accent-25);
968
- background: var(--c-accent-10);
969
- color: var(--c-accent);
970
- font: 11px/1 var(--mono);
971
- white-space: nowrap;
972
- }
973
-
974
- .canvas-toolbar button {
1028
+ padding: 6px 8px;
975
1029
  background: none;
976
1030
  border: 1px solid transparent;
977
- color: var(--c-muted);
978
- padding: 6px 10px;
979
1031
  border-radius: var(--radius-sm);
980
- font: inherit;
981
- font-size: 14px;
1032
+ color: var(--c-muted);
982
1033
  cursor: pointer;
1034
+ flex-shrink: 0;
983
1035
  }
984
-
985
- .canvas-toolbar button:hover {
1036
+ .top-bar-btn svg {
1037
+ display: block;
1038
+ }
1039
+ .top-bar-btn:hover {
986
1040
  background: var(--c-surface-hover);
987
1041
  color: var(--c-text);
988
1042
  border-color: var(--c-line);
989
1043
  }
990
1044
 
991
- .canvas-toolbar .separator {
992
- width: 1px;
993
- height: 20px;
994
- background: var(--c-line);
995
- }
996
-
997
- .canvas-toolbar .canvas-brand {
998
- display: inline-flex;
999
- align-items: center;
1000
- justify-content: center;
1001
- width: 28px;
1002
- height: 28px;
1003
- color: var(--c-accent);
1045
+ .top-bar-zoom-label {
1046
+ min-width: 38px;
1047
+ text-align: center;
1048
+ font: 11px var(--mono);
1049
+ color: var(--c-muted);
1050
+ background: none;
1051
+ border: 1px solid transparent;
1052
+ border-radius: var(--radius-sm);
1053
+ padding: 6px 4px;
1054
+ cursor: pointer;
1004
1055
  flex-shrink: 0;
1005
1056
  }
1057
+ .top-bar-zoom-label:hover {
1058
+ background: var(--c-surface-hover);
1059
+ color: var(--c-text);
1060
+ }
1006
1061
 
1007
- .canvas-toolbar .connection-dot {
1008
- width: 8px;
1009
- height: 8px;
1010
- border-radius: 50%;
1011
- flex-shrink: 0;
1062
+ .canvas-region {
1063
+ flex: 1;
1064
+ min-height: 0;
1065
+ position: relative;
1066
+ overflow: hidden;
1012
1067
  }
1013
1068
 
1014
- .canvas-toolbar .connection-dot.connected {
1015
- background: var(--c-ok);
1069
+ /* ── Agent presence (rail-chrome-v2 phase 3) ────────────────────
1070
+ Every surface below mounts only while a session is attached. Phase colors
1071
+ are tokens so all nine themes agree: thinking=purple, tooling=accent,
1072
+ waiting=warn, idle=dim. */
1073
+ .agent-chip,
1074
+ .agent-cursor,
1075
+ .minimap-presence {
1076
+ --presence-color: var(--c-dim);
1016
1077
  }
1017
- .canvas-toolbar .connection-dot.connecting {
1018
- background: var(--c-warn);
1019
- animation: pulse 1.5s infinite;
1078
+ .agent-chip.phase-thinking,
1079
+ .agent-cursor.phase-thinking,
1080
+ .minimap-presence.phase-thinking {
1081
+ --presence-color: var(--c-purple);
1020
1082
  }
1021
- .canvas-toolbar .connection-dot.disconnected {
1022
- background: var(--c-danger);
1083
+ .agent-chip.phase-tooling,
1084
+ .agent-cursor.phase-tooling,
1085
+ .minimap-presence.phase-tooling {
1086
+ --presence-color: var(--c-accent);
1087
+ }
1088
+ .agent-chip.phase-waiting-approval,
1089
+ .agent-cursor.phase-waiting-approval,
1090
+ .minimap-presence.phase-waiting-approval {
1091
+ --presence-color: var(--c-warn);
1023
1092
  }
1024
1093
 
1025
- @keyframes pulse {
1026
- 0%,
1027
- 100% {
1028
- opacity: 1;
1029
- }
1030
- 50% {
1031
- opacity: 0.4;
1094
+ /* Top-bar chip */
1095
+ .agent-chip {
1096
+ display: inline-flex;
1097
+ align-items: center;
1098
+ gap: 7px;
1099
+ padding: 5px 12px;
1100
+ border-radius: 999px;
1101
+ border: 1px solid color-mix(in srgb, var(--presence-color) 35%, transparent);
1102
+ background: color-mix(in srgb, var(--presence-color) 12%, transparent);
1103
+ color: var(--presence-color);
1104
+ font-size: 11px;
1105
+ font-weight: 600;
1106
+ white-space: nowrap;
1107
+ flex-shrink: 0;
1108
+ min-width: 0;
1109
+ max-width: 280px;
1110
+ }
1111
+ .agent-chip.phase-idle {
1112
+ background: none;
1113
+ border-color: var(--c-line);
1114
+ }
1115
+ .agent-chip-dot {
1116
+ width: 7px;
1117
+ height: 7px;
1118
+ border-radius: 50%;
1119
+ background: var(--presence-color);
1120
+ flex-shrink: 0;
1121
+ }
1122
+ .agent-chip.phase-thinking .agent-chip-dot,
1123
+ .agent-chip.phase-tooling .agent-chip-dot {
1124
+ animation: presence-pulse 1.4s ease-in-out infinite;
1125
+ }
1126
+ .agent-chip-label {
1127
+ overflow: hidden;
1128
+ text-overflow: ellipsis;
1129
+ white-space: nowrap;
1130
+ min-width: 0;
1131
+ }
1132
+ .agent-chip-who {
1133
+ font: 10px var(--mono);
1134
+ font-weight: 400;
1135
+ color: var(--c-muted);
1136
+ white-space: nowrap;
1137
+ }
1138
+
1139
+ /* On-canvas cursor + phase chip (world layer; counter-scaled inner) */
1140
+ .agent-presence-layer {
1141
+ display: contents;
1142
+ }
1143
+ .agent-cursor {
1144
+ position: absolute;
1145
+ left: 0;
1146
+ top: 0;
1147
+ z-index: 9000;
1148
+ pointer-events: none;
1149
+ transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
1150
+ color: var(--presence-color);
1151
+ }
1152
+ .agent-cursor.is-worker {
1153
+ opacity: 0.85;
1154
+ }
1155
+ .agent-cursor.is-worker .agent-cursor-glyph {
1156
+ transform: scale(0.75);
1157
+ transform-origin: top left;
1158
+ }
1159
+ .agent-cursor.is-worker .agent-cursor-chip {
1160
+ font-size: 9px;
1161
+ padding: 1px 6px;
1162
+ }
1163
+ .agent-chip-workers {
1164
+ margin-left: 4px;
1165
+ padding: 0 5px;
1166
+ border-radius: 8px;
1167
+ background: color-mix(in srgb, var(--c-accent) 16%, transparent);
1168
+ color: var(--c-accent);
1169
+ font-size: 9px;
1170
+ font-weight: 700;
1171
+ letter-spacing: 0.04em;
1172
+ white-space: nowrap;
1173
+ }
1174
+
1175
+ /* End THIS session — each chip carries its own ×, so a two-agent board can
1176
+ end one writer without hunting for it in the session panel. */
1177
+ .agent-chip-end {
1178
+ margin-left: 2px;
1179
+ padding: 0 3px;
1180
+ border: none;
1181
+ background: none;
1182
+ color: var(--c-muted);
1183
+ font-size: 12px;
1184
+ line-height: 1;
1185
+ cursor: pointer;
1186
+ border-radius: 6px;
1187
+ }
1188
+
1189
+ .agent-chip-end:hover {
1190
+ color: var(--c-danger, #ef4444);
1191
+ background: color-mix(in srgb, currentColor 12%, transparent);
1192
+ }
1193
+
1194
+ .agent-cursor-glyph path {
1195
+ fill: var(--identity-color, currentColor);
1196
+ }
1197
+ .agent-cursor-chip {
1198
+ border-left: 3px solid var(--identity-color, transparent);
1199
+ }
1200
+ .agent-chip {
1201
+ border-left: 3px solid var(--identity-color, transparent);
1202
+ }
1203
+ .minimap-presence {
1204
+ background: var(--identity-color, var(--presence-color));
1205
+ }
1206
+
1207
+ .agent-cursor.is-external {
1208
+ opacity: 0.8;
1209
+ }
1210
+ .agent-cursor.is-external .agent-cursor-chip {
1211
+ border-style: dashed;
1212
+ }
1213
+
1214
+ .agent-cursor-inner {
1215
+ position: relative;
1216
+ transform-origin: 0 0;
1217
+ }
1218
+ .agent-cursor-glyph {
1219
+ display: block;
1220
+ filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35));
1221
+ }
1222
+ .agent-cursor-chip {
1223
+ position: absolute;
1224
+ left: 14px;
1225
+ top: 18px;
1226
+ display: inline-flex;
1227
+ align-items: center;
1228
+ gap: 6px;
1229
+ padding: 3px 9px;
1230
+ border-radius: 999px;
1231
+ border: 1px solid color-mix(in srgb, var(--presence-color) 35%, transparent);
1232
+ background: color-mix(in srgb, var(--c-panel) 92%, var(--presence-color) 8%);
1233
+ color: var(--presence-color);
1234
+ font-size: 10.5px;
1235
+ font-weight: 600;
1236
+ white-space: nowrap;
1237
+ box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
1238
+ }
1239
+ .agent-cursor-dot {
1240
+ width: 6px;
1241
+ height: 6px;
1242
+ border-radius: 50%;
1243
+ background: var(--presence-color);
1244
+ }
1245
+ .agent-cursor.phase-thinking .agent-cursor-dot,
1246
+ .agent-cursor.phase-tooling .agent-cursor-dot {
1247
+ animation: presence-pulse 1.4s ease-in-out infinite;
1248
+ }
1249
+ .agent-cursor-who {
1250
+ font: 9.5px var(--mono);
1251
+ font-weight: 400;
1252
+ color: var(--c-muted);
1253
+ }
1254
+
1255
+ /* Node shimmer: the node an attached agent is mutating right now */
1256
+ .canvas-node.agent-mutating {
1257
+ border-color: color-mix(in srgb, var(--c-accent) 45%, transparent) !important;
1258
+ background-image: linear-gradient(
1259
+ 100deg,
1260
+ transparent 20%,
1261
+ color-mix(in srgb, var(--c-accent) 13%, transparent) 50%,
1262
+ transparent 80%
1263
+ );
1264
+ background-size: 200% 100%;
1265
+ animation: presence-shimmer 1.6s linear infinite;
1266
+ }
1267
+
1268
+ @keyframes presence-pulse {
1269
+ 0%,
1270
+ 100% {
1271
+ opacity: 1;
1272
+ }
1273
+ 50% {
1274
+ opacity: 0.45;
1275
+ }
1276
+ }
1277
+ @keyframes presence-shimmer {
1278
+ from {
1279
+ background-position: 200% 0;
1280
+ }
1281
+ to {
1282
+ background-position: -200% 0;
1283
+ }
1284
+ }
1285
+
1286
+ /* Reduced motion: keep every static color state, drop the motion. */
1287
+ @media (prefers-reduced-motion: reduce) {
1288
+ .agent-cursor {
1289
+ transition: none;
1290
+ }
1291
+ .agent-chip-dot,
1292
+ .agent-cursor-dot,
1293
+ .canvas-node.agent-mutating {
1294
+ animation: none;
1295
+ }
1296
+ .canvas-node.agent-mutating {
1297
+ background-image: none;
1298
+ }
1299
+ }
1300
+
1301
+ /* ── Session panel (rail-chrome-v2 phase 4) ─────────────────────
1302
+ Right sibling of the centre column while a session is attached. Below
1303
+ 1180px it becomes a fixed overlay drawer and the canvas reclaims its width. */
1304
+ .session-panel {
1305
+ width: 320px;
1306
+ flex-shrink: 0;
1307
+ display: flex;
1308
+ flex-direction: column;
1309
+ background: var(--c-panel-soft);
1310
+ border-left: 1px solid var(--c-line);
1311
+ min-height: 0;
1312
+ z-index: 9997;
1313
+ animation: session-panel-in 180ms ease;
1314
+ }
1315
+ .session-panel.is-collapsed {
1316
+ width: 28px;
1317
+ align-items: center;
1318
+ padding-top: 10px;
1319
+ gap: 10px;
1320
+ }
1321
+ .session-collapsed-label {
1322
+ writing-mode: vertical-rl;
1323
+ font-size: 10px;
1324
+ font-weight: 600;
1325
+ letter-spacing: 0.08em;
1326
+ text-transform: uppercase;
1327
+ color: var(--c-dim);
1328
+ }
1329
+
1330
+ .session-panel-header {
1331
+ height: var(--hud-bar-height);
1332
+ flex-shrink: 0;
1333
+ display: flex;
1334
+ align-items: center;
1335
+ gap: 10px;
1336
+ padding: 0 12px 0 16px;
1337
+ border-bottom: 1px solid var(--c-line);
1338
+ }
1339
+ .session-panel-title {
1340
+ font-size: 11px;
1341
+ font-weight: 700;
1342
+ letter-spacing: 0.08em;
1343
+ text-transform: uppercase;
1344
+ color: var(--c-text);
1345
+ }
1346
+ .session-live {
1347
+ --presence-color: var(--c-dim);
1348
+ display: inline-flex;
1349
+ align-items: center;
1350
+ gap: 5px;
1351
+ font: 10px var(--mono);
1352
+ color: var(--c-muted);
1353
+ }
1354
+ .session-live.phase-thinking {
1355
+ --presence-color: var(--c-purple);
1356
+ }
1357
+ .session-live.phase-tooling {
1358
+ --presence-color: var(--c-accent);
1359
+ }
1360
+ .session-live.phase-waiting-approval {
1361
+ --presence-color: var(--c-warn);
1362
+ }
1363
+ .session-live-dot {
1364
+ width: 6px;
1365
+ height: 6px;
1366
+ border-radius: 50%;
1367
+ background: var(--presence-color);
1368
+ }
1369
+ .session-live.phase-thinking .session-live-dot,
1370
+ .session-live.phase-tooling .session-live-dot {
1371
+ animation: presence-pulse 1.4s ease-in-out infinite;
1372
+ }
1373
+ .session-collapse {
1374
+ width: 26px;
1375
+ height: 26px;
1376
+ border: 1px solid transparent;
1377
+ border-radius: 6px;
1378
+ background: none;
1379
+ color: var(--c-muted);
1380
+ font-size: 16px;
1381
+ line-height: 1;
1382
+ cursor: pointer;
1383
+ }
1384
+ .session-collapse:hover {
1385
+ background: var(--c-surface-hover);
1386
+ color: var(--c-text);
1387
+ }
1388
+
1389
+ .session-panel-body {
1390
+ flex: 1;
1391
+ min-height: 0;
1392
+ overflow-y: auto;
1393
+ padding: 12px 12px 16px;
1394
+ display: flex;
1395
+ flex-direction: column;
1396
+ gap: 16px;
1397
+ }
1398
+ .session-section-title {
1399
+ margin: 0 0 8px;
1400
+ font-size: 10px;
1401
+ font-weight: 700;
1402
+ letter-spacing: 0.08em;
1403
+ text-transform: uppercase;
1404
+ color: var(--c-dim);
1405
+ }
1406
+ .session-empty {
1407
+ font-size: 10.5px;
1408
+ line-height: 1.5;
1409
+ color: var(--c-dim);
1410
+ }
1411
+ .session-list {
1412
+ list-style: none;
1413
+ margin: 0;
1414
+ padding: 0;
1415
+ display: flex;
1416
+ flex-direction: column;
1417
+ gap: 6px;
1418
+ }
1419
+
1420
+ /* Work items + gates */
1421
+ .session-item {
1422
+ --glyph: var(--c-dim);
1423
+ display: flex;
1424
+ align-items: flex-start;
1425
+ gap: 8px;
1426
+ padding: 8px 10px;
1427
+ border: 1px solid var(--c-line);
1428
+ border-radius: 8px;
1429
+ background: color-mix(in srgb, var(--c-panel) 70%, transparent);
1430
+ }
1431
+ .session-item.status-running {
1432
+ --glyph: var(--c-accent);
1433
+ }
1434
+ .session-item.status-awaiting {
1435
+ --glyph: var(--c-warn);
1436
+ }
1437
+ .session-item.status-done {
1438
+ --glyph: var(--c-ok);
1439
+ }
1440
+ .session-item.status-vetoed {
1441
+ --glyph: var(--c-danger);
1442
+ }
1443
+ .session-glyph {
1444
+ width: 7px;
1445
+ height: 7px;
1446
+ margin-top: 5px;
1447
+ border-radius: 50%;
1448
+ background: var(--glyph);
1449
+ flex-shrink: 0;
1450
+ }
1451
+ .session-item.status-running .session-glyph {
1452
+ animation: presence-pulse 1.4s ease-in-out infinite;
1453
+ }
1454
+ .session-item-main {
1455
+ flex: 1;
1456
+ min-width: 0;
1457
+ }
1458
+ .session-item-title {
1459
+ display: block;
1460
+ width: 100%;
1461
+ padding: 0;
1462
+ border: none;
1463
+ background: none;
1464
+ text-align: left;
1465
+ font-size: 12px;
1466
+ font-weight: 600;
1467
+ color: var(--c-text-soft);
1468
+ cursor: pointer;
1469
+ white-space: nowrap;
1470
+ overflow: hidden;
1471
+ text-overflow: ellipsis;
1472
+ }
1473
+ .session-item-title:disabled {
1474
+ cursor: default;
1475
+ }
1476
+ .session-item-title:not(:disabled):hover {
1477
+ color: var(--c-text);
1478
+ }
1479
+ .session-item-detail {
1480
+ margin-top: 2px;
1481
+ font-size: 10.5px;
1482
+ line-height: 1.45;
1483
+ color: var(--c-muted);
1484
+ }
1485
+ .session-item-status {
1486
+ font-size: 9px;
1487
+ font-weight: 700;
1488
+ letter-spacing: 0.06em;
1489
+ text-transform: uppercase;
1490
+ color: var(--glyph);
1491
+ flex-shrink: 0;
1492
+ margin-top: 3px;
1493
+ }
1494
+ .session-item-time {
1495
+ font: 9px var(--mono);
1496
+ color: var(--c-dim);
1497
+ flex-shrink: 0;
1498
+ margin-top: 4px;
1499
+ }
1500
+ .session-gate {
1501
+ border-color: color-mix(in srgb, var(--c-warn) 35%, transparent);
1502
+ background: color-mix(in srgb, var(--c-warn) 6%, transparent);
1503
+ }
1504
+ .session-gate-ttl {
1505
+ margin-top: 4px;
1506
+ font: 10px var(--mono);
1507
+ color: var(--c-warn);
1508
+ }
1509
+ .session-gate-held {
1510
+ opacity: 0.85;
1511
+ }
1512
+ .session-gate-actions {
1513
+ display: flex;
1514
+ gap: 6px;
1515
+ margin-top: 8px;
1516
+ }
1517
+ .session-gate-approve,
1518
+ .session-gate-reject {
1519
+ padding: 4px 12px;
1520
+ border-radius: 7px;
1521
+ font-size: 11px;
1522
+ font-weight: 600;
1523
+ cursor: pointer;
1524
+ }
1525
+ .session-gate-approve {
1526
+ border: 1px solid transparent;
1527
+ background: color-mix(in srgb, var(--c-ok) 15%, transparent);
1528
+ color: var(--c-ok);
1529
+ }
1530
+ .session-gate-approve:hover {
1531
+ background: color-mix(in srgb, var(--c-ok) 25%, transparent);
1532
+ }
1533
+ .session-gate-reject {
1534
+ border: 1px solid var(--c-line);
1535
+ background: none;
1536
+ color: var(--c-muted);
1537
+ }
1538
+ .session-gate-reject:hover {
1539
+ border-color: color-mix(in srgb, var(--c-danger) 45%, transparent);
1540
+ color: var(--c-danger);
1541
+ }
1542
+ .session-gate-approve:disabled,
1543
+ .session-gate-reject:disabled {
1544
+ opacity: 0.6;
1545
+ cursor: progress;
1546
+ }
1547
+
1548
+ /* Timeline */
1549
+ /* One row, always: compact chips, no wrapping, and the row runs full-bleed
1550
+ across the panel's inner padding so all six fit. If a theme/locale ever
1551
+ makes them wider still, the row pans horizontally instead of stacking. */
1552
+ .session-section-toggle {
1553
+ display: flex;
1554
+ align-items: center;
1555
+ gap: 8px;
1556
+ width: 100%;
1557
+ padding: 0;
1558
+ background: none;
1559
+ border: none;
1560
+ cursor: pointer;
1561
+ text-align: left;
1562
+ }
1563
+ .session-work-summary {
1564
+ margin-left: auto;
1565
+ display: inline-flex;
1566
+ align-items: center;
1567
+ gap: 6px;
1568
+ font: 10px/1 var(--mono);
1569
+ color: var(--c-muted);
1570
+ }
1571
+ .session-work-dot {
1572
+ width: 8px;
1573
+ height: 8px;
1574
+ border-radius: 50%;
1575
+ background: var(--c-ok);
1576
+ animation: session-work-pulse 1.6s ease-in-out infinite;
1577
+ }
1578
+ @keyframes session-work-pulse {
1579
+ 0%,
1580
+ 100% {
1581
+ opacity: 0.45;
1582
+ transform: scale(0.85);
1583
+ }
1584
+ 50% {
1585
+ opacity: 1;
1586
+ transform: scale(1);
1587
+ }
1588
+ }
1589
+ .session-section-chevron {
1590
+ color: var(--c-muted);
1591
+ font-size: 13px;
1592
+ transition: transform 0.15s ease;
1593
+ }
1594
+ .session-section-chevron.is-open {
1595
+ transform: rotate(90deg);
1596
+ }
1597
+
1598
+ .session-undo-row {
1599
+ display: flex;
1600
+ align-items: center;
1601
+ gap: 8px;
1602
+ padding: 7px 12px;
1603
+ border-bottom: 1px solid var(--c-line);
1604
+ background: var(--c-accent-8);
1605
+ }
1606
+ .session-undo-text {
1607
+ flex: 1;
1608
+ min-width: 0;
1609
+ overflow: hidden;
1610
+ text-overflow: ellipsis;
1611
+ white-space: nowrap;
1612
+ font-size: 11px;
1613
+ color: var(--c-text-soft);
1614
+ }
1615
+ .session-undo-btn {
1616
+ flex-shrink: 0;
1617
+ padding: 3px 10px;
1618
+ border: 1px solid var(--c-accent-25);
1619
+ border-radius: 999px;
1620
+ background: none;
1621
+ color: var(--c-accent);
1622
+ font-size: 11px;
1623
+ font-weight: 600;
1624
+ cursor: pointer;
1625
+ }
1626
+ .session-undo-btn:hover {
1627
+ background: var(--c-accent-10);
1628
+ }
1629
+
1630
+ .session-timeline-filters {
1631
+ display: flex;
1632
+ flex-wrap: nowrap;
1633
+ gap: 1px;
1634
+ margin: 2px -12px 8px;
1635
+ padding: 0 10px;
1636
+ overflow-x: auto;
1637
+ scrollbar-width: none;
1638
+ }
1639
+ .session-timeline-filters::-webkit-scrollbar {
1640
+ display: none;
1641
+ }
1642
+
1643
+ /* The hovered/active chip's one-line meaning — rendered in flow because an
1644
+ anchored tooltip would clip against the filter row's own scroll container. */
1645
+ .session-timeline-hint {
1646
+ margin: -4px 0 8px;
1647
+ font-size: 10px;
1648
+ line-height: 1.35;
1649
+ color: var(--c-muted);
1650
+ min-height: 14px;
1651
+ }
1652
+ .session-timeline-filters .activity-filter {
1653
+ flex-shrink: 0;
1654
+ padding: 2px 5px;
1655
+ }
1656
+
1657
+ .session-timeline-row {
1658
+ --tone: var(--c-muted);
1659
+ display: flex;
1660
+ gap: 8px;
1661
+ padding: 4px 2px;
1662
+ }
1663
+ .session-timeline-row.tone-accent {
1664
+ --tone: var(--c-accent);
1665
+ }
1666
+ .session-timeline-row.tone-ok {
1667
+ --tone: var(--c-ok);
1668
+ }
1669
+ .session-timeline-row.tone-warn {
1670
+ --tone: var(--c-warn);
1671
+ }
1672
+ .session-timeline-row.tone-danger {
1673
+ --tone: var(--c-danger);
1674
+ }
1675
+ .session-timeline-row.tone-purple {
1676
+ --tone: var(--c-purple);
1677
+ }
1678
+ .session-timeline-dot {
1679
+ width: 6px;
1680
+ height: 6px;
1681
+ margin-top: 5px;
1682
+ border-radius: 50%;
1683
+ background: var(--tone);
1684
+ flex-shrink: 0;
1685
+ }
1686
+ .session-timeline-main {
1687
+ flex: 1;
1688
+ min-width: 0;
1689
+ }
1690
+ .session-timeline-head {
1691
+ display: flex;
1692
+ align-items: baseline;
1693
+ gap: 8px;
1694
+ }
1695
+ .session-timeline-label {
1696
+ font-size: 11px;
1697
+ font-weight: 600;
1698
+ color: var(--tone);
1699
+ }
1700
+ /* Row writer in its identity hue — multi-assistant boards need every row to
1701
+ answer "who wrote this" without opening anything. */
1702
+ .session-timeline-who {
1703
+ font-size: 10px;
1704
+ font-weight: 600;
1705
+ color: var(--identity-color, var(--c-muted));
1706
+ white-space: nowrap;
1707
+ overflow: hidden;
1708
+ text-overflow: ellipsis;
1709
+ max-width: 40%;
1710
+ }
1711
+ .session-timeline-undo {
1712
+ display: inline-flex;
1713
+ align-items: center;
1714
+ gap: 5px;
1715
+ margin-top: 5px;
1716
+ padding: 4px 12px;
1717
+ border: 1px solid var(--c-accent);
1718
+ border-radius: 999px;
1719
+ background: var(--c-accent-10);
1720
+ color: var(--c-accent);
1721
+ font-size: 11.5px;
1722
+ font-weight: 700;
1723
+ cursor: pointer;
1724
+ animation: session-work-pulse 1.6s ease-in-out 2;
1725
+ }
1726
+ .session-timeline-undo:hover {
1727
+ background: var(--c-accent);
1728
+ color: var(--c-bg);
1729
+ }
1730
+ .session-timeline-undone {
1731
+ margin-top: 2px;
1732
+ font: 9px var(--mono);
1733
+ color: var(--c-dim);
1734
+ }
1735
+ .session-timeline-body {
1736
+ font-size: 10.5px;
1737
+ line-height: 1.5;
1738
+ color: var(--c-text-soft);
1739
+ overflow-wrap: anywhere;
1740
+ }
1741
+
1742
+ /* Scope row (session panel) */
1743
+ .session-scope {
1744
+ display: flex;
1745
+ align-items: center;
1746
+ gap: 8px;
1747
+ padding: 8px 12px 8px 16px;
1748
+ border-bottom: 1px solid var(--c-line);
1749
+ font-size: 10.5px;
1750
+ color: var(--c-muted);
1751
+ }
1752
+ .session-scope.is-fenced {
1753
+ background: color-mix(in srgb, var(--c-purple) 8%, transparent);
1754
+ color: var(--c-text-soft);
1755
+ }
1756
+ .session-scope-dot {
1757
+ width: 6px;
1758
+ height: 6px;
1759
+ border-radius: 50%;
1760
+ background: var(--c-dim);
1761
+ flex-shrink: 0;
1762
+ }
1763
+ .session-scope.is-fenced .session-scope-dot {
1764
+ background: var(--c-purple);
1765
+ }
1766
+ .session-scope-text {
1767
+ flex: 1;
1768
+ min-width: 0;
1769
+ }
1770
+ .session-scope-text strong {
1771
+ color: var(--c-purple);
1772
+ }
1773
+ .session-scope-action {
1774
+ padding: 3px 9px;
1775
+ border-radius: 6px;
1776
+ border: 1px solid var(--c-line);
1777
+ background: none;
1778
+ color: var(--c-muted);
1779
+ font-size: 10.5px;
1780
+ font-weight: 600;
1781
+ cursor: pointer;
1782
+ white-space: nowrap;
1783
+ }
1784
+ .session-scope-action:hover:not(:disabled) {
1785
+ border-color: color-mix(in srgb, var(--c-purple) 45%, transparent);
1786
+ color: var(--c-purple);
1787
+ }
1788
+ .session-scope-action:disabled {
1789
+ opacity: 0.5;
1790
+ cursor: default;
1791
+ }
1792
+
1793
+ /* Scope fence on the canvas (world layer) */
1794
+ .scope-fence {
1795
+ position: absolute;
1796
+ left: 0;
1797
+ top: 0;
1798
+ z-index: 1;
1799
+ pointer-events: none;
1800
+ border: 1.5px dashed color-mix(in srgb, var(--c-purple) 40%, transparent);
1801
+ border-radius: 16px;
1802
+ background: color-mix(in srgb, var(--c-purple) 3%, transparent);
1803
+ }
1804
+ .scope-fence-pill {
1805
+ position: absolute;
1806
+ left: 14px;
1807
+ transform-origin: 0 50%;
1808
+ padding: 3px 10px;
1809
+ border-radius: 999px;
1810
+ border: 1px solid color-mix(in srgb, var(--c-purple) 35%, transparent);
1811
+ background: color-mix(in srgb, var(--c-panel) 92%, var(--c-purple) 8%);
1812
+ color: var(--c-purple);
1813
+ font-size: 10px;
1814
+ font-weight: 600;
1815
+ letter-spacing: 0.04em;
1816
+ white-space: nowrap;
1817
+ }
1818
+ .scope-fence-pill-top {
1819
+ top: -11px;
1820
+ }
1821
+ .scope-fence-pill-bottom {
1822
+ bottom: -11px;
1823
+ color: var(--c-muted);
1824
+ font-weight: 500;
1825
+ letter-spacing: 0;
1826
+ }
1827
+
1828
+ /* ── Command bar (rail-chrome-v2 phase 5) ─────────────────────
1829
+ The human's steering surface while a session is attached: the design's
1830
+ floating composer, centered at the bottom of the canvas region, with the
1831
+ pinned-context chips floating above it. */
1832
+ .command-bar {
1833
+ position: absolute;
1834
+ left: 50%;
1835
+ bottom: 18px;
1836
+ transform: translateX(-50%);
1837
+ width: min(560px, calc(100% - 48px));
1838
+ z-index: 65;
1839
+ display: flex;
1840
+ flex-direction: column;
1841
+ gap: 6px;
1842
+ }
1843
+ .command-bar-chips {
1844
+ display: flex;
1845
+ flex-wrap: wrap;
1846
+ align-items: center;
1847
+ gap: 6px;
1848
+ }
1849
+ .command-bar-chip {
1850
+ display: inline-flex;
1851
+ align-items: center;
1852
+ gap: 5px;
1853
+ max-width: 240px;
1854
+ padding: 2px 5px 2px 9px;
1855
+ border-radius: 999px;
1856
+ border: 1px solid color-mix(in srgb, var(--c-warn) 35%, transparent);
1857
+ background: color-mix(in srgb, var(--c-warn) 12%, transparent);
1858
+ color: var(--c-warn);
1859
+ font-size: 10px;
1860
+ font-weight: 600;
1861
+ }
1862
+ .command-bar-chip-glyph {
1863
+ font-size: 10px;
1864
+ line-height: 1;
1865
+ }
1866
+ .command-bar-chip-label {
1867
+ overflow: hidden;
1868
+ text-overflow: ellipsis;
1869
+ white-space: nowrap;
1870
+ }
1871
+ .command-bar-chip-unpin {
1872
+ width: 14px;
1873
+ height: 14px;
1874
+ border: none;
1875
+ border-radius: 50%;
1876
+ background: none;
1877
+ color: var(--c-warn);
1878
+ font-size: 12px;
1879
+ line-height: 1;
1880
+ cursor: pointer;
1881
+ opacity: 0.7;
1882
+ }
1883
+ .command-bar-chip-unpin:hover {
1884
+ opacity: 1;
1885
+ background: color-mix(in srgb, var(--c-warn) 25%, transparent);
1886
+ }
1887
+ .command-bar-chips-note {
1888
+ font-size: 10px;
1889
+ color: var(--c-dim);
1890
+ }
1891
+ .command-bar-composer {
1892
+ display: flex;
1893
+ align-items: center;
1894
+ gap: 10px;
1895
+ padding: 10px 14px;
1896
+ border-radius: 12px;
1897
+ border: 1px solid var(--c-line);
1898
+ background: color-mix(in srgb, var(--c-panel) 95%, transparent);
1899
+ backdrop-filter: blur(16px);
1900
+ box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
1901
+ }
1902
+ .command-bar-target {
1903
+ appearance: none;
1904
+ -webkit-appearance: none;
1905
+ max-width: 148px;
1906
+ padding: 4px 18px 4px 8px;
1907
+ border: 1px solid var(--c-line);
1908
+ border-radius: 7px;
1909
+ background: color-mix(in srgb, var(--c-panel) 80%, transparent)
1910
+ url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M1 1l3 3 3-3' fill='none' stroke='%237a8699' stroke-width='1.4'/%3E%3C/svg%3E")
1911
+ no-repeat right 6px center;
1912
+ color: var(--c-text-soft);
1913
+ font: 12px/1.3 var(--mono);
1914
+ cursor: pointer;
1915
+ flex-shrink: 0;
1916
+ }
1917
+ .command-bar-target:hover,
1918
+ .command-bar-target:focus-visible {
1919
+ border-color: var(--c-accent-25);
1920
+ color: var(--c-text);
1921
+ }
1922
+
1923
+ .command-bar-icon {
1924
+ flex-shrink: 0;
1925
+ color: var(--c-purple);
1926
+ }
1927
+ .command-bar-input {
1928
+ flex: 1;
1929
+ min-width: 0;
1930
+ padding: 0;
1931
+ border: none;
1932
+ outline: none;
1933
+ background: none;
1934
+ color: var(--c-text);
1935
+ font: 13px var(--font);
1936
+ }
1937
+ .command-bar-input::placeholder {
1938
+ color: var(--c-dim);
1939
+ }
1940
+ .command-bar-composer:focus-within {
1941
+ border-color: color-mix(in srgb, var(--c-accent) 45%, var(--c-line));
1942
+ }
1943
+ .command-bar-send {
1944
+ flex-shrink: 0;
1945
+ padding: 5px 14px;
1946
+ border-radius: 7px;
1947
+ border: none;
1948
+ background: var(--c-accent);
1949
+ color: var(--c-bg);
1950
+ font-size: 11px;
1951
+ font-weight: 600;
1952
+ cursor: pointer;
1953
+ }
1954
+ .command-bar-send:hover:not(:disabled) {
1955
+ background: color-mix(in srgb, var(--c-accent) 80%, white);
1956
+ }
1957
+ .command-bar-send:disabled {
1958
+ opacity: 0.45;
1959
+ cursor: default;
1960
+ }
1961
+
1962
+ /* Context-budget meter in the top bar (session-only) */
1963
+ .context-budget {
1964
+ --tone: var(--c-ok);
1965
+ display: inline-flex;
1966
+ align-items: center;
1967
+ gap: 8px;
1968
+ flex-shrink: 0;
1969
+ }
1970
+ .context-budget.tone-warn {
1971
+ --tone: var(--c-warn);
1972
+ }
1973
+ .context-budget.tone-danger {
1974
+ --tone: var(--c-danger);
1975
+ }
1976
+ .context-budget-caption {
1977
+ font-size: 10px;
1978
+ font-weight: 600;
1979
+ letter-spacing: 0.06em;
1980
+ text-transform: uppercase;
1981
+ color: var(--c-muted);
1982
+ }
1983
+ .context-budget-track {
1984
+ display: block;
1985
+ width: 72px;
1986
+ height: 5px;
1987
+ border-radius: 3px;
1988
+ background: var(--c-line);
1989
+ overflow: hidden;
1990
+ }
1991
+ .context-budget-fill {
1992
+ display: block;
1993
+ height: 100%;
1994
+ border-radius: 3px;
1995
+ background: linear-gradient(90deg, var(--c-accent), var(--c-warn));
1996
+ transition: width 180ms ease;
1997
+ }
1998
+ .context-budget.tone-warn .context-budget-fill,
1999
+ .context-budget.tone-danger .context-budget-fill {
2000
+ background: var(--tone);
2001
+ }
2002
+ .context-budget-label {
2003
+ font: 11px var(--mono);
2004
+ color: var(--c-text-soft);
2005
+ min-width: 30px;
2006
+ text-align: right;
2007
+ }
2008
+
2009
+ /* ── External Steering (rail-chrome-v2 phase 6) ───────────────
2010
+ External writers, no session: a passive top-bar indicator, the activity
2011
+ feed popover under it, and the connected-writers sheet. Quiet otherwise. */
2012
+ .writer-avatar {
2013
+ display: inline-flex;
2014
+ align-items: center;
2015
+ justify-content: center;
2016
+ border-radius: 50%;
2017
+ border: 1.5px solid var(--c-panel-soft);
2018
+ color: var(--c-bg);
2019
+ font-size: 8.5px;
2020
+ font-weight: 700;
2021
+ flex-shrink: 0;
2022
+ }
2023
+ .external-indicator {
2024
+ display: inline-flex;
2025
+ align-items: center;
2026
+ gap: 8px;
2027
+ padding: 4px 12px 4px 6px;
2028
+ border-radius: 999px;
2029
+ border: 1px solid color-mix(in srgb, var(--c-purple) 35%, transparent);
2030
+ background: color-mix(in srgb, var(--c-purple) 8%, transparent);
2031
+ color: var(--c-purple);
2032
+ cursor: pointer;
2033
+ white-space: nowrap;
2034
+ flex-shrink: 0;
2035
+ font: inherit;
2036
+ }
2037
+ .external-indicator:hover,
2038
+ .external-indicator[aria-expanded='true'] {
2039
+ background: color-mix(in srgb, var(--c-purple) 15%, transparent);
2040
+ }
2041
+ .external-indicator-avatars {
2042
+ display: inline-flex;
2043
+ align-items: center;
2044
+ }
2045
+ .external-indicator-avatars .writer-avatar + .writer-avatar {
2046
+ margin-left: -6px;
2047
+ }
2048
+ .external-indicator-label {
2049
+ font-size: 11px;
2050
+ font-weight: 600;
2051
+ }
2052
+ .external-indicator-ops {
2053
+ font: 10px var(--mono);
2054
+ color: var(--c-muted);
2055
+ }
2056
+ .external-indicator-dot {
2057
+ width: 7px;
2058
+ height: 7px;
2059
+ border-radius: 50%;
2060
+ background: var(--c-purple);
2061
+ flex-shrink: 0;
2062
+ animation: presence-pulse 1.4s ease-in-out infinite;
2063
+ }
2064
+
2065
+ .activity-feed {
2066
+ position: absolute;
2067
+ top: 10px;
2068
+ right: 14px;
2069
+ width: min(304px, calc(100% - 28px));
2070
+ max-height: calc(100% - 20px);
2071
+ display: flex;
2072
+ flex-direction: column;
2073
+ background: var(--c-panel);
2074
+ border: 1px solid color-mix(in srgb, var(--c-purple) 30%, transparent);
2075
+ border-radius: 10px;
2076
+ box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
2077
+ /* Popover-level like the rail menus: above the minimap, below the rail. */
2078
+ z-index: 9999;
2079
+ overflow: hidden;
2080
+ }
2081
+ .activity-feed-head {
2082
+ display: flex;
2083
+ align-items: center;
2084
+ gap: 8px;
2085
+ padding: 9px 13px;
2086
+ border-bottom: 1px solid var(--c-line);
2087
+ background: color-mix(in srgb, var(--c-bg) 60%, transparent);
2088
+ }
2089
+ .activity-feed-titles {
2090
+ flex: 1;
2091
+ min-width: 0;
2092
+ }
2093
+ .activity-feed-title {
2094
+ font-size: 11.5px;
2095
+ font-weight: 600;
2096
+ color: var(--c-text);
2097
+ }
2098
+ .activity-feed-sub {
2099
+ font: 9px var(--mono);
2100
+ color: var(--c-dim);
2101
+ }
2102
+ .activity-feed-close {
2103
+ background: none;
2104
+ border: none;
2105
+ color: var(--c-muted);
2106
+ font-size: 14px;
2107
+ cursor: pointer;
2108
+ padding: 0 2px;
2109
+ }
2110
+ .activity-feed-close:hover {
2111
+ color: var(--c-text);
2112
+ }
2113
+ .activity-filters {
2114
+ display: flex;
2115
+ flex-wrap: wrap;
2116
+ gap: 4px;
2117
+ padding: 7px 10px;
2118
+ border-bottom: 1px solid var(--c-line);
2119
+ }
2120
+ .activity-filter {
2121
+ --writer: var(--c-purple);
2122
+ padding: 2px 9px;
2123
+ border-radius: 999px;
2124
+ border: 1px solid var(--c-line);
2125
+ background: none;
2126
+ color: var(--c-muted);
2127
+ font-size: 10px;
2128
+ font-weight: 600;
2129
+ cursor: pointer;
2130
+ }
2131
+ .activity-filter.is-active {
2132
+ border-color: color-mix(in srgb, var(--writer) 45%, transparent);
2133
+ background: color-mix(in srgb, var(--writer) 14%, transparent);
2134
+ color: var(--writer);
2135
+ }
2136
+ .activity-rows {
2137
+ display: flex;
2138
+ flex-direction: column;
2139
+ overflow-y: auto;
2140
+ min-height: 0;
2141
+ }
2142
+ .activity-row {
2143
+ display: flex;
2144
+ gap: 9px;
2145
+ padding: 9px 13px;
2146
+ border-bottom: 1px solid var(--c-line);
2147
+ }
2148
+ .activity-row:last-child {
2149
+ border-bottom: none;
2150
+ }
2151
+ .activity-row.is-pending {
2152
+ background: color-mix(in srgb, var(--c-purple) 5%, transparent);
2153
+ }
2154
+ .activity-glyph {
2155
+ flex-shrink: 0;
2156
+ width: 13px;
2157
+ margin-top: 1px;
2158
+ text-align: center;
2159
+ font-size: 11px;
2160
+ font-weight: 700;
2161
+ line-height: 1.3;
2162
+ }
2163
+ .activity-glyph.tone-ok {
2164
+ color: var(--c-ok);
2165
+ }
2166
+ .activity-glyph.tone-danger {
2167
+ color: var(--c-danger);
2168
+ }
2169
+ .activity-glyph.tone-accent {
2170
+ color: var(--c-accent);
2171
+ }
2172
+ .activity-glyph.tone-purple {
2173
+ color: var(--c-purple);
2174
+ }
2175
+ .activity-main {
2176
+ flex: 1;
2177
+ min-width: 0;
2178
+ }
2179
+ .activity-text {
2180
+ font-size: 11px;
2181
+ color: var(--c-text-soft);
2182
+ overflow-wrap: anywhere;
2183
+ }
2184
+ .activity-meta {
2185
+ font-size: 10px;
2186
+ line-height: 1.45;
2187
+ color: var(--c-muted);
2188
+ }
2189
+ .activity-writer {
2190
+ font: 8.5px var(--mono);
2191
+ }
2192
+ .activity-actions {
2193
+ display: flex;
2194
+ align-items: center;
2195
+ gap: 6px;
2196
+ margin-top: 6px;
2197
+ }
2198
+ .activity-veto {
2199
+ padding: 3px 10px;
2200
+ border-radius: 7px;
2201
+ background: none;
2202
+ border: 1px solid color-mix(in srgb, var(--c-danger) 40%, transparent);
2203
+ color: var(--c-danger);
2204
+ font-size: 10.5px;
2205
+ font-weight: 600;
2206
+ cursor: pointer;
2207
+ }
2208
+ .activity-veto:hover {
2209
+ background: color-mix(in srgb, var(--c-danger) 10%, transparent);
2210
+ }
2211
+ .activity-hint,
2212
+ .activity-age {
2213
+ font: 9px var(--mono);
2214
+ color: var(--c-dim);
2215
+ flex-shrink: 0;
2216
+ }
2217
+ .activity-empty {
2218
+ padding: 14px 13px;
2219
+ font-size: 11px;
2220
+ color: var(--c-dim);
2221
+ }
2222
+ .activity-feed-foot {
2223
+ display: flex;
2224
+ align-items: center;
2225
+ gap: 10px;
2226
+ padding: 8px 13px;
2227
+ border-top: 1px solid var(--c-line);
2228
+ background: color-mix(in srgb, var(--c-bg) 50%, transparent);
2229
+ }
2230
+ .activity-feed-note {
2231
+ flex: 1;
2232
+ font-size: 10px;
2233
+ color: var(--c-dim);
2234
+ }
2235
+ .activity-feed-link {
2236
+ background: none;
2237
+ border: none;
2238
+ padding: 0;
2239
+ color: var(--c-muted);
2240
+ font-size: 10.5px;
2241
+ font-weight: 600;
2242
+ cursor: pointer;
2243
+ }
2244
+ .activity-feed-link:hover {
2245
+ color: var(--c-text);
2246
+ }
2247
+ .activity-feed-link.is-accent {
2248
+ color: var(--c-purple);
2249
+ }
2250
+ .activity-feed-link.is-accent:hover {
2251
+ text-decoration: underline;
2252
+ }
2253
+
2254
+ .writers-scrim {
2255
+ position: absolute;
2256
+ inset: 0;
2257
+ background: rgba(4, 10, 18, 0.55);
2258
+ z-index: 9999;
2259
+ }
2260
+ .writers-sheet {
2261
+ position: absolute;
2262
+ top: 50%;
2263
+ left: 50%;
2264
+ transform: translate(-50%, -50%);
2265
+ width: 400px;
2266
+ max-width: calc(100% - 48px);
2267
+ background: var(--c-panel);
2268
+ border: 1px solid var(--c-line);
2269
+ border-radius: 12px;
2270
+ box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
2271
+ z-index: 10000;
2272
+ overflow: hidden;
2273
+ }
2274
+ .writers-head {
2275
+ display: flex;
2276
+ align-items: center;
2277
+ gap: 8px;
2278
+ padding: 11px 14px;
2279
+ border-bottom: 1px solid var(--c-line);
2280
+ background: color-mix(in srgb, var(--c-bg) 60%, transparent);
2281
+ }
2282
+ .writers-title {
2283
+ flex: 1;
2284
+ font-size: 12px;
2285
+ font-weight: 600;
2286
+ color: var(--c-text);
2287
+ }
2288
+ .writers-board {
2289
+ font: 9px var(--mono);
2290
+ color: var(--c-dim);
2291
+ }
2292
+ .writers-body {
2293
+ display: flex;
2294
+ flex-direction: column;
2295
+ gap: 4px;
2296
+ padding: 10px 14px;
2297
+ }
2298
+ .writers-section {
2299
+ padding: 8px 0 2px;
2300
+ font-size: 9px;
2301
+ font-weight: 700;
2302
+ letter-spacing: 0.08em;
2303
+ text-transform: uppercase;
2304
+ color: var(--c-dim);
2305
+ }
2306
+ .writers-row {
2307
+ display: flex;
2308
+ align-items: center;
2309
+ gap: 9px;
2310
+ padding: 6px 0;
2311
+ }
2312
+ .writers-name {
2313
+ flex: 1;
2314
+ font-size: 11.5px;
2315
+ color: var(--c-text-soft);
2316
+ min-width: 0;
2317
+ overflow: hidden;
2318
+ text-overflow: ellipsis;
2319
+ white-space: nowrap;
2320
+ }
2321
+ .writers-name.is-mono {
2322
+ font: 11px var(--mono);
2323
+ }
2324
+ .writers-config {
2325
+ font-size: 9.5px;
2326
+ font-weight: 600;
2327
+ padding: 2px 8px;
2328
+ border-radius: 999px;
2329
+ background: color-mix(in srgb, var(--c-purple) 12%, transparent);
2330
+ color: var(--c-purple);
2331
+ }
2332
+ .writers-meta {
2333
+ font: 9.5px var(--mono);
2334
+ color: var(--c-dim);
2335
+ }
2336
+ .writers-empty {
2337
+ font-size: 10.5px;
2338
+ color: var(--c-dim);
2339
+ padding: 4px 0;
2340
+ }
2341
+ .writers-foot {
2342
+ display: flex;
2343
+ align-items: center;
2344
+ gap: 10px;
2345
+ padding: 10px 14px;
2346
+ border-top: 1px solid var(--c-line);
2347
+ background: color-mix(in srgb, var(--c-bg) 50%, transparent);
2348
+ }
2349
+ .writers-note {
2350
+ flex: 1;
2351
+ font-size: 10px;
2352
+ color: var(--c-dim);
2353
+ }
2354
+ .writers-done {
2355
+ padding: 5px 14px;
2356
+ border: none;
2357
+ border-radius: 7px;
2358
+ background: var(--c-accent);
2359
+ color: var(--c-bg);
2360
+ font-size: 11px;
2361
+ font-weight: 600;
2362
+ cursor: pointer;
2363
+ }
2364
+
2365
+ /* ── Minimap v2 (rail-chrome-v2 phase 7, item 19) ─────────────
2366
+ True-scale map from the store; magnifies ×1.7 from the bottom-right on hover. */
2367
+ .minimap {
2368
+ position: absolute;
2369
+ bottom: 18px;
2370
+ right: 16px;
2371
+ width: 168px;
2372
+ height: 112px;
2373
+ border: 1px solid var(--c-line);
2374
+ border-radius: 8px;
2375
+ overflow: hidden;
2376
+ box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
2377
+ background: color-mix(in srgb, var(--c-panel-soft) 94%, transparent);
2378
+ backdrop-filter: blur(8px);
2379
+ z-index: 60;
2380
+ opacity: 0.85;
2381
+ transform-origin: bottom right;
2382
+ transition:
2383
+ transform 160ms ease,
2384
+ opacity 120ms ease;
2385
+ cursor: crosshair;
2386
+ user-select: none;
2387
+ }
2388
+ .minimap:hover {
2389
+ opacity: 1;
2390
+ transform: scale(1.7);
2391
+ box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55);
2392
+ }
2393
+ .minimap-node {
2394
+ position: absolute;
2395
+ border-radius: 1.5px;
2396
+ background: var(--kind);
2397
+ opacity: 0.55;
2398
+ }
2399
+ .minimap-node.is-group {
2400
+ background: color-mix(in srgb, var(--kind) 4%, transparent);
2401
+ border: 1px dashed color-mix(in srgb, var(--kind) 55%, transparent);
2402
+ opacity: 1;
2403
+ border-radius: 2px;
2404
+ }
2405
+ .minimap-node.is-selected {
2406
+ outline: 1px solid var(--c-accent);
2407
+ opacity: 0.8;
2408
+ }
2409
+ .minimap-fence {
2410
+ position: absolute;
2411
+ border: 1px dashed color-mix(in srgb, var(--c-purple) 45%, transparent);
2412
+ border-radius: 2px;
2413
+ background: color-mix(in srgb, var(--c-purple) 3%, transparent);
2414
+ }
2415
+ .minimap-presence {
2416
+ position: absolute;
2417
+ width: 8px;
2418
+ height: 8px;
2419
+ border-radius: 50%;
2420
+ background: var(--presence-color);
2421
+ border: 1.5px solid var(--c-bg);
2422
+ box-shadow: 0 0 0 2px color-mix(in srgb, var(--presence-color) 45%, transparent);
2423
+ z-index: 4;
2424
+ }
2425
+ /* Actively working = the moment the human is looking for: pulse the halo. */
2426
+ .minimap-presence.phase-thinking,
2427
+ .minimap-presence.phase-tooling {
2428
+ animation: presence-pulse 1.6s ease-in-out infinite;
2429
+ }
2430
+ .minimap-presence.is-worker {
2431
+ width: 6px;
2432
+ height: 6px;
2433
+ }
2434
+ .minimap-presence.is-external {
2435
+ opacity: 0.75;
2436
+ }
2437
+ .minimap-frame {
2438
+ position: absolute;
2439
+ border: 1.5px solid color-mix(in srgb, var(--c-accent) 85%, transparent);
2440
+ border-radius: 2px;
2441
+ background: color-mix(in srgb, var(--c-accent) 5%, transparent);
2442
+ cursor: grab;
2443
+ }
2444
+ .minimap-zoom {
2445
+ position: absolute;
2446
+ right: 5px;
2447
+ bottom: 3px;
2448
+ font: 8px var(--mono);
2449
+ color: var(--c-dim);
2450
+ }
2451
+
2452
+ /* ── Accessibility sweep (rail-chrome-v2 item 18) ───────────────
2453
+ One focus ring for every chrome control; nodes are focusable for the
2454
+ keyboard (arrow keys traverse, Enter opens); reduced motion below. */
2455
+ .tool-rail button:focus-visible,
2456
+ .top-bar button:focus-visible,
2457
+ .connection-banner button:focus-visible,
2458
+ .session-panel button:focus-visible,
2459
+ .session-panel input:focus-visible,
2460
+ .command-bar button:focus-visible,
2461
+ .command-bar-input:focus-visible,
2462
+ .selection-bar button:focus-visible,
2463
+ .activity-feed button:focus-visible,
2464
+ .writers-sheet button:focus-visible,
2465
+ .empty-state button:focus-visible,
2466
+ .session-receipt button:focus-visible,
2467
+ .snapshot-panel button:focus-visible,
2468
+ .expanded-header button:focus-visible,
2469
+ .group-action:focus-visible,
2470
+ .group-menu button:focus-visible,
2471
+ .command-palette-item:focus-visible,
2472
+ .canvas-node:focus-visible {
2473
+ outline: 2px solid var(--c-accent);
2474
+ outline-offset: 2px;
2475
+ }
2476
+ .command-bar-input:focus-visible {
2477
+ outline: none;
2478
+ }
2479
+ .canvas-node:focus {
2480
+ outline: none;
2481
+ }
2482
+ .canvas-node:focus-visible {
2483
+ outline: 2px solid var(--c-accent);
2484
+ outline-offset: 3px;
2485
+ }
2486
+
2487
+ @media (prefers-reduced-motion: reduce) {
2488
+ .human-cursor {
2489
+ transition: none;
2490
+ }
2491
+ .connection-banner-progress-fill,
2492
+ .connection-dot,
2493
+ .external-indicator-dot,
2494
+ .group-chip-expand,
2495
+ .beta-tag {
2496
+ margin-left: 2px;
2497
+ padding: 1px 5px;
2498
+ border-radius: 8px;
2499
+ border: 1px solid color-mix(in srgb, var(--c-accent) 45%, transparent);
2500
+ color: var(--c-accent);
2501
+ font-size: 9px;
2502
+ font-weight: 700;
2503
+ letter-spacing: 0.06em;
2504
+ text-transform: uppercase;
2505
+ line-height: 1.4;
2506
+ }
2507
+
2508
+ .start-session-dot {
2509
+ animation: none;
2510
+ }
2511
+ .command-palette,
2512
+ .snapshot-panel,
2513
+ .session-receipt,
2514
+ .canvas-node.group-node,
2515
+ .activity-feed,
2516
+ .writers-sheet,
2517
+ .context-budget-fill {
2518
+ animation: none;
2519
+ transition: none;
2520
+ }
2521
+ }
2522
+
2523
+ /* ── Edge creation (rail-chrome-v2 item 15) ───────────────────── */
2524
+ .canvas-node.is-edge-target {
2525
+ box-shadow: 0 0 0 2px var(--c-accent), 0 0 0 6px color-mix(in srgb, var(--c-accent) 18%, transparent);
2526
+ }
2527
+ .canvas-node.is-edge-target .node-port {
2528
+ opacity: 1;
2529
+ background: var(--c-accent);
2530
+ }
2531
+ .edge-hint-pill {
2532
+ position: absolute;
2533
+ z-index: 10000;
2534
+ display: inline-flex;
2535
+ align-items: center;
2536
+ gap: 6px;
2537
+ padding: 3px 10px;
2538
+ border-radius: 999px;
2539
+ background: color-mix(in srgb, var(--c-panel) 96%, transparent);
2540
+ border: 1px solid color-mix(in srgb, var(--c-accent) 40%, transparent);
2541
+ pointer-events: none;
2542
+ white-space: nowrap;
2543
+ }
2544
+ .edge-hint-main {
2545
+ font-size: 10px;
2546
+ font-weight: 600;
2547
+ color: var(--c-accent);
2548
+ }
2549
+ .edge-hint-keys {
2550
+ font: 9px var(--mono);
2551
+ color: var(--c-dim);
2552
+ }
2553
+
2554
+ /* ── Human collaborator presence (rail-chrome-v2 phase 8) ─────── */
2555
+ .human-presence-layer {
2556
+ position: absolute;
2557
+ left: 0;
2558
+ top: 0;
2559
+ pointer-events: none;
2560
+ z-index: 69;
2561
+ }
2562
+ .human-cursor {
2563
+ position: absolute;
2564
+ left: 0;
2565
+ top: 0;
2566
+ color: var(--c-ok);
2567
+ transition: transform 120ms linear;
2568
+ }
2569
+ .human-cursor-inner {
2570
+ transform-origin: top left;
2571
+ display: flex;
2572
+ flex-direction: column;
2573
+ align-items: flex-start;
2574
+ }
2575
+ .human-cursor-tag {
2576
+ margin-left: 11px;
2577
+ margin-top: -2px;
2578
+ padding: 3px 9px;
2579
+ border-radius: 999px;
2580
+ background: color-mix(in srgb, var(--c-ok) 92%, transparent);
2581
+ color: var(--c-bg);
2582
+ font-size: 10px;
2583
+ font-weight: 600;
2584
+ white-space: nowrap;
2585
+ }
2586
+ .human-cursor.is-grabbing .human-cursor-tag::after {
2587
+ content: ' · editing';
2588
+ font-weight: 500;
2589
+ opacity: 0.8;
2590
+ }
2591
+ .node-yield-pill {
2592
+ /* Inside the card (paint containment clips anything outside it). */
2593
+ position: absolute;
2594
+ left: 10px;
2595
+ bottom: 8px;
2596
+ z-index: 5;
2597
+ display: inline-flex;
2598
+ align-items: center;
2599
+ gap: 5px;
2600
+ padding: 2px 9px;
2601
+ border-radius: 999px;
2602
+ background: var(--c-panel-soft);
2603
+ border: 1px solid color-mix(in srgb, var(--c-warn) 40%, transparent);
2604
+ color: var(--c-warn);
2605
+ font-size: 9.5px;
2606
+ font-weight: 600;
2607
+ white-space: nowrap;
2608
+ }
2609
+ .node-yield-dot {
2610
+ width: 6px;
2611
+ height: 6px;
2612
+ border-radius: 50%;
2613
+ background: var(--c-warn);
2614
+ }
2615
+
2616
+ /* Quiet-board affordance in the top bar */
2617
+ .start-session-btn {
2618
+ display: inline-flex;
2619
+ align-items: center;
2620
+ gap: 7px;
2621
+ padding: 5px 12px;
2622
+ border-radius: 999px;
2623
+ border: 1px solid var(--c-line);
2624
+ background: none;
2625
+ color: var(--c-muted);
2626
+ font-size: 11px;
2627
+ font-weight: 600;
2628
+ white-space: nowrap;
2629
+ cursor: pointer;
2630
+ flex-shrink: 0;
2631
+ }
2632
+ .start-session-btn:hover {
2633
+ border-color: color-mix(in srgb, var(--c-purple) 40%, transparent);
2634
+ color: var(--c-purple);
2635
+ }
2636
+ .start-session-dot {
2637
+ width: 7px;
2638
+ height: 7px;
2639
+ border-radius: 50%;
2640
+ background: var(--c-dim);
2641
+ }
2642
+ .start-session-btn:hover .start-session-dot {
2643
+ background: var(--c-purple);
2644
+ }
2645
+ .session-end {
2646
+ padding: 3px 10px;
2647
+ border-radius: 6px;
2648
+ border: 1px solid var(--c-line);
2649
+ background: none;
2650
+ color: var(--c-muted);
2651
+ font-size: 10.5px;
2652
+ font-weight: 600;
2653
+ cursor: pointer;
2654
+ }
2655
+ .session-end:hover {
2656
+ border-color: color-mix(in srgb, var(--c-danger) 45%, transparent);
2657
+ color: var(--c-danger);
2658
+ }
2659
+
2660
+ /* Session receipt (design item 2) */
2661
+ .session-receipt {
2662
+ position: absolute;
2663
+ top: 14px;
2664
+ right: 14px;
2665
+ width: 290px;
2666
+ z-index: 9998;
2667
+ padding: 12px 14px;
2668
+ border-radius: 12px;
2669
+ border: 1px solid var(--c-line);
2670
+ background: color-mix(in srgb, var(--c-panel) 96%, transparent);
2671
+ box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
2672
+ animation: session-panel-in 180ms ease;
2673
+ }
2674
+ .session-receipt-head {
2675
+ display: flex;
2676
+ align-items: center;
2677
+ gap: 8px;
2678
+ }
2679
+ .session-receipt-dot {
2680
+ width: 7px;
2681
+ height: 7px;
2682
+ border-radius: 50%;
2683
+ background: var(--c-dim);
2684
+ }
2685
+ .session-receipt-title {
2686
+ flex: 1;
2687
+ font-size: 12px;
2688
+ font-weight: 600;
2689
+ color: var(--c-text);
2690
+ }
2691
+ .session-receipt-close {
2692
+ width: 22px;
2693
+ height: 22px;
2694
+ border: none;
2695
+ border-radius: 6px;
2696
+ background: none;
2697
+ color: var(--c-muted);
2698
+ font-size: 14px;
2699
+ cursor: pointer;
2700
+ }
2701
+ .session-receipt-close:hover {
2702
+ background: var(--c-surface-hover);
2703
+ color: var(--c-text);
2704
+ }
2705
+ .session-receipt-tiles {
2706
+ display: grid;
2707
+ grid-template-columns: repeat(3, 1fr);
2708
+ gap: 8px;
2709
+ margin-top: 12px;
2710
+ }
2711
+ .session-receipt-tile {
2712
+ padding: 8px 10px;
2713
+ border-radius: 8px;
2714
+ border: 1px solid var(--c-line);
2715
+ background: color-mix(in srgb, var(--c-panel-soft) 70%, transparent);
2716
+ display: flex;
2717
+ flex-direction: column;
2718
+ gap: 2px;
2719
+ }
2720
+ .session-receipt-tile-label {
2721
+ font-size: 9.5px;
2722
+ color: var(--c-dim);
2723
+ }
2724
+ .session-receipt-tile-value {
2725
+ font-size: 15px;
2726
+ font-weight: 700;
2727
+ color: var(--c-text);
2728
+ }
2729
+ .session-receipt-tile-value.tone-ok {
2730
+ color: var(--c-ok);
2731
+ }
2732
+ .session-receipt-tile-value.tone-danger {
2733
+ color: var(--c-danger);
2734
+ }
2735
+ .session-receipt-note,
2736
+ .session-receipt-diff {
2737
+ margin-top: 10px;
2738
+ font-size: 10.5px;
2739
+ line-height: 1.5;
2740
+ color: var(--c-muted);
2741
+ }
2742
+ .session-receipt-diff {
2743
+ color: var(--c-text-soft);
2744
+ }
2745
+ .session-receipt-actions {
2746
+ display: flex;
2747
+ gap: 8px;
2748
+ margin-top: 12px;
2749
+ }
2750
+ .session-receipt-primary,
2751
+ .session-receipt-secondary {
2752
+ flex: 1;
2753
+ padding: 7px 10px;
2754
+ border-radius: 8px;
2755
+ font-size: 11px;
2756
+ font-weight: 600;
2757
+ cursor: pointer;
2758
+ }
2759
+ .session-receipt-primary {
2760
+ border: 1px solid var(--c-accent-25);
2761
+ background: var(--c-accent-12);
2762
+ color: var(--c-accent);
2763
+ }
2764
+ .session-receipt-primary:disabled {
2765
+ opacity: 0.5;
2766
+ cursor: default;
2767
+ }
2768
+ .session-receipt-secondary {
2769
+ border: 1px solid var(--c-line);
2770
+ background: none;
2771
+ color: var(--c-muted);
2772
+ }
2773
+ .session-receipt-secondary:hover {
2774
+ color: var(--c-text);
2775
+ }
2776
+
2777
+ /* Top-bar escalation badge while gates are pending */
2778
+ .gate-badge {
2779
+ display: inline-flex;
2780
+ align-items: center;
2781
+ padding: 5px 10px;
2782
+ border-radius: 999px;
2783
+ border: 1px solid color-mix(in srgb, var(--c-warn) 35%, transparent);
2784
+ background: color-mix(in srgb, var(--c-warn) 12%, transparent);
2785
+ color: var(--c-warn);
2786
+ font: 11px var(--mono);
2787
+ font-weight: 600;
2788
+ white-space: nowrap;
2789
+ flex-shrink: 0;
2790
+ }
2791
+
2792
+ @keyframes session-panel-in {
2793
+ from {
2794
+ opacity: 0;
2795
+ transform: translateX(8px);
2796
+ }
2797
+ to {
2798
+ opacity: 1;
2799
+ transform: none;
2800
+ }
2801
+ }
2802
+
2803
+ /* Below 1180px the panel floats over the canvas as a drawer (design item 12). */
2804
+ @media (max-width: 1180px) {
2805
+ .session-panel:not(.is-collapsed) {
2806
+ position: fixed;
2807
+ top: var(--hud-bar-height);
2808
+ right: 0;
2809
+ bottom: 0;
2810
+ width: 312px;
2811
+ box-shadow: -16px 0 40px rgba(0, 0, 0, 0.5);
2812
+ }
2813
+ }
2814
+
2815
+ @media (prefers-reduced-motion: reduce) {
2816
+ .session-panel {
2817
+ animation: none;
2818
+ }
2819
+ .session-live-dot,
2820
+ .session-item.status-running .session-glyph,
2821
+ .external-indicator-dot,
2822
+ .minimap-presence {
2823
+ animation: none;
2824
+ }
2825
+ .minimap {
2826
+ transition: none;
2827
+ }
2828
+ }
2829
+
2830
+ /* Pan tool / held Space: the world layer goes pointer-inert so drags land on
2831
+ the viewport container itself and pan — nodes cannot swallow the drag. */
2832
+ .canvas-viewport.pan-mode .canvas-world {
2833
+ pointer-events: none;
2834
+ }
2835
+ .canvas-viewport.pan-mode:active {
2836
+ cursor: grabbing;
2837
+ }
2838
+
2839
+ .toolbar-tooltip-anchor {
2840
+ position: relative;
2841
+ display: inline-flex;
2842
+ align-items: center;
2843
+ }
2844
+
2845
+ .toolbar-tooltip-anchor-start .toolbar-tooltip {
2846
+ left: 0;
2847
+ transform: translateX(0) translateY(6px);
2848
+ }
2849
+
2850
+ .toolbar-tooltip-anchor-end .toolbar-tooltip {
2851
+ left: auto;
2852
+ right: 0;
2853
+ transform: translateX(0) translateY(6px);
2854
+ }
2855
+
2856
+ .toolbar-tooltip {
2857
+ position: absolute;
2858
+ left: 50%;
2859
+ top: calc(100% + 10px);
2860
+ transform: translateX(-50%) translateY(6px);
2861
+ display: flex;
2862
+ flex-direction: column;
2863
+ gap: 4px;
2864
+ min-width: 168px;
2865
+ max-width: 240px;
2866
+ padding: 10px 12px;
2867
+ background: color-mix(in srgb, var(--c-panel) 92%, black 8%);
2868
+ border: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2869
+ border-radius: 10px;
2870
+ box-shadow: 0 14px 36px var(--c-shadow-heavy), 0 0 0 1px var(--c-accent-8);
2871
+ backdrop-filter: blur(14px);
2872
+ color: var(--c-text);
2873
+ font-size: 12px;
2874
+ line-height: 1.35;
2875
+ white-space: normal;
2876
+ opacity: 0;
2877
+ pointer-events: none;
2878
+ z-index: 10010;
2879
+ transition: opacity 0.14s ease, transform 0.14s ease;
2880
+ }
2881
+
2882
+ .toolbar-tooltip::after {
2883
+ content: '';
2884
+ position: absolute;
2885
+ left: 50%;
2886
+ top: -5px;
2887
+ width: 10px;
2888
+ height: 10px;
2889
+ background: inherit;
2890
+ border-top: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2891
+ border-left: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2892
+ transform: translateX(-50%) rotate(45deg);
2893
+ }
2894
+
2895
+ .toolbar-tooltip-anchor-start .toolbar-tooltip::after {
2896
+ left: 18px;
2897
+ transform: rotate(45deg);
2898
+ }
2899
+
2900
+ .toolbar-tooltip-anchor-end .toolbar-tooltip::after {
2901
+ left: auto;
2902
+ right: 18px;
2903
+ transform: rotate(45deg);
2904
+ }
2905
+
2906
+ /* Up variant: bottom-anchored bars (selection bar) open their tooltip above. */
2907
+ .toolbar-tooltip-anchor-up .toolbar-tooltip {
2908
+ top: auto;
2909
+ bottom: calc(100% + 10px);
2910
+ transform: translateX(-50%) translateY(-6px);
2911
+ }
2912
+ .toolbar-tooltip-anchor-up .toolbar-tooltip::after {
2913
+ top: auto;
2914
+ bottom: -5px;
2915
+ border-top: none;
2916
+ border-left: none;
2917
+ border-bottom: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2918
+ border-right: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2919
+ }
2920
+ .toolbar-tooltip-anchor-up:hover .toolbar-tooltip,
2921
+ .toolbar-tooltip-anchor-up > :focus-visible + .toolbar-tooltip {
2922
+ transform: translateX(-50%) translateY(0);
2923
+ }
2924
+
2925
+ /* :focus-within opens the tooltip only on tap-to-open (informational)
2926
+ anchors — an action button's tooltip must dismiss after its click. */
2927
+ .toolbar-tooltip-anchor:hover .toolbar-tooltip,
2928
+ .toolbar-tooltip-anchor-tap:focus-within .toolbar-tooltip,
2929
+ .toolbar-tooltip-anchor > :focus-visible + .toolbar-tooltip {
2930
+ opacity: 1;
2931
+ transform: translateX(-50%) translateY(0);
2932
+ }
2933
+
2934
+ .toolbar-tooltip-anchor-start:hover .toolbar-tooltip,
2935
+ .toolbar-tooltip-anchor-start.toolbar-tooltip-anchor-tap:focus-within .toolbar-tooltip,
2936
+ .toolbar-tooltip-anchor-start > :focus-visible + .toolbar-tooltip,
2937
+ .toolbar-tooltip-anchor-end:hover .toolbar-tooltip,
2938
+ .toolbar-tooltip-anchor-end.toolbar-tooltip-anchor-tap:focus-within .toolbar-tooltip,
2939
+ .toolbar-tooltip-anchor-end > :focus-visible + .toolbar-tooltip {
2940
+ transform: translateX(0) translateY(0);
2941
+ }
2942
+
2943
+ .toolbar-tooltip-anchor {
2944
+ outline: none;
2945
+ }
2946
+
2947
+ /* Rail variant: fixed beside the hovered button (the rail's scroll clip would
2948
+ swallow an absolute one), arrow on the left, mounted only while hovered. */
2949
+ .toolbar-tooltip.rail-tooltip {
2950
+ position: fixed;
2951
+ right: auto;
2952
+ bottom: auto;
2953
+ min-width: 0;
2954
+ opacity: 1;
2955
+ transform: translateY(-50%);
2956
+ animation: rail-tooltip-in 0.14s ease both;
2957
+ }
2958
+ .toolbar-tooltip.rail-tooltip::after {
2959
+ left: -5px;
2960
+ top: 50%;
2961
+ border-top: none;
2962
+ border-right: none;
2963
+ border-bottom: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2964
+ border-left: 1px solid color-mix(in srgb, var(--c-line) 78%, var(--c-accent) 22%);
2965
+ transform: translateY(-50%) rotate(45deg);
2966
+ }
2967
+ @keyframes rail-tooltip-in {
2968
+ from {
2969
+ opacity: 0;
2970
+ transform: translateY(-50%) translateX(-4px);
2971
+ }
2972
+ to {
2973
+ opacity: 1;
2974
+ transform: translateY(-50%) translateX(0);
1032
2975
  }
1033
2976
  }
1034
2977
 
1035
- .toolbar-group {
2978
+ .toolbar-tooltip-body {
2979
+ font-size: 11.5px;
2980
+ line-height: 1.45;
2981
+ color: var(--c-text-soft);
2982
+ }
2983
+
2984
+ .toolbar-tooltip-label {
2985
+ font-size: 13px;
2986
+ font-weight: 600;
2987
+ letter-spacing: 0.01em;
2988
+ color: var(--c-text);
2989
+ }
2990
+
2991
+ .toolbar-tooltip-meta {
2992
+ display: flex;
2993
+ align-items: center;
2994
+ justify-content: space-between;
2995
+ gap: 10px;
2996
+ color: var(--c-text-soft);
2997
+ }
2998
+
2999
+ .toolbar-tooltip-shortcut {
3000
+ display: inline-flex;
3001
+ align-items: center;
3002
+ justify-content: center;
3003
+ min-height: 20px;
3004
+ padding: 2px 7px;
3005
+ border-radius: 999px;
3006
+ border: 1px solid var(--c-accent-25);
3007
+ background: var(--c-accent-10);
3008
+ color: var(--c-accent);
3009
+ font: 11px/1 var(--mono);
3010
+ white-space: nowrap;
3011
+ }
3012
+
3013
+ .connection-dot {
3014
+ width: 8px;
3015
+ height: 8px;
3016
+ border-radius: 50%;
3017
+ flex-shrink: 0;
3018
+ }
3019
+
3020
+ .connection-dot.connected {
3021
+ background: var(--c-ok);
3022
+ }
3023
+ .connection-dot.connecting {
3024
+ background: var(--c-warn);
3025
+ animation: pulse 1.5s infinite;
3026
+ }
3027
+ .connection-dot.disconnected {
3028
+ background: var(--c-danger);
3029
+ }
3030
+ .connection-dot.reconnecting {
3031
+ background: var(--c-warn);
3032
+ animation: pulse 1.5s infinite;
3033
+ }
3034
+ .connection-dot.resyncing {
3035
+ background: var(--c-accent);
3036
+ animation: pulse 1.5s infinite;
3037
+ }
3038
+
3039
+ /* Degraded-connection banner under the top bar (phase 7, item 14) */
3040
+ .connection-banner {
1036
3041
  display: flex;
1037
- flex-wrap: wrap;
1038
3042
  align-items: center;
1039
- gap: 6px;
3043
+ gap: 9px;
3044
+ padding: 7px 14px;
3045
+ flex-shrink: 0;
3046
+ border-bottom: 1px solid var(--c-line);
3047
+ font-size: 11.5px;
3048
+ }
3049
+ .connection-banner.is-reconnecting {
3050
+ background: color-mix(in srgb, var(--c-warn) 10%, transparent);
3051
+ border-bottom-color: color-mix(in srgb, var(--c-warn) 35%, transparent);
3052
+ color: var(--c-warn);
3053
+ }
3054
+ .connection-banner.is-resyncing {
3055
+ background: color-mix(in srgb, var(--c-accent) 8%, transparent);
3056
+ border-bottom-color: color-mix(in srgb, var(--c-accent) 30%, transparent);
3057
+ color: var(--c-accent);
3058
+ }
3059
+ .connection-banner-glyph {
3060
+ font-size: 13px;
3061
+ line-height: 1;
3062
+ }
3063
+ .connection-banner-text {
3064
+ flex: 1;
1040
3065
  min-width: 0;
1041
- max-width: 100%;
1042
3066
  }
3067
+ .connection-banner-meta {
3068
+ font: 9.5px var(--mono);
3069
+ color: var(--c-muted);
3070
+ }
3071
+ .connection-banner-progress {
3072
+ width: 90px;
3073
+ height: 4px;
3074
+ border-radius: 2px;
3075
+ background: var(--c-line);
3076
+ overflow: hidden;
3077
+ }
3078
+ .connection-banner-progress-fill {
3079
+ display: block;
3080
+ width: 40%;
3081
+ height: 100%;
3082
+ background: var(--c-accent);
3083
+ animation: connection-resync 1.1s ease-in-out infinite;
3084
+ }
3085
+ @keyframes connection-resync {
3086
+ from {
3087
+ transform: translateX(-100%);
3088
+ }
3089
+ to {
3090
+ transform: translateX(260%);
3091
+ }
3092
+ }
3093
+
3094
+ @keyframes pulse {
3095
+ 0%,
3096
+ 100% {
3097
+ opacity: 1;
3098
+ }
3099
+ 50% {
3100
+ opacity: 0.4;
3101
+ }
3102
+ }
3103
+
1043
3104
 
1044
3105
  /* Positioning parent for a toolbar popover menu. Every menu MUST live inside
1045
3106
  one of these wrapped around its trigger — anchoring to a wider ancestor
@@ -1049,16 +3110,15 @@ body,
1049
3110
  display: inline-flex;
1050
3111
  }
1051
3112
 
1052
- .canvas-toolbar button svg {
1053
- display: block;
1054
- }
1055
3113
 
1056
3114
  /* ── Toolbar popover menus (theme picker + narrow-screen More menu) ── */
1057
3115
  .toolbar-menu {
1058
3116
  position: absolute;
1059
3117
  top: calc(100% + 8px);
1060
3118
  right: 0;
1061
- z-index: 1200;
3119
+ /* Above the annotation capture layer (9996) — rail popovers overlap the
3120
+ canvas region and must stay clickable while an annotation tool is armed. */
3121
+ z-index: 9999;
1062
3122
  display: flex;
1063
3123
  flex-direction: column;
1064
3124
  gap: 2px;
@@ -1141,40 +3201,6 @@ body,
1141
3201
  border-radius: 50%;
1142
3202
  }
1143
3203
 
1144
- .toolbar-more-glyph {
1145
- display: block;
1146
- font-size: 16px;
1147
- font-weight: 700;
1148
- line-height: 1;
1149
- }
1150
-
1151
- /* Wide screens: the full two-bar toolbar; the More trigger stays hidden. */
1152
- .toolbar-collapsible {
1153
- display: contents;
1154
- }
1155
-
1156
- .toolbar-more {
1157
- display: none;
1158
- }
1159
-
1160
- /* Narrow screens / embedded panels: ONE compact bar (brand, status, view
1161
- controls) — every secondary control folds into the More menu instead of
1162
- wrapping into a second toolbar row. */
1163
- @media (max-width: 900px) {
1164
- .toolbar-collapsible {
1165
- display: none;
1166
- }
1167
-
1168
- .toolbar-actions-bar {
1169
- display: none;
1170
- }
1171
-
1172
- .toolbar-more {
1173
- /* inline-flex (NOT contents): this span is also the positioning anchor
1174
- for the More menu — display:contents cannot anchor absolute children. */
1175
- display: inline-flex;
1176
- }
1177
- }
1178
3204
 
1179
3205
  @media (max-width: 900px) {
1180
3206
  .toolbar-tooltip {
@@ -1193,16 +3219,39 @@ body,
1193
3219
  }
1194
3220
  }
1195
3221
 
1196
- /* Narrow embedding panels: drop low-value text from the HUD so the icon controls
1197
- fit in fewer rows. Buttons keep their aria-labels + tooltips, so nothing is
1198
- lost for a11y or discovery. */
1199
- @media (max-width: 720px) {
3222
+ /* Below 1180px the top bar drops its low-value meta text (board id, counts).
3223
+ Buttons keep their aria-labels + tooltips, so nothing is lost for a11y or
3224
+ discovery. */
3225
+ @media (max-width: 1180px) {
1200
3226
  .hud-collapsible-text {
1201
3227
  display: none;
1202
3228
  }
1203
3229
  }
1204
3230
 
1205
3231
  /* Raw markdown source editor */
3232
+ .md-edit-btn {
3233
+ position: absolute;
3234
+ top: 4px;
3235
+ right: 4px;
3236
+ padding: 3px 8px;
3237
+ font-size: 10px;
3238
+ background: var(--c-panel);
3239
+ border: 1px solid var(--c-line);
3240
+ border-radius: 4px;
3241
+ color: var(--c-text-soft);
3242
+ cursor: pointer;
3243
+ opacity: 0;
3244
+ transition: opacity 0.12s ease;
3245
+ }
3246
+ .canvas-node:hover .md-edit-btn,
3247
+ .md-edit-btn:focus-visible {
3248
+ opacity: 1;
3249
+ }
3250
+ .md-edit-btn:hover {
3251
+ color: var(--c-text);
3252
+ border-color: var(--c-accent-25);
3253
+ }
3254
+
1206
3255
  .md-editor-split {
1207
3256
  display: flex;
1208
3257
  height: 100%;
@@ -1736,6 +3785,10 @@ html.is-node-resizing .ext-app-preview-catcher {
1736
3785
  color: var(--c-accent);
1737
3786
  }
1738
3787
 
3788
+ .context-menu-item.is-danger .context-menu-label {
3789
+ color: var(--c-danger, #e5484d);
3790
+ }
3791
+
1739
3792
  .context-menu-shortcut {
1740
3793
  color: var(--c-muted);
1741
3794
  font-size: 10px;
@@ -1861,7 +3914,7 @@ html.is-node-resizing .ext-app-preview-catcher {
1861
3914
  constant screen size while zoomed out (see edgeChromeScale in EdgeLayer). */
1862
3915
  .edge-label {
1863
3916
  font-family: var(--font);
1864
- font-size: calc(11px * var(--edge-chrome-scale, 1));
3917
+ font-size: calc(11px * var(--edge-label-scale, 1));
1865
3918
  pointer-events: none;
1866
3919
  user-select: none;
1867
3920
  }
@@ -1869,7 +3922,7 @@ html.is-node-resizing .ext-app-preview-catcher {
1869
3922
  .edge-label-bg {
1870
3923
  fill: var(--c-panel-glass);
1871
3924
  stroke: var(--c-line);
1872
- stroke-width: calc(0.5 * var(--edge-chrome-scale, 1));
3925
+ stroke-width: calc(0.5 * var(--edge-label-scale, 1));
1873
3926
  }
1874
3927
 
1875
3928
  /* Trace nodes — compact pills for agent tool/subagent visualization */
@@ -2061,112 +4114,6 @@ html.is-node-resizing .ext-app-preview-catcher {
2061
4114
  color: var(--c-accent);
2062
4115
  }
2063
4116
 
2064
- /* Docked node — compact toolbar-flanking panel */
2065
- .docked-node {
2066
- min-width: 200px;
2067
- max-width: 360px;
2068
- background: var(--c-panel-glass);
2069
- backdrop-filter: blur(16px);
2070
- border: 1px solid var(--c-line);
2071
- border-radius: var(--radius);
2072
- box-shadow: 0 12px 40px var(--c-shadow-heavy), 0 0 0 1px rgba(255, 255, 255, 0.04);
2073
- display: flex;
2074
- flex-direction: column;
2075
- overflow: hidden;
2076
- }
2077
-
2078
- .docked-node:has(.context-body) {
2079
- width: 320px;
2080
- max-width: 320px;
2081
- }
2082
-
2083
- /* Collapsed docked widget = a single menu-height pill that flanks the toolbar.
2084
- Pinned to the same height as .canvas-toolbar so the top HUD row reads as one
2085
- continuous bar (status on the left, context on the right). */
2086
- .docked-node--collapsed {
2087
- height: var(--hud-bar-height);
2088
- box-sizing: border-box;
2089
- justify-content: center;
2090
- width: auto;
2091
- /* Reset the base .docked-node min-width so the collapsed pill hugs its content
2092
- (badge + count + controls) instead of stretching to a 200px bar. */
2093
- min-width: 0;
2094
- }
2095
- .docked-node--collapsed .docked-node-header {
2096
- height: 100%;
2097
- padding: 0 10px;
2098
- border-bottom: none;
2099
- }
2100
- .docked-node-count {
2101
- min-width: 18px;
2102
- height: 18px;
2103
- padding: 0 5px;
2104
- display: inline-flex;
2105
- align-items: center;
2106
- justify-content: center;
2107
- border-radius: 9px;
2108
- background: var(--c-accent);
2109
- color: var(--c-contrast-fg);
2110
- font-size: 10px;
2111
- font-weight: 700;
2112
- flex-shrink: 0;
2113
- }
2114
-
2115
- .docked-node-header {
2116
- display: flex;
2117
- align-items: center;
2118
- gap: 6px;
2119
- padding: 6px 10px;
2120
- border-bottom: 1px solid var(--c-line);
2121
- user-select: none;
2122
- flex-shrink: 0;
2123
- }
2124
-
2125
- .docked-node-header .node-type-badge {
2126
- font-size: 10px;
2127
- padding: 1px 6px;
2128
- border-radius: 4px;
2129
- background: var(--c-accent-12);
2130
- color: var(--c-accent);
2131
- text-transform: uppercase;
2132
- letter-spacing: 0.04em;
2133
- flex-shrink: 0;
2134
- }
2135
-
2136
- .docked-node-controls {
2137
- display: flex;
2138
- gap: 4px;
2139
- margin-left: auto;
2140
- flex-shrink: 0;
2141
- }
2142
-
2143
- .docked-node-controls button {
2144
- background: none;
2145
- border: none;
2146
- color: var(--c-muted);
2147
- cursor: pointer;
2148
- padding: 2px 4px;
2149
- font-size: 14px;
2150
- line-height: 1;
2151
- border-radius: 3px;
2152
- }
2153
-
2154
- .docked-node-controls button:hover {
2155
- background: var(--c-surface-hover);
2156
- color: var(--c-text);
2157
- }
2158
-
2159
- .docked-node-body {
2160
- padding: 8px 10px;
2161
- max-height: 200px;
2162
- overflow-y: auto;
2163
- }
2164
-
2165
- .docked-node-body.context-body {
2166
- max-height: 420px;
2167
- padding: 10px 14px;
2168
- }
2169
-
2170
4117
  /* MCP app iframe */
2171
4118
  .mcp-app-frame {
2172
4119
  width: 100%;
@@ -2222,10 +4169,36 @@ html.is-node-resizing .ext-app-preview-catcher {
2222
4169
  }
2223
4170
  }
2224
4171
 
2225
- /* ── Multi-node selection ─────────────────────────────────── */
4172
+ /* ── Multi-node selection (item 13: outline, corner handles, soft glow) ── */
2226
4173
  .canvas-node.selected {
2227
4174
  border-color: var(--c-accent);
2228
- box-shadow: 0 0 0 2px var(--c-accent), 0 6px 32px var(--c-accent-25);
4175
+ box-shadow: 0 0 0 1px var(--c-accent), 0 0 0 4px color-mix(in srgb, var(--c-accent) 10%, transparent);
4176
+ }
4177
+ .node-selection-handle {
4178
+ position: absolute;
4179
+ width: 7px;
4180
+ height: 7px;
4181
+ background: var(--c-bg);
4182
+ border: 1.5px solid var(--c-accent);
4183
+ border-radius: 2px;
4184
+ pointer-events: none;
4185
+ z-index: 3;
4186
+ }
4187
+ .node-selection-handle.is-tl {
4188
+ left: -4px;
4189
+ top: -4px;
4190
+ }
4191
+ .node-selection-handle.is-tr {
4192
+ right: -4px;
4193
+ top: -4px;
4194
+ }
4195
+ .node-selection-handle.is-bl {
4196
+ left: -4px;
4197
+ bottom: -4px;
4198
+ }
4199
+ .node-selection-handle.is-br {
4200
+ right: -4px;
4201
+ bottom: -4px;
2229
4202
  }
2230
4203
 
2231
4204
  /* Lasso rectangle overlay */
@@ -2343,83 +4316,147 @@ html.is-node-resizing .ext-app-preview-catcher {
2343
4316
  z-index: 9999;
2344
4317
  }
2345
4318
 
2346
- /* Selection action bar — fixed bottom-center */
4319
+ /* In-canvas text prompt (window.prompt replacement — embedded panes no-op it). */
4320
+ .text-prompt-backdrop {
4321
+ position: absolute;
4322
+ inset: 0;
4323
+ display: flex;
4324
+ align-items: flex-start;
4325
+ justify-content: center;
4326
+ padding-top: 18vh;
4327
+ background: color-mix(in srgb, var(--c-bg) 42%, transparent);
4328
+ z-index: 10015;
4329
+ }
4330
+ .text-prompt {
4331
+ width: min(440px, calc(100% - 48px));
4332
+ padding: 14px;
4333
+ background: var(--c-panel);
4334
+ border: 1px solid var(--c-line);
4335
+ border-radius: 12px;
4336
+ box-shadow: 0 18px 60px var(--c-shadow-heavy);
4337
+ display: flex;
4338
+ flex-direction: column;
4339
+ gap: 10px;
4340
+ }
4341
+ .text-prompt-title {
4342
+ font-size: 13px;
4343
+ font-weight: 600;
4344
+ color: var(--c-text);
4345
+ }
4346
+ .text-prompt-input {
4347
+ width: 100%;
4348
+ padding: 8px 10px;
4349
+ border: 1px solid var(--c-line);
4350
+ border-radius: 8px;
4351
+ background: var(--c-bg);
4352
+ color: var(--c-text);
4353
+ font: 13px/1.4 var(--mono);
4354
+ }
4355
+ .text-prompt-input:focus {
4356
+ outline: none;
4357
+ border-color: var(--c-accent);
4358
+ }
4359
+ .text-prompt-actions {
4360
+ display: flex;
4361
+ justify-content: flex-end;
4362
+ gap: 8px;
4363
+ }
4364
+ .text-prompt-cancel,
4365
+ .text-prompt-confirm {
4366
+ padding: 5px 12px;
4367
+ border-radius: 7px;
4368
+ border: 1px solid var(--c-line);
4369
+ background: none;
4370
+ color: var(--c-text-soft);
4371
+ cursor: pointer;
4372
+ font-size: 12px;
4373
+ }
4374
+ .text-prompt-confirm {
4375
+ background: var(--c-accent);
4376
+ border-color: var(--c-accent);
4377
+ color: var(--c-bg);
4378
+ font-weight: 600;
4379
+ }
4380
+
4381
+ /* Selection action bar — floating bottom-center of the canvas region
4382
+ (rail-chrome-v2 phase 7, item 13). */
4383
+ /* In a session the command bar owns the bottom-center slot — lift the
4384
+ selection bar clear of it (composer + chips row); on the quiet board the
4385
+ pin bar does, so lift past that instead. */
4386
+ [data-session-active='true'] .selection-bar {
4387
+ bottom: 124px;
4388
+ }
4389
+ .selection-bar.is-above-pin-bar {
4390
+ bottom: 70px;
4391
+ }
2347
4392
  .selection-bar {
2348
- position: fixed;
2349
- bottom: 60px;
4393
+ position: absolute;
4394
+ bottom: 18px;
2350
4395
  left: 50%;
2351
4396
  transform: translateX(-50%);
2352
4397
  display: flex;
2353
4398
  align-items: center;
2354
- gap: 8px;
2355
- padding: 8px 14px;
2356
- background: var(--c-panel-glass);
2357
- backdrop-filter: blur(12px);
2358
- border: 1px solid var(--c-accent);
2359
- border-radius: var(--radius);
2360
- box-shadow: 0 8px 32px var(--c-shadow), 0 0 0 1px var(--c-accent-15);
2361
- z-index: 10001;
4399
+ gap: 2px;
4400
+ padding: 6px 8px;
4401
+ background: color-mix(in srgb, var(--c-panel) 97%, transparent);
4402
+ backdrop-filter: blur(12px);
4403
+ border: 1px solid var(--c-line);
4404
+ border-radius: 10px;
4405
+ box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
4406
+ z-index: 66;
2362
4407
  white-space: nowrap;
2363
4408
  }
2364
-
2365
4409
  .selection-bar-count {
2366
- font-size: 12px;
2367
- font-weight: 600;
2368
- color: var(--c-accent);
2369
- }
2370
-
2371
- .selection-bar-btn {
2372
- padding: 5px 12px;
2373
- font-size: 12px;
4410
+ padding: 0 8px;
4411
+ font-size: 11px;
2374
4412
  font-weight: 600;
2375
- background: var(--c-accent-10);
2376
- border: 1px solid var(--c-accent-30);
2377
- border-radius: var(--radius-sm);
2378
4413
  color: var(--c-accent);
2379
- cursor: pointer;
2380
- font-family: var(--font);
2381
- }
2382
-
2383
- .selection-bar-btn:hover {
2384
- background: var(--c-accent-25);
2385
- border-color: var(--c-accent);
2386
- }
2387
-
2388
- .selection-bar-ask {
2389
- background: var(--c-accent);
2390
- color: var(--c-contrast-fg);
2391
- border-color: var(--c-accent);
2392
4414
  }
2393
-
2394
- .selection-bar-ask:hover {
2395
- background: var(--c-accent-hover);
2396
- border-color: var(--c-accent-hover);
4415
+ .selection-bar-sep {
4416
+ width: 1px;
4417
+ height: 18px;
4418
+ margin: 0 4px;
4419
+ background: var(--c-line);
2397
4420
  }
2398
-
2399
- .selection-bar-clear {
2400
- background: none;
4421
+ .selection-bar-icon,
4422
+ .selection-bar-action {
4423
+ display: inline-flex;
4424
+ align-items: center;
4425
+ justify-content: center;
4426
+ gap: 5px;
4427
+ height: 28px;
2401
4428
  border: none;
4429
+ border-radius: 6px;
4430
+ background: none;
2402
4431
  color: var(--c-muted);
2403
- font-size: 16px;
2404
- padding: 2px 6px;
2405
- line-height: 1;
4432
+ cursor: pointer;
4433
+ font: inherit;
4434
+ font-size: 11px;
4435
+ font-weight: 600;
2406
4436
  }
2407
-
2408
- .selection-bar-clear:hover {
4437
+ .selection-bar-icon {
4438
+ width: 28px;
4439
+ font-size: 14px;
4440
+ }
4441
+ .selection-bar-action {
4442
+ padding: 0 9px;
4443
+ }
4444
+ .selection-bar-icon:hover,
4445
+ .selection-bar-action:hover {
4446
+ background: color-mix(in srgb, var(--c-text) 6%, transparent);
2409
4447
  color: var(--c-text);
2410
- background: var(--c-surface-hover);
2411
4448
  }
2412
-
2413
- /* "Pin as context" button in selection bar */
2414
- .selection-bar-pin-ctx {
2415
- background: var(--c-warn-12);
2416
- border-color: var(--c-warn-30);
4449
+ .selection-bar-icon:disabled {
4450
+ opacity: 0.35;
4451
+ cursor: default;
4452
+ }
4453
+ .selection-bar-action.is-pin:hover {
4454
+ background: color-mix(in srgb, var(--c-warn) 10%, transparent);
2417
4455
  color: var(--c-warn);
2418
4456
  }
2419
-
2420
- .selection-bar-pin-ctx:hover {
2421
- background: var(--c-warn-22);
2422
- border-color: var(--c-warn);
4457
+ .selection-bar-icon.is-danger:hover {
4458
+ background: color-mix(in srgb, var(--c-danger) 12%, transparent);
4459
+ color: var(--c-danger);
2423
4460
  }
2424
4461
 
2425
4462
  /* ── Context-pinned nodes — amber glow ───────────────────────── */
@@ -2589,11 +4626,13 @@ html.is-node-resizing .ext-app-preview-catcher {
2589
4626
  box-shadow: 0 0 24px rgba(75, 188, 255, 0.12);
2590
4627
  }
2591
4628
 
4629
+ /* Anchored to the canvas region (not the window): since the rail-chrome
4630
+ restructure the session panel owns the window's right edge. */
2592
4631
  .attention-toast {
2593
- position: fixed;
2594
- top: 76px;
4632
+ position: absolute;
4633
+ top: 18px;
2595
4634
  right: 18px;
2596
- max-width: min(260px, calc(100vw - 24px));
4635
+ max-width: min(260px, calc(100% - 24px));
2597
4636
  display: inline-flex;
2598
4637
  align-items: center;
2599
4638
  gap: 8px;
@@ -2606,7 +4645,7 @@ html.is-node-resizing .ext-app-preview-catcher {
2606
4645
  color: var(--c-text);
2607
4646
  font: inherit;
2608
4647
  cursor: pointer;
2609
- z-index: 10003;
4648
+ z-index: 9990; /* above the world, below the rail popovers and every modal overlay */
2610
4649
  animation: attention-toast-in 180ms ease-out;
2611
4650
  }
2612
4651
 
@@ -2651,96 +4690,11 @@ html.is-node-resizing .ext-app-preview-catcher {
2651
4690
  max-width: 200px;
2652
4691
  }
2653
4692
 
2654
- /* Context dock — expanded panel anchored top-right edge.
2655
- Mutually exclusive with the Updates panel (see DockedNode.tsx and
2656
- AttentionHistory.tsx) — opening one collapses the other, so they can both
2657
- share the same right: 18px anchor without overlapping. */
2658
- .context-dock-panel {
2659
- position: fixed;
2660
- top: 92px;
2661
- right: 18px;
2662
- width: min(360px, calc(100vw - 24px));
2663
- max-height: calc(100vh - 110px);
2664
- display: flex;
2665
- flex-direction: column;
2666
- gap: 10px;
2667
- padding: 14px;
2668
- background: color-mix(in srgb, var(--c-panel-glass) 96%, transparent);
2669
- backdrop-filter: blur(16px);
2670
- border: 1px solid color-mix(in srgb, var(--c-line) 82%, var(--c-accent) 18%);
2671
- border-radius: 18px;
2672
- box-shadow: 0 14px 36px var(--c-shadow), 0 0 0 1px color-mix(in srgb, var(--c-accent) 8%, transparent);
2673
- z-index: 10001;
2674
- overflow: hidden;
2675
- }
2676
-
2677
- .context-dock-header {
2678
- display: flex;
2679
- align-items: flex-start;
2680
- justify-content: space-between;
2681
- gap: 8px;
2682
- padding: 2px 2px 4px;
2683
- flex-shrink: 0;
2684
- }
2685
-
2686
- .context-dock-header-text {
2687
- display: flex;
2688
- flex-direction: column;
2689
- gap: 2px;
2690
- min-width: 0;
2691
- }
2692
-
2693
- .context-dock-title {
2694
- font-size: 12px;
2695
- font-weight: 700;
2696
- letter-spacing: 0.08em;
2697
- text-transform: uppercase;
2698
- color: var(--c-text);
2699
- }
2700
-
2701
- .context-dock-subtitle {
2702
- font-size: 11px;
2703
- color: var(--c-dim);
2704
- }
2705
-
2706
- .context-dock-controls {
2707
- display: flex;
2708
- gap: 4px;
2709
- flex-shrink: 0;
2710
- }
2711
-
2712
- .context-dock-icon-button {
2713
- width: 22px;
2714
- height: 22px;
2715
- border: 0;
2716
- border-radius: 6px;
2717
- background: transparent;
2718
- color: var(--c-dim);
2719
- font-size: 16px;
2720
- line-height: 1;
2721
- cursor: pointer;
2722
- display: grid;
2723
- place-items: center;
2724
- padding: 0;
2725
- }
2726
-
2727
- .context-dock-icon-button:hover {
2728
- color: var(--c-text);
2729
- background: var(--c-surface-hover);
2730
- }
2731
-
2732
- .context-dock-body {
2733
- flex: 1 1 auto;
2734
- min-height: 0;
2735
- overflow-y: auto;
2736
- padding-right: 2px;
2737
- }
2738
-
2739
4693
  .attention-history {
2740
- position: fixed;
2741
- top: 146px;
4694
+ position: absolute;
4695
+ top: 60px;
2742
4696
  right: 18px;
2743
- width: min(320px, calc(100vw - 24px));
4697
+ width: min(320px, calc(100% - 24px));
2744
4698
  display: flex;
2745
4699
  flex-direction: column;
2746
4700
  gap: 10px;
@@ -2750,12 +4704,12 @@ html.is-node-resizing .ext-app-preview-catcher {
2750
4704
  border: 1px solid color-mix(in srgb, var(--c-line) 82%, var(--c-warn) 18%);
2751
4705
  border-radius: 18px;
2752
4706
  box-shadow: 0 14px 36px var(--c-shadow), 0 0 0 1px color-mix(in srgb, var(--c-warn) 8%, transparent);
2753
- z-index: 10002;
4707
+ z-index: 9990;
2754
4708
  }
2755
4709
 
2756
4710
  .attention-history-tab {
2757
- position: fixed;
2758
- top: 146px;
4711
+ position: absolute;
4712
+ top: 60px;
2759
4713
  right: 0;
2760
4714
  display: flex;
2761
4715
  align-items: center;
@@ -2967,82 +4921,265 @@ html.is-node-resizing .ext-app-preview-catcher {
2967
4921
  color: color-mix(in srgb, var(--c-danger) 78%, var(--c-text) 22%);
2968
4922
  }
2969
4923
 
2970
- /* ── Group node — spatial container/frame ─────────────────────── */
4924
+ /* ── Group node — spatial container/frame (groups v2, item 20) ─────
4925
+ Dashed frame with the name pill + action cluster ON the top edge; the
4926
+ children live in the world layer. The frame brightens while a dragged node
4927
+ would join on release; a collapsed group is a compact chip. */
2971
4928
  .canvas-node.group-node {
2972
- background: transparent;
2973
- border: 2px dashed var(--group-color, var(--c-accent));
2974
- border-radius: 12px;
4929
+ background: color-mix(in srgb, var(--group-color, var(--c-accent)) 3%, transparent);
4930
+ border: 1.5px dashed color-mix(in srgb, var(--group-color, var(--c-accent)) 35%, transparent);
4931
+ border-radius: 14px;
2975
4932
  box-shadow: none;
2976
4933
  overflow: visible;
4934
+ /* The edge row hangs outside the frame: no paint containment here. */
4935
+ contain: layout style;
2977
4936
  min-width: 200px;
2978
4937
  min-height: 120px;
4938
+ transition:
4939
+ border-color 150ms ease,
4940
+ background 150ms ease;
2979
4941
  }
2980
-
2981
- .canvas-node.group-node .node-titlebar {
2982
- background: color-mix(in srgb, var(--group-color, var(--c-accent)) 12%, transparent);
2983
- border-bottom: 1px solid color-mix(in srgb, var(--group-color, var(--c-accent)) 25%, transparent);
2984
- border-radius: 10px 10px 0 0;
4942
+ .canvas-node.group-node:hover {
4943
+ border-color: color-mix(in srgb, var(--group-color, var(--c-accent)) 55%, transparent);
2985
4944
  }
2986
-
2987
- .canvas-node.group-node .node-type-badge {
2988
- background: color-mix(in srgb, var(--group-color, var(--c-accent)) 20%, transparent);
2989
- color: var(--group-color, var(--c-accent));
4945
+ .canvas-node.group-node.active,
4946
+ .canvas-node.group-node.selected {
4947
+ border-style: dashed;
4948
+ border-color: color-mix(in srgb, var(--group-color, var(--c-accent)) 70%, transparent);
4949
+ }
4950
+ .canvas-node.group-node.is-drop-target {
4951
+ border-color: color-mix(in srgb, var(--group-color, var(--c-accent)) 80%, transparent);
4952
+ background: color-mix(in srgb, var(--group-color, var(--c-accent)) 9%, transparent);
4953
+ }
4954
+ .canvas-node.group-node.is-drop-source {
4955
+ border-color: color-mix(in srgb, var(--c-warn) 60%, transparent);
2990
4956
  }
2991
-
2992
4957
  .canvas-node.group-node .node-body {
2993
- background: color-mix(in srgb, var(--group-color, var(--c-accent)) 4%, transparent);
2994
- padding: 12px;
4958
+ background: none;
4959
+ padding: 0;
4960
+ display: flex;
4961
+ align-items: center;
4962
+ justify-content: center;
2995
4963
  }
2996
-
2997
- .canvas-node.group-node:hover {
2998
- border-style: solid;
2999
- box-shadow: 0 0 0 1px color-mix(in srgb, var(--group-color, var(--c-accent)) 30%, transparent);
4964
+ .group-empty-hint {
4965
+ font-size: 11px;
4966
+ color: var(--c-dim);
4967
+ font-style: italic;
4968
+ text-align: center;
4969
+ padding: 12px 18px;
4970
+ opacity: 0.8;
4971
+ pointer-events: none;
3000
4972
  }
3001
4973
 
3002
- .canvas-node.group-node.active {
3003
- border-style: solid;
3004
- border-color: var(--group-color, var(--c-accent));
3005
- box-shadow: 0 0 0 2px color-mix(in srgb, var(--group-color, var(--c-accent)) 40%, transparent);
4974
+ /* Frame edge row: the drag handle for the whole group */
4975
+ .canvas-node.group-node .node-titlebar.group-edge-row {
4976
+ position: absolute;
4977
+ top: -12px;
4978
+ left: 12px;
4979
+ right: 12px;
4980
+ height: 24px;
4981
+ padding: 0;
4982
+ display: flex;
4983
+ align-items: center;
4984
+ gap: 6px;
4985
+ background: none;
4986
+ border: none;
4987
+ border-radius: 0;
4988
+ cursor: grab;
4989
+ overflow: visible;
4990
+ }
4991
+ .group-name-pill {
4992
+ display: inline-flex;
4993
+ align-items: center;
4994
+ gap: 6px;
4995
+ padding: 2px 10px;
4996
+ border-radius: 999px;
4997
+ background: var(--c-panel-soft);
4998
+ border: 1px solid color-mix(in srgb, var(--group-color, var(--c-accent)) 35%, transparent);
4999
+ max-width: 70%;
5000
+ }
5001
+ .group-name {
5002
+ font-size: 10px;
5003
+ font-weight: 700;
5004
+ letter-spacing: 0.08em;
5005
+ text-transform: uppercase;
5006
+ color: var(--group-color, var(--c-accent));
5007
+ white-space: nowrap;
5008
+ overflow: hidden;
5009
+ text-overflow: ellipsis;
5010
+ }
5011
+ .group-count {
5012
+ font: 9px var(--mono);
5013
+ color: var(--c-dim);
5014
+ }
5015
+ .group-title-input {
5016
+ width: 140px;
5017
+ font-size: 11px;
5018
+ }
5019
+ .group-edge-spacer {
5020
+ flex: 1;
5021
+ }
5022
+ .group-actions {
5023
+ position: relative;
5024
+ display: inline-flex;
5025
+ gap: 1px;
5026
+ padding: 2px 4px;
5027
+ border-radius: 999px;
5028
+ background: var(--c-panel-soft);
5029
+ border: 1px solid var(--c-line);
5030
+ }
5031
+ .group-action {
5032
+ display: inline-flex;
5033
+ width: 20px;
5034
+ height: 20px;
5035
+ align-items: center;
5036
+ justify-content: center;
5037
+ background: none;
5038
+ border: none;
5039
+ border-radius: 99px;
5040
+ color: var(--c-muted);
5041
+ cursor: pointer;
5042
+ font-size: 11px;
5043
+ line-height: 1;
5044
+ padding: 0;
5045
+ }
5046
+ .group-action:hover:not(:disabled) {
5047
+ color: var(--group-color, var(--c-accent));
5048
+ }
5049
+ .group-action:disabled {
5050
+ opacity: 0.35;
5051
+ cursor: default;
5052
+ }
5053
+ /* A group stacks BELOW its children by design (bringToFront re-stacks members
5054
+ above the frame), so the frame's own popover would paint under the member
5055
+ cards. While the ⋯ menu is open, lift the whole frame — !important because
5056
+ the node's z-index is an inline style from the store. */
5057
+ .canvas-node.group-menu-open {
5058
+ z-index: 9500 !important;
3006
5059
  }
3007
5060
 
3008
- .group-node-body {
5061
+ .group-menu {
5062
+ position: absolute;
5063
+ top: 26px;
5064
+ right: 0;
5065
+ min-width: 160px;
3009
5066
  display: flex;
3010
5067
  flex-direction: column;
3011
- gap: 8px;
3012
- height: 100%;
5068
+ padding: 4px;
5069
+ background: var(--c-panel);
5070
+ border: 1px solid var(--c-line);
5071
+ border-radius: 8px;
5072
+ box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
5073
+ z-index: 20;
5074
+ }
5075
+ .group-menu button {
5076
+ padding: 6px 10px;
5077
+ border: none;
5078
+ border-radius: 6px;
5079
+ background: none;
5080
+ color: var(--c-text-soft);
5081
+ font: inherit;
5082
+ font-size: 11px;
5083
+ text-align: left;
5084
+ cursor: pointer;
5085
+ }
5086
+ .group-menu button:hover:not(:disabled) {
5087
+ background: color-mix(in srgb, var(--c-text) 6%, transparent);
5088
+ color: var(--c-text);
5089
+ }
5090
+ .group-menu button:disabled {
5091
+ opacity: 0.4;
5092
+ cursor: default;
5093
+ }
5094
+ .group-menu button.is-danger:hover {
5095
+ color: var(--c-danger);
5096
+ }
5097
+
5098
+ /* Collapsed group chip */
5099
+ .canvas-node.group-node.group-chip {
5100
+ min-width: 0;
5101
+ min-height: 0;
5102
+ padding: 0;
5103
+ background: color-mix(in srgb, var(--group-color, var(--c-accent)) 4%, transparent);
5104
+ border: 1.5px dashed color-mix(in srgb, var(--group-color, var(--c-accent)) 35%, transparent);
5105
+ border-radius: 12px;
5106
+ cursor: pointer;
5107
+ }
5108
+ .canvas-node.group-node.group-chip:hover {
5109
+ border-color: color-mix(in srgb, var(--group-color, var(--c-accent)) 60%, transparent);
5110
+ background: color-mix(in srgb, var(--group-color, var(--c-accent)) 8%, transparent);
3013
5111
  }
3014
-
3015
- .group-summary {
5112
+ .canvas-node.group-node .node-titlebar.group-chip-inner {
3016
5113
  display: flex;
3017
5114
  align-items: center;
3018
5115
  gap: 10px;
3019
- flex-wrap: wrap;
5116
+ padding: 10px 14px;
5117
+ background: none;
5118
+ border: none;
5119
+ cursor: grab;
3020
5120
  }
3021
-
3022
- .group-child-count {
5121
+ .group-chip-expand {
5122
+ background: none;
5123
+ border: none;
5124
+ padding: 0;
5125
+ color: var(--group-color, var(--c-accent));
3023
5126
  font-size: 13px;
3024
- font-weight: 600;
5127
+ line-height: 1;
5128
+ cursor: pointer;
5129
+ }
5130
+ .group-chip-name {
5131
+ font-size: 10px;
5132
+ font-weight: 700;
5133
+ letter-spacing: 0.08em;
5134
+ text-transform: uppercase;
3025
5135
  color: var(--group-color, var(--c-accent));
5136
+ white-space: nowrap;
3026
5137
  }
3027
-
3028
- .group-type-summary {
3029
- font-size: 12px;
3030
- color: var(--c-text-muted);
5138
+ .group-chip-meta {
5139
+ display: flex;
5140
+ align-items: center;
5141
+ gap: 5px;
5142
+ margin-top: 4px;
5143
+ }
5144
+ .group-kind-dot {
5145
+ width: 6px;
5146
+ height: 6px;
5147
+ border-radius: 2px;
5148
+ opacity: 0.8;
5149
+ }
5150
+ .group-chip-count {
5151
+ font: 9px var(--mono);
5152
+ color: var(--c-dim);
3031
5153
  }
3032
5154
 
3033
- .group-empty-hint {
3034
- font-size: 12px;
3035
- color: var(--c-text-muted);
3036
- font-style: italic;
3037
- padding: 12px 0;
3038
- text-align: center;
3039
- opacity: 0.7;
5155
+ /* Release pill under the dragged node */
5156
+ .drop-pill {
5157
+ position: absolute;
5158
+ z-index: 10000;
5159
+ display: inline-flex;
5160
+ align-items: center;
5161
+ gap: 6px;
5162
+ padding: 3px 10px;
5163
+ border-radius: 999px;
5164
+ background: color-mix(in srgb, var(--c-panel) 96%, transparent);
5165
+ border: 1px solid color-mix(in srgb, var(--c-accent) 40%, transparent);
5166
+ pointer-events: none;
5167
+ white-space: nowrap;
5168
+ }
5169
+ .drop-pill-text {
5170
+ font-size: 10px;
5171
+ font-weight: 600;
5172
+ color: var(--c-accent);
5173
+ }
5174
+ .drop-pill-hint {
5175
+ font: 9px var(--mono);
5176
+ color: var(--c-dim);
3040
5177
  }
3041
5178
 
3042
5179
  /* ── Context pin bar — persistent floating indicator ─────────── */
3043
5180
  .context-pin-bar {
3044
- position: fixed;
3045
- bottom: 20px;
5181
+ position: absolute;
5182
+ bottom: 18px;
3046
5183
  left: 50%;
3047
5184
  transform: translateX(-50%);
3048
5185
  display: flex;
@@ -3054,7 +5191,7 @@ html.is-node-resizing .ext-app-preview-catcher {
3054
5191
  border: 1px solid var(--c-warn);
3055
5192
  border-radius: var(--radius);
3056
5193
  box-shadow: 0 8px 32px var(--c-shadow), 0 0 0 1px var(--c-warn-15);
3057
- z-index: 10000;
5194
+ z-index: 64;
3058
5195
  white-space: nowrap;
3059
5196
  }
3060
5197
 
@@ -3107,6 +5244,114 @@ html.is-node-resizing .ext-app-preview-catcher {
3107
5244
  }
3108
5245
 
3109
5246
  /* ── Expanded overlay actions ────────────────────────────────── */
5247
+ /* Expanded node view (rail-chrome-v2 phase 7, item 16): scrim + inset panel
5248
+ with 36/48px margins, header with kind pill + pin state, footer strip. */
5249
+ .expanded-overlay-backdrop {
5250
+ position: absolute;
5251
+ inset: 0;
5252
+ z-index: 10001;
5253
+ background: rgba(4, 10, 18, 0.6);
5254
+ display: flex;
5255
+ align-items: stretch;
5256
+ justify-content: center;
5257
+ padding: 36px 48px;
5258
+ }
5259
+ .expanded-overlay-panel {
5260
+ flex: 1;
5261
+ max-width: 1400px;
5262
+ display: flex;
5263
+ flex-direction: column;
5264
+ background: var(--c-panel);
5265
+ border: 1px solid var(--c-line);
5266
+ border-radius: 14px;
5267
+ box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
5268
+ overflow: hidden;
5269
+ }
5270
+ .expanded-overlay-panel.is-pinned {
5271
+ border-color: color-mix(in srgb, var(--c-warn) 45%, var(--c-line));
5272
+ }
5273
+ .expanded-header {
5274
+ display: flex;
5275
+ align-items: center;
5276
+ gap: 10px;
5277
+ height: 46px;
5278
+ padding: 0 16px;
5279
+ border-bottom: 1px solid var(--c-line);
5280
+ background: color-mix(in srgb, var(--c-bg) 60%, transparent);
5281
+ flex-shrink: 0;
5282
+ }
5283
+ .expanded-kind-icon {
5284
+ display: inline-flex;
5285
+ color: var(--c-accent);
5286
+ }
5287
+ .expanded-title {
5288
+ font-size: 13px;
5289
+ font-weight: 600;
5290
+ color: var(--c-text);
5291
+ white-space: nowrap;
5292
+ overflow: hidden;
5293
+ text-overflow: ellipsis;
5294
+ min-width: 0;
5295
+ }
5296
+ .expanded-kind-pill {
5297
+ font-size: 9px;
5298
+ font-weight: 600;
5299
+ padding: 2px 8px;
5300
+ border-radius: 999px;
5301
+ border: 1px solid var(--c-line);
5302
+ color: var(--c-muted);
5303
+ white-space: nowrap;
5304
+ }
5305
+ .expanded-pin {
5306
+ background: none;
5307
+ border: none;
5308
+ padding: 0 2px;
5309
+ font-size: 12px;
5310
+ color: var(--c-dim);
5311
+ cursor: pointer;
5312
+ }
5313
+ .expanded-pin.is-on {
5314
+ color: var(--c-warn);
5315
+ }
5316
+ .expanded-spacer {
5317
+ flex: 1;
5318
+ }
5319
+ .expanded-close {
5320
+ background: none;
5321
+ border: none;
5322
+ color: var(--c-muted);
5323
+ font-size: 16px;
5324
+ line-height: 1;
5325
+ cursor: pointer;
5326
+ padding: 0 4px;
5327
+ }
5328
+ .expanded-close:hover {
5329
+ color: var(--c-text);
5330
+ }
5331
+ .expanded-body {
5332
+ flex: 1;
5333
+ min-height: 0;
5334
+ overflow: auto;
5335
+ padding: 16px;
5336
+ }
5337
+ .expanded-body.is-embedded {
5338
+ display: flex;
5339
+ flex-direction: column;
5340
+ }
5341
+ .expanded-footer {
5342
+ display: flex;
5343
+ align-items: center;
5344
+ gap: 12px;
5345
+ padding: 8px 16px;
5346
+ border-top: 1px solid var(--c-line);
5347
+ background: color-mix(in srgb, var(--c-bg) 50%, transparent);
5348
+ font: 9.5px var(--mono);
5349
+ color: var(--c-dim);
5350
+ flex-shrink: 0;
5351
+ }
5352
+ .expanded-footer-hint.is-saving {
5353
+ color: var(--c-warn);
5354
+ }
3110
5355
  .expanded-actions {
3111
5356
  display: flex;
3112
5357
  align-items: center;
@@ -3369,51 +5614,60 @@ html.is-node-resizing .ext-app-preview-catcher {
3369
5614
 
3370
5615
  /* ── Snapshot Panel ───────────────────────────────────────── */
3371
5616
 
5617
+ /* History drawer (rail-chrome-v2 phase 7, item 8): snapshots + sessions as
5618
+ one reverse-chronological list in a right drawer of the canvas region. */
3372
5619
  .snapshot-panel {
3373
- position: fixed;
3374
- width: 320px;
3375
- max-height: 420px;
5620
+ position: absolute;
5621
+ top: 0;
5622
+ right: 0;
5623
+ bottom: 0;
5624
+ width: min(300px, 100%);
3376
5625
  display: flex;
3377
5626
  flex-direction: column;
3378
- background: var(--c-panel-glass);
3379
- backdrop-filter: blur(16px);
3380
- border: 1px solid var(--c-line);
3381
- border-radius: var(--radius);
3382
- box-shadow: 0 12px 40px var(--c-shadow-heavy), 0 0 0 1px rgba(255,255,255,0.04);
3383
- z-index: 10001;
5627
+ background: var(--c-panel-soft);
5628
+ border-left: 1px solid var(--c-line);
5629
+ box-shadow: -16px 0 40px rgba(0, 0, 0, 0.45);
5630
+ /* Above the receipt it is opened from, below the rail popovers. */
5631
+ z-index: 9999;
3384
5632
  overflow: hidden;
3385
- animation: snapshot-panel-in 0.15s ease-out;
5633
+ animation: snapshot-panel-in 0.18s ease-out;
3386
5634
  }
3387
5635
 
3388
5636
  @keyframes snapshot-panel-in {
3389
- from { opacity: 0; transform: translateY(-6px); }
3390
- to { opacity: 1; transform: translateY(0); }
5637
+ from { opacity: 0; transform: translateX(12px); }
5638
+ to { opacity: 1; transform: translateX(0); }
3391
5639
  }
3392
5640
 
3393
5641
  .snapshot-panel-header {
3394
5642
  display: flex;
3395
5643
  align-items: center;
3396
- justify-content: space-between;
3397
- padding: 10px 14px;
5644
+ gap: 8px;
5645
+ height: var(--hud-bar-height);
5646
+ padding: 0 14px;
3398
5647
  border-bottom: 1px solid var(--c-line);
5648
+ flex-shrink: 0;
3399
5649
  }
3400
-
3401
5650
  .snapshot-panel-title {
3402
5651
  font-size: 11px;
3403
- font-weight: 600;
5652
+ font-weight: 700;
5653
+ letter-spacing: 0.08em;
3404
5654
  text-transform: uppercase;
3405
- letter-spacing: 0.06em;
3406
- color: var(--c-muted);
5655
+ color: var(--c-text);
5656
+ }
5657
+ .snapshot-panel-sub {
5658
+ font-size: 10px;
5659
+ color: var(--c-dim);
5660
+ }
5661
+ .snapshot-panel-spacer {
5662
+ flex: 1;
3407
5663
  }
3408
-
3409
5664
  .snapshot-panel-close {
3410
5665
  background: none;
3411
5666
  border: none;
3412
- color: var(--c-dim);
3413
- font-size: 16px;
5667
+ color: var(--c-muted);
5668
+ font-size: 14px;
3414
5669
  cursor: pointer;
3415
5670
  padding: 0 2px;
3416
- line-height: 1;
3417
5671
  }
3418
5672
  .snapshot-panel-close:hover {
3419
5673
  color: var(--c-text);
@@ -3422,152 +5676,172 @@ html.is-node-resizing .ext-app-preview-catcher {
3422
5676
  .snapshot-save-form {
3423
5677
  display: flex;
3424
5678
  gap: 6px;
3425
- padding: 10px 14px;
3426
- border-bottom: 1px solid var(--c-line);
5679
+ padding: 10px 12px 6px;
3427
5680
  }
3428
-
3429
5681
  .snapshot-name-input {
3430
5682
  flex: 1;
3431
- background: var(--c-input-bg);
5683
+ min-width: 0;
5684
+ padding: 6px 10px;
3432
5685
  border: 1px solid var(--c-line);
3433
- border-radius: var(--radius-sm);
5686
+ border-radius: 7px;
5687
+ background: var(--c-panel);
3434
5688
  color: var(--c-text);
3435
- font-family: var(--font);
3436
- font-size: 12px;
3437
- padding: 6px 10px;
3438
- outline: none;
3439
- transition: border-color 0.15s;
5689
+ font: 11.5px var(--font);
3440
5690
  }
3441
5691
  .snapshot-name-input:focus {
3442
- border-color: var(--c-accent);
5692
+ outline: 2px solid var(--c-accent);
5693
+ outline-offset: 1px;
3443
5694
  }
3444
5695
  .snapshot-name-input::placeholder {
3445
5696
  color: var(--c-dim);
3446
5697
  }
3447
-
3448
5698
  .snapshot-save-btn {
3449
- background: var(--c-accent);
5699
+ padding: 6px 12px;
3450
5700
  border: none;
3451
- color: var(--c-contrast-fg);
3452
- font-family: var(--font);
5701
+ border-radius: 7px;
5702
+ background: var(--c-accent);
5703
+ color: var(--c-bg);
3453
5704
  font-size: 11px;
3454
5705
  font-weight: 600;
3455
- padding: 6px 14px;
3456
- border-radius: var(--radius-sm);
3457
5706
  cursor: pointer;
3458
- white-space: nowrap;
3459
- transition: background 0.15s;
3460
- }
3461
- .snapshot-save-btn:hover:not(:disabled) {
3462
- background: var(--c-accent-hover);
3463
5707
  }
3464
5708
  .snapshot-save-btn:disabled {
3465
- opacity: 0.4;
5709
+ opacity: 0.45;
3466
5710
  cursor: default;
3467
5711
  }
3468
-
3469
5712
  .snapshot-restore-note {
3470
- padding: 0 12px 10px;
3471
- font-size: 10px;
5713
+ padding: 0 12px 8px;
5714
+ font-size: 9.5px;
3472
5715
  color: var(--c-dim);
3473
5716
  }
3474
5717
 
3475
5718
  .snapshot-list {
3476
- overflow-y: auto;
3477
5719
  flex: 1;
3478
- padding: 4px 0;
5720
+ min-height: 0;
5721
+ overflow-y: auto;
5722
+ padding: 4px 12px 10px;
5723
+ display: flex;
5724
+ flex-direction: column;
5725
+ gap: 8px;
3479
5726
  }
3480
-
3481
5727
  .snapshot-empty {
3482
- padding: 20px 14px;
5728
+ padding: 14px 2px;
5729
+ font-size: 11px;
3483
5730
  color: var(--c-dim);
3484
- font-size: 12px;
3485
- text-align: center;
3486
- line-height: 1.5;
5731
+ }
5732
+ .snapshot-section-header {
5733
+ margin: 10px 2px 4px;
5734
+ font-size: 10px;
5735
+ font-weight: 700;
5736
+ letter-spacing: 0.08em;
5737
+ text-transform: uppercase;
5738
+ color: var(--c-muted);
3487
5739
  }
3488
5740
 
3489
5741
  .snapshot-item {
5742
+ padding: 10px 12px;
5743
+ border: 1px solid var(--c-line);
5744
+ border-radius: 10px;
5745
+ }
5746
+ .snapshot-item.is-session {
5747
+ border-color: color-mix(in srgb, var(--c-purple) 30%, transparent);
5748
+ background: color-mix(in srgb, var(--c-purple) 5%, transparent);
5749
+ }
5750
+ .snapshot-item-head {
3490
5751
  display: flex;
3491
5752
  align-items: center;
3492
- justify-content: space-between;
3493
- gap: 8px;
3494
- padding: 8px 14px;
3495
- transition: background 0.1s;
5753
+ gap: 7px;
3496
5754
  }
3497
- .snapshot-item:hover {
3498
- background: var(--c-surface-hover);
5755
+ .snapshot-session-dot {
5756
+ width: 7px;
5757
+ height: 7px;
5758
+ border-radius: 50%;
5759
+ background: var(--c-purple);
5760
+ flex-shrink: 0;
3499
5761
  }
3500
-
3501
- .snapshot-item-info {
3502
- display: flex;
3503
- flex-direction: column;
3504
- gap: 2px;
3505
- min-width: 0;
3506
- flex: 1;
5762
+ .snapshot-item-glyph {
5763
+ color: var(--c-muted);
5764
+ font-size: 12px;
5765
+ line-height: 1;
3507
5766
  }
3508
-
3509
5767
  .snapshot-item-name {
3510
- font-size: 12px;
3511
- font-weight: 500;
3512
- color: var(--c-text);
5768
+ flex: 1;
5769
+ min-width: 0;
5770
+ font-size: 11.5px;
5771
+ font-weight: 600;
5772
+ color: var(--c-text-soft);
3513
5773
  white-space: nowrap;
3514
5774
  overflow: hidden;
3515
5775
  text-overflow: ellipsis;
3516
5776
  }
3517
-
3518
- .snapshot-item-meta {
3519
- font-size: 10px;
5777
+ .snapshot-item.is-session .snapshot-item-name {
5778
+ color: var(--c-text);
5779
+ }
5780
+ .snapshot-item-time {
5781
+ font: 9px var(--mono);
3520
5782
  color: var(--c-dim);
3521
5783
  }
3522
-
5784
+ .snapshot-item-meta {
5785
+ margin-top: 3px;
5786
+ font-size: 10.5px;
5787
+ color: var(--c-muted);
5788
+ }
5789
+ .snapshot-item-diff {
5790
+ color: var(--c-accent);
5791
+ }
3523
5792
  .snapshot-item-actions {
3524
5793
  display: flex;
3525
- gap: 4px;
3526
- flex-shrink: 0;
3527
- opacity: 0;
3528
- transition: opacity 0.1s;
3529
- }
3530
- .snapshot-item:hover .snapshot-item-actions {
3531
- opacity: 1;
5794
+ gap: 6px;
5795
+ margin-top: 8px;
3532
5796
  }
3533
-
3534
5797
  .snapshot-action-btn {
3535
- background: none;
5798
+ flex: 1;
5799
+ padding: 5px 0;
3536
5800
  border: 1px solid var(--c-line);
5801
+ border-radius: 6px;
5802
+ background: none;
3537
5803
  color: var(--c-muted);
3538
- font-family: var(--font);
3539
- font-size: 10px;
3540
- padding: 3px 8px;
3541
- border-radius: var(--radius-sm);
5804
+ font-size: 10.5px;
5805
+ font-weight: 600;
3542
5806
  cursor: pointer;
3543
- transition: all 0.1s;
3544
5807
  }
3545
-
5808
+ .snapshot-action-btn:hover:not(:disabled) {
5809
+ color: var(--c-text);
5810
+ }
5811
+ .snapshot-action-btn:disabled {
5812
+ opacity: 0.5;
5813
+ cursor: default;
5814
+ }
5815
+ .snapshot-action-diff,
3546
5816
  .snapshot-action-restore {
5817
+ background: color-mix(in srgb, var(--c-accent) 12%, transparent);
5818
+ border-color: color-mix(in srgb, var(--c-accent) 30%, transparent);
3547
5819
  color: var(--c-accent);
3548
- border-color: var(--c-accent-25);
3549
5820
  }
3550
- .snapshot-action-restore:hover {
3551
- background: var(--c-accent-12);
3552
- border-color: var(--c-accent);
5821
+ .snapshot-action-diff:hover:not(:disabled),
5822
+ .snapshot-action-restore:hover:not(:disabled) {
5823
+ background: color-mix(in srgb, var(--c-accent) 20%, transparent);
5824
+ color: var(--c-accent);
3553
5825
  }
3554
-
3555
5826
  .snapshot-action-delete {
3556
- color: var(--c-dim);
3557
- border-color: transparent;
3558
- padding: 3px 5px;
5827
+ flex: 0 0 auto;
5828
+ padding: 5px 9px;
3559
5829
  }
3560
- .snapshot-action-delete:hover {
5830
+ .snapshot-action-delete:hover:not(:disabled) {
5831
+ border-color: color-mix(in srgb, var(--c-danger) 40%, transparent);
3561
5832
  color: var(--c-danger);
3562
- border-color: var(--c-danger-12);
3563
5833
  }
3564
-
3565
5834
  .snapshot-action-confirm {
5835
+ background: color-mix(in srgb, var(--c-danger) 12%, transparent);
5836
+ border-color: color-mix(in srgb, var(--c-danger) 40%, transparent);
3566
5837
  color: var(--c-danger);
3567
- border-color: var(--c-danger);
3568
5838
  }
3569
- .snapshot-action-confirm:hover {
3570
- background: var(--c-danger-12);
5839
+ .snapshot-panel-foot {
5840
+ padding: 9px 14px;
5841
+ border-top: 1px solid var(--c-line);
5842
+ font-size: 9.5px;
5843
+ color: var(--c-dim);
5844
+ flex-shrink: 0;
3571
5845
  }
3572
5846
 
3573
5847
  /* ── Command Palette (Cmd/Ctrl+K) ──────────────────────────── */
@@ -3576,22 +5850,23 @@ html.is-node-resizing .ext-app-preview-catcher {
3576
5850
  position: fixed;
3577
5851
  inset: 0;
3578
5852
  z-index: 10002;
3579
- background: rgba(0, 0, 0, 0.25);
5853
+ background: rgba(4, 10, 18, 0.55);
3580
5854
  display: flex;
3581
5855
  justify-content: center;
3582
- padding-top: 18vh;
5856
+ padding-top: 56px;
3583
5857
  }
3584
5858
 
5859
+ /* ⌘K palette (rail-chrome-v2 phase 7, item 7): 560px, top-anchored at 56px,
5860
+ grouped results, footer key hints. */
3585
5861
  .command-palette {
3586
- width: 500px;
3587
- max-height: 440px;
5862
+ width: min(560px, calc(100% - 48px));
5863
+ max-height: min(520px, calc(100vh - 80px));
3588
5864
  display: flex;
3589
5865
  flex-direction: column;
3590
- background: var(--c-panel-glass);
3591
- backdrop-filter: blur(16px);
5866
+ background: var(--c-panel);
3592
5867
  border: 1px solid var(--c-line);
3593
- border-radius: var(--radius);
3594
- box-shadow: 0 12px 40px var(--c-shadow-heavy), 0 0 0 1px rgba(255,255,255,0.04);
5868
+ border-radius: 12px;
5869
+ box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
3595
5870
  overflow: hidden;
3596
5871
  animation: command-palette-in 0.12s ease-out;
3597
5872
  align-self: flex-start;
@@ -3602,107 +5877,99 @@ html.is-node-resizing .ext-app-preview-catcher {
3602
5877
  to { opacity: 1; transform: translateY(0) scale(1); }
3603
5878
  }
3604
5879
 
5880
+ .command-palette-search {
5881
+ display: flex;
5882
+ align-items: center;
5883
+ gap: 10px;
5884
+ padding: 12px 14px;
5885
+ border-bottom: 1px solid var(--c-line);
5886
+ color: var(--c-accent);
5887
+ }
3605
5888
  .command-palette-input {
3606
- background: var(--c-input-bg);
5889
+ flex: 1;
5890
+ min-width: 0;
5891
+ padding: 0;
3607
5892
  border: none;
3608
- border-bottom: 1px solid var(--c-line);
3609
- color: var(--c-text);
3610
- font-family: var(--font);
3611
- font-size: 14px;
3612
- padding: 14px 16px;
3613
5893
  outline: none;
3614
- width: 100%;
3615
- box-sizing: border-box;
3616
- }
3617
- .command-palette-input:focus {
3618
- border-bottom-color: var(--c-accent);
5894
+ background: none;
5895
+ color: var(--c-text);
5896
+ font: 13px var(--font);
3619
5897
  }
3620
5898
  .command-palette-input::placeholder {
3621
5899
  color: var(--c-dim);
3622
5900
  }
3623
-
3624
- .command-palette-hint {
3625
- display: flex;
3626
- gap: 12px;
3627
- padding: 6px 16px;
3628
- font-size: 10px;
3629
- color: var(--c-dim);
3630
- border-bottom: 1px solid var(--c-line);
3631
- }
3632
- .command-palette-hint kbd {
3633
- display: inline-block;
3634
- background: var(--c-surface-hover);
5901
+ .command-palette-esc,
5902
+ .command-palette-kbd {
5903
+ padding: 1px 6px;
3635
5904
  border: 1px solid var(--c-line);
3636
- border-radius: 3px;
3637
- padding: 0 4px;
3638
- font-family: var(--font);
3639
- font-size: 9px;
3640
- line-height: 1.6;
3641
- margin-right: 2px;
5905
+ border-radius: 4px;
5906
+ font: 9.5px var(--mono);
5907
+ color: var(--c-muted);
5908
+ }
5909
+ .command-palette-esc {
5910
+ padding: 2px 7px;
5911
+ border-radius: 5px;
5912
+ color: var(--c-dim);
3642
5913
  }
3643
5914
 
3644
5915
  .command-palette-results {
3645
- overflow-y: auto;
3646
5916
  flex: 1;
3647
- padding: 4px 0;
5917
+ min-height: 0;
5918
+ overflow-y: auto;
5919
+ padding: 6px 6px 4px;
3648
5920
  }
3649
-
3650
5921
  .command-palette-empty {
3651
- padding: 24px 16px;
3652
- text-align: center;
3653
- color: var(--c-dim);
5922
+ padding: 14px 10px;
3654
5923
  font-size: 12px;
5924
+ color: var(--c-dim);
5925
+ }
5926
+ .command-palette-group {
5927
+ padding: 6px 10px 4px;
5928
+ font-size: 9px;
5929
+ font-weight: 700;
5930
+ letter-spacing: 0.08em;
5931
+ text-transform: uppercase;
5932
+ color: var(--c-dim);
3655
5933
  }
3656
-
3657
5934
  .command-palette-item {
3658
5935
  display: flex;
3659
5936
  align-items: center;
3660
5937
  gap: 10px;
3661
5938
  width: 100%;
3662
- padding: 8px 16px;
3663
- background: none;
5939
+ padding: 7px 10px;
3664
5940
  border: none;
3665
- color: var(--c-text);
3666
- font-family: var(--font);
3667
- font-size: 12px;
5941
+ border-radius: 8px;
5942
+ background: none;
5943
+ color: var(--c-text-soft);
3668
5944
  cursor: pointer;
3669
5945
  text-align: left;
3670
- transition: background 0.06s;
3671
- }
3672
-
3673
- .command-palette-item.selected {
3674
- background: var(--c-accent-10);
5946
+ font: inherit;
3675
5947
  }
3676
-
3677
5948
  .command-palette-item:hover {
3678
- background: var(--c-surface-hover);
5949
+ background: color-mix(in srgb, var(--c-text) 5%, transparent);
3679
5950
  }
3680
-
5951
+ .command-palette-item.selected,
3681
5952
  .command-palette-item.selected:hover {
3682
- background: var(--c-accent-10);
5953
+ background: color-mix(in srgb, var(--c-accent) 12%, transparent);
5954
+ color: var(--c-text);
3683
5955
  }
3684
-
3685
- .command-palette-badge {
3686
- font-size: 9px;
3687
- padding: 1px 6px;
3688
- border-radius: 4px;
3689
- background: var(--c-accent-12);
3690
- color: var(--c-accent);
5956
+ .command-palette-icon {
5957
+ display: inline-flex;
3691
5958
  flex-shrink: 0;
3692
- font-weight: 600;
3693
- letter-spacing: 0.04em;
3694
- text-transform: uppercase;
3695
- min-width: 32px;
3696
- text-align: center;
5959
+ width: 14px;
5960
+ height: 14px;
5961
+ color: var(--c-accent);
3697
5962
  }
3698
-
3699
- .command-palette-badge--action {
3700
- background: rgba(176, 122, 255, 0.12);
5963
+ .command-palette-icon.tone-purple {
3701
5964
  color: var(--c-purple);
3702
5965
  }
3703
-
5966
+ .command-palette-icon.tone-muted {
5967
+ color: var(--c-muted);
5968
+ }
3704
5969
  .command-palette-label {
3705
5970
  flex: 1;
5971
+ min-width: 0;
5972
+ font-size: 12px;
3706
5973
  white-space: nowrap;
3707
5974
  overflow: hidden;
3708
5975
  text-overflow: ellipsis;
@@ -3712,15 +5979,21 @@ html.is-node-resizing .ext-app-preview-catcher {
3712
5979
  color: var(--c-accent);
3713
5980
  font-weight: 600;
3714
5981
  }
3715
-
3716
5982
  .command-palette-desc {
3717
- font-size: 11px;
3718
5983
  color: var(--c-dim);
3719
- white-space: nowrap;
3720
- overflow: hidden;
3721
- text-overflow: ellipsis;
3722
- max-width: 180px;
3723
- flex-shrink: 0;
5984
+ }
5985
+
5986
+ .command-palette-hint {
5987
+ display: flex;
5988
+ gap: 14px;
5989
+ padding: 8px 14px;
5990
+ border-top: 1px solid var(--c-line);
5991
+ background: color-mix(in srgb, var(--c-bg) 50%, transparent);
5992
+ font: 9.5px var(--mono);
5993
+ color: var(--c-dim);
5994
+ }
5995
+ .command-palette-hint-spacer {
5996
+ flex: 1;
3724
5997
  }
3725
5998
 
3726
5999
  /* ── Shortcut Overlay (Press ?) ────────────────────────────── */
@@ -3829,88 +6102,117 @@ html.is-node-resizing .ext-app-preview-catcher {
3829
6102
  line-height: 1.4;
3830
6103
  }
3831
6104
 
3832
- /* ── Welcome Card (empty canvas) ────────────────────────── */
3833
- .welcome-card {
6105
+ /* ── Empty board (rail-chrome-v2 phase 7, design item 11) ───── */
6106
+ .empty-state {
3834
6107
  position: absolute;
3835
6108
  top: 50%;
3836
6109
  left: 50%;
3837
6110
  transform: translate(-50%, -50%);
3838
6111
  z-index: 5;
6112
+ width: 560px;
6113
+ max-width: calc(100% - 48px);
3839
6114
  display: flex;
3840
6115
  flex-direction: column;
3841
6116
  align-items: center;
3842
- gap: 12px;
3843
- padding: 36px 44px;
3844
- background: var(--c-panel-glass);
3845
- backdrop-filter: blur(16px);
3846
- border: 1px solid var(--c-line);
3847
- border-radius: 16px;
3848
- box-shadow: 0 8px 32px var(--c-shadow), 0 0 0 1px var(--c-line-30);
3849
- animation: welcome-fade-in 0.5s ease-out;
3850
- pointer-events: auto;
3851
- max-width: 380px;
6117
+ gap: 16px;
3852
6118
  text-align: center;
6119
+ animation: empty-state-in 0.4s ease-out;
3853
6120
  }
3854
-
3855
- @keyframes welcome-fade-in {
3856
- from { opacity: 0; transform: translate(-50%, -48%); }
3857
- to { opacity: 1; transform: translate(-50%, -50%); }
6121
+ @keyframes empty-state-in {
6122
+ from {
6123
+ opacity: 0;
6124
+ transform: translate(-50%, -46%);
6125
+ }
6126
+ to {
6127
+ opacity: 1;
6128
+ transform: translate(-50%, -50%);
6129
+ }
3858
6130
  }
3859
-
3860
- .welcome-icon {
3861
- font-size: 32px;
3862
- color: var(--c-accent);
3863
- opacity: 0.7;
3864
- line-height: 1;
6131
+ .empty-state-mark {
6132
+ stroke: var(--c-line);
6133
+ stroke-width: 2.5;
3865
6134
  }
3866
-
3867
- .welcome-title {
3868
- font-size: 18px;
3869
- font-weight: 600;
6135
+ .empty-state-mark rect + rect {
6136
+ stroke: color-mix(in srgb, var(--c-line) 70%, var(--c-accent));
6137
+ }
6138
+ .empty-state-title {
6139
+ font-size: 20px;
6140
+ font-weight: 700;
6141
+ letter-spacing: -0.01em;
3870
6142
  color: var(--c-text);
3871
- letter-spacing: -0.3px;
3872
6143
  }
3873
-
3874
- .welcome-subtitle {
3875
- font-size: 12px;
3876
- color: var(--c-dim);
3877
- margin-bottom: 8px;
3878
- line-height: 1.55;
6144
+ .empty-state-sub {
6145
+ margin-top: 6px;
6146
+ font-size: 12.5px;
6147
+ color: var(--c-muted);
3879
6148
  }
3880
-
3881
- .welcome-hints {
3882
- display: flex;
3883
- flex-direction: column;
3884
- gap: 6px;
6149
+ .empty-state-grid {
6150
+ display: grid;
6151
+ grid-template-columns: 1fr 1fr;
6152
+ gap: 10px;
3885
6153
  width: 100%;
3886
6154
  }
3887
-
3888
- .welcome-hint {
6155
+ .empty-state-action {
3889
6156
  display: flex;
3890
6157
  align-items: center;
3891
- gap: 12px;
3892
- padding: 8px 12px;
3893
- background: var(--c-surface-subtle);
3894
- border: 1px solid transparent;
3895
- border-radius: var(--radius-sm);
6158
+ gap: 10px;
6159
+ padding: 13px 14px;
6160
+ background: var(--c-panel);
6161
+ border: 1px solid var(--c-line);
6162
+ border-radius: 10px;
6163
+ color: var(--c-text-soft);
6164
+ cursor: pointer;
3896
6165
  text-align: left;
3897
- cursor: default;
3898
6166
  font: inherit;
3899
- color: inherit;
3900
6167
  }
3901
-
3902
- button.welcome-hint {
6168
+ .empty-state-action:hover {
6169
+ border-color: color-mix(in srgb, var(--c-accent) 40%, transparent);
6170
+ }
6171
+ .empty-state-action.is-agent:hover {
6172
+ border-color: color-mix(in srgb, var(--c-purple) 45%, transparent);
6173
+ }
6174
+ .empty-state-action .tone-accent {
6175
+ color: var(--c-accent);
6176
+ }
6177
+ .empty-state-action .tone-warn {
6178
+ color: var(--c-warn);
6179
+ }
6180
+ .empty-state-action .tone-ok {
6181
+ color: var(--c-ok);
6182
+ }
6183
+ .empty-state-action .tone-purple {
6184
+ color: var(--c-purple);
6185
+ }
6186
+ .empty-state-action-label {
6187
+ flex: 1;
6188
+ font-size: 12px;
6189
+ font-weight: 600;
6190
+ }
6191
+ .empty-state-action kbd {
6192
+ padding: 1px 6px;
6193
+ border: 1px solid var(--c-line);
6194
+ border-radius: 4px;
6195
+ font: 9.5px var(--mono);
6196
+ color: var(--c-dim);
6197
+ }
6198
+ .empty-state-action-hint {
6199
+ font-size: 10px;
6200
+ color: var(--c-dim);
6201
+ }
6202
+ .empty-state-hint {
6203
+ background: none;
6204
+ border: none;
6205
+ padding: 0;
6206
+ font: 10.5px var(--mono);
6207
+ color: var(--c-dim);
3903
6208
  cursor: pointer;
3904
6209
  }
3905
-
3906
- button.welcome-hint:hover {
3907
- background: var(--c-surface-hover);
3908
- border-color: var(--c-line);
6210
+ .empty-state-hint:hover {
6211
+ color: var(--c-muted);
3909
6212
  }
3910
6213
 
3911
6214
  @media (max-width: 980px) {
3912
6215
  .attention-toast {
3913
- top: 70px;
3914
6216
  left: 12px;
3915
6217
  right: 12px;
3916
6218
  width: auto;
@@ -3924,16 +6226,11 @@ button.welcome-hint:hover {
3924
6226
  width: auto;
3925
6227
  }
3926
6228
 
3927
- .welcome-card {
3928
- width: calc(100vw - 24px);
3929
- max-width: 420px;
3930
- padding: 28px 24px;
3931
- }
3932
6229
  }
3933
6230
 
3934
6231
  @media (prefers-reduced-motion: reduce) {
3935
6232
  .attention-toast,
3936
- .welcome-card,
6233
+ .empty-state,
3937
6234
  .canvas-node.attention-pulse {
3938
6235
  animation: none !important;
3939
6236
  }
@@ -3945,32 +6242,8 @@ button.welcome-hint:hover {
3945
6242
  }
3946
6243
  }
3947
6244
 
3948
- .welcome-hint kbd {
3949
- display: inline-block;
3950
- background: var(--c-input-bg);
3951
- border: 1px solid var(--c-line);
3952
- border-radius: 4px;
3953
- padding: 2px 7px;
3954
- font-family: var(--mono);
3955
- font-size: 10px;
3956
- color: var(--c-accent);
3957
- white-space: nowrap;
3958
- min-width: 70px;
3959
- text-align: center;
3960
- flex-shrink: 0;
3961
- }
3962
6245
 
3963
- .welcome-hint span {
3964
- font-size: 12px;
3965
- color: var(--c-muted);
3966
- }
3967
6246
 
3968
- .welcome-footer {
3969
- font-size: 11px;
3970
- color: var(--c-dim);
3971
- margin-top: 4px;
3972
- line-height: 1.4;
3973
- }
3974
6247
 
3975
6248
  /* ── Image Node ─────────────────────────────────────────────── */
3976
6249
  .image-node {