cornfield 0.21.0 → 0.23.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.
@@ -1,136 +1,11 @@
1
1
  /*
2
- * The topology explorer's stylesheet (explorer/index.html). Plain CSS, no framework: the palette is local
3
- * (--hx-*), and the fonts are the system's (nothing is fetched from outside). Classes are prefixed hx-.
4
- *
5
- * Light and dark (MAP-01). Every colour that depends on the ground is a token here. The dark values are
6
- * the explorer's own; the light ones, under [data-theme="light"] (theme-boot.js and theme.js set it from
7
- * the system and the header toggle), are derived from them, the same way theme-model.js derives the map's:
8
- * the slate greys mirror (300 <-> 700 ...), so text keeps its distance from the ground; each accent keeps
9
- * its hue and takes its deeper Tailwind step, at least 4.5:1 on the light ground (the 700s); surfaces
10
- * become white glass with a dark hairline. A colour on a strong accent (white on indigo) is not a token.
2
+ * The topology explorer's stylesheet (explorer/index.html). Plain CSS, no framework: every colour, font, size,
3
+ * radius, border width, shadow and spacing is a --corn-* token from explorer/tokens.css, loaded before this file
4
+ * (the contract is docs/theming.md, and test/explorer/tokens.test.js fails on any literal left here). Light and
5
+ * dark are tokens.css's business: nothing below names a theme, so a brand that redefines the tokens restyles all
6
+ * of it. The fonts are the system's (nothing is fetched from outside). Classes are prefixed hx-.
11
7
  */
12
8
 
13
- :root {
14
- --pop-font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
15
- --pop-font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
16
- --hx-bg: #090d16;
17
- --hx-text: #f8fafc;
18
- --hx-ink: #fff; /* the strongest text on a surface */
19
- --hx-text-1: #f1f5f9; /* titles */
20
- --hx-text-2: #e2e8f0; /* names */
21
- --hx-slate-300: #cbd5e1;
22
- --hx-slate-400: #94a3b8;
23
- --hx-slate-500: #64748b;
24
- --hx-slate-600: #475569;
25
- --hx-slate-700: #334155;
26
- --hx-slate-800: #1e293b;
27
- --hx-slate-900: #0f172a;
28
- --hx-slate-950: #020617;
29
- --hx-indigo: #818cf8;
30
- --hx-indigo-strong: #4f46e5;
31
- --hx-emerald: #34d399;
32
- --hx-amber: #fcd34d;
33
- --hx-sky: #7dd3fc;
34
- --hx-pink: #f9a8d4;
35
- --hx-fuchsia: #f0abfc;
36
- --hx-fuchsia-strong: #f5d0fe;
37
- --hx-red: #fca5a5;
38
- --hx-code: #fde68a;
39
- --hx-orange-text: #fdba74;
40
- --hx-orange-strong: #fed7aa;
41
- --hx-teal-text: #5eead4;
42
- --hx-teal-strong: #99f6e4;
43
- --hx-violet-text: #c4b5fd;
44
- --hx-green-text: #86efac;
45
- --hx-lime-text: #d9f99d;
46
-
47
- --gradient-primary: linear-gradient(135deg, #4299e1 0%, #818cf8 50%, #e53e3e 100%);
48
- --bg-gradient: radial-gradient(circle at 14% 18%, rgba(66, 153, 225, 0.28) 0%, transparent 45%),
49
- radial-gradient(circle at 86% 82%, rgba(229, 62, 62, 0.22) 0%, transparent 45%),
50
- radial-gradient(circle at 50% 50%, rgba(66, 153, 225, 0.10) 0%, transparent 60%),
51
- var(--hx-bg);
52
-
53
- /* Glass surfaces, and the controls, wells and hairlines on them */
54
- --surface-glass: rgba(26, 34, 52, 0.72);
55
- --surface-glass-header: rgba(11, 15, 23, 0.88);
56
- --border-glass: rgba(255, 255, 255, 0.14);
57
- --border-subtle: rgba(255, 255, 255, 0.08);
58
- --glass-blur: blur(16px);
59
- --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.45);
60
- --hx-control: rgba(30, 41, 59, 0.8); /* a button, a toggle row */
61
- --hx-control-hover: rgba(51, 65, 85, 0.8);
62
- --hx-control-off: rgba(15, 23, 42, 0.4);
63
- --hx-well: rgba(2, 6, 23, 0.8); /* an input, a property box, a field */
64
- --hx-well-soft: rgba(2, 6, 23, 0.55);
65
- --hx-line: rgba(255, 255, 255, 0.1); /* a border on a surface */
66
- --hx-line-soft: rgba(255, 255, 255, 0.07); /* a divider, a hover tint */
67
- --hx-scroll: rgba(255, 255, 255, 0.18);
68
- --hx-scroll-hover: rgba(255, 255, 255, 0.28);
69
- --hx-swatch-solid: rgba(255, 255, 255, 0.6);
70
- --hx-backdrop: rgba(0, 0, 0, 0.6);
71
- --hx-glyph-mix: 100%; /* how much of a panel glyph's own colour is kept (.hx-glyph) */
72
-
73
- color-scheme: dark;
74
- }
75
-
76
- :root[data-theme="light"] {
77
- --hx-bg: #f4f6fa;
78
- --hx-text: #0f172a;
79
- --hx-ink: #0f172a;
80
- --hx-text-1: #0f172a;
81
- --hx-text-2: #1e293b;
82
- --hx-slate-300: #334155;
83
- --hx-slate-400: #475569;
84
- --hx-slate-500: #64748b;
85
- --hx-slate-600: #94a3b8;
86
- --hx-slate-700: #cbd5e1;
87
- --hx-slate-800: #e2e8f0;
88
- --hx-slate-900: #f1f5f9;
89
- --hx-slate-950: #f8fafc;
90
- --hx-indigo: #4f46e5;
91
- --hx-indigo-strong: #4f46e5;
92
- --hx-emerald: #047857;
93
- --hx-amber: #854d0e;
94
- --hx-sky: #0369a1;
95
- --hx-pink: #be185d;
96
- --hx-fuchsia: #a21caf;
97
- --hx-fuchsia-strong: #86198f;
98
- --hx-red: #b91c1c;
99
- --hx-code: #854d0e;
100
- --hx-orange-text: #c2410c;
101
- --hx-orange-strong: #9a3412;
102
- --hx-teal-text: #0f766e;
103
- --hx-teal-strong: #115e59;
104
- --hx-violet-text: #6d28d9;
105
- --hx-green-text: #15803d;
106
- --hx-lime-text: #3f6212;
107
-
108
- --gradient-primary: linear-gradient(135deg, #2563eb 0%, #4f46e5 50%, #dc2626 100%);
109
- --bg-gradient: radial-gradient(circle at 14% 18%, rgba(66, 153, 225, 0.12) 0%, transparent 45%),
110
- radial-gradient(circle at 86% 82%, rgba(229, 62, 62, 0.07) 0%, transparent 45%),
111
- var(--hx-bg);
112
-
113
- --surface-glass: rgba(255, 255, 255, 0.8);
114
- --surface-glass-header: rgba(255, 255, 255, 0.9);
115
- --border-glass: rgba(15, 23, 42, 0.12);
116
- --border-subtle: rgba(15, 23, 42, 0.08);
117
- --glass-shadow: 0 8px 28px 0 rgba(15, 23, 42, 0.12);
118
- --hx-control: rgba(241, 245, 249, 0.92);
119
- --hx-control-hover: rgba(226, 232, 240, 0.95);
120
- --hx-control-off: rgba(241, 245, 249, 0.5);
121
- --hx-well: rgba(255, 255, 255, 0.92);
122
- --hx-well-soft: rgba(248, 250, 252, 0.85);
123
- --hx-line: rgba(15, 23, 42, 0.14);
124
- --hx-line-soft: rgba(15, 23, 42, 0.07);
125
- --hx-scroll: rgba(15, 23, 42, 0.2);
126
- --hx-scroll-hover: rgba(15, 23, 42, 0.32);
127
- --hx-swatch-solid: rgba(15, 23, 42, 0.45);
128
- --hx-backdrop: rgba(15, 23, 42, 0.35);
129
- --hx-glyph-mix: 45%;
130
-
131
- color-scheme: light;
132
- }
133
-
134
9
  *, *::before, *::after { box-sizing: border-box; }
135
10
  [hidden] { display: none !important; }
136
11
 
@@ -141,10 +16,11 @@ body {
141
16
  width: 100vw;
142
17
  height: 100dvh;
143
18
  overflow: hidden;
144
- background: var(--bg-gradient);
19
+ background-color: var(--corn-ground);
20
+ background-image: var(--corn-ground-image);
145
21
  background-attachment: fixed;
146
- color: var(--hx-text);
147
- font-family: var(--pop-font-body);
22
+ color: var(--corn-text);
23
+ font-family: var(--corn-font);
148
24
  -webkit-font-smoothing: antialiased;
149
25
  user-select: none;
150
26
  touch-action: none;
@@ -154,20 +30,20 @@ button { font: inherit; color: inherit; cursor: pointer; }
154
30
  h1, h2, h3, p { margin: 0; }
155
31
 
156
32
  .glass {
157
- background: var(--surface-glass);
158
- backdrop-filter: var(--glass-blur);
159
- -webkit-backdrop-filter: var(--glass-blur);
160
- border: 1px solid var(--border-glass);
161
- box-shadow: var(--glass-shadow);
33
+ background: var(--corn-surface-1);
34
+ backdrop-filter: blur(var(--corn-blur));
35
+ -webkit-backdrop-filter: blur(var(--corn-blur));
36
+ border: var(--corn-border) solid var(--corn-line);
37
+ box-shadow: var(--corn-shadow);
162
38
  }
163
39
  .glass-header {
164
- background: var(--surface-glass-header);
165
- backdrop-filter: var(--glass-blur);
166
- -webkit-backdrop-filter: var(--glass-blur);
167
- border-bottom: 1px solid var(--border-glass);
40
+ background: color-mix(in srgb, var(--corn-ground) 88%, transparent);
41
+ backdrop-filter: blur(var(--corn-blur));
42
+ -webkit-backdrop-filter: blur(var(--corn-blur));
43
+ border-bottom: var(--corn-border) solid var(--corn-line);
168
44
  }
169
45
  .gradient-text {
170
- background: var(--gradient-primary);
46
+ background: var(--corn-brand-gradient);
171
47
  -webkit-background-clip: text;
172
48
  background-clip: text;
173
49
  -webkit-text-fill-color: transparent;
@@ -176,26 +52,28 @@ h1, h2, h3, p { margin: 0; }
176
52
 
177
53
  ::-webkit-scrollbar { width: 5px; height: 5px; }
178
54
  ::-webkit-scrollbar-track { background: transparent; }
179
- ::-webkit-scrollbar-thumb { background: var(--hx-scroll); border-radius: 9999px; }
180
- ::-webkit-scrollbar-thumb:hover { background: var(--hx-scroll-hover); }
55
+ ::-webkit-scrollbar-thumb { background: color-mix(in srgb, var(--corn-text) 18%, transparent); border-radius: var(--corn-radius-pill); }
56
+ ::-webkit-scrollbar-thumb:hover { background: color-mix(in srgb, var(--corn-text) 28%, transparent); }
181
57
 
182
58
  /* ---- text helpers used by the panel markup ---------------------------------------------- */
183
- .hx-faint { color: var(--hx-slate-400); }
184
- .hx-mono { font-family: var(--pop-font-mono); font-size: 10px; }
185
- .hx-strong { color: var(--hx-slate-300); }
59
+ .hx-faint { color: var(--corn-text-3); }
60
+ .hx-mono { font-family: var(--corn-mono); font-size: var(--corn-text-2xs); }
61
+ .hx-strong { color: var(--corn-text-2); }
186
62
  .hx-bold { font-weight: 700; }
187
- .hx-name { color: var(--hx-text-2); }
188
- .hx-accent { color: var(--hx-indigo); }
189
- .hx-good { color: var(--hx-emerald); }
190
- .hx-warn { color: var(--hx-amber); }
191
- .hx-rom { color: var(--hx-fuchsia); }
192
- .hx-link { color: var(--hx-sky); text-decoration: underline; }
193
- .hx-link-faint { color: var(--hx-slate-500); font-family: var(--pop-font-mono); font-size: 9px; }
194
- .hx-link-faint:hover { color: var(--hx-amber); }
195
- .hx-code { color: var(--hx-code); font-family: var(--pop-font-mono); font-size: 10px; }
196
- .hx-var { color: var(--hx-pink); font-family: var(--pop-font-mono); font-size: 10px; background: var(--hx-well-soft); padding: 0 4px; border-radius: 3px; }
197
- .hx-chips { display: flex; flex-wrap: wrap; gap: 4px; padding-top: 4px; }
198
- .hx-pt { padding-top: 8px; }
63
+ .hx-name { color: var(--corn-text-2); }
64
+ .hx-accent { color: var(--corn-accent-text); }
65
+ .hx-good { color: var(--corn-ok); }
66
+ .hx-warn { color: var(--corn-warn); }
67
+ .hx-rom { color: var(--corn-hue-fuchsia); }
68
+ .hx-link { color: var(--corn-info); text-decoration: underline; }
69
+ .hx-link-faint { color: var(--corn-text-3); font-family: var(--corn-mono); font-size: var(--corn-text-2xs); }
70
+ .hx-link-faint:hover { color: var(--corn-warn); }
71
+ .hx-code { color: var(--corn-warn); font-family: var(--corn-mono); font-size: var(--corn-text-2xs); }
72
+ .hx-var { color: var(--corn-hue-pink); font-family: var(--corn-mono); font-size: var(--corn-text-2xs); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); padding: 0 var(--corn-space-1); border-radius: var(--corn-radius-xs); }
73
+ .hx-chips { display: flex; flex-wrap: wrap; gap: var(--corn-space-1); padding-top: var(--corn-space-1); }
74
+ .hx-pt { padding-top: var(--corn-space-3); }
75
+ /* Headings and titles take the display family (the same as the body unless a brand sets it) */
76
+ .hx-title, .hx-drawer-title, .hx-block-title, .hx-menu-title, .hx-confirm-title, .hx-mockup-title { font-family: var(--corn-font-display); }
199
77
 
200
78
  /* ---- header ------------------------------------------------------------------------------ */
201
79
  .hx-header {
@@ -204,21 +82,21 @@ h1, h2, h3, p { margin: 0; }
204
82
  display: flex;
205
83
  align-items: center;
206
84
  justify-content: space-between;
207
- gap: 8px;
208
- padding: 0 10px;
85
+ gap: var(--corn-space-3);
86
+ padding: 0 var(--corn-space-3);
209
87
  z-index: 20;
210
- background: var(--surface-glass-header);
211
- backdrop-filter: var(--glass-blur);
212
- -webkit-backdrop-filter: var(--glass-blur);
213
- border-bottom: 1px solid var(--border-glass);
88
+ background: color-mix(in srgb, var(--corn-ground) 88%, transparent);
89
+ backdrop-filter: blur(var(--corn-blur));
90
+ -webkit-backdrop-filter: blur(var(--corn-blur));
91
+ border-bottom: var(--corn-border) solid var(--corn-line);
214
92
  }
215
- .hx-header-left, .hx-header-right { display: flex; align-items: center; gap: 8px; min-width: 0; }
216
- .hx-header-right { flex: none; gap: 4px; }
217
- @media (min-width: 640px) { .hx-header { padding: 0 16px; } .hx-header-left { gap: 12px; } .hx-header-right { gap: 8px; } }
93
+ .hx-header-left, .hx-header-right { display: flex; align-items: center; gap: var(--corn-space-3); min-width: 0; }
94
+ .hx-header-right { flex: none; gap: var(--corn-space-1); }
95
+ @media (min-width: 640px) { .hx-header { padding: 0 var(--corn-space-5); } .hx-header-left { gap: var(--corn-space-4); } .hx-header-right { gap: var(--corn-space-3); } }
218
96
 
219
- .hx-brand { display: flex; align-items: center; gap: 8px; flex: none; padding: 0; border: 0; background: none; }
220
- .hx-title { font-size: 14px; font-weight: 900; letter-spacing: var(--letter-sm, -0.025em); }
221
- .hx-live-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--hx-emerald); box-shadow: 0 0 8px rgba(52, 211, 153, 0.5); animation: hx-pulse 2s ease-in-out infinite; flex: none; }
97
+ .hx-brand { display: flex; align-items: center; gap: var(--corn-space-3); flex: none; padding: 0; border: 0; background: none; }
98
+ .hx-title { font-size: var(--corn-text-base); font-weight: 900; letter-spacing: -0.025em; }
99
+ .hx-live-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--corn-ok); box-shadow: 0 0 var(--corn-glow) color-mix(in srgb, var(--corn-ok) 50%, transparent); animation: hx-pulse 2s ease-in-out infinite; flex: none; }
222
100
  .hx-live-dot--ping { width: 8px; height: 8px; animation-name: hx-ping; }
223
101
  @keyframes hx-pulse { 50% { opacity: 0.5; } }
224
102
  @keyframes hx-ping { 0% { transform: scale(1); opacity: 1; } 75%, 100% { transform: scale(1.8); opacity: 0.2; } }
@@ -227,62 +105,62 @@ h1, h2, h3, p { margin: 0; }
227
105
  .hx-btn {
228
106
  display: inline-flex;
229
107
  align-items: center;
230
- gap: 6px;
231
- padding: 4px 10px;
232
- border-radius: 8px;
233
- border: 1px solid var(--hx-line);
234
- background: var(--hx-control);
235
- color: var(--hx-slate-300);
236
- font-size: 11px;
108
+ gap: var(--corn-space-2);
109
+ padding: var(--corn-space-1) var(--corn-space-3);
110
+ border-radius: var(--corn-radius-sm);
111
+ border: var(--corn-border) solid var(--corn-line);
112
+ background: var(--corn-surface-2);
113
+ color: var(--corn-text-2);
114
+ font-size: var(--corn-text-xs);
237
115
  font-weight: 600;
238
116
  transition: background 0.15s, color 0.15s, border-color 0.15s;
239
117
  white-space: nowrap;
240
118
  }
241
- .hx-btn:hover { background: var(--hx-control-hover); color: var(--hx-ink); }
242
- .hx-btn:focus-visible, .hx-toggle-row:focus-visible, .hx-zoom-btn:focus-visible, .hx-textbtn:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
243
- .hx-btn--active, .hx-btn--active:hover { background: var(--hx-indigo-strong); border-color: var(--hx-indigo); color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4); }
119
+ .hx-btn:hover { background: var(--corn-surface-3); color: var(--corn-text); }
120
+ .hx-btn:focus-visible, .hx-toggle-row:focus-visible, .hx-zoom-btn:focus-visible, .hx-textbtn:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
121
+ .hx-btn--active, .hx-btn--active:hover { background: var(--corn-accent); border-color: var(--corn-accent-text); color: var(--corn-text-on-accent); box-shadow: var(--corn-shadow-sm); }
244
122
  .hx-btn--dim { opacity: 0.55; }
245
- .hx-btn--quiet { font-weight: 500; color: var(--hx-slate-400); }
246
- .hx-btn--icon { width: 28px; height: 28px; padding: 0; justify-content: center; font-size: 14px; }
247
- .hx-btn--preset { border-color: rgba(251, 146, 60, 0.35); color: var(--hx-orange-text); }
248
- .hx-btn--preset:hover { background: rgba(251, 146, 60, 0.15); color: var(--hx-orange-strong); }
249
- .hx-btn--preset.hx-btn--active { background: #c2410c; border-color: #fb923c; color: #fff; }
250
- .hx-btn--rom { width: 100%; justify-content: center; margin-top: 4px; padding: 6px; background: rgba(217, 70, 239, 0.2); border-color: rgba(232, 121, 249, 0.4); color: var(--hx-fuchsia-strong); font-weight: 700; }
251
- .hx-btn--rom:hover { background: rgba(217, 70, 239, 0.3); }
252
- .hx-btn--copy { padding: 10px 14px; border-radius: 12px; border: 0; }
123
+ .hx-btn--quiet { font-weight: 500; color: var(--corn-text-3); }
124
+ .hx-btn--icon { width: 28px; height: 28px; padding: 0; justify-content: center; font-size: var(--corn-text-base); }
125
+ .hx-btn--preset { border-color: color-mix(in srgb, var(--corn-hue-orange) 35%, transparent); color: var(--corn-hue-orange); }
126
+ .hx-btn--preset:hover { background: color-mix(in srgb, var(--corn-hue-orange) 15%, transparent); color: color-mix(in srgb, var(--corn-hue-orange) 60%, var(--corn-text)); }
127
+ .hx-btn--preset.hx-btn--active { background: var(--corn-hue-orange); border-color: var(--corn-hue-orange); color: var(--corn-ground); }
128
+ .hx-btn--rom { width: 100%; justify-content: center; margin-top: var(--corn-space-1); padding: var(--corn-space-2); background: color-mix(in srgb, var(--corn-hue-fuchsia) 20%, transparent); border-color: color-mix(in srgb, var(--corn-hue-fuchsia) 40%, transparent); color: color-mix(in srgb, var(--corn-hue-fuchsia) 60%, var(--corn-text)); font-weight: 700; }
129
+ .hx-btn--rom:hover { background: color-mix(in srgb, var(--corn-hue-fuchsia) 30%, transparent); }
130
+ .hx-btn--copy { padding: var(--corn-space-3) var(--corn-space-4); border-radius: var(--corn-radius); border: 0; }
253
131
 
254
132
  .hx-dots { display: inline-flex; }
255
- .hx-dots span { width: 8px; height: 8px; border-radius: 50%; box-shadow: 0 0 0 1px #000; margin-left: -4px; }
133
+ .hx-dots span { width: 8px; height: 8px; border-radius: 50%; box-shadow: 0 0 0 var(--corn-border) var(--corn-ground); margin-left: calc(var(--corn-space-1) * -1); }
256
134
  .hx-dots span:first-child { margin-left: 0; }
257
135
 
258
136
  .hx-input {
259
137
  width: 128px;
260
- padding: 4px 8px 4px 26px;
261
- border-radius: 8px;
262
- border: 1px solid var(--hx-line);
263
- background: var(--hx-well) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E") no-repeat 8px center;
264
- color: var(--hx-ink);
138
+ padding: var(--corn-space-1) var(--corn-space-3) var(--corn-space-1) var(--corn-space-6);
139
+ border-radius: var(--corn-radius-sm);
140
+ border: var(--corn-border) solid var(--corn-line);
141
+ background: color-mix(in srgb, var(--corn-ground) 80%, transparent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' viewBox='0 0 24 24' stroke='%2364748b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E") no-repeat 8px center;
142
+ color: var(--corn-text);
265
143
  font: inherit;
266
- font-size: 12px;
144
+ font-size: var(--corn-text-sm);
267
145
  outline: none;
268
146
  transition: width 0.2s, border-color 0.2s;
269
147
  user-select: text;
270
148
  }
271
- .hx-input:focus { width: 208px; border-color: #6366f1; }
272
- .hx-input::placeholder { color: var(--hx-slate-500); }
149
+ .hx-input:focus { width: 208px; border-color: var(--corn-accent-hover); }
150
+ .hx-input::placeholder { color: var(--corn-text-3); }
273
151
  .hx-input--wide, .hx-input--wide:focus { width: 100%; flex: 1; }
274
152
 
275
- .hx-zoom { display: none; align-items: center; padding: 2px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well); }
276
- .hx-zoom-btn { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 6px; background: none; color: var(--hx-slate-400); font-weight: 700; font-size: 12px; }
277
- .hx-zoom-btn:hover { background: var(--hx-slate-800); color: var(--hx-ink); }
278
- .hx-zoom-btn--accent { color: var(--hx-indigo); }
153
+ .hx-zoom { display: none; align-items: center; padding: calc(var(--corn-space-1) / 2); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); }
154
+ .hx-zoom-btn { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: var(--corn-radius-sm); background: none; color: var(--corn-text-3); font-weight: 700; font-size: var(--corn-text-sm); }
155
+ .hx-zoom-btn:hover { background: var(--corn-surface-2); color: var(--corn-text); }
156
+ .hx-zoom-btn--accent { color: var(--corn-accent-text); }
279
157
 
280
- .hx-chip-link { display: none; align-items: center; gap: 4px; padding: 4px 8px; border-radius: 6px; border: 1px solid; font-size: 12px; font-weight: 500; text-decoration: none; transition: background 0.15s; }
158
+ .hx-chip-link { display: none; align-items: center; gap: var(--corn-space-1); padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid; font-size: var(--corn-text-sm); font-weight: 500; text-decoration: none; transition: background 0.15s; }
281
159
  .hx-dot-sm { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
282
- .hx-chip-link--indigo { color: var(--hx-indigo); background: rgba(99, 102, 241, 0.1); border-color: rgba(99, 102, 241, 0.2); }
283
- .hx-chip-link--pink { color: var(--hx-pink); background: rgba(236, 72, 153, 0.1); border-color: rgba(236, 72, 153, 0.2); }
284
- .hx-chip-link--purple { color: var(--hx-violet-text); background: rgba(168, 85, 247, 0.1); border-color: rgba(168, 85, 247, 0.2); }
285
- .hx-chip-link:hover { background: var(--hx-line); }
160
+ .hx-chip-link--indigo { color: var(--corn-accent-text); background: color-mix(in srgb, var(--corn-accent-hover) 10%, transparent); border-color: color-mix(in srgb, var(--corn-accent-hover) 20%, transparent); }
161
+ .hx-chip-link--pink { color: var(--corn-hue-pink); background: color-mix(in srgb, var(--corn-hue-pink) 10%, transparent); border-color: color-mix(in srgb, var(--corn-hue-pink) 20%, transparent); }
162
+ .hx-chip-link--purple { color: var(--corn-edit-text); background: color-mix(in srgb, var(--corn-edit) 10%, transparent); border-color: color-mix(in srgb, var(--corn-edit) 20%, transparent); }
163
+ .hx-chip-link:hover { background: var(--corn-line); }
286
164
 
287
165
  .hx-search { display: none; }
288
166
  .hx-only-wide { display: none; }
@@ -300,48 +178,48 @@ h1, h2, h3, p { margin: 0; }
300
178
  position: absolute;
301
179
  top: 100%;
302
180
  left: 0;
303
- margin-top: 8px;
181
+ margin-top: var(--corn-space-3);
304
182
  width: 288px;
305
183
  max-width: calc(100vw - 24px);
306
184
  max-height: calc(100dvh - 80px);
307
185
  overflow-y: auto;
308
- padding: 12px;
309
- border-radius: 16px;
310
- font-size: 11px;
186
+ padding: var(--corn-space-4);
187
+ border-radius: var(--corn-radius-lg);
188
+ font-size: var(--corn-text-xs);
311
189
  z-index: 50;
312
190
  user-select: none;
313
191
  }
314
- .hx-menu-title { display: flex; align-items: center; justify-content: space-between; padding-bottom: 2px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--hx-slate-400); }
315
- .hx-menu-head { padding-bottom: 6px; border-bottom: 1px solid var(--hx-line); margin-bottom: 8px; }
316
- .hx-menu-links { display: flex; align-items: center; gap: 8px; text-transform: none; letter-spacing: 0; }
317
- .hx-menu-section { padding-top: 8px; margin-top: 8px; border-top: 1px solid var(--hx-line); }
318
- .hx-note { padding: 6px 8px; margin-bottom: 8px; border-radius: 8px; background: rgba(251, 146, 60, 0.12); color: var(--hx-orange-text); font-size: 11px; line-height: 1.4; }
319
- .hx-textbtn { padding: 2px 4px; border: 0; border-radius: 3px; background: none; color: var(--hx-slate-400); font-size: 10px; font-weight: 600; }
320
- .hx-textbtn:hover { background: var(--hx-line-soft); color: var(--hx-slate-300); }
321
- .hx-textbtn--accent { color: var(--hx-indigo); }
322
-
323
- .hx-toggles { display: flex; flex-direction: column; gap: 4px; }
324
- .hx-toggle-row { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 6px 10px; border-radius: 12px; border: 1px solid var(--hx-line); background: var(--hx-control); color: var(--hx-ink); text-align: left; transition: background 0.15s; }
325
- .hx-toggle-row:hover { background: var(--hx-control-hover); }
326
- .hx-toggle-row.is-off { background: var(--hx-control-off); border-color: transparent; color: var(--hx-slate-500); opacity: 0.6; }
327
- .hx-toggle-label, .hx-toggle-meta { display: flex; align-items: center; gap: 8px; }
192
+ .hx-menu-title { display: flex; align-items: center; justify-content: space-between; padding-bottom: calc(var(--corn-space-1) / 2); font-size: var(--corn-text-2xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--corn-text-3); }
193
+ .hx-menu-head { padding-bottom: var(--corn-space-2); border-bottom: var(--corn-border) solid var(--corn-line); margin-bottom: var(--corn-space-3); }
194
+ .hx-menu-links { display: flex; align-items: center; gap: var(--corn-space-3); text-transform: none; letter-spacing: 0; }
195
+ .hx-menu-section { padding-top: var(--corn-space-3); margin-top: var(--corn-space-3); border-top: var(--corn-border) solid var(--corn-line); }
196
+ .hx-note { padding: var(--corn-space-2) var(--corn-space-3); margin-bottom: var(--corn-space-3); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-hue-orange) 12%, transparent); color: var(--corn-hue-orange); font-size: var(--corn-text-xs); line-height: 1.4; }
197
+ .hx-textbtn { padding: calc(var(--corn-space-1) / 2) var(--corn-space-1); border: 0; border-radius: var(--corn-radius-xs); background: none; color: var(--corn-text-3); font-size: var(--corn-text-2xs); font-weight: 600; }
198
+ .hx-textbtn:hover { background: var(--corn-line-soft); color: var(--corn-text-2); }
199
+ .hx-textbtn--accent { color: var(--corn-accent-text); }
200
+
201
+ .hx-toggles { display: flex; flex-direction: column; gap: var(--corn-space-1); }
202
+ .hx-toggle-row { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius); border: var(--corn-border) solid var(--corn-line); background: var(--corn-surface-2); color: var(--corn-text); text-align: left; transition: background 0.15s; }
203
+ .hx-toggle-row:hover { background: var(--corn-surface-3); }
204
+ .hx-toggle-row.is-off { background: color-mix(in srgb, var(--corn-ground) 40%, transparent); border-color: transparent; color: var(--corn-text-3); opacity: 0.6; }
205
+ .hx-toggle-label, .hx-toggle-meta { display: flex; align-items: center; gap: var(--corn-space-3); }
328
206
  .hx-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; transition: transform 0.15s; }
329
207
  .hx-toggle-row.is-off .hx-dot { transform: scale(0.75); opacity: 0.4; }
330
- .hx-toggle-name { font-size: 11px; font-weight: 500; color: var(--hx-text-2); }
331
- .hx-toggle-row.is-off .hx-toggle-name { color: var(--hx-slate-500); text-decoration: line-through; }
332
- .hx-count { padding: 2px 6px; border-radius: 3px; background: var(--hx-control-hover); color: var(--hx-slate-300); font-family: var(--pop-font-mono); font-size: 10px; }
333
- .hx-toggle-row.is-off .hx-count { background: var(--hx-control-off); color: var(--hx-slate-600); }
334
- .hx-tick { font-size: 12px; font-weight: 700; color: var(--hx-emerald); }
335
- .hx-toggle-row.is-off .hx-tick { color: var(--hx-slate-600); }
336
-
337
- .hx-legend-row { display: flex; align-items: center; gap: 8px; padding: 2px 0; color: var(--hx-slate-300); }
208
+ .hx-toggle-name { font-size: var(--corn-text-xs); font-weight: 500; color: var(--corn-text-2); }
209
+ .hx-toggle-row.is-off .hx-toggle-name { color: var(--corn-text-3); text-decoration: line-through; }
210
+ .hx-count { padding: calc(var(--corn-space-1) / 2) var(--corn-space-2); border-radius: var(--corn-radius-xs); background: var(--corn-surface-3); color: var(--corn-text-2); font-family: var(--corn-mono); font-size: var(--corn-text-2xs); }
211
+ .hx-toggle-row.is-off .hx-count { background: color-mix(in srgb, var(--corn-ground) 40%, transparent); color: var(--corn-text-3); }
212
+ .hx-tick { font-size: var(--corn-text-sm); font-weight: 700; color: var(--corn-ok); }
213
+ .hx-toggle-row.is-off .hx-tick { color: var(--corn-text-3); }
214
+
215
+ .hx-legend-row { display: flex; align-items: center; gap: var(--corn-space-3); padding: calc(var(--corn-space-1) / 2) 0; color: var(--corn-text-2); }
338
216
  .hx-legend-row--split { justify-content: space-between; }
339
- .hx-legend-label { display: flex; align-items: center; gap: 8px; font-weight: 500; }
217
+ .hx-legend-label { display: flex; align-items: center; gap: var(--corn-space-3); font-weight: 500; }
340
218
  .hx-legend-swatch { width: 16px; flex: none; display: inline-flex; justify-content: center; }
341
- .hx-swatch-line { display: inline-block; width: 16px; height: 2px; border-radius: 1px; }
342
- .hx-swatch-solid { background: var(--hx-swatch-solid); }
343
- .hx-swatch-dashed { height: 0; background: none; border-top: 2px dashed var(--hx-slate-300); }
344
- .hx-swatch-indigo { border-top-color: var(--hx-indigo); }
219
+ .hx-swatch-line { display: inline-block; width: 16px; height: 2px; border-radius: var(--corn-radius-xs); }
220
+ .hx-swatch-solid { background: color-mix(in srgb, var(--corn-text) 55%, transparent); }
221
+ .hx-swatch-dashed { height: 0; background: none; border-top: var(--corn-border-strong) dashed var(--corn-text-2); }
222
+ .hx-swatch-indigo { border-top-color: var(--corn-accent-text); }
345
223
 
346
224
  /* ---- stage: canvas, hint, states --------------------------------------------------------- */
347
225
  .hx-stage { position: relative; flex: 1; width: 100%; min-height: 0; overflow: hidden; }
@@ -351,267 +229,264 @@ h1, h2, h3, p { margin: 0; }
351
229
  /* The Canvas 2D that stands in for the map canvas when its WebGL2 shaders fail (renderer.js): same place, pointer goes through */
352
230
  .hx-overlay { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; }
353
231
 
354
- .hx-hint { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 6px; max-width: 85vw; padding: 4px 12px; border-radius: 9999px; font-size: 10px; color: var(--hx-slate-300); pointer-events: none; z-index: 10; white-space: nowrap; }
232
+ .hx-hint { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: var(--corn-space-2); max-width: 85vw; padding: var(--corn-space-1) var(--corn-space-4); border-radius: var(--corn-radius-pill); font-size: var(--corn-text-2xs); color: var(--corn-text-2); pointer-events: none; z-index: 10; white-space: nowrap; }
355
233
  .hx-hint span:last-child { overflow: hidden; text-overflow: ellipsis; }
356
- @media (min-width: 640px) { .hx-hint { font-size: 11px; } }
234
+ @media (min-width: 640px) { .hx-hint { font-size: var(--corn-text-xs); } }
357
235
 
358
- .hx-mobile-zoom { position: absolute; bottom: 16px; right: 12px; display: flex; flex-direction: column; gap: 4px; padding: 4px; border-radius: 12px; z-index: 20; }
359
- .hx-mobile-zoom .hx-zoom-btn { width: 32px; height: 32px; background: var(--hx-control); color: var(--hx-ink); border-radius: 8px; }
236
+ .hx-mobile-zoom { position: absolute; bottom: 16px; right: 12px; display: flex; flex-direction: column; gap: var(--corn-space-1); padding: var(--corn-space-1); border-radius: var(--corn-radius); z-index: 20; }
237
+ .hx-mobile-zoom .hx-zoom-btn { width: 32px; height: 32px; background: var(--corn-surface-2); color: var(--corn-text); border-radius: var(--corn-radius-sm); }
360
238
 
361
- .hx-mobile-search { position: absolute; top: 56px; left: 0; right: 0; display: flex; align-items: center; gap: 8px; padding: 10px; z-index: 30; }
239
+ .hx-mobile-search { position: absolute; top: 56px; left: 0; right: 0; display: flex; align-items: center; gap: var(--corn-space-3); padding: var(--corn-space-3); z-index: 30; }
362
240
 
363
- .hx-state { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: var(--hx-slate-400); font-size: 13px; z-index: 5; text-align: center; }
364
- .hx-state--error { display: flex; flex-direction: column; align-items: center; gap: 10px; width: min(440px, calc(100vw - 32px)); padding: 24px; border-radius: 16px; color: var(--hx-slate-300); user-select: text; }
365
- .hx-state--error strong { color: var(--hx-red); font-size: 15px; }
366
- .hx-state--error p { font-size: 12px; line-height: 1.5; }
367
- .hx-state--error #error-message { font-family: var(--pop-font-mono); color: var(--hx-amber); word-break: break-word; }
241
+ .hx-state { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); color: var(--corn-text-3); font-size: var(--corn-text-md); z-index: 5; text-align: center; }
242
+ .hx-state--error { display: flex; flex-direction: column; align-items: center; gap: var(--corn-space-3); width: min(440px, calc(100vw - 32px)); padding: var(--corn-space-6); border-radius: var(--corn-radius-lg); color: var(--corn-text-2); user-select: text; }
243
+ .hx-state--error strong { color: var(--corn-bad); font-size: var(--corn-text-lg); }
244
+ .hx-state--error p { font-size: var(--corn-text-sm); line-height: 1.5; }
245
+ .hx-state--error #error-message { font-family: var(--corn-mono); color: var(--corn-warn); word-break: break-word; }
368
246
 
369
247
  /* ---- node panel -------------------------------------------------------------------------- */
370
- .hx-backdrop { position: fixed; inset: 0; z-index: 40; background: var(--hx-backdrop); backdrop-filter: blur(4px); }
248
+ .hx-backdrop { position: fixed; inset: 0; z-index: 40; background: var(--corn-scrim); backdrop-filter: blur(calc(var(--corn-blur) / 4)); }
371
249
  @media (min-width: 768px) { .hx-backdrop { display: none; } }
372
250
 
373
- .hx-drawer { display: flex; flex-direction: column; z-index: 40; border-color: var(--hx-slate-800); box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5); pointer-events: none; touch-action: pan-y; transition: transform 0.2s ease-out; }
251
+ .hx-drawer { display: flex; flex-direction: column; z-index: 40; border-color: var(--corn-surface-2); box-shadow: var(--corn-shadow-lg); pointer-events: none; touch-action: pan-y; transition: transform 0.2s ease-out; }
374
252
  .hx-drawer * { touch-action: pan-y; }
375
253
  .hx-drawer.drawer-open { pointer-events: auto; }
254
+ /* The closed panel waits just off the right edge: its shadow would show there */
255
+ .hx-drawer:not(.drawer-open) { box-shadow: none; }
376
256
  @media (max-width: 767px) {
377
257
  /* A sheet in #sheet-dock (sheets.js, "phone bottom sheets" at the end of this file) */
378
- .hx-drawer { position: relative; width: 100%; border-radius: 24px 24px 0 0; border-left: 0; transform: none; z-index: auto; }
258
+ .hx-drawer { position: relative; width: 100%; border-radius: var(--corn-radius-lg) var(--corn-radius-lg) 0 0; border-left: 0; transform: none; z-index: auto; }
379
259
  .hx-drawer:not(.drawer-open) { display: none; }
380
260
  }
381
261
  @media (min-width: 768px) {
382
262
  .hx-drawer { position: absolute; top: 0; right: 0; bottom: 0; width: 480px; transform: translateX(100%); }
383
263
  .hx-drawer.drawer-open { transform: translateX(0); }
384
264
  }
385
- .hx-drawer-handle { display: flex; justify-content: center; padding: 10px 0 4px; }
386
- .hx-drawer-handle span { width: 48px; height: 6px; border-radius: 9999px; background: var(--hx-slate-700); }
387
- .hx-drawer-body { flex: 1; display: flex; flex-direction: column; gap: 16px; padding: 20px; overflow-y: auto; user-select: text; }
388
- @media (min-width: 640px) { .hx-drawer-body { padding: 24px; } }
389
- .hx-drawer-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid var(--hx-slate-800); }
390
- .hx-drawer-title-wrap { display: flex; align-items: center; gap: 8px; min-width: 0; }
391
- .hx-drawer-title { font-size: 16px; font-weight: 700; color: var(--hx-ink); overflow-wrap: anywhere; }
392
- .hx-badge { flex: none; padding: 2px 8px; border-radius: 3px; border: 1px solid rgba(99, 102, 241, 0.3); background: rgba(99, 102, 241, 0.2); color: var(--hx-indigo); font-size: 10px; font-weight: 700; letter-spacing: 0.025em; }
393
- .hx-close { width: 32px; height: 32px; flex: none; border: 0; border-radius: 8px; background: var(--hx-slate-800); color: var(--hx-slate-400); font-weight: 700; font-size: 14px; }
394
- .hx-close:hover { color: var(--hx-ink); }
395
- .hx-lead { font-size: 12px; line-height: 1.6; }
396
-
397
- .hx-block { display: flex; flex-direction: column; gap: 8px; }
398
- .hx-block-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--hx-slate-300); }
399
- .hx-props { display: flex; flex-direction: column; gap: 6px; font-family: var(--pop-font-mono); font-size: 11px; }
400
- .hx-prop { padding: 8px; border-radius: 6px; border: 1px solid var(--hx-line); background: var(--hx-well); }
401
- .hx-prop-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
402
- .hx-prop-head .hx-faint { font-size: 10px; }
403
- .hx-prop > .hx-faint { font-size: 10px; margin-top: 2px; }
404
- .hx-meta { display: flex; flex-direction: column; gap: 4px; padding: 12px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well-soft); font-family: var(--pop-font-mono); font-size: 11px; color: var(--hx-slate-400); overflow-wrap: anywhere; }
405
-
406
- .hx-sec { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--hx-line); }
407
- .hx-line { display: flex; align-items: flex-start; gap: 6px; padding: 2px 0; }
408
- .hx-linkbtn { margin-left: 4px; padding: 0; border: 0; background: none; color: var(--hx-fuchsia); text-decoration: underline; font-size: inherit; }
409
-
410
- .hx-sim { display: flex; flex-direction: column; gap: 6px; padding-top: 4px; font-family: var(--pop-font-body); }
411
- .hx-field-label { font-size: 10px; color: var(--hx-slate-400); }
412
- .hx-field { width: 100%; padding: 4px 8px; border-radius: 6px; border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-text-2); font-family: var(--pop-font-mono); font-size: 11px; }
413
- .hx-sim-result { font-size: 11px; }
414
- .hx-error-text { padding-top: 8px; color: var(--hx-red); }
415
- .hx-ms { width: 56px; flex: none; text-align: right; font-family: var(--pop-font-mono); color: var(--hx-fuchsia); }
416
- .hx-file { padding: 2px 0; }
417
-
418
- .hx-sandbox { display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: 12px; border: 1px solid var(--hx-line); background: var(--hx-well); }
419
- .hx-sandbox-title { display: flex; align-items: center; justify-content: space-between; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--hx-slate-400); }
420
- .hx-sandbox-name { display: flex; align-items: center; gap: 6px; }
421
- .hx-sandbox-stage { min-height: 90px; display: flex; align-items: center; justify-content: center; padding: 16px; border-radius: 8px; border: 1px dashed var(--hx-slate-800); background: var(--hx-slate-900); overflow-x: auto; }
422
- .hx-sandbox-controls { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; border-top: 1px solid var(--hx-line); font-size: 11px; }
423
- .hx-ctl-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; color: var(--hx-slate-300); }
424
- .hx-check { display: inline-flex; align-items: center; gap: 4px; margin-right: 8px; cursor: pointer; }
425
- .hx-chip { padding: 2px 8px; border: 0; border-radius: 3px; font-size: 11px; font-weight: 500; color: #fff; }
426
- .hx-chip--ghost { background: var(--hx-slate-800); color: var(--hx-slate-300); }
427
- .hx-chip--outline { background: var(--hx-slate-800); color: var(--hx-indigo); }
428
- .hx-chip--primary { background: #4f46e5; }
429
- .hx-chip--danger { background: #dc2626; }
430
- .hx-chip--success { background: #059669; }
431
- .hx-chip--warning { background: #d97706; }
432
-
433
- .hx-drawer-foot { display: flex; gap: 8px; flex: none; padding: 16px 16px calc(16px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--hx-slate-800); background: var(--hx-well); }
434
- .hx-open { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 12px; border-radius: 12px; background: #4f46e5; color: #fff; font-size: 12px; font-weight: 600; text-align: center; text-decoration: none; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4); transition: background 0.15s; }
435
- .hx-open:hover { background: #6366f1; }
436
- .hx-open:not([href]) { background: var(--hx-slate-800); color: var(--hx-slate-400); }
265
+ .hx-drawer-handle { display: flex; justify-content: center; padding: var(--corn-space-3) 0 var(--corn-space-1); }
266
+ .hx-drawer-handle span { width: 48px; height: 6px; border-radius: var(--corn-radius-pill); background: var(--corn-surface-3); }
267
+ .hx-drawer-body { flex: 1; display: flex; flex-direction: column; gap: var(--corn-space-5); padding: calc(var(--corn-space-5) + var(--corn-space-1)); overflow-y: auto; user-select: text; }
268
+ @media (min-width: 640px) { .hx-drawer-body { padding: var(--corn-space-6); } }
269
+ .hx-drawer-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: var(--corn-space-4); border-bottom: var(--corn-border) solid var(--corn-surface-2); }
270
+ .hx-drawer-title-wrap { display: flex; align-items: center; gap: var(--corn-space-3); min-width: 0; }
271
+ .hx-drawer-title { font-size: var(--corn-text-lg); font-weight: 700; color: var(--corn-text); overflow-wrap: anywhere; }
272
+ .hx-badge { flex: none; padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); border-radius: var(--corn-radius-xs); border: var(--corn-border) solid color-mix(in srgb, var(--corn-accent-hover) 30%, transparent); background: var(--corn-accent-soft); color: var(--corn-accent-text); font-size: var(--corn-text-2xs); font-weight: 700; letter-spacing: 0.025em; }
273
+ .hx-close { width: 32px; height: 32px; flex: none; border: 0; border-radius: var(--corn-radius-sm); background: var(--corn-surface-2); color: var(--corn-text-3); font-weight: 700; font-size: var(--corn-text-base); }
274
+ .hx-close:hover { color: var(--corn-text); }
275
+ .hx-lead { font-size: var(--corn-text-sm); line-height: 1.6; }
276
+
277
+ .hx-block { display: flex; flex-direction: column; gap: var(--corn-space-3); }
278
+ .hx-block-title { font-size: var(--corn-text-sm); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--corn-text-2); }
279
+ .hx-props { display: flex; flex-direction: column; gap: var(--corn-space-2); font-family: var(--corn-mono); font-size: var(--corn-text-xs); }
280
+ .hx-prop { padding: var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); }
281
+ .hx-prop-head { display: flex; align-items: center; justify-content: space-between; gap: var(--corn-space-3); }
282
+ .hx-prop-head .hx-faint { font-size: var(--corn-text-2xs); }
283
+ .hx-prop > .hx-faint { font-size: var(--corn-text-2xs); margin-top: calc(var(--corn-space-1) / 2); }
284
+ .hx-meta { display: flex; flex-direction: column; gap: var(--corn-space-1); padding: var(--corn-space-4); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); font-family: var(--corn-mono); font-size: var(--corn-text-xs); color: var(--corn-text-3); overflow-wrap: anywhere; }
285
+
286
+ .hx-sec { margin-top: var(--corn-space-2); padding-top: var(--corn-space-2); border-top: var(--corn-border) solid var(--corn-line); }
287
+ .hx-line { display: flex; align-items: flex-start; gap: var(--corn-space-2); padding: calc(var(--corn-space-1) / 2) 0; }
288
+ .hx-linkbtn { margin-left: var(--corn-space-1); padding: 0; border: 0; background: none; color: var(--corn-hue-fuchsia); text-decoration: underline; font-size: inherit; }
289
+
290
+ .hx-sim { display: flex; flex-direction: column; gap: var(--corn-space-2); padding-top: var(--corn-space-1); font-family: var(--corn-font); }
291
+ .hx-field-label { font-size: var(--corn-text-2xs); color: var(--corn-text-3); }
292
+ .hx-field { width: 100%; padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text-2); font-family: var(--corn-mono); font-size: var(--corn-text-xs); }
293
+ .hx-sim-result { font-size: var(--corn-text-xs); }
294
+ .hx-error-text { padding-top: var(--corn-space-3); color: var(--corn-bad); }
295
+ .hx-ms { width: 56px; flex: none; text-align: right; font-family: var(--corn-mono); color: var(--corn-hue-fuchsia); }
296
+ .hx-file { padding: calc(var(--corn-space-1) / 2) 0; }
297
+
298
+ .hx-sandbox { display: flex; flex-direction: column; gap: var(--corn-space-4); padding: var(--corn-space-5); border-radius: var(--corn-radius); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); }
299
+ .hx-sandbox-title { display: flex; align-items: center; justify-content: space-between; font-size: var(--corn-text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--corn-text-3); }
300
+ .hx-sandbox-name { display: flex; align-items: center; gap: var(--corn-space-2); }
301
+ .hx-sandbox-stage { min-height: 90px; display: flex; align-items: center; justify-content: center; padding: var(--corn-space-5); border-radius: var(--corn-radius-sm); border: var(--corn-border) dashed var(--corn-surface-2); background: var(--corn-ground); overflow-x: auto; }
302
+ .hx-sandbox-controls { display: flex; flex-direction: column; gap: var(--corn-space-2); padding-top: var(--corn-space-3); border-top: var(--corn-border) solid var(--corn-line); font-size: var(--corn-text-xs); }
303
+ .hx-ctl-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2); color: var(--corn-text-2); }
304
+ .hx-check { display: inline-flex; align-items: center; gap: var(--corn-space-1); margin-right: var(--corn-space-3); cursor: pointer; }
305
+ .hx-chip { padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); border: 0; border-radius: var(--corn-radius-xs); font-size: var(--corn-text-xs); font-weight: 500; color: var(--corn-text-on-accent); }
306
+ .hx-chip--ghost { background: var(--corn-surface-2); color: var(--corn-text-2); }
307
+ .hx-chip--outline { background: var(--corn-surface-2); color: var(--corn-accent-text); }
308
+ .hx-chip--primary { background: var(--corn-accent); }
309
+ .hx-chip--danger { background: var(--corn-bad); }
310
+ .hx-chip--success { background: var(--corn-ok); }
311
+ .hx-chip--warning { background: var(--corn-warn); }
312
+ .hx-chip--danger, .hx-chip--success, .hx-chip--warning { color: var(--corn-ground); }
313
+
314
+ .hx-drawer-foot { display: flex; gap: var(--corn-space-3); flex: none; padding: var(--corn-space-5) var(--corn-space-5) calc(var(--corn-space-5) + env(safe-area-inset-bottom, 0px)); border-top: var(--corn-border) solid var(--corn-surface-2); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); }
315
+ .hx-open { flex: 1; display: flex; align-items: center; justify-content: center; gap: var(--corn-space-2); padding: var(--corn-space-3) var(--corn-space-4); border-radius: var(--corn-radius); background: var(--corn-accent); color: var(--corn-text-on-accent); font-size: var(--corn-text-sm); font-weight: 600; text-align: center; text-decoration: none; box-shadow: var(--corn-shadow-sm); transition: background 0.15s; }
316
+ .hx-open:hover { background: var(--corn-accent-hover); }
317
+ .hx-open:not([href]) { background: var(--corn-surface-2); color: var(--corn-text-3); }
437
318
 
438
319
  /* ---- proposals (proposal.js): picker, bar, marks, panel rows ----------------------------------- */
439
- :root {
440
- --hx-mark-added: #2dd4bf;
441
- --hx-mark-changed: #fbbf24;
442
- --hx-mark-removed: #f87171;
443
- --hx-mark-edit: #a78bfa;
444
- }
445
- .hx-btn--proposal { border-color: rgba(45, 212, 191, 0.35); color: var(--hx-teal-text); }
446
- .hx-btn--proposal:hover { background: rgba(45, 212, 191, 0.14); color: var(--hx-teal-strong); }
447
- .hx-btn--proposal[aria-expanded="true"] { background: rgba(45, 212, 191, 0.2); border-color: var(--hx-mark-added); color: var(--hx-teal-strong); }
320
+ .hx-btn--proposal { border-color: color-mix(in srgb, var(--corn-added) 35%, transparent); color: var(--corn-added-text); }
321
+ .hx-btn--proposal:hover { background: color-mix(in srgb, var(--corn-added) 14%, transparent); color: var(--corn-added-text); }
322
+ .hx-btn--proposal[aria-expanded="true"] { background: color-mix(in srgb, var(--corn-added) 20%, transparent); border-color: var(--corn-added); color: var(--corn-added-text); }
448
323
 
449
324
  .hx-menu--proposals { width: 360px; }
450
- .hx-proposal-list { display: flex; flex-direction: column; gap: 4px; }
451
- .hx-proposal-empty { padding: 8px 2px; font-size: 12px; }
452
- .hx-proposal-item { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; width: 100%; padding: 8px 10px; border-radius: var(--radius-lg, 12px); border: 1px solid var(--hx-line); background: var(--hx-control); color: var(--hx-ink); text-align: left; font-size: 11px; }
453
- button.hx-proposal-item:hover { background: var(--hx-control-hover); }
454
- button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
455
- .hx-proposal-item.is-current { border-color: var(--hx-mark-added); background: rgba(45, 212, 191, 0.12); }
325
+ .hx-proposal-list { display: flex; flex-direction: column; gap: var(--corn-space-1); }
326
+ .hx-proposal-empty { padding: var(--corn-space-3) calc(var(--corn-space-1) / 2); font-size: var(--corn-text-sm); }
327
+ .hx-proposal-item { display: flex; flex-direction: column; align-items: flex-start; gap: var(--corn-space-1); width: 100%; padding: var(--corn-space-3) var(--corn-space-3); border-radius: var(--corn-radius); border: var(--corn-border) solid var(--corn-line); background: var(--corn-surface-2); color: var(--corn-text); text-align: left; font-size: var(--corn-text-xs); }
328
+ button.hx-proposal-item:hover { background: var(--corn-surface-3); }
329
+ button.hx-proposal-item:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
330
+ .hx-proposal-item.is-current { border-color: var(--corn-added); background: color-mix(in srgb, var(--corn-added) 12%, transparent); }
456
331
  .hx-proposal-item.is-broken { opacity: 0.8; cursor: default; }
457
- .hx-proposal-title { font-size: 12px; font-weight: var(--weight-semibold, 600); color: var(--hx-text-1); overflow-wrap: anywhere; }
458
- .hx-proposal-sum { color: var(--hx-slate-300); line-height: 1.4; }
459
- .hx-proposal-meta { display: flex; flex-wrap: wrap; gap: 2px 10px; color: var(--hx-slate-400); font-size: 10px; }
460
- .hx-proposal-where { color: var(--hx-teal-text); }
461
-
462
- .hx-proposal-bar { position: absolute; top: 48px; left: 12px; width: min(720px, calc(100% - 24px)); padding: 8px 10px; border-radius: var(--radius-xl, 16px); font-size: 12px; z-index: 15; user-select: text; }
463
- .hx-proposal-bar.is-error { border-color: rgba(248, 113, 113, 0.5); }
464
- .hx-proposal-message { color: var(--hx-slate-300); }
465
- .hx-proposal-bar.is-error .hx-proposal-message { color: var(--hx-red); }
466
- .hx-proposal-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
467
- .hx-proposal-name { flex: 1 1 140px; min-width: 0; font-size: 13px; color: var(--hx-text-1); overflow-wrap: anywhere; }
468
- .hx-proposal-chip { padding: 3px 10px; border-radius: var(--radius-full, 9999px); border: 1px solid var(--border-glass); background: var(--hx-well-soft); color: var(--hx-slate-300); font-size: 11px; font-variant-numeric: tabular-nums; }
469
- .hx-proposal-chip:hover { background: var(--hx-control-hover); color: var(--hx-ink); }
470
- .hx-proposal-chip:focus-visible, .hx-seg-btn:focus-visible, .hx-change-row:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
471
- .hx-proposal-summary { margin-top: 6px; color: var(--hx-slate-300); line-height: 1.45; }
332
+ .hx-proposal-title { font-size: var(--corn-text-sm); font-weight: 600; color: var(--corn-text); overflow-wrap: anywhere; }
333
+ .hx-proposal-sum { color: var(--corn-text-2); line-height: 1.4; }
334
+ .hx-proposal-meta { display: flex; flex-wrap: wrap; gap: calc(var(--corn-space-1) / 2) var(--corn-space-3); color: var(--corn-text-3); font-size: var(--corn-text-2xs); }
335
+ .hx-proposal-where { color: var(--corn-added-text); }
336
+
337
+ .hx-proposal-bar { position: absolute; top: 48px; left: 12px; width: min(720px, calc(100% - 24px)); padding: var(--corn-space-3) var(--corn-space-3); border-radius: var(--corn-radius-lg); font-size: var(--corn-text-sm); z-index: 15; user-select: text; }
338
+ .hx-proposal-bar.is-error { border-color: color-mix(in srgb, var(--corn-removed) 50%, transparent); }
339
+ .hx-proposal-message { color: var(--corn-text-2); }
340
+ .hx-proposal-bar.is-error .hx-proposal-message { color: var(--corn-bad); }
341
+ .hx-proposal-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2) var(--corn-space-3); }
342
+ .hx-proposal-name { flex: 1 1 140px; min-width: 0; font-size: var(--corn-text-md); color: var(--corn-text); overflow-wrap: anywhere; }
343
+ .hx-proposal-chip { padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-lg); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-text-2); font-size: var(--corn-text-xs); font-variant-numeric: tabular-nums; }
344
+ .hx-proposal-chip:hover { background: var(--corn-surface-3); color: var(--corn-text); }
345
+ .hx-proposal-chip:focus-visible, .hx-seg-btn:focus-visible, .hx-change-row:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
346
+ .hx-proposal-summary { margin-top: var(--corn-space-2); color: var(--corn-text-2); line-height: 1.45; }
472
347
 
473
348
  /* Before / Diff / After */
474
- .hx-seg { display: inline-flex; padding: 2px; border-radius: var(--radius-md, 8px); border: 1px solid var(--hx-line); background: var(--hx-well-soft); }
475
- .hx-seg-btn { padding: 3px 12px; border: 0; border-radius: var(--radius-sm, 6px); background: none; color: var(--hx-slate-400); font-size: 12px; font-weight: var(--weight-medium, 500); }
476
- .hx-seg-btn:hover { color: var(--hx-ink); }
477
- .hx-seg-btn.is-on, .hx-seg-btn[aria-pressed="true"] { background: var(--hx-indigo-strong); color: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4); }
478
-
479
- .hx-proposal-errors { margin-top: 6px; padding: 6px 8px; border-radius: var(--radius-md, 8px); background: rgba(248, 113, 113, 0.1); border: 1px solid rgba(248, 113, 113, 0.3); color: var(--hx-slate-300); }
480
- .hx-proposal-errors summary { cursor: pointer; color: var(--hx-red); font-weight: var(--weight-semibold, 600); }
481
- .hx-proposal-errors ul { margin: 6px 0 4px; padding-left: 18px; line-height: 1.5; }
482
- .hx-proposal-errors p { margin-top: 4px; font-size: 11px; }
483
-
484
- .hx-proposal-changes { display: flex; flex-direction: column; gap: 2px; max-height: 40dvh; margin-top: 6px; overflow-y: auto; }
485
- .hx-change-row { display: flex; align-items: center; gap: 8px; width: 100%; padding: 4px 6px; border: 0; border-radius: var(--radius-sm, 6px); background: none; text-align: left; font-size: 11px; }
486
- .hx-change-row:hover { background: var(--hx-line-soft); }
487
- .hx-change-what { width: 56px; flex: none; color: var(--hx-slate-400); }
488
-
489
- /* The marks' colours, shared with the picture (MARK in scene.js sets the --hx-mark-* variables) */
490
- .hx-mark-dot { display: inline-block; width: 12px; height: 12px; flex: none; margin-right: 6px; border-radius: 50%; border: 2px solid var(--hx-mark-changed); vertical-align: -2px; }
349
+ .hx-seg { display: inline-flex; padding: calc(var(--corn-space-1) / 2); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); }
350
+ .hx-seg-btn { padding: var(--corn-space-1) var(--corn-space-4); border: 0; border-radius: var(--corn-radius-sm); background: none; color: var(--corn-text-3); font-size: var(--corn-text-sm); font-weight: 500; }
351
+ .hx-seg-btn:hover { color: var(--corn-text); }
352
+ .hx-seg-btn.is-on, .hx-seg-btn[aria-pressed="true"] { background: var(--corn-accent); color: var(--corn-text-on-accent); box-shadow: var(--corn-shadow-sm); }
353
+
354
+ .hx-proposal-errors { margin-top: var(--corn-space-2); padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-removed) 10%, transparent); border: var(--corn-border) solid color-mix(in srgb, var(--corn-removed) 30%, transparent); color: var(--corn-text-2); }
355
+ .hx-proposal-errors summary { cursor: pointer; color: var(--corn-bad); font-weight: 600; }
356
+ .hx-proposal-errors ul { margin: var(--corn-space-2) 0 var(--corn-space-1); padding-left: var(--corn-space-5); line-height: 1.5; }
357
+ .hx-proposal-errors p { margin-top: var(--corn-space-1); font-size: var(--corn-text-xs); }
358
+
359
+ .hx-proposal-changes { display: flex; flex-direction: column; gap: calc(var(--corn-space-1) / 2); max-height: 40dvh; margin-top: var(--corn-space-2); overflow-y: auto; }
360
+ .hx-change-row { display: flex; align-items: center; gap: var(--corn-space-3); width: 100%; padding: var(--corn-space-1) var(--corn-space-2); border: 0; border-radius: var(--corn-radius-sm); background: none; text-align: left; font-size: var(--corn-text-xs); }
361
+ .hx-change-row:hover { background: var(--corn-line-soft); }
362
+ .hx-change-what { width: 56px; flex: none; color: var(--corn-text-3); }
363
+
364
+ /* The marks' colours, shared with the picture: the diff tokens, whose light values are theme-model.js `lightColor` of the dark ones */
365
+ .hx-mark-dot { display: inline-block; width: 12px; height: 12px; flex: none; margin-right: var(--corn-space-2); border-radius: 50%; border: var(--corn-border-strong) solid var(--corn-changed); vertical-align: -2px; }
491
366
  .hx-legend-row .hx-mark-dot, .hx-change-row .hx-mark-dot { margin-right: 0; }
492
- .hx-mark-dot--added { border-color: var(--hx-mark-added); border-style: dashed; }
493
- .hx-mark-dot--changed { border-color: var(--hx-mark-changed); }
494
- .hx-mark-dot--removed { border-color: var(--hx-mark-removed); background: rgba(248, 113, 113, 0.25); opacity: 0.7; }
495
- .hx-mark-dot--edit { border-color: var(--hx-mark-edit); }
367
+ .hx-mark-dot--added { border-color: var(--corn-added); border-style: dashed; }
368
+ .hx-mark-dot--changed { border-color: var(--corn-changed); }
369
+ .hx-mark-dot--removed { border-color: var(--corn-removed); background: color-mix(in srgb, var(--corn-removed) 25%, transparent); opacity: 0.7; }
370
+ .hx-mark-dot--edit { border-color: var(--corn-edit); }
496
371
 
497
372
  /* The panel's proposal block: why, and what changes */
498
- .hx-proposal-sec { padding: 8px 10px; border: 1px solid var(--hx-line); border-left-width: 3px; border-radius: var(--radius-md, 8px); background: var(--hx-well-soft); margin: 0 0 6px; font-family: var(--font-sans, sans-serif); }
499
- .hx-proposal-sec--added { border-left-color: var(--hx-mark-added); }
500
- .hx-proposal-sec--changed { border-left-color: var(--hx-mark-changed); }
501
- .hx-proposal-sec--removed { border-left-color: var(--hx-mark-removed); }
502
- .hx-proposal-sec--edit { border-left-color: var(--hx-mark-edit); }
503
- .hx-why { margin: 4px 0 6px; color: var(--hx-text-2); font-size: 12px; line-height: 1.5; }
504
- .hx-change { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; padding: 3px 0; border-top: 1px solid var(--hx-line-soft); font-family: var(--font-mono, monospace); font-size: 11px; }
505
- .hx-change-field { flex: none; min-width: 64px; color: var(--hx-slate-400); }
506
- .hx-change-before { color: var(--hx-red); text-decoration: line-through; text-decoration-color: rgba(252, 165, 165, 0.5); overflow-wrap: anywhere; }
507
- .hx-change-arrow { color: var(--hx-slate-500); }
508
- .hx-change-after { color: var(--hx-green-text); overflow-wrap: anywhere; }
509
- .hx-change em { color: var(--hx-slate-500); text-decoration: none; }
373
+ .hx-proposal-sec { padding: var(--corn-space-3) var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-left-width: var(--corn-border-strong); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); margin: 0 0 var(--corn-space-2); font-family: var(--corn-font); }
374
+ .hx-proposal-sec--added { border-left-color: var(--corn-added); }
375
+ .hx-proposal-sec--changed { border-left-color: var(--corn-changed); }
376
+ .hx-proposal-sec--removed { border-left-color: var(--corn-removed); }
377
+ .hx-proposal-sec--edit { border-left-color: var(--corn-edit); }
378
+ .hx-why { margin: var(--corn-space-1) 0 var(--corn-space-2); color: var(--corn-text-2); font-size: var(--corn-text-sm); line-height: 1.5; }
379
+ .hx-change { display: flex; flex-wrap: wrap; align-items: baseline; gap: calc(var(--corn-space-1) / 2) var(--corn-space-3); padding: var(--corn-space-1) 0; border-top: var(--corn-border) solid var(--corn-line-soft); font-family: var(--corn-mono); font-size: var(--corn-text-xs); }
380
+ .hx-change-field { flex: none; min-width: 64px; color: var(--corn-text-3); }
381
+ .hx-change-before { color: var(--corn-bad); text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--corn-bad) 50%, transparent); overflow-wrap: anywhere; }
382
+ .hx-change-arrow { color: var(--corn-text-3); }
383
+ .hx-change-after { color: var(--corn-ok); overflow-wrap: anywhere; }
384
+ .hx-change em { color: var(--corn-text-3); text-decoration: none; }
510
385
 
511
386
  /* The node panel is a 480px slide-over from 768px: the bar makes room for it */
512
387
  @media (min-width: 768px) { .hx-stage:has(.drawer-open) .hx-proposal-bar { width: min(720px, calc(100% - 504px)); } }
513
388
 
514
389
  @media (max-width: 639px) {
515
390
  .hx-menu--proposals { position: fixed; top: 60px; left: 12px; right: 12px; width: auto; max-width: none; }
516
- .hx-seg-btn { padding: 4px 14px; }
391
+ .hx-seg-btn { padding: var(--corn-space-1) var(--corn-space-4); }
517
392
  }
518
393
 
519
394
  /* ---- scenario player (scenario-ui.js): the bar while a scenario plays, and the scenario list --------- */
520
- .hx-player { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); width: min(560px, calc(100% - 24px)); display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 14px; border-radius: var(--radius-xl, 16px); z-index: 25; overflow: hidden; }
395
+ .hx-player { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); width: min(560px, calc(100% - 24px)); display: flex; flex-direction: column; gap: var(--corn-space-3); padding: var(--corn-space-4) var(--corn-space-4) var(--corn-space-4); border-radius: var(--corn-radius-lg); z-index: 25; overflow: hidden; }
521
396
  @media (max-width: 639px) { .hx-player { left: 12px; right: 56px; width: auto; transform: none; } }
522
- .hx-player-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
523
- .hx-player-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: var(--weight-semibold, 600); color: var(--hx-slate-300); }
524
- .hx-player .hx-close { width: 28px; height: 28px; font-size: 12px; }
397
+ .hx-player-head { display: flex; align-items: center; justify-content: space-between; gap: var(--corn-space-3); }
398
+ .hx-player-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--corn-text-sm); font-weight: 600; color: var(--corn-text-2); }
399
+ .hx-player .hx-close { width: 28px; height: 28px; font-size: var(--corn-text-sm); }
525
400
  .hx-player-title { flex: 1; }
526
- .hx-player-speed { flex: none; height: 28px; padding: 0 6px; border-radius: var(--radius-md, 8px); border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font: inherit; font-size: 12px; cursor: pointer; }
527
- .hx-player-speed:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 1px; }
528
- .hx-player-text { margin: 0; min-height: 2.8em; font-size: 14px; line-height: 1.4; color: var(--hx-ink); user-select: text; }
529
- .hx-player-count { color: var(--hx-indigo); font-weight: var(--weight-semibold, 600); white-space: nowrap; }
530
- .hx-player-controls { display: flex; gap: 8px; }
401
+ .hx-player-speed { flex: none; height: 28px; padding: 0 var(--corn-space-2); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font: inherit; font-size: var(--corn-text-sm); cursor: pointer; }
402
+ .hx-player-speed:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 1px; }
403
+ .hx-player-text { margin: 0; min-height: 2.8em; font-size: var(--corn-text-base); line-height: 1.4; color: var(--corn-text); user-select: text; }
404
+ .hx-player-count { color: var(--corn-accent-text); font-weight: 600; white-space: nowrap; }
405
+ .hx-player-controls { display: flex; gap: var(--corn-space-3); }
531
406
  .hx-player-controls .hx-btn { flex: 1; justify-content: center; }
532
407
  .hx-player-controls .hx-btn:disabled { opacity: 0.4; cursor: default; }
533
- .hx-player-track { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--hx-line-soft); }
534
- .hx-player-fill { display: block; height: 100%; width: 0; background: var(--hx-indigo); }
408
+ .hx-player-track { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--corn-line-soft); }
409
+ .hx-player-fill { display: block; height: 100%; width: 0; background: var(--corn-accent-text); }
535
410
 
536
- .hx-scenarios { position: absolute; top: 12px; left: 12px; max-width: min(320px, calc(100% - 24px)); padding: 6px 10px; border-radius: var(--radius-lg, 12px); font-size: 12px; color: var(--hx-slate-300); z-index: 12; }
537
- .hx-scenarios summary { cursor: pointer; font-weight: var(--weight-semibold, 600); }
538
- .hx-scenarios-item { display: block; width: 100%; margin-top: 6px; padding: 6px 8px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md, 8px); background: transparent; color: var(--hx-ink); font-size: 12px; text-align: left; cursor: pointer; }
539
- .hx-scenarios-item:hover { background: rgba(99, 102, 241, 0.25); }
411
+ .hx-scenarios { position: absolute; top: 12px; left: 12px; max-width: min(320px, calc(100% - 24px)); padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius); font-size: var(--corn-text-sm); color: var(--corn-text-2); z-index: 12; }
412
+ .hx-scenarios summary { cursor: pointer; font-weight: 600; }
413
+ .hx-scenarios-item { display: block; width: 100%; margin-top: var(--corn-space-2); padding: var(--corn-space-2) var(--corn-space-3); border: var(--corn-border) solid var(--corn-line-soft); border-radius: var(--corn-radius-sm); background: transparent; color: var(--corn-text); font-size: var(--corn-text-sm); text-align: left; cursor: pointer; }
414
+ .hx-scenarios-item:hover { background: color-mix(in srgb, var(--corn-accent-hover) 25%, transparent); }
540
415
  /* With a proposal open the list is a row of its bar (scenario-ui.js mounts it there), so it opens in the bar's flow and the bar grows to hold it */
541
- .hx-proposal-bar .hx-scenarios { position: static; max-width: none; max-height: 40dvh; margin-top: 6px; padding: 6px 8px; overflow-y: auto; border-radius: var(--radius-md, 8px); border-color: var(--hx-line); background: var(--hx-well-soft); box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
416
+ .hx-proposal-bar .hx-scenarios { position: static; max-width: none; max-height: 40dvh; margin-top: var(--corn-space-2); padding: var(--corn-space-2) var(--corn-space-3); overflow-y: auto; border-radius: var(--corn-radius-sm); border-color: var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; }
542
417
 
543
418
  /* ---- what-if editing (whatif.js): the controls under the proposal bar, the drag that draws an edge ---- */
544
- .hx-whatif { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(167, 139, 250, 0.3); }
419
+ .hx-whatif { margin-top: var(--corn-space-3); padding-top: var(--corn-space-3); border-top: var(--corn-border) solid color-mix(in srgb, var(--corn-edit) 30%, transparent); }
545
420
  .hx-whatif[hidden] { display: none; }
546
- .hx-whatif-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
421
+ .hx-whatif-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2); }
547
422
  .hx-whatif .hx-btn:disabled { opacity: 0.4; cursor: default; }
548
- .hx-whatif .hx-btn[aria-pressed="true"], .hx-whatif .hx-btn--active { background: #6d28d9; border-color: #a78bfa; color: #fff; }
549
- .hx-whatif-hint { margin: 6px 0 0; color: var(--hx-violet-text); }
550
- .hx-whatif-msg { margin: 6px 0 0; padding: 4px 8px; border-radius: var(--radius-md, 8px); background: rgba(248, 113, 113, 0.12); border: 1px solid rgba(248, 113, 113, 0.35); color: var(--hx-red); line-height: 1.4; }
423
+ .hx-whatif .hx-btn[aria-pressed="true"], .hx-whatif .hx-btn--active { background: var(--corn-edit-text); border-color: var(--corn-edit); color: var(--corn-ground); }
424
+ .hx-whatif-hint { margin: var(--corn-space-2) 0 0; color: var(--corn-edit-text); }
425
+ .hx-whatif-msg { margin: var(--corn-space-2) 0 0; padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-removed) 12%, transparent); border: var(--corn-border) solid color-mix(in srgb, var(--corn-removed) 35%, transparent); color: var(--corn-bad); line-height: 1.4; }
551
426
  .hx-whatif-msg[hidden], .hx-whatif-hint[hidden], .hx-whatif-notice[hidden], .hx-whatif-panel[hidden] { display: none; }
552
- .hx-whatif-notice { margin: 6px 0 0; color: var(--hx-amber); }
553
- .hx-whatif-panel { margin-top: 8px; padding: 8px 10px; border-radius: var(--radius-md, 8px); background: var(--hx-well-soft); border: 1px solid rgba(167, 139, 250, 0.25); max-height: min(40vh, 320px); overflow: auto; }
554
- .hx-whatif-form { display: flex; flex-direction: column; gap: 6px; }
555
- .hx-whatif-field { display: flex; align-items: center; gap: 8px; color: var(--hx-slate-300); }
427
+ .hx-whatif-notice { margin: var(--corn-space-2) 0 0; color: var(--corn-warn); }
428
+ .hx-whatif-panel { margin-top: var(--corn-space-3); padding: var(--corn-space-3) var(--corn-space-3); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); border: var(--corn-border) solid color-mix(in srgb, var(--corn-edit) 25%, transparent); max-height: min(40vh, 320px); overflow: auto; }
429
+ .hx-whatif-form { display: flex; flex-direction: column; gap: var(--corn-space-2); }
430
+ .hx-whatif-field { display: flex; align-items: center; gap: var(--corn-space-3); color: var(--corn-text-2); }
556
431
  .hx-whatif-field > select, .hx-whatif-field > .hx-whatif-input { flex: 1; min-width: 0; }
557
- .hx-whatif-input, .hx-whatif-field select, .hx-whatif select { padding: 4px 8px; border-radius: var(--radius-md, 8px); border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font: inherit; font-size: 12px; user-select: text; }
558
- .hx-whatif-input:focus, .hx-whatif-field select:focus { outline: 2px solid #a78bfa; outline-offset: 1px; }
559
- .hx-whatif-help { margin: 0; font-size: 11px; }
432
+ .hx-whatif-input, .hx-whatif-field select, .hx-whatif select { padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font: inherit; font-size: var(--corn-text-sm); user-select: text; }
433
+ .hx-whatif-input:focus, .hx-whatif-field select:focus { outline: var(--corn-focus-width) solid var(--corn-edit); outline-offset: 1px; }
434
+ .hx-whatif-help { margin: 0; font-size: var(--corn-text-xs); }
560
435
  .hx-whatif-pair { margin: 0; }
561
- .hx-whatif-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
562
- .hx-whatif-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
563
- .hx-whatif-edit { display: flex; align-items: center; gap: 8px; }
436
+ .hx-whatif-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2); }
437
+ .hx-whatif-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: var(--corn-space-1); }
438
+ .hx-whatif-edit { display: flex; align-items: center; gap: var(--corn-space-3); }
564
439
  .hx-whatif-edit-text { flex: 1; min-width: 0; line-height: 1.35; }
565
- .hx-whatif-step { display: flex; align-items: flex-start; gap: 6px; padding: 4px; border-radius: var(--radius-md, 8px); }
566
- .hx-whatif-step.is-current { background: rgba(167, 139, 250, 0.18); }
567
- .hx-whatif-num { flex: none; width: 22px; height: 22px; border: 0; border-radius: 50%; background: rgba(167, 139, 250, 0.3); color: var(--hx-ink); font-size: 11px; font-weight: var(--weight-bold, 700); cursor: pointer; }
568
- .hx-whatif-stepbody { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
440
+ .hx-whatif-step { display: flex; align-items: flex-start; gap: var(--corn-space-2); padding: var(--corn-space-1); border-radius: var(--corn-radius-sm); }
441
+ .hx-whatif-step.is-current { background: color-mix(in srgb, var(--corn-edit) 18%, transparent); }
442
+ .hx-whatif-num { flex: none; width: 22px; height: 22px; border: 0; border-radius: 50%; background: color-mix(in srgb, var(--corn-edit) 30%, transparent); color: var(--corn-text); font-size: var(--corn-text-xs); font-weight: 700; cursor: pointer; }
443
+ .hx-whatif-stepbody { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: calc(var(--corn-space-1) / 2); }
569
444
  .hx-whatif-stepbody .hx-whatif-input { width: 100%; }
570
- .hx-whatif-target { font-size: 11px; }
571
- .hx-whatif-addstep { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
445
+ .hx-whatif-target { font-size: var(--corn-text-xs); }
446
+ .hx-whatif-addstep { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2); margin-top: var(--corn-space-3); }
572
447
  .hx-whatif-addstep .hx-whatif-field { flex: 1 1 220px; }
573
- .hx-whatif-drawer .hx-btn { margin-top: 4px; }
574
- .hx-whatif-edges { margin-top: 8px; color: var(--hx-slate-300); }
448
+ .hx-whatif-drawer .hx-btn { margin-top: var(--corn-space-1); }
449
+ .hx-whatif-edges { margin-top: var(--corn-space-3); color: var(--corn-text-2); }
575
450
  .hx-whatif-edges summary { cursor: pointer; }
576
- .hx-whatif-edges .hx-whatif-list { margin-top: 6px; max-height: 200px; overflow: auto; }
451
+ .hx-whatif-edges .hx-whatif-list { margin-top: var(--corn-space-2); max-height: 200px; overflow: auto; }
577
452
  #graph-canvas.is-drawing-edge { touch-action: none; }
578
453
  .hx-rubber { position: absolute; inset: 0; pointer-events: none; z-index: 14; }
579
454
  .hx-rubber svg { display: block; overflow: visible; }
580
- .hx-rubber-line { stroke: var(--hx-mark-edit, #a78bfa); stroke-width: 3; stroke-dasharray: 8 6; stroke-linecap: round; }
581
- .hx-rubber-from, .hx-rubber-to { fill: rgba(167, 139, 250, 0.15); stroke: var(--hx-mark-edit, #a78bfa); stroke-width: 2; }
455
+ .hx-rubber-line { stroke: var(--corn-edit); stroke-width: 3; stroke-dasharray: 8 6; stroke-linecap: round; }
456
+ .hx-rubber-from, .hx-rubber-to { fill: color-mix(in srgb, var(--corn-edit) 15%, transparent); stroke: var(--corn-edit); stroke-width: 2; }
582
457
  /* Approve and send back (review.js, TOPO-12): under the edit controls on the proposal bar */
583
- .hx-review { margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(45, 212, 191, 0.3); display: flex; flex-direction: column; gap: 6px; }
458
+ .hx-review { margin-top: var(--corn-space-3); padding-top: var(--corn-space-3); border-top: var(--corn-border) solid color-mix(in srgb, var(--corn-added) 30%, transparent); display: flex; flex-direction: column; gap: var(--corn-space-2); }
584
459
  .hx-review[hidden] { display: none; }
585
- .hx-review-label { color: var(--hx-slate-400); font-size: 11px; }
586
- .hx-review-note { width: 100%; min-height: 44px; resize: vertical; padding: 6px 8px; border-radius: var(--radius-md, 8px); border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font: inherit; font-size: 12px; line-height: 1.4; user-select: text; }
587
- .hx-review-note:focus { outline: 2px solid var(--hx-mark-added); outline-offset: 1px; }
588
- .hx-review-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
460
+ .hx-review-label { color: var(--corn-text-3); font-size: var(--corn-text-xs); }
461
+ .hx-review-note { width: 100%; min-height: 44px; resize: vertical; padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font: inherit; font-size: var(--corn-text-sm); line-height: 1.4; user-select: text; }
462
+ .hx-review-note:focus { outline: var(--corn-focus-width) solid var(--corn-added); outline-offset: 1px; }
463
+ .hx-review-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-2) var(--corn-space-3); }
589
464
  .hx-review .hx-btn:disabled { opacity: 0.4; cursor: default; }
590
- .hx-btn--approve { border-color: rgba(45, 212, 191, 0.5); color: var(--hx-teal-strong); }
591
- .hx-btn--approve:hover { background: rgba(45, 212, 191, 0.2); color: var(--hx-teal-strong); }
592
- .hx-review-status { color: var(--hx-teal-text); font-variant-numeric: tabular-nums; }
465
+ .hx-btn--approve { border-color: color-mix(in srgb, var(--corn-added) 50%, transparent); color: var(--corn-added-text); }
466
+ .hx-btn--approve:hover { background: color-mix(in srgb, var(--corn-added) 20%, transparent); color: var(--corn-added-text); }
467
+ .hx-review-status { color: var(--corn-added-text); font-variant-numeric: tabular-nums; }
593
468
  .hx-review-status[hidden], .hx-review-msg[hidden], .hx-review-line[hidden] { display: none; }
594
- .hx-review-msg { margin: 0; padding: 4px 8px; border-radius: var(--radius-md, 8px); background: rgba(248, 113, 113, 0.12); border: 1px solid rgba(248, 113, 113, 0.35); color: var(--hx-red); line-height: 1.4; }
595
- .hx-review-line { margin: 0; color: var(--hx-slate-300); line-height: 1.4; }
596
- .hx-proposal-reviewed { color: var(--hx-teal-text); }
469
+ .hx-review-msg { margin: 0; padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); background: color-mix(in srgb, var(--corn-removed) 12%, transparent); border: var(--corn-border) solid color-mix(in srgb, var(--corn-removed) 35%, transparent); color: var(--corn-bad); line-height: 1.4; }
470
+ .hx-review-line { margin: 0; color: var(--corn-text-2); line-height: 1.4; }
471
+ .hx-proposal-reviewed { color: var(--corn-added-text); }
597
472
  /* A proposal's mockups (mockups.js): the buttons in a node's panel and the window one opens in. A mockup is untrusted content, shown in an <img> or a sandboxed <iframe>. */
598
- .hx-mockup-list { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
599
- .hx-mockup-item { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
473
+ .hx-mockup-list { list-style: none; margin: var(--corn-space-1) 0 0; padding: 0; display: flex; flex-direction: column; gap: var(--corn-space-2); }
474
+ .hx-mockup-item { display: flex; flex-wrap: wrap; align-items: center; gap: var(--corn-space-1) var(--corn-space-3); }
600
475
  .hx-mockup-open { max-width: 100%; white-space: normal; text-align: left; }
601
- .hx-mockup-state { margin: 0; font-size: 11px; color: var(--hx-slate-300); }
602
- .hx-mockup-state--approved { color: var(--hx-teal-text); }
603
- .hx-mockup-state--changed { color: var(--hx-amber); font-weight: 600; }
604
- .hx-mockup-state--missing { color: var(--hx-red); }
605
- .hx-mockup-dialog { position: fixed; z-index: 60; top: 50%; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; gap: 8px; width: min(960px, calc(100vw - 32px)); max-height: calc(100vh - 32px); padding: 12px 14px 14px; border-radius: var(--radius-xl, 16px); border: 1px solid var(--border-glass); background: var(--hx-slate-900); color: var(--hx-text); box-shadow: var(--glass-shadow), 0 0 0 100vmax var(--hx-backdrop); }
606
- .hx-mockup-dialog:focus { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
607
- .hx-mockup-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
608
- .hx-mockup-title { margin: 0; font-size: 14px; font-weight: 600; color: var(--hx-text-1); }
609
- .hx-mockup-stage { min-height: 0; overflow: auto; display: flex; justify-content: center; border-radius: var(--radius-md, 8px); border: 1px solid var(--hx-line); background: #fff; }
476
+ .hx-mockup-state { margin: 0; font-size: var(--corn-text-xs); color: var(--corn-text-2); }
477
+ .hx-mockup-state--approved { color: var(--corn-added-text); }
478
+ .hx-mockup-state--changed { color: var(--corn-warn); font-weight: 600; }
479
+ .hx-mockup-state--missing { color: var(--corn-bad); }
480
+ .hx-mockup-dialog { position: fixed; z-index: 60; top: 50%; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; gap: var(--corn-space-3); width: min(960px, calc(100vw - 32px)); max-height: calc(100vh - 32px); padding: var(--corn-space-4) var(--corn-space-4) var(--corn-space-4); border-radius: var(--corn-radius-lg); border: var(--corn-border) solid var(--corn-line); background: var(--corn-ground); color: var(--corn-text); box-shadow: var(--corn-shadow), 0 0 0 100vmax var(--corn-scrim); }
481
+ .hx-mockup-dialog:focus { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
482
+ .hx-mockup-head { display: flex; align-items: center; justify-content: space-between; gap: var(--corn-space-4); }
483
+ .hx-mockup-title { margin: 0; font-size: var(--corn-text-base); font-weight: 600; color: var(--corn-text); }
484
+ .hx-mockup-stage { min-height: 0; overflow: auto; display: flex; justify-content: center; border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: var(--corn-mockup-ground); }
610
485
  .hx-mockup-img { display: block; max-width: 100%; height: auto; object-fit: contain; }
611
- .hx-mockup-frame { display: block; width: 100%; height: min(560px, calc(100vh - 140px)); border: 0; background: #fff; }
486
+ .hx-mockup-frame { display: block; width: 100%; height: min(560px, calc(100vh - 140px)); border: 0; background: var(--corn-mockup-ground); }
612
487
 
613
488
  /* /?bench=1: the run's numbers, bottom left (bench.js) */
614
- .bench-readout { position: fixed; left: 12px; bottom: 12px; z-index: 50; max-width: calc(100vw - 24px); padding: 8px 12px; border-radius: var(--radius-md, 8px); border: 1px solid var(--border-glass); background: var(--surface-glass-header); color: var(--hx-text-2); font-family: var(--font-mono, monospace); font-size: 11px; line-height: 1.5; pointer-events: none; }
489
+ .bench-readout { position: fixed; left: 12px; bottom: 12px; z-index: 50; max-width: calc(100vw - 24px); padding: var(--corn-space-3) var(--corn-space-4); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 88%, transparent); color: var(--corn-text-2); font-family: var(--corn-mono); font-size: var(--corn-text-xs); line-height: 1.5; pointer-events: none; }
615
490
  .bench-readout p { margin: 0; }
616
491
 
617
492
  /* ---- phone bottom sheets (sheets.js, TOPO-18) ----------------------------------------------------
@@ -626,18 +501,18 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
626
501
  @media (max-width: 767px) {
627
502
  .hx-dock { position: absolute; left: 0; right: 0; bottom: 0; z-index: 45; display: flex; flex-direction: column; justify-content: flex-end; pointer-events: none; }
628
503
  .hx-dock > * { pointer-events: auto; }
629
- .hx-dock > .hx-sheet { position: relative; top: auto; left: auto; right: auto; bottom: auto; width: 100%; max-width: none; margin: 0; transform: none; border-radius: 20px 20px 0 0; border-bottom: 0; box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.35); overscroll-behavior: contain; animation: hx-sheet-in 0.2s ease-out; --sheet-pb: 10px; }
504
+ .hx-dock > .hx-sheet { position: relative; top: auto; left: auto; right: auto; bottom: auto; width: 100%; max-width: none; margin: 0; transform: none; border-radius: var(--corn-radius-lg) var(--corn-radius-lg) 0 0; border-bottom: 0; box-shadow: 0 -8px 24px color-mix(in srgb, var(--corn-shadow-color) 70%, transparent); overscroll-behavior: contain; animation: hx-sheet-in 0.2s ease-out; --sheet-pb: var(--corn-space-3); }
630
505
  .hx-dock > .hx-sheet[data-sheet-last]:not(.hx-drawer), .hx-dock > .hx-drawer[data-sheet-last][data-sheet-state="peek"] { padding-bottom: calc(var(--sheet-pb) + env(safe-area-inset-bottom, 0px)); }
631
506
  .hx-sheet-handle { display: flex; flex: none; align-items: center; justify-content: center; width: 100%; height: 22px; padding: 0; border: 0; background: none; cursor: grab; touch-action: none; }
632
- .hx-sheet-handle span { width: 40px; height: 5px; border-radius: 9999px; background: var(--hx-slate-700); }
633
- .hx-sheet-handle:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: -2px; border-radius: 12px; }
507
+ .hx-sheet-handle span { width: 40px; height: 5px; border-radius: var(--corn-radius-pill); background: var(--corn-surface-3); }
508
+ .hx-sheet-handle:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: -2px; border-radius: var(--corn-radius); }
634
509
  .hx-backdrop { display: none; }
635
510
  .hx-stage[data-sheet-open="drawer"] .hx-backdrop:not([hidden]) { display: block; }
636
511
  /* The zoom buttons ride above the sheets */
637
512
  .hx-mobile-zoom { bottom: calc(16px + var(--hx-covered, 0px)); }
638
513
 
639
514
  /* The proposal bar */
640
- .hx-proposal-bar { max-height: 50dvh; overflow-y: auto; padding: 0 12px 10px; }
515
+ .hx-proposal-bar { max-height: 50dvh; overflow-y: auto; padding: 0 var(--corn-space-4) var(--corn-space-3); }
641
516
  .hx-proposal-bar[data-sheet-state="peek"] > :not(.hx-sheet-handle):not(#proposal-message):not(#proposal-body),
642
517
  .hx-proposal-bar[data-sheet-state="peek"] #proposal-body > :not(.hx-proposal-head),
643
518
  .hx-proposal-bar[data-sheet-state="peek"] .hx-proposal-head > :not(.hx-proposal-name):not(.hx-proposal-chip) { display: none; }
@@ -645,14 +520,14 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
645
520
  .hx-proposal-bar[data-sheet-state="expanded"] .hx-scenarios, .hx-proposal-bar[data-sheet-state="expanded"] .hx-proposal-changes, .hx-proposal-bar[data-sheet-state="expanded"] .hx-whatif-panel { max-height: none; overflow: visible; }
646
521
 
647
522
  /* The scenario player: the title, then the step counter and its text on two lines */
648
- .hx-player { max-height: 50dvh; overflow: hidden; gap: 6px; padding: 0 14px 12px; --sheet-pb: 12px; }
523
+ .hx-player { max-height: 50dvh; overflow: hidden; gap: var(--corn-space-2); padding: 0 var(--corn-space-4) var(--corn-space-4); --sheet-pb: var(--corn-space-4); }
649
524
  .hx-player[data-sheet-state="expanded"] { overflow-y: auto; }
650
525
  .hx-player[data-sheet-state="peek"] > :not(.hx-sheet-handle):not(.hx-player-head):not(.hx-player-text):not(.hx-player-track) { display: none; }
651
- .hx-player[data-sheet-state="peek"] .hx-player-text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; min-height: 0; overflow: hidden; font-size: 13px; }
526
+ .hx-player[data-sheet-state="peek"] .hx-player-text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; min-height: 0; overflow: hidden; font-size: var(--corn-text-md); }
652
527
 
653
528
  /* The node panel: its title and type until expanded */
654
529
  .hx-drawer { max-height: 60dvh; }
655
- .hx-drawer[data-sheet-state="peek"] .hx-drawer-body { flex: none; padding: 0 16px 10px; gap: 0; overflow: hidden; }
530
+ .hx-drawer[data-sheet-state="peek"] .hx-drawer-body { flex: none; padding: 0 var(--corn-space-5) var(--corn-space-3); gap: 0; overflow: hidden; }
656
531
  .hx-drawer[data-sheet-state="peek"] .hx-drawer-body > :not(.hx-drawer-head), .hx-drawer[data-sheet-state="peek"] .hx-drawer-foot { display: none; }
657
532
  .hx-drawer[data-sheet-state="peek"] .hx-drawer-head { padding-bottom: 0; border-bottom: 0; }
658
533
  .hx-drawer[data-sheet-state="peek"] .hx-drawer-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@@ -666,27 +541,27 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
666
541
  /* ---- the live layer (live.js, spec 0029): the chip in the toolbar, its menu, and its part of the node panel ---- */
667
542
  .hx-live-chip { max-width: 240px; min-width: 0; }
668
543
  @media (min-width: 768px) { .hx-live-chip-text { display: inline-block; min-width: 0; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; } }
669
- .hx-live-chip-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--hx-slate-500); }
670
- .hx-live[data-tone="ok"] .hx-live-chip-dot { background: #34d399; box-shadow: 0 0 6px rgba(52, 211, 153, 0.7); }
671
- .hx-live[data-tone="stale"] .hx-live-chip-dot { background: #fbbf24; }
672
- .hx-live[data-tone="error"] .hx-live-chip-dot { background: #f87171; box-shadow: 0 0 6px rgba(248, 113, 113, 0.6); }
673
- .hx-live[data-tone="error"] .hx-live-chip { border-color: rgba(248, 113, 113, 0.4); }
544
+ .hx-live-chip-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--corn-text-3); }
545
+ .hx-live[data-tone="ok"] .hx-live-chip-dot { background: var(--corn-ok); box-shadow: 0 0 calc(var(--corn-glow) * 0.75) color-mix(in srgb, var(--corn-ok) 70%, transparent); }
546
+ .hx-live[data-tone="stale"] .hx-live-chip-dot { background: var(--corn-changed); }
547
+ .hx-live[data-tone="error"] .hx-live-chip-dot { background: var(--corn-removed); box-shadow: 0 0 calc(var(--corn-glow) * 0.75) color-mix(in srgb, var(--corn-removed) 60%, transparent); }
548
+ .hx-live[data-tone="error"] .hx-live-chip { border-color: color-mix(in srgb, var(--corn-removed) 40%, transparent); }
674
549
  .hx-menu--live { width: 320px; }
675
- .hx-live-line { margin: 0 0 6px; color: var(--hx-slate-300); font-size: 12px; line-height: 1.4; user-select: text; }
676
- .hx-live-line--main { color: var(--hx-ink); font-weight: 600; }
677
- .hx-live-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; }
678
- .hx-live-tag { margin-left: 6px; padding: 0 5px; border-radius: 4px; background: rgba(52, 211, 153, 0.15); color: var(--hx-emerald); font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
679
- .hx-live-photo { display: block; max-width: 100%; max-height: 180px; margin: 6px 0; border-radius: var(--radius-md, 8px); object-fit: cover; }
680
- .hx-live-list { margin: 4px 0 0; padding: 0 0 0 4px; list-style: none; font-size: 12px; line-height: 1.6; }
550
+ .hx-live-line { margin: 0 0 var(--corn-space-2); color: var(--corn-text-2); font-size: var(--corn-text-sm); line-height: 1.4; user-select: text; }
551
+ .hx-live-line--main { color: var(--corn-text); font-weight: 600; }
552
+ .hx-live-row { display: flex; align-items: center; justify-content: space-between; gap: var(--corn-space-3); margin-top: var(--corn-space-3); }
553
+ .hx-live-tag { margin-left: var(--corn-space-2); padding: 0 var(--corn-space-1); border-radius: var(--corn-radius-xs); background: var(--corn-ok-soft); color: var(--corn-ok); font-size: var(--corn-text-2xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
554
+ .hx-live-photo { display: block; max-width: 100%; max-height: 180px; margin: var(--corn-space-2) 0; border-radius: var(--corn-radius-sm); object-fit: cover; }
555
+ .hx-live-list { margin: var(--corn-space-1) 0 0; padding: 0 0 0 var(--corn-space-1); list-style: none; font-size: var(--corn-text-sm); line-height: 1.6; }
681
556
  /* The token field (live.js): shown while the live layer is off for want of a token */
682
- .hx-live-token { margin: 10px 0 4px; padding-top: 10px; border-top: 1px solid var(--hx-line-soft); }
683
- .hx-live-token-label { display: block; margin-bottom: 4px; color: var(--hx-ink); font-size: 12px; font-weight: 600; }
684
- .hx-live-token-row { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; }
685
- .hx-live-token-input { flex: 1; min-width: 0; padding: 6px 8px; font-size: 12px; }
686
- .hx-live-token-input:focus { outline: none; border-color: #6366f1; }
687
- .hx-live-help code { font-family: var(--pop-font-mono); font-size: 10.5px; color: var(--hx-slate-300); overflow-wrap: anywhere; }
688
- .hx-live-second { font-size: 11px; }
689
- .hx-live-buttons { display: inline-flex; gap: 6px; }
557
+ .hx-live-token { margin: var(--corn-space-3) 0 var(--corn-space-1); padding-top: var(--corn-space-3); border-top: var(--corn-border) solid var(--corn-line-soft); }
558
+ .hx-live-token-label { display: block; margin-bottom: var(--corn-space-1); color: var(--corn-text); font-size: var(--corn-text-sm); font-weight: 600; }
559
+ .hx-live-token-row { display: flex; gap: var(--corn-space-2); align-items: center; margin-bottom: var(--corn-space-2); }
560
+ .hx-live-token-input { flex: 1; min-width: 0; padding: var(--corn-space-2) var(--corn-space-3); font-size: var(--corn-text-sm); }
561
+ .hx-live-token-input:focus { outline: none; border-color: var(--corn-accent-hover); }
562
+ .hx-live-help code { font-family: var(--corn-mono); font-size: var(--corn-text-2xs); color: var(--corn-text-2); overflow-wrap: anywhere; }
563
+ .hx-live-second { font-size: var(--corn-text-xs); }
564
+ .hx-live-buttons { display: inline-flex; gap: var(--corn-space-2); }
690
565
  @media (max-width: 639px) {
691
566
  .hx-menu--live { position: fixed; top: 60px; left: 12px; right: 12px; width: auto; max-width: none; }
692
567
  }
@@ -695,72 +570,59 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
695
570
 
696
571
  /* ── Checked scenarios (PHY-10, check.js): the step's state on the player bar and the phone's sheet ──
697
572
  The pill sits in the head, so the phone's peek shows it; the line and the As row are the expanded part. */
698
- .hx-player-verdict { flex: none; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: var(--weight-semibold, 600); white-space: nowrap; border: 1px solid var(--border-glass); color: var(--hx-slate-300); background: rgba(148, 163, 184, 0.12); }
699
- .hx-player-check { margin: 0; padding: 6px 10px; border-radius: var(--radius-md, 8px); font-size: 13px; line-height: 1.4; color: var(--hx-slate-300); background: rgba(148, 163, 184, 0.1); border-left: 3px solid rgba(148, 163, 184, 0.5); user-select: text; }
700
- .hx-player-check-detail { display: block; font-size: 11px; color: var(--hx-slate-400); }
701
- .hx-player-verdict[data-tone="allowed"], .hx-player-check[data-tone="allowed"] { color: var(--hx-green-text); background: rgba(74, 222, 128, 0.14); border-color: rgba(74, 222, 128, 0.6); }
702
- .hx-player-verdict[data-tone="refused"], .hx-player-check[data-tone="refused"] { color: var(--hx-red); background: rgba(248, 113, 113, 0.16); border-color: rgba(248, 113, 113, 0.7); }
703
- .hx-player-verdict[data-tone="mismatch"], .hx-player-check[data-tone="mismatch"] { color: var(--hx-code); background: rgba(251, 191, 36, 0.16); border-color: rgba(251, 191, 36, 0.7); }
573
+ .hx-player-verdict { flex: none; padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); border-radius: var(--corn-radius-pill); font-size: var(--corn-text-xs); font-weight: 600; white-space: nowrap; border: var(--corn-border) solid var(--corn-line); color: var(--corn-text-2); background: color-mix(in srgb, var(--corn-text-3) 12%, transparent); }
574
+ .hx-player-check { margin: 0; padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); font-size: var(--corn-text-md); line-height: 1.4; color: var(--corn-text-2); background: color-mix(in srgb, var(--corn-text-3) 10%, transparent); border-left: var(--corn-border-strong) solid color-mix(in srgb, var(--corn-text-3) 50%, transparent); user-select: text; }
575
+ .hx-player-check-detail { display: block; font-size: var(--corn-text-xs); color: var(--corn-text-3); }
576
+ .hx-player-verdict[data-tone="allowed"], .hx-player-check[data-tone="allowed"] { color: var(--corn-ok); background: var(--corn-ok-soft); border-color: color-mix(in srgb, var(--corn-ok) 60%, transparent); }
577
+ .hx-player-verdict[data-tone="refused"], .hx-player-check[data-tone="refused"] { color: var(--corn-bad); background: color-mix(in srgb, var(--corn-removed) 16%, transparent); border-color: color-mix(in srgb, var(--corn-removed) 70%, transparent); }
578
+ .hx-player-verdict[data-tone="mismatch"], .hx-player-check[data-tone="mismatch"] { color: var(--corn-warn); background: color-mix(in srgb, var(--corn-changed) 16%, transparent); border-color: color-mix(in srgb, var(--corn-changed) 70%, transparent); }
704
579
  .hx-player-verdict[data-tone="pending"] { opacity: 0.75; }
705
- .hx-player-as { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; color: var(--hx-slate-300); }
706
- .hx-player-as-label { display: inline-flex; align-items: center; gap: 6px; }
707
- .hx-player-as .hx-btn { padding: 4px 10px; font-size: 12px; }
580
+ .hx-player-as { display: flex; align-items: center; gap: var(--corn-space-3); flex-wrap: wrap; font-size: var(--corn-text-sm); color: var(--corn-text-2); }
581
+ .hx-player-as-label { display: inline-flex; align-items: center; gap: var(--corn-space-2); }
582
+ .hx-player-as .hx-btn { padding: var(--corn-space-1) var(--corn-space-3); font-size: var(--corn-text-sm); }
708
583
  .hx-player-as .hx-btn:disabled { opacity: 0.4; cursor: default; }
709
- .hx-player-as-sum { margin-left: auto; font-size: 11px; }
584
+ .hx-player-as-sum { margin-left: auto; font-size: var(--corn-text-xs); }
710
585
  .hx-player-as[hidden], .hx-player-verdict[hidden], .hx-player-check[hidden] { display: none; }
711
586
 
712
587
  /* ---- cloud nodes (spec 0031, CLOUD-06): the panel's badges, plan and Used by; the `when` line styles -- */
713
588
  /* The `when` swatches mirror cloud-model.js WHEN_STYLES (run solid, deploy dashed, renew dotted; red, amber, violet) */
714
- .hx-swatch-when { width: 18px; height: 2px; border-radius: 0; color: var(--hx-slate-300); background: currentColor; }
715
- .hx-swatch-when--run { color: #f87171; }
716
- .hx-swatch-when--deploy { color: #fbbf24; background: repeating-linear-gradient(90deg, currentColor 0 5px, transparent 5px 8px); }
717
- .hx-swatch-when--renew { color: #a78bfa; background: repeating-linear-gradient(90deg, currentColor 0 2px, transparent 2px 5px); }
718
- .hx-swatch-when--plain { color: var(--hx-slate-300); } /* the legend: the map draws every call in the calls colour, so only the pattern is the key */
719
- .hx-cloud-badges { display: flex; flex-wrap: wrap; gap: 4px; padding-top: 6px; }
720
- .hx-cloud-badge, .hx-cloud-plan { padding: 1px 7px; border-radius: 9999px; border: 1px solid rgba(148, 163, 184, 0.35); background: rgba(148, 163, 184, 0.12); color: var(--hx-slate-300); font-family: var(--pop-font-body); font-size: 10px; font-weight: 600; }
721
- .hx-cloud-badge--kind { border-color: rgba(125, 211, 252, 0.45); background: rgba(125, 211, 252, 0.15); color: var(--hx-sky); }
722
- .hx-cloud-badge--web { border-color: rgba(203, 213, 225, 0.45); background: rgba(203, 213, 225, 0.12); color: var(--hx-text-2); }
589
+ .hx-swatch-when { width: 18px; height: 2px; border-radius: 0; color: var(--corn-text-2); background: currentColor; }
590
+ .hx-swatch-when--run { color: var(--corn-removed); }
591
+ .hx-swatch-when--deploy { color: var(--corn-changed); background: repeating-linear-gradient(90deg, currentColor 0 5px, transparent 5px 8px); }
592
+ .hx-swatch-when--renew { color: var(--corn-edit); background: repeating-linear-gradient(90deg, currentColor 0 2px, transparent 2px 5px); }
593
+ .hx-swatch-when--plain { color: var(--corn-text-2); } /* the legend: the map draws every call in the calls colour, so only the pattern is the key */
594
+ .hx-cloud-badges { display: flex; flex-wrap: wrap; gap: var(--corn-space-1); padding-top: var(--corn-space-2); }
595
+ .hx-cloud-badge, .hx-cloud-plan { padding: calc(var(--corn-space-1) / 2) var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid color-mix(in srgb, var(--corn-text-3) 35%, transparent); background: color-mix(in srgb, var(--corn-text-3) 12%, transparent); color: var(--corn-text-2); font-family: var(--corn-font); font-size: var(--corn-text-2xs); font-weight: 600; }
596
+ .hx-cloud-badge--kind { border-color: color-mix(in srgb, var(--corn-info) 45%, transparent); background: var(--corn-info-soft); color: var(--corn-info); }
597
+ .hx-cloud-badge--web { border-color: color-mix(in srgb, var(--corn-text-2) 45%, transparent); background: color-mix(in srgb, var(--corn-text-2) 12%, transparent); color: var(--corn-text-2); }
723
598
  .hx-cloud-plan { margin-left: auto; }
724
- .hx-cloud-plan--free { border-color: rgba(52, 211, 153, 0.45); background: rgba(52, 211, 153, 0.12); color: var(--hx-emerald); }
725
- .hx-cloud-plan--paid { border-color: rgba(252, 211, 77, 0.5); background: rgba(252, 211, 77, 0.14); color: var(--hx-amber); }
726
- .hx-cloud-plan--unknown { border-style: dashed; color: var(--hx-slate-400); }
727
- .hx-cloud-plan--off { border-color: rgba(252, 165, 165, 0.45); background: rgba(252, 165, 165, 0.1); color: var(--hx-red); }
728
- .hx-cloud-plan-note { padding-top: 2px; text-align: right; font-size: 10px; }
729
- .hx-cloud-breaks { padding: 4px 0 2px; color: var(--hx-text-2); font-family: var(--pop-font-body); line-height: 1.5; }
730
- .hx-cloud-when { padding-top: 4px; }
731
- .hx-cloud-when-head { display: flex; align-items: center; gap: 6px; padding: 2px 0; font-weight: 600; }
599
+ .hx-cloud-plan--free { border-color: color-mix(in srgb, var(--corn-ok) 45%, transparent); background: var(--corn-ok-soft); color: var(--corn-ok); }
600
+ .hx-cloud-plan--paid { border-color: color-mix(in srgb, var(--corn-warn) 50%, transparent); background: var(--corn-warn-soft); color: var(--corn-warn); }
601
+ .hx-cloud-plan--unknown { border-style: dashed; color: var(--corn-text-3); }
602
+ .hx-cloud-plan--off { border-color: color-mix(in srgb, var(--corn-bad) 45%, transparent); background: var(--corn-bad-soft); color: var(--corn-bad); }
603
+ .hx-cloud-plan-note { padding-top: calc(var(--corn-space-1) / 2); text-align: right; font-size: var(--corn-text-2xs); }
604
+ .hx-cloud-breaks { padding: var(--corn-space-1) 0 calc(var(--corn-space-1) / 2); color: var(--corn-text-2); font-family: var(--corn-font); line-height: 1.5; }
605
+ .hx-cloud-when { padding-top: var(--corn-space-1); }
606
+ .hx-cloud-when-head { display: flex; align-items: center; gap: var(--corn-space-2); padding: calc(var(--corn-space-1) / 2) 0; font-weight: 600; }
732
607
  .hx-cloud-when-head .hx-swatch-when { flex: none; }
733
- .hx-cloud-fold > summary { cursor: pointer; padding: 2px 0 2px 16px; color: var(--hx-slate-300); }
734
- .hx-cloud-fold[open] > summary { color: var(--hx-text-2); }
735
- .hx-cloud-browser { color: var(--hx-sky); font-size: 10px; }
608
+ .hx-cloud-fold > summary { cursor: pointer; padding: calc(var(--corn-space-1) / 2) 0 calc(var(--corn-space-1) / 2) var(--corn-space-5); color: var(--corn-text-2); }
609
+ .hx-cloud-fold[open] > summary { color: var(--corn-text-2); }
610
+ .hx-cloud-browser { color: var(--corn-info); font-size: var(--corn-text-2xs); }
736
611
  .hx-cloud-play { width: 100%; justify-content: center; } /* the cloud panel's "Play: X is down" (spec 0031 section 8) */
737
612
 
738
- /* ---- light mode (MAP-01): what a token cannot say ------------------------------------------------
739
- A panel glyph's colour comes from script (the flow or kind it stands for, --glyph): on the light ground it
740
- is mixed with ink, so a pale yellow arrow still reads. The swatches and dots below mirror colours the map
741
- draws: their light values are theme-model.js `lightColor` of the dark ones, so the legend matches the map. */
742
- .hx-glyph { color: var(--glyph); color: color-mix(in srgb, var(--glyph) var(--hx-glyph-mix), #0f172a); }
743
- :root[data-theme="light"] .hx-swatch-when--run { color: #f64c4c; }
744
- :root[data-theme="light"] .hx-swatch-when--deploy { color: #b28103; }
745
- :root[data-theme="light"] .hx-swatch-when--renew { color: #9472f9; }
746
- :root[data-theme="light"] .hx-live[data-tone="ok"] .hx-live-chip-dot { background: #229c70; box-shadow: none; }
747
- :root[data-theme="light"] .hx-live[data-tone="stale"] .hx-live-chip-dot { background: #b28103; }
748
- :root[data-theme="light"] .hx-live[data-tone="error"] .hx-live-chip-dot { background: #f64c4c; box-shadow: none; }
749
- :root[data-theme="light"] .hx-live-dot { box-shadow: none; }
750
- :root[data-theme="light"] .hx-dots span { box-shadow: 0 0 0 1px #fff; }
751
- /* The closed panel waits just off the right edge: its shadow would show there on a light ground */
752
- :root[data-theme="light"] .hx-drawer { box-shadow: -10px 0 30px -12px rgba(15, 23, 42, 0.18); }
753
- :root[data-theme="light"] .hx-drawer:not(.drawer-open) { box-shadow: none; }
754
- :root[data-theme="light"] .hx-btn--active, :root[data-theme="light"] .hx-btn--active:hover, :root[data-theme="light"] .hx-seg-btn[aria-pressed="true"] { box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25); }
613
+ /* ---- a panel glyph (MAP-01) ----------------------------------------------------------------------
614
+ A panel glyph's colour comes from script (the flow or kind it stands for, --glyph): mixed with the text colour by
615
+ --corn-glyph-mix (all of it on dark, 45% on light), so a pale yellow arrow still reads on the light ground. */
616
+ .hx-glyph { color: var(--glyph); color: color-mix(in srgb, var(--glyph) var(--corn-glyph-mix), var(--corn-text)); }
755
617
 
756
618
  /* ---- keyboard and screen reader (MAP-02, keyboard.js) ------------------------------------------
757
619
  Text only a screen reader reads (the heading, the map's keys, the announcer); a focus ring on everything that
758
620
  takes the focus, the map included (the more specific rings above still win where they are set). */
759
- .hx-sr-only { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
760
- :where(button, a[href], summary, select, textarea, [tabindex]):focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
761
- #graph-canvas:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: -3px; }
621
+ .hx-sr-only { position: absolute !important; width: 1px; height: 1px; margin: 0; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
622
+ :where(button, a[href], summary, select, textarea, [tabindex]):focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
623
+ #graph-canvas:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: -3px; }
762
624
  .hx-drawer-title:focus { outline: none; }
763
- .hx-drawer-title:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
625
+ .hx-drawer-title:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
764
626
 
765
627
  /* Sign out (when sign-in is on): a form in the header, inline with the links */
766
628
  .cf-sign-out { display: inline-flex; margin: 0; }
@@ -773,14 +635,14 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
773
635
  .hx-brand { min-width: 24px; min-height: 24px; justify-content: center; }
774
636
  .hx-header .hx-btn { min-width: 24px; }
775
637
  .cf-sign-out .hx-btn { width: 28px; height: 28px; padding: 0; justify-content: center; }
776
- .cf-sign-out-icon { display: inline; font-size: 14px; }
777
- .cf-sign-out-text { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
638
+ .cf-sign-out-icon { display: inline; font-size: var(--corn-text-base); }
639
+ .cf-sign-out-text { position: absolute; width: 1px; height: 1px; margin: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
778
640
  }
779
641
  /* Narrower still (320px, the reflow width): the left of the header scrolls sideways rather than running under the
780
642
  right, so nothing overlaps; its menus open fixed under the header, as the Proposals and Live menus already do there,
781
643
  so the scroll cannot clip them. The padding keeps the focus rings inside the scrolled box. */
782
644
  @media (max-width: 639px) {
783
- .hx-header-left { overflow-x: auto; scrollbar-width: none; padding-block: 4px; }
645
+ .hx-header-left { overflow-x: auto; scrollbar-width: none; padding-block: var(--corn-space-1); }
784
646
  .hx-header-left::-webkit-scrollbar { display: none; }
785
647
  #legend-dropdown.hx-menu { position: fixed; top: 60px; left: 12px; right: 12px; width: auto; max-width: none; }
786
648
  }
@@ -788,17 +650,20 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
788
650
  /* ---- the issues and PRs panel (forge-panel.js, CF-07) -------------------------------------------
789
651
  A slide-over from the left from 768px (the node panel is the one from the right), a bottom sheet in #sheet-dock below.
790
652
  Closed, it is inert (forge-panel.js), and off screen or not displayed. Only the tokens above are used, so it follows the theme. */
791
- .hx-btn--forge { border-color: var(--hx-line); }
792
- .hx-btn--forge[aria-expanded="true"] { background: var(--hx-indigo-strong); border-color: var(--hx-indigo); color: #fff; }
793
- .hx-forge-lit { padding: 0 6px; border-radius: 9999px; border: 1px solid var(--hx-amber); background: var(--hx-well-soft); color: var(--hx-amber); font-family: var(--pop-font-mono); font-size: 10px; }
653
+ .hx-btn--forge { border-color: var(--corn-line); }
654
+ .hx-btn--forge[aria-expanded="true"] { background: var(--corn-accent); border-color: var(--corn-accent-text); color: var(--corn-text-on-accent); }
655
+ .hx-forge-lit { padding: 0 var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid var(--corn-warn); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-warn); font-family: var(--corn-mono); font-size: var(--corn-text-2xs); }
794
656
  @media (max-width: 767px) { .hx-btn--forge { width: 28px; height: 28px; padding: 0; justify-content: center; } .hx-forge-lit { display: none; } }
795
- .hx-forge { display: flex; flex-direction: column; z-index: 40; border-color: var(--hx-slate-800); pointer-events: none; touch-action: pan-y; transition: transform 0.2s ease-out; }
657
+ /* A changed file's status column, and the nodes under it that line up past it */
658
+ .hx-forge { --hx-forge-status-w: 56px; }
659
+ .hx-forge { display: flex; flex-direction: column; z-index: 40; border-color: var(--corn-surface-2); pointer-events: none; touch-action: pan-y; transition: transform 0.2s ease-out; }
796
660
  .hx-forge * { touch-action: pan-y; }
797
661
  .hx-forge.forge-open { pointer-events: auto; }
662
+ .hx-forge:not(.forge-open) { box-shadow: none; }
798
663
  @media (min-width: 768px) {
799
664
  /* The panel's width is the stage's `--hx-forge-w`, so what makes room for it reads the same number (the Runs view's compare widens it, below) */
800
665
  .hx-stage { --hx-forge-w: min(400px, calc(100% - 24px)); }
801
- .hx-forge { position: absolute; top: 0; left: 0; bottom: 0; width: var(--hx-forge-w); border-left: 0; transform: translateX(-100%); box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5); }
666
+ .hx-forge { position: absolute; top: 0; left: 0; bottom: 0; width: var(--hx-forge-w); border-left: 0; transform: translateX(-100%); box-shadow: var(--corn-shadow-lg); }
802
667
  .hx-forge.forge-open { transform: translateX(0); }
803
668
  /* The proposal bar and the player make room for it: 12px past its edge, and the node panel's 480px (+24) when that is open too */
804
669
  .hx-stage:has(.forge-open) .hx-proposal-bar { left: calc(var(--hx-forge-w) + 12px); width: min(720px, calc(100% - var(--hx-forge-w) - 36px)); }
@@ -807,124 +672,121 @@ button.hx-proposal-item:focus-visible { outline: 2px solid var(--hx-indigo); out
807
672
  @media (max-width: 767px) {
808
673
  .hx-forge:not(.forge-open) { display: none; }
809
674
  .hx-forge { max-height: 60dvh; }
810
- .hx-forge[data-sheet-state="peek"] .hx-forge-body { flex: none; padding: 0 16px 10px; gap: 4px; overflow: hidden; }
675
+ .hx-forge[data-sheet-state="peek"] .hx-forge-body { flex: none; padding: 0 var(--corn-space-5) var(--corn-space-3); gap: var(--corn-space-1); overflow: hidden; }
811
676
  .hx-forge[data-sheet-state="peek"] .hx-forge-body > :not(.hx-forge-head):not(#forge-status) { display: none; }
812
677
  .hx-forge[data-sheet-state="peek"] .hx-forge-head { padding-bottom: 0; border-bottom: 0; }
813
678
  .hx-forge[data-sheet-state="peek"] .hx-forge-head .hx-btn { display: none; }
814
679
  }
815
- .hx-forge-body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 12px; padding: 20px 16px; overflow-y: auto; user-select: text; font-size: 12px; }
816
- @media (min-width: 640px) { .hx-forge-body { padding: 24px 20px; } }
817
- .hx-forge-head { display: flex; align-items: center; gap: 8px; padding-bottom: 10px; border-bottom: 1px solid var(--hx-slate-800); }
680
+ .hx-forge-body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: var(--corn-space-4); padding: calc(var(--corn-space-5) + var(--corn-space-1)) var(--corn-space-5); overflow-y: auto; user-select: text; font-size: var(--corn-text-sm); }
681
+ @media (min-width: 640px) { .hx-forge-body { padding: var(--corn-space-6) calc(var(--corn-space-5) + var(--corn-space-1)); } }
682
+ .hx-forge-head { display: flex; align-items: center; gap: var(--corn-space-3); padding-bottom: var(--corn-space-3); border-bottom: var(--corn-border) solid var(--corn-surface-2); }
818
683
  .hx-forge-head .hx-drawer-title { flex: 1; min-width: 0; }
819
- .hx-forge-status, .hx-forge-rate { font-size: 11px; line-height: 1.5; }
820
- .hx-forge-controls { display: flex; flex-direction: column; gap: 8px; }
821
- .hx-forge-tabs { display: inline-flex; align-self: flex-start; padding: 2px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well-soft); }
822
- .hx-forge-tab { padding: 3px 12px; border: 0; border-radius: 6px; background: none; color: var(--hx-slate-400); font-size: 12px; font-weight: 500; }
823
- .hx-forge-tab:hover { color: var(--hx-ink); }
824
- .hx-forge-tab[aria-pressed="true"] { background: var(--hx-indigo-strong); color: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4); }
825
- .hx-forge-filters { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 8px; }
826
- .hx-forge-field { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--hx-slate-400); }
684
+ .hx-forge-status, .hx-forge-rate { font-size: var(--corn-text-xs); line-height: 1.5; }
685
+ .hx-forge-controls { display: flex; flex-direction: column; gap: var(--corn-space-3); }
686
+ .hx-forge-tabs { display: inline-flex; align-self: flex-start; padding: calc(var(--corn-space-1) / 2); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); }
687
+ .hx-forge-tab { padding: var(--corn-space-1) var(--corn-space-4); border: 0; border-radius: var(--corn-radius-sm); background: none; color: var(--corn-text-3); font-size: var(--corn-text-sm); font-weight: 500; }
688
+ .hx-forge-tab:hover { color: var(--corn-text); }
689
+ .hx-forge-tab[aria-pressed="true"] { background: var(--corn-accent); color: var(--corn-text-on-accent); box-shadow: var(--corn-shadow-sm); }
690
+ .hx-forge-filters { display: grid; grid-template-columns: 1fr 1fr; gap: var(--corn-space-2) var(--corn-space-3); }
691
+ .hx-forge-field { display: flex; flex-direction: column; gap: calc(var(--corn-space-1) / 2); min-width: 0; font-size: var(--corn-text-2xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--corn-text-3); }
827
692
  .hx-forge-field--text { grid-column: 1 / -1; }
828
693
  /* The Start dialog's four limits: two a row, under their legend */
829
- .hx-forge-limits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 8px; margin: 0; padding: 0; border: 0; }
830
- .hx-forge-limits > legend { padding: 0 0 4px; }
831
- .hx-forge-select, .hx-forge-input { width: 100%; min-width: 0; padding: 5px 8px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font: inherit; font-size: 12px; font-weight: 400; text-transform: none; letter-spacing: 0; user-select: text; }
832
- .hx-forge-input::placeholder { color: var(--hx-slate-500); }
833
- .hx-forge-input:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
834
- .hx-forge-notice { padding: 6px 8px; border-radius: 8px; border: 1px solid var(--hx-amber); background: var(--hx-well-soft); color: var(--hx-text-2); line-height: 1.5; }
835
-
836
- .hx-forge-list, .hx-forge-checks, .hx-forge-files { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0; list-style: none; }
837
- .hx-forge-item { display: flex; align-items: stretch; gap: 4px; }
838
- .hx-forge-row { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 8px 10px; border: 1px solid var(--hx-line); border-radius: 10px; background: var(--hx-control); color: var(--hx-ink); text-align: left; text-decoration: none; font-size: 12px; }
839
- a.hx-forge-row:hover, button.hx-forge-row:hover { background: var(--hx-control-hover); }
840
- .hx-forge-row[aria-pressed="true"] { border-color: var(--hx-indigo); border-left-width: 4px; background: var(--hx-control-hover); }
694
+ .hx-forge-limits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--corn-space-2) var(--corn-space-3); margin: 0; padding: 0; border: 0; }
695
+ .hx-forge-limits > legend { padding: 0 0 var(--corn-space-1); }
696
+ .hx-forge-select, .hx-forge-input { width: 100%; min-width: 0; padding: var(--corn-space-1) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font: inherit; font-size: var(--corn-text-sm); font-weight: 400; text-transform: none; letter-spacing: 0; user-select: text; }
697
+ .hx-forge-input::placeholder { color: var(--corn-text-3); }
698
+ .hx-forge-input:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
699
+ .hx-forge-notice { padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-warn); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-text-2); line-height: 1.5; }
700
+
701
+ .hx-forge-list, .hx-forge-checks, .hx-forge-files { display: flex; flex-direction: column; gap: var(--corn-space-1); margin: 0; padding: 0; list-style: none; }
702
+ .hx-forge-item { display: flex; align-items: stretch; gap: var(--corn-space-1); }
703
+ .hx-forge-row { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--corn-space-1); padding: var(--corn-space-3) var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-radius: var(--corn-radius); background: var(--corn-surface-2); color: var(--corn-text); text-align: left; text-decoration: none; font-size: var(--corn-text-sm); }
704
+ a.hx-forge-row:hover, button.hx-forge-row:hover { background: var(--corn-surface-3); }
705
+ .hx-forge-row[aria-pressed="true"] { border-color: var(--corn-accent-text); border-left-width: calc(var(--corn-border-strong) * 2); background: var(--corn-surface-3); }
841
706
  .hx-forge-title { font-weight: 600; overflow-wrap: anywhere; }
842
- .hx-forge-meta { color: var(--hx-slate-400); font-size: 11px; overflow-wrap: anywhere; }
843
- .hx-forge-labels { display: flex; flex-wrap: wrap; gap: 4px; }
844
- .hx-forge-label { padding: 0 6px; border-radius: 9999px; border: 1px solid var(--hx-line); background: var(--hx-well-soft); color: var(--hx-slate-300); font-size: 10px; }
845
- .hx-forge-out { flex: none; display: flex; align-items: center; justify-content: center; width: 32px; border-radius: 10px; border: 1px solid var(--hx-line); background: var(--hx-control); color: var(--hx-sky); text-decoration: none; }
846
- .hx-forge-out:hover { background: var(--hx-control-hover); }
847
- .hx-forge-empty { padding: 8px 2px; }
707
+ .hx-forge-meta { color: var(--corn-text-3); font-size: var(--corn-text-xs); overflow-wrap: anywhere; }
708
+ .hx-forge-labels { display: flex; flex-wrap: wrap; gap: var(--corn-space-1); }
709
+ .hx-forge-label { padding: 0 var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-text-2); font-size: var(--corn-text-2xs); }
710
+ .hx-forge-out { flex: none; display: flex; align-items: center; justify-content: center; width: 32px; border-radius: var(--corn-radius); border: var(--corn-border) solid var(--corn-line); background: var(--corn-surface-2); color: var(--corn-info); text-decoration: none; }
711
+ .hx-forge-out:hover { background: var(--corn-surface-3); }
712
+ .hx-forge-empty { padding: var(--corn-space-3) calc(var(--corn-space-1) / 2); }
848
713
 
849
714
  /* A state is a word as well as a colour: open, merged, a check's result */
850
- .hx-forge-state { display: inline-block; padding: 0 6px; border-radius: 9999px; border: 1px solid currentColor; font-size: 10px; font-weight: 700; }
851
- .hx-forge-state--open, .hx-forge-state--success { color: var(--hx-emerald); }
852
- .hx-forge-state--merged { color: var(--hx-violet-text); }
853
- .hx-forge-state--closed, .hx-forge-state--failure { color: var(--hx-red); }
854
- .hx-forge-state--draft, .hx-forge-state--running, .hx-forge-state--queued { color: var(--hx-amber); }
855
- .hx-forge-state--neutral, .hx-forge-state--skipped, .hx-forge-state--cancelled { color: var(--hx-slate-400); }
856
-
857
- .hx-forge-detail { display: flex; flex-direction: column; gap: 6px; padding: 10px; border: 1px solid var(--hx-line); border-left: 4px solid var(--hx-indigo); border-radius: 10px; background: var(--hx-well-soft); }
858
- .hx-forge-detail-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
859
- .hx-forge-detail-title { min-width: 0; font-size: 13px; font-weight: 700; color: var(--hx-ink); overflow-wrap: anywhere; }
860
- .hx-forge-sub, .hx-forge-subact, .hx-forge-runs-title, .hx-forge-confirm-title { margin: 4px 0 0; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--hx-slate-300); }
861
- .hx-forge-check { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; }
715
+ .hx-forge-state { display: inline-block; padding: 0 var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid currentColor; font-size: var(--corn-text-2xs); font-weight: 700; }
716
+ .hx-forge-state--open, .hx-forge-state--success { color: var(--corn-ok); }
717
+ .hx-forge-state--merged { color: var(--corn-edit-text); }
718
+ .hx-forge-state--closed, .hx-forge-state--failure { color: var(--corn-bad); }
719
+ .hx-forge-state--draft, .hx-forge-state--running, .hx-forge-state--queued { color: var(--corn-warn); }
720
+ .hx-forge-state--neutral, .hx-forge-state--skipped, .hx-forge-state--cancelled { color: var(--corn-text-3); }
721
+
722
+ .hx-forge-detail { display: flex; flex-direction: column; gap: var(--corn-space-2); padding: var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-left: calc(var(--corn-border-strong) * 2) solid var(--corn-accent-text); border-radius: var(--corn-radius); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); }
723
+ .hx-forge-detail-head { display: flex; align-items: center; justify-content: space-between; gap: var(--corn-space-3); }
724
+ .hx-forge-detail-title { min-width: 0; font-size: var(--corn-text-md); font-weight: 700; color: var(--corn-text); overflow-wrap: anywhere; }
725
+ .hx-forge-sub, .hx-forge-subact, .hx-forge-runs-title, .hx-forge-confirm-title { margin: var(--corn-space-1) 0 0; font-size: var(--corn-text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--corn-text-2); }
726
+ .hx-forge-check { display: flex; flex-wrap: wrap; align-items: center; gap: calc(var(--corn-space-1) / 2) var(--corn-space-2); }
862
727
  .hx-forge-check .hx-link { display: inline-flex; align-items: center; min-height: 24px; }
863
- .hx-forge-lights { flex-basis: 100%; font-size: 11px; line-height: 1.5; }
864
- .hx-forge-key { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 4px; font-size: 11px; }
865
- .hx-forge-file { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 6px; padding: 4px 0; border-top: 1px solid var(--hx-line-soft); overflow-wrap: anywhere; }
866
- .hx-forge-fstatus { flex: none; min-width: 56px; color: var(--hx-slate-400); font-size: 11px; }
867
- .hx-forge-del { color: var(--hx-red); }
868
- .hx-forge-act { align-self: flex-start; min-height: 24px; padding: 2px 10px; }
869
- .hx-forge-detail > .hx-forge-act { padding: 6px 14px; }
870
- .hx-forge-why { margin: 0; font-size: 11px; line-height: 1.5; }
871
- .hx-forge-step { display: flex; flex-direction: column; gap: 4px; }
728
+ .hx-forge-lights { flex-basis: 100%; font-size: var(--corn-text-xs); line-height: 1.5; }
729
+ .hx-forge-key { display: flex; flex-wrap: wrap; align-items: center; gap: calc(var(--corn-space-1) / 2) var(--corn-space-1); font-size: var(--corn-text-xs); }
730
+ .hx-forge-file { display: flex; flex-wrap: wrap; align-items: baseline; gap: calc(var(--corn-space-1) / 2) var(--corn-space-2); padding: var(--corn-space-1) 0; border-top: var(--corn-border) solid var(--corn-line-soft); overflow-wrap: anywhere; }
731
+ .hx-forge-fstatus { flex: none; min-width: var(--hx-forge-status-w); color: var(--corn-text-3); font-size: var(--corn-text-xs); }
732
+ .hx-forge-del { color: var(--corn-bad); }
733
+ .hx-forge-act { align-self: flex-start; min-height: 24px; padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); }
734
+ .hx-forge-detail > .hx-forge-act { padding: var(--corn-space-2) var(--corn-space-4); }
735
+ .hx-forge-why { margin: 0; font-size: var(--corn-text-xs); line-height: 1.5; }
736
+ .hx-forge-step { display: flex; flex-direction: column; gap: var(--corn-space-1); }
872
737
  .hx-forge-startspec { flex: none; align-self: center; }
873
- .hx-forge-notice--ok { border-color: var(--hx-emerald); }
874
- .hx-confirm-scrim { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(2, 6, 23, 0.6); }
738
+ .hx-forge-notice--ok { border-color: var(--corn-ok); }
739
+ .hx-confirm-scrim { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: var(--corn-space-5); background: color-mix(in srgb, var(--corn-ground) 60%, transparent); }
875
740
  .hx-confirm-scrim[hidden] { display: none; }
876
- .hx-confirm { display: flex; flex-direction: column; gap: 10px; width: min(440px, 100%); max-height: 100%; overflow-y: auto; padding: 18px; border: 1px solid var(--hx-line); border-radius: 14px; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6); font-size: 12px; user-select: text; }
877
- .hx-confirm-title { margin: 0; font-size: 15px; font-weight: 700; color: var(--hx-ink); }
878
- .hx-confirm-facts { display: grid; grid-template-columns: max-content 1fr; gap: 4px 12px; margin: 0; }
879
- .hx-confirm-facts dt { color: var(--hx-slate-400); }
880
- .hx-confirm-facts dd { margin: 0; overflow-wrap: anywhere; color: var(--hx-ink); }
881
- .hx-confirm-checks { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0; list-style: none; }
882
- .hx-confirm-label { margin: 0; color: var(--hx-slate-400); }
883
- .hx-confirm-pre { margin: 0; max-height: 140px; overflow: auto; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font: 11px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; overflow-wrap: anywhere; user-select: text; }
884
- .hx-confirm-pre:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
885
- .hx-confirm-note { margin: 0; color: var(--hx-text-2); line-height: 1.5; }
886
- .hx-confirm-actions { display: flex; justify-content: flex-end; gap: 8px; }
887
- .hx-tokens-list { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; list-style: none; }
888
- .hx-tokens-item { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; align-items: center; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well-soft); }
741
+ .hx-confirm { display: flex; flex-direction: column; gap: var(--corn-space-3); width: min(440px, 100%); max-height: 100%; overflow-y: auto; padding: var(--corn-space-5); border: var(--corn-border) solid var(--corn-line); border-radius: var(--corn-radius-lg); box-shadow: var(--corn-shadow-lg); font-size: var(--corn-text-sm); user-select: text; }
742
+ .hx-confirm-title { margin: 0; font-size: var(--corn-text-lg); font-weight: 700; color: var(--corn-text); }
743
+ .hx-confirm-facts { display: grid; grid-template-columns: max-content 1fr; gap: var(--corn-space-1) var(--corn-space-4); margin: 0; }
744
+ .hx-confirm-facts dt { color: var(--corn-text-3); }
745
+ .hx-confirm-facts dd { margin: 0; overflow-wrap: anywhere; color: var(--corn-text); }
746
+ .hx-confirm-checks { display: flex; flex-direction: column; gap: var(--corn-space-1); margin: 0; padding: 0; list-style: none; }
747
+ .hx-confirm-label { margin: 0; color: var(--corn-text-3); }
748
+ .hx-confirm-pre { margin: 0; max-height: 140px; overflow: auto; padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font: var(--corn-text-xs)/1.5 var(--corn-mono); white-space: pre-wrap; overflow-wrap: anywhere; user-select: text; }
749
+ .hx-confirm-pre:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
750
+ .hx-confirm-note { margin: 0; color: var(--corn-text-2); line-height: 1.5; }
751
+ .hx-confirm-actions { display: flex; justify-content: flex-end; gap: var(--corn-space-3); }
752
+ .hx-tokens-list { display: flex; flex-direction: column; gap: var(--corn-space-2); margin: 0; padding: 0; list-style: none; }
753
+ .hx-tokens-item { display: grid; grid-template-columns: 1fr auto; gap: calc(var(--corn-space-1) / 2) var(--corn-space-3); align-items: center; padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); }
889
754
  .hx-tokens-item[data-state="revoked"], .hx-tokens-item[data-state="expired"] { opacity: 0.65; }
890
- .hx-tokens-label { font-weight: 600; color: var(--hx-ink); overflow-wrap: anywhere; }
755
+ .hx-tokens-label { font-weight: 600; color: var(--corn-text); overflow-wrap: anywhere; }
891
756
  .hx-tokens-meta { grid-column: 1; }
892
757
  .hx-tokens-item .hx-btn { grid-column: 2; grid-row: 1 / span 2; }
893
- .hx-tokens-row { display: flex; gap: 8px; align-items: center; }
758
+ .hx-tokens-row { display: flex; gap: var(--corn-space-3); align-items: center; }
894
759
  .hx-tokens-row .hx-forge-input { flex: 1; }
895
- .hx-tokens-form { display: grid; grid-template-columns: 1fr 5rem; gap: 8px; align-items: end; }
760
+ .hx-tokens-form { display: grid; grid-template-columns: 1fr 5rem; gap: var(--corn-space-3); align-items: end; }
896
761
  .hx-tokens-form .hx-btn { grid-column: 1 / -1; justify-self: start; }
897
- .hx-forge-nodes { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 4px; padding-left: 62px; }
898
- .hx-forge-node { padding: 1px 8px; border-radius: 9999px; border: 1px solid var(--hx-amber); background: var(--hx-well-soft); color: var(--hx-text-2); font-size: 11px; }
899
- .hx-forge-node:hover { background: var(--hx-control-hover); }
900
- .hx-forge-work-filters { display: flex; flex-wrap: wrap; gap: 6px 14px; }
762
+ .hx-forge-nodes { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: var(--corn-space-1); padding-left: calc(var(--hx-forge-status-w) + var(--corn-space-2)); }
763
+ .hx-forge-node { padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid var(--corn-warn); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-text-2); font-size: var(--corn-text-xs); }
764
+ .hx-forge-node:hover { background: var(--corn-surface-3); }
765
+ .hx-forge-work-filters { display: flex; flex-wrap: wrap; gap: var(--corn-space-2) var(--corn-space-4); }
901
766
  .hx-forge-work-filters[hidden], .hx-forge-filters[hidden] { display: none; }
902
- .hx-forge-toggle { display: inline-flex; align-items: center; gap: 6px; min-height: 24px; color: var(--hx-text-2); font-size: 12px; }
903
- .hx-forge-toggle input { accent-color: var(--hx-indigo); }
904
- .hx-forge-toggle input:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
905
- .hx-forge-group { display: flex; flex-direction: column; gap: 4px; margin: 0 0 8px; list-style: none; }
906
- .hx-forge-gtitle { margin: 0; font-size: 12px; font-weight: 700; color: var(--hx-ink); overflow-wrap: anywhere; }
907
- .hx-forge-gout { margin-left: 4px; }
908
- .hx-forge-agentline { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; }
909
- .hx-forge-agent { display: inline-block; padding: 0 6px; border-radius: 9999px; border: 1px solid currentColor; color: var(--hx-violet-text); font-size: 10px; font-weight: 700; }
910
- .hx-forge-why { font-size: 11px; overflow-wrap: anywhere; }
911
- .hx-forge-notes, .hx-forge-confirm { display: flex; flex-direction: column; gap: 8px; }
912
- .hx-forge-preview { width: 100%; min-height: 12em; resize: vertical; padding: 8px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well); color: var(--hx-ink); font-family: var(--pop-font-mono); font-size: 11px; line-height: 1.5; font-weight: 400; text-transform: none; letter-spacing: 0; user-select: text; }
913
- .hx-forge-preview:focus-visible { outline: 2px solid var(--hx-indigo); outline-offset: 2px; }
914
- .hx-forge-actions { display: flex; flex-wrap: wrap; gap: 8px; }
915
- .hx-forge-msg { padding: 6px 8px; border-radius: 8px; border: 1px solid var(--hx-line); background: var(--hx-well-soft); color: var(--hx-text-2); line-height: 1.5; overflow-wrap: anywhere; }
916
- .hx-forge-msg--bad { border-color: var(--hx-amber); }
917
- .hx-forge-confirm { padding: 10px; border: 1px solid var(--hx-line); border-left: 4px solid var(--hx-teal-strong); border-radius: 10px; background: var(--hx-well-soft); line-height: 1.5; }
918
- :root[data-theme="light"] .hx-forge-tab[aria-pressed="true"] { box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25); }
919
- :root[data-theme="light"] .hx-forge { box-shadow: 10px 0 30px -12px rgba(15, 23, 42, 0.18); }
920
- :root[data-theme="light"] .hx-forge:not(.forge-open) { box-shadow: none; }
921
- .hx-forge-runs { display: flex; flex-direction: column; gap: 6px; margin: 4px 0 8px; }
767
+ .hx-forge-toggle { display: inline-flex; align-items: center; gap: var(--corn-space-2); min-height: 24px; color: var(--corn-text-2); font-size: var(--corn-text-sm); }
768
+ .hx-forge-toggle input { accent-color: var(--corn-accent-text); }
769
+ .hx-forge-toggle input:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
770
+ .hx-forge-group { display: flex; flex-direction: column; gap: var(--corn-space-1); margin: 0 0 var(--corn-space-3); list-style: none; }
771
+ .hx-forge-gtitle { margin: 0; font-size: var(--corn-text-sm); font-weight: 700; color: var(--corn-text); overflow-wrap: anywhere; }
772
+ .hx-forge-gout { margin-left: var(--corn-space-1); }
773
+ .hx-forge-agentline { display: flex; flex-wrap: wrap; align-items: center; gap: calc(var(--corn-space-1) / 2) var(--corn-space-2); }
774
+ .hx-forge-agent { display: inline-block; padding: 0 var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid currentColor; color: var(--corn-edit-text); font-size: var(--corn-text-2xs); font-weight: 700; }
775
+ .hx-forge-why { font-size: var(--corn-text-xs); overflow-wrap: anywhere; }
776
+ .hx-forge-notes, .hx-forge-confirm { display: flex; flex-direction: column; gap: var(--corn-space-3); }
777
+ .hx-forge-preview { width: 100%; min-height: 12em; resize: vertical; padding: var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-text); font-family: var(--corn-mono); font-size: var(--corn-text-xs); line-height: 1.5; font-weight: 400; text-transform: none; letter-spacing: 0; user-select: text; }
778
+ .hx-forge-preview:focus-visible { outline: var(--corn-focus-width) solid var(--corn-focus); outline-offset: 2px; }
779
+ .hx-forge-actions { display: flex; flex-wrap: wrap; gap: var(--corn-space-3); }
780
+ .hx-forge-msg { padding: var(--corn-space-2) var(--corn-space-3); border-radius: var(--corn-radius-sm); border: var(--corn-border) solid var(--corn-line); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); color: var(--corn-text-2); line-height: 1.5; overflow-wrap: anywhere; }
781
+ .hx-forge-msg--bad { border-color: var(--corn-warn); }
782
+ .hx-forge-confirm { padding: var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-left: calc(var(--corn-border-strong) * 2) solid var(--corn-added-text); border-radius: var(--corn-radius); background: color-mix(in srgb, var(--corn-ground) 55%, transparent); line-height: 1.5; }
783
+ .hx-forge-runs { display: flex; flex-direction: column; gap: var(--corn-space-2); margin: var(--corn-space-1) 0 var(--corn-space-3); }
922
784
  .hx-forge-runs[hidden] { display: none; }
923
785
 
924
786
  /* Threads (forge-panel.js, docs/threads.md): messages as written, read-only; a node's "Mentioned in" opens one */
925
- .hx-thread-msgs { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
926
- .hx-thread-msg { display: flex; flex-direction: column; gap: 4px; padding: 8px 10px; border: 1px solid var(--hx-line); border-radius: 10px; background: var(--hx-control); }
927
- .hx-thread-body { margin: 0; color: var(--hx-ink); line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; user-select: text; }
787
+ .hx-thread-msgs { display: flex; flex-direction: column; gap: var(--corn-space-3); margin: 0; padding: 0; list-style: none; }
788
+ .hx-thread-msg { display: flex; flex-direction: column; gap: var(--corn-space-1); padding: var(--corn-space-3) var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-radius: var(--corn-radius); background: var(--corn-surface-2); }
789
+ .hx-thread-body { margin: 0; color: var(--corn-text); line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; user-select: text; }
928
790
  .hx-thread-nodes { padding-left: 0; }
929
791
  .hx-thread-compose { font-family: inherit; min-height: 8em; }
930
792
  .hx-thread-open { display: block; max-width: 100%; text-align: left; overflow-wrap: anywhere; }
@@ -934,34 +796,34 @@ a.hx-forge-row:hover, button.hx-forge-row:hover { background: var(--hx-control-h
934
796
  .hx-run-overlay { position: absolute; inset: 0; z-index: 2; overflow: hidden; pointer-events: none; }
935
797
  .hx-run-overlay[hidden] { display: none; }
936
798
  .hx-run-mark { position: absolute; width: 0; height: 0; --r: 14px; }
937
- .hx-run-ring { position: absolute; left: calc(var(--r) * -1); top: calc(var(--r) * -1); width: calc(var(--r) * 2); height: calc(var(--r) * 2); box-sizing: border-box; border-radius: 50%; border: 2px solid var(--hx-teal-text); }
799
+ .hx-run-ring { position: absolute; left: calc(var(--r) * -1); top: calc(var(--r) * -1); width: calc(var(--r) * 2); height: calc(var(--r) * 2); box-sizing: border-box; border-radius: 50%; border: var(--corn-border-strong) solid var(--corn-added); }
938
800
  /* In flight: the ring pulses outward and fades; when motion is reduced it is a still, slightly thicker ring */
939
801
  .hx-run-mark--flight .hx-run-ring { animation: hx-run-pulse 1.8s ease-out infinite; }
940
802
  @keyframes hx-run-pulse { 0% { transform: scale(0.9); opacity: 1; } 100% { transform: scale(1.55); opacity: 0.1; } }
941
- .hx-run-overlay.is-static .hx-run-ring { animation: none; transform: none; opacity: 1; border-width: 3px; }
942
- @media (prefers-reduced-motion: reduce) { .hx-run-ring { animation: none !important; transform: none; opacity: 1; border-width: 3px; } }
803
+ .hx-run-overlay.is-static .hx-run-ring { animation: none; transform: none; opacity: 1; border-width: calc(var(--corn-border-strong) + var(--corn-border)); }
804
+ @media (prefers-reduced-motion: reduce) { .hx-run-ring { animation: none !important; transform: none; opacity: 1; border-width: calc(var(--corn-border-strong) + var(--corn-border)); } }
943
805
  /* Collision: dashed, a sign and words; the same ring whether or not colour is seen */
944
- .hx-run-mark--collision .hx-run-ring { border: 3px dashed var(--hx-amber); animation: none; }
945
- .hx-run-tag { position: absolute; left: 0; top: calc(var(--r) + 4px); transform: translateX(-50%); white-space: nowrap; padding: 1px 7px; border-radius: 9999px; border: 1px solid var(--hx-amber); background: var(--hx-well); color: var(--hx-amber); font-size: 11px; font-weight: 700; }
946
- .hx-run-swatch { display: inline-block; width: 14px; height: 14px; flex: none; box-sizing: border-box; border-radius: 50%; border: 2px solid var(--hx-teal-text); }
947
- .hx-run-swatch--collision { border: 2px dashed var(--hx-amber); }
806
+ .hx-run-mark--collision .hx-run-ring { border: calc(var(--corn-border-strong) + var(--corn-border)) dashed var(--corn-warn); animation: none; }
807
+ .hx-run-tag { position: absolute; left: 0; top: calc(var(--r) + 4px); transform: translateX(-50%); white-space: nowrap; padding: calc(var(--corn-space-1) / 2) var(--corn-space-2); border-radius: var(--corn-radius-pill); border: var(--corn-border) solid var(--corn-warn); background: color-mix(in srgb, var(--corn-ground) 80%, transparent); color: var(--corn-warn); font-size: var(--corn-text-xs); font-weight: 700; }
808
+ .hx-run-swatch { display: inline-block; width: 14px; height: 14px; flex: none; box-sizing: border-box; border-radius: 50%; border: var(--corn-border-strong) solid var(--corn-added); }
809
+ .hx-run-swatch--collision { border: var(--corn-border-strong) dashed var(--corn-warn); }
948
810
 
949
811
  /* The Runs view (forge-panel.js, runs-view.js): each run, its limits beside what was reported, its timeline; the compare puts profiles side by side */
950
- .hx-runs-list { display: flex; flex-direction: column; gap: 8px; margin: 0; padding: 0; list-style: none; }
951
- .hx-run { display: flex; flex-direction: column; gap: 4px; padding: 8px 10px; border: 1px solid var(--hx-line); border-radius: 10px; background: var(--hx-control); overflow-wrap: anywhere; min-width: 0; }
952
- .hx-run-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
953
- .hx-run-actions { display: flex; flex-wrap: wrap; gap: 6px; }
954
- .hx-run-collide { margin: 0; padding: 2px 8px; border: 1px dashed var(--hx-amber); border-radius: 8px; color: var(--hx-amber); font-weight: 600; }
955
- .hx-run-limits { display: grid; grid-template-columns: auto 1fr; gap: 0 10px; margin: 0; font-size: 11px; }
956
- .hx-run-limits dt { color: var(--hx-slate-300); font-weight: 600; }
957
- .hx-run-limits dd { margin: 0; color: var(--hx-text-2); }
958
- .hx-run-timeline { display: flex; flex-direction: column; gap: 4px; margin: 0; padding: 0 0 0 18px; font-size: 11px; }
959
- .hx-run-timeline li { color: var(--hx-text-2); }
960
- .hx-run-timeline time { color: var(--hx-slate-300); margin-right: 6px; }
961
- .hx-run-note { display: block; color: var(--hx-slate-300); white-space: pre-wrap; }
962
- .hx-run-compare { border: 1px solid var(--hx-line); border-left: 4px solid var(--hx-teal-strong); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
963
- .hx-run-compare-title { margin: 0; font-size: 12px; font-weight: 700; color: var(--hx-text-1); }
964
- .hx-run-columns { display: grid; grid-template-columns: 1fr; gap: 8px; margin: 0; padding: 0; list-style: none; }
812
+ .hx-runs-list { display: flex; flex-direction: column; gap: var(--corn-space-3); margin: 0; padding: 0; list-style: none; }
813
+ .hx-run { display: flex; flex-direction: column; gap: var(--corn-space-1); padding: var(--corn-space-3) var(--corn-space-3); border: var(--corn-border) solid var(--corn-line); border-radius: var(--corn-radius); background: var(--corn-surface-2); overflow-wrap: anywhere; min-width: 0; }
814
+ .hx-run-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--corn-space-1) var(--corn-space-3); }
815
+ .hx-run-actions { display: flex; flex-wrap: wrap; gap: var(--corn-space-2); }
816
+ .hx-run-collide { margin: 0; padding: calc(var(--corn-space-1) / 2) var(--corn-space-3); border: var(--corn-border) dashed var(--corn-warn); border-radius: var(--corn-radius-sm); color: var(--corn-warn); font-weight: 600; }
817
+ .hx-run-limits { display: grid; grid-template-columns: auto 1fr; gap: 0 var(--corn-space-3); margin: 0; font-size: var(--corn-text-xs); }
818
+ .hx-run-limits dt { color: var(--corn-text-2); font-weight: 600; }
819
+ .hx-run-limits dd { margin: 0; color: var(--corn-text-2); }
820
+ .hx-run-timeline { display: flex; flex-direction: column; gap: var(--corn-space-1); margin: 0; padding: 0 0 0 var(--corn-space-5); font-size: var(--corn-text-xs); }
821
+ .hx-run-timeline li { color: var(--corn-text-2); }
822
+ .hx-run-timeline time { color: var(--corn-text-2); margin-right: var(--corn-space-2); }
823
+ .hx-run-note { display: block; color: var(--corn-text-2); white-space: pre-wrap; }
824
+ .hx-run-compare { border: var(--corn-border) solid var(--corn-line); border-left: calc(var(--corn-border-strong) * 2) solid var(--corn-added-text); border-radius: var(--corn-radius); padding: var(--corn-space-3); display: flex; flex-direction: column; gap: var(--corn-space-2); }
825
+ .hx-run-compare-title { margin: 0; font-size: var(--corn-text-sm); font-weight: 700; color: var(--corn-text); }
826
+ .hx-run-columns { display: grid; grid-template-columns: 1fr; gap: var(--corn-space-3); margin: 0; padding: 0; list-style: none; }
965
827
  @media (min-width: 1100px) {
966
828
  .hx-stage:has(.hx-forge .hx-run-compare) { --hx-forge-w: min(780px, calc(100% - 24px)); }
967
829
  .hx-run-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }