@zsviczian/kplex-web 0.0.0-stage → 0.0.2

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.
package/compass.css ADDED
@@ -0,0 +1,4805 @@
1
+ @scope (.kplex-publication) {
2
+ /* Native theme fallbacks are consumed at each surface. Public K-Plex variables are deliberately
3
+ not declared on view roots: body and view-local theme/snippet overrides must both inherit. */
4
+
5
+ .kplex-view-host,
6
+ .kplex-view-host > div,
7
+ .kplex-app {
8
+ width: 100%;
9
+ height: 100%;
10
+ min-width: 0;
11
+ min-height: 0;
12
+ }
13
+
14
+ .kplex-canvas-usage-tips {
15
+ position: absolute;
16
+ z-index: 4;
17
+ /* Leave the first row for the view heading and relationship-area captions. */
18
+ top: 32px;
19
+ left: 16px;
20
+ right: 16px;
21
+ color: var(--text-muted);
22
+ font-size: calc(var(--font-ui-smaller) - 1px);
23
+ text-align: center;
24
+ pointer-events: none;
25
+ overflow-wrap: anywhere;
26
+ }
27
+ .kplex-canvas-usage-tips.is-contextual { color: var(--text-normal); }
28
+
29
+ .kplex-app {
30
+ position: relative;
31
+ color: var(--kplex-text, var(--text-normal));
32
+ background: var(--kplex-panel, var(--background-primary));
33
+ font-family: var(--font-interface);
34
+ overflow: hidden;
35
+ }
36
+
37
+ .kplex-main-column {
38
+ height: 100%;
39
+ display: grid;
40
+ grid-template-rows: 46px minmax(0, 1fr) 40px;
41
+ }
42
+
43
+ .kplex-topbar {
44
+ position: relative;
45
+ z-index: 30;
46
+ display: flex;
47
+ align-items: center;
48
+ gap: 7px;
49
+ padding: 0 10px;
50
+ background: var(--kplex-panel-2, var(--background-secondary));
51
+ border-bottom: 1px solid var(--kplex-line, var(--background-modifier-border));
52
+ box-shadow: var(--shadow-s);
53
+ }
54
+
55
+ .kplex-brand {
56
+ display: flex;
57
+ align-items: center;
58
+ gap: 7px;
59
+ margin-right: 4px;
60
+ letter-spacing: .01em;
61
+ white-space: nowrap;
62
+ }
63
+
64
+ .kplex-index-status {
65
+ position: relative;
66
+ min-height: 9px;
67
+ max-height: 9px;
68
+ min-width: 9px;
69
+ max-width: 9px;
70
+ flex: 0 0 9px;
71
+ padding: 0;
72
+ border-radius: 50%;
73
+ border: 1px solid var(--background-modifier-border);
74
+ cursor: pointer;
75
+ }
76
+
77
+ .kplex-index-activities {
78
+ white-space: pre-line;
79
+ }
80
+
81
+ /* Keep the compact dot layout while giving mouse/touch users a larger invisible hit target. */
82
+ .kplex-index-status::before {
83
+ content: "";
84
+ position: absolute;
85
+ top: -8px;
86
+ right: -8px;
87
+ bottom: -8px;
88
+ left: -8px;
89
+ border-radius: 50%;
90
+ }
91
+
92
+ .kplex-topbar button.kplex-index-status,
93
+ .kplex-index-status-empty button.kplex-index-status {
94
+ width: 9px;
95
+ height: 9px;
96
+ min-width: 9px;
97
+ padding: 0;
98
+ border: 1px solid var(--background-modifier-border);
99
+ border-radius: 50%;
100
+ }
101
+
102
+ .kplex-index-status:focus-visible {
103
+ outline: 2px solid var(--interactive-accent);
104
+ outline-offset: 4px;
105
+ }
106
+
107
+ .kplex-index-status.is-ready,
108
+ .kplex-topbar button.kplex-index-status.is-ready {
109
+ background: var(--color-green);
110
+ box-shadow: var(--shadow-s);
111
+ }
112
+
113
+ .kplex-index-status.is-updating,
114
+ .kplex-topbar button.kplex-index-status.is-updating {
115
+ background: var(--color-red);
116
+ box-shadow: var(--shadow-s);
117
+ animation: kplex-index-status-blink 1s ease-in-out infinite;
118
+ }
119
+
120
+ .kplex-index-status.is-paused,
121
+ .kplex-topbar button.kplex-index-status.is-paused {
122
+ animation: none;
123
+ }
124
+
125
+ .kplex-index-status-empty {
126
+ position: absolute;
127
+ top: 18px;
128
+ left: 18px;
129
+ }
130
+
131
+ @keyframes kplex-index-status-blink {
132
+ 0%, 100% { opacity: 1; }
133
+ 50% { opacity: .25; }
134
+ }
135
+
136
+ @media (prefers-reduced-motion: reduce) {
137
+ .kplex-index-status.is-updating,
138
+ .kplex-topbar button.kplex-index-status.is-updating { animation: none; }
139
+ }
140
+
141
+ .kplex-info-bubble {
142
+ z-index: 1000;
143
+ display: flex;
144
+ flex-direction: column;
145
+ box-sizing: border-box;
146
+ padding: 12px;
147
+ color: var(--text-normal);
148
+ background: var(--background-primary);
149
+ border: 1px solid var(--background-modifier-border);
150
+ border-radius: var(--radius-m);
151
+ box-shadow: var(--shadow-s);
152
+ }
153
+
154
+ .kplex-info-bubble-content { min-height: 0; overflow: auto; overflow-wrap: anywhere; }
155
+
156
+ .kplex-info-bubble-pointer {
157
+ position: absolute;
158
+ top: -6px;
159
+ left: 10px;
160
+ width: 10px;
161
+ height: 10px;
162
+ pointer-events: none;
163
+ background: var(--background-primary);
164
+ border-top: 1px solid var(--background-modifier-border);
165
+ border-left: 1px solid var(--background-modifier-border);
166
+ transform: rotate(45deg);
167
+ }
168
+
169
+ .kplex-info-bubble-message {
170
+ font-size: var(--font-ui-small);
171
+ line-height: 1.4;
172
+ }
173
+
174
+ .kplex-info-bubble-actions {
175
+ display: flex;
176
+ flex-wrap: wrap;
177
+ gap: 8px;
178
+ justify-content: flex-end;
179
+ margin-top: 10px;
180
+ }
181
+
182
+ .kplex-brand-mark {
183
+ color: var(--interactive-accent);
184
+ font-size: 20px;
185
+ text-shadow: none;
186
+ }
187
+
188
+ .kplex-topbar button,
189
+ .kplex-find button,
190
+ button.kplex-footprints-trigger,
191
+ button.kplex-layout-toggle,
192
+ button.kplex-zone-filter-button,
193
+ .kplex-sidecar-controls button,
194
+ button.kplex-sidecar-unfold-plex,
195
+ .kplex-central-editor-toolbar button,
196
+ .kplex-zoom-controls button,
197
+ .kplex-wander-controls button {
198
+ color: var(--kplex-text, var(--text-normal));
199
+ background: var(--kplex-control-bg, var(--interactive-normal));
200
+ border: 1px solid var(--kplex-control-border, var(--background-modifier-border));
201
+ border-radius: 7px;
202
+ height: 28px;
203
+ padding: 0 9px;
204
+ display: inline-flex;
205
+ align-items: center;
206
+ justify-content: center;
207
+ box-shadow: none;
208
+ cursor: pointer;
209
+ }
210
+
211
+ .kplex-topbar button:hover,
212
+ .kplex-find button:hover,
213
+ button.kplex-footprints-trigger:hover,
214
+ button.kplex-layout-toggle:hover,
215
+ button.kplex-zone-filter-button:hover,
216
+ .kplex-sidecar-controls button:hover,
217
+ button.kplex-sidecar-unfold-plex:hover,
218
+ .kplex-central-editor-toolbar button:hover,
219
+ .kplex-zoom-controls button:hover,
220
+ .kplex-wander-controls button:hover { background: var(--kplex-control-hover, var(--interactive-hover)); }
221
+
222
+ .kplex-topbar button:disabled { opacity: .28; cursor: default; }
223
+ .kplex-topbar .kplex-action-button {
224
+ color: var(--kplex-action-fg, var(--text-normal));
225
+ background: var(--kplex-action-bg, var(--interactive-normal));
226
+ border-color: var(--kplex-action-border, var(--background-modifier-border));
227
+ }
228
+ .kplex-topbar .kplex-action-button:hover { background: var(--kplex-action-bg-hover, var(--interactive-hover)); }
229
+ .kplex-topbar .kplex-action-button:disabled { opacity: var(--kplex-action-disabled-opacity, var(--disabled-opacity, .5)); }
230
+ .kplex-topbar .kplex-action-button:focus-visible {
231
+ outline: 2px solid var(--kplex-action-focus, var(--interactive-accent));
232
+ outline-offset: 2px;
233
+ }
234
+ .kplex-view-host .kplex-icon-button { width: 30px; padding: 0; font-size: 17px; }
235
+ .kplex-top-actions { display: flex; align-items: center; gap: 5px; margin-left: auto; }
236
+ .kplex-top-actions .kplex-auto-open { width: 32px; padding: 0; }
237
+
238
+ .kplex-search-shell { position: relative; flex: 1; max-width: 520px; min-width: 100px; }
239
+ .kplex-search-icon { position: absolute; left: 10px; top: 5px; color: var(--kplex-muted, var(--text-muted)); font-size: 18px; pointer-events: none; }
240
+ .kplex-view-host .kplex-search {
241
+ width: 100%;
242
+ height: 30px;
243
+ padding: 0 12px 0 33px;
244
+ color: var(--kplex-text, var(--text-normal));
245
+ background: var(--background-secondary);
246
+ border: 1px solid var(--background-modifier-border);
247
+ border-radius: 8px;
248
+ box-shadow: var(--shadow-s);
249
+ }
250
+ .kplex-view-host .kplex-search:focus { border-color: var(--interactive-accent); box-shadow: 0 0 0 1px var(--interactive-accent); }
251
+ .kplex-search-results {
252
+ position: absolute;
253
+ z-index: 60;
254
+ box-sizing: border-box;
255
+ overflow: auto;
256
+ overscroll-behavior: contain;
257
+ border: 1px solid var(--background-modifier-border);
258
+ background: var(--background-secondary);
259
+ border-radius: 9px;
260
+ box-shadow: var(--shadow-s);
261
+ padding: 6px;
262
+ }
263
+ .kplex-search-results .kplex-search-result {
264
+ width: 100%;
265
+ display: grid;
266
+ grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
267
+ align-items: center;
268
+ gap: 18px;
269
+ text-align: left;
270
+ border: 0;
271
+ color: var(--kplex-text, var(--text-normal));
272
+ background: transparent;
273
+ border-radius: 6px;
274
+ padding: 8px 10px;
275
+ cursor: pointer;
276
+ height: auto;
277
+ box-shadow: none;
278
+ }
279
+ .kplex-search-results .kplex-search-result:hover { background: var(--background-modifier-hover); }
280
+ .kplex-search-results .kplex-search-result + .kplex-search-result {
281
+ border-top: 1px solid var(--background-modifier-border-faint);
282
+ }
283
+ .kplex-search-result.has-prefix {
284
+ grid-template-columns: 16px minmax(0, .9fr) minmax(0, 1.1fr);
285
+ gap: 10px;
286
+ }
287
+ .kplex-search-result-prefix {
288
+ display: inline-flex;
289
+ align-items: center;
290
+ justify-content: center;
291
+ color: var(--text-muted);
292
+ }
293
+ .kplex-search-result > span,
294
+ .kplex-search-result small {
295
+ min-width: 0;
296
+ overflow: hidden;
297
+ text-overflow: ellipsis;
298
+ white-space: nowrap;
299
+ }
300
+ .kplex-search-result small { color: var(--kplex-muted, var(--text-muted)); text-align: right; }
301
+ .kplex-create-folder-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
302
+ .kplex-create-folder-caption { color: var(--text-muted); font-size: var(--font-ui-small); flex: none; }
303
+ .kplex-create-folder-row .kplex-folder-path-input { flex: 1; min-width: 0; }
304
+ .kplex-materialize-folder-input { width: 100%; min-width: 0; }
305
+ .kplex-materialize-folder-input .kplex-folder-path-input { width: 100%; max-width: none; min-width: 0; }
306
+ .kplex-materialize-folder-row { gap: 8px; }
307
+ .kplex-materialize-folder-row .setting-item-info { flex: none; margin: 0; }
308
+ .kplex-materialize-folder-row .setting-item-name { color: var(--text-muted); font-size: var(--font-ui-small); }
309
+ .kplex-materialize-folder-row .setting-item-control { flex: 1; min-width: 0; }
310
+ .kplex-folder-path-results .kplex-search-result { display: block; height: auto; }
311
+ .kplex-folder-path-results .kplex-search-result > span {
312
+ display: block;
313
+ overflow: visible;
314
+ text-overflow: clip;
315
+ white-space: normal;
316
+ overflow-wrap: break-word;
317
+ }
318
+
319
+ .kplex-workspace { min-height: 0; display: flex; }
320
+ .kplex-graph-area { position: relative; min-width: 0; min-height: 0; flex: 1; overflow: hidden; }
321
+ /* Native editor startup may focus content beyond the canvas aperture. hidden would let the
322
+ browser scroll this viewport, displacing HUD/tint and invalidating gate pointer coordinates.
323
+ clip keeps the camera as the only canvas motion owner; editor/list scroll lanes stay native. */
324
+ .kplex-plex { position: absolute; inset: 0; overflow: clip; user-select: none; cursor: grab; }
325
+ .kplex-plex:active { cursor: grabbing; }
326
+ .kplex-plex::after {
327
+ content: "";
328
+ position: absolute;
329
+ inset: 0;
330
+ pointer-events: none;
331
+ background: none;
332
+ }
333
+ /* Let Chromium reraster labels at the current zoom. A permanent transform hint retains old-scale
334
+ textures, so scrolling tiles and expanded outlines can stay soft after camera motion settles. */
335
+ .kplex-camera { position: absolute; width: 0; height: 0; transform-origin: 0 0; }
336
+ /* Promote only during desktop camera input. Idle releases this hint to restore sharp labels;
337
+ the existing coarse-pointer rule below avoids large GPU layers on mobile WebViews. */
338
+ .kplex-camera.is-camera-moving { will-change: transform; }
339
+ .kplex-links { position: absolute; left: -1600px; top: -1200px; overflow: visible; pointer-events: none; z-index: 4; }
340
+ .kplex-nodes { position: absolute; left: 0; top: 0; z-index: 8; }
341
+ .kplex-edge { transition: opacity .11s ease, filter .11s ease; }
342
+ .kplex-edge-visible { pointer-events: none; filter: none; transition: opacity .11s ease, filter .11s ease; }
343
+ .kplex-edge-hit { pointer-events: stroke; cursor: pointer; }
344
+ .kplex-edge.is-hover-peek .kplex-edge-hit { pointer-events: none; }
345
+ .kplex-edge.is-highlighted .kplex-edge-visible { filter: none; }
346
+ .kplex-edge.is-dimmed, .kplex-expanded-connector.is-dimmed { opacity: .16; }
347
+ .kplex-edge-label { pointer-events: none; paint-order: stroke; stroke: var(--kplex-link-label-background, var(--background-primary)); stroke-width: 3px; stroke-linejoin: round; }
348
+
349
+ .kplex-zone-label {
350
+ position: absolute;
351
+ z-index: 3;
352
+ pointer-events: none;
353
+ font-size: 9px;
354
+ letter-spacing: .18em;
355
+ color: var(--text-faint);
356
+ font-weight: 700;
357
+ }
358
+ .zone-parent { top: 12px; left: 50%; transform: translateX(-50%); }
359
+ .zone-child { bottom: 12px; left: 50%; transform: translateX(-50%); }
360
+ .zone-left { top: 50%; left: 10px; transform: translateY(-50%) rotate(-90deg); transform-origin: left top; }
361
+ .zone-right { top: 50%; right: 10px; transform: translateY(-50%) rotate(90deg); transform-origin: right top; }
362
+
363
+ .kplex-thought {
364
+ position: absolute;
365
+ z-index: 10;
366
+ display: flex;
367
+ align-items: center;
368
+ justify-content: center;
369
+ gap: 6px;
370
+ padding: 4px 10px;
371
+ box-sizing: border-box;
372
+ text-align: center;
373
+ line-height: 1.2;
374
+ box-shadow: var(--kplex-node-shadow, var(--shadow-s));
375
+ cursor: pointer;
376
+ transition: filter .11s ease, box-shadow .11s ease, opacity .11s ease;
377
+ }
378
+ .kplex-thought:hover { filter: brightness(1.12); z-index: 12; }
379
+ .kplex-thought.is-highlighted { filter: brightness(1.22); box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s); z-index: 13; }
380
+ .kplex-thought.is-dimmed { opacity: .24; filter: saturate(.55) brightness(.72); }
381
+ .kplex-thought.is-selected { box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s); }
382
+ /* Legacy clipping preserves accessible region names and announcements without newer clip-path. */
383
+ .kplex-keyboard-announcement,
384
+ .kplex-accessible-name {
385
+ position: absolute;
386
+ width: 1px;
387
+ height: 1px;
388
+ overflow: hidden;
389
+ clip: rect(0, 0, 0, 0);
390
+ white-space: nowrap;
391
+ }
392
+ .kplex-hotkey-setting .setting-item-control { flex-wrap: wrap; }
393
+ .kplex-thought.is-selected.is-highlighted { box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s); }
394
+ .kplex-role-center { font-weight: 650; z-index: 14; padding: 8px 13px; }
395
+ .kplex-role-sibling { opacity: .86; }
396
+ .kplex-role-sibling.is-dimmed { opacity: .22; }
397
+ .kplex-thought-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
398
+ /* Obsidian's tablet button padding outranks a single control class and can enlarge
399
+ even a fixed-size button in WebKit. Scope the reset to shared node controls,
400
+ retaining each control's visual size and the branch's separate 44px hit area. */
401
+ .kplex-plex .kplex-thought > .kplex-thought-corner-action,
402
+ .kplex-plex .kplex-thought > .kplex-section-fold-handle {
403
+ box-sizing: border-box;
404
+ appearance: none;
405
+ -webkit-appearance: none;
406
+ padding: 0;
407
+ margin: 0;
408
+ }
409
+ .kplex-thought-corner-action {
410
+ position: absolute;
411
+ z-index: 22;
412
+ top: -6px;
413
+ right: -6px;
414
+ display: inline-flex;
415
+ align-items: center;
416
+ justify-content: center;
417
+ width: 16px;
418
+ height: 16px;
419
+ min-width: 16px;
420
+ min-height: 16px;
421
+ max-width: 16px;
422
+ max-height: 16px;
423
+ padding: 0;
424
+ border: 1px solid transparent;
425
+ border-radius: 4px;
426
+ color: var(--kplex-muted, var(--text-muted));
427
+ background: var(--background-secondary);
428
+ cursor: pointer;
429
+ opacity: .76;
430
+ }
431
+ .kplex-thought-corner-action:hover,
432
+ .kplex-thought-corner-action:focus-visible {
433
+ color: var(--kplex-text, var(--text-normal));
434
+ border-color: var(--kplex-line, var(--background-modifier-border));
435
+ background: var(--background-modifier-hover);
436
+ opacity: 1;
437
+ }
438
+ .kplex-thought-corner-action:focus-visible {
439
+ outline: 1px solid var(--kplex-accent, var(--interactive-accent));
440
+ outline-offset: 1px;
441
+ }
442
+ .kplex-count {
443
+ display: inline-flex;
444
+ flex: 0 0 auto;
445
+ min-width: 17px;
446
+ height: 17px;
447
+ align-items: center;
448
+ justify-content: center;
449
+ border-radius: 9px;
450
+ font-size: 9px;
451
+ color: var(--text-muted);
452
+ background: var(--background-secondary);
453
+ border: 1px solid var(--background-modifier-border);
454
+ }
455
+ .kplex-role-center .kplex-count { min-width: 19px; height: 19px; border-radius: 10px; font-size: 10px; }
456
+ .kplex-gate-wrap {
457
+ position: absolute;
458
+ z-index: 18;
459
+ width: var(--kplex-gate-size, 8px);
460
+ height: var(--kplex-gate-size, 8px);
461
+ pointer-events: none;
462
+ }
463
+ .gate-wrap-top { top: calc(-1 * var(--kplex-gate-size, 8px) - 3px); left: 50%; transform: translateX(-50%); }
464
+ .gate-wrap-bottom { bottom: calc(-1 * var(--kplex-gate-size, 8px) - 3px); left: 50%; transform: translateX(-50%); }
465
+ .gate-wrap-left { left: calc(-1 * var(--kplex-gate-size, 8px) - 3px); top: 50%; transform: translateY(-50%); }
466
+ .gate-wrap-right { right: calc(-1 * var(--kplex-gate-size, 8px) - 3px); top: 50%; transform: translateY(-50%); }
467
+ .kplex-gate {
468
+ position: relative;
469
+ display: block;
470
+ width: 100%;
471
+ height: 100%;
472
+ box-sizing: border-box;
473
+ border-radius: 50%;
474
+ background: transparent;
475
+ border: 1.25px solid var(--kplex-gate-stroke, var(--background-modifier-border));
476
+ opacity: .82;
477
+ box-shadow: var(--shadow-s);
478
+ pointer-events: auto;
479
+ cursor: crosshair;
480
+ transition: opacity .1s ease, box-shadow .1s ease, background .1s ease;
481
+ }
482
+ .kplex-gate::after {
483
+ content: "";
484
+ position: absolute;
485
+ inset: -5px;
486
+ border-radius: 50%;
487
+ }
488
+ .kplex-gate.has-connections { background: var(--kplex-gate-fill, var(--interactive-accent)); }
489
+ .kplex-gate.is-empty { background: transparent; }
490
+ .kplex-gate.is-link-disabled { cursor: default; opacity: .56; }
491
+ .kplex-gate.is-link-disabled::after { display: none; }
492
+ .kplex-gate:hover,
493
+ .kplex-gate.is-highlighted { opacity: 1; box-shadow: 0 0 0 2px var(--interactive-accent); }
494
+ .kplex-gate-count {
495
+ position: absolute;
496
+ z-index: 20;
497
+ pointer-events: none;
498
+ min-width: 12px;
499
+ color: var(--text-normal);
500
+ font-size: 8px;
501
+ font-weight: 650;
502
+ line-height: 1;
503
+ text-shadow: none;
504
+ }
505
+ .gate-wrap-top .kplex-gate-count { left: calc(100% + 4px); top: 50%; transform: translateY(-50%); text-align: left; }
506
+ .gate-wrap-bottom .kplex-gate-count { left: calc(100% + 4px); top: 50%; transform: translateY(-50%); text-align: left; }
507
+ .gate-wrap-left .kplex-gate-count { right: calc(100% + 4px); top: 50%; transform: translateY(-50%); text-align: right; }
508
+ .gate-wrap-right .kplex-gate-count { left: calc(100% + 4px); top: 50%; transform: translateY(-50%); text-align: left; }
509
+
510
+ .kplex-sibling-scroll {
511
+ position: absolute;
512
+ z-index: 16;
513
+ overflow-y: auto;
514
+ overflow-x: hidden;
515
+ scrollbar-width: thin;
516
+ scrollbar-color: var(--scrollbar-thumb-bg) transparent;
517
+ overscroll-behavior: contain;
518
+ border-radius: 10px;
519
+ background: transparent;
520
+ }
521
+ .kplex-sibling-scroll::-webkit-scrollbar { width: 7px; }
522
+ .kplex-sibling-scroll::-webkit-scrollbar-track { background: transparent; }
523
+ .kplex-sibling-scroll::-webkit-scrollbar-thumb { background: var(--background-modifier-hover); border-radius: 8px; }
524
+ .kplex-sibling-content { position: relative; width: 100%; min-height: 100%; }
525
+
526
+ .kplex-zoom-controls { position: absolute; z-index: 20; right: 12px; bottom: clamp(0px, calc(100% - 42px), 12px); display: flex; gap: 5px; }
527
+ .kplex-zoom-controls button,
528
+ button.kplex-layout-toggle,
529
+ button.kplex-zone-filter-button,
530
+ .kplex-sidecar-controls button,
531
+ button.kplex-sidecar-unfold-plex,
532
+ .kplex-central-editor-toolbar button,
533
+ .kplex-find button { width: 30px; padding: 0; }
534
+
535
+ .kplex-history-bar {
536
+ z-index: 30;
537
+ display: flex;
538
+ align-items: center;
539
+ gap: 9px;
540
+ padding: 0 9px;
541
+ background: var(--background-secondary);
542
+ border-top: 1px solid var(--background-modifier-border);
543
+ overflow: hidden;
544
+ }
545
+ .kplex-history-label { flex: 0 0 auto; font-size: 8px; font-weight: 700; letter-spacing: .13em; color: var(--text-muted); }
546
+ .kplex-history-list { min-width: 0; display: flex; gap: 5px; overflow-x: auto; scrollbar-width: none; user-select: none; }
547
+ .kplex-history-list.is-mouse-scrolling, .kplex-history-list.is-mouse-scrolling button,
548
+ .kplex-pinned-bar.is-mouse-scrolling, .kplex-pinned-bar.is-mouse-scrolling button { cursor: grabbing; }
549
+ .kplex-history-list::-webkit-scrollbar, .kplex-pinned-bar::-webkit-scrollbar { display: none; }
550
+ .kplex-history-list, .kplex-pinned-bar { touch-action: pan-x pinch-zoom; overscroll-behavior-x: contain; }
551
+ .kplex-history-list button { flex: 0 0 auto; width: 180px; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; justify-content: flex-start; color: var(--text-normal); border: 1px solid var(--background-modifier-border); border-radius: 6px; background: var(--background-primary); padding: 5px 9px; cursor: pointer; font-size: 11px; }
552
+ .kplex-history-list button { display: flex; align-items: center; gap: 5px; }
553
+ .kplex-history-list button > .kplex-icon,
554
+ .kplex-pinned-open > .kplex-icon { flex: 0 0 auto; }
555
+ .kplex-action-picker-row { display: flex; align-items: center; gap: 8px; }
556
+ .kplex-action-picker-row .suggestion-icon { flex: 0 0 auto; display: flex; }
557
+ .kplex-action-picker-row .suggestion-content { min-width: 0; }
558
+ /* A shrinking text box keeps overflowing history titles anchored to their first character,
559
+ even when the host theme centers button contents with flexbox. */
560
+ .kplex-history-text {
561
+ flex: 1 1 auto;
562
+ min-width: 0;
563
+ display: block;
564
+ overflow: hidden;
565
+ text-overflow: ellipsis;
566
+ white-space: nowrap;
567
+ text-align: left;
568
+ line-height: 1.15;
569
+ }
570
+ .kplex-main-column.is-two-line-history {
571
+ grid-template-rows: auto minmax(0, 1fr) 52px;
572
+ }
573
+ .kplex-main-column.is-two-line-history .kplex-history-list button { height: 40px; }
574
+ .kplex-main-column.is-two-line-history .kplex-history-text {
575
+ display: -webkit-box;
576
+ -webkit-box-orient: vertical;
577
+ -webkit-line-clamp: 2;
578
+ white-space: normal;
579
+ overflow-wrap: break-word;
580
+ max-height: 2.3em;
581
+ }
582
+ .kplex-history-list button:hover { box-shadow: inset 0 0 0 1px var(--background-modifier-border-hover); }
583
+ .kplex-history-list button.is-active { outline: 1px solid var(--interactive-accent); outline-offset: -2px; }
584
+ .kplex-empty { display: grid; place-items: center; color: var(--text-muted); }
585
+
586
+ @media (max-width: 900px) {
587
+ .kplex-brand strong { display: none; }
588
+ }
589
+
590
+ /* Obsidian 1.13+ declarative settings keep native rendering; only control width is adjusted. */
591
+ .kplex-settings .setting-item-control textarea {
592
+ width: 100%;
593
+ min-width: min(420px, 52vw);
594
+ max-width: 780px;
595
+ resize: vertical;
596
+ }
597
+ @media (max-width: 900px) {
598
+ .kplex-settings .setting-item-control textarea {
599
+ min-width: 0;
600
+ width: 100%;
601
+ max-width: none;
602
+ }
603
+ }
604
+
605
+ /* K-Plex Lucide icons */
606
+ .kplex-icon { display: inline-flex; align-items: center; justify-content: center; line-height: 0; flex: 0 0 auto; }
607
+ .kplex-icon svg { display: block; stroke: currentColor; }
608
+ .kplex-brand-mark { color: var(--interactive-accent); filter: none; }
609
+ .kplex-index-background .kplex-icon.kplex-brand-mark { opacity: 0.5; }
610
+ .kplex-node-icon { opacity: .88; margin-right: 4px; }
611
+ .kplex-thought-label { display: inline-flex; align-items: center; justify-content: center; min-width: 0; }
612
+ .kplex-thought-label > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
613
+ /* Font ink may extend outside its line box (notably Segoe UI descenders). Keep ellipsis clipping
614
+ around a padded text box; node geometry reserves the same 0.4em of vertical ink space. */
615
+ .kplex-thought-text { padding: .2em 0; box-sizing: content-box; }
616
+ .kplex-thought-caption { display: flex; flex-direction: column; min-width: 0; width: 100%; gap: 4px; }
617
+ .kplex-thought-caption > .kplex-thought-label { flex-shrink: 0; }
618
+ .kplex-node-properties { display: flex; flex-direction: column; min-width: 0; font-size: var(--kplex-node-property-font-size, 12px); line-height: 1.4; font-weight: normal; text-align: start; }
619
+ .kplex-node-property { display: flex; align-items: center; gap: 4px; min-width: 0; overflow: hidden; white-space: nowrap; }
620
+ .kplex-node-property-icon { flex: 0 0 1em; width: 1em; height: 1em; display: inline-flex; align-items: center; justify-content: center; overflow: hidden; }
621
+ .kplex-node-property-icon svg { width: 1em; height: 1em; }
622
+ .kplex-node-property-label { flex: 1 1 0; min-width: 0; max-width: max-content; overflow: hidden; text-overflow: ellipsis; color: var(--text-muted); }
623
+ .kplex-node-property-value { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
624
+ .kplex-property-measurement { position: absolute; left: -100000px; top: 0; visibility: hidden; pointer-events: none; width: max-content; max-width: none; height: auto; transform: none; transition: none; box-shadow: none; }
625
+ .kplex-node-details-editor { min-width: 0; }
626
+ .kplex-node-detail-group { padding: 8px 0; margin-block-end: 16px; border-block-end: 1px solid var(--background-modifier-border); }
627
+ .kplex-node-detail-row .setting-item-control { display: flex; flex-wrap: wrap; gap: 8px; width: 100%; }
628
+ .kplex-node-detail-row .setting-item-control input[type=text] { flex: 1 1 140px; min-width: 0; }
629
+ .kplex-node-details-preview { padding: 16px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); margin-block: 16px; }
630
+ .kplex-note-type-review-group { margin-block-end: 16px; }
631
+ .kplex-note-type-change-preview { white-space: pre-wrap; overflow-wrap: anywhere; }
632
+ @media (max-width: 480px) { .kplex-node-detail-row .setting-item-control input[type=text] { flex-basis: 100%; } }
633
+ .kplex-thought.is-dragging { cursor: grabbing; z-index: 28; filter: brightness(1.16); box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s); }
634
+ .kplex-role-parent,
635
+ .kplex-role-child,
636
+ .kplex-role-left,
637
+ .kplex-role-right,
638
+ .kplex-role-previous,
639
+ .kplex-role-next { cursor: grab; }
640
+
641
+ /* Toolbar mirrors the compact legacy controls while staying horizontally scrollable. */
642
+ .kplex-topbar { overflow: visible; }
643
+ .kplex-top-actions {
644
+ min-width: 0;
645
+ max-width: 58%;
646
+ overflow-x: auto;
647
+ overflow-y: hidden;
648
+ scrollbar-width: none;
649
+ padding: 2px 0;
650
+ }
651
+ .kplex-top-actions::-webkit-scrollbar { display: none; }
652
+ .kplex-view-host .kplex-icon-button { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 30px; }
653
+ .kplex-toolbar-divider { width: 1px; height: 20px; flex: 0 0 1px; margin: 0 2px; background: var(--background-modifier-hover); }
654
+ .kplex-search-icon { display: flex; align-items: center; top: 7px; }
655
+
656
+ /* Interactive relationship editing */
657
+ .kplex-drag-connector {
658
+ pointer-events: none;
659
+ stroke: var(--interactive-accent);
660
+ stroke-width: 2.2px;
661
+ stroke-dasharray: 5 4;
662
+ filter: none;
663
+ }
664
+
665
+ .kplex-relation-actions button {
666
+ display: inline-flex;
667
+ align-items: center;
668
+ justify-content: center;
669
+ width: 30px;
670
+ height: 28px;
671
+ padding: 0;
672
+ color: var(--text-normal);
673
+ border: 1px solid var(--background-modifier-border, var(--background-modifier-border));
674
+ border-radius: 6px;
675
+ background: var(--background-secondary, var(--background-modifier-hover));
676
+ cursor: pointer;
677
+ }
678
+ .kplex-relation-label { display: block; margin: 9px 0 5px; color: var(--text-muted); font-size: 10px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; }
679
+ .kplex-relation-search-wrap { display: flex; align-items: center; gap: 7px; padding: 0 8px; border: 1px solid var(--background-modifier-border); border-radius: 7px; background: var(--background-secondary); }
680
+ .kplex-relation-modal .kplex-relation-search-wrap input { width: 100%; height: 30px; padding: 0; border: 0; box-shadow: none; background: transparent; }
681
+ .kplex-relation-results { max-height: 210px; overflow-y: auto; margin-top: 6px; padding: 3px; border-radius: 7px; background: var(--background-secondary-alt, var(--background-secondary)); }
682
+ .kplex-relation-results button { width: 100%; display: grid; grid-template-columns: 18px minmax(80px, 1fr) minmax(80px, .9fr); align-items: center; gap: 6px; min-height: 30px; padding: 4px 7px; text-align: left; border: 0; border-radius: 5px; color: var(--text-normal); background: transparent; cursor: pointer; }
683
+ .kplex-relation-results button:hover,
684
+ .kplex-relation-results button.is-selected { background: var(--background-modifier-hover, var(--background-modifier-hover)); }
685
+ .kplex-relation-results button.is-selected {
686
+ box-shadow: inset 2px 0 0 var(--interactive-accent);
687
+ }
688
+ .kplex-relation-file-name,
689
+ .kplex-relation-results small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
690
+ .kplex-relation-results small { color: var(--text-muted); text-align: right; }
691
+ .kplex-relation-empty { padding: 10px 8px; color: var(--text-muted); font-size: 11px; }
692
+
693
+ .kplex-relation-hint { margin-top: 8px; padding: 7px 8px; color: var(--text-muted); background: var(--background-secondary); border-radius: 6px; font-size: 10px; line-height: 1.35; }
694
+ .kplex-relation-summary { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 8px; border-radius: 7px; background: var(--background-secondary); }
695
+ .kplex-relation-summary > span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
696
+ .kplex-relation-direction { flex: 0 0 auto; padding: 2px 6px; color: var(--text-accent); border: 1px solid var(--background-modifier-border); border-radius: 10px; font-size: 9px; text-transform: uppercase; letter-spacing: .05em; }
697
+ .kplex-relation-actions { display: flex; justify-content: flex-end; gap: 6px; margin-top: 10px; }
698
+
699
+ /* Property-value node style editor modal */
700
+ .modal.kplex-style-editor-modal {
701
+ width: min(560px, calc(100vw - 32px));
702
+ max-width: calc(100vw - 20px);
703
+ box-sizing: border-box;
704
+ }
705
+ .modal.kplex-style-editor-modal .modal-content { min-width: 0; overflow-x: hidden; }
706
+ .kplex-style-editor > p {
707
+ margin: 0 0 var(--kplex-form-gap, var(--size-4-4));
708
+ }
709
+ .kplex-style-form {
710
+ min-width: 0;
711
+ }
712
+ .kplex-style-row {
713
+ min-width: 0;
714
+ }
715
+ .kplex-style-actions {
716
+ display: flex;
717
+ justify-content: flex-end;
718
+ gap: 8px;
719
+ margin-top: 16px;
720
+ flex-wrap: wrap;
721
+ }
722
+ .kplex-style-actions button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
723
+ .kplex-style-form input.is-invalid { border-color: var(--text-error); }
724
+ .kplex-input-suggestion-line { display: flex; align-items: center; gap: 7px; min-width: 0; }
725
+ .kplex-input-suggestion-line .kplex-lucide { flex: 0 0 auto; width: 16px; height: 16px; color: var(--text-muted); }
726
+ .kplex-input-suggestion-line span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
727
+ @media (max-width: 520px) {
728
+ .kplex-style-actions button { flex: 1 1 auto; }
729
+ }
730
+
731
+ /* K-Plex responsive toolbar: controls wrap rather than disappearing into horizontal scroll. */
732
+ .kplex-main-column {
733
+ grid-template-rows: auto minmax(0, 1fr) 40px;
734
+ }
735
+ .kplex-topbar {
736
+ min-height: 46px;
737
+ height: auto;
738
+ padding: 6px 10px;
739
+ flex-wrap: wrap;
740
+ align-content: center;
741
+ overflow: visible;
742
+ }
743
+ .kplex-search-shell {
744
+ /* Wrap at the usable minimum, after spare margin and search width are consumed. */
745
+ flex: 1 1 100px;
746
+ max-width: 560px;
747
+ }
748
+ .kplex-top-actions {
749
+ flex: 0 0 auto;
750
+ min-width: 0;
751
+ max-width: none;
752
+ margin-left: auto;
753
+ padding: 0;
754
+ overflow: visible;
755
+ flex-wrap: wrap;
756
+ justify-content: flex-end;
757
+ }
758
+ .kplex-toolbar-divider { align-self: center; }
759
+
760
+ /* Eligible hover reveals transient relationship-area boundaries; the modifier preference gates
761
+ normal pointer input. Explicit area settings retain all frames and keyboard height controls. */
762
+ .kplex-area-frame {
763
+ position: absolute;
764
+ z-index: 14;
765
+ box-sizing: border-box;
766
+ pointer-events: none;
767
+ border: 1px dashed var(--background-modifier-border-hover);
768
+ border-radius: 10px;
769
+ opacity: .58;
770
+ transition: opacity 90ms ease, border-color 90ms ease;
771
+ }
772
+ .kplex-area-frame.is-settings-mode {
773
+ border-color: var(--background-modifier-border-focus);
774
+ opacity: .78;
775
+ }
776
+ .kplex-area-frame.is-active {
777
+ border-style: solid;
778
+ border-color: var(--interactive-accent);
779
+ opacity: .82;
780
+ }
781
+ .kplex-area-frame.is-resizing { opacity: 1; }
782
+ /* Dark host borders disappear against the independently configured Plex canvas. A foreground
783
+ theme token keeps the idle dashed outline visible without changing active resize accents. */
784
+ .theme-dark .kplex-area-frame:not(.is-active) {
785
+ border-color: var(--text-muted);
786
+ opacity: .85;
787
+ }
788
+ .kplex-area-frame.is-settings-mode::after,
789
+ .kplex-area-frame.is-active::after {
790
+ content: "";
791
+ position: absolute;
792
+ left: 12px;
793
+ right: 12px;
794
+ height: 5px;
795
+ border-radius: 5px;
796
+ background: var(--interactive-accent);
797
+ opacity: .82;
798
+ }
799
+ .kplex-area-frame.is-active::after,
800
+ .kplex-area-frame.is-resizing::after { opacity: 1; }
801
+ .kplex-area-frame.is-edge-top::after { top: -1px; }
802
+ .kplex-area-frame.is-edge-bottom::after { bottom: -1px; }
803
+ /* Keyboard access shares the visual resize edge; the canvas owns pointer hit testing. */
804
+ .kplex-area-keyboard-handle {
805
+ position: absolute;
806
+ left: 12px;
807
+ right: 12px;
808
+ height: 5px;
809
+ pointer-events: auto;
810
+ cursor: ns-resize;
811
+ }
812
+ .is-edge-top > .kplex-area-keyboard-handle { top: -1px; }
813
+ .is-edge-bottom > .kplex-area-keyboard-handle { bottom: -1px; }
814
+ .kplex-area-keyboard-handle:focus-visible { outline: 2px solid var(--text-accent); }
815
+ .kplex-plex.is-area-resize-ready,
816
+ .kplex-plex.is-area-resizing { cursor: ns-resize; }
817
+ .kplex-area-frame.is-no-height-resize::after { content: none; }
818
+ .kplex-area-frame.is-width-resizable.is-settings-mode::before,
819
+ .kplex-area-frame.is-width-resizable.is-active::before {
820
+ content: "";
821
+ position: absolute;
822
+ top: 12px;
823
+ bottom: 12px;
824
+ width: 5px;
825
+ border-radius: 5px;
826
+ background: var(--interactive-accent);
827
+ opacity: .82;
828
+ }
829
+ .kplex-area-frame.is-side-left::before { left: -1px; }
830
+ .kplex-area-frame.is-side-right::before { right: -1px; }
831
+ .kplex-area-keyboard-handle.is-width-handle {
832
+ top: 12px;
833
+ bottom: 12px;
834
+ left: auto;
835
+ right: auto;
836
+ width: 5px;
837
+ height: auto;
838
+ cursor: ew-resize;
839
+ }
840
+ .kplex-area-keyboard-handle.is-width-handle.is-edge-left { left: -1px; }
841
+ .kplex-area-keyboard-handle.is-width-handle.is-edge-right { right: -1px; }
842
+ .kplex-plex.is-area-width-resize { cursor: ew-resize; }
843
+
844
+ /* Generic bounded graph zones (parents, children, friends and siblings). */
845
+ .kplex-zone-panel {
846
+ position: absolute;
847
+ z-index: 16;
848
+ overflow: visible;
849
+ border-radius: 10px;
850
+ /* Connectors and the Compass decoration remain visible beneath overflowing rows. */
851
+ background: transparent;
852
+ }
853
+ /* An overflowing focused field must remain interactive above adjacent areas' node clips. */
854
+ .kplex-zone-panel:focus-within { z-index: 17; }
855
+ .kplex-zone-fixed {
856
+ position: absolute;
857
+ inset: 0;
858
+ z-index: 1;
859
+ overflow: visible;
860
+ }
861
+ .kplex-zone-scroll {
862
+ position: absolute;
863
+ inset: 0;
864
+ z-index: 1;
865
+ overflow-y: auto;
866
+ overflow-x: hidden;
867
+ overscroll-behavior: contain;
868
+ scrollbar-width: thin;
869
+ scrollbar-color: var(--scrollbar-thumb-bg) transparent;
870
+ }
871
+ .kplex-zone-scroll::-webkit-scrollbar { width: 7px; }
872
+ .kplex-zone-scroll::-webkit-scrollbar-track { background: transparent; }
873
+ .kplex-zone-scroll::-webkit-scrollbar-thumb { background: var(--background-modifier-hover); border-radius: 8px; }
874
+ .kplex-zone-content {
875
+ position: relative;
876
+ width: 100%;
877
+ min-height: 100%;
878
+ }
879
+ .kplex-zone-tools {
880
+ position: absolute;
881
+ z-index: 34;
882
+ /* Anchor the whole control row above the clip, including taller touch buttons and open fields. */
883
+ bottom: calc(100% + 6px);
884
+ right: 0;
885
+ display: flex;
886
+ align-items: center;
887
+ justify-content: flex-end;
888
+ gap: 4px;
889
+ pointer-events: none;
890
+ }
891
+ .kplex-zone-tools > * { pointer-events: auto; }
892
+ .kplex-view-host .kplex-zone-filter-input {
893
+ box-sizing: border-box;
894
+ width: 150px;
895
+ flex: 0 0 150px;
896
+ height: 28px;
897
+ padding: 0 7px;
898
+ font-size: 10px;
899
+ border: 1px solid var(--background-modifier-border);
900
+ border-radius: 6px;
901
+ box-shadow: var(--shadow-s);
902
+ }
903
+
904
+ /* Gate-drag selection is intentionally inverted: only unavailable targets dim. */
905
+ .kplex-thought.is-connect-blocked {
906
+ opacity: .18;
907
+ filter: saturate(.45) brightness(.68);
908
+ }
909
+ .kplex-thought.is-connect-candidate {
910
+ opacity: 1;
911
+ }
912
+ .kplex-thought.is-connect-candidate:hover {
913
+ box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s);
914
+ }
915
+ .kplex-thought.is-connect-origin {
916
+ opacity: 1;
917
+ filter: brightness(1.16);
918
+ box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s);
919
+ }
920
+
921
+ /* Centered Obsidian relationship modal. */
922
+ .kplex-relation-modal {
923
+ width: min(620px, calc(100vw - 48px));
924
+ max-width: min(620px, calc(100vw - 48px));
925
+ }
926
+ .kplex-relation-modal-content {
927
+ display: flex;
928
+ flex-direction: column;
929
+ min-height: 0;
930
+ }
931
+ .kplex-relation-modal .kplex-relation-results {
932
+ max-height: min(38vh, 340px);
933
+ overflow-y: auto;
934
+ }
935
+ .kplex-relation-modal .kplex-relation-actions {
936
+ position: sticky;
937
+ bottom: 0;
938
+ z-index: 4;
939
+ padding-top: 10px;
940
+ background: var(--background-primary);
941
+ }
942
+ .kplex-relation-modal .kplex-relation-actions button {
943
+ width: 34px;
944
+ height: 30px;
945
+ }
946
+ .kplex-relation-modal select { width: 100%; }
947
+
948
+ /* Ontology lists use one shared label/editor grid so every textarea has the same width.
949
+ Scope directly to the setting group: Obsidian settings pages do not provide a
950
+ stable .kplex-settings ancestor. */
951
+ .kplex-ontology-fields > .setting-items {
952
+ width: 100%;
953
+ }
954
+ .kplex-ontology-fields > .setting-items > .setting-item {
955
+ display: grid;
956
+ grid-template-columns: minmax(220px, 1fr) minmax(420px, 1.35fr);
957
+ gap: 32px;
958
+ align-items: start;
959
+ width: 100%;
960
+ }
961
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-info,
962
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-control {
963
+ min-width: 0;
964
+ width: 100%;
965
+ max-width: none;
966
+ margin: 0;
967
+ }
968
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-control {
969
+ display: block;
970
+ justify-self: stretch;
971
+ }
972
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-control textarea {
973
+ display: block;
974
+ box-sizing: border-box;
975
+ width: 100%;
976
+ min-width: 100%;
977
+ max-width: 100%;
978
+ resize: vertical;
979
+ }
980
+
981
+ .kplex-import-file-row { margin: 10px 0 7px; }
982
+ .kplex-import-file-row input[type="file"] { width: 100%; }
983
+ .kplex-import-status { color: var(--text-muted); font-size: var(--font-ui-small); }
984
+
985
+ @media (max-width: 900px) {
986
+ .kplex-ontology-fields > .setting-items > .setting-item {
987
+ grid-template-columns: minmax(0, 1fr);
988
+ row-gap: 8px;
989
+ }
990
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-info,
991
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-control,
992
+ .kplex-ontology-fields > .setting-items > .setting-item > .setting-item-control textarea {
993
+ min-width: 0;
994
+ width: 100%;
995
+ max-width: 100%;
996
+ }
997
+ }
998
+
999
+ /* Refinements: compact nodes, inline relationship labels, zone counts and quick layout controls. */
1000
+ .kplex-thought {
1001
+ padding: 3px 8px;
1002
+ }
1003
+ .kplex-role-center {
1004
+ padding: 7px 11px;
1005
+ }
1006
+ .kplex-edge-label {
1007
+ paint-order: normal;
1008
+ stroke: none;
1009
+ font-weight: 600;
1010
+ }
1011
+
1012
+ .kplex-zone-filter-control {
1013
+ position: relative;
1014
+ display: inline-flex;
1015
+ align-items: center;
1016
+ justify-content: center;
1017
+ }
1018
+ .kplex-zone-count {
1019
+ position: absolute;
1020
+ right: 1px;
1021
+ top: -11px;
1022
+ z-index: 2;
1023
+ min-width: 13px;
1024
+ height: 12px;
1025
+ padding: 0 3px;
1026
+ display: inline-flex;
1027
+ align-items: center;
1028
+ justify-content: center;
1029
+ border-radius: 7px;
1030
+ color: var(--text-muted);
1031
+ background: var(--background-secondary);
1032
+ border: 1px solid var(--background-modifier-border);
1033
+ font-size: 8px;
1034
+ line-height: 1;
1035
+ font-weight: 700;
1036
+ pointer-events: none;
1037
+ }
1038
+
1039
+ .kplex-layout-controls {
1040
+ position: absolute;
1041
+ left: 16px;
1042
+ bottom: 17px;
1043
+ z-index: 34;
1044
+ display: flex;
1045
+ align-items: flex-end;
1046
+ gap: 12px;
1047
+ padding: 5px 7px 4px;
1048
+ border-radius: 8px;
1049
+ background: var(--background-secondary);
1050
+ backdrop-filter: blur(2px);
1051
+ }
1052
+
1053
+ @media (max-width: 760px) {
1054
+ .kplex-layout-controls { left: 8px; bottom: 12px; gap: 6px; padding: 4px; }
1055
+
1056
+ }
1057
+
1058
+ /* Compactness is visual density only: keep the tight node interior padding at every setting. */
1059
+ .kplex-thought { padding: 3px 8px; }
1060
+ .kplex-role-center { padding: 7px 11px; }
1061
+
1062
+ /* Expanded view: each first-level thought can expose a lightweight, scrollable 3x2 child strip. */
1063
+ .kplex-expanded-cluster {
1064
+ position: absolute;
1065
+ z-index: 19;
1066
+ overflow: visible;
1067
+ pointer-events: auto;
1068
+ }
1069
+ .kplex-expanded-scroll {
1070
+ position: absolute;
1071
+ inset: 0;
1072
+ overflow: hidden;
1073
+ overscroll-behavior: contain;
1074
+ scrollbar-width: thin;
1075
+ scrollbar-color: var(--scrollbar-thumb-bg) transparent;
1076
+ }
1077
+ .kplex-expanded-scroll.is-scrollable { overflow-y: auto; overflow-x: hidden; }
1078
+ .kplex-expanded-scroll::-webkit-scrollbar { width: 5px; }
1079
+ .kplex-expanded-scroll::-webkit-scrollbar-track { background: transparent; }
1080
+ .kplex-expanded-scroll::-webkit-scrollbar-thumb { background: var(--background-modifier-hover); border-radius: 8px; }
1081
+ .kplex-expanded-content { position: relative; width: 100%; }
1082
+ .kplex-expanded-mini-thought {
1083
+ position: absolute;
1084
+ z-index: 20;
1085
+ box-sizing: border-box;
1086
+ display: flex;
1087
+ align-items: center;
1088
+ justify-content: center;
1089
+ gap: 3px;
1090
+ padding: 1px 4px;
1091
+ overflow: visible;
1092
+ border: 1px solid var(--background-modifier-border);
1093
+ border-radius: 6px;
1094
+ color: var(--text-muted);
1095
+ font-size: 8px;
1096
+ line-height: 1;
1097
+ opacity: .70;
1098
+ box-shadow: var(--shadow-s);
1099
+ cursor: pointer;
1100
+ transition: opacity .1s ease, filter .1s ease;
1101
+ }
1102
+ .kplex-expanded-mini-thought:hover { opacity: .92; filter: brightness(1.12); }
1103
+ .kplex-expanded-mini-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
1104
+ .kplex-expanded-mini-icon { flex: 0 0 auto; opacity: .82; }
1105
+ .kplex-expanded-mini-gate {
1106
+ position: absolute;
1107
+ left: 50%;
1108
+ top: -3px;
1109
+ width: 4px;
1110
+ height: 4px;
1111
+ transform: translate(-50%, -50%);
1112
+ border: 1px solid var(--background-modifier-border);
1113
+ border-radius: 50%;
1114
+ background: var(--background-modifier-border);
1115
+ pointer-events: none;
1116
+ }
1117
+ .kplex-expanded-edge {
1118
+ pointer-events: none;
1119
+ opacity: .52;
1120
+ filter: none;
1121
+ }
1122
+
1123
+ /* Interaction polish: navigable thoughts use a pointer; the Plex background remains pannable. */
1124
+ .kplex-role-parent,
1125
+ .kplex-role-child,
1126
+ .kplex-role-left,
1127
+ .kplex-role-right,
1128
+ .kplex-role-previous,
1129
+ .kplex-role-next,
1130
+ .kplex-role-sibling,
1131
+ .kplex-thought.is-structural-thought {
1132
+ cursor: pointer;
1133
+ }
1134
+ .kplex-thought:hover { filter: none; }
1135
+ .kplex-thought.is-highlighted:hover { filter: brightness(1.22); }
1136
+ .kplex-thought.is-dragging { cursor: grabbing; }
1137
+
1138
+ /* Bottom-left density controls: deliberately neutral, thin native-range replacements. */
1139
+ .kplex-layout-controls {
1140
+ gap: 14px;
1141
+ padding: 6px 9px 5px;
1142
+ border: 1px solid var(--background-modifier-border);
1143
+ border-radius: 7px;
1144
+ background: var(--background-secondary);
1145
+ box-shadow: var(--shadow-s);
1146
+ }
1147
+
1148
+ /* Performance/UI pass: tighter thought chrome and professional micro controls. */
1149
+ .kplex-view-host .kplex-thought {
1150
+ padding: 1px 8px;
1151
+ }
1152
+ .kplex-view-host .kplex-role-center {
1153
+ padding: 2px 10px;
1154
+ }
1155
+
1156
+ .kplex-layout-controls {
1157
+ left: 14px;
1158
+ bottom: clamp(0px, calc(100% - 45px), 15px);
1159
+ gap: 8px;
1160
+ padding: 0;
1161
+ border: 0;
1162
+ border-radius: 0;
1163
+ background: transparent;
1164
+ box-shadow: none;
1165
+ backdrop-filter: none;
1166
+ }
1167
+ .kplex-density-control {
1168
+ width: 126px;
1169
+ padding: 5px 7px 6px;
1170
+ display: grid;
1171
+ grid-template-rows: 14px 12px;
1172
+ gap: 2px;
1173
+ box-sizing: border-box;
1174
+ border: 1px solid var(--background-modifier-border);
1175
+ border-radius: 7px;
1176
+ background: var(--background-secondary);
1177
+ box-shadow: var(--shadow-s);
1178
+ color: var(--text-muted);
1179
+ cursor: default;
1180
+ user-select: none;
1181
+ }
1182
+ .kplex-density-heading {
1183
+ display: grid;
1184
+ grid-template-columns: 13px 1fr auto;
1185
+ align-items: center;
1186
+ gap: 4px;
1187
+ min-width: 0;
1188
+ }
1189
+ .kplex-density-heading,
1190
+ .kplex-wrap-label-caption {
1191
+ font-size: 7px;
1192
+ line-height: 1;
1193
+ letter-spacing: .055em;
1194
+ text-transform: uppercase;
1195
+ }
1196
+ .kplex-density-heading svg { opacity: .7; }
1197
+ .kplex-density-heading output {
1198
+ min-width: 24px;
1199
+ text-align: right;
1200
+ color: var(--text-muted);
1201
+ font-variant-numeric: tabular-nums;
1202
+ letter-spacing: 0;
1203
+ text-transform: none;
1204
+ }
1205
+ .kplex-density-rail {
1206
+ position: relative;
1207
+ align-self: center;
1208
+ display: block;
1209
+ width: 100%;
1210
+ height: 12px;
1211
+ }
1212
+ .kplex-density-rail::before {
1213
+ content: "";
1214
+ position: absolute;
1215
+ left: 1px;
1216
+ right: 1px;
1217
+ top: 5px;
1218
+ height: 1px;
1219
+ border-radius: 999px;
1220
+ background: var(--background-modifier-border);
1221
+ }
1222
+ .kplex-density-rail.is-stepped::after {
1223
+ content: "";
1224
+ position: absolute;
1225
+ left: 1px;
1226
+ right: 1px;
1227
+ top: 3px;
1228
+ height: 5px;
1229
+ opacity: .28;
1230
+ background: repeating-linear-gradient(to right, transparent 0 calc(14.285% - 1px), var(--background-modifier-border) calc(14.285% - 1px) 14.285%);
1231
+ pointer-events: none;
1232
+ }
1233
+ .kplex-density-fill {
1234
+ position: absolute;
1235
+ left: 1px;
1236
+ top: 5px;
1237
+ height: 1px;
1238
+ border-radius: 999px;
1239
+ background: var(--interactive-accent);
1240
+ pointer-events: none;
1241
+ }
1242
+ .kplex-view-host .kplex-density-rail input[type="range"] {
1243
+ -webkit-appearance: none;
1244
+ appearance: none;
1245
+ position: absolute;
1246
+ inset: 0;
1247
+ width: 100%;
1248
+ height: 12px;
1249
+ min-height: 12px;
1250
+ margin: 0;
1251
+ padding: 0;
1252
+ border: 0;
1253
+ background: transparent;
1254
+ box-shadow: none;
1255
+ outline: none;
1256
+ cursor: ew-resize;
1257
+ }
1258
+ .kplex-view-host .kplex-density-rail input[type="range"]::-webkit-slider-runnable-track {
1259
+ height: 12px;
1260
+ border: 0;
1261
+ background: transparent;
1262
+ box-shadow: none;
1263
+ }
1264
+ .kplex-view-host .kplex-density-rail input[type="range"]::-webkit-slider-thumb {
1265
+ -webkit-appearance: none;
1266
+ appearance: none;
1267
+ width: 8px;
1268
+ height: 8px;
1269
+ min-width: 8px;
1270
+ min-height: 8px;
1271
+ margin-top: 2px;
1272
+ padding: 0;
1273
+ border: 1px solid var(--background-modifier-border);
1274
+ border-radius: 50%;
1275
+ background: var(--interactive-accent);
1276
+ box-shadow: var(--shadow-s);
1277
+ }
1278
+ .kplex-view-host .kplex-density-rail input[type="range"]::-moz-range-track {
1279
+ height: 12px;
1280
+ border: 0;
1281
+ background: transparent;
1282
+ }
1283
+ .kplex-view-host .kplex-density-rail input[type="range"]::-moz-range-progress { background: transparent; }
1284
+ .kplex-view-host .kplex-density-rail input[type="range"]::-moz-range-thumb {
1285
+ width: 8px;
1286
+ height: 8px;
1287
+ border: 1px solid var(--background-modifier-border);
1288
+ border-radius: 50%;
1289
+ background: var(--interactive-accent);
1290
+ box-shadow: var(--shadow-s);
1291
+ }
1292
+
1293
+ /* K-Plex top stack: toolbar plus persistent quick-access pins. */
1294
+ .kplex-top-stack {
1295
+ position: relative;
1296
+ z-index: 30;
1297
+ min-width: 0;
1298
+ background: var(--background-secondary);
1299
+ border-bottom: 1px solid var(--kplex-line, var(--background-modifier-border));
1300
+ }
1301
+ .kplex-top-stack .kplex-topbar {
1302
+ border-bottom: 0;
1303
+ box-shadow: none;
1304
+ }
1305
+ .kplex-pinned-row {
1306
+ display: flex;
1307
+ min-width: 0;
1308
+ align-items: center;
1309
+ background: var(--background-secondary);
1310
+ }
1311
+ .kplex-pin-tools { display: flex; flex: 0 0 auto; gap: 2px; padding: 2px 2px 6px 8px; }
1312
+ .kplex-pin-tools .kplex-icon-button { width: 28px; height: 28px; }
1313
+ .kplex-calendar-modal { width: 360px; max-width: calc(100vw - 24px); }
1314
+ .kplex-calendar-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
1315
+ .kplex-calendar-heading > span { font-weight: 600; text-align: center; }
1316
+ .kplex-calendar-weekdays, .kplex-calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
1317
+ .kplex-calendar-weekdays { color: var(--text-muted); text-align: center; font-size: var(--font-ui-smaller); margin-bottom: 4px; }
1318
+ .kplex-calendar-grid { margin-bottom: 12px; }
1319
+ .kplex-calendar-grid button { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 0; height: 40px; padding: 2px; }
1320
+ .kplex-calendar-grid .is-other-month { color: var(--text-muted); }
1321
+ .kplex-calendar-grid .is-today { outline: 2px solid var(--interactive-accent); outline-offset: -2px; }
1322
+ .kplex-calendar-grid .has-note { font-weight: 600; }
1323
+ .kplex-calendar-note-dot { height: 9px; line-height: 9px; color: var(--interactive-accent); }
1324
+ .kplex-calendar-picker input[type="date"] { width: 100%; }
1325
+ .kplex-pinned-bar {
1326
+ flex: 1 1 auto;
1327
+ min-width: 0;
1328
+ display: flex;
1329
+ align-items: center;
1330
+ gap: 6px;
1331
+ min-height: 30px;
1332
+ padding: 2px 10px 6px;
1333
+ overflow-x: auto;
1334
+ overflow-y: hidden;
1335
+ scrollbar-width: none;
1336
+ user-select: none;
1337
+ background: var(--background-secondary);
1338
+ }
1339
+ .kplex-pinned-chip {
1340
+ flex: 0 0 auto;
1341
+ display: inline-flex;
1342
+ align-items: stretch;
1343
+ max-width: 240px;
1344
+ border: 1px solid var(--background-modifier-border);
1345
+ border-radius: 7px;
1346
+ overflow: hidden;
1347
+ background: var(--background-modifier-hover);
1348
+ }
1349
+ .kplex-pinned-chip.is-active {
1350
+ outline: 1px solid var(--interactive-accent);
1351
+ outline-offset: -2px;
1352
+ }
1353
+ .kplex-pinned-chip.is-unavailable { color: var(--text-muted); }
1354
+ .kplex-pinned-bar.is-reordering { cursor: grabbing; background: color-mix(in srgb, var(--interactive-accent) 10%, var(--background-secondary)); }
1355
+ .kplex-pinned-bar.is-reordering > .kplex-pinned-chip { opacity: .5; }
1356
+ .kplex-pinned-bar.is-reordering > .kplex-pinned-chip.is-reorder-source {
1357
+ position: relative;
1358
+ z-index: 2;
1359
+ opacity: 1;
1360
+ outline: 2px solid var(--interactive-accent);
1361
+ outline-offset: -2px;
1362
+ box-shadow: var(--shadow-s);
1363
+ transform: translateX(var(--reorder-drag-x, 0px));
1364
+ pointer-events: none;
1365
+ }
1366
+ .kplex-pinned-bar.is-reordering > .kplex-pinned-chip.is-reorder-before {
1367
+ opacity: 1;
1368
+ box-shadow: inset 5px 0 var(--interactive-accent);
1369
+ border-left-color: var(--interactive-accent);
1370
+ }
1371
+ .kplex-pinned-bar.is-reorder-end > .kplex-pinned-chip:last-child { opacity: 1; box-shadow: inset -5px 0 var(--interactive-accent); }
1372
+ .kplex-pinned-chip .kplex-pin-reorder-handle { width: 18px; padding: 0; cursor: grab; touch-action: none; }
1373
+ .kplex-pinned-bar.is-reordering .kplex-pin-reorder-handle { cursor: grabbing; }
1374
+ .kplex-pinned-chip button {
1375
+ height: 25px;
1376
+ border: 0;
1377
+ border-radius: 0;
1378
+ background: transparent;
1379
+ color: inherit;
1380
+ cursor: pointer;
1381
+ }
1382
+ .kplex-pinned-chip button:hover { background: var(--background-modifier-hover); color: inherit; }
1383
+ .kplex-pinned-open {
1384
+ min-width: 0;
1385
+ max-width: 205px;
1386
+ display: inline-flex;
1387
+ align-items: center;
1388
+ gap: 5px;
1389
+ padding: 0 8px;
1390
+ text-align: left;
1391
+ font-size: 10px;
1392
+ }
1393
+ .kplex-pinned-open svg { flex: 0 0 auto; color: var(--text-accent); }
1394
+ .kplex-pinned-open span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
1395
+ .kplex-view-host .kplex-pinned-remove {
1396
+ width: 25px;
1397
+ padding: 0;
1398
+ display: inline-flex;
1399
+ align-items: center;
1400
+ justify-content: center;
1401
+ border-left: 1px solid var(--background-modifier-border);
1402
+ color: var(--text-muted);
1403
+ }
1404
+
1405
+ /* Keyboard search selection mirrors pointer hover and remains visible while arrowing. */
1406
+ .kplex-search-results .kplex-search-result.is-selected {
1407
+ color: var(--text-normal);
1408
+ background: var(--background-modifier-hover);
1409
+ box-shadow: inset 2px 0 0 var(--interactive-accent);
1410
+ }
1411
+
1412
+ /* Sibling nodes and their expanded descendants deliberately read as secondary context. */
1413
+ .kplex-expanded-mini-thought.is-sibling-descendant {
1414
+ opacity: .60;
1415
+ padding-left: 3px;
1416
+ padding-right: 3px;
1417
+ }
1418
+
1419
+ /* Compact resource links on the opening declarative settings page. */
1420
+ .kplex-settings .kplex-resource-links {
1421
+ display: flex;
1422
+ justify-content: center;
1423
+ align-items: center;
1424
+ gap: 0;
1425
+ flex-wrap: wrap;
1426
+ padding: 2px 0 10px;
1427
+ margin-bottom: 2px;
1428
+ border-bottom: 1px solid var(--background-modifier-border);
1429
+ }
1430
+ .kplex-settings .kplex-resource-links .setting-item {
1431
+ position: relative;
1432
+ flex: 0 0 auto;
1433
+ width: auto;
1434
+ min-width: 0;
1435
+ padding: 0 10px;
1436
+ border: 0;
1437
+ }
1438
+ .kplex-settings .kplex-resource-links .setting-item + .setting-item::before {
1439
+ content: "|";
1440
+ position: absolute;
1441
+ left: -2px;
1442
+ top: 50%;
1443
+ transform: translateY(-50%);
1444
+ color: var(--text-faint);
1445
+ }
1446
+ .kplex-settings .kplex-resource-links .setting-item-info {
1447
+ margin: 0;
1448
+ }
1449
+ .kplex-settings .kplex-resource-links .setting-item-name {
1450
+ color: var(--text-accent);
1451
+ font-size: var(--font-ui-small);
1452
+ white-space: nowrap;
1453
+ }
1454
+ .kplex-settings .kplex-resource-links .setting-item-description { display: none; }
1455
+ .kplex-settings .kplex-resource-links .setting-item-control { margin-left: 5px; }
1456
+ .kplex-settings .kplex-resource-links button {
1457
+ min-width: 0;
1458
+ height: 24px;
1459
+ padding: 0 6px;
1460
+ font-size: var(--font-ui-smaller);
1461
+ }
1462
+
1463
+ /* Relationship explainability */
1464
+ .kplex-explanation-modal { max-width: 760px; }
1465
+ .kplex-explanation-pair { margin-bottom: 8px; font-size: 1.05em; }
1466
+ .kplex-explanation-result { margin: 8px 0; font-weight: 600; }
1467
+ .kplex-explanation-summary { margin: 8px 0 16px; color: var(--text-muted); line-height: 1.45; }
1468
+ .kplex-explanation-evidence { display: flex; flex-direction: column; gap: 8px; }
1469
+ .kplex-explanation-evidence-row { border: 1px solid var(--background-modifier-border); border-radius: 6px; padding: 8px 10px; }
1470
+ .kplex-explanation-evidence-row.is-suppressed { opacity: .72; }
1471
+ .kplex-explanation-state { display: inline-block; min-width: 82px; margin-right: 8px; font-size: 10px; font-weight: 700; letter-spacing: .06em; color: var(--text-accent); }
1472
+ .kplex-explanation-evidence-row.is-suppressed .kplex-explanation-state { color: var(--text-muted); }
1473
+ .kplex-explanation-description { font-size: 12px; }
1474
+ .kplex-explanation-evidence code { display: block; margin-top: 6px; white-space: pre-wrap; overflow-wrap: anywhere; }
1475
+ .kplex-explanation-reason { margin-top: 5px; color: var(--text-muted); font-size: 11px; }
1476
+ .kplex-explanation-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
1477
+ .kplex-explanation-navigate { height: 28px; min-height: 28px; padding: 0 9px; font-size: var(--font-ui-smaller); }
1478
+ .kplex-explanation-empty { color: var(--text-muted); }
1479
+
1480
+ .kplex-explanation-display-context {
1481
+ margin: 8px 0;
1482
+ padding: 8px 10px;
1483
+ border-left: 3px solid var(--interactive-accent);
1484
+ background: var(--background-secondary);
1485
+ color: var(--text-muted);
1486
+ }
1487
+
1488
+ /* --------------------------------------------------------------------------
1489
+ * K-Plex mobile, sidepanel, filtering and transition refinements
1490
+ * -------------------------------------------------------------------------- */
1491
+ .kplex-plex {
1492
+ overscroll-behavior: none;
1493
+ -webkit-user-select: none;
1494
+ user-select: none;
1495
+ }
1496
+
1497
+ /* The graph itself owns one- and two-finger gestures. Scrollable relationship
1498
+ lists opt back in to vertical touch scrolling below. */
1499
+ .kplex-plex,
1500
+ .kplex-camera,
1501
+ .kplex-nodes {
1502
+ touch-action: none;
1503
+ }
1504
+ .kplex-zone-scroll,
1505
+ .kplex-expanded-scroll,
1506
+ .kplex-relation-results {
1507
+ touch-action: pan-y;
1508
+ overscroll-behavior: contain;
1509
+ -webkit-overflow-scrolling: touch;
1510
+ }
1511
+
1512
+ /* Global visible-Plex filter. It intentionally lives in the toolbar rather
1513
+ than consuming graph space until opened. */
1514
+ .kplex-filter {
1515
+ position: relative;
1516
+ flex: 0 0 auto;
1517
+ }
1518
+ .kplex-filter > summary {
1519
+ list-style: none;
1520
+ }
1521
+ .kplex-filter > summary::-webkit-details-marker { display: none; }
1522
+ .kplex-filter.is-active > summary {
1523
+ color: var(--text-normal);
1524
+ border-color: var(--background-modifier-border);
1525
+ background: var(--background-modifier-hover);
1526
+ }
1527
+ .kplex-filter-panel {
1528
+ position: absolute;
1529
+ z-index: 90;
1530
+ top: calc(100% + 6px);
1531
+ left: 0;
1532
+ display: grid;
1533
+ grid-template-columns: minmax(155px, 1fr);
1534
+ gap: 8px;
1535
+ width: min(290px, calc(100vw - 28px));
1536
+ padding: 10px;
1537
+ border: 1px solid var(--background-modifier-border);
1538
+ border-radius: 8px;
1539
+ background: var(--background-primary-alt, var(--background-primary));
1540
+ box-shadow: var(--shadow-s);
1541
+ }
1542
+ .kplex-filter-panel label {
1543
+ display: grid;
1544
+ gap: 3px;
1545
+ color: var(--text-muted);
1546
+ font-size: 10px;
1547
+ font-weight: 600;
1548
+ letter-spacing: .025em;
1549
+ }
1550
+ .kplex-filter-panel input,
1551
+ .kplex-filter-panel select {
1552
+ width: 100%;
1553
+ min-width: 0;
1554
+ font-size: var(--font-ui-small);
1555
+ }
1556
+ .kplex-filter-panel button { justify-self: end; }
1557
+
1558
+ /* Sidepanel views deliberately trade toolbar chrome for graph space. */
1559
+ .kplex-surface-sidepanel .kplex-topbar {
1560
+ gap: 4px;
1561
+ padding: 4px 6px;
1562
+ flex-wrap: wrap;
1563
+ }
1564
+ .kplex-surface-sidepanel .kplex-brand {
1565
+ min-width: auto;
1566
+ }
1567
+ .kplex-surface-sidepanel .kplex-brand strong { display: none; }
1568
+ .kplex-surface-sidepanel .kplex-brand-mark { width: 17px; height: 17px; }
1569
+ .kplex-surface-sidepanel .kplex-search { min-width: 110px; flex: 1 1 145px; }
1570
+ .kplex-surface-sidepanel .kplex-top-actions {
1571
+ flex: 1 1 100%;
1572
+ min-width: 0;
1573
+ overflow-x: auto;
1574
+ overflow-y: hidden;
1575
+ justify-content: flex-start;
1576
+ scrollbar-width: none;
1577
+ }
1578
+ .kplex-surface-sidepanel .kplex-top-actions::-webkit-scrollbar { display: none; }
1579
+ .kplex-surface-sidepanel .kplex-topbar button { flex: 0 0 auto; }
1580
+ .kplex-surface-sidepanel .kplex-pinned-bar { padding-left: 6px; padding-right: 6px; }
1581
+ .kplex-surface-sidepanel .kplex-history-label { display: none; }
1582
+ .kplex-surface-sidepanel .kplex-history-bar { padding-left: 5px; padding-right: 5px; }
1583
+ .kplex-surface-sidepanel .kplex-layout-controls { transform: scale(.92); transform-origin: bottom left; }
1584
+
1585
+ /* Scene motion is driven by FLIP/Web Animations in PlexGraph so nodes that existed in both
1586
+ scenes visibly migrate between their actual old/new positions. CSS only handles connector
1587
+ appearance; duplicating positional CSS transitions here makes the FLIP transform fight layout. */
1588
+ @keyframes kplex-edge-arrive { from { opacity: 0; } to { opacity: 1; } }
1589
+ /* Only actual scene transitions animate arrival. Follow/focus and source updates must not
1590
+ restart opacity on stationary connectors. Keep the inner group separate from hover dimming. */
1591
+ .kplex-plex.is-scene-transitioning .kplex-edge-paint {
1592
+ animation: kplex-edge-arrive max(120ms, calc(var(--kplex-motion-ms, 560ms) * .55)) ease-out both;
1593
+ }
1594
+ .kplex-plex.is-following-document .kplex-edge-paint { animation: none; }
1595
+ @media (prefers-reduced-motion: reduce) {
1596
+ .kplex-plex.is-scene-transitioning .kplex-edge-paint { animation: none; }
1597
+ }
1598
+
1599
+ .kplex-plex.is-section-expanded .kplex-thought.is-selected {
1600
+ box-shadow: 0 0 0 2px var(--interactive-accent), var(--shadow-s);
1601
+ }
1602
+
1603
+ /* Relation/new-note modal additions. */
1604
+ .kplex-relation-new-note {
1605
+ display: inline-flex;
1606
+ align-items: center;
1607
+ gap: 6px;
1608
+ margin-top: 8px;
1609
+ }
1610
+ .kplex-relation-new-note .kplex-lucide { width: 14px; height: 14px; }
1611
+
1612
+ /* On narrow touch devices prioritize graph navigation and large hit targets.
1613
+ Platform-specific layout density itself is stored in settings profiles. */
1614
+ @media (max-width: 700px) {
1615
+ .kplex-view-host .kplex-topbar {
1616
+ gap: 4px;
1617
+ padding: 4px 5px;
1618
+ }
1619
+ .kplex-view-host .kplex-brand strong { display: none; }
1620
+ /* The index dot already has an enlarged invisible hit target; keep its visible size. */
1621
+ .kplex-view-host .kplex-topbar button:where(:not(.kplex-index-status)),
1622
+ .kplex-view-host .kplex-icon-button:where(:not(.kplex-index-status)),
1623
+ .kplex-view-host .kplex-zoom-controls button,
1624
+ .kplex-view-host button.kplex-zone-filter-button,
1625
+ .kplex-sidecar-controls button,
1626
+ .kplex-central-editor-toolbar button,
1627
+ button.kplex-sidecar-unfold-plex {
1628
+ min-width: 30px;
1629
+ min-height: 30px;
1630
+ }
1631
+ .kplex-view-host .kplex-search { flex: 1 1 130px; min-width: 100px; }
1632
+ .kplex-view-host .kplex-top-actions {
1633
+ flex: 0 0 auto;
1634
+ overflow-x: auto;
1635
+ overflow-y: hidden;
1636
+ scrollbar-width: none;
1637
+ }
1638
+ .kplex-view-host .kplex-top-actions::-webkit-scrollbar { display: none; }
1639
+ .kplex-view-host .kplex-filter-panel {
1640
+ position: fixed;
1641
+ top: max(52px, env(safe-area-inset-top));
1642
+ left: 8px;
1643
+ right: 8px;
1644
+ width: auto;
1645
+ }
1646
+ .kplex-view-host .kplex-history-bar { min-height: 26px; }
1647
+ .kplex-view-host .kplex-layout-controls { max-width: calc(100% - 70px); }
1648
+ }
1649
+
1650
+ /* Fade the bounded canvas, not the zero-sized camera whose overflow can span thousands of
1651
+ scroll rows. Keeping the opacity layer inside the canvas clip avoids oversized stale scroll
1652
+ textures during navigation/window exposure. Individual visible thoughts retain their motion. */
1653
+ @keyframes kplex-scene-arrive {
1654
+ 0% { opacity: .82; }
1655
+ 100% { opacity: 1; }
1656
+ }
1657
+ .kplex-plex.is-scene-transitioning {
1658
+ animation: kplex-scene-arrive max(120ms, calc(var(--kplex-motion-ms, 560ms) * .72)) ease-out both;
1659
+ }
1660
+ @media (prefers-reduced-motion: reduce) {
1661
+ .kplex-plex.is-scene-transitioning { animation: none; }
1662
+ }
1663
+
1664
+ /* Touch/mobile rendering stability --------------------------------------
1665
+ iOS WebViews are much more sensitive to large transformed/filter-heavy layers. Keep K-Plex
1666
+ visually identical enough on touch devices while avoiding forced 3D compositing and hundreds
1667
+ of simultaneous drop-shadow/position animations during a gesture. Camera motion itself is
1668
+ requestAnimationFrame-batched in PlexGraph. */
1669
+ @media (hover: none) and (pointer: coarse) {
1670
+ .kplex-camera.is-camera-moving { will-change: auto; }
1671
+ .kplex-edge-visible { filter: none; }
1672
+ .kplex-edge.is-highlighted .kplex-edge-visible { filter: none; }
1673
+ }
1674
+
1675
+ /* Direct manipulation is intentionally visually cheaper than an idle Plex. In particular, iOS
1676
+ WebViews can reload under memory pressure when a large transformed graph, drop shadows and
1677
+ hundreds of CSS animations are all rasterized while pinching. The gesture classes are toggled
1678
+ imperatively, so this adds no React render traffic during pan/pinch. */
1679
+ .kplex-plex.is-touch-gesturing .kplex-thought,
1680
+ .kplex-plex.is-touch-gesturing .kplex-edge,
1681
+ .kplex-plex.is-touch-gesturing .kplex-expanded-edge,
1682
+ .kplex-plex.is-pinch-gesturing .kplex-camera {
1683
+ animation: none;
1684
+ transition: none;
1685
+ }
1686
+ .kplex-plex.is-pinch-gesturing .kplex-thought {
1687
+ box-shadow: none;
1688
+ }
1689
+ .kplex-plex.is-pinch-gesturing .kplex-edge-label-wrap {
1690
+ opacity: 0;
1691
+ }
1692
+ .kplex-plex.is-pinch-gesturing .kplex-section-tree-edge {
1693
+ filter: none;
1694
+ }
1695
+
1696
+ /* iOS WebKit is particularly prone to process reloads when a large SVG relationship layer and
1697
+ hundreds of shadowed HTML nodes are continuously rescaled together. During the *active* pinch
1698
+ gesture keep thoughts visible but temporarily suppress expensive relationship painting. The
1699
+ edges return as soon as the second finger lifts. Android/desktop keep the full graph. */
1700
+ .kplex-plex.is-ios.is-pinch-gesturing .kplex-edge-visible,
1701
+ .kplex-plex.is-ios.is-pinch-gesturing .kplex-expanded-edge,
1702
+ .kplex-plex.is-ios.is-pinch-gesturing .kplex-section-tree-edge {
1703
+ opacity: 0;
1704
+ }
1705
+ .kplex-plex.is-ios.is-pinch-gesturing .kplex-thought {
1706
+ box-shadow: none;
1707
+ filter: none;
1708
+ }
1709
+
1710
+ /* Section outline tree ----------------------------------------------------
1711
+ Central-note sections use a document-outline language, not ordinary Plex thought styling.
1712
+ Structural hierarchy is a solid orthogonal tree entering each heading at its left-center edge;
1713
+ semantic relationships still use the normal four K-Plex gates. */
1714
+ .kplex-section-tree-edge {
1715
+ stroke: color-mix(in srgb, var(--interactive-accent) 64%, var(--text-muted));
1716
+ stroke-width: 1.55;
1717
+ stroke-linecap: square;
1718
+ stroke-linejoin: miter;
1719
+ opacity: .9;
1720
+ pointer-events: none;
1721
+ }
1722
+ .kplex-thought.is-kplex-section {
1723
+ border-radius: 4px;
1724
+ border: 1px solid color-mix(in srgb, var(--text-muted) 34%, var(--background-modifier-border));
1725
+ border-left: 3px solid color-mix(in srgb, var(--interactive-accent) 66%, var(--text-accent));
1726
+ background: color-mix(in srgb, var(--background-secondary) 94%, var(--interactive-accent) 6%);
1727
+ color: var(--text-normal);
1728
+ box-shadow: var(--shadow-s);
1729
+ }
1730
+ .kplex-thought.is-kplex-section:hover {
1731
+ border-color: color-mix(in srgb, var(--interactive-accent) 58%, var(--background-modifier-border));
1732
+ border-left-color: var(--interactive-accent);
1733
+ background: color-mix(in srgb, var(--background-secondary) 90%, var(--interactive-accent) 10%);
1734
+ box-shadow: var(--shadow-s);
1735
+ }
1736
+ /* Incoming structural port: the L-branch terminates here at the card's left-center edge. */
1737
+ .kplex-thought.is-kplex-section::after {
1738
+ content: "";
1739
+ position: absolute;
1740
+ left: -4px;
1741
+ top: 50%;
1742
+ width: 7px;
1743
+ height: 7px;
1744
+ transform: translate(-50%, -50%);
1745
+ border-radius: 1px;
1746
+ background: var(--background-primary);
1747
+ border: 1.5px solid color-mix(in srgb, var(--interactive-accent) 72%, var(--text-muted));
1748
+ pointer-events: none;
1749
+ }
1750
+ .kplex-thought.is-kplex-section .kplex-thought-label {
1751
+ justify-content: flex-start;
1752
+ gap: 8px;
1753
+ padding-inline: 8px 10px;
1754
+ color: var(--text-normal);
1755
+ font-weight: 570;
1756
+ letter-spacing: .003em;
1757
+ }
1758
+ .kplex-section-heading-mark {
1759
+ display: inline-flex;
1760
+ align-items: center;
1761
+ justify-content: center;
1762
+ flex: 0 0 auto;
1763
+ min-width: 24px;
1764
+ padding: 0 3px;
1765
+ border: 0;
1766
+ border-radius: 3px;
1767
+ background: color-mix(in srgb, var(--interactive-accent) 10%, transparent);
1768
+ color: color-mix(in srgb, var(--text-accent) 86%, var(--text-normal));
1769
+ font-size: 9px;
1770
+ font-weight: 760;
1771
+ line-height: 18px;
1772
+ }
1773
+ .kplex-thought.is-kplex-section .kplex-gate.is-empty,
1774
+ .kplex-thought.is-kplex-section .kplex-gate-wrap.is-empty .kplex-gate-count {
1775
+ opacity: 0;
1776
+ pointer-events: none;
1777
+ }
1778
+ .kplex-section-fold-handle {
1779
+ position: absolute;
1780
+ left: 14px;
1781
+ bottom: -6px;
1782
+ width: 10px;
1783
+ height: 10px;
1784
+ min-width: 10px;
1785
+ min-height: 10px;
1786
+ padding: 0;
1787
+ margin: 0;
1788
+ transform: translateX(-50%);
1789
+ border: 1.5px solid color-mix(in srgb, var(--interactive-accent) 76%, var(--text-muted));
1790
+ border-radius: 1px;
1791
+ background: var(--background-primary);
1792
+ box-shadow: 0 0 0 2px color-mix(in srgb, var(--background-primary) 88%, transparent);
1793
+ z-index: 8;
1794
+ cursor: pointer;
1795
+ }
1796
+ .kplex-section-fold-handle.is-expanded::after {
1797
+ content: "";
1798
+ position: absolute;
1799
+ left: 2px; right: 2px; top: 3px;
1800
+ height: 1.5px;
1801
+ border-radius: 1px;
1802
+ background: var(--interactive-accent);
1803
+ }
1804
+ .kplex-section-fold-handle.is-folded {
1805
+ background: color-mix(in srgb, var(--interactive-accent) 72%, var(--background-primary));
1806
+ }
1807
+ .kplex-section-fold-handle.is-folded::before,
1808
+ .kplex-section-fold-handle.is-folded::after {
1809
+ content: "";
1810
+ position: absolute;
1811
+ background: var(--background-primary);
1812
+ border-radius: 1px;
1813
+ }
1814
+ .kplex-section-fold-handle.is-folded::before { left: 2px; right: 2px; top: 3px; height: 1.5px; }
1815
+ .kplex-section-fold-handle.is-folded::after { top: 2px; bottom: 2px; left: 3px; width: 1.5px; }
1816
+ .kplex-section-fold-handle:hover {
1817
+ border-color: var(--interactive-accent);
1818
+ box-shadow: 0 0 0 3px color-mix(in srgb, var(--interactive-accent) 16%, transparent);
1819
+ }
1820
+ .kplex-section-fold-handle.is-branch-disclosure {
1821
+ left: auto;
1822
+ right: -6px;
1823
+ transform: none;
1824
+ width: 16px;
1825
+ height: 16px;
1826
+ inline-size: 16px;
1827
+ block-size: 16px;
1828
+ min-inline-size: 16px;
1829
+ min-block-size: 16px;
1830
+ max-inline-size: 16px;
1831
+ max-block-size: 16px;
1832
+ flex: 0 0 16px;
1833
+ bottom: -6px;
1834
+ display: flex;
1835
+ align-items: center;
1836
+ justify-content: center;
1837
+ border-radius: 4px;
1838
+ color: var(--text-normal);
1839
+ background: var(--background-primary);
1840
+ }
1841
+ .kplex-section-fold-handle.is-branch-disclosure::before,
1842
+ .kplex-section-fold-handle.is-branch-disclosure::after { content: none; }
1843
+ .kplex-branch-disclosure-symbol {
1844
+ display: flex;
1845
+ align-items: center;
1846
+ justify-content: center;
1847
+ width: 100%;
1848
+ height: 100%;
1849
+ }
1850
+ .kplex-section-fold-handle.is-branch-disclosure.has-expanded-hit-target {
1851
+ left: calc(100% - 10px);
1852
+ top: calc(100% - 10px);
1853
+ right: auto;
1854
+ bottom: auto;
1855
+ width: 44px;
1856
+ height: 44px;
1857
+ inline-size: 44px;
1858
+ block-size: 44px;
1859
+ min-inline-size: 44px;
1860
+ min-block-size: 44px;
1861
+ max-inline-size: 44px;
1862
+ max-block-size: 44px;
1863
+ flex-basis: 44px;
1864
+ align-items: flex-start;
1865
+ justify-content: flex-start;
1866
+ padding: 0;
1867
+ border: 0;
1868
+ box-shadow: none;
1869
+ background: transparent;
1870
+ }
1871
+ .has-expanded-hit-target .kplex-branch-disclosure-symbol {
1872
+ box-sizing: border-box;
1873
+ width: 16px;
1874
+ height: 16px;
1875
+ border: 1px solid var(--interactive-accent);
1876
+ border-radius: 4px;
1877
+ background: var(--background-primary);
1878
+ }
1879
+ .has-expanded-hit-target:hover .kplex-branch-disclosure-symbol {
1880
+ border-color: var(--interactive-accent-hover);
1881
+ }
1882
+ .kplex-node-status {
1883
+ position: absolute;
1884
+ left: 0;
1885
+ bottom: -16px;
1886
+ max-width: 100%;
1887
+ overflow: hidden;
1888
+ white-space: nowrap;
1889
+ text-overflow: ellipsis;
1890
+ font-size: 10px;
1891
+ line-height: 12px;
1892
+ color: var(--text-muted);
1893
+ background: var(--background-primary);
1894
+ pointer-events: none;
1895
+ }
1896
+
1897
+ /* Relationship edits are optimistic, but briefly block accidental follow-up clicks until the
1898
+ metadata cache + authoritative index have caught up. */
1899
+ .kplex-relationship-updating {
1900
+ position: absolute;
1901
+ inset: 0;
1902
+ z-index: 90;
1903
+ display: flex;
1904
+ align-items: flex-start;
1905
+ justify-content: center;
1906
+ padding-top: 56px;
1907
+ background: color-mix(in srgb, var(--background-primary) 5%, transparent);
1908
+ cursor: wait;
1909
+ pointer-events: auto;
1910
+ }
1911
+ .kplex-relationship-updating > span,
1912
+ .kplex-relationship-updating > svg { pointer-events: none; }
1913
+ .kplex-relationship-updating {
1914
+ gap: 7px;
1915
+ color: var(--text-normal);
1916
+ font-size: var(--font-ui-small);
1917
+ }
1918
+ .kplex-relationship-updating::before {
1919
+ content: "";
1920
+ position: absolute;
1921
+ top: 47px;
1922
+ width: 190px;
1923
+ height: 34px;
1924
+ border-radius: 17px;
1925
+ background: var(--background-secondary-alt);
1926
+ border: 1px solid var(--background-modifier-border);
1927
+ box-shadow: var(--shadow-s);
1928
+ z-index: -1;
1929
+ }
1930
+ .kplex-relationship-updating svg { animation: kplex-spin 1s linear infinite; }
1931
+ @keyframes kplex-spin { to { transform: rotate(360deg); } }
1932
+
1933
+ /* Companion sidecar controls live on the K-Plex edge. The actual sidecar is a native adjacent
1934
+ WorkspaceLeaf, so its divider/resizing remains entirely Obsidian-owned. */
1935
+ .kplex-sidecar-controls {
1936
+ position: absolute;
1937
+ z-index: 82;
1938
+ display: flex;
1939
+ gap: 5px;
1940
+ padding: 0;
1941
+ }
1942
+ .kplex-sidecar-controls.is-right { right: 4px; top: 50%; transform: translateY(-50%); flex-direction: column; }
1943
+ .kplex-sidecar-controls.is-left { left: 4px; top: 50%; transform: translateY(-50%); flex-direction: column; }
1944
+ .kplex-sidecar-controls.is-above { top: 4px; left: 50%; transform: translateX(-50%); }
1945
+ .kplex-sidecar-controls.is-below { bottom: 4px; left: 50%; transform: translateX(-50%); }
1946
+ .kplex-top-actions.is-compact { flex-wrap: nowrap; }
1947
+ .kplex-app.is-sidecar-condensed .kplex-brand strong { display: none; }
1948
+ .kplex-section-root-port {
1949
+ fill: var(--background-primary);
1950
+ stroke: color-mix(in srgb, var(--interactive-accent) 65%, var(--text-muted));
1951
+ stroke-width: 1.25;
1952
+ pointer-events: none;
1953
+ }
1954
+
1955
+ /* Streamlined add-related modal: one fuzzy note field, ontology field, and creation buttons. */
1956
+ .kplex-add-related-modal {
1957
+ width: min(680px, calc(100vw - 24px));
1958
+ max-width: min(680px, calc(100vw - 24px));
1959
+ }
1960
+ .kplex-add-related-form {
1961
+ display: grid;
1962
+ gap: 12px;
1963
+ min-width: 0;
1964
+ }
1965
+ .kplex-add-related-form .kplex-fuzzy-search {
1966
+ width: 100%;
1967
+ max-width: none;
1968
+ min-width: 0;
1969
+ flex: 1 1 auto;
1970
+ }
1971
+ .kplex-add-related-form .kplex-search,
1972
+ .kplex-import-modal .kplex-search,
1973
+ .kplex-folder-path-input .kplex-search {
1974
+ box-sizing: border-box;
1975
+ width: 100%;
1976
+ }
1977
+ .kplex-folder-path-input .kplex-search,
1978
+ .kplex-add-related-form .kplex-folder-path-input .kplex-search {
1979
+ width: 100%;
1980
+ box-sizing: border-box;
1981
+ }
1982
+ .kplex-add-related-form .kplex-search-icon,
1983
+ .kplex-import-modal .kplex-search-icon {
1984
+ top: 10px;
1985
+ color: var(--text-muted);
1986
+ }
1987
+ .kplex-add-related-form .kplex-fuzzy-inline-results {
1988
+ left: 0;
1989
+ right: 0;
1990
+ top: calc(100% + 4px);
1991
+ max-height: min(36vh, 300px);
1992
+ color: var(--text-normal);
1993
+ background: var(--background-primary);
1994
+ border-color: var(--background-modifier-border);
1995
+ box-shadow: var(--shadow-s);
1996
+ }
1997
+ .kplex-add-related-form .kplex-search-result {
1998
+ color: var(--text-normal);
1999
+ }
2000
+ .kplex-add-related-form .kplex-search-result small {
2001
+ color: var(--text-muted);
2002
+ }
2003
+ .kplex-add-related-form .kplex-search-result:hover,
2004
+ .kplex-add-related-form .kplex-search-result.is-selected {
2005
+ background: var(--background-modifier-hover);
2006
+ }
2007
+ .kplex-add-related-role-row {
2008
+ display: grid;
2009
+ grid-template-columns: repeat(4, minmax(0, 1fr));
2010
+ gap: 6px;
2011
+ }
2012
+ .kplex-add-related-role-row button {
2013
+ min-width: 0;
2014
+ height: 30px;
2015
+ padding: 0 8px;
2016
+ }
2017
+ .kplex-add-related-role-row button.is-active {
2018
+ color: var(--text-on-accent);
2019
+ background: var(--interactive-accent);
2020
+ }
2021
+ .kplex-add-related-control-row {
2022
+ display: flex;
2023
+ align-items: center;
2024
+ gap: 10px;
2025
+ min-width: 0;
2026
+ flex-wrap: wrap;
2027
+ }
2028
+ .kplex-add-related-control-row .kplex-add-related-ontology-search {
2029
+ flex: 1 1 280px;
2030
+ }
2031
+ .kplex-edit-selected-ontology { flex: 0 0 auto; }
2032
+ .kplex-edge-ontology-field { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
2033
+ .kplex-relationship-direction { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; padding: 8px 0; }
2034
+ .kplex-relationship-direction > .setting-item-description { flex: 1 1 240px; overflow-wrap: anywhere; }
2035
+ .kplex-relationship-direction > button { flex: 0 0 auto; }
2036
+ .kplex-add-related-footer {
2037
+ display: flex;
2038
+ justify-content: flex-end;
2039
+ align-items: center;
2040
+ flex-wrap: wrap;
2041
+ gap: 8px 16px;
2042
+ }
2043
+ .kplex-creation-completion-row {
2044
+ display: flex;
2045
+ flex-wrap: wrap;
2046
+ gap: var(--size-4-2);
2047
+ justify-content: flex-end;
2048
+ min-width: 0;
2049
+ padding: var(--size-4-3) 0;
2050
+ }
2051
+ .kplex-add-related-control-row .kplex-add-related-role-select {
2052
+ max-width: 100%;
2053
+ }
2054
+ .kplex-add-related-compose-row {
2055
+ display: grid;
2056
+ grid-template-columns: minmax(0, 1fr) auto;
2057
+ gap: 10px;
2058
+ align-items: start;
2059
+ min-width: 0;
2060
+ }
2061
+ .kplex-add-related-action-area {
2062
+ min-width: 0;
2063
+ display: flex;
2064
+ align-items: center;
2065
+ height: 38px;
2066
+ }
2067
+ .kplex-add-related-create-actions {
2068
+ display: flex;
2069
+ justify-content: flex-end;
2070
+ gap: 10px;
2071
+ height: 38px;
2072
+ }
2073
+ .kplex-add-related-type-button {
2074
+ display: inline-flex;
2075
+ align-items: center;
2076
+ justify-content: center;
2077
+ width: 42px;
2078
+ height: 38px;
2079
+ min-width: 42px;
2080
+ padding: 0;
2081
+ border: 1px solid var(--background-modifier-border);
2082
+ background: var(--background-primary);
2083
+ }
2084
+ /* Recovery is a separate message and action row; paths and translated buttons wrap safely. */
2085
+ .kplex-add-related-recovery {
2086
+ display: grid;
2087
+ gap: 10px;
2088
+ min-width: 0;
2089
+ padding: 12px;
2090
+ border: 1px solid var(--background-modifier-border);
2091
+ border-radius: var(--input-radius, 5px);
2092
+ background: var(--background-secondary);
2093
+ font-size: var(--font-ui-small);
2094
+ line-height: 1.45;
2095
+ overflow-wrap: anywhere;
2096
+ }
2097
+ .kplex-add-related-recovery-reason {
2098
+ color: var(--text-muted);
2099
+ }
2100
+ .kplex-add-related-recovery-actions {
2101
+ display: flex;
2102
+ flex-wrap: wrap;
2103
+ align-items: center;
2104
+ gap: 8px;
2105
+ }
2106
+ .kplex-add-related-recovery-actions button {
2107
+ max-width: 100%;
2108
+ height: auto;
2109
+ min-height: var(--input-height);
2110
+ white-space: normal;
2111
+ }
2112
+ .kplex-add-related-create-hint.is-error {
2113
+ color: var(--text-error);
2114
+ }
2115
+ .kplex-add-related-create-hint {
2116
+ margin-top: -4px;
2117
+ color: var(--text-muted);
2118
+ font-size: var(--font-ui-smaller);
2119
+ line-height: 1.35;
2120
+ }
2121
+ @media (max-width: 520px) {
2122
+ .kplex-add-related-role-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
2123
+ .kplex-add-related-control-row { gap: 7px; }
2124
+ .kplex-add-related-control-row .kplex-add-related-ontology-search { flex-basis: 210px; }
2125
+ .kplex-add-related-compose-row { gap: 7px; }
2126
+ .kplex-add-related-action-area { min-width: 83px; }
2127
+ .kplex-add-related-create-actions { gap: 6px; }
2128
+ .kplex-add-related-type-button { width: 36px; min-width: 36px; }
2129
+ .kplex-add-related-link-button { width: 83px; min-width: 83px; }
2130
+ }
2131
+ @media (max-width: 380px) {
2132
+ .kplex-add-related-modal {
2133
+ width: calc(100vw - 12px);
2134
+ max-width: calc(100vw - 12px);
2135
+ }
2136
+ .kplex-add-related-control-row .kplex-add-related-ontology-search { flex-basis: 150px; }
2137
+ .kplex-add-related-create-actions { gap: 4px; }
2138
+ .kplex-add-related-type-button { width: 33px; min-width: 33px; }
2139
+ }
2140
+
2141
+ /* Opt-in native modals fill the usable mobile WebView, including when its software keyboard
2142
+ changes VisualViewport without resizing the layout viewport. The shell supplies these values. */
2143
+ .is-mobile .modal.kplex-mobile-fullscreen-modal {
2144
+ position: fixed;
2145
+ left: var(--kplex-visible-left, 0px);
2146
+ top: var(--kplex-visible-top, 0px);
2147
+ width: var(--kplex-visible-width, 100%);
2148
+ max-width: var(--kplex-visible-width, 100%);
2149
+ height: var(--kplex-visible-height, 100%);
2150
+ max-height: var(--kplex-visible-height, 100%);
2151
+ margin: 0;
2152
+ border-radius: 0;
2153
+ overflow: hidden;
2154
+ }
2155
+ .is-mobile .modal.kplex-mobile-fullscreen-modal > .modal-content {
2156
+ flex: 1 1 auto;
2157
+ min-height: 0;
2158
+ overflow-y: auto;
2159
+ }
2160
+
2161
+ /* Shared draggable shell geometry. Native modals opt in on desktop; floating filter panels
2162
+ use the same owner-document mechanics across desktop, tablet and phone surfaces. */
2163
+ .kplex-draggable-dialog.is-positioned {
2164
+ position: fixed;
2165
+ left: var(--kplex-dialog-left);
2166
+ top: var(--kplex-dialog-top);
2167
+ right: auto;
2168
+ bottom: auto;
2169
+ margin: 0;
2170
+ }
2171
+ .kplex-draggable-dialog-handle {
2172
+ cursor: grab;
2173
+ user-select: none;
2174
+ touch-action: none;
2175
+ }
2176
+ .kplex-draggable-dialog-handle.is-dragging {
2177
+ cursor: grabbing;
2178
+ }
2179
+ .kplex-draggable-dialog-handle button,
2180
+ .kplex-draggable-dialog-handle input,
2181
+ .kplex-draggable-dialog-handle select,
2182
+ .kplex-draggable-dialog-handle textarea,
2183
+ .kplex-draggable-dialog-handle a,
2184
+ .kplex-draggable-dialog-handle [contenteditable="true"],
2185
+ .kplex-draggable-dialog-handle [role="button"],
2186
+ .kplex-draggable-dialog-handle [role="link"] {
2187
+ cursor: auto;
2188
+ user-select: auto;
2189
+ touch-action: auto;
2190
+ }
2191
+
2192
+ /* Folding K-Plex in companion-sidecar mode removes the Plex tab group from the split. The
2193
+ surviving native document group owns this small edge control so K-Plex is always recoverable. */
2194
+ .kplex-folded-workspace-group { display: none; }
2195
+ .kplex-fold-recovery-host { position: relative; }
2196
+ .kplex-sidecar-unfold-plex {
2197
+ position: absolute;
2198
+ z-index: 1000;
2199
+ }
2200
+ .kplex-sidecar-unfold-plex.is-left { left: 5px; top: 50%; transform: translateY(-50%); }
2201
+ .kplex-sidecar-unfold-plex.is-right { right: 5px; top: 50%; transform: translateY(-50%); }
2202
+ .kplex-sidecar-unfold-plex.is-top { top: 5px; left: 50%; transform: translateX(-50%); }
2203
+ .kplex-sidecar-unfold-plex.is-bottom { bottom: 5px; left: 50%; transform: translateX(-50%); }
2204
+
2205
+ /* Declarative settings can insert one wrapper around group items depending on the Obsidian build.
2206
+ Keep the resource shortcuts on one row in either DOM shape, wrapping only when space runs out. */
2207
+ .kplex-settings .kplex-resource-links > :is(div, section):not(.setting-item) {
2208
+ display: flex;
2209
+ align-items: center;
2210
+ justify-content: center;
2211
+ flex-wrap: wrap;
2212
+ width: 100%;
2213
+ }
2214
+
2215
+ /* Fuzzy results shown from modals are portalled to the viewport so they are never clipped by
2216
+ the modal's own bounds. Keep their theme-native appearance even though they no longer inherit
2217
+ from `.kplex-add-related-form`. */
2218
+ .kplex-fuzzy-floating-results {
2219
+ color: var(--text-normal);
2220
+ background: var(--background-primary);
2221
+ border-color: var(--background-modifier-border);
2222
+ box-shadow: var(--shadow-s);
2223
+ }
2224
+ .kplex-fuzzy-floating-results .kplex-search-result { color: var(--text-normal); }
2225
+ .kplex-fuzzy-floating-results .kplex-search-result small { color: var(--text-muted); }
2226
+ .kplex-fuzzy-floating-results .kplex-search-result:hover,
2227
+ .kplex-fuzzy-floating-results .kplex-search-result.is-selected { background: var(--background-modifier-hover); }
2228
+ .kplex-fuzzy-match {
2229
+ padding: 0;
2230
+ color: var(--text-accent);
2231
+ background: transparent;
2232
+ font: inherit;
2233
+ font-weight: 750;
2234
+ }
2235
+
2236
+ /* Relationship-create/link feedback. The animation intentionally changes only glow/brightness so
2237
+ it composes with FLIP positioning and never moves the thought itself. */
2238
+ @keyframes kplex-new-relationship-flair {
2239
+ 0%, 100% { box-shadow: var(--kplex-node-shadow, var(--shadow-s)); filter: brightness(1); }
2240
+ 12%, 38%, 64% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--interactive-accent) 82%, white), 0 0 34px color-mix(in srgb, var(--interactive-accent) 58%, transparent), var(--shadow-s); filter: brightness(1.28); }
2241
+ 25%, 51%, 77% { box-shadow: 0 0 0 1px color-mix(in srgb, var(--interactive-accent) 50%, transparent), 0 0 16px color-mix(in srgb, var(--interactive-accent) 34%, transparent), var(--shadow-s); filter: brightness(1.08); }
2242
+ }
2243
+ .kplex-thought.is-new-flair {
2244
+ z-index: 35;
2245
+ animation: kplex-new-relationship-flair 3.6s ease-in-out both;
2246
+ }
2247
+ @keyframes kplex-filter-flair {
2248
+ 0%, 100% { box-shadow: none; }
2249
+ 12%, 38%, 64% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--interactive-accent) 75%, transparent), 0 0 22px color-mix(in srgb, var(--interactive-accent) 48%, transparent); }
2250
+ 25%, 51%, 77% { box-shadow: 0 0 0 1px color-mix(in srgb, var(--interactive-accent) 45%, transparent); }
2251
+ }
2252
+ .kplex-zone-filter-control.is-new-flair {
2253
+ border-radius: 7px;
2254
+ animation: kplex-filter-flair 3.6s ease-in-out both;
2255
+ }
2256
+
2257
+ /* Rename-note modal: put the filename editor on its own row so it uses the full width. */
2258
+ .kplex-rename-note-modal .kplex-rename-note-name-setting {
2259
+ display: block;
2260
+ }
2261
+
2262
+ .kplex-rename-note-modal .kplex-rename-note-name-setting .setting-item-info {
2263
+ margin-bottom: 8px;
2264
+ }
2265
+
2266
+ .kplex-rename-note-modal .kplex-rename-note-name-setting .setting-item-control,
2267
+ .kplex-rename-note-modal .kplex-rename-note-name-setting input[type="text"] {
2268
+ width: 100%;
2269
+ }
2270
+
2271
+ /* Named Graph Lenses (checkpoint 2). Keep the control compact until opened; lens evaluation is
2272
+ still strictly local to the currently materialized Plex. */
2273
+ .kplex-filter > summary { position: relative; }
2274
+ .kplex-lens-count {
2275
+ position: absolute;
2276
+ right: -5px;
2277
+ top: -5px;
2278
+ min-width: 14px;
2279
+ height: 14px;
2280
+ padding: 0 3px;
2281
+ display: inline-flex;
2282
+ align-items: center;
2283
+ justify-content: center;
2284
+ border-radius: 999px;
2285
+ background: var(--interactive-accent);
2286
+ color: var(--text-on-accent);
2287
+ font-size: 9px;
2288
+ line-height: 1;
2289
+ font-weight: 700;
2290
+ }
2291
+ .kplex-filter-panel { width: min(390px, calc(100vw - 28px)); max-height: min(72vh, 720px); overflow: auto; }
2292
+ .kplex-filter-panel textarea { width: 100%; min-width: 0; resize: vertical; font: var(--font-ui-smaller) var(--font-monospace); }
2293
+ .kplex-predicate-rule-editor,
2294
+ .kplex-predicate-expression-field { display: grid; gap: 8px; min-width: 0; }
2295
+ .kplex-predicate-rule-editor label,
2296
+ .kplex-predicate-expression-field > label { display: grid; gap: 4px; min-width: 0; }
2297
+ .kplex-predicate-expression-field > label { color: var(--text-muted); font-size: var(--font-ui-smaller); }
2298
+ .kplex-predicate-expression-field textarea {
2299
+ box-sizing: border-box;
2300
+ width: 100%;
2301
+ min-width: 0;
2302
+ min-height: 6em;
2303
+ resize: vertical;
2304
+ font: var(--font-ui-smaller) var(--font-monospace);
2305
+ color: var(--text-normal);
2306
+ }
2307
+ .kplex-filter-section { display: grid; gap: 8px; }
2308
+ .kplex-filter-section + .kplex-filter-section,
2309
+ .kplex-view-controls + .kplex-filter-section { padding-top: 10px; border-top: 1px solid var(--background-modifier-border); }
2310
+ .kplex-view-controls { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; }
2311
+ .kplex-view-controls > .kplex-view-selector,
2312
+ .kplex-view-controls > .kplex-view-choice { flex: 1 1 150px; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px; align-items: end; }
2313
+ .kplex-view-controls > .kplex-view-choice { flex-basis: 240px; min-width: min(100%, 220px); grid-template-columns: minmax(0, 1fr) auto auto; }
2314
+ .kplex-view-controls label { min-width: 0; display: grid; gap: 6px; }
2315
+ .kplex-view-controls select { width: 100%; min-width: 0; }
2316
+ .kplex-view-controls .kplex-lens-help { flex-basis: 100%; grid-column: 1 / -1; }
2317
+ .kplex-filter-section-heading { color: var(--text-normal); font-size: 11px; font-weight: 700; letter-spacing: .025em; }
2318
+ .kplex-visibility-bulk { display: flex; flex-direction: column; gap: 6px; }
2319
+ .kplex-visibility-bulk-buttons { display: flex; flex-wrap: wrap; gap: 6px; }
2320
+ .kplex-visibility-bulk-buttons button { min-height: 32px; }
2321
+ .kplex-lens-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
2322
+ .kplex-lens-heading .kplex-icon-button { justify-self: auto; }
2323
+ .kplex-lens-empty,
2324
+ .kplex-lens-help { color: var(--text-muted); font-size: 10px; line-height: 1.35; }
2325
+ .kplex-lens-help code { font-size: 9px; }
2326
+ .kplex-lens-list { display: grid; gap: 4px; }
2327
+ .kplex-lens-row {
2328
+ display: grid;
2329
+ grid-template-columns: auto minmax(0, 1fr) auto auto auto;
2330
+ align-items: center;
2331
+ gap: 4px;
2332
+ padding: 4px 5px;
2333
+ border: 1px solid var(--background-modifier-border);
2334
+ border-radius: 6px;
2335
+ opacity: .72;
2336
+ }
2337
+ .kplex-lens-row.is-enabled { opacity: 1; background: var(--background-secondary); }
2338
+ .kplex-lens-row.has-error { border-color: var(--text-error); }
2339
+ .kplex-lens-toggle { display: flex; place-items: center; }
2340
+ .kplex-lens-toggle input { width: auto; margin: 0; }
2341
+ .kplex-lens-main {
2342
+ display: grid;
2343
+ gap: 1px;
2344
+ min-width: 0;
2345
+ padding: 2px 4px;
2346
+ text-align: left;
2347
+ background: transparent;
2348
+ border: 0;
2349
+ box-shadow: none;
2350
+ justify-self: stretch;
2351
+ }
2352
+ .kplex-lens-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-normal); font-size: 11px; font-weight: 600; }
2353
+ .kplex-lens-meta { color: var(--text-muted); font-size: 9px; text-transform: capitalize; }
2354
+ .kplex-lens-error-dot { color: var(--text-error); font-weight: 800; }
2355
+ .kplex-lens-editor { display: grid; gap: 8px; padding: 8px; border-radius: 7px; background: var(--background-secondary); }
2356
+ .kplex-lens-editor-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
2357
+ .kplex-lens-editor-error { color: var(--text-error); font-size: 10px; line-height: 1.35; }
2358
+ .kplex-lens-editor-actions { display: flex; justify-content: flex-end; gap: 6px; }
2359
+ .kplex-lens-editor-actions button { justify-self: auto; }
2360
+
2361
+ /* Graph Lens usability pass ---------------------------------------------------
2362
+ The filter panel is portalled to document.body so it can paint above adjacent Obsidian panes
2363
+ (including a K-Plex companion sidecar). The trigger remains in the K-Plex toolbar. */
2364
+ .kplex-filter { position: relative; flex: 0 0 auto; }
2365
+ .kplex-filter-trigger { position: relative; }
2366
+ .kplex-filter.is-active .kplex-filter-trigger {
2367
+ color: var(--text-normal);
2368
+ border-color: var(--background-modifier-border);
2369
+ background: var(--background-modifier-hover);
2370
+ }
2371
+ .kplex-filter.is-open .kplex-filter-trigger {
2372
+ box-shadow: 0 0 0 1px var(--background-modifier-border);
2373
+ }
2374
+ .kplex-filter-portal {
2375
+ /* Float above workspace panes while native color dialogs and suggestions retain their layers. */
2376
+ z-index: var(--layer-popover, 30);
2377
+ box-sizing: border-box;
2378
+ overflow: auto;
2379
+ overscroll-behavior: contain;
2380
+ color: var(--text-normal);
2381
+ background: var(--background-primary-alt, var(--background-primary));
2382
+ box-shadow: var(--shadow-s);
2383
+ }
2384
+ /* Bounded mobile disclosures share the canvas's local stack rather than the body's native
2385
+ popover stack. Keep every shared disclosure above scene tools and Sidecar edge controls. */
2386
+ .kplex-app[data-floating-layer-boundary] > :is(.kplex-filter-portal, .kplex-footprints-panel, .kplex-info-bubble) {
2387
+ z-index: 95;
2388
+ }
2389
+ /* Obsidian's styled tooltip is also portalled outside the filter panel. While this overlay is
2390
+ open, keep those tooltips one layer above it instead of letting the panel cover them. */
2391
+ body.kplex-filter-panel-open .tooltip { z-index: 100300; }
2392
+ .kplex-filter-portal button { justify-self: auto; }
2393
+ .kplex-lens-heading-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; max-width: 100%; }
2394
+ .kplex-lens-disable-all {
2395
+ min-height: 26px;
2396
+ padding: 0 8px;
2397
+ border-radius: 6px;
2398
+ color: var(--text-muted);
2399
+ font-size: 10px;
2400
+ }
2401
+ .kplex-lens-row {
2402
+ grid-template-columns: auto minmax(0, 1fr) auto auto auto;
2403
+ opacity: .62;
2404
+ }
2405
+ .kplex-lens-row.is-enabled { opacity: 1; }
2406
+ .kplex-lens-enable-button {
2407
+ display: inline-flex;
2408
+ align-items: center;
2409
+ justify-content: center;
2410
+ width: 30px;
2411
+ height: 30px;
2412
+ padding: 0;
2413
+ border: 1px solid var(--background-modifier-border);
2414
+ border-radius: 7px;
2415
+ color: var(--text-faint);
2416
+ background: var(--background-secondary);
2417
+ cursor: pointer;
2418
+ }
2419
+ .kplex-lens-enable-button.is-on {
2420
+ color: var(--text-accent);
2421
+ border-color: var(--interactive-accent);
2422
+ background: color-mix(in srgb, var(--interactive-accent) 12%, var(--background-secondary));
2423
+ }
2424
+ .kplex-lens-optional { color: var(--text-faint); font-size: 9px; font-weight: 500; }
2425
+ .kplex-lens-editor-mode {
2426
+ display: flex;
2427
+ gap: 4px;
2428
+ padding: 3px;
2429
+ border: 1px solid var(--background-modifier-border);
2430
+ border-radius: 7px;
2431
+ background: var(--background-primary);
2432
+ }
2433
+ .kplex-lens-editor-mode button {
2434
+ display: inline-flex;
2435
+ align-items: center;
2436
+ justify-content: center;
2437
+ gap: 5px;
2438
+ flex: 1 1 0;
2439
+ min-height: 28px;
2440
+ border: 0;
2441
+ border-radius: 5px;
2442
+ color: var(--text-muted);
2443
+ background: transparent;
2444
+ }
2445
+ .kplex-lens-editor-mode button.is-on {
2446
+ color: var(--text-normal);
2447
+ background: var(--background-modifier-hover);
2448
+ box-shadow: inset 0 0 0 1px var(--background-modifier-border);
2449
+ }
2450
+ .kplex-lens-simple-builder {
2451
+ display: grid;
2452
+ gap: 8px;
2453
+ padding: 8px;
2454
+ border: 1px solid var(--background-modifier-border);
2455
+ border-radius: 7px;
2456
+ background: var(--background-primary);
2457
+ }
2458
+ .kplex-lens-group-heading {
2459
+ display: flex;
2460
+ align-items: center;
2461
+ gap: 7px;
2462
+ color: var(--text-muted);
2463
+ font-size: 10px;
2464
+ font-weight: 600;
2465
+ }
2466
+ .kplex-lens-group-heading select { width: auto; min-width: 170px; }
2467
+ .kplex-lens-conditions { display: grid; gap: 7px; }
2468
+ .kplex-lens-condition {
2469
+ display: flex;
2470
+ align-items: center;
2471
+ gap: 5px;
2472
+ flex-wrap: wrap;
2473
+ padding: 6px;
2474
+ border: 1px solid var(--background-modifier-border);
2475
+ border-radius: 7px;
2476
+ background: var(--background-secondary);
2477
+ }
2478
+ .kplex-lens-where {
2479
+ flex: 0 0 auto;
2480
+ color: var(--text-muted);
2481
+ font-size: 10px;
2482
+ }
2483
+ .kplex-lens-condition-field { flex: 1 1 145px; min-width: 120px; width: auto; }
2484
+ .kplex-lens-condition-property { flex: 1 1 130px; min-width: 110px; width: auto; }
2485
+ .kplex-lens-condition-operator { flex: 0 1 125px; min-width: 105px; width: auto; }
2486
+ .kplex-lens-condition-value { flex: 1 1 140px; min-width: 120px; width: auto; }
2487
+ .kplex-lens-condition-remove { flex: 0 0 30px; }
2488
+ .kplex-lens-add-condition {
2489
+ display: inline-flex;
2490
+ align-items: center;
2491
+ gap: 5px;
2492
+ justify-self: start;
2493
+ min-height: 28px;
2494
+ }
2495
+ .kplex-lens-help strong { color: var(--text-normal); }
2496
+ .kplex-gate-count { white-space: nowrap; min-width: max-content; }
2497
+
2498
+ @media (max-width: 520px) {
2499
+ .kplex-lens-editor-row { grid-template-columns: 1fr; }
2500
+ .kplex-lens-condition-field,
2501
+ .kplex-lens-condition-property,
2502
+ .kplex-lens-condition-operator,
2503
+ .kplex-lens-condition-value { flex-basis: calc(50% - 16px); }
2504
+ }
2505
+
2506
+ /* Graph Lens presentation + styling (checkpoint 3). */
2507
+ .kplex-filter-heading-row {
2508
+ display: flex;
2509
+ align-items: center;
2510
+ justify-content: space-between;
2511
+ gap: 10px;
2512
+ }
2513
+ .kplex-filter-heading-row .kplex-filter-layout-toggle {
2514
+ display: inline-flex;
2515
+ align-items: center;
2516
+ gap: 7px;
2517
+ margin: 0;
2518
+ color: var(--text-muted);
2519
+ font-size: 10px;
2520
+ font-weight: 600;
2521
+ cursor: pointer;
2522
+ }
2523
+
2524
+ .kplex-filter-visibility-heading {
2525
+ display: flex;
2526
+ align-items: flex-start;
2527
+ justify-content: space-between;
2528
+ gap: 12px;
2529
+ }
2530
+ .kplex-filter-visibility-options {
2531
+ display: flex;
2532
+ flex-wrap: wrap;
2533
+ justify-content: flex-end;
2534
+ gap: 8px 14px;
2535
+ }
2536
+ .kplex-filter-visibility-options .kplex-filter-layout-toggle {
2537
+ display: inline-flex;
2538
+ align-items: center;
2539
+ gap: 7px;
2540
+ margin: 0;
2541
+ color: var(--text-muted);
2542
+ font-size: 10px;
2543
+ font-weight: 600;
2544
+ cursor: pointer;
2545
+ }
2546
+ .kplex-filter-layout-toggle input {
2547
+ position: absolute;
2548
+ width: 1px;
2549
+ height: 1px;
2550
+ opacity: 0;
2551
+ pointer-events: none;
2552
+ }
2553
+ .kplex-filter-switch {
2554
+ position: relative;
2555
+ width: 31px;
2556
+ height: 17px;
2557
+ border: 1px solid var(--background-modifier-border);
2558
+ border-radius: 999px;
2559
+ background: var(--background-modifier-form-field);
2560
+ transition: background 120ms ease, border-color 120ms ease;
2561
+ }
2562
+ .kplex-filter-switch::after {
2563
+ content: "";
2564
+ position: absolute;
2565
+ top: 2px;
2566
+ left: 2px;
2567
+ width: 11px;
2568
+ height: 11px;
2569
+ border-radius: 50%;
2570
+ background: var(--text-muted);
2571
+ transition: transform 120ms ease, background 120ms ease;
2572
+ }
2573
+ .kplex-filter-layout-toggle input:checked + .kplex-filter-switch {
2574
+ border-color: var(--interactive-accent);
2575
+ background: color-mix(in srgb, var(--interactive-accent) 35%, var(--background-modifier-form-field));
2576
+ }
2577
+ .kplex-filter-layout-toggle input:checked + .kplex-filter-switch::after {
2578
+ transform: translateX(14px);
2579
+ background: var(--text-on-accent, white);
2580
+ }
2581
+ .kplex-filter-layout-toggle:focus-within .kplex-filter-switch {
2582
+ box-shadow: 0 0 0 2px color-mix(in srgb, var(--interactive-accent) 28%, transparent);
2583
+ }
2584
+ .kplex-lens-style-editor {
2585
+ display: grid;
2586
+ gap: 8px;
2587
+ padding: 8px;
2588
+ border: 1px solid var(--background-modifier-border);
2589
+ border-radius: 7px;
2590
+ background: var(--background-primary);
2591
+ }
2592
+ .kplex-lens-style-heading {
2593
+ color: var(--text-normal);
2594
+ font-size: 10px;
2595
+ font-weight: 700;
2596
+ }
2597
+ .kplex-lens-style-grid {
2598
+ display: grid;
2599
+ grid-template-columns: repeat(2, minmax(0, 1fr));
2600
+ gap: 7px;
2601
+ }
2602
+ .kplex-lens-style-grid label {
2603
+ display: grid;
2604
+ grid-template-columns: minmax(0, 1fr) auto;
2605
+ align-items: center;
2606
+ gap: 7px;
2607
+ min-width: 0;
2608
+ }
2609
+ .kplex-lens-style-grid input[type="color"] {
2610
+ width: 42px;
2611
+ min-width: 42px;
2612
+ height: 28px;
2613
+ padding: 2px;
2614
+ border-radius: 6px;
2615
+ }
2616
+ .kplex-lens-style-grid input[type="number"],
2617
+ .kplex-lens-style-grid select {
2618
+ width: 104px;
2619
+ min-width: 86px;
2620
+ }
2621
+ .kplex-lens-style-grid .kplex-lens-style-check {
2622
+ display: flex;
2623
+ grid-column: 1 / -1;
2624
+ align-items: center;
2625
+ justify-content: flex-start;
2626
+ gap: 7px;
2627
+ }
2628
+ .kplex-lens-style-check input { width: auto; margin: 0; }
2629
+ @media (max-width: 520px) {
2630
+ .kplex-lens-style-grid { grid-template-columns: 1fr; }
2631
+ }
2632
+
2633
+ /* Edge imagery is resolved only for the currently visible Plex. The preview never changes the
2634
+ layout box: visual recognition improves without making dense graphs grow around images. */
2635
+ .kplex-thought.has-node-visual .kplex-thought-label {
2636
+ overflow: visible;
2637
+ gap: 5px;
2638
+ }
2639
+ .kplex-node-visual {
2640
+ position: relative;
2641
+ z-index: 1;
2642
+ display: inline-flex;
2643
+ align-items: center;
2644
+ justify-content: center;
2645
+ flex: 0 0 auto;
2646
+ width: 18px;
2647
+ height: 18px;
2648
+ border-radius: 4px;
2649
+ overflow: visible;
2650
+ }
2651
+ .kplex-role-center .kplex-node-visual { width: 24px; height: 24px; }
2652
+ .kplex-node-visual img {
2653
+ display: block;
2654
+ width: 100%;
2655
+ height: 100%;
2656
+ min-width: 0;
2657
+ min-height: 0;
2658
+ max-width: 100%;
2659
+ max-height: 100%;
2660
+ border-radius: inherit;
2661
+ object-fit: contain;
2662
+ background: var(--background-secondary);
2663
+ box-shadow: 0 0 0 1px color-mix(in srgb, var(--text-muted) 28%, transparent);
2664
+ transition: transform .12s ease, box-shadow .12s ease;
2665
+ transform-origin: center;
2666
+ }
2667
+ .kplex-node-visual.is-replace { width: 26px; height: 22px; }
2668
+ .kplex-role-center .kplex-node-visual.is-replace { width: 38px; height: 30px; }
2669
+ .kplex-node-visual.is-replace img { object-fit: contain; }
2670
+ .kplex-node-visual.kplex-local-video-visual { width: 13px; height: 13px; margin-inline-end: .5rem; }
2671
+ .kplex-role-center .kplex-node-visual.kplex-local-video-visual { width: 18px; height: 18px; }
2672
+ .kplex-local-video-visual > .kplex-node-icon { margin-right: 0; }
2673
+ .kplex-local-video-slot, .kplex-local-video-slot img { position: absolute; inset: 0; }
2674
+ /* The label row centers the line box. Lower the frame slightly to align with the title's ink. */
2675
+ .kplex-local-video-slot { transform: translateY(.05em); }
2676
+ .kplex-thought-label > .kplex-node-visual:last-child { overflow: visible; text-overflow: clip; }
2677
+ @media (hover: hover) and (pointer: fine) {
2678
+ .kplex-thought.has-node-visual:hover { z-index: 40; }
2679
+ .kplex-node-visual:hover { z-index: 70; }
2680
+ .kplex-node-visual:hover img {
2681
+ transform: scale(7);
2682
+ box-shadow: 0 0 0 1px var(--background-modifier-border);
2683
+ }
2684
+ }
2685
+
2686
+ /* Connection details is optimized for skimming provenance occurrences and hands actual editing
2687
+ off to the native Markdown source view. */
2688
+ .kplex-edge-properties-modal { width: min(860px, calc(100vw - 36px)); max-width: min(860px, calc(100vw - 36px)); }
2689
+ .kplex-edge-connection-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: var(--size-4-2); margin-top: var(--size-4-2); }
2690
+ .kplex-edge-ontology-row {
2691
+ display: flex;
2692
+ align-items: center;
2693
+ justify-content: space-between;
2694
+ gap: 14px;
2695
+ margin: 12px 0 16px;
2696
+ padding: 10px 12px;
2697
+ border: 1px solid var(--background-modifier-border);
2698
+ border-radius: var(--radius-s);
2699
+ background: var(--background-secondary);
2700
+ }
2701
+ .kplex-edge-ontology-copy { min-width: 0; display: grid; gap: 2px; }
2702
+ .kplex-edge-ontology-value { color: var(--text-muted); overflow-wrap: anywhere; }
2703
+ .kplex-edge-ontology-conflict { margin-top: var(--size-4-2); }
2704
+ .kplex-relation-additional { display: flex; flex-wrap: wrap; align-items: center; gap: var(--size-4-2); margin-block: var(--size-4-4); }
2705
+ .kplex-relation-additional[hidden] { display: none; }
2706
+ .kplex-relation-additional .setting-item-description { flex: 1 1 240px; min-width: 0; }
2707
+ .kplex-relation-additional button { margin-inline-start: auto; }
2708
+ .kplex-edge-why { margin-bottom: 14px; }
2709
+ .kplex-edge-source-intro { margin: -3px 0 10px; color: var(--text-muted); line-height: 1.4; font-size: var(--font-ui-small); }
2710
+ .kplex-edge-source-list { display: grid; gap: 9px; }
2711
+ .kplex-edge-source-card {
2712
+ min-width: 0;
2713
+ padding: 10px;
2714
+ border: 1px solid var(--background-modifier-border);
2715
+ border-radius: var(--radius-s);
2716
+ background: var(--background-secondary);
2717
+ }
2718
+ .kplex-edge-source-card.is-overridden { opacity: .74; }
2719
+ .kplex-edge-source-header { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 9px; }
2720
+ .kplex-edge-source-title { min-width: 0; overflow-wrap: anywhere; }
2721
+ .kplex-edge-source-title span { color: var(--text-muted); font-size: var(--font-ui-smaller); }
2722
+ .kplex-edge-source-status { display: flex; flex: 0 0 auto; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 5px; max-width: 55%; }
2723
+ .kplex-edge-source-evaluations { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
2724
+ .kplex-edge-source-evaluation {
2725
+ padding: 2px 6px;
2726
+ border: 1px solid var(--background-modifier-border);
2727
+ border-radius: 999px;
2728
+ background: var(--background-primary-alt);
2729
+ color: var(--text-muted);
2730
+ font-size: 9px;
2731
+ font-weight: 650;
2732
+ white-space: nowrap;
2733
+ }
2734
+ .kplex-edge-source-evaluation.is-active {
2735
+ color: var(--text-normal);
2736
+ border-color: color-mix(in srgb, var(--interactive-accent) 40%, var(--background-modifier-border));
2737
+ }
2738
+ .kplex-edge-source-evaluation.is-overridden { opacity: .72; }
2739
+ .kplex-edge-source-state { flex: 0 0 auto; padding: 2px 5px; border-radius: 4px; font-size: 9px; font-weight: 700; letter-spacing: .07em; }
2740
+ .kplex-edge-source-state.is-used { color: var(--text-success); background: color-mix(in srgb, var(--text-success) 12%, transparent); }
2741
+ .kplex-edge-source-state.is-overridden { color: var(--text-muted); background: var(--background-modifier-hover); }
2742
+ .kplex-edge-source-text {
2743
+ max-height: 180px;
2744
+ margin: 8px 0;
2745
+ padding: 8px;
2746
+ overflow: auto;
2747
+ white-space: pre-wrap;
2748
+ overflow-wrap: anywhere;
2749
+ border-radius: var(--radius-s);
2750
+ background: var(--background-primary);
2751
+ border: 1px solid var(--background-modifier-border);
2752
+ font-size: var(--font-ui-smaller);
2753
+ }
2754
+ .kplex-edge-source-reason { margin: 5px 0; color: var(--text-muted); font-size: var(--font-ui-smaller); }
2755
+ .kplex-edge-source-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--size-4-2); }
2756
+ .kplex-edge-source-header > .kplex-edge-source-actions { flex-basis: 100%; }
2757
+ .kplex-edge-source-removal { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--size-4-2); margin-top: var(--size-4-2); }
2758
+ .kplex-edge-source-removal-coordinate { flex: 1 1 220px; min-width: 0; color: var(--text-muted); font-size: var(--font-ui-small); overflow-wrap: anywhere; }
2759
+ .kplex-edge-declaration-actions { display: flex; gap: var(--size-4-2); margin-inline-start: auto; }
2760
+ .kplex-edge-source-removal [data-kplex-remove-field] { color: var(--text-error); }
2761
+ .kplex-edge-removal-status { padding: var(--size-4-2) 0; color: var(--text-muted); }
2762
+ .kplex-edge-source-action { display: inline-flex; align-items: center; gap: 6px; min-height: 28px; padding: 3px 8px; font-size: var(--font-ui-smaller); }
2763
+ .kplex-edge-source-action svg { width: 14px; height: 14px; }
2764
+
2765
+ .kplex-edge-hover-tooltip {
2766
+ position: absolute;
2767
+ z-index: 95;
2768
+ max-width: min(360px, calc(100% - 24px));
2769
+ padding: 7px 9px;
2770
+ border: 1px solid var(--background-modifier-border-hover);
2771
+ border-radius: var(--radius-s);
2772
+ background: var(--background-primary);
2773
+ color: var(--text-normal);
2774
+ box-shadow: var(--shadow-s);
2775
+ font-size: var(--font-ui-smaller);
2776
+ line-height: 1.35;
2777
+ white-space: pre-line;
2778
+ pointer-events: none;
2779
+ }
2780
+
2781
+ /* The companion control remains on the remembered side even when the native sidecar is closed. */
2782
+
2783
+ /* Searchable managers keep large style/ontology collections compact and native-looking. */
2784
+ .modal.kplex-style-manager-modal {
2785
+ width: min(760px, calc(100vw - 48px));
2786
+ max-width: calc(100vw - 24px);
2787
+ box-sizing: border-box;
2788
+ }
2789
+ .modal.kplex-style-manager-modal .modal-content {
2790
+ min-width: 0;
2791
+ max-width: 100%;
2792
+ overflow-x: clip;
2793
+ }
2794
+ .kplex-style-manager {
2795
+ width: 100%;
2796
+ min-width: 0;
2797
+ max-width: 100%;
2798
+ box-sizing: border-box;
2799
+ overflow-x: clip;
2800
+ }
2801
+ .kplex-style-manager > p {
2802
+ max-width: 64ch;
2803
+ margin: 0 0 12px;
2804
+ color: var(--text-muted);
2805
+ line-height: 1.45;
2806
+ }
2807
+ .kplex-style-manager-controls {
2808
+ display: grid;
2809
+ grid-template-columns: minmax(0, 1fr) auto auto;
2810
+ align-items: center;
2811
+ gap: 8px;
2812
+ width: 100%;
2813
+ min-width: 0;
2814
+ margin: 12px 0 8px;
2815
+ }
2816
+ .kplex-style-manager-search {
2817
+ min-width: 0;
2818
+ max-width: 100%;
2819
+ }
2820
+ .kplex-style-manager-search input {
2821
+ width: 100%;
2822
+ min-width: 0;
2823
+ box-sizing: border-box;
2824
+ }
2825
+ .kplex-style-manager-controls select,
2826
+ .kplex-style-manager-controls button {
2827
+ min-width: 0;
2828
+ max-width: 220px;
2829
+ }
2830
+ .kplex-style-manager-controls button {
2831
+ display: inline-flex;
2832
+ align-items: center;
2833
+ justify-content: center;
2834
+ gap: 6px;
2835
+ }
2836
+ .kplex-style-manager-status {
2837
+ margin: 8px 0;
2838
+ color: var(--text-muted);
2839
+ font-size: var(--font-ui-smaller);
2840
+ }
2841
+ .kplex-style-manager-list {
2842
+ display: grid;
2843
+ gap: 2px;
2844
+ width: 100%;
2845
+ min-width: 0;
2846
+ max-width: 100%;
2847
+ box-sizing: border-box;
2848
+ padding: 4px;
2849
+ border: 1px solid var(--background-modifier-border);
2850
+ border-radius: 10px;
2851
+ background: var(--background-secondary);
2852
+ overflow: clip;
2853
+ }
2854
+ .kplex-style-manager-row {
2855
+ width: 100%;
2856
+ min-width: 0;
2857
+ max-width: 100%;
2858
+ box-sizing: border-box;
2859
+ display: flex;
2860
+ align-items: center;
2861
+ gap: 10px;
2862
+ padding: 9px 10px;
2863
+ color: var(--text-normal);
2864
+ text-align: left;
2865
+ border: 0;
2866
+ border-radius: 7px;
2867
+ background: transparent;
2868
+ box-shadow: none;
2869
+ cursor: pointer;
2870
+ overflow: hidden;
2871
+ }
2872
+ .kplex-style-manager-row:hover,
2873
+ .kplex-style-manager-row:focus-visible {
2874
+ background: var(--background-modifier-hover);
2875
+ }
2876
+ .kplex-style-manager-row > .kplex-lucide { order: 3; flex: 0 0 auto; color: var(--text-muted); }
2877
+ button.kplex-style-manager-row { height: fit-content; }
2878
+ .kplex-style-manager-copy { flex: 1 1 auto; min-width: 0; max-width: 100%; display: grid; gap: 2px; overflow: hidden; }
2879
+ .kplex-style-manager-heading { min-width: 0; max-width: 100%; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; overflow: hidden; }
2880
+ .kplex-style-manager-name { min-width: 0; max-width: 100%; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
2881
+ .kplex-style-manager-summary { min-width: 0; max-width: 100%; color: var(--text-muted); font-size: var(--font-ui-smaller); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
2882
+ /* Ontology identities and both pair endpoints must remain readable at narrow native modal widths. */
2883
+ .kplex-ontology-manager .kplex-style-manager-name,
2884
+ .kplex-ontology-manager .kplex-style-manager-summary {
2885
+ white-space: normal;
2886
+ overflow-wrap: break-word;
2887
+ }
2888
+ .kplex-style-manager-badges { min-width: 0; display: inline-flex; gap: 4px; flex-wrap: wrap; }
2889
+ .kplex-style-manager-badge {
2890
+ padding: 1px 5px;
2891
+ color: var(--text-muted);
2892
+ border: 1px solid var(--background-modifier-border);
2893
+ border-radius: 999px;
2894
+ font-size: 10px;
2895
+ font-weight: 500;
2896
+ }
2897
+ .kplex-style-manager-line-swatch {
2898
+ flex: 0 0 28px;
2899
+ height: 0;
2900
+ border-top: 3px solid var(--kplex-style-swatch, var(--text-muted));
2901
+ border-radius: 3px;
2902
+ }
2903
+ .kplex-style-manager-node-swatch {
2904
+ flex: 0 0 28px;
2905
+ width: 28px;
2906
+ height: 22px;
2907
+ border: 2px solid var(--kplex-style-node-border, var(--background-modifier-border));
2908
+ border-radius: 6px;
2909
+ background: var(--kplex-style-node-bg, var(--background-secondary-alt));
2910
+ }
2911
+ .kplex-style-manager-property-icon {
2912
+ display: inline-flex;
2913
+ flex: 0 0 28px;
2914
+ align-items: center;
2915
+ justify-content: center;
2916
+ color: var(--text-muted);
2917
+ }
2918
+ .kplex-style-manager-empty,
2919
+ .kplex-style-manager-limit { padding: 12px; color: var(--text-muted); }
2920
+ .kplex-style-manager-empty p { margin: 0 0 10px; }
2921
+ .kplex-style-manager-more {
2922
+ justify-self: center;
2923
+ margin: 6px 0 2px;
2924
+ }
2925
+
2926
+ @media (max-width: 680px) {
2927
+ .modal.kplex-style-manager-modal { width: calc(100vw - 20px); max-width: calc(100vw - 20px); }
2928
+ .kplex-style-manager-controls { grid-template-columns: minmax(0, 1fr); }
2929
+ .kplex-style-manager-controls select,
2930
+ .kplex-style-manager-controls button { width: 100%; max-width: none; }
2931
+ .kplex-style-manager-summary { white-space: normal; }
2932
+ }
2933
+ .kplex-style-manager-line-swatch.is-dashed { border-top-style: dashed; }
2934
+ .kplex-style-manager-line-swatch.is-dotted { border-top-style: dotted; }
2935
+
2936
+ /* Briefly identify the entire note leaf currently linked/pinned to K-Plex. The warning token is
2937
+ supplied by the active Obsidian theme; no inline style or hard-coded alert color is required. */
2938
+ .kplex-linked-leaf-alert {
2939
+ border: 3px;
2940
+ border-color: var(--text-warning, var(--interactive-accent));
2941
+ border-style: solid;
2942
+ }
2943
+
2944
+ /* Folder-child creation gives the note name its own full-width row. The native Setting layout is
2945
+ optimized for short controls and otherwise leaves a long filename input cramped into the right
2946
+ column on wide dialogs. */
2947
+ .kplex-create-folder-note-modal .kplex-create-folder-note-name-setting {
2948
+ display: block;
2949
+ }
2950
+ .kplex-create-folder-note-modal .kplex-create-folder-note-name-setting .setting-item-info {
2951
+ margin-bottom: 8px;
2952
+ }
2953
+ .kplex-create-folder-note-modal .kplex-create-folder-note-name-setting .setting-item-control,
2954
+ .kplex-create-folder-note-modal .kplex-create-folder-note-name-setting input[type="text"] {
2955
+ width: 100%;
2956
+ max-width: none;
2957
+ }
2958
+
2959
+ /* Scoped control hints own delay/placement; native warm hints must not bypass that owner. */
2960
+ [data-kplex-tooltip-scope] button[aria-label],
2961
+ [data-kplex-tooltip-scope] input[aria-label],
2962
+ [data-kplex-tooltip-scope] [role="button"][aria-label],
2963
+ [data-kplex-tooltip-scope] [role="group"][aria-label],
2964
+ [data-kplex-tooltip-scope] [data-kplex-control-tooltip],
2965
+ [data-kplex-tooltip-scope] [data-kplex-long-press-tooltip] {
2966
+ --no-tooltip: true;
2967
+ }
2968
+ .tooltip.kplex-control-tooltip {
2969
+ position: fixed;
2970
+ z-index: 100300;
2971
+ max-width: min(300px, calc(100vw - 16px));
2972
+ transform: none;
2973
+ animation: none;
2974
+ pointer-events: none;
2975
+ white-space: normal;
2976
+ }
2977
+ .tooltip.kplex-control-tooltip.is-measuring { visibility: hidden; }
2978
+ .tooltip.kplex-control-tooltip.is-multiline { white-space: pre-line; text-align: left; }
2979
+
2980
+ /* Consolidated filter / lens controls ------------------------------------- */
2981
+ .kplex-filter-visibility-grid {
2982
+ display: grid;
2983
+ grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr));
2984
+ gap: 6px 12px;
2985
+ /* Clip first-column separators while leaving space for the switch focus ring. */
2986
+ overflow: hidden;
2987
+ padding: 2px;
2988
+ margin: -2px;
2989
+ }
2990
+ .kplex-filter-visibility-grid .kplex-filter-layout-toggle {
2991
+ position: relative;
2992
+ display: flex;
2993
+ align-items: center;
2994
+ justify-content: space-between;
2995
+ gap: 8px;
2996
+ min-width: 0;
2997
+ margin: 0;
2998
+ color: var(--text-muted);
2999
+ font-size: 10px;
3000
+ font-weight: 600;
3001
+ cursor: pointer;
3002
+ }
3003
+ .kplex-filter-visibility-grid .kplex-filter-layout-toggle::before {
3004
+ content: "";
3005
+ position: absolute;
3006
+ left: -6px;
3007
+ top: -3px;
3008
+ bottom: -3px;
3009
+ border-left: 1px solid var(--background-modifier-border);
3010
+ pointer-events: none;
3011
+ }
3012
+ .kplex-filter-visibility-grid .kplex-filter-layout-toggle > span:first-child {
3013
+ overflow: hidden;
3014
+ text-overflow: ellipsis;
3015
+ white-space: nowrap;
3016
+ }
3017
+ .kplex-quick-lens-row {
3018
+ display: grid;
3019
+ grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr));
3020
+ gap: 7px;
3021
+ align-items: end;
3022
+ }
3023
+ .kplex-filter-clear {
3024
+ justify-self: start;
3025
+ }
3026
+
3027
+ /* Authored names and aliases use shared full-width fields; focus never shrinks another draft. */
3028
+ .kplex-create-name-pair { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; min-width: 0; width: 100%; }
3029
+ .kplex-creation-properties,
3030
+ .kplex-creation-property-section { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--kplex-form-gap, 16px); min-width: 0; }
3031
+ .kplex-creation-property-section > hr { box-sizing: border-box; width: 100%; margin: 0; }
3032
+ .kplex-create-name-pair .kplex-add-related-note-search { width: 100%; min-width: 0; max-width: none; }
3033
+ .kplex-create-alias-input { width: 100%; min-width: 0; }
3034
+
3035
+ @media (max-width: 520px) {
3036
+ .kplex-filter-visibility-grid { grid-template-columns: 1fr; }
3037
+ .kplex-create-name-pair { gap: 6px; }
3038
+ .kplex-create-alias-input { min-width: 62px; }
3039
+ }
3040
+
3041
+ /* Add-related modal: direction shares the ontology row and the filename field does not
3042
+ spend horizontal space on a decorative search glyph. */
3043
+ .kplex-add-related-title {
3044
+ display: flex;
3045
+ align-items: center;
3046
+ gap: 8px;
3047
+ min-width: 0;
3048
+ }
3049
+ .kplex-add-related-role-select {
3050
+ width: auto;
3051
+ min-width: 128px;
3052
+ max-width: min(46vw, 220px);
3053
+ flex: 0 1 auto;
3054
+ }
3055
+ .kplex-create-name-pair .kplex-add-related-note-search .kplex-search-icon {
3056
+ display: none;
3057
+ }
3058
+
3059
+ /* Keep the section outline control square; coarse pointers get a slightly larger glyph. */
3060
+ .kplex-section-fold-handle {
3061
+ inline-size: 10px;
3062
+ block-size: 10px;
3063
+ min-inline-size: 10px;
3064
+ min-block-size: 10px;
3065
+ max-inline-size: 10px;
3066
+ max-block-size: 10px;
3067
+ flex: 0 0 10px;
3068
+ overflow: hidden;
3069
+ font-size: 0;
3070
+ -webkit-touch-callout: none;
3071
+ }
3072
+ .kplex-thought,
3073
+ .kplex-thought * {
3074
+ -webkit-touch-callout: none;
3075
+ }
3076
+ @media (pointer: coarse) {
3077
+ .kplex-section-fold-handle {
3078
+ width: 14px;
3079
+ height: 14px;
3080
+ min-width: 14px;
3081
+ min-height: 14px;
3082
+ max-width: 14px;
3083
+ max-height: 14px;
3084
+ inline-size: 14px;
3085
+ block-size: 14px;
3086
+ min-inline-size: 14px;
3087
+ min-block-size: 14px;
3088
+ max-inline-size: 14px;
3089
+ max-block-size: 14px;
3090
+ flex-basis: 14px;
3091
+ bottom: -8px;
3092
+ }
3093
+ .kplex-section-fold-handle.is-expanded::after,
3094
+ .kplex-section-fold-handle.is-folded::before {
3095
+ left: 3px;
3096
+ right: 3px;
3097
+ top: 5px;
3098
+ }
3099
+ .kplex-section-fold-handle.is-folded::after {
3100
+ top: 3px;
3101
+ bottom: 3px;
3102
+ left: 5px;
3103
+ }
3104
+ }
3105
+
3106
+ /* Obsidian Mobile/iPad can impose large native button metrics inside modals. Keep the
3107
+ relationship actions compact and make their Lucide glyphs explicit so the buttons do not
3108
+ turn into large empty tap targets. */
3109
+ .kplex-relation-modal .kplex-relation-actions {
3110
+ flex: 0 0 auto;
3111
+ min-height: 0;
3112
+ height: auto;
3113
+ padding-bottom: 0;
3114
+ }
3115
+ .kplex-relation-modal .kplex-relation-actions button {
3116
+ box-sizing: border-box;
3117
+ appearance: none;
3118
+ -webkit-appearance: none;
3119
+ flex: 0 0 34px;
3120
+ width: 34px;
3121
+ min-width: 34px;
3122
+ max-width: 34px;
3123
+ height: 30px;
3124
+ min-height: 30px;
3125
+ max-height: 30px;
3126
+ padding: 0;
3127
+ line-height: 1;
3128
+ }
3129
+ .kplex-relation-modal .kplex-relation-actions .kplex-lucide,
3130
+ .kplex-relation-modal .kplex-relation-actions svg {
3131
+ display: block;
3132
+ width: 17px;
3133
+ height: 17px;
3134
+ min-width: 17px;
3135
+ min-height: 17px;
3136
+ stroke: currentColor;
3137
+ color: inherit;
3138
+ }
3139
+ @media (pointer: coarse) {
3140
+ .kplex-relation-modal .kplex-relation-actions {
3141
+ position: static;
3142
+ margin-top: 10px;
3143
+ padding-top: 0;
3144
+ padding-bottom: 0;
3145
+ align-items: center;
3146
+ }
3147
+ }
3148
+
3149
+ /* Central-node editor: native Obsidian view hosted above the transformed graph camera. */
3150
+ .kplex-central-editor-overlay {
3151
+ position: absolute;
3152
+ z-index: 26;
3153
+ box-sizing: border-box;
3154
+ padding: 6px;
3155
+ overflow: visible;
3156
+ border: 1px solid var(--background-modifier-border-hover);
3157
+ border-radius: 18px;
3158
+ background: var(--background-primary);
3159
+ color: var(--text-normal);
3160
+ box-shadow: 0 0 0 1px var(--background-modifier-border), 0 10px 34px var(--background-modifier-box-shadow);
3161
+ }
3162
+ .kplex-central-editor-overlay.is-maximized {
3163
+ box-shadow: 0 0 0 1px var(--background-modifier-border-hover), 0 12px 42px var(--background-modifier-box-shadow);
3164
+ }
3165
+ .kplex-central-editor-overlay.is-area-clipped {
3166
+ background: transparent;
3167
+ border-color: transparent;
3168
+ box-shadow: none;
3169
+ pointer-events: none;
3170
+ }
3171
+ .kplex-central-editor-overlay.is-area-clipped .kplex-central-editor-document,
3172
+ .kplex-central-editor-overlay.is-area-clipped .kplex-central-editor-toolbar { pointer-events: auto; }
3173
+ /* Only the document/frame follow the area aperture; native recovery controls stay outside it. */
3174
+ .kplex-central-editor-overlay.is-area-clipped::before {
3175
+ content: "";
3176
+ position: absolute;
3177
+ inset: -1px;
3178
+ border: 1px solid var(--background-modifier-border-hover);
3179
+ border-radius: inherit;
3180
+ background: var(--background-primary);
3181
+ clip: var(--kplex-editor-frame-clip, auto);
3182
+ pointer-events: none;
3183
+ }
3184
+ .kplex-central-editor-placeholder {
3185
+ width: 100%;
3186
+ height: 100%;
3187
+ pointer-events: none;
3188
+ }
3189
+ .kplex-thought.has-embedded-content {
3190
+ padding: 6px;
3191
+ overflow: visible;
3192
+ cursor: default;
3193
+ background: var(--background-primary);
3194
+ color: var(--text-normal);
3195
+ border-color: var(--background-modifier-border-hover);
3196
+ box-shadow: 0 0 0 1px var(--background-modifier-border), 0 10px 34px var(--background-modifier-box-shadow);
3197
+ }
3198
+ .kplex-thought.has-embedded-content:hover,
3199
+ .kplex-thought.has-embedded-content.is-highlighted {
3200
+ filter: none;
3201
+ }
3202
+ .kplex-thought-embedded-content {
3203
+ position: relative;
3204
+ width: 100%;
3205
+ height: 100%;
3206
+ min-width: 0;
3207
+ min-height: 0;
3208
+ overflow: hidden;
3209
+ border-radius: 12px;
3210
+ background: var(--background-primary);
3211
+ color: var(--text-normal);
3212
+ text-align: start;
3213
+ line-height: normal;
3214
+ user-select: text;
3215
+ cursor: text;
3216
+ touch-action: pan-x pan-y;
3217
+ }
3218
+ .kplex-central-editor-content,
3219
+ .kplex-central-editor-document,
3220
+ .kplex-central-editor-leaf-host,
3221
+ .kplex-embedded-workspace-root {
3222
+ width: 100%;
3223
+ height: 100%;
3224
+ min-width: 0;
3225
+ min-height: 0;
3226
+ }
3227
+ .kplex-central-editor-content {
3228
+ position: relative;
3229
+ overflow: visible;
3230
+ border-radius: inherit;
3231
+ color: var(--text-normal);
3232
+ isolation: isolate;
3233
+ touch-action: pan-x pan-y;
3234
+ }
3235
+ .kplex-central-editor-document {
3236
+ position: absolute;
3237
+ inset: 0;
3238
+ border-radius: inherit;
3239
+ background: var(--background-primary);
3240
+ clip: var(--kplex-editor-body-clip, auto);
3241
+ }
3242
+ .kplex-central-editor-content.is-edit-mode {
3243
+ cursor: default;
3244
+ }
3245
+ .kplex-central-editor-leaf-host,
3246
+ .kplex-embedded-workspace-root {
3247
+ position: absolute;
3248
+ inset: 0;
3249
+ overflow: hidden;
3250
+ border-radius: 12px;
3251
+ background: var(--background-primary);
3252
+ }
3253
+ /* Only Markdown opts into camera scaling; canvas hosts and editor controls remain untransformed. */
3254
+ .kplex-central-editor-content.is-markdown-zoom-scaled > .kplex-central-editor-document > .kplex-central-editor-leaf-host {
3255
+ width: calc(100% / var(--kplex-editor-camera-scale, 1));
3256
+ height: calc(100% / var(--kplex-editor-camera-scale, 1));
3257
+ transform: scale(var(--kplex-editor-camera-scale, 1));
3258
+ transform-origin: top left;
3259
+ }
3260
+ .kplex-embedded-workspace-split {
3261
+ display: flex;
3262
+ flex-direction: column;
3263
+ }
3264
+ .kplex-central-editor-overlay.is-native-view-fullscreen {
3265
+ padding: 0;
3266
+ border: 0;
3267
+ border-radius: 0;
3268
+ box-shadow: none;
3269
+ }
3270
+ .kplex-central-editor-overlay.is-native-view-fullscreen .kplex-central-editor-document { clip: auto; }
3271
+ .kplex-central-editor-overlay.is-native-view-fullscreen .kplex-central-editor-leaf-host,
3272
+ .kplex-central-editor-overlay.is-native-view-fullscreen .kplex-embedded-workspace-root {
3273
+ border-radius: 0;
3274
+ }
3275
+ .kplex-central-editor-overlay.is-native-view-fullscreen .kplex-central-editor-toolbar {
3276
+ display: none;
3277
+ }
3278
+ .kplex-central-editor-leaf-host .workspace-tab-header-container,
3279
+ .kplex-central-editor-leaf-host .view-header {
3280
+ display: none;
3281
+ }
3282
+ .kplex-central-editor-leaf-host .workspace-leaf,
3283
+ .kplex-central-editor-leaf-host .workspace-leaf-content,
3284
+ .kplex-central-editor-leaf-host .view-content,
3285
+ .kplex-central-editor-leaf-host .markdown-source-view,
3286
+ .kplex-central-editor-leaf-host .markdown-reading-view {
3287
+ width: 100%;
3288
+ height: 100%;
3289
+ min-width: 0;
3290
+ min-height: 0;
3291
+ box-sizing: border-box;
3292
+ }
3293
+ .kplex-central-editor-leaf-host .workspace-leaf-content,
3294
+ .kplex-central-editor-leaf-host .view-content {
3295
+ overflow: hidden;
3296
+ }
3297
+ .kplex-central-editor-leaf-host .cm-scroller,
3298
+ .kplex-central-editor-leaf-host .markdown-reading-view,
3299
+ .kplex-central-editor-leaf-host .markdown-preview-view {
3300
+ touch-action: pan-y;
3301
+ overscroll-behavior: contain;
3302
+ }
3303
+ .kplex-central-editor-toolbar {
3304
+ position: absolute;
3305
+ z-index: 32;
3306
+ top: var(--kplex-editor-toolbar-top, -34px);
3307
+ right: var(--kplex-editor-toolbar-right, 1px);
3308
+ left: var(--kplex-editor-toolbar-left, 1px);
3309
+ display: flex;
3310
+ gap: 2px;
3311
+ align-items: center;
3312
+ padding: 2px;
3313
+ border: 1px solid var(--kplex-line, var(--background-modifier-border));
3314
+ border-radius: 6px;
3315
+ background: var(--kplex-panel, var(--background-primary));
3316
+ box-shadow: var(--shadow-s);
3317
+ }
3318
+ .kplex-central-editor-title {
3319
+ flex: 1 1 auto;
3320
+ min-width: 0;
3321
+ padding: 0 6px;
3322
+ overflow: hidden;
3323
+ text-overflow: ellipsis;
3324
+ white-space: nowrap;
3325
+ font-size: var(--font-ui-small);
3326
+ font-weight: var(--font-semibold);
3327
+ }
3328
+ .kplex-central-editor-toolbar > button { flex-shrink: 0; }
3329
+ .kplex-central-editor-status {
3330
+ position: absolute;
3331
+ z-index: 31;
3332
+ left: 50%;
3333
+ top: 50%;
3334
+ transform: translate(-50%, -50%);
3335
+ max-width: calc(100% - 36px);
3336
+ padding: 6px 9px;
3337
+ border-radius: 7px;
3338
+ color: var(--text-muted);
3339
+ background: var(--background-secondary);
3340
+ font-size: var(--font-ui-smaller);
3341
+ pointer-events: none;
3342
+ }
3343
+ .kplex-central-editor-status.is-error { color: var(--text-error); }
3344
+ .kplex-plex.is-central-editor-maximized .kplex-zoom-controls,
3345
+ .kplex-plex.is-central-editor-maximized .kplex-layout-controls {
3346
+ opacity: 0;
3347
+ visibility: hidden;
3348
+ pointer-events: none;
3349
+ }
3350
+ .kplex-plex.is-central-editor-maximized .kplex-role-center.has-embedded-content {
3351
+ box-shadow: none;
3352
+ }
3353
+
3354
+ /* Optional fixed-height two-line thought labels keep graph rows aligned while exposing longer titles. */
3355
+ .kplex-thought-label.is-two-line > .kplex-thought-text {
3356
+ display: -webkit-box;
3357
+ -webkit-box-orient: vertical;
3358
+ -webkit-line-clamp: 2;
3359
+ white-space: normal;
3360
+ line-height: 1.2;
3361
+ max-height: 2.4em;
3362
+ overflow: hidden;
3363
+ text-overflow: ellipsis;
3364
+ }
3365
+
3366
+ /* Native image views fit both dimensions of the untransformed embedded editor. */
3367
+ .kplex-central-editor-leaf-host [data-type="image"] .view-content {
3368
+ display: flex;
3369
+ align-items: center;
3370
+ justify-content: center;
3371
+ padding: 0;
3372
+ }
3373
+ .kplex-central-editor-leaf-host [data-type="image"] .image-container {
3374
+ display: flex;
3375
+ align-items: center;
3376
+ justify-content: center;
3377
+ width: 100%;
3378
+ height: 100%;
3379
+ min-width: 0;
3380
+ min-height: 0;
3381
+ overflow: hidden;
3382
+ }
3383
+ .kplex-central-editor-leaf-host [data-type="image"] .view-content img {
3384
+ display: block;
3385
+ width: 100%;
3386
+ height: 100%;
3387
+ max-width: 100%;
3388
+ max-height: 100%;
3389
+ object-fit: contain;
3390
+ }
3391
+
3392
+ /* Find stays local to the Plex, with a touch target and no result popup. */
3393
+ .kplex-scene-tools {
3394
+ position: absolute;
3395
+ top: 8px;
3396
+ right: 8px;
3397
+ z-index: 45;
3398
+ display: flex;
3399
+ align-items: center;
3400
+ gap: 4px;
3401
+ max-width: calc(100% - 16px);
3402
+ padding: 0;
3403
+ }
3404
+ .kplex-scene-tools.is-suspended { display: none; }
3405
+ /* In phone landscape, native chrome can leave only one row of canvas. Reuse the measured
3406
+ viewport state to place search beside the bottom controls instead of covering Zen/full screen. */
3407
+ .kplex-plex.is-short-canvas .kplex-scene-tools { top: 0; left: 60px; right: auto; }
3408
+ .kplex-find { display: flex; align-items: center; gap: 4px; min-width: 0; }
3409
+ .kplex-footprints-panel {
3410
+ position: fixed;
3411
+ box-sizing: border-box;
3412
+ z-index: var(--layer-popover);
3413
+ display: flex;
3414
+ flex-direction: column;
3415
+ overflow: hidden;
3416
+ color: var(--text-normal);
3417
+ background: var(--background-primary);
3418
+ border: 1px solid var(--background-modifier-border);
3419
+ border-radius: var(--radius-m);
3420
+ box-shadow: var(--shadow-s);
3421
+ }
3422
+ .kplex-footprints-heading { display: flex; align-items: center; gap: var(--size-4-2); padding: var(--size-4-2); }
3423
+ .kplex-footprints-heading strong { flex: 1; min-width: 0; overflow-wrap: anywhere; }
3424
+ .kplex-footprints-heading > span, .kplex-footprints-empty { color: var(--text-muted); font-size: var(--font-ui-small); }
3425
+ .kplex-footprints-empty { padding: var(--size-4-3); }
3426
+ .kplex-footprints-list { max-height: 320px; min-height: 0; overflow-y: auto; overscroll-behavior: contain; touch-action: pan-y; }
3427
+ .kplex-footprints-row {
3428
+ display: flex; align-items: center; gap: var(--size-4-2); width: 100%; height: 40px;
3429
+ margin: 0; padding: 0 var(--size-4-3); border: 0; border-radius: 0; box-shadow: none;
3430
+ color: var(--text-normal); background: transparent; text-align: start;
3431
+ }
3432
+ .kplex-footprints-row > span:not(.kplex-icon) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
3433
+ .kplex-footprints-row > .kplex-icon { flex-shrink: 0; }
3434
+ .kplex-footprints-row small { color: var(--text-muted); }
3435
+ .kplex-footprints-row[aria-current="location"] { background: var(--background-secondary); }
3436
+ .kplex-footprints-row:hover, .kplex-footprints-row:focus-visible { background: var(--background-modifier-hover); }
3437
+ .kplex-footprints-row[aria-disabled="true"] { color: var(--text-muted); }
3438
+ .kplex-view-host .kplex-find-input {
3439
+ width: 170px;
3440
+ min-width: 0;
3441
+ height: 28px;
3442
+ border: 1px solid var(--kplex-line, var(--background-modifier-border));
3443
+ }
3444
+ /* Pair text and surface for both pointer focus and programmatic filter autofocus. */
3445
+ .kplex-view-host .kplex-find-input,
3446
+ .kplex-view-host .kplex-find-input:focus,
3447
+ .kplex-view-host .kplex-zone-filter-input,
3448
+ .kplex-view-host .kplex-zone-filter-input:focus {
3449
+ color: var(--text-normal);
3450
+ background: var(--background-primary);
3451
+ }
3452
+ .kplex-view-host .kplex-find-input::placeholder,
3453
+ .kplex-view-host .kplex-zone-filter-input::placeholder {
3454
+ color: var(--text-muted);
3455
+ }
3456
+ .kplex-find-count {
3457
+ color: var(--kplex-muted, var(--text-muted));
3458
+ font-size: var(--font-smallest);
3459
+ white-space: nowrap;
3460
+ background: var(--kplex-control-bg, var(--interactive-normal));
3461
+ border-radius: 7px;
3462
+ padding: 3px 5px;
3463
+ }
3464
+ /* Typing selects displayed occurrences without creating another search field or taking pointer focus. */
3465
+ .kplex-type-selection {
3466
+ position: absolute;
3467
+ left: 8px;
3468
+ top: 8px;
3469
+ z-index: 45;
3470
+ display: flex;
3471
+ align-items: center;
3472
+ gap: 8px;
3473
+ box-sizing: border-box;
3474
+ max-width: calc(100% - 56px);
3475
+ min-height: 28px;
3476
+ padding: 4px 8px;
3477
+ border: 1px solid var(--background-modifier-border);
3478
+ border-radius: 7px;
3479
+ color: var(--text-normal);
3480
+ background: var(--background-primary);
3481
+ font-size: var(--font-ui-small);
3482
+ pointer-events: none;
3483
+ }
3484
+ .kplex-type-selection-query { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
3485
+ .kplex-type-selection-count { flex: 0 0 auto; white-space: nowrap; color: var(--text-muted); }
3486
+ /* Navigation, typing selection and local Find share one theme-accent ring and halo, including center and expanded nodes. */
3487
+ .kplex-thought.is-keyboard-selected,
3488
+ .kplex-expanded-mini-thought.is-keyboard-selected,
3489
+ .kplex-thought.is-selected.is-keyboard-selected,
3490
+ .kplex-plex.is-section-expanded .kplex-thought.is-selected.is-keyboard-selected,
3491
+ .kplex-plex.is-finding .kplex-thought.is-highlighted,
3492
+ .kplex-expanded-mini-thought.is-find-match {
3493
+ outline: 3px solid var(--interactive-accent);
3494
+ outline-offset: 3px;
3495
+ box-shadow: 0 0 0 3px var(--background-primary), 0 0 0 6px var(--interactive-accent), 0 0 28px 6px var(--interactive-accent);
3496
+ }
3497
+ .kplex-plex.is-finding .kplex-edge.is-highlighted .kplex-edge-visible,
3498
+ .kplex-expanded-edge.is-find-match { stroke: var(--interactive-accent); }
3499
+
3500
+ .kplex-vault-stats { display: grid; gap: 4px; margin: 8px 0 14px; }
3501
+ .kplex-vault-stats-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: baseline; }
3502
+ .kplex-vault-stats-row.is-nested { padding-left: 18px; color: var(--text-muted); }
3503
+ .kplex-vault-stats-value { font-variant-numeric: tabular-nums; text-align: right; }
3504
+
3505
+ /* Explicit ontology choices remain accessible without populating the text input. */
3506
+ .kplex-add-related-ontology-search .kplex-search { padding-right: 36px; }
3507
+ .kplex-fuzzy-disclosure {
3508
+ position: absolute;
3509
+ right: 4px;
3510
+ top: 4px;
3511
+ display: flex;
3512
+ align-items: center;
3513
+ justify-content: center;
3514
+ width: 28px;
3515
+ height: 26px;
3516
+ padding: 0;
3517
+ background: transparent;
3518
+ box-shadow: none;
3519
+ color: var(--text-muted);
3520
+ }
3521
+ .kplex-fuzzy-disclosure:hover { color: var(--text-normal); background: var(--background-modifier-hover); }
3522
+
3523
+ /* Explicit URL expansion owns one isolated browser/player inside the existing editor frame. */
3524
+ .kplex-embedded-web-page {
3525
+ display: flex;
3526
+ align-items: center;
3527
+ justify-content: center;
3528
+ width: 100%;
3529
+ height: 100%;
3530
+ min-width: 0;
3531
+ min-height: 0;
3532
+ overflow: hidden;
3533
+ background: var(--background-primary);
3534
+ }
3535
+ .kplex-embedded-web-frame {
3536
+ display: flex;
3537
+ flex: 0 0 auto;
3538
+ border: 0;
3539
+ }
3540
+
3541
+ /* A settled unavailable scope has no active work and must not suggest an endless spinner. */
3542
+ .kplex-index-status.is-incomplete,
3543
+ .kplex-topbar button.kplex-index-status.is-incomplete {
3544
+ background: var(--color-orange);
3545
+ box-shadow: none;
3546
+ animation: none;
3547
+ }
3548
+
3549
+ /* Local Find is retained while a maximized native editor owns the viewport. */
3550
+ .kplex-find.is-suspended { display: none; }
3551
+
3552
+ /* Pointer-captured relationship drags can target the history outside the Plex canvas. */
3553
+ .kplex-history-list button.is-relationship-drop-target,
3554
+ .kplex-pinned-open.is-relationship-drop-target {
3555
+ color: var(--text-normal);
3556
+ border-color: var(--interactive-accent);
3557
+ background: var(--background-secondary-alt);
3558
+ box-shadow: 0 0 0 1px var(--interactive-accent);
3559
+ }
3560
+
3561
+ /* A paired density stack preserves the previous two-card footprint on narrow Plex surfaces. */
3562
+ .kplex-density-axes { display: grid; gap: 4px; }
3563
+ /* Disclosure stays first in Tab order and bottom-left; only the expanded content can scroll. */
3564
+ .kplex-layout-controls { flex-wrap: nowrap; align-items: flex-end; max-width: calc(100% - 84px); }
3565
+ /* Override the shared icon's horizontal 30px flex basis when this shell turns vertical. */
3566
+ .kplex-layout-controls .kplex-layout-toggle { flex: 0 0 auto; }
3567
+ .kplex-layout-panel {
3568
+ display: flex;
3569
+ align-items: flex-end;
3570
+ gap: 8px;
3571
+ min-width: 0;
3572
+ max-height: var(--kplex-layout-panel-height);
3573
+ overflow-y: auto;
3574
+ overflow-x: hidden;
3575
+ touch-action: pan-y;
3576
+ }
3577
+ .kplex-layout-panel > .kplex-density-axes { flex: 0 0 auto; }
3578
+ .kplex-layout-panel > .kplex-typography-group { flex: 0 0 auto; }
3579
+ .kplex-layout-controls.is-stacked { flex-direction: column-reverse; align-items: flex-start; }
3580
+ .kplex-layout-controls.is-stacked .kplex-layout-panel {
3581
+ flex-direction: column;
3582
+ align-items: stretch;
3583
+ width: 198px;
3584
+ max-width: 100%;
3585
+ }
3586
+ .kplex-layout-controls.is-stacked .kplex-layout-panel > .kplex-density-axes > .kplex-density-control { width: 100%; }
3587
+ .kplex-layout-controls.is-stacked .kplex-density-control { grid-template-rows: auto 12px; }
3588
+ .kplex-layout-controls.is-stacked .kplex-density-heading { font-size: var(--font-ui-smaller, 12px); line-height: 1.2; letter-spacing: normal; text-transform: none; }
3589
+ .kplex-layout-controls.is-stacked .kplex-density-heading > span { min-width: 0; white-space: normal; overflow-wrap: anywhere; }
3590
+ /* Toggles retain one common active state instead of changing their surface palette. */
3591
+ .kplex-topbar button.is-on,
3592
+ .kplex-find button[aria-pressed="true"],
3593
+ button.kplex-footprints-trigger[aria-expanded="true"],
3594
+ button.kplex-layout-toggle[aria-pressed="true"],
3595
+ button.kplex-zone-filter-button.is-on,
3596
+ .kplex-sidecar-controls button[aria-pressed="true"] { color: var(--text-accent); border-color: var(--interactive-accent); }
3597
+
3598
+ .kplex-topbar button:focus-visible,
3599
+ .kplex-find button:focus-visible,
3600
+ button.kplex-footprints-trigger:focus-visible,
3601
+ button.kplex-layout-toggle:focus-visible,
3602
+ button.kplex-zone-filter-button:focus-visible,
3603
+ .kplex-sidecar-controls button:focus-visible,
3604
+ button.kplex-sidecar-unfold-plex:focus-visible,
3605
+ .kplex-central-editor-toolbar button:focus-visible,
3606
+ .kplex-zoom-controls button:focus-visible,
3607
+ .kplex-wander-controls button:focus-visible { outline: 2px solid var(--interactive-accent); outline-offset: 2px; }
3608
+ .kplex-filter-panel-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
3609
+ .kplex-filter-panel-header > span { font-size: var(--font-ui-medium); font-weight: var(--font-semibold); }
3610
+ .kplex-filter-panel-header > button { flex: 0 0 auto; }
3611
+
3612
+ /* Feedback is painted outside camera/zone stacking contexts, above graph panels and below controls. */
3613
+ .kplex-drop-area-preview {
3614
+ position: absolute;
3615
+ z-index: 19;
3616
+ box-sizing: border-box;
3617
+ pointer-events: none;
3618
+ border: 2px solid var(--interactive-accent);
3619
+ border-radius: 10px;
3620
+ background: transparent;
3621
+ box-shadow: 0 0 0 1px var(--interactive-accent);
3622
+ }
3623
+ .kplex-drop-area-preview::before {
3624
+ content: "";
3625
+ position: absolute;
3626
+ inset: 0;
3627
+ border-radius: inherit;
3628
+ background: var(--interactive-accent);
3629
+ opacity: .08;
3630
+ pointer-events: none;
3631
+ }
3632
+ .kplex-center-drop-preview { z-index: 27; border-radius: 18px; }
3633
+
3634
+ /* Typography matches the other layout cards, with full-width rails in stacked panes. */
3635
+ .kplex-typography-controls { min-width: 0; max-width: 100%; display: flex; flex-direction: column; align-items: stretch; gap: 4px; }
3636
+ .kplex-typography-controls .kplex-density-control { width: 100%; }
3637
+ .kplex-wrap-label-control { min-height: 36px; display: flex; flex-direction: row; align-items: center; gap: 8px; cursor: pointer; }
3638
+ .kplex-wrap-label-caption { display: block; width: 100%; line-height: 1.4; text-align: left; white-space: normal; overflow-wrap: anywhere; }
3639
+ .kplex-wrap-label-control input { margin: 0; }
3640
+ .kplex-typography-group { width: 126px; min-width: 0; max-width: 100%; display: flex; flex-direction: column; gap: 4px; }
3641
+ .kplex-typography-scope { display: flex; align-items: center; justify-content: space-between; gap: 4px; color: var(--text-muted); font-size: 9px; line-height: 1.2; }
3642
+ .kplex-typography-scope > span { min-width: 0; overflow-wrap: anywhere; }
3643
+ .kplex-layout-controls.is-stacked .kplex-typography-group { width: 100%; }
3644
+ .kplex-layout-controls.is-stacked .kplex-typography-scope { font-size: var(--font-ui-smaller, 12px); }
3645
+ .kplex-typography-scope button { padding: 2px; height: auto; min-height: 20px; background: transparent; box-shadow: none; color: var(--text-muted); }
3646
+
3647
+ /* Declarative shortcut rows stay within the native Settings page and global search results. */
3648
+ .kplex-action-setting .setting-item-control { flex-wrap: wrap; gap: 6px; }
3649
+ .kplex-action-setting button.setting-hotkey { border: 0; box-shadow: none; height: auto; min-height: 0; }
3650
+ .kplex-action-setting button.setting-add-hotkey-button { border: 0; box-shadow: none; background-color: transparent; }
3651
+ .kplex-action-setting .clickable-icon.is-active { color: var(--interactive-accent); }
3652
+ .kplex-action-settings-header .setting-item-info { display: none; }
3653
+ .kplex-action-settings-header .setting-item-control { width: 100%; flex-direction: column; align-items: stretch; gap: 10px; }
3654
+ .kplex-action-settings-header .search-input-container { width: 100%; }
3655
+ .kplex-action-settings-header input { padding-right: 64px; }
3656
+ .kplex-action-settings-header [data-kplex-action-control="search-hotkey"] { position: absolute; right: 28px; top: 3px; bottom: 3px; }
3657
+ .kplex-action-filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
3658
+ .kplex-action-filters .filter-pill { border-radius: 16px; padding: 3px 10px; background-color: transparent; border: 1px solid var(--background-modifier-border); box-shadow: none; }
3659
+ .kplex-action-filters .filter-pill.is-active { color: var(--text-on-accent); background-color: var(--interactive-accent); }
3660
+ .kplex-action-filtered { display: none; }
3661
+ .kplex-action-feedback { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
3662
+ .kplex-action-status { color: var(--text-muted); font-size: var(--font-ui-small); overflow-wrap: anywhere; }
3663
+ .kplex-action-scope,
3664
+ .kplex-action-publication-state { color: var(--text-muted); font-size: var(--font-ui-small); margin-top: 4px; overflow-wrap: anywhere; }
3665
+ .kplex-action-publication-state.kplex-action-diagnostic-warning { color: var(--text-warning); }
3666
+
3667
+ /* Native suggestion themes supply row typography and surfaces; these rules keep both columns bounded. */
3668
+ .kplex-action-suggestion { display: flex; align-items: center; gap: 12px; min-width: 0; }
3669
+ .kplex-action-suggestion .suggestion-content { flex: 1 1 auto; min-width: 0; }
3670
+ .kplex-action-suggestion .suggestion-title,
3671
+ .kplex-action-suggestion .suggestion-note { white-space: normal; overflow-wrap: anywhere; }
3672
+ .kplex-action-suggestion .suggestion-aux { flex: 0 1 auto; min-width: 0; max-width: 45%; }
3673
+ .kplex-action-suggestion .setting-command-hotkeys { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; min-width: 0; max-width: 100%; }
3674
+ .kplex-action-suggestion .suggestion-hotkey { margin: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
3675
+
3676
+ /* The shortcut reference owns one result scroller while its explanation, search and footer stay fixed. */
3677
+ .kplex-keyboard-help { display: flex; flex-direction: column; max-height: 80vh; }
3678
+ .kplex-keyboard-help .modal-content { display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; overflow: hidden; }
3679
+ .kplex-keyboard-help-header { display: flex; flex-direction: column; flex: 0 0 auto; gap: 12px; padding-bottom: 12px; }
3680
+ .kplex-keyboard-help-header p { margin: 0; color: var(--text-muted); font-size: var(--font-ui-small); }
3681
+ .kplex-keyboard-help-header .search-input-container { width: 100%; }
3682
+ .kplex-keyboard-help-results { flex: 1 1 auto; min-height: 0; overflow-y: auto; }
3683
+ .kplex-keyboard-help-footer { flex: 0 0 auto; padding-top: 12px; }
3684
+ .kplex-keyboard-help-footer .setting-item { padding: 0; border-top: 0; }
3685
+ @media (max-width: 600px) {
3686
+ .kplex-action-setting { flex-wrap: wrap; gap: 8px; }
3687
+ .kplex-action-setting .setting-item-control { justify-content: flex-start; }
3688
+ }
3689
+
3690
+ /* The recorder reuses native settings and modal buttons; only its capture region needs structure. */
3691
+ .kplex-shortcut-recording-description { color: var(--text-muted); font-size: var(--font-ui-small); }
3692
+ .kplex-shortcut-matching { gap: 12px; padding-top: 0; border-top: 0; }
3693
+ .kplex-shortcut-recording-area { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 88px; padding: 24px 16px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); background-color: var(--background-secondary); }
3694
+ .kplex-shortcut-recording-area:focus { border-color: var(--interactive-accent); outline: 2px solid var(--interactive-accent); outline-offset: 2px; }
3695
+ .kplex-shortcut-recording-hint { color: var(--text-muted); font-size: var(--font-ui-small); text-align: center; }
3696
+ .kplex-shortcut-recorder .modal-button-container { flex-wrap: wrap; }
3697
+ @media (max-width: 600px) {
3698
+ .kplex-shortcut-matching { flex-wrap: wrap; }
3699
+ .kplex-shortcut-matching .setting-item-control { justify-content: flex-start; }
3700
+ .kplex-shortcut-matching select { max-width: 100%; }
3701
+ }
3702
+
3703
+ /* Local ambiguity inherits native red; global assignments remain a distinct advisory marker. */
3704
+ .kplex-action-setting .kplex-action-local-conflict,
3705
+ .kplex-action-setting .kplex-action-global-warning,
3706
+ .kplex-action-setting .kplex-action-global-self { display: inline-flex; align-items: center; }
3707
+ .kplex-action-setting .kplex-action-global-warning { color: var(--text-warning); }
3708
+ .kplex-action-setting .kplex-action-global-self { color: var(--text-muted); }
3709
+ .kplex-action-setting .kplex-action-local-conflict svg,
3710
+ .kplex-action-setting .kplex-action-global-warning svg,
3711
+ .kplex-action-setting .kplex-action-global-self svg { width: 14px; height: 14px; }
3712
+
3713
+ /* Saved overlaps are visible without hover; selected conflict filtering retains its error color. */
3714
+ .kplex-action-diagnostics { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; font-size: var(--font-ui-small); overflow-wrap: anywhere; }
3715
+ .kplex-action-diagnostic-error { color: var(--text-error); }
3716
+ .kplex-action-diagnostic-warning { color: var(--text-warning); }
3717
+ .kplex-action-diagnostic-info { color: var(--text-muted); }
3718
+ .kplex-action-filters .kplex-action-conflicts-filter { color: var(--text-error); border-color: var(--text-error); }
3719
+ .kplex-action-filters .kplex-action-conflicts-filter.is-active { color: var(--text-on-accent); background-color: var(--background-modifier-error); border-color: var(--background-modifier-error); }
3720
+
3721
+ /* One owning-document fullscreen lease covers workspace chrome below native popovers/dialogs. */
3722
+ /* Match the native layout docking used by Excalidraw: reserve the bar's actual height rather
3723
+ than guessing bottom padding. Native safe-area, keyboard, floating/hidden-nav and tablet rules
3724
+ remain authoritative; the active view's lease restores them on tab change or close. */
3725
+ body.is-mobile > .app-container > .mobile-navbar.kplex-mobile-navbar-docked { position: relative; }
3726
+ body.is-mobile > .app-container > .mobile-navbar.kplex-mobile-navbar-hidden { display: none; }
3727
+ .kplex-fullscreen-anchor { display: none; }
3728
+ /* An emptied native mobile drawer/backdrop must not cover its canvas at popover z-index 30/32.
3729
+ Keep the fullscreen overlay below native previews, dialogs and menus. */
3730
+ .workspace-drawer.kplex-fullscreen-drawer,
3731
+ .workspace-drawer-backdrop.kplex-fullscreen-drawer,
3732
+ .workspace-split.mod-root.is-sliding-sidebar.kplex-fullscreen-drawer,
3733
+ .workspace-split.mod-root > .workspace-drawer-backdrop.kplex-fullscreen-drawer { z-index: var(--layer-sidedock, 10); }
3734
+ .kplex-fullscreen-overlay {
3735
+ position: fixed;
3736
+ inset: 0;
3737
+ z-index: calc(var(--layer-popover, 30) - 1);
3738
+ overflow: hidden;
3739
+ background-color: var(--background-primary);
3740
+ }
3741
+ /* Keep the graph viewport and left gutter; Windows fullscreen action bars share measured native-control exclusion. */
3742
+ .kplex-fullscreen-overlay.kplex-windows-fullscreen .kplex-topbar {
3743
+ padding-right: calc(10px + var(--kplex-window-controls-inset, 0px));
3744
+ }
3745
+ .kplex-fullscreen-overlay.kplex-windows-fullscreen .kplex-app.is-zen .kplex-central-editor-overlay.is-maximized .kplex-central-editor-toolbar {
3746
+ right: calc(1px + var(--kplex-window-controls-inset, 0px));
3747
+ }
3748
+ .kplex-fullscreen-overlay > .kplex-view-host { padding: 0; }
3749
+ .kplex-app.is-zen > .kplex-main-column { grid-template-rows: minmax(0, 1fr); }
3750
+ .kplex-app.is-zen > .kplex-main-column > .kplex-top-stack,
3751
+ .kplex-app.is-zen > .kplex-main-column > .kplex-history-bar { display: none; }
3752
+
3753
+ /* Native support guidance keeps its exact Markdown payload selectable in narrow owner windows. */
3754
+ .kplex-support-report-modal { width: 640px; max-width: calc(100vw - 32px); }
3755
+ .kplex-empty-support { position: absolute; top: 12px; right: 12px; }
3756
+ .kplex-support-report-links { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 12px; }
3757
+ .kplex-support-report-preview { display: block; box-sizing: border-box; width: 100%; max-width: 100%; min-height: 180px; max-height: 40vh; font-family: var(--font-monospace); font-size: var(--font-ui-small); resize: vertical; }
3758
+
3759
+ /* Wander reuses the Plex button and layout-rail palette; only its floating position differs. */
3760
+ .kplex-layout-controls.kplex-wander-controls { z-index: 35; bottom: 12px; left: 50%; transform: translateX(-50%); max-width: calc(100% - 24px); }
3761
+ /* Detached color editors use native chrome; preview variables stay on their private cards. */
3762
+ .kplex-color-modal { width: min(740px, 94vw); }
3763
+ .kplex-color-source-editor { display: grid; gap: var(--size-4-3); margin-block: var(--size-4-3); }
3764
+ .kplex-color-source-editor label, .kplex-literal-controls label, .kplex-literal-opacity label { display: grid; gap: var(--size-4-1); min-width: 0; }
3765
+ .kplex-color-source-editor input[type="text"] { width: 100%; }
3766
+ .kplex-literal-editor { border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); margin: 0; padding: var(--size-4-3); min-width: 0; }
3767
+ .kplex-literal-controls { display: grid; grid-template-columns: auto auto minmax(0, 1fr); align-items: end; gap: var(--size-4-2); }
3768
+ .kplex-color-swatch { background: var(--kplex-color-swatch); width: 28px; height: 28px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-s); }
3769
+ .kplex-literal-opacity { margin-top: var(--size-4-3); }
3770
+ .kplex-literal-opacity input { width: 100%; }
3771
+ .kplex-color-previews { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--size-4-3); margin-top: var(--size-4-3); }
3772
+ .kplex-color-preview { border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); padding: var(--size-4-2); min-width: 0; }
3773
+ .kplex-color-preview-heading { display: flex; align-items: baseline; justify-content: space-between; gap: var(--size-4-2); }
3774
+ .kplex-color-preview-canvas { position: relative; height: 140px; overflow: hidden; border-radius: var(--radius-s); margin-top: var(--size-4-2); background: var(--_kplex-preview-base); }
3775
+ .kplex-color-preview-canvas svg { position: absolute; inset: 0; width: 100%; height: 100%; }
3776
+ .kplex-color-preview-canvas::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: var(--_kplex-preview-canvas); }
3777
+ .kplex-color-preview-node { position: absolute; left: 35%; top: 27%; width: 60%; min-height: 56px; padding: var(--size-4-2); border: 1px solid var(--_kplex-preview-node-border); border-radius: var(--radius-m); background: var(--_kplex-preview-node-fill); color: var(--_kplex-preview-node-text); font-size: var(--font-ui-small); }
3778
+ .kplex-color-preview-gate { position: absolute; width: 10px; height: 10px; left: -6px; top: calc(50% - 5px); border: 1px solid var(--_kplex-preview-gate-stroke); border-radius: 50%; background: var(--_kplex-preview-gate-fill); }
3779
+ .kplex-color-preview-gate.is-empty { left: auto; right: -6px; background: transparent; }
3780
+ .kplex-color-preview-label { position: absolute; left: 4%; bottom: 8%; font-size: var(--font-ui-smaller); padding: 2px 4px; border-radius: var(--radius-s); color: var(--_kplex-preview-label-text); background: var(--_kplex-preview-label-fill); }
3781
+ .kplex-color-preview-contrast { margin-top: var(--size-4-2); color: var(--text-muted); font-size: var(--font-ui-smaller); }
3782
+ @media (max-width: 500px) { .kplex-color-previews { grid-template-columns: minmax(0, 1fr); } }
3783
+
3784
+ .kplex-color-source-editor select { width: 100%; max-width: 100%; min-width: 0; }
3785
+ .kplex-color-source-editor button { white-space: normal; overflow-wrap: anywhere; max-width: 100%; }
3786
+
3787
+ .kplex-lens-fields { border: 0; margin: 0; padding: 0; min-width: 0; }
3788
+ .kplex-palette-controls, .kplex-palette-row { display: flex; align-items: center; gap: 0.5em; flex-wrap: wrap; }
3789
+ .kplex-palette-controls input { flex: 1; min-width: 8em; }
3790
+ .kplex-palette-row { padding: var(--size-4-2) 0; border-bottom: var(--border-width) solid var(--background-modifier-border); }
3791
+ .kplex-palette-name { flex: 1; min-width: 8em; overflow-wrap: anywhere; }
3792
+
3793
+ /* Four viewport decorations stay beneath the camera and never participate in input or drop routing. */
3794
+ .kplex-compass-background { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
3795
+ .kplex-compass-intensity { max-width: 26em; }
3796
+ @media (forced-colors: active) { .kplex-compass-background, .kplex-color-preview-compass { display: none; } }
3797
+
3798
+ /* Shared paired property samples and palette sequences in native Settings and style editors. */
3799
+ .kplex-color-strips { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
3800
+ .kplex-color-strip { display: flex; align-items: center; gap: var(--size-4-2); }
3801
+ .kplex-color-strip-label { color: var(--text-muted); font-size: var(--font-ui-smaller); min-width: 3.5em; }
3802
+ .kplex-color-strip-cells { display: flex; gap: 1px; min-width: 0; }
3803
+ .kplex-color-strip-cells .kplex-color-swatch { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 16px; border-radius: 0; flex-shrink: 1; }
3804
+ .setting-item-control > .kplex-color-strips { margin-inline-end: var(--size-4-2); }
3805
+ .kplex-style-row > .kplex-color-strips { margin-inline-start: auto; }
3806
+ .kplex-color-suggestion { display: flex; align-items: center; gap: var(--size-4-3); }
3807
+ .kplex-color-suggestion > .suggestion-content { flex: 1; min-width: 0; overflow-wrap: anywhere; }
3808
+ .kplex-color-suggestion > .kplex-color-strips { flex-shrink: 0; }
3809
+ .kplex-color-suggestion .kplex-color-strip-label { min-width: 0; }
3810
+ .kplex-color-suggestion .kplex-color-strip-cells .kplex-color-swatch { width: 18px; height: 12px; }
3811
+
3812
+ /* Explicit appearance drafts share one scrolling body; native Save/Cancel stay visible. */
3813
+ .modal.kplex-scroll-editor-modal { display: flex; flex-direction: column; max-height: 90vh; }
3814
+ .modal.kplex-scroll-editor-modal .modal-content { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
3815
+ .kplex-style-editor-body,
3816
+ .kplex-publish-sections { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding-inline-end: var(--size-4-2); padding-bottom: var(--size-4-3); }
3817
+ .kplex-style-editor-actions { flex: 0 0 auto; padding-top: var(--size-4-2); background: var(--modal-background, var(--background-primary)); }
3818
+ .kplex-style-editor-actions .setting-item { border-top: var(--border-width) solid var(--background-modifier-border); padding-bottom: 0; }
3819
+ /* Shared native modal controls leave room for scrollbars, chevrons and button icons. */
3820
+ .kplex-scroll-editor-modal .setting-item-control { min-width: 0; }
3821
+ .kplex-scroll-editor-modal .setting-item-control select { min-width: 0; max-width: 100%; }
3822
+ .kplex-modal-action-row button { display: inline-flex; align-items: center; gap: var(--size-4-1); }
3823
+ .kplex-modal-action-row .setting-item-info { display: none; }
3824
+ .kplex-modal-action-row .setting-item-control { flex: 1; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
3825
+ .modal button.kplex-icon-action { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 36px; min-width: 36px; height: 36px; padding: 8px; font-size: 0; }
3826
+ .modal button.kplex-icon-action .kplex-lucide { width: 18px; height: 18px; flex: 0 0 18px; }
3827
+ .modal.kplex-facet-preset-editor { width: min(1120px, 94vw); max-width: 94vw; height: min(900px, 90vh); }
3828
+ .modal.kplex-facet-preset-editor .modal-content { flex: 1 1 auto; }
3829
+ .kplex-facet-preset-editor .setting-item-control { min-width: 0; }
3830
+ .kplex-facet-preset-editor .setting-item-control > input[type="text"] { width: min(420px, 100%); }
3831
+ .kplex-facet-preset-editor .setting-item-control select { max-width: 100%; }
3832
+
3833
+ /* Native theme controls wrap on narrow Settings pages without a separate toolbar. */
3834
+ .kplex-theme-setting .setting-item-control { flex-wrap: wrap; gap: var(--size-4-2); }
3835
+ .kplex-theme-setting select { max-width: min(260px, 100%); }
3836
+
3837
+ /* Group totals sit outside the pill and remain visible independently of gate-count settings. */
3838
+ .kplex-group-count {
3839
+ position: absolute;
3840
+ right: -10px;
3841
+ bottom: -13px;
3842
+ color: var(--text-muted);
3843
+ font-size: 10px;
3844
+ line-height: 1;
3845
+ pointer-events: none;
3846
+ }
3847
+
3848
+ .kplex-thought.is-relation-group { cursor: pointer; }
3849
+
3850
+ /* A failed view policy retains native editing and exposes a local, non-destructive recovery action. */
3851
+ .kplex-view-error {
3852
+ position: absolute;
3853
+ top: var(--size-4-3);
3854
+ left: var(--size-4-3);
3855
+ z-index: 40;
3856
+ display: flex;
3857
+ align-items: center;
3858
+ gap: var(--size-4-2);
3859
+ padding: var(--size-4-2);
3860
+ border: 1px solid var(--background-modifier-border);
3861
+ border-radius: var(--radius-s);
3862
+ background: var(--background-primary);
3863
+ color: var(--text-normal);
3864
+ font-size: var(--font-ui-small);
3865
+ }
3866
+ .kplex-view-decorations {
3867
+ position: absolute;
3868
+ left: 0;
3869
+ top: 0;
3870
+ width: 1px;
3871
+ height: 1px;
3872
+ overflow: visible;
3873
+ pointer-events: none;
3874
+ }
3875
+
3876
+ .kplex-view-region rect,
3877
+ .kplex-view-region > path {
3878
+ fill: var(--background-secondary);
3879
+ fill-opacity: 0.24;
3880
+ stroke: var(--background-modifier-border);
3881
+ stroke-width: 1;
3882
+ }
3883
+
3884
+ .kplex-area-frame.is-shaped-area { border: none; }
3885
+ .kplex-area-shape { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
3886
+ .kplex-area-shape path { fill: none; stroke: var(--background-modifier-border-focus); stroke-width: 1; stroke-dasharray: 4 4; }
3887
+ .kplex-area-frame.is-active .kplex-area-shape path { stroke: var(--interactive-accent); stroke-dasharray: none; }
3888
+ .kplex-drop-area-shape { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 20; }
3889
+ .kplex-drop-area-shape path { fill: var(--interactive-accent); fill-opacity: .15; stroke: var(--interactive-accent); stroke-width: 2; }
3890
+ .kplex-facet-anchor-preview { display: grid; grid-template-columns: auto 1fr auto; grid-template-rows: auto 1fr auto; gap: 12px; padding: 16px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); }
3891
+ .kplex-facet-anchor-focus { padding: 6px; border: 1px solid var(--interactive-accent); border-radius: var(--radius-s); text-align: center; }
3892
+ .kplex-facet-anchor-categories { grid-area: 2 / 2; display: flex; gap: 6px; }
3893
+ .kplex-facet-anchor-categories span { padding: 6px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-s); }
3894
+ .kplex-facet-anchor-preview.is-vertical .kplex-facet-anchor-categories { flex-direction: column; }
3895
+ .kplex-facet-anchor-preview.is-anchor-top .kplex-facet-anchor-focus { grid-area: 1 / 2; }
3896
+ .kplex-facet-anchor-preview.is-anchor-bottom .kplex-facet-anchor-focus { grid-area: 3 / 2; }
3897
+ .kplex-facet-anchor-preview.is-anchor-left .kplex-facet-anchor-focus { grid-area: 2 / 1; align-self: center; }
3898
+ .kplex-facet-anchor-preview.is-anchor-right .kplex-facet-anchor-focus { grid-area: 2 / 3; align-self: center; }
3899
+ .kplex-markdown-help-modal { width: min(760px, 94vw); }
3900
+ .kplex-markdown-help-content { overflow-wrap: break-word; }
3901
+ .kplex-markdown-help-content pre { overflow-x: auto; }
3902
+ .kplex-facet-help-settings textarea { width: 100%; min-height: 180px; }
3903
+ .kplex-facet-help-source { flex-direction: column; align-items: stretch; gap: 12px; }
3904
+ .kplex-facet-help-source .setting-item-info { margin-right: 0; }
3905
+ .kplex-facet-help-source .setting-item-control { width: 100%; }
3906
+ .kplex-ontology-description-setting { flex-direction: column; align-items: stretch; gap: var(--size-4-2); }
3907
+ .kplex-ontology-description-setting .setting-item-info { margin-right: 0; }
3908
+ .kplex-ontology-description-setting .setting-item-control { width: 100%; }
3909
+ .kplex-ontology-description-setting textarea { width: 100%; min-width: 0; resize: vertical; }
3910
+ .kplex-preset-help-preview { padding: 12px; }
3911
+
3912
+ .kplex-view-region.is-water rect { fill: var(--color-blue); fill-opacity: 0.06; }
3913
+ .kplex-view-region.is-wood rect { fill: var(--color-green); fill-opacity: 0.06; }
3914
+ .kplex-view-region.is-fire rect { fill: var(--color-red); fill-opacity: 0.06; }
3915
+ .kplex-view-region.is-earth rect { fill: var(--color-yellow); fill-opacity: 0.06; }
3916
+ .kplex-view-region.is-metal rect { fill: var(--color-purple); fill-opacity: 0.06; }
3917
+
3918
+ .kplex-view-region text { fill: var(--text-normal); font-size: 16px; }
3919
+ .kplex-view-region .kplex-view-region-count { fill: var(--text-muted); font-size: 11px; }
3920
+ .kplex-view-guide { stroke: var(--text-faint); stroke-width: 1; stroke-dasharray: 5 7; opacity: 0.5; }
3921
+ .kplex-view-guide.is-generating { stroke: var(--text-muted); stroke-dasharray: none; }
3922
+ .kplex-view-guide.is-regulating { stroke: var(--text-muted); stroke-dasharray: 3 5; }
3923
+ .kplex-view-guide.is-no-line { stroke: none; }
3924
+ .kplex-view-guide-caption rect { fill: var(--background-primary); stroke: var(--background-modifier-border); stroke-width: 1; }
3925
+ .kplex-view-guide-caption text { fill: var(--text-muted); }
3926
+ .kplex-view-region .kplex-view-region-description { fill: var(--text-muted); font-size: 12px; }
3927
+ .kplex-view-heading {
3928
+ position: absolute;
3929
+ z-index: 2;
3930
+ top: 12px;
3931
+ left: 50%;
3932
+ transform: translateX(-50%);
3933
+ max-width: 50%;
3934
+ overflow: hidden;
3935
+ text-overflow: ellipsis;
3936
+ white-space: nowrap;
3937
+ color: var(--text-muted);
3938
+ font-size: var(--font-ui-small);
3939
+ pointer-events: none;
3940
+ }
3941
+ .kplex-view-status {
3942
+ position: absolute;
3943
+ z-index: 3;
3944
+ top: 38px;
3945
+ left: 12px;
3946
+ max-width: 70%;
3947
+ color: var(--text-muted);
3948
+ font-size: var(--font-ui-small);
3949
+ }
3950
+ .kplex-node-badge {
3951
+ position: absolute;
3952
+ display: flex;
3953
+ align-items: center;
3954
+ padding: 3px 8px;
3955
+ border-radius: var(--radius-s);
3956
+ border: 1px solid var(--background-modifier-border);
3957
+ box-sizing: border-box;
3958
+ white-space: nowrap;
3959
+ overflow: hidden;
3960
+ text-overflow: ellipsis;
3961
+ font-weight: var(--font-semibold);
3962
+ pointer-events: none;
3963
+ }
3964
+ .kplex-node-badge > span { overflow: hidden; text-overflow: ellipsis; }
3965
+
3966
+ .modal.kplex-portable-package-modal { width: min(1100px, 94vw); max-width: 94vw; }
3967
+ .kplex-package-intro { display: flex; align-items: flex-start; gap: 12px; }
3968
+ .kplex-package-intro p { flex: 1; margin-top: 0; }
3969
+ .kplex-package-source { width: 100%; min-height: 140px; height: clamp(140px, 24vh, 260px); max-height: 45vh; font-family: var(--font-monospace); resize: vertical; }
3970
+ .kplex-package-json { white-space: pre-wrap; overflow-wrap: anywhere; }
3971
+
3972
+ /* Shared native numeric settings keep their value visible without a hover-only tooltip. */
3973
+ .kplex-number-value { min-width: 3em; text-align: end; font-variant-numeric: tabular-nums; color: var(--text-muted); }
3974
+ .kplex-number-setting .slider-value { display: none; }
3975
+ .kplex-literal-opacity .setting-item { padding: 0; border: 0; }
3976
+
3977
+ /* Authored ontology text stays concise visually; full literal text remains in accessible names. */
3978
+ .kplex-ontology-description {
3979
+ min-width: 0;
3980
+ max-width: 100%;
3981
+ overflow: hidden;
3982
+ text-overflow: ellipsis;
3983
+ white-space: nowrap;
3984
+ color: var(--text-muted);
3985
+ font-size: var(--font-ui-smaller);
3986
+ }
3987
+ .kplex-ontology-results .kplex-search-result { display: grid; gap: 2px; }
3988
+ .kplex-ontology-results .kplex-search-result small {
3989
+ display: block;
3990
+ max-width: 100%;
3991
+ overflow: hidden;
3992
+ text-overflow: ellipsis;
3993
+ white-space: pre;
3994
+ text-align: left;
3995
+ }
3996
+
3997
+ /* Integrated native settings need their own full-width row; the default label/control split
3998
+ otherwise squeezes period names beside a form and inherits right-aligned control content. */
3999
+ .setting-item.kplex-periodic-pin-section {
4000
+ display: block;
4001
+ padding-block: var(--size-4-5);
4002
+ }
4003
+
4004
+ .kplex-periodic-pin-section > .setting-item-info {
4005
+ width: 100%;
4006
+ margin: 0 0 var(--size-4-3);
4007
+ text-align: start;
4008
+ }
4009
+
4010
+ .kplex-periodic-pin-section > .setting-item-info > .setting-item-name {
4011
+ color: var(--text-normal);
4012
+ font-size: var(--font-ui-medium);
4013
+ font-weight: var(--font-semibold);
4014
+ white-space: normal;
4015
+ overflow: visible;
4016
+ text-overflow: clip;
4017
+ }
4018
+
4019
+ .kplex-periodic-pin-section > .setting-item-control {
4020
+ display: block;
4021
+ width: 100%;
4022
+ min-width: 0;
4023
+ padding: 0;
4024
+ text-align: start;
4025
+ }
4026
+
4027
+ .kplex-periodic-pin-settings {
4028
+ width: 100%;
4029
+ min-width: 0;
4030
+ }
4031
+
4032
+ .kplex-periodic-pin-section .kplex-periodic-pin-settings .setting-item {
4033
+ align-items: center;
4034
+ flex-wrap: wrap;
4035
+ gap: var(--size-4-2) var(--size-4-4);
4036
+ padding-block: var(--size-4-3);
4037
+ padding-inline: 0;
4038
+ border: 0;
4039
+ }
4040
+
4041
+ .kplex-periodic-pin-section .kplex-periodic-pin-settings .setting-item:first-child {
4042
+ padding-top: 0;
4043
+ }
4044
+
4045
+ /* Native Settings groups also draw row separators with a pseudo-element. The outer
4046
+ period sections already provide separation, so nested controls need no second divider. */
4047
+ .kplex-periodic-pin-section .kplex-periodic-pin-settings .setting-item::before {
4048
+ display: none;
4049
+ }
4050
+
4051
+ .kplex-periodic-pin-section .kplex-periodic-pin-settings :where(.setting-item:not(.kplex-form-field)) > .setting-item-info {
4052
+ flex: 1 1 12rem;
4053
+ min-width: 0;
4054
+ margin: 0;
4055
+ text-align: start;
4056
+ }
4057
+
4058
+ .kplex-periodic-pin-section .kplex-periodic-pin-settings :where(.setting-item:not(.kplex-form-field)) > .setting-item-control {
4059
+ flex: 1 1 16rem;
4060
+ min-width: 0;
4061
+ padding: 0;
4062
+ text-align: start;
4063
+ }
4064
+
4065
+ .kplex-periodic-pin-section .kplex-periodic-pin-toggle .setting-item-control {
4066
+ flex: 0 0 auto;
4067
+ }
4068
+
4069
+ .kplex-periodic-pin-settings input[type="text"],
4070
+ .kplex-periodic-pin-settings select {
4071
+ width: 100%;
4072
+ min-width: 0;
4073
+ max-width: 100%;
4074
+ }
4075
+
4076
+ .kplex-periodic-pin-preview {
4077
+ margin-top: var(--size-4-2);
4078
+ padding: var(--size-4-3);
4079
+ border-radius: var(--radius-s);
4080
+ background: var(--background-secondary);
4081
+ color: var(--text-muted);
4082
+ line-height: 1.5;
4083
+ text-align: start;
4084
+ white-space: normal;
4085
+ overflow-wrap: anywhere;
4086
+ }
4087
+
4088
+ .kplex-periodic-pin-preview > div {
4089
+ margin-top: var(--size-4-1);
4090
+ }
4091
+
4092
+ /* Shared tab navigation keeps creation drafts mounted, including on narrow screens. */
4093
+ .kplex-tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--background-modifier-border); margin-bottom: 16px; padding-bottom: 8px; }
4094
+ .kplex-tabs > [role="tab"] { flex: 1 1 140px; box-shadow: none; }
4095
+ .kplex-tabs > [aria-selected="true"] { color: var(--text-accent); background: var(--background-modifier-active-hover); outline: 1px solid var(--interactive-accent); }
4096
+ /* Creation kinds share one panel; native fields and actions retain their own control chrome. */
4097
+ .kplex-creation-types { min-width: 0; }
4098
+ .kplex-add-related-footer > .kplex-creation-types + .kplex-creation-completion { margin-top: var(--kplex-form-gap); }
4099
+ .kplex-creation-types > .kplex-tabs { gap: 4px; margin-bottom: 0; padding-bottom: 0; border-bottom: 0; }
4100
+ .kplex-creation-types > .kplex-tabs > [role="tab"] { flex: 1 1 90px; min-width: 0; min-height: var(--input-height); height: auto; white-space: normal; overflow-wrap: anywhere; border-end-start-radius: 0; border-end-end-radius: 0; }
4101
+ .kplex-creation-type-panel { min-width: 0; padding: 16px; border: 1px solid var(--background-modifier-border); border-radius: 0 0 var(--radius-m) var(--radius-m); }
4102
+ .kplex-creation-type-panel > .kplex-form-actions { margin-bottom: 0; }
4103
+ .kplex-create-folder-note-modal [role="tabpanel"][hidden] { display: none; }
4104
+ .kplex-ownership-preview { padding: 12px 16px; margin-bottom: 12px; border: 1px solid var(--background-modifier-border); border-radius: var(--radius-m); }
4105
+ .kplex-ownership-preview.is-after { border-color: var(--interactive-accent); }
4106
+ .kplex-ownership-preview h4 { margin: 0 0 8px; font-size: var(--font-ui-small); color: var(--text-muted); }
4107
+ .kplex-ownership-preview p { margin: 0; overflow-wrap: anywhere; }
4108
+ .kplex-import-files input { width: 100%; }
4109
+
4110
+ /* Canonical native/React form treatment. UI_RULES.md owns the consumer contract. */
4111
+ .kplex-modal {
4112
+ --kplex-form-gap: 16px;
4113
+ --kplex-control-gap: 8px;
4114
+ --kplex-control-height: var(--input-height, 30px);
4115
+ font-family: var(--font-interface);
4116
+ font-size: var(--font-ui-medium);
4117
+ }
4118
+ .kplex-modal .modal-content { font-family: var(--font-interface); font-size: var(--font-ui-medium); }
4119
+ .modal.kplex-modal .modal-content .setting-item { padding: 0; margin-block: 0 var(--kplex-form-gap); border: 0; gap: var(--kplex-control-gap); }
4120
+ .modal.kplex-modal .setting-item-name,
4121
+ .kplex-modal .kplex-form-option > label { font-size: var(--font-ui-medium); font-weight: var(--font-normal); }
4122
+ .modal.kplex-modal .setting-item-description,
4123
+ .kplex-modal .kplex-form-status { font-family: var(--font-interface); font-size: var(--font-ui-small); line-height: 1.5; }
4124
+ .kplex-modal .setting-item-control { min-width: 0; gap: var(--kplex-control-gap); }
4125
+ .kplex-form-field { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
4126
+ .kplex-form-field > .setting-item-info { margin: 0; width: 100%; flex: 0 0 auto; }
4127
+ .kplex-form-field > .setting-item-control { width: 100%; display: flex; flex-wrap: wrap; min-width: 0; flex: 0 0 auto; }
4128
+ .kplex-form-field > .setting-item-control > input[type="text"],
4129
+ .kplex-form-field > .setting-item-control > select,
4130
+ .kplex-form-field > .setting-item-control > textarea,
4131
+ .kplex-form-field > .setting-item-control > div { width: 100%; min-width: 0; flex: 1 1 100%; }
4132
+ .kplex-form-field textarea { width: 100%; min-width: 0; resize: vertical; }
4133
+ .kplex-modal .kplex-form-field > .setting-item-control > select { max-width: none; }
4134
+ /* Source editors share field geometry while retaining readable code typography. */
4135
+ .kplex-modal .kplex-predicate-expression-field textarea,
4136
+ .kplex-modal textarea.kplex-package-source,
4137
+ .kplex-modal textarea.kplex-support-report-preview { font-family: var(--font-monospace); }
4138
+ .kplex-form-option {
4139
+ display: grid;
4140
+ grid-template-columns: minmax(120px, 1fr) minmax(180px, 1fr);
4141
+ align-items: center;
4142
+ gap: 8px 16px;
4143
+ width: 100%;
4144
+ margin-block: 16px;
4145
+ font-family: var(--font-interface);
4146
+ font-size: var(--font-ui-medium);
4147
+ }
4148
+ .kplex-form-option > label { margin: 0; color: var(--text-normal); text-align: start; }
4149
+ .kplex-form-option > select { width: 100%; max-width: none; margin: 0; }
4150
+ .kplex-modal .kplex-creation-completion-row { margin: 0; padding: 0; }
4151
+ .kplex-modal .kplex-add-related-footer { display: block; width: 100%; margin: 0; padding: 0; }
4152
+ .kplex-modal .kplex-add-related-form { gap: var(--kplex-form-gap); }
4153
+ .kplex-modal .kplex-add-related-form .kplex-form-option { margin: 0; }
4154
+ .kplex-modal .kplex-add-related-compose-row { grid-template-columns: minmax(0, 1fr); }
4155
+ .kplex-modal .kplex-add-related-action-area { justify-self: end; }
4156
+ .kplex-modal .kplex-create-folder-row { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
4157
+ .kplex-modal .kplex-create-folder-row .kplex-folder-path-input { width: 100%; max-width: none; }
4158
+ .kplex-react-field > label { font-size: var(--font-ui-medium); }
4159
+ .kplex-react-field > input, .kplex-react-field > .kplex-search-shell { width: 100%; min-width: 0; max-width: none; }
4160
+ .modal.kplex-modal .modal-content .kplex-form-actions,
4161
+ .modal.kplex-modal .modal-content .kplex-modal-action-row {
4162
+ display: flex;
4163
+ flex-direction: row;
4164
+ flex-wrap: wrap;
4165
+ align-items: center;
4166
+ gap: 12px 16px;
4167
+ margin-block: 20px 0;
4168
+ padding-block: 16px 0;
4169
+ border-top: var(--border-width) solid var(--background-modifier-border);
4170
+ }
4171
+ .kplex-form-actions > .setting-item-info { margin: 0; min-width: 0; flex: 1 1 180px; }
4172
+ .kplex-form-actions > .setting-item-info > .setting-item-name:empty,
4173
+ .kplex-form-actions > .setting-item-info > .setting-item-description:empty { display: none; }
4174
+ .kplex-form-actions > .setting-item-control { flex: 1 1 auto; margin-inline-start: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; }
4175
+ .kplex-modal button.kplex-icon-action,
4176
+ .kplex-modal .kplex-add-related-type-button,
4177
+ .kplex-modal .kplex-edit-selected-ontology {
4178
+ display: inline-flex;
4179
+ align-items: center;
4180
+ justify-content: center;
4181
+ flex: 0 0 auto;
4182
+ min-width: var(--kplex-control-height);
4183
+ width: var(--kplex-control-height);
4184
+ height: var(--kplex-control-height);
4185
+ padding: 8px;
4186
+ font-size: 0;
4187
+ }
4188
+ .kplex-modal .kplex-icon-action svg { width: 18px; height: 18px; flex: 0 0 18px; }
4189
+ .kplex-icon-action-label { display: none; }
4190
+ .kplex-modal .kplex-add-related-action-area,
4191
+ .kplex-modal .kplex-add-related-create-actions { height: auto; }
4192
+ .kplex-modal .kplex-add-related-create-actions { align-items: center; }
4193
+ .kplex-relationship-field-control { width: 100%; display: flex; align-items: center; gap: 8px; }
4194
+ .kplex-relationship-field-control > .kplex-add-related-role-select { flex: 0 1 160px; min-width: 90px; }
4195
+ .kplex-relationship-field-control > .kplex-add-related-ontology-search { flex: 1 1 160px; min-width: 0; max-width: none; }
4196
+ .kplex-import-modal .kplex-relationship-field-control { margin-block: 0 16px; }
4197
+ /* Obsidian's .dropdown supplies the complete skin and caret. The input remains editable;
4198
+ the transparent hit area opens suggestions without drawing a second boxed arrow. */
4199
+ .kplex-native-combobox { position: relative; }
4200
+ .kplex-native-combobox > input[type="text"] {
4201
+ height: 100%;
4202
+ width: 100%;
4203
+ min-width: 0;
4204
+ box-sizing: border-box;
4205
+ padding-block: 0;
4206
+ padding-inline: 24px 0;
4207
+ font: inherit;
4208
+ color: inherit;
4209
+ background: transparent;
4210
+ border: 0;
4211
+ box-shadow: none;
4212
+ }
4213
+ .kplex-native-combobox > input[type="text"]:focus { box-shadow: none; }
4214
+ .kplex-template-picker > input[type="text"] { padding-inline: 0 24px; }
4215
+ /* The search shell's horizontal flex basis must not become height in a stacked form field. */
4216
+ .kplex-drawing-template > .kplex-template-picker { flex: 0 0 auto; }
4217
+ .kplex-native-combobox:focus-within { box-shadow: 0 0 0 3px var(--background-modifier-border-focus); }
4218
+ .kplex-native-combobox .kplex-search-icon { top: 50%; transform: translateY(-50%); }
4219
+ .kplex-native-combobox > .kplex-fuzzy-disclosure {
4220
+ inset-block: 0;
4221
+ inset-inline-end: 0;
4222
+ width: var(--dropdown-padding-end, 2.4em);
4223
+ height: 100%;
4224
+ padding: 0;
4225
+ border: 0;
4226
+ border-radius: 0;
4227
+ background: transparent;
4228
+ box-shadow: none;
4229
+ }
4230
+ @media (max-width: 480px) {
4231
+ .kplex-form-option { grid-template-columns: minmax(0, 1fr); }
4232
+ .kplex-relationship-field-control { flex-wrap: wrap; }
4233
+ .kplex-relationship-field-control > .kplex-add-related-role-select { flex-basis: 100%; }
4234
+ }
4235
+ @media (pointer: coarse) {
4236
+ .kplex-modal { --kplex-control-height: 44px; }
4237
+ }
4238
+ .kplex-edge-source-actions { flex-wrap: wrap; }.kplex-edge-source-actions .kplex-edge-source-action { max-width: 100%; height: auto; white-space: normal; overflow-wrap: anywhere; text-align: start; }
4239
+ .kplex-edge-source-actions .kplex-edge-source-action svg { flex: 0 0 14px; }
4240
+ .kplex-relationship-selection { width: 100%; min-width: 0; }
4241
+ .kplex-relationship-selection-detail { margin-top: var(--size-4-2); white-space: pre-line; overflow-wrap: anywhere; }
4242
+ .modal.kplex-modal .kplex-relationship-selection-detail { font-size: var(--font-ui-smaller, var(--font-ui-small)); }
4243
+ /* Bound label width so larger native UI fonts keep enough room for the selector. */
4244
+ .modal.kplex-modal .kplex-form-select-row { display: grid; grid-template-columns: fit-content(calc(40% - var(--kplex-control-gap))) minmax(0, 1fr); align-items: center; }
4245
+ .kplex-form-select-row > .setting-item-info { margin: 0; max-width: 200px; min-width: 0; overflow-wrap: anywhere; }
4246
+ .kplex-form-select-row > .setting-item-control { width: 100%; }
4247
+ .kplex-form-select-row > .setting-item-control > select { width: 100%; max-width: none; }
4248
+ .kplex-form-select-row > .setting-item-description { grid-column: 1 / -1; }
4249
+ .kplex-form-select-row > .setting-item-description:empty { display: none; }
4250
+ .kplex-modal button.kplex-icon-action { gap: 0; }
4251
+ @media (max-width: 420px) {
4252
+ .modal.kplex-modal .kplex-form-select-row { grid-template-columns: minmax(0, 1fr); }
4253
+ .kplex-form-select-row > .setting-item-info { max-width: none; }
4254
+ }
4255
+ /* Native Setting markup owns colors and finite choices; only their group geometry differs. */
4256
+ .kplex-style-color-row > .setting-item-control { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--size-4-2); }
4257
+ .kplex-style-color-row button { flex: 1 1 0; min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
4258
+ .kplex-style-row .kplex-number-value { flex: 0 0 7.5em; min-width: 0; white-space: nowrap; }
4259
+ .kplex-style-row .setting-item-control > input[type="range"] { flex: 1 1 0; min-width: 0; }
4260
+ .kplex-form-options .setting-item:not(.kplex-form-field) > .setting-item-info { flex: 1 1 50%; min-width: 0; margin: 0; }
4261
+ .kplex-form-options .setting-item:not(.kplex-form-field) > .setting-item-control { flex: 1 1 50%; min-width: 0; }
4262
+ .kplex-form-options .setting-item-control > select { width: 100%; max-width: none; }
4263
+ .kplex-form-disclosure { margin-block-end: var(--kplex-form-gap, var(--size-4-4)); }
4264
+ @media (max-width: 420px) {
4265
+ .kplex-form-options .setting-item:not(.kplex-form-field) { flex-wrap: wrap; }
4266
+ .kplex-form-options .setting-item:not(.kplex-form-field) > .setting-item-info,
4267
+ .kplex-form-options .setting-item:not(.kplex-form-field) > .setting-item-control { flex-basis: 100%; }
4268
+ }
4269
+
4270
+ /* Compact authored rows keep a short visible label and all remaining width for the native input. */
4271
+ .kplex-modal .kplex-form-inline {
4272
+ display: grid;
4273
+ grid-template-columns: minmax(0, 5em) minmax(0, 1fr);
4274
+ align-items: center;
4275
+ gap: var(--kplex-control-gap);
4276
+ min-width: 0;
4277
+ width: 100%;
4278
+ }
4279
+ .kplex-form-inline > label { margin: 0; overflow-wrap: anywhere; }
4280
+ .kplex-modal .kplex-form-inline > :not(label):not(.kplex-field-actions) { min-width: 0; width: 100%; max-width: none; box-sizing: border-box; }
4281
+ .kplex-modal .kplex-form-inline.has-actions { grid-template-columns: minmax(0, 5em) minmax(0, 1fr) auto; }
4282
+ .kplex-field-actions { display: flex; align-items: center; justify-content: flex-end; min-width: 0; gap: var(--kplex-control-gap); }
4283
+ .kplex-field-actions .kplex-add-related-action-area { min-width: 0; height: auto; }
4284
+ .kplex-creation-types { container-type: inline-size; }
4285
+ .kplex-creation-type-panel { padding: 12px; }
4286
+ .kplex-creation-type-actions { display: flex; justify-content: flex-end; }
4287
+ .kplex-creation-status { margin-top: 8px; color: var(--text-muted); font-size: var(--font-ui-small); overflow-wrap: anywhere; }
4288
+ .kplex-creation-status .kplex-add-related-create-hint { margin-top: 0; }
4289
+ @container (max-width: 360px) {
4290
+ .kplex-modal .kplex-drawing-template.has-actions { grid-template-columns: minmax(0, 1fr) auto; }
4291
+ .kplex-drawing-template.has-actions > label { grid-column: 1 / -1; }
4292
+ .kplex-drawing-template.has-actions > .kplex-template-picker { grid-column: 1; }
4293
+ .kplex-drawing-template.has-actions > .kplex-field-actions { grid-column: 2; }
4294
+ }
4295
+ .kplex-publish-modal {
4296
+ width: min(760px, 94vw);
4297
+ }
4298
+
4299
+ .modal.kplex-publish-modal .modal-content > .kplex-form-actions {
4300
+ flex: 0 0 auto;
4301
+ margin-block-start: var(--size-4-2);
4302
+ padding-block-start: var(--size-4-2);
4303
+ }
4304
+
4305
+ .kplex-publish-output-actions[hidden] { display: none; }
4306
+
4307
+ .kplex-publish-progress {
4308
+ display: block;
4309
+ width: min(14rem, 100%);
4310
+ margin-block-start: var(--size-4-1);
4311
+ accent-color: var(--interactive-accent);
4312
+ }
4313
+
4314
+ .kplex-publish-rules .setting-item-description code {
4315
+ display: block;
4316
+ margin-block-start: var(--size-4-1);
4317
+ }
4318
+
4319
+ .kplex-publish-fields,
4320
+ .kplex-publish-review {
4321
+ min-width: 0;
4322
+ overflow-wrap: anywhere;
4323
+ }
4324
+
4325
+ .kplex-publish-fields > h3,
4326
+ .kplex-publish-review > h3,
4327
+ .kplex-publish-rules > h3,
4328
+ .kplex-publish-properties > h3 {
4329
+ margin-block: 12px 4px;
4330
+ }
4331
+
4332
+ .kplex-publish-choice.dropdown { width: 100%; min-width: 0; max-width: none; }
4333
+ .kplex-publish-choice > input[type="text"] { padding-inline: 0 var(--dropdown-padding-end, 2.4em); }
4334
+ .kplex-publish-fields .kplex-form-select-row > .setting-item-control > div { flex: 1 1 100%; min-width: 0; }
4335
+ .kplex-publish-setup-actions > .setting-item-control { flex-wrap: wrap; }
4336
+ .kplex-publish-selected {
4337
+ margin-block-end: var(--kplex-form-gap);
4338
+ margin-inline-start: var(--size-4-3);
4339
+ padding: var(--size-4-2) var(--size-4-3);
4340
+ border: var(--border-width) solid var(--background-modifier-border);
4341
+ border-radius: var(--radius-s);
4342
+ }
4343
+ .modal.kplex-publish-modal .kplex-publish-selected > .setting-item { margin-block-end: 0; }
4344
+ .modal.kplex-publish-modal .kplex-publish-selected > .setting-item + .setting-item {
4345
+ margin-block-start: var(--size-4-2);
4346
+ padding-block-start: var(--size-4-2);
4347
+ border-block-start: var(--border-width) solid var(--background-modifier-border);
4348
+ }
4349
+ .kplex-publish-options {
4350
+ border-block-start: var(--border-width) solid var(--background-modifier-border);
4351
+ padding-block-start: var(--kplex-form-gap);
4352
+ }
4353
+
4354
+ .kplex-publish-list {
4355
+ margin-block: 8px;
4356
+ }
4357
+
4358
+ .kplex-publish-list summary {
4359
+ cursor: pointer;
4360
+ }
4361
+
4362
+ .kplex-publish-list li {
4363
+ overflow-wrap: anywhere;
4364
+ }
4365
+
4366
+ .hover-popover.kplex-publish-hover {
4367
+ z-index: max(var(--layer-popover, 30), calc(var(--layer-modal, 50) + 1));
4368
+ }
4369
+
4370
+ .modal.kplex-publish-modal .modal-content [hidden] {
4371
+ display: none;
4372
+ }
4373
+
4374
+ }
4375
+ .kplex-publication-demo { margin: 0; background: #f5f7fa; }
4376
+ .kplex-publication-licenses {
4377
+ padding: .5rem 1rem;
4378
+ color: CanvasText;
4379
+ background: Canvas;
4380
+ font: .875rem/1.5 system-ui, sans-serif;
4381
+ }
4382
+ .kplex-publication-licenses pre { white-space: pre-wrap; overflow-wrap: anywhere; }
4383
+ .kplex-publication {
4384
+ --background-primary: #f5f7fa;
4385
+ --background-modifier-border: #a7b5bf;
4386
+ --text-normal: #152934;
4387
+ --text-muted: #47606d;
4388
+ --interactive-accent: #207364;
4389
+ --kplex-publication-panel: #fff;
4390
+ --kplex-publication-link: #6f868c;
4391
+ --kplex-publication-card: #fff;
4392
+ --kplex-publication-center: #164f47;
4393
+ --kplex-publication-center-text: #fff;
4394
+ --shadow-s: 0 2px 6px #1e374120;
4395
+ display: grid;
4396
+ grid-template-rows: auto minmax(18rem, 1fr) auto;
4397
+ min-height: 29rem;
4398
+ color: var(--text-normal);
4399
+ background: var(--background-primary);
4400
+ font: 1rem/1.5 system-ui, sans-serif;
4401
+ }
4402
+ .kplex-publication-demo .kplex-publication { min-height: 100vh; min-height: 100dvh; }
4403
+ .kplex-publication-header, .kplex-publication-note {
4404
+ background: var(--kplex-publication-panel);
4405
+ padding: .8rem clamp(1rem, 4vw, 3rem);
4406
+ }
4407
+ .kplex-publication-header {
4408
+ display: flex;
4409
+ align-items: center;
4410
+ justify-content: space-between;
4411
+ gap: .65rem 1rem;
4412
+ flex-wrap: wrap;
4413
+ border-bottom: 1px solid var(--background-modifier-border);
4414
+ }
4415
+ .kplex-publication-header h1, .kplex-publication-note h2 { margin: 0; font-size: 1.05rem; }
4416
+ .kplex-publication-header span { font-size: .85rem; color: var(--text-muted); }
4417
+ .kplex-publication-controls { display: flex; flex-wrap: wrap; gap: .35rem; }
4418
+ .kplex-publication-controls button {
4419
+ min-width: 2.75rem;
4420
+ min-height: 2.75rem;
4421
+ padding: .35rem .6rem;
4422
+ border: 1px solid var(--background-modifier-border);
4423
+ border-radius: .45rem;
4424
+ background: var(--kplex-publication-panel);
4425
+ color: inherit;
4426
+ font: inherit;
4427
+ cursor: pointer;
4428
+ }
4429
+ .kplex-publication-controls button:disabled { opacity: .5; cursor: default; }
4430
+ .kplex-publication-controls button[aria-pressed="true"] { background: var(--background-primary); border-color: var(--interactive-accent); }
4431
+ .kplex-publication :focus-visible { outline: 2px solid var(--interactive-accent); outline-offset: 3px; }
4432
+ .kplex-publication-viewport {
4433
+ overflow: hidden;
4434
+ position: relative;
4435
+ color: var(--text-muted);
4436
+ background-image: radial-gradient(var(--background-modifier-border) .7px, transparent .7px);
4437
+ background-size: 20px 20px;
4438
+ touch-action: none;
4439
+ user-select: none;
4440
+ cursor: grab;
4441
+ }
4442
+ .kplex-publication-viewport:active { cursor: grabbing; }
4443
+ .kplex-publication .kplex-camera { left: 50%; top: 50%; }
4444
+ .kplex-publication-exits { position: absolute; inset: 0; pointer-events: none; }
4445
+ .kplex-publication .kplex-publication-sibling-scroll { touch-action: pan-y; scrollbar-color: var(--background-modifier-border) transparent; }
4446
+ .kplex-publication .kplex-publication-sibling-scroll:focus-visible { outline-offset: -2px; }
4447
+ .kplex-publication .kplex-thought {
4448
+ background: var(--kplex-publication-card);
4449
+ color: var(--text-normal);
4450
+ border: 1px solid var(--background-modifier-border);
4451
+ border-radius: 12px;
4452
+ font-weight: 600;
4453
+ }
4454
+ .kplex-publication .kplex-role-center {
4455
+ background: var(--kplex-publication-center);
4456
+ color: var(--kplex-publication-center-text);
4457
+ border-color: transparent;
4458
+ border-radius: 18px;
4459
+ }
4460
+ .kplex-publication .kplex-gate { pointer-events: none; }
4461
+ .kplex-publication-note { border-top: 1px solid var(--background-modifier-border); }
4462
+ .kplex-publication-note p { color: var(--text-muted); margin: .3rem 0 0; max-width: 70ch; }
4463
+ .kplex-publication-opening { margin: 1.2rem; font: 1rem/1.5 system-ui, sans-serif; }
4464
+ .kplex-publication-production {
4465
+ --background-primary: var(--kplex-published-light-background-primary, #f5f7fa);
4466
+ --background-modifier-border: var(--kplex-published-light-background-modifier-border, #a7b5bf);
4467
+ --text-normal: var(--kplex-published-light-text-normal, #152934);
4468
+ --text-muted: var(--kplex-published-light-text-muted, #47606d);
4469
+ --interactive-accent: var(--kplex-published-light-interactive-accent, #207364);
4470
+ --kplex-publication-panel: var(--kplex-published-light-kplex-publication-panel, #fff);
4471
+ --kplex-publication-link: var(--kplex-published-light-kplex-publication-link, #6f868c);
4472
+ --background-primary-alt: var(--kplex-publication-panel);
4473
+ --background-secondary: var(--kplex-publication-panel);
4474
+ --background-secondary-alt: var(--background-primary);
4475
+ --background-modifier-hover: var(--background-primary);
4476
+ --text-accent: var(--interactive-accent);
4477
+ --text-faint: var(--text-muted);
4478
+ --input-height: 2.75rem;
4479
+ position: relative;
4480
+ overflow-x: clip;
4481
+ grid-template-rows: auto minmax(24rem, 1fr) auto;
4482
+ }
4483
+ .kplex-publication-demo .kplex-publication-production { height: 100vh; height: 100dvh; grid-template-rows: auto minmax(0, 1fr) auto; }
4484
+ .kplex-publication-production .kplex-publication-header { justify-content: flex-start; padding: .5rem clamp(.75rem, 2vw, 1.5rem); }
4485
+ .kplex-publication-production .kplex-publication-header h1 { max-width: min(28rem, 65vw); overflow-wrap: anywhere; }
4486
+ .kplex-publication-tools { display: flex; gap: .5rem 1rem; align-items: center; flex: 1 1 26rem; min-width: 0; flex-wrap: wrap; }
4487
+ .kplex-publication-tools .kplex-search-shell { flex: 1 1 12rem; min-width: min(100%, 10rem); max-width: none; }
4488
+ .kplex-publication-tools .kplex-search-shell input { width: 100%; }
4489
+ .kplex-publication-production .kplex-search-results { max-width: calc(100% - 1rem); }
4490
+ .kplex-publication-tools input {
4491
+ min-width: 0; max-width: 100%; min-height: var(--input-height); box-sizing: border-box;
4492
+ border: 1px solid var(--background-modifier-border); border-radius: .45rem;
4493
+ background: var(--kplex-publication-panel); color: inherit; font: inherit; padding: .3rem .55rem;
4494
+ }
4495
+ .kplex-publication-tools input::placeholder { color: var(--text-muted); }
4496
+ .kplex-publication-tools button, .kplex-publication-note button, .kplex-publication-opening button {
4497
+ min-height: 2.75rem; border: 1px solid var(--background-modifier-border); border-radius: .45rem;
4498
+ background: var(--kplex-publication-panel); color: inherit; font: inherit; cursor: pointer; padding: .35rem .6rem;
4499
+ }
4500
+ .kplex-publication-tools button[aria-pressed="true"] { background: var(--background-primary); border-color: var(--interactive-accent); }
4501
+ .kplex-publication-search-options { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
4502
+ .kplex-publication-address { position: relative; margin: 0; flex: 0 1 clamp(16rem, 56%, 24rem); min-width: min(100%, 16rem); }
4503
+ .kplex-publication-address .kplex-form-inline { display: grid; grid-template-columns: auto minmax(6rem, 1fr) auto; gap: .45rem; align-items: center; }
4504
+ .kplex-publication-address .kplex-form-inline label { font-size: .9rem; }
4505
+ .kplex-publication-address input { width: 100%; }
4506
+ .kplex-publication-address-matches {
4507
+ position: absolute; right: 0; top: 100%; z-index: 5; max-width: 100%; max-height: min(20rem, 52vh); overflow: auto;
4508
+ padding: .65rem; box-sizing: border-box; background: var(--kplex-publication-panel); color: var(--text-normal);
4509
+ border: 1px solid var(--background-modifier-border); border-radius: .45rem; box-shadow: var(--shadow-s);
4510
+ }
4511
+ .kplex-publication-address-matches ul { list-style: none; padding: 0; }
4512
+ .kplex-publication-address-matches button { max-width: 100%; overflow-wrap: anywhere; text-align: start; }
4513
+ .kplex-publication-trail {
4514
+ display: flex; align-items: center; gap: .65rem; min-width: 0;
4515
+ background: var(--background-secondary); font-size: .875rem;
4516
+ }
4517
+ .kplex-publication-pins { flex: 1 1 100%; }
4518
+ .kplex-publication-history { padding: .25rem clamp(.75rem, 2vw, 1.5rem); border-top: 1px solid var(--background-modifier-border); }
4519
+ .kplex-publication-trail > span { flex: none; color: var(--text-muted); }
4520
+ .kplex-publication-trail ol { display: flex; align-items: center; gap: .3rem; min-width: 0; margin: 0; padding: .15rem 0; overflow-x: auto; list-style: none; }
4521
+ .kplex-publication-trail li { flex: none; min-width: 0; }
4522
+ .kplex-publication-trail a {
4523
+ display: block; max-width: min(18rem, 55vw); padding: .25rem .55rem;
4524
+ border: 1px solid var(--background-modifier-border); border-radius: .35rem; color: inherit;
4525
+ text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
4526
+ }
4527
+ .kplex-publication-trail a:hover, .kplex-publication-trail a[aria-current] { border-color: var(--interactive-accent); }
4528
+ .kplex-publication-address-menu {
4529
+ z-index: 90; box-sizing: border-box; padding: .3rem; overflow: auto;
4530
+ background: var(--background-secondary); color: var(--text-normal);
4531
+ border: 1px solid var(--background-modifier-border); border-radius: .45rem; box-shadow: var(--shadow-s);
4532
+ }
4533
+ .kplex-publication-address-menu :is(button,input) {
4534
+ box-sizing: border-box; width: 100%; min-height: 2rem; padding: .25rem .5rem;
4535
+ color: inherit; background: var(--background-primary); font: inherit; border: 1px solid var(--background-modifier-border); border-radius: .3rem;
4536
+ }
4537
+ .kplex-publication-address-menu button { text-align: start; cursor: pointer; }
4538
+ .kplex-publication-address-menu button + button { margin-block-start: .25rem; }
4539
+ .kplex-publication-address-menu button:disabled { opacity: .6; cursor: default; }
4540
+ .kplex-publication-address-menu p { margin: .25rem .4rem; color: var(--text-muted); font-size: .9em; }
4541
+ .kplex-publication-workspace {
4542
+ display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); min-width: 0; min-height: 0;
4543
+ }
4544
+ .kplex-publication-workspace[data-sidecar-dock="right"] {
4545
+ grid-template-columns: minmax(0, 1fr) var(--kplex-publication-divider-size) var(--kplex-publication-sidecar-size);
4546
+ }
4547
+ .kplex-publication-workspace[data-sidecar-dock="bottom"] {
4548
+ grid-template-rows: minmax(0, 1fr) var(--kplex-publication-divider-size) var(--kplex-publication-sidecar-size);
4549
+ }
4550
+ .kplex-publication-divider {
4551
+ display: grid; place-items: center; background: var(--kplex-publication-panel);
4552
+ cursor: col-resize; touch-action: none; user-select: none;
4553
+ }
4554
+ .kplex-publication-divider::before {
4555
+ content: ""; width: 2px; height: 2rem; border-radius: 2px; background: var(--background-modifier-border);
4556
+ }
4557
+ .kplex-publication-divider:focus-visible { outline-offset: -2px; }
4558
+ .kplex-publication-divider:is(:hover, :active, :focus-visible)::before { background: var(--interactive-accent); }
4559
+ .kplex-publication-divider[aria-orientation="horizontal"] { cursor: row-resize; }
4560
+ .kplex-publication-divider[aria-orientation="horizontal"]::before { width: 2rem; height: 2px; }
4561
+ .kplex-publication-canvas { position: relative; display: grid; min-width: 0; min-height: 0; }
4562
+ .kplex-publication-camera-actions { position: absolute; bottom: .75rem; left: .75rem; }
4563
+ .kplex-publication-status { position: absolute; top: .6rem; left: .75rem; right: .75rem; pointer-events: none; }
4564
+ .kplex-publication-status p { display: table; margin: 0 0 .3rem; padding: .2rem .45rem; border-radius: .3rem; background: var(--kplex-publication-panel); }
4565
+ .kplex-publication-production .kplex-publication-note {
4566
+ min-width: 0; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 1rem; border: 0;
4567
+ }
4568
+ .kplex-publication-sidecar-heading {
4569
+ display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-start; justify-content: space-between; margin-bottom: .65rem;
4570
+ }
4571
+ .kplex-publication-sidecar-heading h2 { flex: 1 1 9rem; min-width: 0; font-size: 1.25rem; overflow-wrap: anywhere; }
4572
+ .kplex-publication-sidecar-actions { display: flex; gap: .35rem; flex-wrap: wrap; }
4573
+ .kplex-publication-sidecar-actions button:last-child { min-width: 2.75rem; }
4574
+ .kplex-publication-note-content { min-width: 0; overflow-wrap: anywhere; }
4575
+ .kplex-publication-note-content :is(img, svg, audio, video) { max-width: 100%; }
4576
+ .kplex-publication-note-content :is(img, svg, video) { height: auto; }
4577
+ .kplex-publication-note-content figure[data-publication-drawing] { margin-inline: 0; }
4578
+ .kplex-publication-note-content figure[data-publication-width] > img { width: var(--kplex-published-drawing-width); }
4579
+ .kplex-publication-note-content figure[data-publication-width] > svg { max-width: min(100%, var(--kplex-published-drawing-width)); }
4580
+ .kplex-publication-note-content figure[data-publication-width][data-publication-height] > :is(img, svg) {
4581
+ min-height: var(--kplex-published-drawing-height);
4582
+ }
4583
+ .kplex-publication-note-content figure[data-publication-height]:not([data-publication-width]) > :is(img, svg) {
4584
+ max-height: var(--kplex-published-drawing-height);
4585
+ }
4586
+ .kplex-publication-note-content img:not([src]) { display: none; }
4587
+ .kplex-publication-note-content a { color: var(--interactive-accent); }
4588
+ .kplex-publication-note-content svg a { cursor: pointer; }
4589
+ .kplex-publication-note-content pre { overflow: auto; padding: .6rem; background: var(--background-primary); }
4590
+ .kplex-publication-note-content table { display: block; overflow: auto; border-collapse: collapse; }
4591
+ .kplex-publication-note-content :is(td, th) { padding: .2rem .45rem; border: 1px solid var(--background-modifier-border); }
4592
+ .kplex-publication-note-content :is(blockquote, [data-callout]) { padding: .2rem .65rem; margin-inline: 0; border-inline-start: .2rem solid var(--interactive-accent); }
4593
+ @media (prefers-color-scheme: dark) {
4594
+ .kplex-publication-demo { background: #141f25; }
4595
+ .kplex-publication {
4596
+ --background-primary: #141f25;
4597
+ --background-modifier-border: #526c74;
4598
+ --text-normal: #edf5f6;
4599
+ --text-muted: #bdd0d4;
4600
+ --interactive-accent: #78cdb8;
4601
+ --kplex-publication-panel: #1b2b32;
4602
+ --kplex-publication-link: #89a6ac;
4603
+ --kplex-publication-card: #223940;
4604
+ --kplex-publication-center: #8ed9c4;
4605
+ --kplex-publication-center-text: #143028;
4606
+ }
4607
+ .kplex-publication-production {
4608
+ --background-primary: var(--kplex-published-dark-background-primary, #141f25);
4609
+ --background-modifier-border: var(--kplex-published-dark-background-modifier-border, #526c74);
4610
+ --text-normal: var(--kplex-published-dark-text-normal, #edf5f6);
4611
+ --text-muted: var(--kplex-published-dark-text-muted, #bdd0d4);
4612
+ --interactive-accent: var(--kplex-published-dark-interactive-accent, #78cdb8);
4613
+ --kplex-publication-panel: var(--kplex-published-dark-kplex-publication-panel, #1b2b32);
4614
+ --kplex-publication-link: var(--kplex-published-dark-kplex-publication-link, #89a6ac);
4615
+ }
4616
+ }
4617
+ @media (max-width: 46rem) {
4618
+ .kplex-publication-demo .kplex-publication-production { grid-template-rows: auto minmax(20rem, 1fr) auto; }
4619
+ .kplex-publication-tools { flex-basis: 100%; }
4620
+ .kplex-publication-address { flex-grow: 1; }
4621
+ }
4622
+
4623
+ /* Obsidian-inspired shell and Markdown styles. A publication may carry a literal author theme. */
4624
+ .kplex-publication-production {
4625
+ color-scheme: light dark;
4626
+ --background-primary: var(--kplex-published-author-background-primary, var(--kplex-reader-legacy-background-primary, light-dark(#ffffff, #1e1e1e)));
4627
+ --background-modifier-border: var(--kplex-published-author-background-modifier-border, var(--kplex-reader-legacy-background-modifier-border, light-dark(#e4e4e4, #373737)));
4628
+ --text-normal: var(--kplex-published-author-text-normal, var(--kplex-reader-legacy-text-normal, light-dark(#222222, #dadada)));
4629
+ --text-muted: var(--kplex-published-author-text-muted, var(--kplex-reader-legacy-text-muted, light-dark(#575757, #b3b3b3)));
4630
+ --interactive-accent: var(--kplex-published-author-interactive-accent, var(--kplex-reader-legacy-interactive-accent, light-dark(#7852ee, #a882ff)));
4631
+ --kplex-publication-panel: var(--kplex-published-author-kplex-publication-panel, var(--kplex-reader-legacy-kplex-publication-panel, light-dark(#f6f6f6, #262626)));
4632
+ --kplex-publication-link: var(--kplex-published-author-kplex-publication-link, var(--kplex-reader-legacy-kplex-publication-link, light-dark(#8b8b8b, #888888)));
4633
+ --background-secondary: var(--kplex-published-author-background-secondary, var(--kplex-publication-panel));
4634
+ --background-modifier-hover: var(--kplex-published-author-background-modifier-hover, light-dark(#ebebeb, #353535));
4635
+ --text-faint: var(--kplex-published-author-text-faint, var(--text-muted));
4636
+ --interactive-normal: var(--kplex-published-author-interactive-normal, var(--background-primary));
4637
+ --interactive-hover: var(--kplex-published-author-interactive-hover, var(--background-modifier-hover));
4638
+ --text-on-accent: var(--kplex-published-author-text-on-accent, #ffffff);
4639
+ --kplex-publication-card: var(--background-primary);
4640
+ --kplex-publication-center: var(--interactive-accent);
4641
+ --kplex-publication-center-text: var(--text-on-accent);
4642
+ --kplex-reader-font-interface: var(--kplex-published-author-font-interface, system-ui);
4643
+ --kplex-reader-font-text: var(--kplex-published-author-font-text, system-ui);
4644
+ --kplex-reader-font-monospace: var(--kplex-published-author-font-monospace, ui-monospace);
4645
+ --kplex-reader-paragraph-spacing: var(--kplex-published-author-p-spacing, 1em);
4646
+ --kplex-reader-link: var(--kplex-published-author-link-color, var(--interactive-accent));
4647
+ --kplex-reader-code-bg: var(--kplex-published-author-code-background, var(--background-secondary));
4648
+ --kplex-reader-code-color: var(--kplex-published-author-code-normal, var(--text-normal));
4649
+ font-family: var(--kplex-reader-font-interface), system-ui, sans-serif;
4650
+ font-size: var(--kplex-published-author-font-ui-medium, 14px);
4651
+ }
4652
+ @media (prefers-color-scheme: light) {
4653
+ .kplex-publication-production {
4654
+ --kplex-reader-legacy-background-primary: var(--kplex-published-light-background-primary);
4655
+ --kplex-reader-legacy-background-modifier-border: var(--kplex-published-light-background-modifier-border);
4656
+ --kplex-reader-legacy-text-normal: var(--kplex-published-light-text-normal);
4657
+ --kplex-reader-legacy-text-muted: var(--kplex-published-light-text-muted);
4658
+ --kplex-reader-legacy-interactive-accent: var(--kplex-published-light-interactive-accent);
4659
+ --kplex-reader-legacy-kplex-publication-panel: var(--kplex-published-light-kplex-publication-panel);
4660
+ --kplex-reader-legacy-kplex-publication-link: var(--kplex-published-light-kplex-publication-link);
4661
+ }
4662
+ }
4663
+ @media (prefers-color-scheme: dark) {
4664
+ .kplex-publication-production {
4665
+ --kplex-reader-legacy-background-primary: var(--kplex-published-dark-background-primary);
4666
+ --kplex-reader-legacy-background-modifier-border: var(--kplex-published-dark-background-modifier-border);
4667
+ --kplex-reader-legacy-text-normal: var(--kplex-published-dark-text-normal);
4668
+ --kplex-reader-legacy-text-muted: var(--kplex-published-dark-text-muted);
4669
+ --kplex-reader-legacy-interactive-accent: var(--kplex-published-dark-interactive-accent);
4670
+ --kplex-reader-legacy-kplex-publication-panel: var(--kplex-published-dark-kplex-publication-panel);
4671
+ --kplex-reader-legacy-kplex-publication-link: var(--kplex-published-dark-kplex-publication-link);
4672
+ }
4673
+ }
4674
+
4675
+ .kplex-publication-production .kplex-publication-viewport {
4676
+ background-color: var(--kplex-published-author-kplex-publication-canvas, var(--background-primary));
4677
+ background-image: none;
4678
+ }
4679
+ .kplex-publication-production .kplex-publication-header {
4680
+ background: var(--background-secondary);
4681
+ }
4682
+ .kplex-publication-production .kplex-publication-tools input {
4683
+ border-radius: var(--kplex-published-author-input-radius, .35rem);
4684
+ background: var(--background-primary);
4685
+ }
4686
+ .kplex-publication-production :is(.kplex-publication-tools, .kplex-publication-note, .kplex-publication-controls) button {
4687
+ border-radius: var(--kplex-published-author-button-radius, .35rem);
4688
+ background: var(--interactive-normal);
4689
+ }
4690
+ .kplex-publication-production :is(.kplex-publication-tools, .kplex-publication-note, .kplex-publication-controls) button:hover:not(:disabled) {
4691
+ background: var(--interactive-hover);
4692
+ }
4693
+ .kplex-publication-production .kplex-publication-tools button[aria-pressed="true"] {
4694
+ background: var(--interactive-accent);
4695
+ color: var(--text-on-accent);
4696
+ }
4697
+ .kplex-publication-production .kplex-publication-note {
4698
+ background: var(--background-primary);
4699
+ }
4700
+ .kplex-publication-production .kplex-publication-sidecar-heading h2 {
4701
+ color: var(--kplex-published-author-inline-title-color, var(--text-normal));
4702
+ font-family: var(--kplex-published-author-inline-title-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4703
+ font-size: var(--kplex-published-author-inline-title-size, 1.5em);
4704
+ font-weight: var(--kplex-published-author-inline-title-weight, 700);
4705
+ line-height: 1.25;
4706
+ }
4707
+ .kplex-publication-production .kplex-publication-note-content {
4708
+ color: var(--text-normal);
4709
+ font-family: var(--kplex-reader-font-text), system-ui, sans-serif;
4710
+ font-size: var(--kplex-published-author-font-text-size, 16px);
4711
+ line-height: var(--kplex-published-author-line-height-normal, 1.5);
4712
+ }
4713
+ .kplex-publication-production .kplex-publication-note-content p {
4714
+ color: inherit;
4715
+ margin: 0 0 var(--kplex-reader-paragraph-spacing);
4716
+ max-width: none;
4717
+ }
4718
+ .kplex-publication-production .kplex-publication-note-content :is(h1, h2, h3, h4, h5, h6) {
4719
+ margin: var(--kplex-published-author-heading-spacing, 1.3em) 0 .45em;
4720
+ }
4721
+ .kplex-publication-production .kplex-publication-note-content > :first-child { margin-block-start: 0; }
4722
+ .kplex-publication-production .kplex-publication-note-content h1 {
4723
+ font: var(--kplex-published-author-h1-style, normal) var(--kplex-published-author-h1-weight, 700) var(--kplex-published-author-h1-size, 1.802em)/var(--kplex-published-author-h1-line-height, 1.3) var(--kplex-published-author-h1-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4724
+ color: var(--kplex-published-author-h1-color, var(--text-normal));
4725
+ }
4726
+ .kplex-publication-production .kplex-publication-note-content h2 {
4727
+ font: var(--kplex-published-author-h2-style, normal) var(--kplex-published-author-h2-weight, 700) var(--kplex-published-author-h2-size, 1.602em)/var(--kplex-published-author-h2-line-height, 1.3) var(--kplex-published-author-h2-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4728
+ color: var(--kplex-published-author-h2-color, var(--text-normal));
4729
+ }
4730
+ .kplex-publication-production .kplex-publication-note-content h3 {
4731
+ font: var(--kplex-published-author-h3-style, normal) var(--kplex-published-author-h3-weight, 600) var(--kplex-published-author-h3-size, 1.424em)/var(--kplex-published-author-h3-line-height, 1.3) var(--kplex-published-author-h3-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4732
+ color: var(--kplex-published-author-h3-color, var(--text-normal));
4733
+ }
4734
+ .kplex-publication-production .kplex-publication-note-content h4 {
4735
+ font: var(--kplex-published-author-h4-style, normal) var(--kplex-published-author-h4-weight, 600) var(--kplex-published-author-h4-size, 1.266em)/var(--kplex-published-author-h4-line-height, 1.3) var(--kplex-published-author-h4-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4736
+ color: var(--kplex-published-author-h4-color, var(--text-normal));
4737
+ }
4738
+ .kplex-publication-production .kplex-publication-note-content h5 {
4739
+ font: var(--kplex-published-author-h5-style, normal) var(--kplex-published-author-h5-weight, 600) var(--kplex-published-author-h5-size, 1.125em)/var(--kplex-published-author-h5-line-height, 1.3) var(--kplex-published-author-h5-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4740
+ color: var(--kplex-published-author-h5-color, var(--text-normal));
4741
+ }
4742
+ .kplex-publication-production .kplex-publication-note-content h6 {
4743
+ font: var(--kplex-published-author-h6-style, normal) var(--kplex-published-author-h6-weight, 600) var(--kplex-published-author-h6-size, 1em)/var(--kplex-published-author-h6-line-height, 1.3) var(--kplex-published-author-h6-font, var(--kplex-reader-font-text)), system-ui, sans-serif;
4744
+ color: var(--kplex-published-author-h6-color, var(--text-normal));
4745
+ }
4746
+ .kplex-publication-production .kplex-publication-note-content a { color: var(--kplex-reader-link); }
4747
+ .kplex-publication-production .kplex-publication-note-content a[href^="http"] {
4748
+ color: var(--kplex-published-author-link-external-color, var(--kplex-reader-link));
4749
+ }
4750
+ .kplex-publication-production .kplex-publication-note-content a:hover {
4751
+ color: var(--kplex-published-author-link-color-hover, var(--kplex-reader-link));
4752
+ }
4753
+ .kplex-publication-production .kplex-publication-note-content :is(code, pre) {
4754
+ background: var(--kplex-reader-code-bg);
4755
+ color: var(--kplex-reader-code-color);
4756
+ border-radius: .25em;
4757
+ font-family: var(--kplex-reader-font-monospace), ui-monospace, monospace;
4758
+ font-size: .9em;
4759
+ }
4760
+ .kplex-publication-production .kplex-publication-note-content code { padding: .1em .25em; }
4761
+ .kplex-publication-production .kplex-publication-note-content pre { padding: .85em; }
4762
+ .kplex-publication-production .kplex-publication-note-content pre code { padding: 0; font-size: 1em; }
4763
+ .kplex-publication-production .kplex-publication-note-content mark {
4764
+ background: var(--kplex-published-author-text-highlight-bg, #fff3a3);
4765
+ color: inherit;
4766
+ }
4767
+ .kplex-publication-production .kplex-publication-note-content hr {
4768
+ border: 0;
4769
+ border-top: 1px solid var(--background-modifier-border);
4770
+ }
4771
+ .kplex-publication-production .kplex-publication-note-content :is(td, th) {
4772
+ border-color: var(--kplex-published-author-table-border-color, var(--background-modifier-border));
4773
+ padding: .35em .7em;
4774
+ }
4775
+ .kplex-publication-production .kplex-publication-note-content th {
4776
+ background: var(--kplex-published-author-table-header-background, var(--background-secondary));
4777
+ }
4778
+ .kplex-publication-production .kplex-publication-note-content blockquote {
4779
+ border-inline-start-color: var(--kplex-published-author-blockquote-border-color, var(--interactive-accent));
4780
+ color: var(--kplex-published-author-blockquote-color, var(--text-muted));
4781
+ }
4782
+ .kplex-publication-production .kplex-publication-note-content [data-callout] {
4783
+ --kplex-reader-callout: var(--kplex-published-author-color-blue, var(--interactive-accent));
4784
+ border-inline-start-color: var(--kplex-reader-callout);
4785
+ border-radius: var(--kplex-published-author-callout-radius, .35rem);
4786
+ background: color-mix(in srgb, var(--kplex-reader-callout) 12%, var(--background-primary));
4787
+ color: var(--text-normal);
4788
+ padding: .6em .85em;
4789
+ }
4790
+ .kplex-publication-production .kplex-publication-note-content [data-callout] > :last-child { margin-block-end: 0; }
4791
+ .kplex-publication-production .kplex-publication-note-content [data-callout]:is([data-callout="danger"], [data-callout="error"], [data-callout="failure"], [data-callout="bug"]) {
4792
+ --kplex-reader-callout: var(--kplex-published-author-color-red, #d33649);
4793
+ }
4794
+ .kplex-publication-production .kplex-publication-note-content [data-callout]:is([data-callout="warning"], [data-callout="caution"], [data-callout="attention"]) {
4795
+ --kplex-reader-callout: var(--kplex-published-author-color-orange, #cf7324);
4796
+ }
4797
+ .kplex-publication-production .kplex-publication-note-content [data-callout]:is([data-callout="success"], [data-callout="check"], [data-callout="done"]) {
4798
+ --kplex-reader-callout: var(--kplex-published-author-color-green, #1a9b49);
4799
+ }
4800
+ .kplex-publication-production .kplex-publication-note-content [data-callout]:is([data-callout="tip"], [data-callout="hint"], [data-callout="important"]) {
4801
+ --kplex-reader-callout: var(--kplex-published-author-color-cyan, #169a9c);
4802
+ }
4803
+ .kplex-publication-production .kplex-publication-note-content [data-callout="example"] {
4804
+ --kplex-reader-callout: var(--kplex-published-author-color-purple, #7852ee);
4805
+ }