dsh-kingdom 2.0.0 → 3.2.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 (78) hide show
  1. package/ASSETS_NOTICE.md +22 -22
  2. package/README.md +246 -243
  3. package/THIRD_PARTY_NOTICES.md +92 -92
  4. package/docs/DSH-KINGDOM-3.0-ANNOUNCEMENT.md +13 -0
  5. package/docs/V2.0-RELEASE-NOTES.md +30 -30
  6. package/docs/V2.0-USER-GUIDE.md +74 -74
  7. package/docs/V3.0-RELEASE-NOTES.md +21 -0
  8. package/docs/V3.0-USER-GUIDE.md +33 -0
  9. package/docs/V3.1-RELEASE-NOTES.md +76 -0
  10. package/docs/V3.2-RELEASE-NOTES.md +103 -0
  11. package/lib/core/binding.js +167 -60
  12. package/lib/core/binding.js.map +1 -1
  13. package/lib/core/db.js +582 -546
  14. package/lib/core/db.js.map +1 -1
  15. package/lib/core/delivery-ack.js +1356 -0
  16. package/lib/core/delivery-ack.js.map +1 -0
  17. package/lib/core/delivery-change.js +1237 -0
  18. package/lib/core/delivery-change.js.map +1 -0
  19. package/lib/core/owner-binding-intent.js +14 -25
  20. package/lib/core/owner-binding-intent.js.map +1 -1
  21. package/lib/core/owner-window.js +698 -23
  22. package/lib/core/owner-window.js.map +1 -1
  23. package/lib/core/task-service.js +144 -5
  24. package/lib/core/task-service.js.map +1 -1
  25. package/lib/core/territory.js +43 -9
  26. package/lib/core/territory.js.map +1 -1
  27. package/lib/gui/assets/characters/chancellor-idle.svg +67 -67
  28. package/lib/gui/assets/characters/chancellor-sleeping.svg +67 -67
  29. package/lib/gui/assets/characters/chancellor-thinking.svg +67 -67
  30. package/lib/gui/assets/characters/chancellor-working.svg +67 -67
  31. package/lib/gui/assets/characters/knight-redraw-r1-idle.svg +67 -67
  32. package/lib/gui/assets/characters/knight-redraw-r1-sleeping.svg +67 -67
  33. package/lib/gui/assets/characters/knight-redraw-r1-thinking.svg +67 -67
  34. package/lib/gui/assets/characters/knight-redraw-r1-working.svg +67 -67
  35. package/lib/gui/assets/characters/supervisor-idle.svg +67 -67
  36. package/lib/gui/assets/characters/supervisor-sleeping.svg +67 -67
  37. package/lib/gui/assets/characters/supervisor-thinking.svg +67 -67
  38. package/lib/gui/assets/characters/supervisor-working.svg +67 -67
  39. package/lib/gui/console-app.js +7 -1
  40. package/lib/gui/console-app.js.map +1 -1
  41. package/lib/gui/contract.js +6 -0
  42. package/lib/gui/contract.js.map +1 -1
  43. package/lib/gui/control-contract.js +3 -2
  44. package/lib/gui/control-contract.js.map +1 -1
  45. package/lib/gui/owner-control.js +114 -4
  46. package/lib/gui/owner-control.js.map +1 -1
  47. package/lib/gui/owner-ui.js +645 -183
  48. package/lib/gui/owner-ui.js.map +1 -1
  49. package/lib/gui/server.js +109 -109
  50. package/lib/gui/snapshot.js +127 -4
  51. package/lib/gui/snapshot.js.map +1 -1
  52. package/lib/gui/visual-assets.js +37 -21
  53. package/lib/gui/visual-assets.js.map +1 -1
  54. package/lib/gui/visual-system.js +269 -269
  55. package/lib/gui/workbench-ui.js +549 -136
  56. package/lib/gui/workbench-ui.js.map +1 -1
  57. package/lib/gui/workbench.js +133 -0
  58. package/lib/gui/workbench.js.map +1 -1
  59. package/lib/index.js +392 -40
  60. package/lib/index.js.map +1 -1
  61. package/lib/types/core/binding.d.ts +29 -0
  62. package/lib/types/core/db.d.ts +14 -0
  63. package/lib/types/core/delivery-ack.d.ts +688 -0
  64. package/lib/types/core/delivery-change.d.ts +381 -0
  65. package/lib/types/core/owner-binding-intent.d.ts +9 -1
  66. package/lib/types/core/owner-window.d.ts +237 -3
  67. package/lib/types/core/task-service.d.ts +22 -0
  68. package/lib/types/core/territory.d.ts +18 -3
  69. package/lib/types/gui/contract.d.ts +162 -1
  70. package/lib/types/gui/owner-control.d.ts +61 -1
  71. package/lib/types/gui/snapshot.d.ts +8 -0
  72. package/lib/types/gui/visual-assets.d.ts +16 -0
  73. package/lib/types/gui/workbench.d.ts +47 -1
  74. package/lib/types/index.d.ts +60 -1
  75. package/lib/types/worker/governed-executor.d.ts +15 -0
  76. package/lib/worker/governed-executor.js +21 -0
  77. package/lib/worker/governed-executor.js.map +1 -1
  78. package/package.json +80 -75
@@ -1,272 +1,272 @@
1
1
  /** Final presentation layer; the existing console owns all state and behavior. */
2
- export const CONSOLE_DESIGN_CSS = String.raw `
3
- /* Theme tokens: territory identity and operational status are separate. */
4
- :root, html[data-theme="parchment"] {
5
- color-scheme: light;
6
- --gate: #eee8db; --gate-deep: #f7f2e8; --patina: #fffdf7; --patina-raised: #f2eddf;
7
- --panel-soft: #f5f0e6; --field-bg: #fffdf7; --bamboo: #302f28; --ink: #302f28;
8
- --muted: #5d6053; --dim: #626658; --gold: #765b20; --jade: #346744;
9
- --cinnabar: #a8393d; --danger-text: #a8393d; --line: #d0ccbc; --line-strong: #737b65;
10
- --shadow: 0 4px 16px rgba(43, 44, 33, .06); --texture: transparent;
11
- --status-running: #235f91; --status-review: #73528f; --status-done: #346744;
12
- --status-blocked: #a8393d; --status-unknown: #835a16; --status-idle: #62675c;
13
- --status-running-wash: #e9f1f8; --status-review-wash: #f1ebf7; --status-done-wash: #eaf2e9;
14
- --status-blocked-wash: #faeaea; --status-unknown-wash: #f6eedc; --status-idle-wash: #eeefe8;
15
- --territory-1: #5f7b63; --territory-2: #8a6785; --territory-3: #6a7b8b;
16
- --territory-4: #997638; --territory-5: #447d80; --territory-6: #a26e59;
17
- --focus-ring: #765b20; --connector: #737b65; --nav-height: 76px; --feedback-offset: 84px;
18
- font-family: "Noto Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
19
- }
20
- html[data-theme="night"] {
21
- color-scheme: dark;
22
- --gate: #131d29; --gate-deep: #162231; --patina: #1e2c3d; --patina-raised: #293a4c;
23
- --panel-soft: #1a2736; --field-bg: #172432; --bamboo: #edf2f5; --ink: #edf2f5;
24
- --muted: #bdc9d5; --dim: #a8b8c9; --gold: #dbbf82; --jade: #a0d4ae;
25
- --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #3a4c5c; --line-strong: #8094a5;
26
- --shadow: 0 4px 16px rgba(0, 0, 0, .16); --focus-ring: #dbbf82; --connector: #8094a5;
27
- }
28
- html[data-theme="forest"] {
29
- color-scheme: dark;
30
- --gate: #13251f; --gate-deep: #172c24; --patina: #1c342c; --patina-raised: #254137;
31
- --panel-soft: #1a2f27; --field-bg: #172b23; --bamboo: #f0f4ea; --ink: #f0f4ea;
32
- --muted: #b7c8bd; --dim: #a9bcb0; --gold: #d8be7c; --jade: #a0d4ae;
33
- --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #3b5448; --line-strong: #859b8b;
34
- --shadow: 0 4px 16px rgba(0, 0, 0, .15); --focus-ring: #d8be7c; --connector: #859b8b;
35
- }
36
- html[data-theme="wine"] {
37
- color-scheme: dark;
38
- --gate: #281c24; --gate-deep: #2f212a; --patina: #3b2a33; --patina-raised: #4c3642;
39
- --panel-soft: #35262f; --field-bg: #30222b; --bamboo: #f6edf0; --ink: #f6edf0;
40
- --muted: #d2bdc7; --dim: #c5adb8; --gold: #e1c08b; --jade: #a0d4ae;
41
- --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #604853; --line-strong: #a28792;
42
- --shadow: 0 4px 16px rgba(0, 0, 0, .16); --focus-ring: #e1c08b; --connector: #a28792;
43
- }
44
- html[data-theme="night"], html[data-theme="forest"], html[data-theme="wine"] {
45
- --status-running: #9fcbf5; --status-review: #d1b9f5; --status-done: #a0d4ae;
46
- --status-blocked: #ffaba8; --status-unknown: #e6c184; --status-idle: #bec8c1;
47
- --status-running-wash: rgba(159, 203, 245, .08); --status-review-wash: rgba(209, 185, 245, .08);
48
- --status-done-wash: rgba(160, 212, 174, .08); --status-blocked-wash: rgba(255, 171, 168, .08);
49
- --status-unknown-wash: rgba(230, 193, 132, .08); --status-idle-wash: rgba(190, 200, 193, .08);
50
- --territory-1: #94b99e; --territory-2: #b99cb5; --territory-3: #9faebc;
51
- --territory-4: #c3ab77; --territory-5: #89b1b3; --territory-6: #c19c86;
52
- }
53
- /* Typography, quiet surfaces, and visible keyboard paths. */
54
- html, html[data-theme], body, html[data-theme] body { background: var(--gate); color: var(--bamboo); }
55
- body { font-size: 14px; line-height: 1.6; }
56
- h1, h2, h3, .display-title { font-family: "Noto Serif SC", "Source Han Serif SC", STSong, serif; }
57
- button, input, textarea, select { font: inherit; }
58
- code, kbd { font-family: Consolas, "SFMono-Regular", monospace; }
59
- a, button, summary, input, textarea, select { -webkit-tap-highlight-color: transparent; }
60
- a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--focus-ring); outline-offset: 3px; }
61
- .skip-link { z-index: 100; }
62
- [data-console-section], [data-console-page], #ledger, #management { scroll-margin-top: calc(var(--nav-height) + var(--feedback-offset)); }
63
- .ui-icon { display: inline-block; flex: 0 0 20px; width: 20px; height: 20px; color: currentColor; vertical-align: -.2em; }
64
- .role-insignia { width: 20px; height: 20px; color: var(--gold); vertical-align: -.2em; }
65
- .section-kicker, .brand-kicker { font-size: 12px; line-height: 1.5; letter-spacing: .08em; }
66
- .meta, .hint, .source-ref, .evidence-kind, .button-reason, .danger-note, .code-badge,
67
- .session-chip, .status-glossary, .organogram-footer, .organogram-technical, .map-legend,
68
- .attention-technical, .node-details, .theme-picker-label, .active-theme-name,
69
- .task-composer-meta, .task-composer-heading > span, .task-territory-chip { font-size: 12px; line-height: 1.6; }
70
- .zone-head p, .attention-heading p, .brand-note, .rail-item code, .metric span,
71
- .health-copy small, #overview-content .metric span, .unassigned-worker-rail > header p,
72
- .management-heading-copy small, .territory-heading p { font-size: 12px; line-height: 1.55; }
73
- .map-heading .map-intro, .hero-copy p:not(.section-kicker), .capability-copy, .action-dock-head p,
74
- .form-route-note, .task-summary-card p, label, .rail-item span, .data-row { font-size: 14px; line-height: 1.65; }
75
- .ledger-page { font-size: 14px; line-height: 1.65; }
76
- .page-heading > p:not(.section-kicker), .ledger-page .timeline-item p, .ledger-page .attention-item > p { font-size: 14px; line-height: 1.65; }
77
- .zone, .capability-card, details.form-card, .attention-council, .task-composer-card { border: 1px solid var(--line); border-radius: 12px; background: var(--patina); box-shadow: none; }
78
- .zone { padding: 20px; }
79
- .zone-head { align-items: center; }
80
- .zone-head h2, .action-dock-head h2 { font-size: 18px; }
81
- .zone.map-page { padding: 0; border: 0; background: transparent; }
82
- /* Compact sticky navigation; names and theme preferences remain intact. */
83
- .realm-sidebar { position: sticky; top: 0; z-index: 50; height: auto; min-height: var(--nav-height); gap: 24px; padding: 10px clamp(20px, 4vw, 64px); background: var(--gate-deep); box-shadow: 0 1px 0 var(--line); }
84
- .realm-brand { min-width: 0; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; }
85
- .realm-brand h1 { font-size: 20px; line-height: 1.2; }
86
- .realm-seal { width: 40px; height: 40px; border: 0; background: transparent; }
87
- .realm-seal-icon { width: 36px; height: 36px; }
88
- .realm-seal > .kingdom-brand-mark { display: block; width: 100%; height: 100%; }
89
- .brand-note { margin-top: 3px; }
90
- .main-nav { gap: 6px; padding: 0; margin-left: auto; overflow: visible; }
91
- .main-nav a, .main-nav .nav-item { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 14px; border: 1px solid transparent; border-radius: 8px; color: var(--muted); font-size: 14px; white-space: nowrap; }
92
- .main-nav a:hover, .main-nav a[aria-current="page"] { border: 1px solid var(--line-strong); background: var(--patina-raised); color: var(--bamboo); }
93
- .main-nav a[aria-current="page"] { box-shadow: inset 0 -2px var(--gold); }
94
- .theme-picker { flex: 0 0 auto; gap: 8px; padding: 3px; border-radius: 10px; background: transparent; }
95
- .theme-picker-label { padding-left: 6px; }
96
- .theme-swatch { width: 40px; height: 40px; min-height: 40px; }
97
- .theme-swatch > span { box-shadow: none; }
98
- .theme-swatch[aria-pressed="true"] { box-shadow: none; border-color: var(--gold); background: var(--patina-raised); }
99
- .active-theme-name { padding-right: 6px; }
100
- .console-main { width: 100%; margin: 0 auto; padding: 20px clamp(20px, 4vw, 64px) 48px; }
101
- .map-heading, .page-heading { margin-bottom: 24px; }
102
- .map-heading h2, .page-heading h2 { font-size: clamp(26px, 2.6vw, 36px); line-height: 1.3; }
103
- .page-heading h2 { display: flex; align-items: center; gap: 10px; }
104
- .map-heading h2 .ui-icon { width: 28px; height: 28px; flex-basis: 28px; color: var(--gold); }
105
- /* Read feedback where it occurs; technical reasons remain selectable. */
106
- .feedback-stack { position: sticky; top: calc(var(--nav-height) + 8px); z-index: 30; margin-bottom: 16px; border-radius: 8px; background: var(--gate); }
107
- .feedback-stack .status-bar { margin-bottom: 0; }
108
- .feedback-stack .status-technical:not([hidden]) { max-height: min(32vh, 220px); margin: 6px 0 0; overflow: auto; }
109
- html:has(.feedback-stack .status-technical:not([hidden])) { --feedback-offset: 132px; }
110
- html:has(.feedback-stack .status-technical[open]:not([hidden])) { --feedback-offset: 300px; }
111
- .status-bar, .status-technical:not([hidden]) { position: relative; inset: auto; z-index: auto; width: 100%; max-width: none; margin: 0 0 16px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-soft); box-shadow: none; backdrop-filter: none; pointer-events: auto; }
112
- .status-bar { min-height: 42px; }
113
- .status-bar .status-text { font-size: 12px; line-height: 1.6; }
114
- .status-text[data-level="unknown"], .status-text[data-level="stale"] { color: var(--status-unknown); }
115
- .status-text[data-level="error"] { color: var(--status-blocked); }
116
- .status-technical:not([hidden]) { margin-top: -10px; font-size: 12px; }
117
- .status-technical code, .owner-management code { background: var(--field-bg); border-radius: 6px; }
118
- /* Organization hierarchy: restrained identity rules, legible role cards. */
119
- .realm-map { min-height: 0; }
120
- .realm-map::after { display: none; }
121
- .organogram-connection-layer path, .territory-connection-layer path { stroke: var(--connector); stroke-width: 1.5; opacity: 1; }
122
- .chancellor-card { width: min(100%, 560px); grid-template-columns: 80px minmax(0, 1fr) auto; gap: 12px; margin-bottom: 0; padding: 12px 16px; }
123
- .chancellor-card .pixel-sprite { width: 76px; height: 96px; }
124
- .chancellor-card h3 { font-size: 19px; }
125
- .chancellor-card p, .org-node p, .worker-stack .org-node p { font-size: 12px; line-height: 1.55; }
126
- .chancellor-card .node-task, .node-task { font-size: 14px; line-height: 1.55; }
127
- .organogram-branches, .organogram-branches[data-branch-count] { gap: 20px; padding-top: 32px; }
128
- .organogram-branches[data-branch-count="0"] { padding-top: 16px; }
129
- .territory-column, .territory-column[data-status] { padding: 16px; background: var(--panel-soft); border: 1px solid var(--line); border-top: 3px solid var(--territory-color); border-radius: 12px; box-shadow: none; }
130
- .territory-heading { padding-bottom: 10px; border-color: var(--line); }
131
- .territory-heading h3 { font-size: 18px; line-height: 1.4; }
132
- .territory-heading h3::before { width: 8px; height: 8px; border-radius: 2px; }
133
- .territory-role-network { gap: 24px; margin-top: 12px; padding-top: 0; }
134
- .chancellor-card, .org-node, .org-node[data-status], .task-summary-card { border: 1px solid var(--line); border-left: 3px solid var(--tone); border-radius: 10px; background: var(--patina); box-shadow: none; }
135
- .org-node[data-stage-evidence="indeterminate"] { background: var(--patina); border-left-color: var(--status-unknown); }
136
- .org-node[data-stage-evidence="unavailable"] { opacity: 1; }
137
- .org-node[data-role="supervisor"] { grid-template-columns: 68px minmax(0, 1fr); min-height: 108px; padding: 12px; }
138
- .org-node[data-role="supervisor"] .pixel-sprite { width: 68px; height: 88px; }
139
- .worker-stack .org-node, .org-node[data-role="worker"] { grid-template-columns: 56px minmax(0, 1fr); min-height: 96px; padding: 10px 12px; }
140
- .org-node[data-role="worker"] .pixel-sprite { width: 56px; height: 74px; }
141
- .org-node h4, .worker-stack .org-node h4 { font: 700 15px/1.5 "Noto Sans SC", "Microsoft YaHei UI", sans-serif; }
142
- .org-node[data-stage-evidence="unbound"], .org-node[data-stage-evidence="absent"] { grid-template-columns: minmax(0, 1fr); }
143
- .org-node .node-details p, .org-node .node-details code { font-size: 12px; }
144
- .node-details { border-top-color: var(--line); }
145
- .organogram-footer { margin-top: 16px; gap: 12px 20px; }
146
- .unassigned-worker-rail { padding: 12px; box-shadow: none; }
147
- /* SVG masks are decorative; adjacent text remains the semantic label. */
148
- [data-status-icon="!"] { --status-symbol: var(--icon-error); }
149
- [data-status-icon="?"] { --status-symbol: var(--icon-unknown); }
150
- [data-status-icon="◆"] { --status-symbol: var(--icon-review); }
151
- [data-status-icon="▶"] { --status-symbol: var(--icon-run); }
152
- [data-status-icon="✓"] { --status-symbol: var(--icon-accept); }
153
- [data-status-icon="○"] { --status-symbol: var(--icon-idle); }
154
- .status-pill::before, .task-link .task-status::before, .territory-alert[data-status]::before { content: ""; display: inline-block; flex: 0 0 14px; width: 14px; height: 14px; margin: 0; border-radius: 0; color: inherit; background: currentColor; mask: var(--status-symbol, var(--icon-unknown)) center / contain no-repeat; vertical-align: -.15em; }
155
- .status-pill, .task-link .task-status { display: inline-flex; align-items: center; gap: 5px; color: var(--tone, var(--status-unknown)); font-size: 12px; line-height: 1.5; }
156
- .status-pill { padding: 3px 7px; border-color: var(--line); background: var(--tone-wash, var(--status-unknown-wash)); }
157
- .territory-alert, .territory-alert[data-status] { min-height: 32px; margin: 10px 0; padding: 6px 8px; border-color: var(--line); background: var(--patina); color: var(--alert-tone); font-size: 12px; line-height: 1.6; }
158
- .territory-alert span::before { display: none; }
159
- .org-node h4::before, .chancellor-card .section-kicker::before { content: ""; display: inline-block; width: 16px; height: 16px; margin-right: 6px; background: var(--gold); mask: var(--role-symbol) center / contain no-repeat; vertical-align: -.17em; }
160
- .org-node[data-role="supervisor"] { --role-symbol: var(--icon-supervisor); }
161
- .org-node[data-role="worker"] { --role-symbol: var(--icon-worker); }
162
- .chancellor-card { --role-symbol: var(--icon-chancellor); }
163
- .empty, .org-empty { display: flex; align-items: center; gap: 12px; min-height: 48px; margin: 0; padding: 12px; border: 1px dashed var(--line-strong); border-radius: 10px; background: var(--panel-soft); color: var(--muted); font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
164
- .empty::before, .org-empty::before { content: ""; flex: 0 0 32px; width: 32px; height: 28px; background: var(--muted); mask: var(--empty-illustration-bg) center / contain no-repeat; }
165
- #territory-map-list > .empty { min-height: 132px; justify-content: center; }
166
- #territory-map-list > .empty::before { flex-basis: 80px; width: 80px; height: 68px; }
167
- .metric-grid > .empty { grid-column: 1 / -1; }
168
- .metric-grid > .empty::before { display: none; }
169
- /* Forms, ledger evidence, and the five-stage governance explanation. */
170
- input, textarea, select { min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--field-bg); }
171
- input::placeholder, textarea::placeholder { color: var(--dim); opacity: 1; }
172
- .primary, .secondary, .refresh { min-height: 40px; border-radius: 8px; font-size: 14px; }
173
- .primary { color: var(--bamboo); border-color: var(--line-strong); background: var(--patina-raised); }
174
- .primary:hover:not(:disabled) { border-color: var(--gold); background: var(--patina-raised); }
175
- .primary.danger { color: var(--status-blocked); border-color: var(--status-blocked); background: var(--status-blocked-wash); }
176
- button:disabled, .primary:disabled { opacity: 1; color: var(--dim); border-color: var(--line); background: var(--panel-soft); cursor: not-allowed; }
177
- .task-composer-shell { border-radius: 10px; box-shadow: none; }
178
- .task-composer-shell input:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: -2px; }
179
- .task-composer-card { padding: 20px; }
180
- details.form-card { padding: 0 16px 14px; }
181
- details.form-card summary { min-height: 48px; font-size: 14px; }
182
- .form-grid { gap: 14px; }
183
- .button-reason { display: block; max-width: 72ch; margin-top: 4px; }
184
- .task-link { padding: 12px; border: 1px solid var(--line); border-left: 3px solid var(--tone); background: var(--patina); }
185
- .task-link strong { font-size: 14px; line-height: 1.55; }
186
- .task-link:hover, .task-link[aria-current="page"] { background: var(--patina-raised); box-shadow: none; border-color: var(--tone); }
187
- .data-row, .timeline-item, .attention-item { padding: 12px; border-radius: 8px; background: var(--panel-soft); }
188
- .attention-item, .attention-item[data-severity] { --tone: var(--status-unknown); --tone-wash: var(--status-unknown-wash); border-left-color: var(--tone); }
189
- .attention-item:has(> .status-pill[data-status-icon="!"]) { --tone: var(--status-blocked); --tone-wash: var(--status-blocked-wash); }
190
- .attention-item:has(> .status-pill[data-status-icon="◆"]) { --tone: var(--status-review); --tone-wash: var(--status-review-wash); }
191
- .attention-item:has(> .status-pill[data-status-icon="▶"]) { --tone: var(--status-running); --tone-wash: var(--status-running-wash); }
192
- .attention-item:has(> .status-pill[data-status-icon="✓"]) { --tone: var(--status-done); --tone-wash: var(--status-done-wash); }
193
- .attention-item:has(> .status-pill[data-status-icon="○"]) { --tone: var(--status-idle); --tone-wash: var(--status-idle-wash); }
194
- .attention-item > .status-pill { border-color: var(--tone); }
195
- .rail-item { padding: 12px; }
196
- .evidence-rail { gap: 8px; background: transparent; }
197
- .evidence-kind { color: var(--muted); background: var(--patina-raised); border-radius: 4px; }
198
- .developer-nav { gap: 8px; margin-block: 16px; }
199
- .developer-nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; }
200
- .developer-nav a[aria-current="page"] { border-color: var(--gold); color: var(--bamboo); background: var(--patina-raised); }
201
- .task-technical > summary, .health-copy strong { font-size: 14px; }
202
- #overview-content .metric strong { font-size: 18px; }
203
- .control-stack > #refresh-button { min-height: 40px; font-size: 14px; }
204
- .governance-flow { margin: 16px 0; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-soft); }
205
- .governance-flow > figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 14px; }
206
- .governance-flow > figcaption strong { color: var(--bamboo); font-size: 14px; }
207
- .governance-flow > figcaption span { color: var(--muted); font-size: 12px; }
208
- .flow-stages { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
209
- .flow-step { position: relative; min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--patina); }
210
- .flow-step:not(:last-child)::after { content: ""; position: absolute; top: 26px; right: -19px; width: 18px; height: 18px; background: var(--muted); mask: var(--icon-next) center / contain no-repeat; }
211
- .flow-step .ui-icon { display: block; margin-bottom: 8px; color: var(--gold); }
212
- .flow-step strong { display: block; font-size: 14px; }
213
- .flow-step span, .flow-step p, .flow-step small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.55; }
214
- .flow-branch { margin: 12px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
215
- /* Responsive layouts keep readable text and the existing graph geometry. */
216
- @media (max-width: 1200px) {
217
- .theme-picker-label, .active-theme-name { display: none; }
218
- .realm-sidebar { gap: 16px; }
219
- .kingdom-status { grid-template-columns: minmax(0, 1fr); }
220
- }
221
- @media (max-width: 900px) {
222
- .realm-sidebar { flex-wrap: wrap; gap: 8px 16px; }
223
- .realm-brand { flex: 1 1 auto; }
224
- .main-nav { order: 3; width: 100%; margin: 0; justify-content: center; }
225
- .main-nav a { flex: 1 1 0; }
226
- .theme-picker { margin-left: auto; }
227
- :root, html[data-theme] { --nav-height: 124px; }
228
- .flow-stages { gap: 20px; }
229
- .flow-step { padding: 10px; }
230
- .flow-step:not(:last-child)::after { right: -19px; width: 18px; }
231
- }
232
- @media (max-width: 760px) {
233
- .realm-sidebar { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 8px 14px; gap: 6px 8px; }
234
- .realm-brand { grid-template-columns: 32px minmax(0, 1fr); gap: 8px; }
235
- .realm-seal, .realm-seal-icon { width: 32px; height: 32px; }
236
- .realm-brand h1 { font-size: 16px; }
237
- .brand-note { font-size: 12px; }
238
- .main-nav { grid-column: 1 / -1; gap: 4px; }
239
- .main-nav a, .main-nav .nav-item { min-height: 44px; padding: 8px 6px; gap: 6px; font-size: 14px; }
240
- .main-nav .ui-icon { width: 18px; height: 18px; flex-basis: 18px; }
241
- .theme-picker { width: auto; order: initial; margin: 0; padding: 2px; border-radius: 10px; }
242
- .theme-swatch { width: 40px; height: 40px; }
243
- .console-main { width: 100%; padding: 16px 14px 32px; }
244
- .organogram-branches, .organogram-branches[data-branch-count] { grid-template-columns: minmax(0, 1fr); padding: 28px 0 0; gap: 16px; }
245
- .organogram-branches[data-branch-count="0"] { padding-top: 16px; }
246
- .chancellor-card { grid-template-columns: 66px minmax(0, 1fr); padding: 12px; margin-bottom: 0; }
247
- .chancellor-card .pixel-sprite { width: 62px; height: 80px; }
248
- .territory-column, .territory-column[data-status] { padding: 14px; }
249
- .organogram-footer { grid-template-columns: minmax(0, 1fr); }
250
- .flow-stages { grid-template-columns: minmax(0, 1fr); gap: 20px; }
251
- .flow-step { padding: 12px 12px 12px 44px; }
252
- .flow-step .ui-icon { position: absolute; top: 14px; left: 12px; }
253
- .flow-step:not(:last-child)::after { top: auto; bottom: -19px; left: 16px; right: auto; width: 18px; height: 18px; transform: rotate(90deg); }
254
- .empty, .org-empty { padding: 12px; }
255
- .empty::before, .org-empty::before { flex-basis: 40px; width: 40px; }
256
- }
257
- @media (max-width: 480px) {
258
- .brand-note { display: none; }
259
- .realm-brand h1 { max-width: 8em; font-size: 15px; line-height: 1.35; white-space: normal; overflow-wrap: normal; word-break: normal; }
260
- .territory-role-network > .worker-stack, .unassigned-worker-rail .worker-stack { grid-template-columns: minmax(0, 1fr); }
261
- .task-composer-card, .governance-flow { padding: 14px; }
262
- .task-composer-shell { display: flex; flex-wrap: wrap; }
263
- .task-composer-shell input { flex-basis: 100%; }
264
- .task-territory-chip { max-width: calc(100% - 90px); }
265
- .task-composer-submit { margin-left: auto; }
266
- .status-bar .status-text, .button-reason { font-size: 12px; }
267
- }
268
- @media (prefers-reduced-motion: reduce) {
269
- *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
270
- }
2
+ export const CONSOLE_DESIGN_CSS = String.raw `
3
+ /* Theme tokens: territory identity and operational status are separate. */
4
+ :root, html[data-theme="parchment"] {
5
+ color-scheme: light;
6
+ --gate: #eee8db; --gate-deep: #f7f2e8; --patina: #fffdf7; --patina-raised: #f2eddf;
7
+ --panel-soft: #f5f0e6; --field-bg: #fffdf7; --bamboo: #302f28; --ink: #302f28;
8
+ --muted: #5d6053; --dim: #626658; --gold: #765b20; --jade: #346744;
9
+ --cinnabar: #a8393d; --danger-text: #a8393d; --line: #d0ccbc; --line-strong: #737b65;
10
+ --shadow: 0 4px 16px rgba(43, 44, 33, .06); --texture: transparent;
11
+ --status-running: #235f91; --status-review: #73528f; --status-done: #346744;
12
+ --status-blocked: #a8393d; --status-unknown: #835a16; --status-idle: #62675c;
13
+ --status-running-wash: #e9f1f8; --status-review-wash: #f1ebf7; --status-done-wash: #eaf2e9;
14
+ --status-blocked-wash: #faeaea; --status-unknown-wash: #f6eedc; --status-idle-wash: #eeefe8;
15
+ --territory-1: #5f7b63; --territory-2: #8a6785; --territory-3: #6a7b8b;
16
+ --territory-4: #997638; --territory-5: #447d80; --territory-6: #a26e59;
17
+ --focus-ring: #765b20; --connector: #737b65; --nav-height: 76px; --feedback-offset: 84px;
18
+ font-family: "Noto Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
19
+ }
20
+ html[data-theme="night"] {
21
+ color-scheme: dark;
22
+ --gate: #131d29; --gate-deep: #162231; --patina: #1e2c3d; --patina-raised: #293a4c;
23
+ --panel-soft: #1a2736; --field-bg: #172432; --bamboo: #edf2f5; --ink: #edf2f5;
24
+ --muted: #bdc9d5; --dim: #a8b8c9; --gold: #dbbf82; --jade: #a0d4ae;
25
+ --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #3a4c5c; --line-strong: #8094a5;
26
+ --shadow: 0 4px 16px rgba(0, 0, 0, .16); --focus-ring: #dbbf82; --connector: #8094a5;
27
+ }
28
+ html[data-theme="forest"] {
29
+ color-scheme: dark;
30
+ --gate: #13251f; --gate-deep: #172c24; --patina: #1c342c; --patina-raised: #254137;
31
+ --panel-soft: #1a2f27; --field-bg: #172b23; --bamboo: #f0f4ea; --ink: #f0f4ea;
32
+ --muted: #b7c8bd; --dim: #a9bcb0; --gold: #d8be7c; --jade: #a0d4ae;
33
+ --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #3b5448; --line-strong: #859b8b;
34
+ --shadow: 0 4px 16px rgba(0, 0, 0, .15); --focus-ring: #d8be7c; --connector: #859b8b;
35
+ }
36
+ html[data-theme="wine"] {
37
+ color-scheme: dark;
38
+ --gate: #281c24; --gate-deep: #2f212a; --patina: #3b2a33; --patina-raised: #4c3642;
39
+ --panel-soft: #35262f; --field-bg: #30222b; --bamboo: #f6edf0; --ink: #f6edf0;
40
+ --muted: #d2bdc7; --dim: #c5adb8; --gold: #e1c08b; --jade: #a0d4ae;
41
+ --cinnabar: #ffaba8; --danger-text: #ffaba8; --line: #604853; --line-strong: #a28792;
42
+ --shadow: 0 4px 16px rgba(0, 0, 0, .16); --focus-ring: #e1c08b; --connector: #a28792;
43
+ }
44
+ html[data-theme="night"], html[data-theme="forest"], html[data-theme="wine"] {
45
+ --status-running: #9fcbf5; --status-review: #d1b9f5; --status-done: #a0d4ae;
46
+ --status-blocked: #ffaba8; --status-unknown: #e6c184; --status-idle: #bec8c1;
47
+ --status-running-wash: rgba(159, 203, 245, .08); --status-review-wash: rgba(209, 185, 245, .08);
48
+ --status-done-wash: rgba(160, 212, 174, .08); --status-blocked-wash: rgba(255, 171, 168, .08);
49
+ --status-unknown-wash: rgba(230, 193, 132, .08); --status-idle-wash: rgba(190, 200, 193, .08);
50
+ --territory-1: #94b99e; --territory-2: #b99cb5; --territory-3: #9faebc;
51
+ --territory-4: #c3ab77; --territory-5: #89b1b3; --territory-6: #c19c86;
52
+ }
53
+ /* Typography, quiet surfaces, and visible keyboard paths. */
54
+ html, html[data-theme], body, html[data-theme] body { background: var(--gate); color: var(--bamboo); }
55
+ body { font-size: 14px; line-height: 1.6; }
56
+ h1, h2, h3, .display-title { font-family: "Noto Serif SC", "Source Han Serif SC", STSong, serif; }
57
+ button, input, textarea, select { font: inherit; }
58
+ code, kbd { font-family: Consolas, "SFMono-Regular", monospace; }
59
+ a, button, summary, input, textarea, select { -webkit-tap-highlight-color: transparent; }
60
+ a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--focus-ring); outline-offset: 3px; }
61
+ .skip-link { z-index: 100; }
62
+ [data-console-section], [data-console-page], #ledger, #management { scroll-margin-top: calc(var(--nav-height) + var(--feedback-offset)); }
63
+ .ui-icon { display: inline-block; flex: 0 0 20px; width: 20px; height: 20px; color: currentColor; vertical-align: -.2em; }
64
+ .role-insignia { width: 20px; height: 20px; color: var(--gold); vertical-align: -.2em; }
65
+ .section-kicker, .brand-kicker { font-size: 12px; line-height: 1.5; letter-spacing: .08em; }
66
+ .meta, .hint, .source-ref, .evidence-kind, .button-reason, .danger-note, .code-badge,
67
+ .session-chip, .status-glossary, .organogram-footer, .organogram-technical, .map-legend,
68
+ .attention-technical, .node-details, .theme-picker-label, .active-theme-name,
69
+ .task-composer-meta, .task-composer-heading > span, .task-territory-chip { font-size: 12px; line-height: 1.6; }
70
+ .zone-head p, .attention-heading p, .brand-note, .rail-item code, .metric span,
71
+ .health-copy small, #overview-content .metric span, .unassigned-worker-rail > header p,
72
+ .management-heading-copy small, .territory-heading p { font-size: 12px; line-height: 1.55; }
73
+ .map-heading .map-intro, .hero-copy p:not(.section-kicker), .capability-copy, .action-dock-head p,
74
+ .form-route-note, .task-summary-card p, label, .rail-item span, .data-row { font-size: 14px; line-height: 1.65; }
75
+ .ledger-page { font-size: 14px; line-height: 1.65; }
76
+ .page-heading > p:not(.section-kicker), .ledger-page .timeline-item p, .ledger-page .attention-item > p { font-size: 14px; line-height: 1.65; }
77
+ .zone, .capability-card, details.form-card, .attention-council, .task-composer-card { border: 1px solid var(--line); border-radius: 12px; background: var(--patina); box-shadow: none; }
78
+ .zone { padding: 20px; }
79
+ .zone-head { align-items: center; }
80
+ .zone-head h2, .action-dock-head h2 { font-size: 18px; }
81
+ .zone.map-page { padding: 0; border: 0; background: transparent; }
82
+ /* Compact sticky navigation; names and theme preferences remain intact. */
83
+ .realm-sidebar { position: sticky; top: 0; z-index: 50; height: auto; min-height: var(--nav-height); gap: 24px; padding: 10px clamp(20px, 4vw, 64px); background: var(--gate-deep); box-shadow: 0 1px 0 var(--line); }
84
+ .realm-brand { min-width: 0; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; }
85
+ .realm-brand h1 { font-size: 20px; line-height: 1.2; }
86
+ .realm-seal { width: 40px; height: 40px; border: 0; background: transparent; }
87
+ .realm-seal-icon { width: 36px; height: 36px; }
88
+ .realm-seal > .kingdom-brand-mark { display: block; width: 100%; height: 100%; }
89
+ .brand-note { margin-top: 3px; }
90
+ .main-nav { gap: 6px; padding: 0; margin-left: auto; overflow: visible; }
91
+ .main-nav a, .main-nav .nav-item { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 14px; border: 1px solid transparent; border-radius: 8px; color: var(--muted); font-size: 14px; white-space: nowrap; }
92
+ .main-nav a:hover, .main-nav a[aria-current="page"] { border: 1px solid var(--line-strong); background: var(--patina-raised); color: var(--bamboo); }
93
+ .main-nav a[aria-current="page"] { box-shadow: inset 0 -2px var(--gold); }
94
+ .theme-picker { flex: 0 0 auto; gap: 8px; padding: 3px; border-radius: 10px; background: transparent; }
95
+ .theme-picker-label { padding-left: 6px; }
96
+ .theme-swatch { width: 40px; height: 40px; min-height: 40px; }
97
+ .theme-swatch > span { box-shadow: none; }
98
+ .theme-swatch[aria-pressed="true"] { box-shadow: none; border-color: var(--gold); background: var(--patina-raised); }
99
+ .active-theme-name { padding-right: 6px; }
100
+ .console-main { width: 100%; margin: 0 auto; padding: 20px clamp(20px, 4vw, 64px) 48px; }
101
+ .map-heading, .page-heading { margin-bottom: 24px; }
102
+ .map-heading h2, .page-heading h2 { font-size: clamp(26px, 2.6vw, 36px); line-height: 1.3; }
103
+ .page-heading h2 { display: flex; align-items: center; gap: 10px; }
104
+ .map-heading h2 .ui-icon { width: 28px; height: 28px; flex-basis: 28px; color: var(--gold); }
105
+ /* Read feedback where it occurs; technical reasons remain selectable. */
106
+ .feedback-stack { position: sticky; top: calc(var(--nav-height) + 8px); z-index: 30; margin-bottom: 16px; border-radius: 8px; background: var(--gate); }
107
+ .feedback-stack .status-bar { margin-bottom: 0; }
108
+ .feedback-stack .status-technical:not([hidden]) { max-height: min(32vh, 220px); margin: 6px 0 0; overflow: auto; }
109
+ html:has(.feedback-stack .status-technical:not([hidden])) { --feedback-offset: 132px; }
110
+ html:has(.feedback-stack .status-technical[open]:not([hidden])) { --feedback-offset: 300px; }
111
+ .status-bar, .status-technical:not([hidden]) { position: relative; inset: auto; z-index: auto; width: 100%; max-width: none; margin: 0 0 16px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel-soft); box-shadow: none; backdrop-filter: none; pointer-events: auto; }
112
+ .status-bar { min-height: 42px; }
113
+ .status-bar .status-text { font-size: 12px; line-height: 1.6; }
114
+ .status-text[data-level="unknown"], .status-text[data-level="stale"] { color: var(--status-unknown); }
115
+ .status-text[data-level="error"] { color: var(--status-blocked); }
116
+ .status-technical:not([hidden]) { margin-top: -10px; font-size: 12px; }
117
+ .status-technical code, .owner-management code { background: var(--field-bg); border-radius: 6px; }
118
+ /* Organization hierarchy: restrained identity rules, legible role cards. */
119
+ .realm-map { min-height: 0; }
120
+ .realm-map::after { display: none; }
121
+ .organogram-connection-layer path, .territory-connection-layer path { stroke: var(--connector); stroke-width: 1.5; opacity: 1; }
122
+ .chancellor-card { width: min(100%, 560px); grid-template-columns: 80px minmax(0, 1fr) auto; gap: 12px; margin-bottom: 0; padding: 12px 16px; }
123
+ .chancellor-card .pixel-sprite { width: 76px; height: 96px; }
124
+ .chancellor-card h3 { font-size: 19px; }
125
+ .chancellor-card p, .org-node p, .worker-stack .org-node p { font-size: 12px; line-height: 1.55; }
126
+ .chancellor-card .node-task, .node-task { font-size: 14px; line-height: 1.55; }
127
+ .organogram-branches, .organogram-branches[data-branch-count] { gap: 20px; padding-top: 32px; }
128
+ .organogram-branches[data-branch-count="0"] { padding-top: 16px; }
129
+ .territory-column, .territory-column[data-status] { padding: 16px; background: var(--panel-soft); border: 1px solid var(--line); border-top: 3px solid var(--territory-color); border-radius: 12px; box-shadow: none; }
130
+ .territory-heading { padding-bottom: 10px; border-color: var(--line); }
131
+ .territory-heading h3 { font-size: 18px; line-height: 1.4; }
132
+ .territory-heading h3::before { width: 8px; height: 8px; border-radius: 2px; }
133
+ .territory-role-network { gap: 24px; margin-top: 12px; padding-top: 0; }
134
+ .chancellor-card, .org-node, .org-node[data-status], .task-summary-card { border: 1px solid var(--line); border-left: 3px solid var(--tone); border-radius: 10px; background: var(--patina); box-shadow: none; }
135
+ .org-node[data-stage-evidence="indeterminate"] { background: var(--patina); border-left-color: var(--status-unknown); }
136
+ .org-node[data-stage-evidence="unavailable"] { opacity: 1; }
137
+ .org-node[data-role="supervisor"] { grid-template-columns: 68px minmax(0, 1fr); min-height: 108px; padding: 12px; }
138
+ .org-node[data-role="supervisor"] .pixel-sprite { width: 68px; height: 88px; }
139
+ .worker-stack .org-node, .org-node[data-role="worker"] { grid-template-columns: 56px minmax(0, 1fr); min-height: 96px; padding: 10px 12px; }
140
+ .org-node[data-role="worker"] .pixel-sprite { width: 56px; height: 74px; }
141
+ .org-node h4, .worker-stack .org-node h4 { font: 700 15px/1.5 "Noto Sans SC", "Microsoft YaHei UI", sans-serif; }
142
+ .org-node[data-stage-evidence="unbound"], .org-node[data-stage-evidence="absent"] { grid-template-columns: minmax(0, 1fr); }
143
+ .org-node .node-details p, .org-node .node-details code { font-size: 12px; }
144
+ .node-details { border-top-color: var(--line); }
145
+ .organogram-footer { margin-top: 16px; gap: 12px 20px; }
146
+ .unassigned-worker-rail { padding: 12px; box-shadow: none; }
147
+ /* SVG masks are decorative; adjacent text remains the semantic label. */
148
+ [data-status-icon="!"] { --status-symbol: var(--icon-error); }
149
+ [data-status-icon="?"] { --status-symbol: var(--icon-unknown); }
150
+ [data-status-icon="◆"] { --status-symbol: var(--icon-review); }
151
+ [data-status-icon="▶"] { --status-symbol: var(--icon-run); }
152
+ [data-status-icon="✓"] { --status-symbol: var(--icon-accept); }
153
+ [data-status-icon="○"] { --status-symbol: var(--icon-idle); }
154
+ .status-pill::before, .task-link .task-status::before, .territory-alert[data-status]::before { content: ""; display: inline-block; flex: 0 0 14px; width: 14px; height: 14px; margin: 0; border-radius: 0; color: inherit; background: currentColor; mask: var(--status-symbol, var(--icon-unknown)) center / contain no-repeat; vertical-align: -.15em; }
155
+ .status-pill, .task-link .task-status { display: inline-flex; align-items: center; gap: 5px; color: var(--tone, var(--status-unknown)); font-size: 12px; line-height: 1.5; }
156
+ .status-pill { padding: 3px 7px; border-color: var(--line); background: var(--tone-wash, var(--status-unknown-wash)); }
157
+ .territory-alert, .territory-alert[data-status] { min-height: 32px; margin: 10px 0; padding: 6px 8px; border-color: var(--line); background: var(--patina); color: var(--alert-tone); font-size: 12px; line-height: 1.6; }
158
+ .territory-alert span::before { display: none; }
159
+ .org-node h4::before, .chancellor-card .section-kicker::before { content: ""; display: inline-block; width: 16px; height: 16px; margin-right: 6px; background: var(--gold); mask: var(--role-symbol) center / contain no-repeat; vertical-align: -.17em; }
160
+ .org-node[data-role="supervisor"] { --role-symbol: var(--icon-supervisor); }
161
+ .org-node[data-role="worker"] { --role-symbol: var(--icon-worker); }
162
+ .chancellor-card { --role-symbol: var(--icon-chancellor); }
163
+ .empty, .org-empty { display: flex; align-items: center; gap: 12px; min-height: 48px; margin: 0; padding: 12px; border: 1px dashed var(--line-strong); border-radius: 10px; background: var(--panel-soft); color: var(--muted); font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
164
+ .empty::before, .org-empty::before { content: ""; flex: 0 0 32px; width: 32px; height: 28px; background: var(--muted); mask: var(--empty-illustration-bg) center / contain no-repeat; }
165
+ #territory-map-list > .empty { min-height: 132px; justify-content: center; }
166
+ #territory-map-list > .empty::before { flex-basis: 80px; width: 80px; height: 68px; }
167
+ .metric-grid > .empty { grid-column: 1 / -1; }
168
+ .metric-grid > .empty::before { display: none; }
169
+ /* Forms, ledger evidence, and the five-stage governance explanation. */
170
+ input, textarea, select { min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--field-bg); }
171
+ input::placeholder, textarea::placeholder { color: var(--dim); opacity: 1; }
172
+ .primary, .secondary, .refresh { min-height: 40px; border-radius: 8px; font-size: 14px; }
173
+ .primary { color: var(--bamboo); border-color: var(--line-strong); background: var(--patina-raised); }
174
+ .primary:hover:not(:disabled) { border-color: var(--gold); background: var(--patina-raised); }
175
+ .primary.danger { color: var(--status-blocked); border-color: var(--status-blocked); background: var(--status-blocked-wash); }
176
+ button:disabled, .primary:disabled { opacity: 1; color: var(--dim); border-color: var(--line); background: var(--panel-soft); cursor: not-allowed; }
177
+ .task-composer-shell { border-radius: 10px; box-shadow: none; }
178
+ .task-composer-shell input:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: -2px; }
179
+ .task-composer-card { padding: 20px; }
180
+ details.form-card { padding: 0 16px 14px; }
181
+ details.form-card summary { min-height: 48px; font-size: 14px; }
182
+ .form-grid { gap: 14px; }
183
+ .button-reason { display: block; max-width: 72ch; margin-top: 4px; }
184
+ .task-link { padding: 12px; border: 1px solid var(--line); border-left: 3px solid var(--tone); background: var(--patina); }
185
+ .task-link strong { font-size: 14px; line-height: 1.55; }
186
+ .task-link:hover, .task-link[aria-current="page"] { background: var(--patina-raised); box-shadow: none; border-color: var(--tone); }
187
+ .data-row, .timeline-item, .attention-item { padding: 12px; border-radius: 8px; background: var(--panel-soft); }
188
+ .attention-item, .attention-item[data-severity] { --tone: var(--status-unknown); --tone-wash: var(--status-unknown-wash); border-left-color: var(--tone); }
189
+ .attention-item:has(> .status-pill[data-status-icon="!"]) { --tone: var(--status-blocked); --tone-wash: var(--status-blocked-wash); }
190
+ .attention-item:has(> .status-pill[data-status-icon="◆"]) { --tone: var(--status-review); --tone-wash: var(--status-review-wash); }
191
+ .attention-item:has(> .status-pill[data-status-icon="▶"]) { --tone: var(--status-running); --tone-wash: var(--status-running-wash); }
192
+ .attention-item:has(> .status-pill[data-status-icon="✓"]) { --tone: var(--status-done); --tone-wash: var(--status-done-wash); }
193
+ .attention-item:has(> .status-pill[data-status-icon="○"]) { --tone: var(--status-idle); --tone-wash: var(--status-idle-wash); }
194
+ .attention-item > .status-pill { border-color: var(--tone); }
195
+ .rail-item { padding: 12px; }
196
+ .evidence-rail { gap: 8px; background: transparent; }
197
+ .evidence-kind { color: var(--muted); background: var(--patina-raised); border-radius: 4px; }
198
+ .developer-nav { gap: 8px; margin-block: 16px; }
199
+ .developer-nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; }
200
+ .developer-nav a[aria-current="page"] { border-color: var(--gold); color: var(--bamboo); background: var(--patina-raised); }
201
+ .task-technical > summary, .health-copy strong { font-size: 14px; }
202
+ #overview-content .metric strong { font-size: 18px; }
203
+ .control-stack > #refresh-button { min-height: 40px; font-size: 14px; }
204
+ .governance-flow { margin: 16px 0; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-soft); }
205
+ .governance-flow > figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin-bottom: 14px; }
206
+ .governance-flow > figcaption strong { color: var(--bamboo); font-size: 14px; }
207
+ .governance-flow > figcaption span { color: var(--muted); font-size: 12px; }
208
+ .flow-stages { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
209
+ .flow-step { position: relative; min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--patina); }
210
+ .flow-step:not(:last-child)::after { content: ""; position: absolute; top: 26px; right: -19px; width: 18px; height: 18px; background: var(--muted); mask: var(--icon-next) center / contain no-repeat; }
211
+ .flow-step .ui-icon { display: block; margin-bottom: 8px; color: var(--gold); }
212
+ .flow-step strong { display: block; font-size: 14px; }
213
+ .flow-step span, .flow-step p, .flow-step small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.55; }
214
+ .flow-branch { margin: 12px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
215
+ /* Responsive layouts keep readable text and the existing graph geometry. */
216
+ @media (max-width: 1200px) {
217
+ .theme-picker-label, .active-theme-name { display: none; }
218
+ .realm-sidebar { gap: 16px; }
219
+ .kingdom-status { grid-template-columns: minmax(0, 1fr); }
220
+ }
221
+ @media (max-width: 900px) {
222
+ .realm-sidebar { flex-wrap: wrap; gap: 8px 16px; }
223
+ .realm-brand { flex: 1 1 auto; }
224
+ .main-nav { order: 3; width: 100%; margin: 0; justify-content: center; }
225
+ .main-nav a { flex: 1 1 0; }
226
+ .theme-picker { margin-left: auto; }
227
+ :root, html[data-theme] { --nav-height: 124px; }
228
+ .flow-stages { gap: 20px; }
229
+ .flow-step { padding: 10px; }
230
+ .flow-step:not(:last-child)::after { right: -19px; width: 18px; }
231
+ }
232
+ @media (max-width: 760px) {
233
+ .realm-sidebar { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 8px 14px; gap: 6px 8px; }
234
+ .realm-brand { grid-template-columns: 32px minmax(0, 1fr); gap: 8px; }
235
+ .realm-seal, .realm-seal-icon { width: 32px; height: 32px; }
236
+ .realm-brand h1 { font-size: 16px; }
237
+ .brand-note { font-size: 12px; }
238
+ .main-nav { grid-column: 1 / -1; gap: 4px; }
239
+ .main-nav a, .main-nav .nav-item { min-height: 44px; padding: 8px 6px; gap: 6px; font-size: 14px; }
240
+ .main-nav .ui-icon { width: 18px; height: 18px; flex-basis: 18px; }
241
+ .theme-picker { width: auto; order: initial; margin: 0; padding: 2px; border-radius: 10px; }
242
+ .theme-swatch { width: 40px; height: 40px; }
243
+ .console-main { width: 100%; padding: 16px 14px 32px; }
244
+ .organogram-branches, .organogram-branches[data-branch-count] { grid-template-columns: minmax(0, 1fr); padding: 28px 0 0; gap: 16px; }
245
+ .organogram-branches[data-branch-count="0"] { padding-top: 16px; }
246
+ .chancellor-card { grid-template-columns: 66px minmax(0, 1fr); padding: 12px; margin-bottom: 0; }
247
+ .chancellor-card .pixel-sprite { width: 62px; height: 80px; }
248
+ .territory-column, .territory-column[data-status] { padding: 14px; }
249
+ .organogram-footer { grid-template-columns: minmax(0, 1fr); }
250
+ .flow-stages { grid-template-columns: minmax(0, 1fr); gap: 20px; }
251
+ .flow-step { padding: 12px 12px 12px 44px; }
252
+ .flow-step .ui-icon { position: absolute; top: 14px; left: 12px; }
253
+ .flow-step:not(:last-child)::after { top: auto; bottom: -19px; left: 16px; right: auto; width: 18px; height: 18px; transform: rotate(90deg); }
254
+ .empty, .org-empty { padding: 12px; }
255
+ .empty::before, .org-empty::before { flex-basis: 40px; width: 40px; }
256
+ }
257
+ @media (max-width: 480px) {
258
+ .brand-note { display: none; }
259
+ .realm-brand h1 { max-width: 8em; font-size: 15px; line-height: 1.35; white-space: normal; overflow-wrap: normal; word-break: normal; }
260
+ .territory-role-network > .worker-stack, .unassigned-worker-rail .worker-stack { grid-template-columns: minmax(0, 1fr); }
261
+ .task-composer-card, .governance-flow { padding: 14px; }
262
+ .task-composer-shell { display: flex; flex-wrap: wrap; }
263
+ .task-composer-shell input { flex-basis: 100%; }
264
+ .task-territory-chip { max-width: calc(100% - 90px); }
265
+ .task-composer-submit { margin-left: auto; }
266
+ .status-bar .status-text, .button-reason { font-size: 12px; }
267
+ }
268
+ @media (prefers-reduced-motion: reduce) {
269
+ *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
270
+ }
271
271
  `;
272
272
  //# sourceMappingURL=visual-system.js.map