@hef2024/llmasaservice-ui 0.16.8

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.
@@ -0,0 +1,1618 @@
1
+ /* ============================================================================
2
+ AI CHAT PANEL CSS
3
+
4
+ Uses CSS variables from AIAgentPanel.css for consistent theming.
5
+ This file extends those variables with chat-specific styles.
6
+ ============================================================================ */
7
+
8
+ /* ============================================================================
9
+ CSS Variables - Chat Specific
10
+ ============================================================================ */
11
+
12
+ :root {
13
+ /* Messages */
14
+ --ai-chat-user-bg: #e5e7eb;
15
+ --ai-chat-user-text: #1f2937;
16
+ --ai-chat-assistant-bg: transparent;
17
+ --ai-chat-assistant-text: #374151;
18
+ --ai-chat-message-radius: 12px;
19
+ --ai-chat-message-padding: 12px 16px;
20
+ --ai-chat-message-max-width: 85%;
21
+
22
+ /* Input */
23
+ --ai-chat-input-bg: #ffffff;
24
+ --ai-chat-input-border: #d1d5db;
25
+ --ai-chat-input-text: #1f2937;
26
+ --ai-chat-input-placeholder: #9ca3af;
27
+ --ai-chat-input-focus-border: #3b82f6;
28
+ --ai-chat-input-focus-ring: rgba(59, 130, 246, 0.2);
29
+ --ai-chat-input-radius: 12px;
30
+
31
+ /* Suggestions */
32
+ --ai-chat-suggestion-bg: #f3f4f6;
33
+ --ai-chat-suggestion-border: #e5e7eb;
34
+ --ai-chat-suggestion-text: #374151;
35
+ --ai-chat-suggestion-hover-bg: #e5e7eb;
36
+
37
+ /* Thinking Blocks */
38
+ --ai-chat-thinking-bg: #f0f9ff;
39
+ --ai-chat-thinking-border: #bae6fd;
40
+ --ai-chat-thinking-text: #0c4a6e;
41
+ --ai-chat-thinking-icon: #0369a1;
42
+
43
+ /* Loading */
44
+ --ai-chat-loading-dot: #9ca3af;
45
+
46
+ /* Footer */
47
+ --ai-chat-footer-text: #9ca3af;
48
+ --ai-chat-footer-link: #3b82f6;
49
+
50
+ /* Tools Status */
51
+ --ai-chat-tools-ready: #22c55e;
52
+ --ai-chat-tools-loading: #f59e0b;
53
+ --ai-chat-tools-error: #ef4444;
54
+ }
55
+
56
+ /* Dark Theme */
57
+ .dark-theme {
58
+ --ai-chat-user-bg: #374151;
59
+ --ai-chat-user-text: #f9fafb;
60
+ --ai-chat-assistant-bg: transparent;
61
+ --ai-chat-assistant-text: #e5e7eb;
62
+
63
+ --ai-chat-input-bg: #1f2937;
64
+ --ai-chat-input-border: #374151;
65
+ --ai-chat-input-text: #f9fafb;
66
+ --ai-chat-input-placeholder: #6b7280;
67
+ --ai-chat-input-focus-border: #60a5fa;
68
+ --ai-chat-input-focus-ring: rgba(96, 165, 250, 0.2);
69
+
70
+ --ai-chat-suggestion-bg: #1f2937;
71
+ --ai-chat-suggestion-border: #374151;
72
+ --ai-chat-suggestion-text: #e5e7eb;
73
+ --ai-chat-suggestion-hover-bg: #374151;
74
+
75
+ --ai-chat-thinking-bg: #0c4a6e;
76
+ --ai-chat-thinking-border: #0369a1;
77
+ --ai-chat-thinking-text: #e0f2fe;
78
+ --ai-chat-thinking-icon: #7dd3fc;
79
+
80
+ --ai-chat-loading-dot: #6b7280;
81
+
82
+ --ai-chat-footer-text: #6b7280;
83
+ --ai-chat-footer-link: #60a5fa;
84
+ }
85
+
86
+ /* ============================================================================
87
+ Base Panel Styles
88
+ ============================================================================ */
89
+
90
+ .ai-chat-panel {
91
+ display: flex;
92
+ flex-direction: column;
93
+ flex: 1;
94
+ width: 100%;
95
+ min-width: 0;
96
+ min-height: 0;
97
+ overflow: hidden;
98
+ background-color: var(--ai-chat-bg, #ffffff);
99
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
100
+ font-size: 14px;
101
+ color: var(--ai-chat-assistant-text);
102
+ }
103
+
104
+ .dark-theme.ai-chat-panel {
105
+ background-color: var(--ai-chat-bg, #111827);
106
+ }
107
+
108
+ /* ============================================================================
109
+ Title
110
+ ============================================================================ */
111
+
112
+ .ai-chat-panel__title {
113
+ padding: 12px 16px;
114
+ font-size: 16px;
115
+ font-weight: 600;
116
+ border-bottom: 1px solid var(--ai-sidebar-border, #e5e7eb);
117
+ flex-shrink: 0;
118
+ }
119
+
120
+ /* ============================================================================
121
+ Messages Area
122
+ ============================================================================ */
123
+
124
+ .ai-chat-panel__messages {
125
+ flex: 1;
126
+ overflow-y: auto;
127
+ overflow-x: hidden;
128
+ padding: 16px;
129
+ display: flex;
130
+ flex-direction: column;
131
+ gap: 16px;
132
+ min-width: 0;
133
+ min-height: 0;
134
+ }
135
+
136
+ /* Entry container */
137
+ .ai-chat-entry {
138
+ display: flex;
139
+ flex-direction: column;
140
+ gap: 12px;
141
+ }
142
+
143
+ /* ============================================================================
144
+ Message Bubbles
145
+ ============================================================================ */
146
+
147
+ .ai-chat-message {
148
+ display: flex;
149
+ flex-direction: column;
150
+ max-width: var(--ai-chat-message-max-width);
151
+ min-width: 0;
152
+ word-wrap: break-word;
153
+ overflow-wrap: break-word;
154
+ }
155
+
156
+ .ai-chat-message--user {
157
+ align-self: flex-end;
158
+ }
159
+
160
+ .ai-chat-message--user .ai-chat-message__content {
161
+ background-color: var(--ai-chat-user-bg);
162
+ color: var(--ai-chat-user-text);
163
+ border-radius: var(--ai-chat-message-radius);
164
+ border-bottom-right-radius: 4px;
165
+ padding: var(--ai-chat-message-padding);
166
+ }
167
+
168
+ .ai-chat-message--assistant {
169
+ align-self: flex-start;
170
+ max-width: 100%;
171
+ }
172
+
173
+ .ai-chat-message--assistant .ai-chat-message__content {
174
+ background-color: var(--ai-chat-assistant-bg);
175
+ color: var(--ai-chat-assistant-text);
176
+ padding: 4px 0;
177
+ word-wrap: break-word;
178
+ overflow-wrap: break-word;
179
+ min-width: 0;
180
+ }
181
+
182
+ /* Message Content Markdown Styles */
183
+ .ai-chat-message__content p {
184
+ margin: 0 0 0.75em 0;
185
+ line-height: 1.6;
186
+ }
187
+
188
+ .ai-chat-message__content p:last-child {
189
+ margin-bottom: 0;
190
+ }
191
+
192
+ .ai-chat-message__content ul,
193
+ .ai-chat-message__content ol {
194
+ margin: 0 0 1em 0;
195
+ padding-left: 1.5em;
196
+ line-height: 1.6;
197
+ }
198
+
199
+ .ai-chat-message__content li {
200
+ margin: 0.5em 0;
201
+ line-height: 1.6;
202
+ }
203
+
204
+ .ai-chat-message__content li:first-child {
205
+ margin-top: 0;
206
+ }
207
+
208
+ .ai-chat-message__content li:last-child {
209
+ margin-bottom: 0;
210
+ }
211
+
212
+ .ai-chat-message__content ul ul,
213
+ .ai-chat-message__content ol ol,
214
+ .ai-chat-message__content ul ol,
215
+ .ai-chat-message__content ol ul {
216
+ margin-top: 0.5em;
217
+ margin-bottom: 0.5em;
218
+ }
219
+
220
+ /* Headings */
221
+ .ai-chat-message__content h1,
222
+ .ai-chat-message__content h2,
223
+ .ai-chat-message__content h3,
224
+ .ai-chat-message__content h4,
225
+ .ai-chat-message__content h5,
226
+ .ai-chat-message__content h6 {
227
+ margin: 1.25em 0 0.75em 0;
228
+ line-height: 1.4;
229
+ font-weight: 600;
230
+ }
231
+
232
+ .ai-chat-message__content h1:first-child,
233
+ .ai-chat-message__content h2:first-child,
234
+ .ai-chat-message__content h3:first-child,
235
+ .ai-chat-message__content h4:first-child,
236
+ .ai-chat-message__content h5:first-child,
237
+ .ai-chat-message__content h6:first-child {
238
+ margin-top: 0;
239
+ }
240
+
241
+ /* Tables */
242
+ .ai-chat-message__content table {
243
+ margin: 1em 0;
244
+ border-collapse: collapse;
245
+ width: 100%;
246
+ }
247
+
248
+ .ai-chat-message__content th,
249
+ .ai-chat-message__content td {
250
+ padding: 0.5em 0.75em;
251
+ border: 1px solid rgba(0, 0, 0, 0.1);
252
+ line-height: 1.5;
253
+ }
254
+
255
+ .dark-theme .ai-chat-message__content th,
256
+ .dark-theme .ai-chat-message__content td {
257
+ border-color: rgba(255, 255, 255, 0.1);
258
+ }
259
+
260
+ .ai-chat-message__content th {
261
+ font-weight: 600;
262
+ background-color: rgba(0, 0, 0, 0.05);
263
+ }
264
+
265
+ .dark-theme .ai-chat-message__content th {
266
+ background-color: rgba(255, 255, 255, 0.05);
267
+ }
268
+
269
+ .ai-chat-message__content tr {
270
+ line-height: 1.5;
271
+ }
272
+
273
+ /* Blockquotes */
274
+ .ai-chat-message__content blockquote {
275
+ margin: 1em 0;
276
+ padding: 0.5em 1em;
277
+ border-left: 4px solid rgba(0, 0, 0, 0.2);
278
+ background-color: rgba(0, 0, 0, 0.02);
279
+ line-height: 1.6;
280
+ }
281
+
282
+ .dark-theme .ai-chat-message__content blockquote {
283
+ border-left-color: rgba(255, 255, 255, 0.2);
284
+ background-color: rgba(255, 255, 255, 0.02);
285
+ }
286
+
287
+ /* Horizontal rules */
288
+ .ai-chat-message__content hr {
289
+ margin: 1.5em 0;
290
+ border: none;
291
+ border-top: 1px solid rgba(0, 0, 0, 0.1);
292
+ }
293
+
294
+ .dark-theme .ai-chat-message__content hr {
295
+ border-top-color: rgba(255, 255, 255, 0.1);
296
+ }
297
+
298
+ .ai-chat-message__content code {
299
+ background-color: rgba(0, 0, 0, 0.05);
300
+ padding: 0.2em 0.4em;
301
+ border-radius: 4px;
302
+ font-size: 0.9em;
303
+ font-family: 'SF Mono', Monaco, Consolas, monospace;
304
+ }
305
+
306
+ .dark-theme .ai-chat-message__content code {
307
+ background-color: rgba(255, 255, 255, 0.1);
308
+ }
309
+
310
+ .ai-chat-message__content pre {
311
+ margin: 0.75em 0;
312
+ border-radius: 8px;
313
+ overflow: hidden;
314
+ }
315
+
316
+ .ai-chat-message__content pre code {
317
+ background: none;
318
+ padding: 0;
319
+ }
320
+
321
+ .ai-chat-message__content a {
322
+ color: var(--ai-chat-footer-link);
323
+ text-decoration: none;
324
+ }
325
+
326
+ .ai-chat-message__content a:hover {
327
+ text-decoration: underline;
328
+ }
329
+
330
+ /* Action Buttons */
331
+ .ai-chat-message__actions {
332
+ display: flex;
333
+ gap: 4px;
334
+ margin-top: 8px;
335
+ opacity: 0;
336
+ transition: opacity 0.2s;
337
+ }
338
+
339
+ .ai-chat-message:hover .ai-chat-message__actions {
340
+ opacity: 1;
341
+ }
342
+
343
+ /* ============================================================================
344
+ Thinking Blocks
345
+ ============================================================================ */
346
+
347
+ .ai-chat-thinking {
348
+ background-color: var(--ai-chat-thinking-bg);
349
+ border: 1px solid var(--ai-chat-thinking-border);
350
+ border-radius: 8px;
351
+ padding: 12px;
352
+ margin-bottom: 12px;
353
+ font-size: 13px;
354
+ }
355
+
356
+ .ai-chat-thinking__header {
357
+ display: flex;
358
+ align-items: center;
359
+ gap: 8px;
360
+ margin-bottom: 8px;
361
+ color: var(--ai-chat-thinking-text);
362
+ }
363
+
364
+ .ai-chat-thinking__icon {
365
+ color: var(--ai-chat-thinking-icon);
366
+ }
367
+
368
+ .ai-chat-thinking__title {
369
+ font-weight: 600;
370
+ flex: 1;
371
+ }
372
+
373
+ .ai-chat-thinking__nav {
374
+ display: flex;
375
+ align-items: center;
376
+ gap: 4px;
377
+ font-size: 12px;
378
+ }
379
+
380
+ .ai-chat-thinking__nav button {
381
+ background: none;
382
+ border: none;
383
+ color: var(--ai-chat-thinking-icon);
384
+ cursor: pointer;
385
+ padding: 2px 6px;
386
+ font-size: 14px;
387
+ border-radius: 4px;
388
+ }
389
+
390
+ .ai-chat-thinking__nav button:hover:not(:disabled) {
391
+ background-color: rgba(0, 0, 0, 0.1);
392
+ }
393
+
394
+ .ai-chat-thinking__nav button:disabled {
395
+ opacity: 0.4;
396
+ cursor: not-allowed;
397
+ }
398
+
399
+ .ai-chat-thinking__content {
400
+ color: var(--ai-chat-thinking-text);
401
+ opacity: 0.9;
402
+ line-height: 1.5;
403
+ }
404
+
405
+ /* ============================================================================
406
+ Loading Animation
407
+ ============================================================================ */
408
+
409
+ .ai-chat-loading {
410
+ display: flex;
411
+ align-items: center;
412
+ gap: 4px;
413
+ color: var(--ai-chat-loading-dot);
414
+ }
415
+
416
+ .ai-chat-loading__dots {
417
+ display: flex;
418
+ gap: 4px;
419
+ }
420
+
421
+ .ai-chat-loading__dot {
422
+ width: 6px;
423
+ height: 6px;
424
+ background-color: var(--ai-chat-loading-dot);
425
+ border-radius: 50%;
426
+ animation: ai-chat-dot-bounce 1.4s ease-in-out infinite both;
427
+ }
428
+
429
+ .ai-chat-loading__dot:nth-child(1) {
430
+ animation-delay: -0.32s;
431
+ }
432
+
433
+ .ai-chat-loading__dot:nth-child(2) {
434
+ animation-delay: -0.16s;
435
+ }
436
+
437
+ @keyframes ai-chat-dot-bounce {
438
+ 0%, 80%, 100% {
439
+ transform: scale(0.6);
440
+ opacity: 0.4;
441
+ }
442
+ 40% {
443
+ transform: scale(1);
444
+ opacity: 1;
445
+ }
446
+ }
447
+
448
+ /* ============================================================================
449
+ Suggestions
450
+ ============================================================================ */
451
+
452
+ .ai-chat-suggestions {
453
+ display: flex;
454
+ flex-wrap: wrap;
455
+ gap: 8px;
456
+ margin-top: 8px;
457
+ width: 100%;
458
+ min-width: 0;
459
+ }
460
+
461
+ .ai-chat-suggestions__button {
462
+ font-size: 13px;
463
+ white-space: normal;
464
+ text-align: left;
465
+ height: auto;
466
+ padding: 8px 12px;
467
+ min-width: 0;
468
+ max-width: 100%;
469
+ word-wrap: break-word;
470
+ overflow-wrap: break-word;
471
+ }
472
+
473
+ /* ============================================================================
474
+ New Conversation Button
475
+ ============================================================================ */
476
+
477
+ .ai-chat-panel__new-conversation {
478
+ padding: 8px 16px;
479
+ display: flex;
480
+ justify-content: center;
481
+ flex-shrink: 0;
482
+ }
483
+
484
+ .ai-chat-new-conversation {
485
+ width: 100%;
486
+ }
487
+
488
+ /* ============================================================================
489
+ Input Area
490
+ ============================================================================ */
491
+
492
+ .ai-chat-panel__input {
493
+ display: flex;
494
+ align-items: flex-end;
495
+ gap: 8px;
496
+ padding: 12px 16px;
497
+ border-top: 1px solid var(--ai-sidebar-border, #e5e7eb);
498
+ flex-shrink: 0;
499
+ }
500
+
501
+ .ai-chat-input {
502
+ flex: 1;
503
+ min-height: 40px;
504
+ max-height: 200px;
505
+ padding: 10px 14px;
506
+ background-color: var(--ai-chat-input-bg);
507
+ border: 1px solid var(--ai-chat-input-border);
508
+ border-radius: var(--ai-chat-input-radius);
509
+ color: var(--ai-chat-input-text);
510
+ font-size: 14px;
511
+ font-family: inherit;
512
+ line-height: 1.5;
513
+ resize: none;
514
+ outline: none;
515
+ transition: border-color 0.2s, box-shadow 0.2s;
516
+ }
517
+
518
+ .ai-chat-input::placeholder {
519
+ color: var(--ai-chat-input-placeholder);
520
+ }
521
+
522
+ .ai-chat-input:focus {
523
+ border-color: var(--ai-chat-input-focus-border);
524
+ box-shadow: 0 0 0 3px var(--ai-chat-input-focus-ring);
525
+ }
526
+
527
+ /* Send button - Cursor style circular with up arrow */
528
+ .ai-chat-send-button {
529
+ display: flex;
530
+ align-items: center;
531
+ justify-content: center;
532
+ width: 24px;
533
+ height: 24px;
534
+ padding: 0;
535
+ border: none;
536
+ border-radius: 6px;
537
+ background-color: var(--ai-button-primary-bg, #3b82f6);
538
+ color: white;
539
+ cursor: pointer;
540
+ transition: background-color 0.15s, opacity 0.15s;
541
+ flex-shrink: 0;
542
+ }
543
+
544
+ .ai-chat-send-button:hover:not(:disabled) {
545
+ background-color: var(--ai-button-primary-hover, #2563eb);
546
+ }
547
+
548
+ .ai-chat-send-button--disabled,
549
+ .ai-chat-send-button:disabled {
550
+ opacity: 0.4;
551
+ cursor: not-allowed;
552
+ }
553
+
554
+ .ai-chat-send-button--stop {
555
+ background-color: var(--ai-chat-tools-error, #ef4444);
556
+ }
557
+
558
+ .ai-chat-send-button--stop:hover:not(:disabled) {
559
+ background-color: #dc2626;
560
+ }
561
+
562
+ /* ============================================================================
563
+ Footer
564
+ ============================================================================ */
565
+
566
+ .ai-chat-panel__footer {
567
+ display: flex;
568
+ align-items: center;
569
+ justify-content: space-between;
570
+ padding: 8px 16px;
571
+ font-size: 12px;
572
+ color: var(--ai-chat-footer-text);
573
+ border-top: 1px solid var(--ai-sidebar-border, #e5e7eb);
574
+ flex-shrink: 0;
575
+ }
576
+
577
+ /* Tools Status */
578
+ .ai-chat-tools-status {
579
+ display: flex;
580
+ align-items: center;
581
+ gap: 6px;
582
+ }
583
+
584
+ .ai-chat-tools-status__dot {
585
+ width: 8px;
586
+ height: 8px;
587
+ border-radius: 50%;
588
+ }
589
+
590
+ .ai-chat-tools-status__dot.ready {
591
+ background-color: var(--ai-chat-tools-ready);
592
+ }
593
+
594
+ .ai-chat-tools-status__dot.loading {
595
+ background-color: var(--ai-chat-tools-loading);
596
+ animation: ai-chat-pulse 1.5s ease-in-out infinite;
597
+ }
598
+
599
+ .ai-chat-tools-status__dot.error {
600
+ background-color: var(--ai-chat-tools-error);
601
+ }
602
+
603
+ @keyframes ai-chat-pulse {
604
+ 0%, 100% {
605
+ opacity: 1;
606
+ }
607
+ 50% {
608
+ opacity: 0.4;
609
+ }
610
+ }
611
+
612
+ /* Powered By */
613
+ .ai-chat-powered-by {
614
+ display: flex;
615
+ align-items: center;
616
+ gap: 6px;
617
+ }
618
+
619
+ .ai-chat-powered-by a {
620
+ display: flex;
621
+ align-items: center;
622
+ gap: 4px;
623
+ color: var(--ai-chat-footer-link);
624
+ text-decoration: none;
625
+ }
626
+
627
+ .ai-chat-powered-by a:hover {
628
+ text-decoration: underline;
629
+ }
630
+
631
+ /* ============================================================================
632
+ Icons
633
+ ============================================================================ */
634
+
635
+ .ai-chat-icon {
636
+ width: 20px;
637
+ height: 20px;
638
+ }
639
+
640
+ .ai-chat-icon-sm {
641
+ width: 16px;
642
+ height: 16px;
643
+ }
644
+
645
+ /* ============================================================================
646
+ Scrollbar Styling
647
+ ============================================================================ */
648
+
649
+ .ai-chat-panel__messages::-webkit-scrollbar {
650
+ width: 6px;
651
+ }
652
+
653
+ .ai-chat-panel__messages::-webkit-scrollbar-track {
654
+ background: transparent;
655
+ }
656
+
657
+ .ai-chat-panel__messages::-webkit-scrollbar-thumb {
658
+ background-color: rgba(0, 0, 0, 0.2);
659
+ border-radius: 3px;
660
+ }
661
+
662
+ .dark-theme .ai-chat-panel__messages::-webkit-scrollbar-thumb {
663
+ background-color: rgba(255, 255, 255, 0.2);
664
+ }
665
+
666
+ .ai-chat-panel__messages::-webkit-scrollbar-thumb:hover {
667
+ background-color: rgba(0, 0, 0, 0.3);
668
+ }
669
+
670
+ .dark-theme .ai-chat-panel__messages::-webkit-scrollbar-thumb:hover {
671
+ background-color: rgba(255, 255, 255, 0.3);
672
+ }
673
+
674
+ /* ============================================================================
675
+ Responsive
676
+ ============================================================================ */
677
+
678
+ @media (max-width: 480px) {
679
+ .ai-chat-message {
680
+ max-width: 95%;
681
+ }
682
+
683
+ .ai-chat-suggestions {
684
+ flex-direction: column;
685
+ }
686
+
687
+ .ai-chat-suggestions__button {
688
+ width: 100%;
689
+ }
690
+ }
691
+
692
+ /* ============================================================================
693
+ Narrow Panel Responsive (for resizable panels at min-width)
694
+ ============================================================================ */
695
+
696
+ /* Container query fallback - handles narrow panel widths */
697
+ .ai-chat-panel {
698
+ container-type: inline-size;
699
+ container-name: chat-panel;
700
+ }
701
+
702
+ /* When panel is narrow, stack suggestions vertically */
703
+ @container chat-panel (max-width: 380px) {
704
+ .ai-chat-suggestions {
705
+ flex-direction: column;
706
+ }
707
+
708
+ .ai-chat-suggestions__button {
709
+ width: 100%;
710
+ min-width: 0;
711
+ text-align: left;
712
+ word-wrap: break-word;
713
+ overflow-wrap: break-word;
714
+ hyphens: auto;
715
+ }
716
+
717
+ .ai-chat-message__content {
718
+ word-wrap: break-word;
719
+ overflow-wrap: break-word;
720
+ hyphens: auto;
721
+ }
722
+
723
+ .ai-chat-panel__messages {
724
+ padding: 12px;
725
+ }
726
+
727
+ .ai-chat-panel__input {
728
+ padding: 10px 12px;
729
+ }
730
+
731
+ .ai-chat-input {
732
+ min-height: 36px;
733
+ padding: 8px 12px;
734
+ font-size: 13px;
735
+ }
736
+ }
737
+
738
+ /* Extra narrow - more aggressive wrapping */
739
+ @container chat-panel (max-width: 320px) {
740
+ .ai-chat-panel__messages {
741
+ padding: 8px;
742
+ }
743
+
744
+ .ai-chat-panel__input {
745
+ padding: 8px;
746
+ gap: 6px;
747
+ }
748
+
749
+ .ai-chat-suggestions__button {
750
+ padding: 6px 10px;
751
+ font-size: 12px;
752
+ }
753
+
754
+ .ai-chat-send-button {
755
+ width: 36px;
756
+ height: 36px;
757
+ }
758
+ }
759
+
760
+ /* ============================================================================
761
+ Input Container (wraps input + agent selector) - Cursor-style unified box
762
+ ============================================================================ */
763
+
764
+ .ai-chat-panel__input-container {
765
+ margin: 12px 16px;
766
+ border: 1px solid var(--ai-chat-input-border);
767
+ border-radius: var(--ai-chat-input-radius);
768
+ background-color: var(--ai-chat-input-bg);
769
+ flex-shrink: 0;
770
+ transition: border-color 0.2s, box-shadow 0.2s;
771
+ }
772
+
773
+ .ai-chat-panel__input-container:focus-within {
774
+ border-color: var(--ai-chat-input-focus-border);
775
+ box-shadow: 0 0 0 3px var(--ai-chat-input-focus-ring);
776
+ }
777
+
778
+ .ai-chat-panel__input-container--dropdown-open {
779
+ border-color: var(--ai-chat-input-focus-border);
780
+ }
781
+
782
+ .ai-chat-panel__input-container .ai-chat-panel__input {
783
+ border-top: none;
784
+ padding: 8px 8px 4px 8px;
785
+ }
786
+
787
+ .ai-chat-panel__input-container .ai-chat-input {
788
+ border: none;
789
+ background: transparent;
790
+ padding: 4px 8px;
791
+ border-radius: 0;
792
+ }
793
+
794
+ .ai-chat-panel__input-container .ai-chat-input:focus {
795
+ border-color: transparent;
796
+ box-shadow: none;
797
+ }
798
+
799
+ /* ============================================================================
800
+ Input Footer (agent selector + send button row - Cursor style)
801
+ ============================================================================ */
802
+
803
+ .ai-chat-panel__input-footer {
804
+ display: flex;
805
+ align-items: center;
806
+ justify-content: space-between;
807
+ gap: 8px;
808
+ padding: 0 8px 8px 8px;
809
+ flex-shrink: 0;
810
+ }
811
+
812
+ .ai-chat-panel__input-footer-spacer {
813
+ flex: 1;
814
+ }
815
+
816
+ /* ============================================================================
817
+ Agent Selector (Cursor-style dropdown)
818
+ ============================================================================ */
819
+
820
+ .ai-chat-agent-selector {
821
+ position: relative;
822
+ }
823
+
824
+ .ai-chat-agent-selector__trigger {
825
+ display: flex;
826
+ align-items: center;
827
+ gap: 4px;
828
+ padding: 2px 6px;
829
+ background: transparent;
830
+ border: none;
831
+ border-radius: 4px;
832
+ color: var(--ai-chat-footer-text, #6b7280);
833
+ font-size: 12px;
834
+ font-family: inherit;
835
+ cursor: pointer;
836
+ transition: background-color 0.15s, color 0.15s;
837
+ }
838
+
839
+ .ai-chat-agent-selector__trigger:hover {
840
+ background-color: var(--ai-button-ghost-hover, rgba(0, 0, 0, 0.04));
841
+ color: var(--ai-chat-assistant-text);
842
+ }
843
+
844
+ .ai-chat-agent-selector__trigger:disabled {
845
+ opacity: 0.5;
846
+ cursor: not-allowed;
847
+ }
848
+
849
+ .ai-chat-agent-selector__label {
850
+ font-weight: 500;
851
+ }
852
+
853
+ /* Inside dropdown option styling */
854
+ .ai-chat-agent-selector__dropdown-inside .ai-chat-agent-selector__option {
855
+ border-radius: 0;
856
+ }
857
+
858
+ .ai-chat-agent-selector__dropdown-inside .ai-chat-agent-selector__option:first-child {
859
+ border-top-left-radius: 0;
860
+ border-top-right-radius: 0;
861
+ }
862
+
863
+ .ai-chat-agent-selector__dropdown-inside .ai-chat-agent-selector__option:last-child {
864
+ border-bottom-left-radius: calc(var(--ai-chat-input-radius) - 1px);
865
+ border-bottom-right-radius: calc(var(--ai-chat-input-radius) - 1px);
866
+ }
867
+
868
+ /* Old floating dropdown - kept for backwards compatibility */
869
+ .ai-chat-agent-selector__dropdown {
870
+ position: absolute;
871
+ bottom: 100%;
872
+ left: 0;
873
+ min-width: 200px;
874
+ max-width: 280px;
875
+ margin-bottom: 6px;
876
+ background-color: var(--ai-select-bg, #ffffff);
877
+ border: 1px solid var(--ai-select-border, #d1d5db);
878
+ border-radius: 8px;
879
+ box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
880
+ z-index: 1000;
881
+ overflow: hidden;
882
+ animation: ai-chat-dropdown-appear 0.15s ease-out;
883
+ }
884
+
885
+ .dark-theme .ai-chat-agent-selector__dropdown {
886
+ background-color: var(--ai-select-bg, #1f2937);
887
+ border-color: var(--ai-select-border, #374151);
888
+ box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
889
+ }
890
+
891
+ /* New inside dropdown - Cursor style */
892
+ .ai-chat-agent-selector__dropdown-inside {
893
+ background-color: var(--ai-select-bg, #f9fafb);
894
+ overflow: hidden;
895
+ animation: ai-chat-dropdown-inside-appear 0.15s ease-out;
896
+ max-height: 200px;
897
+ overflow-y: auto;
898
+ }
899
+
900
+ .dark-theme .ai-chat-agent-selector__dropdown-inside {
901
+ background-color: var(--ai-select-bg, #1f2937);
902
+ }
903
+
904
+ @keyframes ai-chat-dropdown-inside-appear {
905
+ from {
906
+ opacity: 0;
907
+ max-height: 0;
908
+ }
909
+ to {
910
+ opacity: 1;
911
+ max-height: 200px;
912
+ }
913
+ }
914
+
915
+ @keyframes ai-chat-dropdown-appear {
916
+ from {
917
+ opacity: 0;
918
+ transform: translateY(4px);
919
+ }
920
+ to {
921
+ opacity: 1;
922
+ transform: translateY(0);
923
+ }
924
+ }
925
+
926
+ .ai-chat-agent-selector__option {
927
+ display: flex;
928
+ align-items: center;
929
+ gap: 8px;
930
+ width: 100%;
931
+ padding: 8px 10px;
932
+ background: none;
933
+ border: none;
934
+ color: var(--ai-select-text, #1f2937);
935
+ font-size: 12px;
936
+ font-family: inherit;
937
+ text-align: left;
938
+ cursor: pointer;
939
+ transition: background-color 0.15s;
940
+ }
941
+
942
+ .dark-theme .ai-chat-agent-selector__option {
943
+ color: var(--ai-select-text, #f3f4f6);
944
+ }
945
+
946
+ .ai-chat-agent-selector__option:hover {
947
+ background-color: var(--ai-select-item-hover, #f3f4f6);
948
+ }
949
+
950
+ .dark-theme .ai-chat-agent-selector__option:hover {
951
+ background-color: var(--ai-select-item-hover, #374151);
952
+ }
953
+
954
+ .ai-chat-agent-selector__option--selected {
955
+ background-color: var(--ai-select-item-selected, #eff6ff);
956
+ }
957
+
958
+ .dark-theme .ai-chat-agent-selector__option--selected {
959
+ background-color: var(--ai-select-item-selected, #1e3a5f);
960
+ }
961
+
962
+ .ai-chat-agent-selector__avatar {
963
+ width: 20px;
964
+ height: 20px;
965
+ border-radius: 50%;
966
+ object-fit: cover;
967
+ flex-shrink: 0;
968
+ }
969
+
970
+ .ai-chat-agent-selector__option-avatar {
971
+ width: 24px;
972
+ height: 24px;
973
+ border-radius: 50%;
974
+ object-fit: cover;
975
+ flex-shrink: 0;
976
+ }
977
+
978
+ .ai-chat-agent-selector__option-icon {
979
+ display: flex;
980
+ color: var(--ai-chat-footer-text, #9ca3af);
981
+ }
982
+
983
+ .ai-chat-agent-selector__option-content {
984
+ flex: 1;
985
+ min-width: 0;
986
+ }
987
+
988
+ .ai-chat-agent-selector__option-label {
989
+ display: block;
990
+ font-weight: 500;
991
+ }
992
+
993
+ .ai-chat-agent-selector__option-description {
994
+ display: block;
995
+ font-size: 11px;
996
+ color: var(--ai-sidebar-text-muted, #6b7280);
997
+ margin-top: 2px;
998
+ white-space: nowrap;
999
+ overflow: hidden;
1000
+ text-overflow: ellipsis;
1001
+ }
1002
+
1003
+ .ai-chat-agent-selector__option-check {
1004
+ display: flex;
1005
+ color: var(--ai-button-primary-bg, #3b82f6);
1006
+ }
1007
+
1008
+ /* Responsive adjustments for agent selector */
1009
+ @container chat-panel (max-width: 380px) {
1010
+ .ai-chat-panel__input-container {
1011
+ margin: 10px 12px;
1012
+ }
1013
+
1014
+ .ai-chat-panel__input-footer {
1015
+ padding: 0 6px 6px 6px;
1016
+ }
1017
+
1018
+ .ai-chat-agent-selector__trigger {
1019
+ padding: 2px 6px;
1020
+ font-size: 12px;
1021
+ }
1022
+
1023
+ .ai-chat-agent-selector__dropdown {
1024
+ min-width: 180px;
1025
+ }
1026
+
1027
+ .ai-chat-agent-selector__dropdown-inside {
1028
+ max-height: 160px;
1029
+ }
1030
+
1031
+ .ai-chat-send-button {
1032
+ width: 22px;
1033
+ height: 22px;
1034
+ }
1035
+ }
1036
+
1037
+ @container chat-panel (max-width: 320px) {
1038
+ .ai-chat-panel__input-container {
1039
+ margin: 8px;
1040
+ }
1041
+
1042
+ .ai-chat-panel__input-footer {
1043
+ padding: 0 6px 4px 6px;
1044
+ }
1045
+
1046
+ .ai-chat-send-button {
1047
+ width: 20px;
1048
+ height: 20px;
1049
+ }
1050
+ }
1051
+
1052
+ /* ============================================================================
1053
+ Agent Suggestion Card (inline handoff UI)
1054
+ ============================================================================ */
1055
+
1056
+ .ai-chat-agent-suggestion {
1057
+ display: flex;
1058
+ align-items: center;
1059
+ justify-content: space-between;
1060
+ gap: 12px;
1061
+ padding: 12px 16px;
1062
+ margin: 12px 0;
1063
+ background-color: var(--ai-chat-suggestion-bg);
1064
+ border: 1px solid var(--ai-chat-suggestion-border);
1065
+ border-radius: 8px;
1066
+ transition: border-color 0.15s, box-shadow 0.15s;
1067
+ }
1068
+
1069
+ .ai-chat-agent-suggestion:hover {
1070
+ border-color: var(--ai-chat-input-focus-border);
1071
+ box-shadow: 0 0 0 2px var(--ai-chat-input-focus-ring);
1072
+ }
1073
+
1074
+ .ai-chat-agent-suggestion__content {
1075
+ display: flex;
1076
+ align-items: center;
1077
+ gap: 10px;
1078
+ flex: 1;
1079
+ min-width: 0;
1080
+ }
1081
+
1082
+ .ai-chat-agent-suggestion__icon {
1083
+ display: flex;
1084
+ align-items: center;
1085
+ justify-content: center;
1086
+ width: 32px;
1087
+ height: 32px;
1088
+ border-radius: 8px;
1089
+ background-color: var(--ai-button-primary-bg, #3b82f6);
1090
+ color: white;
1091
+ flex-shrink: 0;
1092
+ }
1093
+
1094
+ .ai-chat-agent-suggestion__icon svg {
1095
+ width: 16px;
1096
+ height: 16px;
1097
+ }
1098
+
1099
+ .ai-chat-agent-suggestion__text {
1100
+ display: flex;
1101
+ flex-direction: column;
1102
+ gap: 2px;
1103
+ min-width: 0;
1104
+ }
1105
+
1106
+ .ai-chat-agent-suggestion__label {
1107
+ font-weight: 600;
1108
+ font-size: 14px;
1109
+ color: var(--ai-chat-assistant-text);
1110
+ }
1111
+
1112
+ .ai-chat-agent-suggestion__reason {
1113
+ font-size: 12px;
1114
+ color: var(--ai-sidebar-text-muted, #6b7280);
1115
+ white-space: nowrap;
1116
+ overflow: hidden;
1117
+ text-overflow: ellipsis;
1118
+ }
1119
+
1120
+ .ai-chat-agent-suggestion__button {
1121
+ flex-shrink: 0;
1122
+ }
1123
+
1124
+ /* Dark theme adjustments */
1125
+ .dark-theme .ai-chat-agent-suggestion {
1126
+ background-color: var(--ai-chat-suggestion-bg);
1127
+ border-color: var(--ai-chat-suggestion-border);
1128
+ }
1129
+
1130
+ .dark-theme .ai-chat-agent-suggestion__label {
1131
+ color: var(--ai-chat-assistant-text);
1132
+ }
1133
+
1134
+ .dark-theme .ai-chat-agent-suggestion__reason {
1135
+ color: var(--ai-sidebar-text-muted, #9ca3af);
1136
+ }
1137
+
1138
+ /* Agent avatar */
1139
+ .ai-chat-agent-suggestion__avatar {
1140
+ width: 32px;
1141
+ height: 32px;
1142
+ border-radius: 8px;
1143
+ object-fit: cover;
1144
+ flex-shrink: 0;
1145
+ }
1146
+
1147
+ /* Invalid/unavailable agent suggestion */
1148
+ .ai-chat-agent-suggestion--invalid {
1149
+ opacity: 0.7;
1150
+ }
1151
+
1152
+ .ai-chat-agent-suggestion--invalid:hover {
1153
+ border-color: var(--ai-chat-suggestion-border);
1154
+ box-shadow: none;
1155
+ }
1156
+
1157
+ .ai-chat-agent-suggestion__unavailable {
1158
+ font-size: 12px;
1159
+ color: var(--ai-sidebar-text-muted, #6b7280);
1160
+ font-style: italic;
1161
+ flex-shrink: 0;
1162
+ }
1163
+
1164
+ /* Switched state */
1165
+ .ai-chat-agent-suggestion--switched {
1166
+ background-color: rgba(34, 197, 94, 0.08);
1167
+ border-color: rgba(34, 197, 94, 0.3);
1168
+ }
1169
+
1170
+ .ai-chat-agent-suggestion--switched:hover {
1171
+ border-color: rgba(34, 197, 94, 0.4);
1172
+ box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.1);
1173
+ }
1174
+
1175
+ .ai-chat-agent-suggestion__icon--switched {
1176
+ background-color: #22c55e;
1177
+ }
1178
+
1179
+ .ai-chat-agent-suggestion__switched-badge {
1180
+ display: flex;
1181
+ align-items: center;
1182
+ gap: 4px;
1183
+ padding: 6px 12px;
1184
+ background-color: rgba(34, 197, 94, 0.1);
1185
+ color: #16a34a;
1186
+ border-radius: 6px;
1187
+ font-size: 12px;
1188
+ font-weight: 600;
1189
+ flex-shrink: 0;
1190
+ }
1191
+
1192
+ .dark-theme .ai-chat-agent-suggestion--switched {
1193
+ background-color: rgba(34, 197, 94, 0.12);
1194
+ border-color: rgba(34, 197, 94, 0.25);
1195
+ }
1196
+
1197
+ .dark-theme .ai-chat-agent-suggestion__switched-badge {
1198
+ background-color: rgba(34, 197, 94, 0.15);
1199
+ color: #4ade80;
1200
+ }
1201
+
1202
+ /* Responsive adjustments for agent suggestion card */
1203
+ @container chat-panel (max-width: 380px) {
1204
+ .ai-chat-agent-suggestion {
1205
+ flex-direction: column;
1206
+ align-items: stretch;
1207
+ gap: 10px;
1208
+ padding: 10px 12px;
1209
+ }
1210
+
1211
+ .ai-chat-agent-suggestion__button {
1212
+ width: 100%;
1213
+ }
1214
+
1215
+ .ai-chat-agent-suggestion__reason {
1216
+ white-space: normal;
1217
+ }
1218
+ }
1219
+
1220
+ /* ============================================================================
1221
+ Context Viewer - Cursor-Style Pill & Popover
1222
+ ============================================================================ */
1223
+
1224
+ /* Pill Wrapper - positions the popover */
1225
+ .ai-chat-context-pill-wrapper {
1226
+ position: relative;
1227
+ flex-shrink: 0;
1228
+ }
1229
+
1230
+ /* Context Pill - Cursor style */
1231
+ .ai-chat-context-pill {
1232
+ display: flex;
1233
+ align-items: center;
1234
+ gap: 6px;
1235
+ padding: 4px 10px;
1236
+ background: var(--ai-chat-suggestion-bg, #f3f4f6);
1237
+ border: none;
1238
+ border-radius: 999px;
1239
+ color: var(--ai-sidebar-text-muted, #6b7280);
1240
+ font-size: 12px;
1241
+ cursor: pointer;
1242
+ transition: all 0.15s ease;
1243
+ font-family: inherit;
1244
+ }
1245
+
1246
+ .ai-chat-context-pill:hover {
1247
+ background: var(--ai-chat-suggestion-hover-bg, #e5e7eb);
1248
+ color: var(--ai-chat-input-text, #1f2937);
1249
+ }
1250
+
1251
+ .ai-chat-context-pill--active {
1252
+ background: var(--ai-chat-suggestion-hover-bg, #e5e7eb);
1253
+ color: var(--ai-chat-input-text, #1f2937);
1254
+ }
1255
+
1256
+ .ai-chat-context-pill--warning {
1257
+ color: #f59e0b;
1258
+ }
1259
+
1260
+ .ai-chat-context-pill__count {
1261
+ display: none;
1262
+ border-radius: 999px;
1263
+ }
1264
+
1265
+ .ai-chat-context-pill__label {
1266
+ font-weight: 400;
1267
+ color: var(--ai-sidebar-text-muted, #6b7280);
1268
+ font-size: 12px;
1269
+ }
1270
+
1271
+ .ai-chat-context-pill__tokens {
1272
+ display: none;
1273
+ }
1274
+
1275
+ /* Context Popover - slides up from pill */
1276
+ .ai-chat-context-popover {
1277
+ position: absolute;
1278
+ bottom: calc(100% + 8px);
1279
+ left: 50%;
1280
+ transform: translateX(-50%);
1281
+ min-width: 280px;
1282
+ max-width: 360px;
1283
+ background: var(--ai-chat-input-bg, #ffffff);
1284
+ border: 1px solid var(--ai-chat-input-border, #e5e7eb);
1285
+ border-radius: 12px;
1286
+ box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.04);
1287
+ z-index: 1000;
1288
+ overflow: hidden;
1289
+ animation: contextPopoverSlideUp 0.15s ease-out;
1290
+ }
1291
+
1292
+ .ai-chat-context-popover--detail {
1293
+ position: fixed;
1294
+ bottom: 80px;
1295
+ left: 50%;
1296
+ transform: translateX(-50%);
1297
+ width: calc(100vw - 100px);
1298
+ max-width: 800px;
1299
+ min-width: 500px;
1300
+ max-height: calc(100vh - 200px);
1301
+ z-index: 1001;
1302
+ }
1303
+
1304
+ @keyframes contextPopoverSlideUp {
1305
+ from {
1306
+ opacity: 0;
1307
+ transform: translateX(-50%) translateY(4px);
1308
+ }
1309
+ to {
1310
+ opacity: 1;
1311
+ transform: translateX(-50%) translateY(0);
1312
+ }
1313
+ }
1314
+
1315
+ /* Popover Header */
1316
+ .ai-chat-context-popover__header {
1317
+ display: flex;
1318
+ align-items: center;
1319
+ justify-content: space-between;
1320
+ padding: 12px 14px;
1321
+ border-bottom: 1px solid var(--ai-chat-suggestion-border, #e5e7eb);
1322
+ }
1323
+
1324
+ .ai-chat-context-popover__title {
1325
+ font-weight: 600;
1326
+ font-size: 13px;
1327
+ color: var(--ai-chat-input-text, #1f2937);
1328
+ }
1329
+
1330
+ .ai-chat-context-popover__close {
1331
+ display: flex;
1332
+ align-items: center;
1333
+ justify-content: center;
1334
+ width: 24px;
1335
+ height: 24px;
1336
+ background: transparent;
1337
+ border: none;
1338
+ border-radius: 6px;
1339
+ color: var(--ai-sidebar-text-muted, #9ca3af);
1340
+ font-size: 18px;
1341
+ cursor: pointer;
1342
+ transition: all 0.15s;
1343
+ }
1344
+
1345
+ .ai-chat-context-popover__close:hover {
1346
+ background: var(--ai-chat-suggestion-bg, #f3f4f6);
1347
+ color: var(--ai-chat-input-text, #1f2937);
1348
+ }
1349
+
1350
+ /* Token Bar */
1351
+ .ai-chat-context-popover__token-bar {
1352
+ padding: 10px 14px;
1353
+ background: var(--ai-chat-suggestion-bg, #f9fafb);
1354
+ }
1355
+
1356
+ .ai-chat-context-popover__token-info {
1357
+ display: flex;
1358
+ align-items: baseline;
1359
+ gap: 4px;
1360
+ margin-bottom: 6px;
1361
+ font-size: 12px;
1362
+ }
1363
+
1364
+ .ai-chat-context-popover__token-info > span:first-child {
1365
+ font-weight: 600;
1366
+ color: var(--ai-chat-input-text, #1f2937);
1367
+ }
1368
+
1369
+ .ai-chat-context-popover__token-limit {
1370
+ color: var(--ai-sidebar-text-muted, #9ca3af);
1371
+ }
1372
+
1373
+ .ai-chat-context-popover__tokens--warning {
1374
+ color: #f59e0b !important;
1375
+ }
1376
+
1377
+ /* Progress Bar */
1378
+ .ai-chat-context-popover__progress {
1379
+ height: 4px;
1380
+ background: var(--ai-chat-suggestion-border, #e5e7eb);
1381
+ border-radius: 2px;
1382
+ overflow: hidden;
1383
+ }
1384
+
1385
+ .ai-chat-context-popover__progress-bar {
1386
+ height: 100%;
1387
+ background: #22c55e;
1388
+ border-radius: 2px;
1389
+ transition: width 0.3s ease;
1390
+ }
1391
+
1392
+ .ai-chat-context-popover__progress-bar--warning {
1393
+ background: #f59e0b;
1394
+ }
1395
+
1396
+ /* Summary View */
1397
+ .ai-chat-context-popover__summary {
1398
+ display: flex;
1399
+ flex-direction: column;
1400
+ }
1401
+
1402
+ /* Section List */
1403
+ .ai-chat-context-popover__sections {
1404
+ display: flex;
1405
+ flex-direction: column;
1406
+ max-height: 200px;
1407
+ overflow-y: auto;
1408
+ }
1409
+
1410
+ .ai-chat-context-popover__section-item {
1411
+ display: flex;
1412
+ align-items: center;
1413
+ gap: 10px;
1414
+ padding: 10px 14px;
1415
+ border-bottom: 1px solid var(--ai-chat-suggestion-border, #f3f4f6);
1416
+ transition: background 0.1s;
1417
+ }
1418
+
1419
+ .ai-chat-context-popover__section-item:last-child {
1420
+ border-bottom: none;
1421
+ }
1422
+
1423
+ .ai-chat-context-popover__section-item--clickable {
1424
+ cursor: pointer;
1425
+ }
1426
+
1427
+ .ai-chat-context-popover__section-item--clickable:hover {
1428
+ background: var(--ai-chat-suggestion-bg, #f9fafb);
1429
+ }
1430
+
1431
+ .ai-chat-context-popover__section-icon {
1432
+ font-size: 14px;
1433
+ opacity: 0.7;
1434
+ }
1435
+
1436
+ .ai-chat-context-popover__section-title {
1437
+ flex: 1;
1438
+ font-size: 13px;
1439
+ font-weight: 500;
1440
+ color: var(--ai-chat-input-text, #1f2937);
1441
+ white-space: nowrap;
1442
+ overflow: hidden;
1443
+ text-overflow: ellipsis;
1444
+ }
1445
+
1446
+ .ai-chat-context-popover__section-tokens {
1447
+ font-size: 11px;
1448
+ color: var(--ai-sidebar-text-muted, #9ca3af);
1449
+ flex-shrink: 0;
1450
+ }
1451
+
1452
+ /* Expand Button */
1453
+ .ai-chat-context-popover__expand-btn {
1454
+ display: flex;
1455
+ align-items: center;
1456
+ justify-content: center;
1457
+ width: 100%;
1458
+ padding: 10px 14px;
1459
+ background: transparent;
1460
+ border: none;
1461
+ border-top: 1px solid var(--ai-chat-suggestion-border, #e5e7eb);
1462
+ color: var(--ai-button-primary-bg, #3b82f6);
1463
+ font-size: 12px;
1464
+ font-weight: 500;
1465
+ cursor: pointer;
1466
+ transition: background 0.15s;
1467
+ }
1468
+
1469
+ .ai-chat-context-popover__expand-btn:hover {
1470
+ background: var(--ai-chat-suggestion-bg, #f9fafb);
1471
+ }
1472
+
1473
+ /* Detail View */
1474
+ .ai-chat-context-popover__detail {
1475
+ display: flex;
1476
+ flex-direction: column;
1477
+ height: 100%;
1478
+ max-height: calc(100vh - 250px);
1479
+ min-height: 300px;
1480
+ }
1481
+
1482
+ .ai-chat-context-popover__back {
1483
+ display: flex;
1484
+ align-items: center;
1485
+ gap: 2px;
1486
+ padding: 4px 8px;
1487
+ margin-right: 8px;
1488
+ background: transparent;
1489
+ border: none;
1490
+ border-radius: 6px;
1491
+ color: var(--ai-sidebar-text-muted, #6b7280);
1492
+ font-size: 12px;
1493
+ cursor: pointer;
1494
+ transition: all 0.15s;
1495
+ }
1496
+
1497
+ .ai-chat-context-popover__back:hover {
1498
+ background: var(--ai-chat-suggestion-bg, #f3f4f6);
1499
+ color: var(--ai-chat-input-text, #1f2937);
1500
+ }
1501
+
1502
+ /* Detail Sections */
1503
+ .ai-chat-context-popover__detail-sections {
1504
+ flex: 1;
1505
+ overflow-y: auto;
1506
+ padding: 12px;
1507
+ min-height: 0;
1508
+ }
1509
+
1510
+ .ai-chat-context-popover__detail-section {
1511
+ margin-bottom: 6px;
1512
+ background: var(--ai-chat-suggestion-bg, #f9fafb);
1513
+ border-radius: 8px;
1514
+ overflow: hidden;
1515
+ }
1516
+
1517
+ .ai-chat-context-popover__detail-section-header {
1518
+ display: flex;
1519
+ align-items: center;
1520
+ justify-content: space-between;
1521
+ padding: 10px 12px;
1522
+ cursor: pointer;
1523
+ user-select: none;
1524
+ list-style: none;
1525
+ font-size: 13px;
1526
+ }
1527
+
1528
+ .ai-chat-context-popover__detail-section-header::-webkit-details-marker {
1529
+ display: none;
1530
+ }
1531
+
1532
+ .ai-chat-context-popover__detail-section-title {
1533
+ font-weight: 600;
1534
+ color: var(--ai-chat-input-text, #1f2937);
1535
+ }
1536
+
1537
+ .ai-chat-context-popover__detail-section-meta {
1538
+ display: flex;
1539
+ align-items: center;
1540
+ gap: 8px;
1541
+ font-size: 11px;
1542
+ color: var(--ai-sidebar-text-muted, #9ca3af);
1543
+ }
1544
+
1545
+ .ai-chat-context-popover__detail-section-meta code {
1546
+ background: var(--ai-chat-suggestion-hover-bg, #e5e7eb);
1547
+ padding: 2px 6px;
1548
+ border-radius: 4px;
1549
+ font-family: 'SF Mono', monospace;
1550
+ font-size: 10px;
1551
+ }
1552
+
1553
+ /* Detail Content */
1554
+ .ai-chat-context-popover__detail-content {
1555
+ margin: 0;
1556
+ padding: 12px 14px;
1557
+ background: var(--ai-chat-input-bg, #ffffff);
1558
+ border-top: 1px solid var(--ai-chat-suggestion-border, #e5e7eb);
1559
+ font-family: 'SF Mono', 'Monaco', 'Fira Code', monospace;
1560
+ font-size: 12px;
1561
+ line-height: 1.6;
1562
+ color: var(--ai-chat-input-text, #374151);
1563
+ overflow-x: auto;
1564
+ white-space: pre-wrap;
1565
+ word-break: break-word;
1566
+ max-height: 400px;
1567
+ overflow-y: auto;
1568
+ }
1569
+
1570
+ /* Dark Theme */
1571
+ .dark-theme .ai-chat-context-pill {
1572
+ background: var(--ai-chat-suggestion-bg, #374151);
1573
+ }
1574
+
1575
+ .dark-theme .ai-chat-context-pill:hover,
1576
+ .dark-theme .ai-chat-context-pill--active {
1577
+ background: var(--ai-chat-suggestion-hover-bg, #4b5563);
1578
+ }
1579
+
1580
+ .dark-theme .ai-chat-context-popover {
1581
+ background: var(--ai-chat-input-bg, #1f2937);
1582
+ border-color: var(--ai-chat-input-border, #374151);
1583
+ box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
1584
+ }
1585
+
1586
+ .dark-theme .ai-chat-context-popover__token-bar {
1587
+ background: var(--ai-chat-suggestion-bg, #111827);
1588
+ }
1589
+
1590
+ .dark-theme .ai-chat-context-popover__detail-content {
1591
+ background: #111827;
1592
+ }
1593
+
1594
+ /* Responsive */
1595
+ @container chat-panel (max-width: 380px) {
1596
+ .ai-chat-context-pill__label {
1597
+ font-size: 11px;
1598
+ }
1599
+
1600
+ .ai-chat-context-popover {
1601
+ min-width: 260px;
1602
+ left: auto;
1603
+ right: 0;
1604
+ transform: none;
1605
+ }
1606
+
1607
+ @keyframes contextPopoverSlideUp {
1608
+ from {
1609
+ opacity: 0;
1610
+ transform: translateY(4px);
1611
+ }
1612
+ to {
1613
+ opacity: 1;
1614
+ transform: translateY(0);
1615
+ }
1616
+ }
1617
+ }
1618
+