@kweaver-ai/kweaver-sdk 0.5.2 → 0.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/README.md +19 -1
  2. package/README.zh.md +19 -1
  3. package/dist/api/agent-chat.d.ts +7 -1
  4. package/dist/api/agent-chat.js +146 -40
  5. package/dist/api/agent-list.js +13 -13
  6. package/dist/api/business-domains.js +9 -5
  7. package/dist/api/context-loader.js +4 -1
  8. package/dist/api/conversations.js +4 -9
  9. package/dist/api/dataflow2.d.ts +95 -0
  10. package/dist/api/dataflow2.js +80 -0
  11. package/dist/api/headers.d.ts +2 -0
  12. package/dist/api/headers.js +7 -2
  13. package/dist/api/skills.js +2 -10
  14. package/dist/api/vega.d.ts +0 -16
  15. package/dist/api/vega.js +0 -33
  16. package/dist/auth/oauth.d.ts +7 -6
  17. package/dist/auth/oauth.js +170 -80
  18. package/dist/cli.js +21 -1
  19. package/dist/client.d.ts +9 -0
  20. package/dist/client.js +48 -8
  21. package/dist/commands/auth.js +103 -42
  22. package/dist/commands/bkn-schema.js +22 -0
  23. package/dist/commands/call.js +8 -5
  24. package/dist/commands/dataflow.d.ts +1 -0
  25. package/dist/commands/dataflow.js +251 -0
  26. package/dist/commands/explore-bkn.d.ts +79 -0
  27. package/dist/commands/explore-bkn.js +273 -0
  28. package/dist/commands/explore-chat.d.ts +3 -0
  29. package/dist/commands/explore-chat.js +193 -0
  30. package/dist/commands/explore-vega.d.ts +3 -0
  31. package/dist/commands/explore-vega.js +71 -0
  32. package/dist/commands/explore.d.ts +9 -0
  33. package/dist/commands/explore.js +258 -0
  34. package/dist/commands/vega.js +2 -104
  35. package/dist/config/no-auth.d.ts +3 -0
  36. package/dist/config/no-auth.js +5 -0
  37. package/dist/config/store.d.ts +8 -0
  38. package/dist/config/store.js +22 -0
  39. package/dist/index.d.ts +1 -1
  40. package/dist/index.js +1 -1
  41. package/dist/kweaver.d.ts +5 -0
  42. package/dist/kweaver.js +32 -2
  43. package/dist/resources/bkn.js +2 -3
  44. package/dist/resources/knowledge-networks.js +3 -8
  45. package/dist/resources/vega.d.ts +0 -6
  46. package/dist/resources/vega.js +1 -10
  47. package/dist/templates/explorer/app.js +136 -0
  48. package/dist/templates/explorer/bkn.js +747 -0
  49. package/dist/templates/explorer/chat.js +980 -0
  50. package/dist/templates/explorer/dashboard.js +82 -0
  51. package/dist/templates/explorer/index.html +35 -0
  52. package/dist/templates/explorer/style.css +2440 -0
  53. package/dist/templates/explorer/vega.js +291 -0
  54. package/dist/utils/browser.js +33 -10
  55. package/dist/utils/http.d.ts +3 -0
  56. package/dist/utils/http.js +37 -1
  57. package/package.json +9 -5
@@ -0,0 +1,2440 @@
1
+ @import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');
2
+
3
+ * { margin: 0; padding: 0; box-sizing: border-box; }
4
+
5
+ :root {
6
+ /* Premium Light Mode Palette based on Tailwind slate/blue */
7
+ --bg: #f8fafc;
8
+ --surface: #ffffff;
9
+ --text: #0f172a;
10
+ --text-secondary: #64748b;
11
+ --border: #e2e8f0;
12
+ --accent: #3b82f6;
13
+ --accent-hover: #2563eb;
14
+ --accent-light: #eff6ff;
15
+ --accent-glow: rgba(59, 130, 246, 0.15);
16
+
17
+ --header-height: 64px;
18
+
19
+ /* Shadows */
20
+ --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
21
+ --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.025);
22
+ --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -4px rgba(0, 0, 0, 0.025);
23
+
24
+ /* Radii */
25
+ --radius-sm: 6px;
26
+ --radius-md: 10px;
27
+ --radius-lg: 14px;
28
+ --radius-pill: 9999px;
29
+
30
+ /* Transitions */
31
+ --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
32
+ }
33
+
34
+ html[data-theme='dark'] {
35
+ --bg: #0f172a;
36
+ --surface: #1e293b;
37
+ --text: #f8fafc;
38
+ --text-secondary: #94a3b8;
39
+ --border: #334155;
40
+ --accent: #3b82f6;
41
+ --accent-hover: #frontend;
42
+ --accent-light: rgba(59, 130, 246, 0.15);
43
+ --accent-glow: rgba(59, 130, 246, 0.3);
44
+ }
45
+
46
+ body {
47
+ font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
48
+ background: var(--bg);
49
+ color: var(--text);
50
+ line-height: 1.6;
51
+ -webkit-font-smoothing: antialiased;
52
+ -moz-osx-font-smoothing: grayscale;
53
+ }
54
+
55
+ /* Scrollbar styling */
56
+ ::-webkit-scrollbar { width: 8px; height: 8px; }
57
+ ::-webkit-scrollbar-track { background: transparent; }
58
+ ::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
59
+ ::-webkit-scrollbar-thumb:hover { background: #94a3b8; }
60
+
61
+ /* ===========================================================================
62
+ Top Bar
63
+ =========================================================================== */
64
+ #top-bar {
65
+ position: fixed;
66
+ top: 0; left: 0; right: 0;
67
+ height: var(--header-height);
68
+ background: rgba(255, 255, 255, 0.85);
69
+ backdrop-filter: blur(12px);
70
+ -webkit-backdrop-filter: blur(12px);
71
+ border-bottom: 1px solid var(--border);
72
+ z-index: 100;
73
+ box-shadow: var(--shadow-sm);
74
+ display: flex;
75
+ align-items: center;
76
+ padding: 0 32px;
77
+ gap: 32px;
78
+ }
79
+
80
+ .top-bar-left {
81
+ display: flex;
82
+ align-items: center;
83
+ flex-shrink: 0;
84
+ }
85
+
86
+ .logo {
87
+ font-size: 20px;
88
+ font-weight: 700;
89
+ color: var(--text);
90
+ text-decoration: none;
91
+ letter-spacing: -0.5px;
92
+ display: flex;
93
+ align-items: center;
94
+ gap: 8px;
95
+ }
96
+
97
+ #tab-bar {
98
+ display: flex;
99
+ align-items: center;
100
+ gap: 4px;
101
+ flex: 1;
102
+ }
103
+
104
+ .tab {
105
+ padding: 8px 18px;
106
+ font-size: 14px;
107
+ font-weight: 500;
108
+ color: var(--text-secondary);
109
+ text-decoration: none;
110
+ border-radius: var(--radius-sm);
111
+ transition: var(--transition-smooth);
112
+ position: relative;
113
+ }
114
+
115
+ .tab:hover {
116
+ color: var(--text);
117
+ background: var(--accent-light);
118
+ }
119
+
120
+ .tab.active {
121
+ color: var(--accent);
122
+ background: var(--accent-light);
123
+ font-weight: 600;
124
+ }
125
+
126
+
127
+ .top-bar-right {
128
+ display: flex;
129
+ align-items: center;
130
+ flex-shrink: 0;
131
+ }
132
+
133
+ #env-label {
134
+ font-size: 12px;
135
+ font-weight: 600;
136
+ color: var(--text-secondary);
137
+ background: var(--bg);
138
+ padding: 4px 12px;
139
+ border-radius: var(--radius-pill);
140
+ border: 1px solid var(--border);
141
+ }
142
+
143
+ /* ===========================================================================
144
+ Main content area
145
+ =========================================================================== */
146
+ #content {
147
+ margin-top: var(--header-height);
148
+ max-width: 1280px;
149
+ margin-left: auto;
150
+ margin-right: auto;
151
+ padding: 40px 32px;
152
+ }
153
+
154
+ /* ===========================================================================
155
+ Shared utilities
156
+ =========================================================================== */
157
+ .loading {
158
+ text-align: center;
159
+ padding: 100px 0;
160
+ color: var(--text-secondary);
161
+ font-size: 16px;
162
+ font-weight: 500;
163
+ display: flex;
164
+ flex-direction: column;
165
+ align-items: center;
166
+ gap: 16px;
167
+ }
168
+
169
+ .loading::after {
170
+ content: '';
171
+ display: block;
172
+ width: 32px; height: 32px;
173
+ border: 3px solid var(--border);
174
+ border-top-color: var(--accent);
175
+ border-radius: 50%;
176
+ animation: spin 1s linear infinite;
177
+ }
178
+
179
+ @keyframes spin {
180
+ from { transform: rotate(0deg); }
181
+ to { transform: rotate(360deg); }
182
+ }
183
+
184
+ /* Skeleton Loaders */
185
+ .skeleton {
186
+ background: linear-gradient(90deg, var(--border) 25%, var(--bg) 50%, var(--border) 75%);
187
+ background-size: 200% 100%;
188
+ animation: shimmer 1.5s infinite linear;
189
+ border-radius: var(--radius-sm);
190
+ display: inline-block;
191
+ }
192
+
193
+ @keyframes shimmer {
194
+ 0% { background-position: -200% 0; }
195
+ 100% { background-position: 200% 0; }
196
+ }
197
+
198
+ .skeleton-text { height: 16px; margin-bottom: 8px; width: 100%; }
199
+ .skeleton-title { height: 24px; margin-bottom: 12px; width: 60%; }
200
+ .skeleton-card { height: 120px; border-radius: var(--radius-lg); width: 100%; }
201
+ .skeleton-list-item { height: 56px; border-radius: var(--radius-sm); margin-bottom: 8px; width: 100%; }
202
+
203
+ .loading-skeleton {
204
+ padding: 24px 0;
205
+ display: flex;
206
+ flex-direction: column;
207
+ gap: 16px;
208
+ width: 100%;
209
+ }
210
+
211
+ .loading-skeleton.grid {
212
+ flex-direction: row;
213
+ flex-wrap: wrap;
214
+ }
215
+
216
+ .loading-skeleton.grid > .skeleton {
217
+ flex: 1;
218
+ min-width: 250px;
219
+ }
220
+
221
+ .error-banner {
222
+ background: #fef2f2;
223
+ color: #b91c1c;
224
+ border: 1px solid #fecaca;
225
+ border-radius: var(--radius-md);
226
+ padding: 16px 24px;
227
+ font-size: 14px;
228
+ font-weight: 500;
229
+ }
230
+
231
+ .null {
232
+ color: var(--text-secondary);
233
+ opacity: 0.5;
234
+ }
235
+
236
+ .breadcrumb {
237
+ font-size: 14px;
238
+ font-weight: 500;
239
+ color: var(--text-secondary);
240
+ margin-bottom: 24px;
241
+ display: flex;
242
+ gap: 8px;
243
+ align-items: center;
244
+ }
245
+
246
+ .breadcrumb a {
247
+ color: var(--accent);
248
+ text-decoration: none;
249
+ padding: 4px 8px;
250
+ border-radius: var(--radius-sm);
251
+ transition: var(--transition-smooth);
252
+ margin-left: -8px;
253
+ }
254
+
255
+ .breadcrumb a:hover {
256
+ background: var(--accent-light);
257
+ }
258
+
259
+ .breadcrumb span::after {
260
+ content: '/';
261
+ margin-left: 8px;
262
+ color: #cbd5e1;
263
+ }
264
+ .breadcrumb span:last-child::after { content: none; }
265
+ .breadcrumb span:last-child { color: var(--text); font-weight: 600; }
266
+
267
+ .page-title {
268
+ font-size: 28px;
269
+ font-weight: 700;
270
+ margin-bottom: 12px;
271
+ color: var(--text);
272
+ letter-spacing: -0.5px;
273
+ }
274
+
275
+ .page-subtitle {
276
+ font-size: 15px;
277
+ color: var(--text-secondary);
278
+ margin-bottom: 32px;
279
+ line-height: 1.5;
280
+ max-width: 800px;
281
+ }
282
+
283
+ pre {
284
+ font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
285
+ font-size: 13px;
286
+ line-height: 1.5;
287
+ white-space: pre-wrap;
288
+ word-break: break-all;
289
+ }
290
+
291
+ /* ===========================================================================
292
+ Dashboard
293
+ =========================================================================== */
294
+ .dashboard {
295
+ display: flex;
296
+ flex-direction: column;
297
+ gap: 32px;
298
+ }
299
+
300
+ .summary-cards {
301
+ display: flex;
302
+ gap: 20px;
303
+ }
304
+
305
+ .summary-card {
306
+ flex: 1;
307
+ background: var(--surface);
308
+ border: 1px solid var(--border);
309
+ border-radius: var(--radius-lg);
310
+ padding: 24px;
311
+ box-shadow: var(--shadow-sm);
312
+ transition: var(--transition-smooth);
313
+ position: relative;
314
+ overflow: hidden;
315
+ text-decoration: none;
316
+ color: inherit;
317
+ display: block;
318
+ }
319
+
320
+ .summary-card::after {
321
+ content: '';
322
+ position: absolute;
323
+ top: 0; right: 0;
324
+ width: 80px; height: 80px;
325
+ background: linear-gradient(135deg, transparent, var(--accent-light));
326
+ border-bottom-left-radius: 80px;
327
+ opacity: 0.5;
328
+ }
329
+
330
+ .summary-card:hover {
331
+ transform: translateY(-3px);
332
+ box-shadow: var(--shadow-lg);
333
+ border-color: #cbd5e1;
334
+ }
335
+
336
+ .summary-card-label {
337
+ font-size: 14px;
338
+ font-weight: 500;
339
+ color: var(--text-secondary);
340
+ margin-bottom: 8px;
341
+ }
342
+
343
+ .summary-card-count {
344
+ font-size: 36px;
345
+ font-weight: 700;
346
+ color: var(--text);
347
+ letter-spacing: -1px;
348
+ line-height: 1.2;
349
+ }
350
+
351
+ .resource-section {
352
+ background: var(--surface);
353
+ border: 1px solid var(--border);
354
+ border-radius: var(--radius-lg);
355
+ padding: 24px;
356
+ box-shadow: var(--shadow-sm);
357
+ }
358
+
359
+ .resource-section h3 {
360
+ font-size: 16px;
361
+ font-weight: 600;
362
+ margin-bottom: 16px;
363
+ color: var(--text);
364
+ }
365
+
366
+ .resource-list {
367
+ display: flex;
368
+ flex-direction: column;
369
+ }
370
+
371
+ .resource-row {
372
+ display: flex;
373
+ align-items: center;
374
+ justify-content: space-between;
375
+ padding: 12px 16px;
376
+ border-bottom: 1px solid var(--border);
377
+ cursor: pointer;
378
+ transition: var(--transition-smooth);
379
+ border-radius: var(--radius-sm);
380
+ }
381
+
382
+ .resource-row:last-child { border-bottom: none; }
383
+
384
+ .resource-row:hover {
385
+ background: var(--accent-light);
386
+ padding-left: 20px;
387
+ }
388
+
389
+ .resource-name {
390
+ font-weight: 500;
391
+ font-size: 14px;
392
+ color: var(--text);
393
+ }
394
+
395
+ .resource-meta {
396
+ font-size: 13px;
397
+ color: var(--text-secondary);
398
+ }
399
+
400
+ /* ===========================================================================
401
+ Chat
402
+ =========================================================================== */
403
+ .chat-layout {
404
+ display: flex;
405
+ height: calc(100vh - var(--header-height) - 80px);
406
+ gap: 0;
407
+ background: var(--surface);
408
+ border: 1px solid var(--border);
409
+ border-radius: var(--radius-lg);
410
+ overflow: hidden;
411
+ box-shadow: var(--shadow-md);
412
+ }
413
+
414
+ .chat-sidebar {
415
+ width: 280px;
416
+ border-right: 1px solid var(--border);
417
+ overflow-y: auto;
418
+ padding: 16px;
419
+ background: var(--bg);
420
+ flex-shrink: 0;
421
+ display: flex;
422
+ flex-direction: column;
423
+ gap: 16px;
424
+ }
425
+
426
+ .chat-sidebar-header {
427
+ font-size: 16px;
428
+ font-weight: 600;
429
+ color: var(--text);
430
+ padding: 4px 8px;
431
+ }
432
+
433
+ .chat-sidebar-search {
434
+ padding: 0 4px;
435
+ }
436
+ .chat-sidebar-search input {
437
+ width: 100%;
438
+ padding: 8px 12px;
439
+ border: 1px solid var(--border);
440
+ border-radius: var(--radius-md);
441
+ font-size: 13px;
442
+ background: var(--surface);
443
+ outline: none;
444
+ transition: var(--transition-smooth);
445
+ }
446
+ .chat-sidebar-search input:focus {
447
+ border-color: var(--accent);
448
+ box-shadow: 0 0 0 2px var(--accent-glow);
449
+ }
450
+
451
+ .chat-agent-list {
452
+ display: flex;
453
+ flex-direction: column;
454
+ gap: 4px;
455
+ }
456
+
457
+ .chat-agent-item {
458
+ display: flex;
459
+ align-items: center;
460
+ gap: 12px;
461
+ padding: 12px 14px;
462
+ font-size: 14px;
463
+ font-weight: 500;
464
+ color: var(--text);
465
+ border-radius: var(--radius-md);
466
+ cursor: pointer;
467
+ transition: var(--transition-smooth);
468
+ }
469
+
470
+ .chat-agent-item:hover {
471
+ background: var(--surface);
472
+ box-shadow: var(--shadow-sm);
473
+ }
474
+
475
+ .chat-agent-item.active {
476
+ background: var(--surface);
477
+ color: var(--accent);
478
+ font-weight: 600;
479
+ box-shadow: var(--shadow-sm);
480
+ border-left: 3px solid var(--accent);
481
+ }
482
+
483
+ .chat-agent-item-icon {
484
+ font-size: 20px;
485
+ flex-shrink: 0;
486
+ }
487
+
488
+ .chat-agent-item-content {
489
+ display: flex;
490
+ flex-direction: column;
491
+ min-width: 0;
492
+ }
493
+
494
+ .chat-agent-item-name {
495
+ white-space: nowrap;
496
+ overflow: hidden;
497
+ text-overflow: ellipsis;
498
+ min-width: 0;
499
+ }
500
+
501
+ .chat-agent-item-desc {
502
+ font-size: 12px;
503
+ font-weight: 400;
504
+ color: var(--text-secondary);
505
+ white-space: nowrap;
506
+ overflow: hidden;
507
+ text-overflow: ellipsis;
508
+ margin-top: 2px;
509
+ }
510
+
511
+ /* Test agent styling */
512
+ .chat-agent-item.chat-agent-test {
513
+ opacity: 0.55;
514
+ }
515
+ .chat-agent-item.chat-agent-test:hover {
516
+ opacity: 0.8;
517
+ }
518
+ .chat-test-badge {
519
+ display: inline-block;
520
+ font-size: 10px;
521
+ padding: 1px 6px;
522
+ border-radius: 8px;
523
+ background: #fef3c7;
524
+ color: #92400e;
525
+ font-weight: 500;
526
+ vertical-align: middle;
527
+ margin-left: 4px;
528
+ }
529
+
530
+ .chat-main {
531
+ flex: 1;
532
+ display: flex;
533
+ flex-direction: column;
534
+ min-width: 0;
535
+ }
536
+
537
+ .chat-header {
538
+ padding: 16px 24px;
539
+ border-bottom: 1px solid var(--border);
540
+ font-size: 16px;
541
+ font-weight: 600;
542
+ color: var(--text);
543
+ display: flex;
544
+ align-items: center;
545
+ gap: 12px;
546
+ }
547
+
548
+ .chat-conversation {
549
+ flex: 1;
550
+ min-height: 0;
551
+ display: flex;
552
+ flex-direction: column;
553
+ }
554
+ .chat-pane {
555
+ display: flex;
556
+ flex-direction: column;
557
+ height: 100%;
558
+ min-height: 0;
559
+ }
560
+ .chat-messages {
561
+ flex: 1;
562
+ overflow-y: auto;
563
+ min-height: 0;
564
+ padding: 24px 32px;
565
+ display: flex;
566
+ flex-direction: column;
567
+ gap: 20px;
568
+ background: #fdfdfd;
569
+ }
570
+
571
+ .chat-message-row {
572
+ display: flex;
573
+ align-items: flex-start;
574
+ gap: 12px;
575
+ max-width: 80%;
576
+ animation: fadeIn 0.3s ease;
577
+ }
578
+ @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
579
+
580
+ .chat-message-row.user {
581
+ align-self: flex-end;
582
+ flex-direction: row;
583
+ }
584
+
585
+ .chat-message-row.assistant {
586
+ align-self: flex-start;
587
+ }
588
+
589
+ .chat-avatar {
590
+ width: 32px;
591
+ height: 32px;
592
+ border-radius: 50%;
593
+ background: var(--bg);
594
+ border: 1px solid var(--border);
595
+ display: flex;
596
+ align-items: center;
597
+ justify-content: center;
598
+ font-size: 16px;
599
+ flex-shrink: 0;
600
+ }
601
+
602
+ .chat-bubble {
603
+ padding: 14px 18px;
604
+ border-radius: var(--radius-lg);
605
+ font-size: 14px;
606
+ line-height: 1.6;
607
+ position: relative;
608
+ }
609
+
610
+ .chat-bubble.user, .chat-bubble-user {
611
+ background: var(--accent);
612
+ color: #fff;
613
+ border-bottom-right-radius: 4px;
614
+ box-shadow: var(--shadow-sm);
615
+ }
616
+
617
+ .chat-bubble.assistant, .chat-bubble-assistant {
618
+ background: var(--surface);
619
+ color: var(--text);
620
+ border: 1px solid var(--border);
621
+ border-bottom-left-radius: 4px;
622
+ box-shadow: var(--shadow-sm);
623
+ }
624
+
625
+ .chat-bubble-sender {
626
+ font-size: 12px;
627
+ font-weight: 600;
628
+ margin-bottom: 4px;
629
+ opacity: 0.7;
630
+ }
631
+
632
+ .chat-bubble-content {
633
+ word-break: break-word;
634
+ }
635
+
636
+ .chat-bubble-content pre {
637
+ background: rgba(0, 0, 0, 0.06);
638
+ padding: 12px;
639
+ border-radius: var(--radius-sm);
640
+ margin: 8px 0;
641
+ overflow-x: auto;
642
+ }
643
+ .chat-bubble-content code {
644
+ background: rgba(0, 0, 0, 0.06);
645
+ padding: 2px 5px;
646
+ border-radius: 3px;
647
+ font-size: 0.9em;
648
+ }
649
+ .chat-bubble-content pre code {
650
+ background: none;
651
+ padding: 0;
652
+ }
653
+ .chat-bubble-user .chat-bubble-content code {
654
+ background: rgba(255, 255, 255, 0.2);
655
+ }
656
+ .chat-md-heading {
657
+ margin: 12px 0 6px;
658
+ font-weight: 600;
659
+ line-height: 1.3;
660
+ }
661
+ h1.chat-md-heading { font-size: 1.3em; }
662
+ h2.chat-md-heading { font-size: 1.15em; }
663
+ h3.chat-md-heading { font-size: 1.05em; }
664
+ h4.chat-md-heading { font-size: 1em; }
665
+ .chat-md-list {
666
+ margin: 6px 0;
667
+ padding-left: 24px;
668
+ }
669
+ .chat-md-list li {
670
+ margin-bottom: 3px;
671
+ }
672
+ .chat-md-hr {
673
+ border: none;
674
+ border-top: 1px solid var(--border);
675
+ margin: 10px 0;
676
+ }
677
+
678
+ .chat-input-bar {
679
+ display: flex;
680
+ align-items: center;
681
+ gap: 12px;
682
+ padding: 16px 24px;
683
+ border-top: 1px solid var(--border);
684
+ background: var(--surface);
685
+ }
686
+
687
+ .chat-input {
688
+ flex: 1;
689
+ padding: 12px 18px;
690
+ border: 1px solid var(--border);
691
+ border-radius: var(--radius-pill);
692
+ font-size: 14px;
693
+ font-family: inherit;
694
+ outline: none;
695
+ transition: var(--transition-smooth);
696
+ background: var(--bg);
697
+ resize: none;
698
+ max-height: 120px;
699
+ line-height: 1.4;
700
+ }
701
+
702
+ .chat-input:focus {
703
+ border-color: var(--accent);
704
+ box-shadow: 0 0 0 3px var(--accent-glow);
705
+ background: var(--surface);
706
+ }
707
+
708
+ .chat-send-btn {
709
+ padding: 10px 24px;
710
+ background: var(--accent);
711
+ color: #fff;
712
+ border: none;
713
+ border-radius: var(--radius-pill);
714
+ cursor: pointer;
715
+ font-size: 14px;
716
+ font-weight: 600;
717
+ font-family: inherit;
718
+ transition: var(--transition-smooth);
719
+ flex-shrink: 0;
720
+ }
721
+
722
+ .chat-send-btn:hover {
723
+ background: var(--accent-hover);
724
+ box-shadow: var(--shadow-md);
725
+ transform: translateY(-1px);
726
+ }
727
+
728
+ .chat-send-btn:disabled {
729
+ opacity: 0.5;
730
+ cursor: not-allowed;
731
+ transform: none;
732
+ box-shadow: none;
733
+ }
734
+
735
+ /* Stop button mode */
736
+ .chat-send-btn.chat-stop-mode {
737
+ background: #ef4444;
738
+ opacity: 1;
739
+ cursor: pointer;
740
+ }
741
+ .chat-send-btn.chat-stop-mode:hover {
742
+ background: #dc2626;
743
+ }
744
+
745
+ .chat-placeholder {
746
+ display: flex;
747
+ align-items: center;
748
+ justify-content: center;
749
+ height: 100%;
750
+ color: var(--text-secondary);
751
+ font-size: 15px;
752
+ font-weight: 500;
753
+ }
754
+
755
+ .entity-card {
756
+ background: var(--surface);
757
+ border: 1px solid var(--border);
758
+ border-radius: var(--radius-md);
759
+ padding: 16px 20px;
760
+ margin: 8px 0;
761
+ box-shadow: var(--shadow-sm);
762
+ transition: var(--transition-smooth);
763
+ }
764
+
765
+ .entity-card:hover {
766
+ border-color: var(--accent);
767
+ box-shadow: var(--shadow-md);
768
+ }
769
+
770
+ .chat-clear-btn {
771
+ margin-left: auto;
772
+ padding: 6px 12px;
773
+ background: transparent;
774
+ color: var(--text-secondary);
775
+ border: 1px solid var(--border);
776
+ border-radius: var(--radius-sm);
777
+ font-size: 13px;
778
+ font-weight: 500;
779
+ cursor: pointer;
780
+ transition: var(--transition-smooth);
781
+ }
782
+ .chat-clear-btn:hover {
783
+ background: #fee2e2;
784
+ color: #ef4444;
785
+ border-color: #fecaca;
786
+ }
787
+
788
+ .chat-welcome-box {
789
+ display: flex;
790
+ flex-direction: column;
791
+ align-items: center;
792
+ justify-content: center;
793
+ height: 100%;
794
+ color: var(--text-secondary);
795
+ gap: 16px;
796
+ }
797
+ .chat-welcome-icon {
798
+ font-size: 48px;
799
+ opacity: 0.8;
800
+ }
801
+ .chat-welcome-text {
802
+ font-size: 16px;
803
+ }
804
+
805
+ /* ===========================================================================
806
+ BKN (carried over from old explorer)
807
+ =========================================================================== */
808
+ .search-box {
809
+ display: flex;
810
+ gap: 12px;
811
+ position: relative;
812
+ }
813
+
814
+ .search-box input {
815
+ width: 320px;
816
+ padding: 10px 16px 10px 36px;
817
+ border: 1px solid var(--border);
818
+ border-radius: var(--radius-pill);
819
+ font-size: 14px;
820
+ background: #f8fafc;
821
+ outline: none;
822
+ transition: var(--transition-smooth);
823
+ font-family: inherit;
824
+ }
825
+
826
+ .search-box::before {
827
+ content: '\26B2';
828
+ position: absolute;
829
+ left: 14px;
830
+ top: 50%;
831
+ transform: translateY(-50%) rotate(-45deg);
832
+ font-size: 18px;
833
+ color: var(--text-secondary);
834
+ pointer-events: none;
835
+ z-index: 10;
836
+ }
837
+
838
+ .search-box input:focus {
839
+ border-color: var(--accent);
840
+ background: var(--surface);
841
+ box-shadow: 0 0 0 3px var(--accent-glow);
842
+ }
843
+
844
+ .search-box button {
845
+ padding: 8px 20px;
846
+ background: var(--text);
847
+ color: #fff;
848
+ border: none;
849
+ border-radius: var(--radius-pill);
850
+ cursor: pointer;
851
+ font-size: 14px;
852
+ font-weight: 500;
853
+ transition: var(--transition-smooth);
854
+ font-family: inherit;
855
+ }
856
+
857
+ .search-box button:hover {
858
+ background: #334155;
859
+ box-shadow: var(--shadow-md);
860
+ transform: translateY(-1px);
861
+ }
862
+
863
+ .refresh-btn {
864
+ background: var(--surface);
865
+ border: 1px solid var(--border);
866
+ border-radius: var(--radius-pill);
867
+ width: 36px;
868
+ height: 36px;
869
+ display: flex;
870
+ align-items: center;
871
+ justify-content: center;
872
+ font-size: 18px;
873
+ cursor: pointer;
874
+ color: var(--text-secondary);
875
+ margin-left: 12px;
876
+ transition: var(--transition-smooth);
877
+ box-shadow: var(--shadow-sm);
878
+ }
879
+
880
+ .refresh-btn:hover {
881
+ color: var(--text);
882
+ border-color: #cbd5e1;
883
+ background: #f1f5f9;
884
+ transform: translateY(-1px);
885
+ }
886
+
887
+ .refresh-btn.spinning {
888
+ animation: spin 0.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
889
+ color: var(--accent);
890
+ border-color: var(--accent-glow);
891
+ }
892
+
893
+ /* Statistics row */
894
+ .stats-row {
895
+ display: flex;
896
+ gap: 20px;
897
+ margin-bottom: 40px;
898
+ }
899
+
900
+ .stat-card {
901
+ flex: 1;
902
+ background: var(--surface);
903
+ border: 1px solid var(--border);
904
+ border-radius: var(--radius-lg);
905
+ padding: 24px;
906
+ text-align: left;
907
+ box-shadow: var(--shadow-sm);
908
+ transition: var(--transition-smooth);
909
+ position: relative;
910
+ overflow: hidden;
911
+ }
912
+
913
+ .stat-card::after {
914
+ content: '';
915
+ position: absolute;
916
+ top: 0; right: 0;
917
+ width: 100px; height: 100px;
918
+ background: linear-gradient(135deg, transparent, var(--accent-light));
919
+ border-bottom-left-radius: 100px;
920
+ opacity: 0.5;
921
+ }
922
+
923
+ .stat-card:hover {
924
+ transform: translateY(-3px);
925
+ box-shadow: var(--shadow-lg);
926
+ border-color: #cbd5e1;
927
+ }
928
+
929
+ .stat-card .number {
930
+ font-size: 36px;
931
+ font-weight: 700;
932
+ color: var(--text);
933
+ letter-spacing: -1px;
934
+ line-height: 1.2;
935
+ }
936
+
937
+ .stat-card .label {
938
+ font-size: 14px;
939
+ font-weight: 500;
940
+ color: var(--text-secondary);
941
+ margin-top: 8px;
942
+ }
943
+
944
+ /* Object Types Grid */
945
+ .ot-grid {
946
+ display: grid;
947
+ grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
948
+ gap: 20px;
949
+ }
950
+
951
+ .ot-card {
952
+ background: var(--surface);
953
+ border: 1px solid var(--border);
954
+ border-radius: var(--radius-lg);
955
+ padding: 24px;
956
+ cursor: pointer;
957
+ box-shadow: var(--shadow-sm);
958
+ transition: var(--transition-smooth);
959
+ display: flex;
960
+ flex-direction: column;
961
+ }
962
+
963
+ .ot-card:hover {
964
+ border-color: var(--accent);
965
+ box-shadow: var(--shadow-md);
966
+ transform: translateY(-2px);
967
+ }
968
+
969
+ .ot-card h3 {
970
+ font-size: 18px;
971
+ font-weight: 600;
972
+ margin-bottom: 12px;
973
+ color: var(--text);
974
+ }
975
+
976
+ .ot-card .meta {
977
+ margin-top: auto;
978
+ font-size: 13px;
979
+ color: var(--text-secondary);
980
+ background: var(--bg);
981
+ padding: 6px 12px;
982
+ border-radius: var(--radius-sm);
983
+ display: inline-block;
984
+ align-self: flex-start;
985
+ }
986
+
987
+ /* Instance Lists & Detail Panels */
988
+ .instance-list {
989
+ background: var(--surface);
990
+ border: 1px solid var(--border);
991
+ border-radius: var(--radius-lg);
992
+ box-shadow: var(--shadow-sm);
993
+ overflow: hidden;
994
+ }
995
+
996
+ .instance-item {
997
+ padding: 16px 24px;
998
+ border-bottom: 1px solid var(--border);
999
+ cursor: pointer;
1000
+ transition: var(--transition-smooth);
1001
+ display: flex;
1002
+ flex-direction: column;
1003
+ justify-content: center;
1004
+ }
1005
+
1006
+ .instance-item:last-child { border-bottom: none; }
1007
+
1008
+ .instance-item:hover {
1009
+ background: var(--accent-light);
1010
+ padding-left: 28px;
1011
+ }
1012
+
1013
+ .instance-item .name {
1014
+ font-weight: 600;
1015
+ color: var(--text);
1016
+ font-size: 15px;
1017
+ }
1018
+
1019
+ .instance-subtitle {
1020
+ margin-top: 6px;
1021
+ font-size: 13px;
1022
+ color: var(--text-secondary);
1023
+ }
1024
+
1025
+ .field-picker {
1026
+ display: flex;
1027
+ flex-wrap: wrap;
1028
+ align-items: center;
1029
+ gap: 8px;
1030
+ padding: 16px 24px;
1031
+ border-bottom: 1px dashed var(--border);
1032
+ background: #f8fafc;
1033
+ }
1034
+
1035
+ .field-picker-label {
1036
+ font-size: 13px;
1037
+ font-weight: 500;
1038
+ color: var(--text-secondary);
1039
+ margin-right: 8px;
1040
+ }
1041
+
1042
+ .field-chip {
1043
+ font-size: 13px;
1044
+ font-weight: 500;
1045
+ padding: 6px 14px;
1046
+ border-radius: var(--radius-pill);
1047
+ border: 1px solid var(--border);
1048
+ background: var(--surface);
1049
+ cursor: pointer;
1050
+ color: var(--text-secondary);
1051
+ transition: var(--transition-smooth);
1052
+ }
1053
+
1054
+ .field-chip:hover {
1055
+ border-color: var(--accent);
1056
+ color: var(--accent);
1057
+ background: var(--accent-light);
1058
+ }
1059
+
1060
+ .field-chip.active {
1061
+ background: var(--text);
1062
+ color: #fff;
1063
+ border-color: var(--text);
1064
+ }
1065
+
1066
+ .field-chip-auto {
1067
+ font-style: italic;
1068
+ opacity: 0.8;
1069
+ }
1070
+
1071
+ .detail-section {
1072
+ margin-bottom: 40px;
1073
+ background: var(--surface);
1074
+ border: 1px solid var(--border);
1075
+ border-radius: var(--radius-lg);
1076
+ padding: 32px;
1077
+ box-shadow: var(--shadow-sm);
1078
+ }
1079
+
1080
+ .detail-section h2 {
1081
+ font-size: 20px;
1082
+ font-weight: 600;
1083
+ margin-bottom: 20px;
1084
+ color: var(--text);
1085
+ display: flex;
1086
+ align-items: center;
1087
+ gap: 8px;
1088
+ }
1089
+
1090
+ .props-table {
1091
+ width: 100%;
1092
+ border-collapse: collapse;
1093
+ background: var(--surface);
1094
+ border-radius: var(--radius-md);
1095
+ overflow: hidden;
1096
+ border: 1px solid var(--border);
1097
+ }
1098
+
1099
+ .props-table tr {
1100
+ border-bottom: 1px solid var(--border);
1101
+ transition: var(--transition-smooth);
1102
+ }
1103
+
1104
+ .props-table tr:last-child { border-bottom: none; }
1105
+
1106
+ .props-table tr:hover { background: var(--accent-light); }
1107
+
1108
+ .props-table td {
1109
+ padding: 14px 20px;
1110
+ font-size: 14px;
1111
+ }
1112
+
1113
+ .props-table td:first-child {
1114
+ width: 220px;
1115
+ font-weight: 500;
1116
+ color: var(--text-secondary);
1117
+ background: #f8fafc;
1118
+ border-right: 1px solid var(--border);
1119
+ }
1120
+
1121
+ /* Relation group */
1122
+ .relation-group {
1123
+ margin-bottom: 24px;
1124
+ padding: 16px;
1125
+ background: var(--bg);
1126
+ border-radius: var(--radius-md);
1127
+ border: 1px solid var(--border);
1128
+ }
1129
+
1130
+ .relation-group h4 {
1131
+ font-size: 14px;
1132
+ font-weight: 600;
1133
+ color: var(--text-secondary);
1134
+ margin-bottom: 12px;
1135
+ display: flex;
1136
+ align-items: center;
1137
+ gap: 6px;
1138
+ }
1139
+
1140
+ .link-list {
1141
+ display: flex;
1142
+ flex-wrap: wrap;
1143
+ gap: 10px;
1144
+ }
1145
+
1146
+ .link-tag {
1147
+ display: inline-flex;
1148
+ align-items: center;
1149
+ padding: 6px 14px;
1150
+ background: var(--surface);
1151
+ color: var(--accent);
1152
+ border: 1px solid #cbd5e1;
1153
+ border-radius: var(--radius-pill);
1154
+ font-size: 13px;
1155
+ font-weight: 500;
1156
+ text-decoration: none;
1157
+ transition: var(--transition-smooth);
1158
+ box-shadow: 0 1px 2px rgba(0,0,0,0.02);
1159
+ }
1160
+
1161
+ .link-tag::before {
1162
+ content: '\2192';
1163
+ font-size: 12px;
1164
+ margin-right: 6px;
1165
+ opacity: 0.6;
1166
+ }
1167
+
1168
+ .link-tag:hover {
1169
+ background: var(--accent);
1170
+ color: #fff;
1171
+ border-color: var(--accent);
1172
+ transform: translateY(-1px);
1173
+ box-shadow: 0 4px 6px rgba(37, 99, 235, 0.2);
1174
+ }
1175
+
1176
+ .rt-icon {
1177
+ display: inline-block;
1178
+ margin-right: 6px;
1179
+ font-size: 14px;
1180
+ opacity: 0.6;
1181
+ }
1182
+
1183
+ .rt-nav-item {
1184
+ font-size: 13px;
1185
+ line-height: 1.4;
1186
+ }
1187
+
1188
+ .rt-source-item {
1189
+ border-bottom: 1px solid var(--border);
1190
+ }
1191
+
1192
+ .rt-source-item:last-child { border-bottom: none; }
1193
+
1194
+ .rt-source-header {
1195
+ display: flex;
1196
+ align-items: center;
1197
+ justify-content: space-between;
1198
+ padding: 12px 20px;
1199
+ }
1200
+
1201
+ .rt-source-header .name {
1202
+ font-weight: 500;
1203
+ text-decoration: none;
1204
+ color: inherit;
1205
+ }
1206
+
1207
+ .rt-source-header .name:hover { color: var(--accent); }
1208
+
1209
+ .rt-link-count {
1210
+ font-size: 12px;
1211
+ color: var(--accent);
1212
+ background: var(--accent-light);
1213
+ padding: 2px 8px;
1214
+ border-radius: 10px;
1215
+ }
1216
+
1217
+ .rt-targets {
1218
+ padding: 0 20px 12px 36px;
1219
+ }
1220
+
1221
+ .rt-no-links-section {
1222
+ margin-top: 16px;
1223
+ padding: 0 20px;
1224
+ }
1225
+
1226
+ .rt-no-links-section summary {
1227
+ font-size: 13px;
1228
+ color: var(--text-secondary);
1229
+ cursor: pointer;
1230
+ padding: 8px 0;
1231
+ }
1232
+
1233
+ .rt-no-links-list {
1234
+ display: flex;
1235
+ flex-wrap: wrap;
1236
+ gap: 6px;
1237
+ padding: 8px 0;
1238
+ }
1239
+
1240
+ .rt-no-link-item {
1241
+ font-size: 13px;
1242
+ color: var(--text-secondary);
1243
+ text-decoration: none;
1244
+ padding: 4px 10px;
1245
+ background: var(--bg);
1246
+ border-radius: 6px;
1247
+ border: 1px solid var(--border);
1248
+ }
1249
+
1250
+ .rt-no-link-item:hover {
1251
+ border-color: var(--accent);
1252
+ color: var(--accent);
1253
+ }
1254
+
1255
+ /* Search results */
1256
+ .search-result {
1257
+ background: var(--surface);
1258
+ border: 1px solid var(--border);
1259
+ border-radius: var(--radius-md);
1260
+ padding: 20px 24px;
1261
+ margin-bottom: 16px;
1262
+ cursor: pointer;
1263
+ box-shadow: var(--shadow-sm);
1264
+ transition: var(--transition-smooth);
1265
+ }
1266
+
1267
+ .search-result:hover {
1268
+ border-color: var(--accent);
1269
+ box-shadow: var(--shadow-md);
1270
+ transform: translateY(-2px);
1271
+ }
1272
+
1273
+ .search-result .type-badge {
1274
+ display: inline-block;
1275
+ font-size: 12px;
1276
+ font-weight: 600;
1277
+ padding: 4px 10px;
1278
+ border-radius: var(--radius-pill);
1279
+ background: var(--bg);
1280
+ color: var(--text-secondary);
1281
+ border: 1px solid var(--border);
1282
+ margin-right: 12px;
1283
+ }
1284
+
1285
+ .search-result .score {
1286
+ float: right;
1287
+ font-size: 12px;
1288
+ font-weight: 500;
1289
+ color: #94a3b8;
1290
+ background: #f1f5f9;
1291
+ padding: 2px 8px;
1292
+ border-radius: 4px;
1293
+ }
1294
+
1295
+ .pagination {
1296
+ display: flex;
1297
+ justify-content: center;
1298
+ gap: 12px;
1299
+ margin-top: 32px;
1300
+ }
1301
+
1302
+ .pagination button {
1303
+ padding: 10px 20px;
1304
+ border: 1px solid var(--border);
1305
+ border-radius: var(--radius-sm);
1306
+ background: var(--surface);
1307
+ cursor: pointer;
1308
+ font-size: 14px;
1309
+ font-weight: 500;
1310
+ color: var(--text);
1311
+ box-shadow: var(--shadow-sm);
1312
+ transition: var(--transition-smooth);
1313
+ }
1314
+
1315
+ .pagination button:hover:not(:disabled) {
1316
+ border-color: var(--accent);
1317
+ color: var(--accent);
1318
+ transform: translateY(-1px);
1319
+ }
1320
+
1321
+ .pagination button:disabled {
1322
+ opacity: 0.4;
1323
+ cursor: not-allowed;
1324
+ box-shadow: none;
1325
+ }
1326
+
1327
+ /* ===========================================================================
1328
+ Vega
1329
+ =========================================================================== */
1330
+ .vega-view {
1331
+ display: flex;
1332
+ flex-direction: column;
1333
+ gap: 32px;
1334
+ }
1335
+
1336
+ .catalog-grid {
1337
+ display: grid;
1338
+ grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
1339
+ gap: 20px;
1340
+ }
1341
+
1342
+ .catalog-card {
1343
+ background: var(--surface);
1344
+ border: 1px solid var(--border);
1345
+ border-radius: var(--radius-lg);
1346
+ padding: 24px;
1347
+ cursor: pointer;
1348
+ box-shadow: var(--shadow-sm);
1349
+ transition: var(--transition-smooth);
1350
+ display: flex;
1351
+ flex-direction: column;
1352
+ gap: 12px;
1353
+ }
1354
+
1355
+ .catalog-card:hover {
1356
+ border-color: var(--accent);
1357
+ box-shadow: var(--shadow-md);
1358
+ transform: translateY(-2px);
1359
+ }
1360
+
1361
+ .catalog-card-header {
1362
+ display: flex;
1363
+ align-items: center;
1364
+ justify-content: space-between;
1365
+ }
1366
+
1367
+ .catalog-name {
1368
+ font-size: 16px;
1369
+ font-weight: 600;
1370
+ color: var(--text);
1371
+ }
1372
+
1373
+ .catalog-meta {
1374
+ font-size: 13px;
1375
+ color: var(--text-secondary);
1376
+ line-height: 1.5;
1377
+ }
1378
+
1379
+ .health-indicator {
1380
+ display: inline-flex;
1381
+ align-items: center;
1382
+ gap: 6px;
1383
+ font-size: 12px;
1384
+ font-weight: 600;
1385
+ padding: 4px 12px;
1386
+ border-radius: var(--radius-pill);
1387
+ }
1388
+
1389
+ .health-indicator.healthy {
1390
+ color: #15803d;
1391
+ background: #f0fdf4;
1392
+ border: 1px solid #bbf7d0;
1393
+ }
1394
+
1395
+ .health-indicator.unhealthy {
1396
+ color: #b91c1c;
1397
+ background: #fef2f2;
1398
+ border: 1px solid #fecaca;
1399
+ }
1400
+
1401
+ .health-indicator.unknown {
1402
+ color: var(--text-secondary);
1403
+ background: var(--bg);
1404
+ border: 1px solid var(--border);
1405
+ }
1406
+
1407
+ .data-table {
1408
+ width: 100%;
1409
+ border-collapse: collapse;
1410
+ background: var(--surface);
1411
+ border: 1px solid var(--border);
1412
+ border-radius: var(--radius-md);
1413
+ overflow: hidden;
1414
+ }
1415
+
1416
+ .data-table th {
1417
+ text-align: left;
1418
+ padding: 12px 16px;
1419
+ font-size: 12px;
1420
+ font-weight: 600;
1421
+ text-transform: uppercase;
1422
+ letter-spacing: 0.5px;
1423
+ color: var(--text-secondary);
1424
+ background: var(--bg);
1425
+ border-bottom: 2px solid var(--border);
1426
+ }
1427
+
1428
+ .data-table td {
1429
+ padding: 12px 16px;
1430
+ font-size: 14px;
1431
+ border-bottom: 1px solid var(--border);
1432
+ }
1433
+
1434
+ .data-table tr:last-child td { border-bottom: none; }
1435
+
1436
+ .data-table tr:hover td { background: var(--accent-light); }
1437
+
1438
+ .table-scroll {
1439
+ overflow-x: auto;
1440
+ border-radius: var(--radius-md);
1441
+ border: 1px solid var(--border);
1442
+ }
1443
+
1444
+ .table-scroll .data-table {
1445
+ border: none;
1446
+ border-radius: 0;
1447
+ }
1448
+
1449
+ .data-preview {
1450
+ background: var(--surface);
1451
+ border: 1px solid var(--border);
1452
+ border-radius: var(--radius-lg);
1453
+ padding: 24px;
1454
+ box-shadow: var(--shadow-sm);
1455
+ }
1456
+
1457
+ .schema-section {
1458
+ background: var(--surface);
1459
+ border: 1px solid var(--border);
1460
+ border-radius: var(--radius-lg);
1461
+ padding: 24px;
1462
+ box-shadow: var(--shadow-sm);
1463
+ }
1464
+
1465
+ .schema-section h3 {
1466
+ font-size: 16px;
1467
+ font-weight: 600;
1468
+ margin-bottom: 16px;
1469
+ color: var(--text);
1470
+ }
1471
+
1472
+ .schema-fields {
1473
+ display: flex;
1474
+ flex-direction: column;
1475
+ gap: 8px;
1476
+ }
1477
+
1478
+ .schema-field {
1479
+ display: flex;
1480
+ align-items: center;
1481
+ gap: 12px;
1482
+ padding: 10px 16px;
1483
+ background: var(--bg);
1484
+ border-radius: var(--radius-sm);
1485
+ font-size: 14px;
1486
+ }
1487
+
1488
+ .schema-field .field-name {
1489
+ font-weight: 600;
1490
+ color: var(--text);
1491
+ min-width: 160px;
1492
+ }
1493
+
1494
+ .field-type {
1495
+ font-size: 12px;
1496
+ font-weight: 600;
1497
+ color: var(--accent);
1498
+ background: var(--accent-light);
1499
+ padding: 2px 10px;
1500
+ border-radius: var(--radius-pill);
1501
+ }
1502
+
1503
+ .discover-tasks {
1504
+ background: var(--surface);
1505
+ border: 1px solid var(--border);
1506
+ border-radius: var(--radius-lg);
1507
+ padding: 24px;
1508
+ box-shadow: var(--shadow-sm);
1509
+ }
1510
+
1511
+ .discover-tasks h3 {
1512
+ font-size: 16px;
1513
+ font-weight: 600;
1514
+ margin-bottom: 16px;
1515
+ color: var(--text);
1516
+ }
1517
+
1518
+ .task-list {
1519
+ display: flex;
1520
+ flex-direction: column;
1521
+ gap: 8px;
1522
+ }
1523
+
1524
+ .task-item {
1525
+ display: flex;
1526
+ align-items: center;
1527
+ justify-content: space-between;
1528
+ padding: 12px 16px;
1529
+ background: var(--bg);
1530
+ border-radius: var(--radius-sm);
1531
+ border: 1px solid var(--border);
1532
+ transition: var(--transition-smooth);
1533
+ }
1534
+
1535
+ .task-item:hover {
1536
+ border-color: #cbd5e1;
1537
+ }
1538
+
1539
+ .task-status {
1540
+ display: inline-flex;
1541
+ align-items: center;
1542
+ gap: 6px;
1543
+ font-size: 12px;
1544
+ font-weight: 600;
1545
+ padding: 4px 12px;
1546
+ border-radius: var(--radius-pill);
1547
+ }
1548
+
1549
+ .task-status.running {
1550
+ color: var(--accent);
1551
+ background: var(--accent-light);
1552
+ }
1553
+
1554
+ .task-status.completed {
1555
+ color: #15803d;
1556
+ background: #f0fdf4;
1557
+ }
1558
+
1559
+ .task-status.failed {
1560
+ color: #b91c1c;
1561
+ background: #fef2f2;
1562
+ }
1563
+
1564
+ .task-status.pending {
1565
+ color: var(--text-secondary);
1566
+ background: var(--bg);
1567
+ border: 1px solid var(--border);
1568
+ }
1569
+
1570
+ .empty-state {
1571
+ text-align: center;
1572
+ padding: 60px 20px;
1573
+ color: var(--text-secondary);
1574
+ font-size: 15px;
1575
+ font-weight: 500;
1576
+ }
1577
+
1578
+ .empty-state::before {
1579
+ content: '';
1580
+ display: block;
1581
+ width: 48px;
1582
+ height: 48px;
1583
+ margin: 0 auto 16px;
1584
+ background: var(--bg);
1585
+ border: 2px dashed var(--border);
1586
+ border-radius: 50%;
1587
+ }
1588
+
1589
+ /* ===========================================================================
1590
+ Responsive
1591
+ =========================================================================== */
1592
+ @media (max-width: 768px) {
1593
+ #top-bar {
1594
+ padding: 0 16px;
1595
+ gap: 16px;
1596
+ }
1597
+
1598
+ #tab-bar {
1599
+ gap: 2px;
1600
+ }
1601
+
1602
+ .tab {
1603
+ padding: 6px 12px;
1604
+ font-size: 13px;
1605
+ }
1606
+
1607
+ #content {
1608
+ padding: 24px 16px;
1609
+ }
1610
+
1611
+ .summary-cards {
1612
+ flex-direction: column;
1613
+ }
1614
+
1615
+ .stats-row {
1616
+ flex-direction: column;
1617
+ }
1618
+
1619
+ .chat-layout {
1620
+ flex-direction: column;
1621
+ height: auto;
1622
+ }
1623
+
1624
+ .chat-sidebar {
1625
+ width: 100%;
1626
+ border-right: none;
1627
+ border-bottom: 1px solid var(--border);
1628
+ max-height: 200px;
1629
+ }
1630
+
1631
+ .catalog-grid {
1632
+ grid-template-columns: 1fr;
1633
+ }
1634
+
1635
+ .ot-grid {
1636
+ grid-template-columns: 1fr;
1637
+ }
1638
+ }
1639
+
1640
+ /* ===========================================================================
1641
+ Chat Clear Button (C1 fix)
1642
+ =========================================================================== */
1643
+ .chat-clear-btn {
1644
+ padding: 6px 14px;
1645
+ font-size: 13px;
1646
+ font-weight: 500;
1647
+ font-family: inherit;
1648
+ color: var(--text-secondary);
1649
+ background: transparent;
1650
+ border: 1px solid var(--border);
1651
+ border-radius: var(--radius-sm);
1652
+ cursor: pointer;
1653
+ transition: var(--transition-smooth);
1654
+ }
1655
+
1656
+ .chat-clear-btn:hover {
1657
+ color: #dc2626;
1658
+ border-color: #fca5a5;
1659
+ background: #fef2f2;
1660
+ }
1661
+
1662
+ /* ===========================================================================
1663
+ Health Dots — CSS-styled (V1 fix)
1664
+ =========================================================================== */
1665
+ .health-dot {
1666
+ display: inline-block;
1667
+ width: 10px;
1668
+ height: 10px;
1669
+ border-radius: 50%;
1670
+ flex-shrink: 0;
1671
+ }
1672
+
1673
+ .health-dot.healthy {
1674
+ background: #22c55e;
1675
+ box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
1676
+ }
1677
+
1678
+ .health-dot.unhealthy {
1679
+ background: #ef4444;
1680
+ box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
1681
+ }
1682
+
1683
+ .health-dot.unknown {
1684
+ background: #cbd5e1;
1685
+ box-shadow: 0 0 0 3px rgba(203, 213, 225, 0.3);
1686
+ }
1687
+
1688
+ /* ===========================================================================
1689
+ Error Banner (B8 fix)
1690
+ =========================================================================== */
1691
+ .error-banner {
1692
+ padding: 16px 24px;
1693
+ background: #fef2f2;
1694
+ border: 1px solid #fca5a5;
1695
+ border-radius: var(--radius-md);
1696
+ color: #991b1b;
1697
+ font-size: 14px;
1698
+ text-align: center;
1699
+ margin: 24px;
1700
+ }
1701
+
1702
+ .error-banner a {
1703
+ color: var(--accent);
1704
+ font-weight: 600;
1705
+ text-decoration: none;
1706
+ }
1707
+
1708
+ .error-banner a:hover {
1709
+ text-decoration: underline;
1710
+ }
1711
+
1712
+ /* Chat Thinking Pulse */
1713
+ .chat-thinking-pulse {
1714
+ display: flex;
1715
+ align-items: center;
1716
+ gap: 4px;
1717
+ height: 24px;
1718
+ padding: 0 4px;
1719
+ }
1720
+ .chat-thinking-pulse .dot {
1721
+ width: 6px;
1722
+ height: 6px;
1723
+ background: var(--text-secondary);
1724
+ border-radius: 50%;
1725
+ animation: pulse 1.5s infinite ease-in-out;
1726
+ }
1727
+ .chat-thinking-pulse .dot:nth-child(1) { animation-delay: -0.32s; }
1728
+ .chat-thinking-pulse .dot:nth-child(2) { animation-delay: -0.16s; }
1729
+
1730
+ @keyframes pulse {
1731
+ 0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
1732
+ 40% { transform: scale(1); opacity: 1; }
1733
+ }
1734
+
1735
+ /* Agent Thoughts */
1736
+ .agent-thoughts {
1737
+ background: var(--bg);
1738
+ border: 1px solid var(--border);
1739
+ border-radius: var(--radius-sm);
1740
+ margin: 12px 0;
1741
+ overflow: hidden;
1742
+ }
1743
+ .agent-thoughts summary {
1744
+ padding: 10px 14px;
1745
+ cursor: pointer;
1746
+ font-size: 13px;
1747
+ font-weight: 500;
1748
+ color: var(--text-secondary);
1749
+ background: rgba(0, 0, 0, 0.02);
1750
+ user-select: none;
1751
+ transition: var(--transition-smooth);
1752
+ }
1753
+ .agent-thoughts summary:hover {
1754
+ background: rgba(0, 0, 0, 0.05);
1755
+ color: var(--text);
1756
+ }
1757
+ .agent-thoughts-content {
1758
+ padding: 16px;
1759
+ font-size: 13px;
1760
+ color: var(--text-secondary);
1761
+ border-top: 1px solid var(--border);
1762
+ background: var(--surface);
1763
+ white-space: pre-wrap;
1764
+ }
1765
+
1766
+ /* Error Boundary */
1767
+ .error-boundary {
1768
+ background: var(--surface);
1769
+ border: 1px dashed #ef4444;
1770
+ border-radius: var(--radius-lg);
1771
+ padding: 40px;
1772
+ text-align: center;
1773
+ box-shadow: var(--shadow-sm);
1774
+ margin: 20px 0;
1775
+ }
1776
+ .error-boundary .error-icon {
1777
+ font-size: 40px;
1778
+ margin-bottom: 16px;
1779
+ line-height: 1;
1780
+ }
1781
+ .error-boundary h3 {
1782
+ font-size: 16px;
1783
+ font-weight: 600;
1784
+ color: #b91c1c;
1785
+ margin-bottom: 12px;
1786
+ }
1787
+ .error-boundary p {
1788
+ color: var(--text-secondary);
1789
+ margin-bottom: 24px;
1790
+ font-size: 14px;
1791
+ }
1792
+ .retry-btn {
1793
+ padding: 10px 24px;
1794
+ background: var(--accent);
1795
+ color: #fff;
1796
+ border: none;
1797
+ border-radius: var(--radius-sm);
1798
+ cursor: pointer;
1799
+ font-size: 14px;
1800
+ font-weight: 600;
1801
+ transition: var(--transition-smooth);
1802
+ }
1803
+ .retry-btn:hover {
1804
+ background: var(--accent-hover);
1805
+ box-shadow: var(--shadow-md);
1806
+ }
1807
+
1808
+ /* Health Dots */
1809
+ .health-dot {
1810
+ display: inline-block;
1811
+ width: 10px;
1812
+ height: 10px;
1813
+ border-radius: 50%;
1814
+ margin-right: 8px;
1815
+ box-shadow: inset 0 1px 2px rgba(0,0,0,0.1);
1816
+ }
1817
+ .health-dot.healthy { background: #22c55e; }
1818
+ .health-dot.unhealthy { background: #ef4444; }
1819
+ .health-dot.unknown { background: #94a3b8; }
1820
+
1821
+ /* Dashboard Search */
1822
+ .dashboard-search {
1823
+ padding: 8px 16px;
1824
+ border: 1px solid var(--border);
1825
+ border-radius: var(--radius-pill);
1826
+ font-size: 14px;
1827
+ background: var(--bg);
1828
+ color: var(--text);
1829
+ outline: none;
1830
+ width: 280px;
1831
+ transition: var(--transition-smooth);
1832
+ }
1833
+ .dashboard-search:focus {
1834
+ border-color: var(--accent);
1835
+ box-shadow: 0 0 0 3px var(--accent-glow);
1836
+ background: var(--surface);
1837
+ }
1838
+
1839
+ /* Agent Thoughts */
1840
+ .agent-thoughts {
1841
+ margin: 12px 0;
1842
+ border: 1px solid var(--border);
1843
+ border-radius: var(--radius-sm);
1844
+ background: var(--bg);
1845
+ overflow: hidden;
1846
+ }
1847
+ .agent-thoughts summary {
1848
+ padding: 8px 12px;
1849
+ font-size: 13px;
1850
+ font-weight: 600;
1851
+ cursor: pointer;
1852
+ color: var(--text-secondary);
1853
+ background: rgba(0, 0, 0, 0.02);
1854
+ user-select: none;
1855
+ border-bottom: 1px solid transparent;
1856
+ }
1857
+ .agent-thoughts[open] summary {
1858
+ border-bottom-color: var(--border);
1859
+ color: var(--accent);
1860
+ }
1861
+ .agent-thoughts-content {
1862
+ padding: 12px;
1863
+ font-size: 13px;
1864
+ color: var(--text-secondary);
1865
+ margin: 0;
1866
+ }
1867
+ ul.agent-thoughts-content {
1868
+ padding-left: 28px;
1869
+ }
1870
+ ul.agent-thoughts-content li {
1871
+ margin-bottom: 6px;
1872
+ }
1873
+
1874
+ /* ── Chat Assistant Container (segments + progress + text) ───────────────── */
1875
+
1876
+ .chat-assistant-container {
1877
+ display: flex;
1878
+ flex-direction: column;
1879
+ gap: 10px;
1880
+ flex: 1;
1881
+ min-width: 0;
1882
+ max-width: 100%;
1883
+ overflow: hidden;
1884
+ }
1885
+
1886
+ .chat-segments {
1887
+ display: flex;
1888
+ flex-direction: column;
1889
+ gap: 8px;
1890
+ }
1891
+
1892
+ .chat-segment-bubble {
1893
+ opacity: 0.85;
1894
+ border-left: 3px solid var(--accent);
1895
+ font-size: 13px;
1896
+ }
1897
+
1898
+ /* Step divider between segments */
1899
+ .chat-step-divider {
1900
+ display: flex;
1901
+ align-items: center;
1902
+ gap: 10px;
1903
+ margin: 4px 0;
1904
+ }
1905
+ .chat-step-divider-line {
1906
+ flex: 1;
1907
+ height: 1px;
1908
+ background: var(--border);
1909
+ }
1910
+ .chat-step-divider-label {
1911
+ font-size: 11px;
1912
+ color: var(--text-secondary);
1913
+ font-weight: 600;
1914
+ white-space: nowrap;
1915
+ }
1916
+
1917
+ /* JSON data display */
1918
+ .chat-json-data {
1919
+ background: var(--bg);
1920
+ border: 1px solid var(--border);
1921
+ border-radius: var(--radius-sm);
1922
+ margin: 4px 0;
1923
+ overflow: hidden;
1924
+ }
1925
+ .chat-json-data summary {
1926
+ padding: 8px 12px;
1927
+ cursor: pointer;
1928
+ font-size: 12px;
1929
+ font-weight: 600;
1930
+ color: var(--text-secondary);
1931
+ background: rgba(0,0,0,0.02);
1932
+ user-select: none;
1933
+ }
1934
+ .chat-json-data summary:hover {
1935
+ background: rgba(0,0,0,0.05);
1936
+ color: var(--text);
1937
+ }
1938
+ .chat-json-data pre {
1939
+ margin: 0;
1940
+ padding: 12px;
1941
+ font-size: 11px;
1942
+ max-height: 250px;
1943
+ overflow: auto;
1944
+ white-space: pre-wrap;
1945
+ word-break: break-word;
1946
+ background: var(--surface);
1947
+ border-top: 1px solid var(--border);
1948
+ }
1949
+
1950
+ /* ── Inline Tool Call Card (between segments) ────────────────────────────── */
1951
+
1952
+ .chat-tool-call {
1953
+ display: flex;
1954
+ align-items: center;
1955
+ gap: 6px;
1956
+ padding: 7px 14px;
1957
+ background: var(--bg);
1958
+ border: 1px dashed var(--border);
1959
+ border-radius: var(--radius-sm);
1960
+ font-size: 12px;
1961
+ color: var(--text-secondary);
1962
+ transition: background 0.15s;
1963
+ }
1964
+ .chat-tool-call:hover {
1965
+ background: var(--surface);
1966
+ border-color: var(--accent);
1967
+ }
1968
+
1969
+ .chat-tool-call-icon {
1970
+ flex-shrink: 0;
1971
+ }
1972
+
1973
+ .chat-tool-call-name {
1974
+ font-weight: 700;
1975
+ color: var(--accent);
1976
+ }
1977
+
1978
+ .chat-tool-call-args {
1979
+ font-family: monospace;
1980
+ font-size: 11px;
1981
+ color: var(--text-secondary);
1982
+ opacity: 0.7;
1983
+ white-space: nowrap;
1984
+ overflow: hidden;
1985
+ text-overflow: ellipsis;
1986
+ max-width: 350px;
1987
+ }
1988
+
1989
+ .chat-tool-call-time {
1990
+ margin-left: auto;
1991
+ font-size: 11px;
1992
+ opacity: 0.6;
1993
+ flex-shrink: 0;
1994
+ }
1995
+
1996
+ /* ── Tool Detail Slide-out Panel ─────────────────────────────────────────── */
1997
+
1998
+ .tool-detail-panel {
1999
+ position: fixed;
2000
+ top: 0;
2001
+ right: -420px;
2002
+ width: 420px;
2003
+ height: 100vh;
2004
+ background: var(--surface);
2005
+ border-left: 1px solid var(--border);
2006
+ box-shadow: -4px 0 20px rgba(0,0,0,0.1);
2007
+ z-index: 1000;
2008
+ display: flex;
2009
+ flex-direction: column;
2010
+ transition: right 0.25s ease;
2011
+ }
2012
+ .tool-detail-panel-open {
2013
+ right: 0;
2014
+ }
2015
+
2016
+ .tool-detail-panel-header {
2017
+ display: flex;
2018
+ align-items: center;
2019
+ justify-content: space-between;
2020
+ padding: 16px 20px;
2021
+ border-bottom: 1px solid var(--border);
2022
+ background: var(--bg);
2023
+ }
2024
+
2025
+ .tool-detail-panel-title {
2026
+ font-size: 15px;
2027
+ font-weight: 700;
2028
+ color: var(--accent);
2029
+ }
2030
+
2031
+ .tool-detail-panel-close {
2032
+ background: none;
2033
+ border: none;
2034
+ font-size: 18px;
2035
+ color: var(--text-secondary);
2036
+ cursor: pointer;
2037
+ padding: 4px 8px;
2038
+ border-radius: 4px;
2039
+ }
2040
+ .tool-detail-panel-close:hover {
2041
+ background: rgba(0,0,0,0.06);
2042
+ color: var(--text);
2043
+ }
2044
+
2045
+ .tool-detail-panel-body {
2046
+ flex: 1;
2047
+ overflow-y: auto;
2048
+ padding: 16px 20px;
2049
+ }
2050
+
2051
+ .tool-detail-section {
2052
+ margin-bottom: 20px;
2053
+ }
2054
+
2055
+ .tool-detail-section-title {
2056
+ font-size: 12px;
2057
+ font-weight: 600;
2058
+ color: var(--text-secondary);
2059
+ text-transform: uppercase;
2060
+ letter-spacing: 0.5px;
2061
+ margin-bottom: 8px;
2062
+ }
2063
+
2064
+ .tool-detail-kv {
2065
+ display: flex;
2066
+ gap: 8px;
2067
+ padding: 4px 0;
2068
+ font-size: 13px;
2069
+ border-bottom: 1px solid rgba(0,0,0,0.04);
2070
+ }
2071
+
2072
+ .tool-detail-key {
2073
+ font-weight: 600;
2074
+ color: var(--accent);
2075
+ min-width: 80px;
2076
+ flex-shrink: 0;
2077
+ }
2078
+
2079
+ .tool-detail-val {
2080
+ color: var(--text);
2081
+ word-break: break-word;
2082
+ }
2083
+
2084
+ .tool-detail-section pre {
2085
+ margin: 0;
2086
+ padding: 12px;
2087
+ background: var(--bg);
2088
+ border: 1px solid var(--border);
2089
+ border-radius: var(--radius-sm);
2090
+ font-size: 11px;
2091
+ line-height: 1.5;
2092
+ max-height: 400px;
2093
+ overflow: auto;
2094
+ white-space: pre-wrap;
2095
+ word-break: break-word;
2096
+ }
2097
+
2098
+ .tool-detail-empty {
2099
+ color: var(--text-secondary);
2100
+ font-size: 13px;
2101
+ text-align: center;
2102
+ padding: 20px;
2103
+ }
2104
+
2105
+ .chat-progress-inline {
2106
+ padding: 4px 0;
2107
+ }
2108
+
2109
+ .chat-trace-holder {
2110
+ margin-top: 4px;
2111
+ }
2112
+
2113
+ /* ── Chat Progress Card (legacy / progress events) ──────────────────────── */
2114
+
2115
+ .chat-progress-card {
2116
+ background: var(--bg);
2117
+ border: 1px solid var(--border);
2118
+ border-radius: var(--radius-lg);
2119
+ padding: 12px 16px;
2120
+ font-size: 13px;
2121
+ }
2122
+
2123
+ .chat-progress-header {
2124
+ display: flex;
2125
+ align-items: center;
2126
+ gap: 8px;
2127
+ font-size: 12px;
2128
+ font-weight: 600;
2129
+ color: var(--text-secondary);
2130
+ margin-bottom: 8px;
2131
+ }
2132
+
2133
+ /* Tool call detail styles */
2134
+ .tool-detail {
2135
+ width: 100%;
2136
+ margin-top: 6px;
2137
+ padding-left: 24px;
2138
+ font-size: 12px;
2139
+ }
2140
+
2141
+ .tool-args {
2142
+ display: flex;
2143
+ flex-wrap: wrap;
2144
+ gap: 4px 10px;
2145
+ margin-bottom: 4px;
2146
+ }
2147
+
2148
+ .tool-arg {
2149
+ background: rgba(0,0,0,0.04);
2150
+ padding: 2px 8px;
2151
+ border-radius: 4px;
2152
+ font-family: monospace;
2153
+ font-size: 11px;
2154
+ }
2155
+
2156
+ .tool-arg-name {
2157
+ color: var(--accent);
2158
+ font-weight: 500;
2159
+ }
2160
+
2161
+ .tool-type-badge {
2162
+ background: var(--accent-glow);
2163
+ color: var(--accent);
2164
+ padding: 1px 8px;
2165
+ border-radius: 10px;
2166
+ font-size: 11px;
2167
+ font-weight: 500;
2168
+ }
2169
+
2170
+ .tool-io {
2171
+ color: var(--text-secondary);
2172
+ margin-bottom: 4px;
2173
+ line-height: 1.5;
2174
+ }
2175
+
2176
+ .tool-io-label {
2177
+ font-weight: 500;
2178
+ margin-right: 4px;
2179
+ }
2180
+
2181
+ .tool-io-value {
2182
+ font-family: monospace;
2183
+ font-size: 11px;
2184
+ word-break: break-word;
2185
+ }
2186
+
2187
+ .tool-result-full pre {
2188
+ margin: 4px 0 0;
2189
+ padding: 8px;
2190
+ background: var(--surface);
2191
+ border: 1px solid var(--border);
2192
+ border-radius: var(--radius-sm);
2193
+ font-size: 11px;
2194
+ max-height: 200px;
2195
+ overflow: auto;
2196
+ white-space: pre-wrap;
2197
+ word-break: break-word;
2198
+ }
2199
+
2200
+ .tool-expand {
2201
+ cursor: pointer;
2202
+ color: var(--accent);
2203
+ font-size: 11px;
2204
+ margin-left: 6px;
2205
+ }
2206
+
2207
+ .tool-expand:hover {
2208
+ text-decoration: underline;
2209
+ }
2210
+
2211
+ .tool-meta-info {
2212
+ margin-top: 4px;
2213
+ }
2214
+
2215
+ /* Auth error card */
2216
+ .chat-auth-error {
2217
+ text-align: center;
2218
+ padding: 16px 12px;
2219
+ }
2220
+ .chat-auth-error-icon {
2221
+ font-size: 28px;
2222
+ margin-bottom: 8px;
2223
+ }
2224
+ .chat-auth-error-title {
2225
+ font-size: 15px;
2226
+ font-weight: 600;
2227
+ color: var(--text);
2228
+ margin-bottom: 6px;
2229
+ }
2230
+ .chat-auth-error-desc {
2231
+ font-size: 13px;
2232
+ color: var(--text-secondary);
2233
+ margin-bottom: 10px;
2234
+ }
2235
+ .chat-auth-error-cmd code {
2236
+ display: inline-block;
2237
+ background: var(--bg);
2238
+ border: 1px solid var(--border);
2239
+ padding: 6px 16px;
2240
+ border-radius: var(--radius-sm);
2241
+ font-size: 13px;
2242
+ font-weight: 600;
2243
+ color: var(--accent);
2244
+ user-select: all;
2245
+ }
2246
+
2247
+ .chat-stopped {
2248
+ color: var(--text-secondary);
2249
+ font-style: italic;
2250
+ }
2251
+ .chat-error {
2252
+ color: #ef4444;
2253
+ }
2254
+ .chat-error-detail {
2255
+ margin-top: 8px;
2256
+ font-size: 12px;
2257
+ color: #6b7280;
2258
+ }
2259
+ .chat-error-detail summary {
2260
+ cursor: pointer;
2261
+ color: #9ca3af;
2262
+ user-select: none;
2263
+ }
2264
+ .chat-error-detail pre {
2265
+ margin-top: 4px;
2266
+ padding: 8px 12px;
2267
+ background: #fef2f2;
2268
+ border: 1px solid #fecaca;
2269
+ border-radius: 6px;
2270
+ white-space: pre-wrap;
2271
+ word-break: break-all;
2272
+ max-height: 200px;
2273
+ overflow-y: auto;
2274
+ font-size: 11px;
2275
+ color: #b91c1c;
2276
+ }
2277
+ /* Blinking cursor shown at end of streaming text */
2278
+ .chat-streaming-cursor::after {
2279
+ content: "▍";
2280
+ animation: blink-cursor 0.8s steps(2) infinite;
2281
+ color: var(--accent);
2282
+ font-weight: bold;
2283
+ }
2284
+ @keyframes blink-cursor {
2285
+ 0% { opacity: 1; }
2286
+ 50% { opacity: 0; }
2287
+ }
2288
+ .chat-stall-warning {
2289
+ color: var(--text-secondary);
2290
+ font-size: 0.85em;
2291
+ font-style: italic;
2292
+ margin-top: 6px;
2293
+ }
2294
+
2295
+ /* ── Trace Section ────────────────────────────────────────────────────────── */
2296
+
2297
+ .trace-section {
2298
+ margin-top: 12px;
2299
+ border-top: 1px solid var(--border);
2300
+ padding-top: 8px;
2301
+ font-size: 13px;
2302
+ }
2303
+
2304
+ .trace-header {
2305
+ cursor: pointer;
2306
+ color: var(--text-secondary);
2307
+ font-size: 12px;
2308
+ padding: 4px 0;
2309
+ user-select: none;
2310
+ }
2311
+
2312
+ .trace-header:hover {
2313
+ color: var(--text);
2314
+ }
2315
+
2316
+ .trace-toggle {
2317
+ display: inline-block;
2318
+ transition: transform 0.2s;
2319
+ margin-right: 4px;
2320
+ font-size: 10px;
2321
+ }
2322
+
2323
+ .trace-expanded .trace-toggle {
2324
+ transform: rotate(90deg);
2325
+ }
2326
+
2327
+ .trace-body {
2328
+ display: none;
2329
+ padding: 4px 0 4px 8px;
2330
+ }
2331
+
2332
+ .trace-expanded .trace-body {
2333
+ display: block;
2334
+ }
2335
+
2336
+ .trace-steps {
2337
+ display: flex;
2338
+ flex-direction: column;
2339
+ gap: 4px;
2340
+ }
2341
+
2342
+ .trace-step {
2343
+ display: flex;
2344
+ align-items: flex-start;
2345
+ flex-wrap: wrap;
2346
+ gap: 6px;
2347
+ padding: 4px 8px;
2348
+ border-radius: var(--radius-sm);
2349
+ background: var(--bg);
2350
+ }
2351
+
2352
+ .trace-step-icon {
2353
+ flex-shrink: 0;
2354
+ width: 18px;
2355
+ text-align: center;
2356
+ }
2357
+
2358
+ .trace-step-name {
2359
+ font-weight: 500;
2360
+ color: var(--text);
2361
+ }
2362
+
2363
+ .trace-step-desc {
2364
+ color: var(--text-secondary);
2365
+ font-size: 12px;
2366
+ }
2367
+
2368
+ .trace-step-duration {
2369
+ margin-left: auto;
2370
+ color: var(--text-secondary);
2371
+ font-size: 12px;
2372
+ flex-shrink: 0;
2373
+ }
2374
+
2375
+ .trace-spinner {
2376
+ display: inline-block;
2377
+ width: 14px;
2378
+ height: 14px;
2379
+ border: 2px solid var(--border);
2380
+ border-top-color: var(--accent);
2381
+ border-radius: 50%;
2382
+ animation: trace-spin 0.8s linear infinite;
2383
+ }
2384
+
2385
+ @keyframes trace-spin {
2386
+ to { transform: rotate(360deg); }
2387
+ }
2388
+
2389
+ /* ── Trace Detail (Level 2) ──────────────────────────────────────────────── */
2390
+
2391
+ .trace-detail {
2392
+ width: 100%;
2393
+ margin-top: 4px;
2394
+ margin-left: 24px;
2395
+ }
2396
+
2397
+ .trace-detail-toggle {
2398
+ cursor: pointer;
2399
+ color: var(--accent);
2400
+ font-size: 12px;
2401
+ user-select: none;
2402
+ }
2403
+
2404
+ .trace-detail-toggle:hover {
2405
+ text-decoration: underline;
2406
+ }
2407
+
2408
+ .trace-detail-content {
2409
+ display: none;
2410
+ margin-top: 4px;
2411
+ }
2412
+
2413
+ .trace-detail-expanded .trace-detail-content {
2414
+ display: block;
2415
+ }
2416
+
2417
+ .trace-kv {
2418
+ margin-bottom: 6px;
2419
+ }
2420
+
2421
+ .trace-kv-label {
2422
+ font-size: 11px;
2423
+ color: var(--text-secondary);
2424
+ font-weight: 500;
2425
+ }
2426
+
2427
+ .trace-kv pre {
2428
+ margin: 2px 0 0 0;
2429
+ padding: 8px;
2430
+ background: var(--surface);
2431
+ border: 1px solid var(--border);
2432
+ border-radius: var(--radius-sm);
2433
+ font-size: 11px;
2434
+ line-height: 1.4;
2435
+ overflow-x: auto;
2436
+ max-height: 200px;
2437
+ overflow-y: auto;
2438
+ white-space: pre-wrap;
2439
+ word-break: break-word;
2440
+ }