sang-ai-kit 0.1.1 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -8
- package/generated/sang-ai-utilities.css +120 -1
- package/package.json +3 -1
- package/src/AiAssistant.tsx +20 -33
- package/src/AiSettings.tsx +6 -3
- package/src/ModelControls.tsx +3 -11
- package/src/SessionList.tsx +4 -1
- package/src/SkillSettings.tsx +4 -2
- package/src/TokenUsageBar.tsx +4 -1
- package/src/assistant.css +2125 -1712
- package/src/assistantTypes.ts +7 -2
- package/src/background-removal/BackgroundRemovalSettings.tsx +502 -0
- package/src/background-removal/ColorMattingEditor.tsx +649 -0
- package/src/background-removal/background-removal.css +294 -0
- package/src/background-removal/color-matting.css +838 -0
- package/src/background-removal/colorMatting.ts +117 -0
- package/src/background-removal/colorMatting.worker.ts +21 -0
- package/src/background-removal/index.ts +92 -0
- package/src/background-removal/inference.worker.ts +117 -0
- package/src/background-removal/models.ts +65 -0
- package/src/background-removal/processing.ts +61 -0
- package/src/background-removal/resources.ts +114 -0
- package/src/background-removal/status.ts +23 -0
- package/src/background-removal/storage.ts +56 -0
- package/src/background-removal/tool.ts +70 -0
- package/src/background-removal/types.ts +38 -0
- package/src/background-removal/useResources.ts +38 -0
- package/src/builtInToolDefinitions.ts +68 -0
- package/src/builtInTools.ts +66 -22
- package/src/bun-env.d.ts +25 -0
- package/src/conversationUtils.ts +71 -1
- package/src/endpointConnection.ts +2 -2
- package/src/features.ts +3 -1
- package/src/imageToolHost.ts +86 -0
- package/src/index.ts +15 -6
- package/src/modelConfig.ts +49 -7
- package/src/openai.ts +56 -30
- package/src/responses.ts +14 -0
- package/src/settingsTypes.ts +6 -8
- package/src/skills.ts +1 -1
- package/src/style.css +111 -67
- package/src/useAssistant.ts +5 -38
- package/src/useResolvedTheme.ts +2 -1
package/src/assistant.css
CHANGED
|
@@ -1,1713 +1,2126 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
--ai-
|
|
6
|
-
--ai-
|
|
7
|
-
--ai-
|
|
8
|
-
--ai-
|
|
9
|
-
--ai-
|
|
10
|
-
--ai-
|
|
11
|
-
--ai-
|
|
12
|
-
--ai-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
--
|
|
20
|
-
--
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
:
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
:
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
:
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
:
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
--ai-
|
|
71
|
-
--ai-
|
|
72
|
-
--ai-
|
|
73
|
-
--ai-
|
|
74
|
-
--ai-
|
|
75
|
-
--ai-
|
|
76
|
-
--
|
|
77
|
-
--
|
|
78
|
-
--
|
|
79
|
-
--
|
|
80
|
-
--
|
|
81
|
-
--
|
|
82
|
-
--
|
|
83
|
-
--
|
|
84
|
-
--
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
--color-slate-
|
|
110
|
-
--color-slate-
|
|
111
|
-
|
|
112
|
-
--color-
|
|
113
|
-
--color-
|
|
114
|
-
--color-
|
|
115
|
-
--color-
|
|
116
|
-
--color-
|
|
117
|
-
--color-
|
|
118
|
-
--color-
|
|
119
|
-
|
|
120
|
-
color: #
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
color:
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
.cf-ai-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
border
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
.cf-ai-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
}
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
}
|
|
356
|
-
|
|
357
|
-
.cf-ai-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
border-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
.
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
.
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
.
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
.cf-ai-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
.
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
}
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
color:
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
.cf-ai-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
color: var(--ai-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
user-select: none;
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
}
|
|
602
|
-
|
|
603
|
-
/*
|
|
604
|
-
.cf-ai-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
}
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
color:
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
}
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
}
|
|
748
|
-
|
|
749
|
-
.cf-ai-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
.cf-ai-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
.cf-ai-
|
|
789
|
-
.cf-ai-
|
|
790
|
-
.cf-ai-
|
|
791
|
-
|
|
792
|
-
.cf-ai-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
.cf-ai-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
border-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
color: #
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
.cf-ai-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
font-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
}
|
|
925
|
-
|
|
926
|
-
.cf-ai-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
.cf-ai-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
.cf-ai-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
}
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
}
|
|
1104
|
-
|
|
1105
|
-
.cf-ai-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
}
|
|
1124
|
-
|
|
1125
|
-
.cf-ai-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
border-radius:
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
border
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
}
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
font-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
}
|
|
1180
|
-
|
|
1181
|
-
.cf-ai-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
}
|
|
1197
|
-
|
|
1198
|
-
.cf-ai-
|
|
1199
|
-
|
|
1200
|
-
}
|
|
1201
|
-
|
|
1202
|
-
.cf-ai-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
}
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
.cf-ai-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
font-size:
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
}
|
|
1282
|
-
|
|
1283
|
-
.cf-ai-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
.
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
}
|
|
1321
|
-
|
|
1322
|
-
.cf-ai-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
border-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
}
|
|
1341
|
-
|
|
1342
|
-
.cf-ai-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
}
|
|
1368
|
-
|
|
1369
|
-
.cf-ai-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
color: var(--ai-
|
|
1378
|
-
font-size:
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
font-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
color:
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
font-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
}
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
}
|
|
1499
|
-
|
|
1500
|
-
.cf-ai-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
}
|
|
1511
|
-
|
|
1512
|
-
.cf-ai-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
}
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
.
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
}
|
|
1587
|
-
|
|
1588
|
-
.cf-ai-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
}
|
|
1598
|
-
|
|
1599
|
-
.cf-ai-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
}
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
}
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
.cf-ai-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
}
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
align-items: center;
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1
|
+
/* ==========================================================================
|
|
2
|
+
1. 全新默认深色模式 (Redesigned Default Dark Mode — Obsidian Graphite & Cobalt Indigo)
|
|
3
|
+
========================================================================== */
|
|
4
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) {
|
|
5
|
+
--ai-bg: var(--sang-ai-bg, rgba(17, 20, 28, 0.95));
|
|
6
|
+
--ai-surface: var(--sang-ai-surface, rgba(26, 31, 43, 0.82));
|
|
7
|
+
--ai-surface-elevated: var(--sang-ai-surface-elevated, rgba(36, 43, 59, 0.78));
|
|
8
|
+
--ai-surface-hover: var(--sang-ai-surface-hover, rgba(48, 57, 77, 0.72));
|
|
9
|
+
--ai-header-bg: var(--sang-ai-header-bg, rgba(20, 24, 34, 0.82));
|
|
10
|
+
--ai-subbar-bg: var(--sang-ai-subbar-bg, rgba(23, 28, 39, 0.56));
|
|
11
|
+
--ai-input-bg: var(--sang-ai-input-bg, rgba(11, 14, 20, 0.88));
|
|
12
|
+
--ai-code-bg: var(--sang-ai-code-bg, rgba(10, 13, 19, 0.9));
|
|
13
|
+
--ai-border: var(--sang-ai-border, rgba(56, 65, 82, 0.68));
|
|
14
|
+
--ai-border-light: var(--sang-ai-border-light, rgba(71, 82, 102, 0.42));
|
|
15
|
+
--ai-text: var(--sang-ai-text, #f3f5f9);
|
|
16
|
+
--ai-text-secondary: var(--sang-ai-text-secondary, #d5dbe6);
|
|
17
|
+
--ai-muted: var(--sang-ai-muted, #949eb0);
|
|
18
|
+
--ai-subtle: var(--sang-ai-subtle, #687387);
|
|
19
|
+
--ai-accent: var(--sang-ai-accent, #4f6ef7);
|
|
20
|
+
--ai-accent-hover: var(--sang-ai-accent-hover, color-mix(in srgb, var(--ai-accent) 84%, #000000));
|
|
21
|
+
--ai-accent-strong: var(--sang-ai-accent-strong, color-mix(in srgb, var(--ai-accent) 72%, #ffffff));
|
|
22
|
+
--ai-accent-soft: var(--sang-ai-accent-soft, color-mix(in srgb, var(--ai-accent) 56%, #ffffff));
|
|
23
|
+
--ai-accent-contrast: var(--sang-ai-accent-text, #ffffff);
|
|
24
|
+
--ai-accent-bg: var(--sang-ai-accent-bg, color-mix(in srgb, var(--ai-accent) 15%, transparent));
|
|
25
|
+
--ai-accent-border: var(--sang-ai-accent-border, color-mix(in srgb, var(--ai-accent) 35%, transparent));
|
|
26
|
+
--ai-user-bg: var(--sang-ai-user-bg, linear-gradient(135deg, color-mix(in srgb, var(--ai-accent) 22%, rgba(26, 31, 43, 0.85)), color-mix(in srgb, var(--ai-accent) 12%, rgba(17, 20, 28, 0.9))));
|
|
27
|
+
--ai-user-border: var(--sang-ai-user-border, color-mix(in srgb, var(--ai-accent) 38%, transparent));
|
|
28
|
+
--ai-assistant-bg: var(--sang-ai-assistant-bg, rgba(26, 31, 43, 0.62));
|
|
29
|
+
--ai-dialog-bg: var(--sang-ai-dialog-bg, #11141c);
|
|
30
|
+
--ai-scrollbar-track: color-mix(in srgb, var(--ai-surface) 90%, #090b10);
|
|
31
|
+
--ai-scrollbar-thumb: color-mix(in srgb, var(--ai-subtle) 80%, transparent);
|
|
32
|
+
--ai-scrollbar-thumb-hover: var(--ai-muted);
|
|
33
|
+
|
|
34
|
+
/* 同步内部 Tailwind 工具类色彩变量以随主题/强调色联动 */
|
|
35
|
+
--color-blue-700: color-mix(in srgb, var(--ai-accent) 82%, #000000);
|
|
36
|
+
--color-blue-600: var(--ai-accent);
|
|
37
|
+
--color-blue-500: var(--ai-accent-hover);
|
|
38
|
+
--color-blue-400: var(--ai-accent-strong);
|
|
39
|
+
--color-blue-300: var(--ai-accent-soft);
|
|
40
|
+
--color-blue-200: color-mix(in srgb, var(--ai-accent) 36%, #ffffff);
|
|
41
|
+
--color-blue-100: color-mix(in srgb, var(--ai-accent) 20%, #ffffff);
|
|
42
|
+
--color-indigo-700: color-mix(in srgb, var(--ai-accent) 80%, #1e1b4b);
|
|
43
|
+
--color-indigo-600: color-mix(in srgb, var(--ai-accent) 92%, #4338ca);
|
|
44
|
+
--color-indigo-500: color-mix(in srgb, var(--ai-accent) 86%, #818cf8);
|
|
45
|
+
--color-indigo-400: var(--ai-accent-strong);
|
|
46
|
+
--color-indigo-300: var(--ai-accent-soft);
|
|
47
|
+
--color-indigo-200: color-mix(in srgb, var(--ai-accent) 36%, #ffffff);
|
|
48
|
+
|
|
49
|
+
--color-slate-950: color-mix(in srgb, var(--ai-dialog-bg) 92%, #05070b);
|
|
50
|
+
--color-slate-900: var(--ai-dialog-bg);
|
|
51
|
+
--color-slate-850: color-mix(in srgb, var(--ai-dialog-bg) 70%, #2a3346);
|
|
52
|
+
--color-slate-800: color-mix(in srgb, var(--ai-dialog-bg) 52%, #333e54);
|
|
53
|
+
--color-slate-750: color-mix(in srgb, var(--ai-dialog-bg) 40%, #3f4c66);
|
|
54
|
+
--color-slate-700: color-mix(in srgb, var(--ai-dialog-bg) 28%, #4b5975);
|
|
55
|
+
--color-slate-600: #52607a;
|
|
56
|
+
--color-slate-500: var(--ai-subtle);
|
|
57
|
+
--color-slate-400: var(--ai-muted);
|
|
58
|
+
--color-slate-300: var(--ai-text-secondary);
|
|
59
|
+
--color-slate-200: color-mix(in srgb, var(--ai-text) 92%, var(--ai-muted));
|
|
60
|
+
--color-slate-100: var(--ai-text);
|
|
61
|
+
|
|
62
|
+
font-family: inherit;
|
|
63
|
+
letter-spacing: -0.01em;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/* ==========================================================================
|
|
67
|
+
2. 全新默认浅色模式 (Redesigned Default Light Mode — Daylight Slate & Royal Cobalt)
|
|
68
|
+
========================================================================== */
|
|
69
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] {
|
|
70
|
+
--ai-bg: var(--sang-ai-bg, rgba(255, 255, 255, 0.96));
|
|
71
|
+
--ai-surface: var(--sang-ai-surface, #ffffff);
|
|
72
|
+
--ai-surface-elevated: var(--sang-ai-surface-elevated, #f2f4f9);
|
|
73
|
+
--ai-surface-hover: var(--sang-ai-surface-hover, #e8ecf4);
|
|
74
|
+
--ai-header-bg: var(--sang-ai-header-bg, rgba(255, 255, 255, 0.94));
|
|
75
|
+
--ai-subbar-bg: var(--sang-ai-subbar-bg, #f6f8fc);
|
|
76
|
+
--ai-input-bg: var(--sang-ai-input-bg, #ffffff);
|
|
77
|
+
--ai-code-bg: var(--sang-ai-code-bg, #f2f4f9);
|
|
78
|
+
--ai-border: var(--sang-ai-border, #dde3ee);
|
|
79
|
+
--ai-border-light: var(--sang-ai-border-light, #e9edf5);
|
|
80
|
+
--ai-text: var(--sang-ai-text, #141923);
|
|
81
|
+
--ai-text-secondary: var(--sang-ai-text-secondary, #2d3648);
|
|
82
|
+
--ai-muted: var(--sang-ai-muted, #5c667a);
|
|
83
|
+
--ai-subtle: var(--sang-ai-subtle, #8692a6);
|
|
84
|
+
--ai-accent: var(--sang-ai-accent, #3b5bdb);
|
|
85
|
+
--ai-accent-hover: var(--sang-ai-accent-hover, color-mix(in srgb, var(--ai-accent) 86%, #000000));
|
|
86
|
+
--ai-accent-strong: var(--sang-ai-accent-strong, color-mix(in srgb, var(--ai-accent) 92%, #000000));
|
|
87
|
+
--ai-accent-soft: var(--sang-ai-accent-soft, color-mix(in srgb, var(--ai-accent) 78%, #000000));
|
|
88
|
+
--ai-accent-contrast: var(--sang-ai-accent-text, #ffffff);
|
|
89
|
+
--ai-accent-bg: var(--sang-ai-accent-bg, color-mix(in srgb, var(--ai-accent) 10%, #ffffff));
|
|
90
|
+
--ai-accent-border: var(--sang-ai-accent-border, color-mix(in srgb, var(--ai-accent) 28%, #ffffff));
|
|
91
|
+
--ai-user-bg: var(--sang-ai-user-bg, color-mix(in srgb, var(--ai-accent) 9%, #ffffff));
|
|
92
|
+
--ai-user-border: var(--sang-ai-user-border, color-mix(in srgb, var(--ai-accent) 26%, #ffffff));
|
|
93
|
+
--ai-assistant-bg: var(--sang-ai-assistant-bg, #ffffff);
|
|
94
|
+
--ai-dialog-bg: var(--sang-ai-dialog-bg, #f8f9fc);
|
|
95
|
+
--ai-scrollbar-track: #edf1f7;
|
|
96
|
+
--ai-scrollbar-thumb: #b4bfd0;
|
|
97
|
+
--ai-scrollbar-thumb-hover: #8e9cb2;
|
|
98
|
+
|
|
99
|
+
--color-slate-950: color-mix(in srgb, var(--ai-dialog-bg) 96%, #e2e8f0);
|
|
100
|
+
--color-slate-900: var(--ai-surface);
|
|
101
|
+
--color-slate-850: var(--ai-surface-elevated);
|
|
102
|
+
--color-slate-800: var(--ai-surface-hover);
|
|
103
|
+
--color-slate-750: var(--ai-border);
|
|
104
|
+
--color-slate-700: color-mix(in srgb, var(--ai-border) 85%, #94a3b8);
|
|
105
|
+
--color-slate-600: var(--ai-subtle);
|
|
106
|
+
--color-slate-500: var(--ai-muted);
|
|
107
|
+
--color-slate-400: var(--ai-muted);
|
|
108
|
+
--color-slate-300: var(--ai-text-secondary);
|
|
109
|
+
--color-slate-200: var(--ai-text);
|
|
110
|
+
--color-slate-100: var(--ai-text);
|
|
111
|
+
|
|
112
|
+
--color-blue-400: var(--ai-accent);
|
|
113
|
+
--color-blue-300: var(--ai-accent-strong);
|
|
114
|
+
--color-blue-200: var(--ai-accent-strong);
|
|
115
|
+
--color-blue-900: color-mix(in srgb, var(--ai-accent) 28%, #ffffff);
|
|
116
|
+
--color-blue-950: color-mix(in srgb, var(--ai-accent) 36%, #ffffff);
|
|
117
|
+
--color-indigo-400: var(--ai-accent);
|
|
118
|
+
--color-indigo-300: var(--ai-accent-strong);
|
|
119
|
+
--color-indigo-200: var(--ai-accent-strong);
|
|
120
|
+
--color-indigo-900: color-mix(in srgb, var(--ai-accent) 28%, #e0e7ff);
|
|
121
|
+
--color-indigo-950: color-mix(in srgb, var(--ai-accent) 38%, #e0e7ff);
|
|
122
|
+
--color-emerald-400: #059669;
|
|
123
|
+
--color-emerald-300: #047857;
|
|
124
|
+
--color-emerald-200: #065f46;
|
|
125
|
+
--color-emerald-900: #6ee7b7;
|
|
126
|
+
--color-emerald-950: #a7f3d0;
|
|
127
|
+
--color-amber-400: #d97706;
|
|
128
|
+
--color-amber-300: #b45309;
|
|
129
|
+
--color-amber-200: #92400e;
|
|
130
|
+
--color-amber-900: #fcd34d;
|
|
131
|
+
--color-amber-950: #fde68a;
|
|
132
|
+
--color-rose-400: #e11d48;
|
|
133
|
+
--color-rose-300: #be123c;
|
|
134
|
+
--color-rose-200: #9f1239;
|
|
135
|
+
--color-rose-900: #fda4af;
|
|
136
|
+
--color-rose-950: #fecdd3;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
/* 补齐自定义阶梯工具类 (slate-850 / slate-750) */
|
|
140
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .bg-slate-850 {
|
|
141
|
+
background-color: var(--color-slate-850);
|
|
142
|
+
}
|
|
143
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .hover\:bg-slate-750:hover {
|
|
144
|
+
background-color: var(--color-slate-750);
|
|
145
|
+
}
|
|
146
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .hover\:bg-slate-850\/60:hover {
|
|
147
|
+
background-color: color-mix(in srgb, var(--color-slate-850) 60%, transparent);
|
|
148
|
+
}
|
|
149
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .hover\:bg-slate-850\/50:hover {
|
|
150
|
+
background-color: color-mix(in srgb, var(--color-slate-850) 50%, transparent);
|
|
151
|
+
}
|
|
152
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .border-slate-750 {
|
|
153
|
+
border-color: var(--color-slate-750);
|
|
154
|
+
}
|
|
155
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) .border-slate-850\/80 {
|
|
156
|
+
border-color: color-mix(in srgb, var(--color-slate-850) 80%, transparent);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) :is(.bg-blue-600, .bg-indigo-600, .from-blue-600, .from-indigo-600).text-white,
|
|
160
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) :is(.hover\:bg-blue-600, .hover\:bg-indigo-600).hover\:text-white:hover {
|
|
161
|
+
color: var(--ai-accent-contrast);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
/* ==========================================================================
|
|
165
|
+
3. 原项目提取配色 (Extracted Original Project Theme — Pine & Emerald / Steel Blue)
|
|
166
|
+
========================================================================== */
|
|
167
|
+
:where([data-palette='legacy']) :where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal),
|
|
168
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-palette='legacy'] {
|
|
169
|
+
--ai-bg: var(--sang-ai-bg, rgba(15, 23, 42, 0.94));
|
|
170
|
+
--ai-surface: var(--sang-ai-surface, rgba(30, 41, 59, 0.7));
|
|
171
|
+
--ai-surface-elevated: var(--sang-ai-surface-elevated, rgba(51, 65, 85, 0.6));
|
|
172
|
+
--ai-surface-hover: var(--sang-ai-surface-hover, rgba(71, 85, 105, 0.55));
|
|
173
|
+
--ai-header-bg: var(--sang-ai-header-bg, rgba(15, 23, 42, 0.6));
|
|
174
|
+
--ai-subbar-bg: var(--sang-ai-subbar-bg, rgba(15, 23, 42, 0.4));
|
|
175
|
+
--ai-input-bg: var(--sang-ai-input-bg, rgba(2, 6, 23, 0.8));
|
|
176
|
+
--ai-code-bg: var(--sang-ai-code-bg, rgba(2, 6, 23, 0.85));
|
|
177
|
+
--ai-border: var(--sang-ai-border, rgba(51, 65, 85, 0.65));
|
|
178
|
+
--ai-border-light: var(--sang-ai-border-light, rgba(71, 85, 105, 0.4));
|
|
179
|
+
--ai-text: var(--sang-ai-text, #f1f5f9);
|
|
180
|
+
--ai-text-secondary: var(--sang-ai-text-secondary, #cbd5e1);
|
|
181
|
+
--ai-muted: var(--sang-ai-muted, #94a3b8);
|
|
182
|
+
--ai-subtle: var(--sang-ai-subtle, #64748b);
|
|
183
|
+
--ai-accent: var(--sang-ai-accent, #10b981);
|
|
184
|
+
--ai-accent-hover: var(--sang-ai-accent-hover, #059669);
|
|
185
|
+
--ai-accent-strong: var(--sang-ai-accent-strong, #34d399);
|
|
186
|
+
--ai-accent-soft: var(--sang-ai-accent-soft, #60a5fa);
|
|
187
|
+
--ai-accent-bg: var(--sang-ai-accent-bg, rgba(16, 185, 129, 0.12));
|
|
188
|
+
--ai-accent-border: var(--sang-ai-accent-border, rgba(16, 185, 129, 0.3));
|
|
189
|
+
--ai-user-bg: var(--sang-ai-user-bg, linear-gradient(135deg, rgba(37, 99, 235, 0.18), rgba(29, 78, 216, 0.12)));
|
|
190
|
+
--ai-user-border: var(--sang-ai-user-border, rgba(59, 130, 246, 0.35));
|
|
191
|
+
--ai-assistant-bg: var(--sang-ai-assistant-bg, rgba(30, 41, 59, 0.4));
|
|
192
|
+
--ai-dialog-bg: var(--sang-ai-dialog-bg, #0b0f17);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
:where([data-palette='legacy']) :where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'],
|
|
196
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-palette='legacy'][data-theme='light'] {
|
|
197
|
+
--ai-bg: var(--sang-ai-bg, #f9fbfd);
|
|
198
|
+
--ai-surface: var(--sang-ai-surface, #ffffff);
|
|
199
|
+
--ai-surface-elevated: var(--sang-ai-surface-elevated, #f1f5f9);
|
|
200
|
+
--ai-surface-hover: var(--sang-ai-surface-hover, #e7edf4);
|
|
201
|
+
--ai-header-bg: var(--sang-ai-header-bg, #ffffff);
|
|
202
|
+
--ai-subbar-bg: var(--sang-ai-subbar-bg, #f4f7fb);
|
|
203
|
+
--ai-input-bg: var(--sang-ai-input-bg, #ffffff);
|
|
204
|
+
--ai-code-bg: var(--sang-ai-code-bg, #f1f5f9);
|
|
205
|
+
--ai-border: var(--sang-ai-border, #dce5ed);
|
|
206
|
+
--ai-border-light: var(--sang-ai-border-light, #e6ecf1);
|
|
207
|
+
--ai-text: var(--sang-ai-text, #1c2a3c);
|
|
208
|
+
--ai-text-secondary: var(--sang-ai-text-secondary, #2d3e53);
|
|
209
|
+
--ai-muted: var(--sang-ai-muted, #65758b);
|
|
210
|
+
--ai-subtle: var(--sang-ai-subtle, #8895a4);
|
|
211
|
+
--ai-accent: var(--sang-ai-accent, #1675d1);
|
|
212
|
+
--ai-accent-hover: var(--sang-ai-accent-hover, #1261ab);
|
|
213
|
+
--ai-accent-strong: var(--sang-ai-accent-strong, #1675d1);
|
|
214
|
+
--ai-accent-soft: var(--sang-ai-accent-soft, #2563eb);
|
|
215
|
+
--ai-accent-bg: var(--sang-ai-accent-bg, #e7f2ff);
|
|
216
|
+
--ai-accent-border: var(--sang-ai-accent-border, #c4dcf8);
|
|
217
|
+
--ai-user-bg: var(--sang-ai-user-bg, #eef5fd);
|
|
218
|
+
--ai-user-border: var(--sang-ai-user-border, #c4dcf8);
|
|
219
|
+
--ai-assistant-bg: var(--sang-ai-assistant-bg, #ffffff);
|
|
220
|
+
--ai-dialog-bg: var(--sang-ai-dialog-bg, #f9fbfd);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
/* ==========================================================================
|
|
224
|
+
4. 滚动条与浅色模式弹窗适配
|
|
225
|
+
========================================================================== */
|
|
226
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)::-webkit-scrollbar,
|
|
227
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) *::-webkit-scrollbar {
|
|
228
|
+
width: 6px;
|
|
229
|
+
height: 6px;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)::-webkit-scrollbar-track,
|
|
233
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) *::-webkit-scrollbar-track {
|
|
234
|
+
background: var(--ai-scrollbar-track);
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)::-webkit-scrollbar-thumb,
|
|
238
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) *::-webkit-scrollbar-thumb {
|
|
239
|
+
background: var(--ai-scrollbar-thumb);
|
|
240
|
+
border-radius: 3px;
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)::-webkit-scrollbar-thumb:hover,
|
|
244
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) *::-webkit-scrollbar-thumb:hover {
|
|
245
|
+
background: var(--ai-scrollbar-thumb-hover);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
@supports (-moz-appearance: none) {
|
|
249
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal) * {
|
|
250
|
+
scrollbar-width: thin;
|
|
251
|
+
scrollbar-color: var(--ai-scrollbar-thumb) var(--ai-scrollbar-track);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.cf-ai-panel[data-theme='light'] {
|
|
256
|
+
box-shadow: 0 20px 52px -12px rgba(15, 23, 42, 0.14), 0 0 0 1px var(--ai-border);
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-header {
|
|
260
|
+
background: var(--ai-header-bg);
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-heading h2,
|
|
264
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-empty h3,
|
|
265
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-message-bubble,
|
|
266
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-markdown,
|
|
267
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-markdown :is(h1, h2, h3, h4, h5, h6, strong, em) {
|
|
268
|
+
color: var(--ai-text);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-bot-avatar,
|
|
272
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-empty-icon-wrap {
|
|
273
|
+
background: var(--ai-accent-bg);
|
|
274
|
+
color: var(--ai-accent);
|
|
275
|
+
box-shadow: none;
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-quick-btn,
|
|
279
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-assistant .cf-ai-message-bubble {
|
|
280
|
+
background: var(--ai-surface);
|
|
281
|
+
color: var(--ai-text);
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-user .cf-ai-message-bubble {
|
|
285
|
+
background: var(--ai-user-bg);
|
|
286
|
+
border-color: var(--ai-user-border);
|
|
287
|
+
color: var(--ai-text);
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-message-role {
|
|
291
|
+
color: var(--ai-accent);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-markdown :is(code, pre, blockquote, th) {
|
|
295
|
+
background: var(--ai-code-bg);
|
|
296
|
+
color: var(--ai-text);
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool {
|
|
300
|
+
background: var(--ai-surface-elevated);
|
|
301
|
+
color: var(--ai-text);
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool summary > span:nth-child(2) {
|
|
305
|
+
color: var(--ai-text);
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool pre {
|
|
309
|
+
background: var(--ai-surface);
|
|
310
|
+
color: var(--ai-text);
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool-badge {
|
|
314
|
+
background: var(--ai-surface-hover);
|
|
315
|
+
color: var(--ai-muted);
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-reasoning {
|
|
319
|
+
background: color-mix(in srgb, #8b5cf6 8%, var(--ai-surface));
|
|
320
|
+
border-color: color-mix(in srgb, #8b5cf6 24%, var(--ai-border));
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-reasoning summary {
|
|
324
|
+
color: #6d28d9;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-reasoning p {
|
|
328
|
+
color: #5b21b6;
|
|
329
|
+
border-top-color: color-mix(in srgb, #8b5cf6 18%, var(--ai-border));
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-icon:hover {
|
|
333
|
+
background: var(--ai-surface-hover);
|
|
334
|
+
color: var(--ai-text);
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
.sang-ai-settings [role='dialog'] {
|
|
338
|
+
background: var(--ai-dialog-bg);
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
.sang-ai-settings[data-theme='light'] [role='dialog'] {
|
|
342
|
+
background: var(--ai-dialog-bg);
|
|
343
|
+
color: var(--ai-text-secondary);
|
|
344
|
+
box-shadow: 0 24px 64px rgba(15, 23, 42, 0.18);
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
.sang-ai-settings[data-theme='light'] [role='dialog'] header h2,
|
|
348
|
+
.sang-ai-settings[data-theme='light'] [role='dialog'] :is(h3, h4, p, strong).text-white {
|
|
349
|
+
color: var(--ai-text);
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
.sang-ai-settings[data-theme='light'] [role='tab'][aria-selected='true'],
|
|
353
|
+
.sang-ai-settings[data-theme='light'] [role='tab'][aria-selected='true'] span {
|
|
354
|
+
color: var(--ai-accent-strong);
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
.sang-ai-settings[data-theme='light'] .cf-ai-active-model {
|
|
358
|
+
background: linear-gradient(
|
|
359
|
+
135deg,
|
|
360
|
+
color-mix(in srgb, var(--ai-accent) 11%, #ffffff) 0%,
|
|
361
|
+
color-mix(in srgb, var(--ai-accent) 4%, #ffffff) 100%
|
|
362
|
+
);
|
|
363
|
+
border-color: color-mix(in srgb, var(--ai-accent) 26%, var(--ai-border));
|
|
364
|
+
box-shadow: 0 6px 20px -6px color-mix(in srgb, var(--ai-accent) 12%, rgba(15, 23, 42, 0.05));
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
.sang-ai-settings[data-theme='light'] .cf-ai-active-model div.text-white {
|
|
368
|
+
color: var(--ai-text);
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
/* 浅色模式:技能规则 (Skills)、智能抠图 (Removal)、快捷短语 (Snippets) 与其他设置 (Other Settings) 顶部横幅卡片背景优化 */
|
|
372
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-skills > fieldset > div:first-of-type,
|
|
373
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-removal .cf-removal-banner,
|
|
374
|
+
.sang-ai-settings[data-theme='light'] .from-indigo-950\/30.via-slate-900\/60.to-blue-950\/20,
|
|
375
|
+
.sang-ai-settings[data-theme='light'] .from-blue-950\/30.via-slate-900\/60.to-indigo-950\/20 {
|
|
376
|
+
background: linear-gradient(
|
|
377
|
+
135deg,
|
|
378
|
+
color-mix(in srgb, var(--ai-accent) 11%, #ffffff) 0%,
|
|
379
|
+
color-mix(in srgb, var(--ai-accent) 3.5%, #ffffff) 52%,
|
|
380
|
+
color-mix(in srgb, var(--ai-accent-soft) 9%, #ffffff) 100%
|
|
381
|
+
);
|
|
382
|
+
border-color: color-mix(in srgb, var(--ai-accent) 24%, var(--ai-border));
|
|
383
|
+
box-shadow:
|
|
384
|
+
0 8px 24px -6px color-mix(in srgb, var(--ai-accent) 12%, rgba(15, 23, 42, 0.06)),
|
|
385
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.9);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-removal .cf-removal-model.is-active,
|
|
389
|
+
.sang-ai-settings[data-theme='light'] .from-blue-950\/25.to-slate-900\/70 {
|
|
390
|
+
background: linear-gradient(
|
|
391
|
+
180deg,
|
|
392
|
+
color-mix(in srgb, var(--ai-accent) 9.5%, #ffffff) 0%,
|
|
393
|
+
#ffffff 100%
|
|
394
|
+
);
|
|
395
|
+
border-color: color-mix(in srgb, var(--ai-accent) 46%, var(--ai-border));
|
|
396
|
+
box-shadow:
|
|
397
|
+
0 10px 24px -8px color-mix(in srgb, var(--ai-accent) 15%, rgba(15, 23, 42, 0.08)),
|
|
398
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.95);
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-skills > fieldset > div:first-of-type > .blur-3xl {
|
|
402
|
+
background-color: color-mix(in srgb, var(--ai-accent) 12%, transparent);
|
|
403
|
+
opacity: 0.65;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-snippets > div > div:first-of-type,
|
|
407
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .bg-blue-950\/20 {
|
|
408
|
+
background: linear-gradient(
|
|
409
|
+
135deg,
|
|
410
|
+
color-mix(in srgb, var(--ai-accent) 11%, #ffffff) 0%,
|
|
411
|
+
color-mix(in srgb, var(--ai-accent) 4%, #ffffff) 55%,
|
|
412
|
+
color-mix(in srgb, var(--ai-accent-soft) 8%, #ffffff) 100%
|
|
413
|
+
);
|
|
414
|
+
border-color: color-mix(in srgb, var(--ai-accent) 26%, var(--ai-border));
|
|
415
|
+
box-shadow:
|
|
416
|
+
0 8px 24px -6px color-mix(in srgb, var(--ai-accent) 10%, rgba(15, 23, 42, 0.05)),
|
|
417
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.9);
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .bg-indigo-950\/20 {
|
|
421
|
+
background: linear-gradient(
|
|
422
|
+
135deg,
|
|
423
|
+
color-mix(in srgb, var(--ai-accent) 11%, #ffffff) 0%,
|
|
424
|
+
color-mix(in srgb, var(--ai-accent) 4%, #ffffff) 100%
|
|
425
|
+
);
|
|
426
|
+
box-shadow: 0 8px 24px -6px color-mix(in srgb, var(--ai-accent) 12%, rgba(15, 23, 42, 0.06));
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other .from-emerald-950\/20,
|
|
430
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .from-emerald-950\/20.via-slate-900\/60.to-slate-900\/80 {
|
|
431
|
+
background: linear-gradient(
|
|
432
|
+
135deg,
|
|
433
|
+
rgba(16, 185, 129, 0.12) 0%,
|
|
434
|
+
rgba(236, 253, 245, 0.82) 48%,
|
|
435
|
+
#ffffff 100%
|
|
436
|
+
);
|
|
437
|
+
border-color: rgba(16, 185, 129, 0.32);
|
|
438
|
+
box-shadow:
|
|
439
|
+
0 8px 24px -6px rgba(16, 185, 129, 0.1),
|
|
440
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.92);
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other .from-amber-950\/20,
|
|
444
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .from-amber-950\/20.via-slate-900\/60.to-slate-900\/80 {
|
|
445
|
+
background: linear-gradient(
|
|
446
|
+
135deg,
|
|
447
|
+
rgba(245, 158, 11, 0.14) 0%,
|
|
448
|
+
rgba(255, 251, 235, 0.86) 48%,
|
|
449
|
+
#ffffff 100%
|
|
450
|
+
);
|
|
451
|
+
border-color: rgba(245, 158, 11, 0.34);
|
|
452
|
+
box-shadow:
|
|
453
|
+
0 8px 24px -6px rgba(245, 158, 11, 0.1),
|
|
454
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.92);
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other .from-rose-950\/20,
|
|
458
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .from-rose-950\/20.via-slate-900\/60.to-slate-900\/80 {
|
|
459
|
+
background: linear-gradient(
|
|
460
|
+
135deg,
|
|
461
|
+
rgba(244, 63, 94, 0.12) 0%,
|
|
462
|
+
rgba(255, 241, 242, 0.84) 48%,
|
|
463
|
+
#ffffff 100%
|
|
464
|
+
);
|
|
465
|
+
border-color: rgba(244, 63, 94, 0.32);
|
|
466
|
+
box-shadow:
|
|
467
|
+
0 8px 24px -6px rgba(244, 63, 94, 0.1),
|
|
468
|
+
inset 0 1px 0 0 rgba(255, 255, 255, 0.92);
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
.sang-ai-settings[data-theme='light'] .sang-ai-security-notice,
|
|
472
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other .bg-amber-500\/10 {
|
|
473
|
+
background: linear-gradient(135deg, rgba(254, 243, 199, 0.65) 0%, rgba(255, 251, 235, 0.92) 100%);
|
|
474
|
+
border-color: rgba(245, 158, 11, 0.3);
|
|
475
|
+
color: #92400e;
|
|
476
|
+
}
|
|
477
|
+
|
|
478
|
+
/* 浅色模式下次级按钮 hover 文字可读性与边框对比度修正 */
|
|
479
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] :is(.bg-slate-800, .bg-slate-850, .bg-slate-800\/60).hover\:text-white:hover,
|
|
480
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] :is(.hover\:bg-slate-800, .hover\:bg-slate-750, .hover\:bg-slate-700).hover\:text-white:hover {
|
|
481
|
+
color: var(--ai-text);
|
|
482
|
+
}
|
|
483
|
+
|
|
484
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .group:hover .group-hover\:text-white {
|
|
485
|
+
color: var(--ai-text);
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-skills > fieldset > div:first-of-type button.bg-slate-850,
|
|
489
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-snippets > div > div:first-of-type button.bg-slate-800,
|
|
490
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other [role='status'] button.bg-slate-800,
|
|
491
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-removal .cf-removal-secondary-btn {
|
|
492
|
+
background-color: rgba(255, 255, 255, 0.92);
|
|
493
|
+
border-color: var(--ai-border);
|
|
494
|
+
color: var(--ai-text-secondary);
|
|
495
|
+
box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-skills > fieldset > div:first-of-type button.bg-slate-850:hover,
|
|
499
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-snippets > div > div:first-of-type button.bg-slate-800:hover,
|
|
500
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-other [role='status'] button.bg-slate-800:hover,
|
|
501
|
+
.sang-ai-settings[data-theme='light'] #ai-settings-tabpanel-removal .cf-removal-secondary-btn:hover:not(:disabled) {
|
|
502
|
+
background-color: #ffffff;
|
|
503
|
+
border-color: var(--ai-accent-border);
|
|
504
|
+
color: var(--ai-accent-strong);
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
:where(.cf-ai-panel, .sang-ai-settings, .sang-ai-portal)[data-theme='light'] .bg-\[\#070a0f\] {
|
|
508
|
+
background-color: var(--ai-surface-elevated);
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
/* ==========================================================================
|
|
512
|
+
5. 浮窗主面板与内部组件布局样式
|
|
513
|
+
========================================================================== */
|
|
514
|
+
.cf-ai-panel {
|
|
515
|
+
position: fixed;
|
|
516
|
+
z-index: 80;
|
|
517
|
+
display: flex;
|
|
518
|
+
flex-direction: column;
|
|
519
|
+
min-width: min(360px, 100vw - 20px);
|
|
520
|
+
color: var(--ai-text);
|
|
521
|
+
background: var(--ai-bg);
|
|
522
|
+
backdrop-filter: blur(24px) saturate(180%);
|
|
523
|
+
-webkit-backdrop-filter: blur(24px) saturate(180%);
|
|
524
|
+
border: 1px solid var(--ai-border);
|
|
525
|
+
border-radius: 18px;
|
|
526
|
+
box-shadow:
|
|
527
|
+
0 24px 60px -12px rgba(0, 0, 0, 0.72),
|
|
528
|
+
0 0 0 1px rgba(255, 255, 255, 0.06),
|
|
529
|
+
0 8px 32px color-mix(in srgb, var(--ai-accent) 7%, transparent);
|
|
530
|
+
overflow: hidden;
|
|
531
|
+
font-size: 13px;
|
|
532
|
+
transition: box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
.cf-ai-panel:focus-within {
|
|
536
|
+
border-color: var(--ai-accent-border);
|
|
537
|
+
box-shadow:
|
|
538
|
+
0 24px 60px -12px rgba(0, 0, 0, 0.78),
|
|
539
|
+
0 0 0 1px var(--ai-accent-border),
|
|
540
|
+
0 8px 32px var(--ai-accent-bg);
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
.cf-ai-panel[data-theme='light']:focus-within {
|
|
544
|
+
border-color: var(--ai-accent-border);
|
|
545
|
+
box-shadow:
|
|
546
|
+
0 20px 52px -12px rgba(15, 23, 42, 0.18),
|
|
547
|
+
0 0 0 1px var(--ai-accent-border),
|
|
548
|
+
0 8px 28px var(--ai-accent-bg);
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
/* 顶部标题栏 */
|
|
552
|
+
.cf-ai-header {
|
|
553
|
+
height: 56px;
|
|
554
|
+
min-height: 56px;
|
|
555
|
+
flex-shrink: 0;
|
|
556
|
+
display: flex;
|
|
557
|
+
align-items: center;
|
|
558
|
+
gap: 10px;
|
|
559
|
+
padding: 0 14px;
|
|
560
|
+
background: var(--ai-header-bg);
|
|
561
|
+
border-bottom: 1px solid var(--ai-border);
|
|
562
|
+
cursor: grab;
|
|
563
|
+
touch-action: none;
|
|
564
|
+
user-select: none;
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
.cf-ai-header:active {
|
|
568
|
+
cursor: grabbing;
|
|
569
|
+
}
|
|
570
|
+
|
|
571
|
+
.cf-ai-header-drag-dots {
|
|
572
|
+
display: inline-grid;
|
|
573
|
+
grid-template-columns: repeat(3, 3.5px);
|
|
574
|
+
grid-template-rows: repeat(2, 3.5px);
|
|
575
|
+
gap: 3px;
|
|
576
|
+
align-items: center;
|
|
577
|
+
justify-content: center;
|
|
578
|
+
flex-shrink: 0;
|
|
579
|
+
cursor: grab;
|
|
580
|
+
user-select: none;
|
|
581
|
+
padding: 3px;
|
|
582
|
+
border-radius: 4px;
|
|
583
|
+
}
|
|
584
|
+
|
|
585
|
+
.cf-ai-header-drag-dots:active {
|
|
586
|
+
cursor: grabbing;
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
.cf-ai-drag-dot {
|
|
590
|
+
width: 3.5px;
|
|
591
|
+
height: 3.5px;
|
|
592
|
+
border-radius: 50%;
|
|
593
|
+
background-color: var(--ai-subtle);
|
|
594
|
+
opacity: 0.6;
|
|
595
|
+
transition: all 0.2s ease;
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
.cf-ai-header:hover .cf-ai-drag-dot {
|
|
599
|
+
opacity: 0.95;
|
|
600
|
+
background-color: var(--ai-muted);
|
|
601
|
+
}
|
|
602
|
+
|
|
603
|
+
/* 当 AI 处理/busy 时,左上角 6 个点呼吸脉冲与波浪光效 */
|
|
604
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot {
|
|
605
|
+
background-color: var(--ai-accent-strong);
|
|
606
|
+
animation: cf-ai-dot-pulse 1.2s infinite ease-in-out;
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(1) { animation-delay: 0.0s; }
|
|
610
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(2) { animation-delay: 0.15s; }
|
|
611
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(3) { animation-delay: 0.3s; }
|
|
612
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(4) { animation-delay: 0.1s; }
|
|
613
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(5) { animation-delay: 0.25s; }
|
|
614
|
+
.cf-ai-header-drag-dots.is-loading .cf-ai-drag-dot:nth-child(6) { animation-delay: 0.4s; }
|
|
615
|
+
|
|
616
|
+
@keyframes cf-ai-dot-pulse {
|
|
617
|
+
0%, 100% {
|
|
618
|
+
transform: scale(0.85);
|
|
619
|
+
opacity: 0.35;
|
|
620
|
+
background-color: var(--ai-accent);
|
|
621
|
+
box-shadow: none;
|
|
622
|
+
}
|
|
623
|
+
50% {
|
|
624
|
+
transform: scale(1.45);
|
|
625
|
+
opacity: 1;
|
|
626
|
+
background-color: var(--ai-accent-strong);
|
|
627
|
+
box-shadow: 0 0 5px var(--ai-accent-strong), 0 0 10px var(--ai-accent-border);
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
.cf-ai-header-drag-icon {
|
|
632
|
+
color: var(--ai-subtle);
|
|
633
|
+
flex-shrink: 0;
|
|
634
|
+
opacity: 0.6;
|
|
635
|
+
transition: opacity 0.2s;
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
.cf-ai-header:hover .cf-ai-header-drag-icon {
|
|
639
|
+
opacity: 1;
|
|
640
|
+
color: var(--ai-muted);
|
|
641
|
+
}
|
|
642
|
+
|
|
643
|
+
.cf-ai-bot-avatar {
|
|
644
|
+
width: 32px;
|
|
645
|
+
height: 32px;
|
|
646
|
+
border-radius: 10px;
|
|
647
|
+
background: linear-gradient(135deg, var(--ai-accent-bg), color-mix(in srgb, var(--ai-accent) 24%, transparent));
|
|
648
|
+
border: 1px solid var(--ai-accent-border);
|
|
649
|
+
display: flex;
|
|
650
|
+
align-items: center;
|
|
651
|
+
justify-content: center;
|
|
652
|
+
color: var(--ai-accent-strong);
|
|
653
|
+
flex-shrink: 0;
|
|
654
|
+
box-shadow: 0 0 16px var(--ai-accent-bg);
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
.cf-ai-heading {
|
|
658
|
+
flex: 1;
|
|
659
|
+
min-width: 0;
|
|
660
|
+
display: flex;
|
|
661
|
+
flex-direction: column;
|
|
662
|
+
gap: 2px;
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
.cf-ai-heading h2 {
|
|
666
|
+
font-size: 14px;
|
|
667
|
+
font-weight: 700;
|
|
668
|
+
margin: 0;
|
|
669
|
+
display: flex;
|
|
670
|
+
align-items: center;
|
|
671
|
+
gap: 6px;
|
|
672
|
+
color: var(--ai-text);
|
|
673
|
+
}
|
|
674
|
+
|
|
675
|
+
.cf-ai-heading-badge {
|
|
676
|
+
font-size: 9px;
|
|
677
|
+
font-weight: 600;
|
|
678
|
+
text-transform: uppercase;
|
|
679
|
+
letter-spacing: 0.06em;
|
|
680
|
+
padding: 1px 6px;
|
|
681
|
+
border-radius: 6px;
|
|
682
|
+
background: var(--ai-accent-bg);
|
|
683
|
+
border: 1px solid var(--ai-accent-border);
|
|
684
|
+
color: var(--ai-accent-strong);
|
|
685
|
+
}
|
|
686
|
+
|
|
687
|
+
.cf-ai-heading > span {
|
|
688
|
+
display: block;
|
|
689
|
+
font-size: 11px;
|
|
690
|
+
color: var(--ai-muted);
|
|
691
|
+
overflow: hidden;
|
|
692
|
+
text-overflow: ellipsis;
|
|
693
|
+
white-space: nowrap;
|
|
694
|
+
}
|
|
695
|
+
|
|
696
|
+
/* 最小化工作状态实时信息跑马灯/滚动条 */
|
|
697
|
+
.cf-ai-minimized-ticker {
|
|
698
|
+
display: flex;
|
|
699
|
+
align-items: center;
|
|
700
|
+
gap: 6px;
|
|
701
|
+
overflow: hidden;
|
|
702
|
+
white-space: nowrap;
|
|
703
|
+
font-size: 11px;
|
|
704
|
+
color: var(--ai-accent-strong);
|
|
705
|
+
animation: cf-ai-fade-in 0.25s ease-out;
|
|
706
|
+
min-width: 0;
|
|
707
|
+
}
|
|
708
|
+
|
|
709
|
+
.cf-ai-ticker-badge {
|
|
710
|
+
font-size: 9px;
|
|
711
|
+
font-weight: 700;
|
|
712
|
+
text-transform: uppercase;
|
|
713
|
+
letter-spacing: 0.05em;
|
|
714
|
+
padding: 1px 5px;
|
|
715
|
+
border-radius: 4px;
|
|
716
|
+
background: var(--ai-accent-bg);
|
|
717
|
+
border: 1px solid var(--ai-accent-border);
|
|
718
|
+
color: var(--ai-accent-strong);
|
|
719
|
+
flex-shrink: 0;
|
|
720
|
+
}
|
|
721
|
+
|
|
722
|
+
.cf-ai-ticker-text {
|
|
723
|
+
overflow: hidden;
|
|
724
|
+
text-overflow: ellipsis;
|
|
725
|
+
white-space: nowrap;
|
|
726
|
+
font-family: inherit;
|
|
727
|
+
font-weight: 500;
|
|
728
|
+
color: var(--ai-text-secondary);
|
|
729
|
+
animation: cf-ai-fade-in 0.25s ease-out, cf-ai-ticker-pulse 2.4s infinite ease-in-out;
|
|
730
|
+
}
|
|
731
|
+
|
|
732
|
+
@keyframes cf-ai-ticker-pulse {
|
|
733
|
+
0%, 100% {
|
|
734
|
+
opacity: 0.85;
|
|
735
|
+
}
|
|
736
|
+
50% {
|
|
737
|
+
opacity: 1;
|
|
738
|
+
color: var(--ai-text);
|
|
739
|
+
}
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
/* 标题栏操作图标按钮 */
|
|
743
|
+
.cf-ai-header-actions {
|
|
744
|
+
display: flex;
|
|
745
|
+
align-items: center;
|
|
746
|
+
gap: 4px;
|
|
747
|
+
}
|
|
748
|
+
|
|
749
|
+
.cf-ai-icon {
|
|
750
|
+
width: 28px;
|
|
751
|
+
height: 28px;
|
|
752
|
+
display: inline-flex;
|
|
753
|
+
align-items: center;
|
|
754
|
+
justify-content: center;
|
|
755
|
+
border-radius: 8px;
|
|
756
|
+
color: var(--ai-muted);
|
|
757
|
+
background: transparent;
|
|
758
|
+
border: none;
|
|
759
|
+
flex-shrink: 0;
|
|
760
|
+
transition: all 0.15s ease;
|
|
761
|
+
cursor: pointer;
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
.cf-ai-icon:hover {
|
|
765
|
+
background: var(--ai-surface-hover);
|
|
766
|
+
color: var(--ai-text);
|
|
767
|
+
}
|
|
768
|
+
|
|
769
|
+
.cf-ai-icon.cf-ai-icon-close:hover {
|
|
770
|
+
background: rgba(239, 68, 68, 0.18);
|
|
771
|
+
color: #ef4444;
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
.cf-ai-icon.cf-ai-icon-active {
|
|
775
|
+
background: var(--ai-accent-bg);
|
|
776
|
+
color: var(--ai-accent-strong);
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
.cf-ai-panel button {
|
|
780
|
+
cursor: pointer;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
.cf-ai-panel button:disabled {
|
|
784
|
+
opacity: 0.4;
|
|
785
|
+
cursor: not-allowed;
|
|
786
|
+
}
|
|
787
|
+
|
|
788
|
+
.cf-ai-panel button:focus-visible,
|
|
789
|
+
.cf-ai-panel summary:focus-visible,
|
|
790
|
+
.cf-ai-panel input:focus-visible,
|
|
791
|
+
.cf-ai-panel select:focus-visible,
|
|
792
|
+
.cf-ai-panel textarea:focus-visible {
|
|
793
|
+
outline: 2px solid var(--ai-accent);
|
|
794
|
+
outline-offset: 1px;
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
/* 模型选择与参数栏 */
|
|
798
|
+
.cf-ai-model-controls {
|
|
799
|
+
display: flex;
|
|
800
|
+
flex-wrap: wrap;
|
|
801
|
+
align-items: center;
|
|
802
|
+
gap: 8px;
|
|
803
|
+
padding: 8px 14px;
|
|
804
|
+
background: var(--ai-subbar-bg);
|
|
805
|
+
border-bottom: 1px solid var(--ai-border);
|
|
806
|
+
flex-shrink: 0;
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
.cf-ai-model-select {
|
|
810
|
+
display: flex;
|
|
811
|
+
align-items: center;
|
|
812
|
+
gap: 6px;
|
|
813
|
+
flex: 1 1 180px;
|
|
814
|
+
min-width: 0;
|
|
815
|
+
background: var(--ai-input-bg);
|
|
816
|
+
border: 1px solid var(--ai-border);
|
|
817
|
+
border-radius: 8px;
|
|
818
|
+
padding: 4px 8px;
|
|
819
|
+
transition: border-color 0.15s;
|
|
820
|
+
}
|
|
821
|
+
|
|
822
|
+
.cf-ai-model-select:focus-within {
|
|
823
|
+
border-color: var(--ai-accent);
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
.cf-ai-model-select > svg {
|
|
827
|
+
color: var(--ai-accent-strong);
|
|
828
|
+
flex-shrink: 0;
|
|
829
|
+
}
|
|
830
|
+
|
|
831
|
+
.cf-ai-model-select select {
|
|
832
|
+
min-width: 0;
|
|
833
|
+
padding: 2px 4px;
|
|
834
|
+
font-size: 11px;
|
|
835
|
+
font-weight: 500;
|
|
836
|
+
background: transparent;
|
|
837
|
+
border: none;
|
|
838
|
+
color: var(--ai-text);
|
|
839
|
+
outline: none;
|
|
840
|
+
cursor: pointer;
|
|
841
|
+
}
|
|
842
|
+
|
|
843
|
+
.cf-ai-reasoning-controls {
|
|
844
|
+
display: flex;
|
|
845
|
+
align-items: center;
|
|
846
|
+
gap: 6px;
|
|
847
|
+
flex: 0 1 auto;
|
|
848
|
+
background: var(--ai-input-bg);
|
|
849
|
+
border: 1px solid var(--ai-border);
|
|
850
|
+
border-radius: 8px;
|
|
851
|
+
padding: 4px 8px;
|
|
852
|
+
transition: border-color 0.15s;
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
.cf-ai-reasoning-controls:focus-within {
|
|
856
|
+
border-color: var(--ai-accent);
|
|
857
|
+
}
|
|
858
|
+
|
|
859
|
+
.cf-ai-reasoning-controls > svg {
|
|
860
|
+
color: #a855f7;
|
|
861
|
+
flex-shrink: 0;
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
.cf-ai-reasoning-controls select {
|
|
865
|
+
width: 64px;
|
|
866
|
+
padding: 2px 2px;
|
|
867
|
+
font-size: 11px;
|
|
868
|
+
font-weight: 500;
|
|
869
|
+
background: transparent;
|
|
870
|
+
border: none;
|
|
871
|
+
color: var(--ai-text);
|
|
872
|
+
outline: none;
|
|
873
|
+
cursor: pointer;
|
|
874
|
+
}
|
|
875
|
+
|
|
876
|
+
/* 会话栏 */
|
|
877
|
+
.cf-ai-session-bar {
|
|
878
|
+
display: flex;
|
|
879
|
+
align-items: center;
|
|
880
|
+
gap: 8px;
|
|
881
|
+
padding: 6px 14px;
|
|
882
|
+
background: var(--ai-subbar-bg);
|
|
883
|
+
border-bottom: 1px solid var(--ai-border-light);
|
|
884
|
+
flex-shrink: 0;
|
|
885
|
+
}
|
|
886
|
+
|
|
887
|
+
.cf-ai-session-bar > span {
|
|
888
|
+
flex: 1;
|
|
889
|
+
min-width: 0;
|
|
890
|
+
overflow: hidden;
|
|
891
|
+
white-space: nowrap;
|
|
892
|
+
text-overflow: ellipsis;
|
|
893
|
+
font-size: 11px;
|
|
894
|
+
font-weight: 600;
|
|
895
|
+
color: var(--ai-text-secondary);
|
|
896
|
+
}
|
|
897
|
+
|
|
898
|
+
/* 上下文环境栏 */
|
|
899
|
+
.cf-ai-context {
|
|
900
|
+
display: flex;
|
|
901
|
+
align-items: center;
|
|
902
|
+
gap: 8px;
|
|
903
|
+
padding: 6px 14px;
|
|
904
|
+
border-bottom: 1px solid var(--ai-border-light);
|
|
905
|
+
font-size: 11px;
|
|
906
|
+
color: var(--ai-muted);
|
|
907
|
+
}
|
|
908
|
+
|
|
909
|
+
.cf-ai-context > span:nth-child(2) {
|
|
910
|
+
overflow: hidden;
|
|
911
|
+
text-overflow: ellipsis;
|
|
912
|
+
white-space: nowrap;
|
|
913
|
+
flex: 1;
|
|
914
|
+
color: var(--ai-muted);
|
|
915
|
+
}
|
|
916
|
+
|
|
917
|
+
.cf-ai-dot {
|
|
918
|
+
width: 6px;
|
|
919
|
+
height: 6px;
|
|
920
|
+
border-radius: 50%;
|
|
921
|
+
background: var(--ai-accent);
|
|
922
|
+
flex-shrink: 0;
|
|
923
|
+
box-shadow: 0 0 8px var(--ai-accent);
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
.cf-ai-meta {
|
|
927
|
+
font-size: 11px;
|
|
928
|
+
color: var(--ai-subtle);
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
/* 消息流区域 */
|
|
932
|
+
.cf-ai-messages-region {
|
|
933
|
+
position: relative;
|
|
934
|
+
display: flex;
|
|
935
|
+
flex-direction: column;
|
|
936
|
+
flex: 1;
|
|
937
|
+
min-height: 0;
|
|
938
|
+
}
|
|
939
|
+
|
|
940
|
+
.cf-ai-messages {
|
|
941
|
+
flex: 1;
|
|
942
|
+
min-height: 0;
|
|
943
|
+
overflow-y: auto;
|
|
944
|
+
padding: 16px 22px 16px 16px;
|
|
945
|
+
overflow-anchor: none;
|
|
946
|
+
scrollbar-width: none;
|
|
947
|
+
}
|
|
948
|
+
|
|
949
|
+
.cf-ai-messages-content {
|
|
950
|
+
display: flex;
|
|
951
|
+
flex-direction: column;
|
|
952
|
+
gap: 14px;
|
|
953
|
+
min-width: 0;
|
|
954
|
+
min-height: 100%;
|
|
955
|
+
}
|
|
956
|
+
|
|
957
|
+
.cf-ai-messages-content > * {
|
|
958
|
+
flex-shrink: 0;
|
|
959
|
+
}
|
|
960
|
+
|
|
961
|
+
.cf-ai-messages::-webkit-scrollbar {
|
|
962
|
+
display: none;
|
|
963
|
+
}
|
|
964
|
+
|
|
965
|
+
.cf-ai-scrollbar {
|
|
966
|
+
position: absolute;
|
|
967
|
+
top: 8px;
|
|
968
|
+
bottom: 8px;
|
|
969
|
+
right: 0;
|
|
970
|
+
width: 10px;
|
|
971
|
+
touch-action: none;
|
|
972
|
+
user-select: none;
|
|
973
|
+
cursor: default;
|
|
974
|
+
}
|
|
975
|
+
|
|
976
|
+
.cf-ai-scrollbar-thumb {
|
|
977
|
+
position: absolute;
|
|
978
|
+
top: 0;
|
|
979
|
+
left: 2px;
|
|
980
|
+
width: 6px;
|
|
981
|
+
background: color-mix(in srgb, var(--ai-muted) 28%, transparent);
|
|
982
|
+
border-radius: 999px;
|
|
983
|
+
pointer-events: none;
|
|
984
|
+
}
|
|
985
|
+
|
|
986
|
+
.cf-ai-scrollbar:hover .cf-ai-scrollbar-thumb,
|
|
987
|
+
.cf-ai-scrollbar:focus-visible .cf-ai-scrollbar-thumb {
|
|
988
|
+
background: color-mix(in srgb, var(--ai-muted) 50%, transparent);
|
|
989
|
+
}
|
|
990
|
+
|
|
991
|
+
.cf-ai-scrollbar:focus-visible {
|
|
992
|
+
outline: 1px solid var(--ai-accent);
|
|
993
|
+
}
|
|
994
|
+
|
|
995
|
+
/* 空状态欢迎区 */
|
|
996
|
+
.cf-ai-empty {
|
|
997
|
+
display: flex;
|
|
998
|
+
flex-direction: column;
|
|
999
|
+
align-items: center;
|
|
1000
|
+
justify-content: center;
|
|
1001
|
+
text-align: center;
|
|
1002
|
+
gap: 12px;
|
|
1003
|
+
padding: 24px 8px;
|
|
1004
|
+
margin: auto 0;
|
|
1005
|
+
container-type: inline-size;
|
|
1006
|
+
}
|
|
1007
|
+
|
|
1008
|
+
.cf-ai-empty-icon-wrap {
|
|
1009
|
+
width: 52px;
|
|
1010
|
+
height: 52px;
|
|
1011
|
+
border-radius: 16px;
|
|
1012
|
+
background: linear-gradient(135deg, var(--ai-accent-bg), color-mix(in srgb, var(--ai-accent) 26%, transparent));
|
|
1013
|
+
border: 1px solid var(--ai-accent-border);
|
|
1014
|
+
display: flex;
|
|
1015
|
+
align-items: center;
|
|
1016
|
+
justify-content: center;
|
|
1017
|
+
color: var(--ai-accent-strong);
|
|
1018
|
+
box-shadow: 0 8px 24px var(--ai-accent-bg);
|
|
1019
|
+
}
|
|
1020
|
+
|
|
1021
|
+
.cf-ai-empty h3 {
|
|
1022
|
+
font-size: 15px;
|
|
1023
|
+
font-weight: 700;
|
|
1024
|
+
color: var(--ai-text);
|
|
1025
|
+
margin: 0;
|
|
1026
|
+
}
|
|
1027
|
+
|
|
1028
|
+
.cf-ai-empty p {
|
|
1029
|
+
font-size: 12px;
|
|
1030
|
+
color: var(--ai-muted);
|
|
1031
|
+
max-width: 320px;
|
|
1032
|
+
margin: 0;
|
|
1033
|
+
line-height: 1.5;
|
|
1034
|
+
}
|
|
1035
|
+
|
|
1036
|
+
/* 快捷提示词建议卡片 */
|
|
1037
|
+
.cf-ai-quick-prompts {
|
|
1038
|
+
display: grid;
|
|
1039
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
1040
|
+
gap: 8px;
|
|
1041
|
+
width: 100%;
|
|
1042
|
+
margin-top: 10px;
|
|
1043
|
+
}
|
|
1044
|
+
|
|
1045
|
+
.cf-ai-quick-btn {
|
|
1046
|
+
min-width: 0;
|
|
1047
|
+
display: flex;
|
|
1048
|
+
align-items: center;
|
|
1049
|
+
gap: 8px;
|
|
1050
|
+
padding: 10px 12px;
|
|
1051
|
+
background: var(--ai-surface);
|
|
1052
|
+
border: 1px solid var(--ai-border);
|
|
1053
|
+
border-radius: 12px;
|
|
1054
|
+
color: var(--ai-text-secondary);
|
|
1055
|
+
font-size: 11px;
|
|
1056
|
+
font-weight: 500;
|
|
1057
|
+
text-align: left;
|
|
1058
|
+
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
1059
|
+
cursor: pointer;
|
|
1060
|
+
line-height: 1.4;
|
|
1061
|
+
}
|
|
1062
|
+
|
|
1063
|
+
.cf-ai-quick-btn:hover {
|
|
1064
|
+
background: var(--ai-accent-bg);
|
|
1065
|
+
border-color: var(--ai-accent-border);
|
|
1066
|
+
color: var(--ai-text);
|
|
1067
|
+
transform: translateY(-1px);
|
|
1068
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.14);
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
.cf-ai-quick-btn span.emoji {
|
|
1072
|
+
font-size: 14px;
|
|
1073
|
+
flex-shrink: 0;
|
|
1074
|
+
}
|
|
1075
|
+
|
|
1076
|
+
.cf-ai-quick-btn .truncate {
|
|
1077
|
+
min-width: 0;
|
|
1078
|
+
}
|
|
1079
|
+
|
|
1080
|
+
@container (max-width: 420px) {
|
|
1081
|
+
.cf-ai-quick-prompts {
|
|
1082
|
+
grid-template-columns: minmax(0, 1fr);
|
|
1083
|
+
}
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1086
|
+
/* 消息卡片 */
|
|
1087
|
+
.cf-ai-message {
|
|
1088
|
+
display: flex;
|
|
1089
|
+
flex-direction: column;
|
|
1090
|
+
animation: cf-ai-fade-in 0.2s ease-out;
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
@keyframes cf-ai-fade-in {
|
|
1094
|
+
from { opacity: 0; transform: translateY(4px); }
|
|
1095
|
+
to { opacity: 1; transform: translateY(0); }
|
|
1096
|
+
}
|
|
1097
|
+
|
|
1098
|
+
.cf-ai-message-header {
|
|
1099
|
+
display: flex;
|
|
1100
|
+
align-items: center;
|
|
1101
|
+
gap: 6px;
|
|
1102
|
+
margin-bottom: 6px;
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
.cf-ai-message-role {
|
|
1106
|
+
font-size: 11px;
|
|
1107
|
+
font-weight: 700;
|
|
1108
|
+
color: var(--ai-accent-strong);
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1111
|
+
.cf-ai-user .cf-ai-message-role {
|
|
1112
|
+
color: var(--ai-accent-soft);
|
|
1113
|
+
margin-left: auto;
|
|
1114
|
+
}
|
|
1115
|
+
|
|
1116
|
+
.cf-ai-message-bubble {
|
|
1117
|
+
border-radius: 14px;
|
|
1118
|
+
padding: 10px 14px;
|
|
1119
|
+
line-height: 1.6;
|
|
1120
|
+
font-size: 12.5px;
|
|
1121
|
+
position: relative;
|
|
1122
|
+
overflow-wrap: anywhere;
|
|
1123
|
+
}
|
|
1124
|
+
|
|
1125
|
+
.cf-ai-user .cf-ai-message-bubble {
|
|
1126
|
+
background: var(--ai-user-bg);
|
|
1127
|
+
border: 1px solid var(--ai-user-border);
|
|
1128
|
+
color: var(--ai-text);
|
|
1129
|
+
border-top-right-radius: 4px;
|
|
1130
|
+
margin-left: 28px;
|
|
1131
|
+
}
|
|
1132
|
+
|
|
1133
|
+
.cf-ai-assistant .cf-ai-message-bubble {
|
|
1134
|
+
background: var(--ai-assistant-bg);
|
|
1135
|
+
border: 1px solid var(--ai-border);
|
|
1136
|
+
color: var(--ai-text);
|
|
1137
|
+
border-top-left-radius: 4px;
|
|
1138
|
+
margin-right: 28px;
|
|
1139
|
+
}
|
|
1140
|
+
|
|
1141
|
+
.cf-ai-message p {
|
|
1142
|
+
margin: 0;
|
|
1143
|
+
white-space: pre-wrap;
|
|
1144
|
+
}
|
|
1145
|
+
|
|
1146
|
+
/* AI Markdown 内容排版 */
|
|
1147
|
+
.cf-ai-markdown {
|
|
1148
|
+
font-size: 12.5px;
|
|
1149
|
+
line-height: 1.65;
|
|
1150
|
+
color: var(--ai-text);
|
|
1151
|
+
overflow-wrap: anywhere;
|
|
1152
|
+
}
|
|
1153
|
+
|
|
1154
|
+
.cf-ai-markdown > *:first-child {
|
|
1155
|
+
margin-top: 0;
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
.cf-ai-markdown > *:last-child {
|
|
1159
|
+
margin-bottom: 0;
|
|
1160
|
+
}
|
|
1161
|
+
|
|
1162
|
+
.cf-ai-markdown p {
|
|
1163
|
+
margin: 0 0 0.6em 0;
|
|
1164
|
+
white-space: normal;
|
|
1165
|
+
}
|
|
1166
|
+
|
|
1167
|
+
.cf-ai-markdown h1,
|
|
1168
|
+
.cf-ai-markdown h2,
|
|
1169
|
+
.cf-ai-markdown h3,
|
|
1170
|
+
.cf-ai-markdown h4,
|
|
1171
|
+
.cf-ai-markdown h5,
|
|
1172
|
+
.cf-ai-markdown h6 {
|
|
1173
|
+
color: var(--ai-text);
|
|
1174
|
+
font-weight: 700;
|
|
1175
|
+
margin: 0.8em 0 0.35em 0;
|
|
1176
|
+
line-height: 1.35;
|
|
1177
|
+
}
|
|
1178
|
+
|
|
1179
|
+
.cf-ai-markdown h1 { font-size: 15px; border-bottom: 1px solid var(--ai-border); padding-bottom: 4px; }
|
|
1180
|
+
.cf-ai-markdown h2 { font-size: 14px; border-bottom: 1px solid var(--ai-border-light); padding-bottom: 3px; }
|
|
1181
|
+
.cf-ai-markdown h3 { font-size: 13px; }
|
|
1182
|
+
.cf-ai-markdown h4 { font-size: 12.5px; }
|
|
1183
|
+
|
|
1184
|
+
.cf-ai-markdown ul,
|
|
1185
|
+
.cf-ai-markdown ol {
|
|
1186
|
+
margin: 0.35em 0 0.6em 0;
|
|
1187
|
+
padding-left: 1.3em;
|
|
1188
|
+
}
|
|
1189
|
+
|
|
1190
|
+
.cf-ai-markdown ul {
|
|
1191
|
+
list-style-type: disc;
|
|
1192
|
+
}
|
|
1193
|
+
|
|
1194
|
+
.cf-ai-markdown ol {
|
|
1195
|
+
list-style-type: decimal;
|
|
1196
|
+
}
|
|
1197
|
+
|
|
1198
|
+
.cf-ai-markdown li {
|
|
1199
|
+
margin-bottom: 0.25em;
|
|
1200
|
+
}
|
|
1201
|
+
|
|
1202
|
+
.cf-ai-markdown li > p {
|
|
1203
|
+
margin-bottom: 0.25em;
|
|
1204
|
+
}
|
|
1205
|
+
|
|
1206
|
+
.cf-ai-markdown strong {
|
|
1207
|
+
font-weight: 700;
|
|
1208
|
+
color: var(--ai-text);
|
|
1209
|
+
}
|
|
1210
|
+
|
|
1211
|
+
.cf-ai-markdown em {
|
|
1212
|
+
font-style: italic;
|
|
1213
|
+
color: var(--ai-text-secondary);
|
|
1214
|
+
}
|
|
1215
|
+
|
|
1216
|
+
.cf-ai-markdown blockquote {
|
|
1217
|
+
margin: 0.6em 0;
|
|
1218
|
+
padding: 4px 12px;
|
|
1219
|
+
border-left: 3px solid var(--ai-accent);
|
|
1220
|
+
background: var(--ai-accent-bg);
|
|
1221
|
+
border-radius: 0 8px 8px 0;
|
|
1222
|
+
color: var(--ai-text-secondary);
|
|
1223
|
+
}
|
|
1224
|
+
|
|
1225
|
+
.cf-ai-markdown blockquote p {
|
|
1226
|
+
margin: 0;
|
|
1227
|
+
}
|
|
1228
|
+
|
|
1229
|
+
.cf-ai-markdown code {
|
|
1230
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
|
|
1231
|
+
font-size: 11.5px;
|
|
1232
|
+
background: var(--ai-code-bg);
|
|
1233
|
+
border: 1px solid var(--ai-border-light);
|
|
1234
|
+
border-radius: 4px;
|
|
1235
|
+
padding: 1.5px 5px;
|
|
1236
|
+
color: var(--ai-accent-strong);
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
.cf-ai-markdown pre {
|
|
1240
|
+
margin: 0.6em 0;
|
|
1241
|
+
padding: 10px 12px;
|
|
1242
|
+
background: var(--ai-code-bg);
|
|
1243
|
+
border: 1px solid var(--ai-border);
|
|
1244
|
+
border-radius: 10px;
|
|
1245
|
+
overflow-x: auto;
|
|
1246
|
+
}
|
|
1247
|
+
|
|
1248
|
+
.cf-ai-markdown pre code {
|
|
1249
|
+
background: transparent;
|
|
1250
|
+
border: none;
|
|
1251
|
+
padding: 0;
|
|
1252
|
+
color: var(--ai-text-secondary);
|
|
1253
|
+
font-size: 11.5px;
|
|
1254
|
+
line-height: 1.5;
|
|
1255
|
+
white-space: pre;
|
|
1256
|
+
}
|
|
1257
|
+
|
|
1258
|
+
.cf-ai-markdown a {
|
|
1259
|
+
color: var(--ai-accent-strong);
|
|
1260
|
+
text-decoration: underline;
|
|
1261
|
+
text-underline-offset: 2px;
|
|
1262
|
+
transition: color 0.15s;
|
|
1263
|
+
}
|
|
1264
|
+
|
|
1265
|
+
.cf-ai-markdown a:hover {
|
|
1266
|
+
color: var(--ai-accent-soft);
|
|
1267
|
+
}
|
|
1268
|
+
|
|
1269
|
+
.cf-ai-markdown table {
|
|
1270
|
+
width: 100%;
|
|
1271
|
+
margin: 0.6em 0;
|
|
1272
|
+
border-collapse: collapse;
|
|
1273
|
+
font-size: 11.5px;
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1276
|
+
.cf-ai-markdown th,
|
|
1277
|
+
.cf-ai-markdown td {
|
|
1278
|
+
padding: 6px 10px;
|
|
1279
|
+
border: 1px solid var(--ai-border);
|
|
1280
|
+
text-align: left;
|
|
1281
|
+
}
|
|
1282
|
+
|
|
1283
|
+
.cf-ai-markdown th {
|
|
1284
|
+
background: var(--ai-surface);
|
|
1285
|
+
font-weight: 600;
|
|
1286
|
+
color: var(--ai-text);
|
|
1287
|
+
}
|
|
1288
|
+
|
|
1289
|
+
.cf-ai-markdown hr {
|
|
1290
|
+
margin: 0.8em 0;
|
|
1291
|
+
border: none;
|
|
1292
|
+
border-top: 1px solid var(--ai-border);
|
|
1293
|
+
}
|
|
1294
|
+
|
|
1295
|
+
/* 思考过程展开卡片 */
|
|
1296
|
+
.cf-ai-reasoning {
|
|
1297
|
+
margin: 6px 0 10px;
|
|
1298
|
+
border-radius: 10px;
|
|
1299
|
+
background: rgba(88, 28, 135, 0.14);
|
|
1300
|
+
border: 1px solid rgba(168, 85, 247, 0.28);
|
|
1301
|
+
overflow: hidden;
|
|
1302
|
+
font-size: 11px;
|
|
1303
|
+
}
|
|
1304
|
+
|
|
1305
|
+
.cf-ai-reasoning summary {
|
|
1306
|
+
cursor: pointer;
|
|
1307
|
+
display: flex;
|
|
1308
|
+
gap: 6px;
|
|
1309
|
+
align-items: center;
|
|
1310
|
+
padding: 6px 10px;
|
|
1311
|
+
color: #c084fc;
|
|
1312
|
+
font-weight: 600;
|
|
1313
|
+
list-style: none;
|
|
1314
|
+
user-select: none;
|
|
1315
|
+
transition: background 0.15s;
|
|
1316
|
+
}
|
|
1317
|
+
|
|
1318
|
+
.cf-ai-reasoning summary:hover {
|
|
1319
|
+
background: rgba(168, 85, 247, 0.1);
|
|
1320
|
+
}
|
|
1321
|
+
|
|
1322
|
+
.cf-ai-reasoning p {
|
|
1323
|
+
margin: 0;
|
|
1324
|
+
padding: 8px 10px 10px;
|
|
1325
|
+
max-height: 200px;
|
|
1326
|
+
overflow-y: auto;
|
|
1327
|
+
color: #d8b4fe;
|
|
1328
|
+
line-height: 1.5;
|
|
1329
|
+
border-top: 1px solid rgba(168, 85, 247, 0.16);
|
|
1330
|
+
font-family: inherit;
|
|
1331
|
+
}
|
|
1332
|
+
|
|
1333
|
+
/* 工具调用卡片 */
|
|
1334
|
+
.cf-ai-tool {
|
|
1335
|
+
border: 1px solid var(--ai-border);
|
|
1336
|
+
border-radius: 10px;
|
|
1337
|
+
margin: 8px 0;
|
|
1338
|
+
background: var(--ai-surface);
|
|
1339
|
+
overflow: hidden;
|
|
1340
|
+
}
|
|
1341
|
+
|
|
1342
|
+
.cf-ai-tool summary {
|
|
1343
|
+
display: flex;
|
|
1344
|
+
align-items: center;
|
|
1345
|
+
gap: 8px;
|
|
1346
|
+
padding: 6px 10px;
|
|
1347
|
+
cursor: pointer;
|
|
1348
|
+
list-style: none;
|
|
1349
|
+
font-size: 11px;
|
|
1350
|
+
font-weight: 600;
|
|
1351
|
+
color: var(--ai-muted);
|
|
1352
|
+
transition: background 0.15s;
|
|
1353
|
+
}
|
|
1354
|
+
|
|
1355
|
+
.cf-ai-tool summary:hover {
|
|
1356
|
+
background: var(--ai-surface-hover);
|
|
1357
|
+
}
|
|
1358
|
+
|
|
1359
|
+
.cf-ai-tool summary > svg {
|
|
1360
|
+
flex-shrink: 0;
|
|
1361
|
+
color: var(--ai-accent-strong);
|
|
1362
|
+
}
|
|
1363
|
+
|
|
1364
|
+
.cf-ai-tool summary > span:nth-child(2) {
|
|
1365
|
+
flex: 1;
|
|
1366
|
+
color: var(--ai-text);
|
|
1367
|
+
}
|
|
1368
|
+
|
|
1369
|
+
.cf-ai-tool summary:has(.cf-ai-tool-model) > span:nth-child(2) {
|
|
1370
|
+
flex: 0 0 auto;
|
|
1371
|
+
}
|
|
1372
|
+
|
|
1373
|
+
.cf-ai-tool-model {
|
|
1374
|
+
flex: 0 1 auto;
|
|
1375
|
+
max-width: 35%;
|
|
1376
|
+
overflow: hidden;
|
|
1377
|
+
color: var(--ai-accent-soft);
|
|
1378
|
+
font-size: 10px;
|
|
1379
|
+
font-weight: 500;
|
|
1380
|
+
text-overflow: ellipsis;
|
|
1381
|
+
white-space: nowrap;
|
|
1382
|
+
}
|
|
1383
|
+
|
|
1384
|
+
.cf-ai-tool summary:has(.cf-ai-tool-model) .cf-ai-tool-duration {
|
|
1385
|
+
margin-left: auto;
|
|
1386
|
+
}
|
|
1387
|
+
|
|
1388
|
+
.cf-ai-tool-badge {
|
|
1389
|
+
font-size: 10px;
|
|
1390
|
+
font-weight: 500;
|
|
1391
|
+
padding: 1px 6px;
|
|
1392
|
+
border-radius: 6px;
|
|
1393
|
+
background: var(--ai-surface-elevated);
|
|
1394
|
+
color: var(--ai-muted);
|
|
1395
|
+
}
|
|
1396
|
+
|
|
1397
|
+
.cf-ai-tool-duration {
|
|
1398
|
+
flex: 0 0 auto;
|
|
1399
|
+
white-space: nowrap;
|
|
1400
|
+
font-size: 10px;
|
|
1401
|
+
font-variant-numeric: tabular-nums;
|
|
1402
|
+
font-weight: 400;
|
|
1403
|
+
color: var(--ai-muted);
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
.cf-ai-tool-badge.running {
|
|
1407
|
+
background: rgba(245, 158, 11, 0.15);
|
|
1408
|
+
color: #fbbf24;
|
|
1409
|
+
}
|
|
1410
|
+
|
|
1411
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool-badge.running {
|
|
1412
|
+
background: rgba(245, 158, 11, 0.14);
|
|
1413
|
+
color: #b45309;
|
|
1414
|
+
}
|
|
1415
|
+
|
|
1416
|
+
.cf-ai-tool-badge.done {
|
|
1417
|
+
background: rgba(16, 185, 129, 0.15);
|
|
1418
|
+
color: #34d399;
|
|
1419
|
+
}
|
|
1420
|
+
|
|
1421
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool-badge.done {
|
|
1422
|
+
background: rgba(16, 185, 129, 0.12);
|
|
1423
|
+
color: #047857;
|
|
1424
|
+
}
|
|
1425
|
+
|
|
1426
|
+
.cf-ai-tool-badge.error {
|
|
1427
|
+
background: rgba(239, 68, 68, 0.15);
|
|
1428
|
+
color: #f87171;
|
|
1429
|
+
}
|
|
1430
|
+
|
|
1431
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-tool-badge.error {
|
|
1432
|
+
background: rgba(239, 68, 68, 0.12);
|
|
1433
|
+
color: #b91c1c;
|
|
1434
|
+
}
|
|
1435
|
+
|
|
1436
|
+
.cf-ai-tool-section-label {
|
|
1437
|
+
padding: 6px 10px;
|
|
1438
|
+
border-top: 1px solid var(--ai-border-light);
|
|
1439
|
+
color: var(--ai-muted);
|
|
1440
|
+
font-size: 11px;
|
|
1441
|
+
font-weight: 600;
|
|
1442
|
+
}
|
|
1443
|
+
|
|
1444
|
+
.cf-ai-tool pre {
|
|
1445
|
+
margin: 0;
|
|
1446
|
+
padding: 8px 10px;
|
|
1447
|
+
background: var(--ai-code-bg);
|
|
1448
|
+
border-top: 1px solid var(--ai-border-light);
|
|
1449
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
|
|
1450
|
+
font-size: 11px;
|
|
1451
|
+
max-height: 160px;
|
|
1452
|
+
overflow-y: auto;
|
|
1453
|
+
color: var(--ai-text-secondary);
|
|
1454
|
+
line-height: 1.5;
|
|
1455
|
+
white-space: pre-wrap;
|
|
1456
|
+
overflow-wrap: anywhere;
|
|
1457
|
+
}
|
|
1458
|
+
|
|
1459
|
+
.cf-ai-preview-link {
|
|
1460
|
+
display: inline-flex;
|
|
1461
|
+
align-items: center;
|
|
1462
|
+
gap: 6px;
|
|
1463
|
+
max-width: calc(100% - 20px);
|
|
1464
|
+
margin: 8px 10px 10px;
|
|
1465
|
+
padding: 5px 8px;
|
|
1466
|
+
border: 1px solid var(--ai-border);
|
|
1467
|
+
border-radius: 6px;
|
|
1468
|
+
background: var(--ai-surface);
|
|
1469
|
+
color: var(--ai-text-secondary);
|
|
1470
|
+
font-size: 11px;
|
|
1471
|
+
cursor: pointer;
|
|
1472
|
+
}
|
|
1473
|
+
|
|
1474
|
+
.cf-ai-preview-link:hover {
|
|
1475
|
+
border-color: var(--ai-accent-border);
|
|
1476
|
+
color: var(--ai-accent-strong);
|
|
1477
|
+
}
|
|
1478
|
+
|
|
1479
|
+
.cf-ai-preview-link span {
|
|
1480
|
+
overflow: hidden;
|
|
1481
|
+
text-overflow: ellipsis;
|
|
1482
|
+
white-space: nowrap;
|
|
1483
|
+
}
|
|
1484
|
+
|
|
1485
|
+
.cf-ai-continue-btn {
|
|
1486
|
+
display: inline-flex;
|
|
1487
|
+
align-items: center;
|
|
1488
|
+
gap: 5px;
|
|
1489
|
+
min-height: 26px;
|
|
1490
|
+
padding: 0 8px;
|
|
1491
|
+
border: 1px solid var(--ai-accent-border);
|
|
1492
|
+
border-radius: 6px;
|
|
1493
|
+
background: var(--ai-accent-bg);
|
|
1494
|
+
color: var(--ai-accent-strong);
|
|
1495
|
+
font-size: 11px;
|
|
1496
|
+
font-weight: 600;
|
|
1497
|
+
cursor: pointer;
|
|
1498
|
+
}
|
|
1499
|
+
|
|
1500
|
+
.cf-ai-continuable-note {
|
|
1501
|
+
margin: 6px 2px;
|
|
1502
|
+
color: var(--ai-muted);
|
|
1503
|
+
font-size: 11px;
|
|
1504
|
+
line-height: 1.45;
|
|
1505
|
+
}
|
|
1506
|
+
|
|
1507
|
+
.cf-ai-continue-btn:hover:not(:disabled) {
|
|
1508
|
+
border-color: var(--ai-accent);
|
|
1509
|
+
background: color-mix(in srgb, var(--ai-accent) 22%, transparent);
|
|
1510
|
+
}
|
|
1511
|
+
|
|
1512
|
+
.cf-ai-continue-btn:disabled {
|
|
1513
|
+
opacity: 0.45;
|
|
1514
|
+
cursor: not-allowed;
|
|
1515
|
+
}
|
|
1516
|
+
|
|
1517
|
+
.cf-ai-error, .cf-ai-tool summary > svg.cf-ai-error {
|
|
1518
|
+
color: #f43f5e;
|
|
1519
|
+
}
|
|
1520
|
+
|
|
1521
|
+
/* 输入区域 */
|
|
1522
|
+
.cf-ai-composer {
|
|
1523
|
+
padding: 10px 14px max(14px, env(safe-area-inset-bottom));
|
|
1524
|
+
background: var(--ai-header-bg);
|
|
1525
|
+
border-top: 1px solid var(--ai-border);
|
|
1526
|
+
flex-shrink: 0;
|
|
1527
|
+
display: flex;
|
|
1528
|
+
flex-direction: column;
|
|
1529
|
+
gap: 8px;
|
|
1530
|
+
}
|
|
1531
|
+
|
|
1532
|
+
.cf-ai-input-wrapper {
|
|
1533
|
+
position: relative;
|
|
1534
|
+
background: var(--ai-input-bg);
|
|
1535
|
+
border: 1px solid var(--ai-border);
|
|
1536
|
+
border-radius: 12px;
|
|
1537
|
+
padding: 8px 10px;
|
|
1538
|
+
transition: all 0.2s ease;
|
|
1539
|
+
}
|
|
1540
|
+
|
|
1541
|
+
.cf-ai-input-wrapper:focus-within {
|
|
1542
|
+
border-color: var(--ai-accent);
|
|
1543
|
+
box-shadow: 0 0 0 2px var(--ai-accent-bg);
|
|
1544
|
+
background: var(--ai-input-bg);
|
|
1545
|
+
}
|
|
1546
|
+
|
|
1547
|
+
.cf-ai-panel textarea {
|
|
1548
|
+
color: var(--ai-text);
|
|
1549
|
+
outline: none;
|
|
1550
|
+
font-family: inherit;
|
|
1551
|
+
}
|
|
1552
|
+
|
|
1553
|
+
.cf-ai-panel textarea::placeholder {
|
|
1554
|
+
color: var(--ai-subtle);
|
|
1555
|
+
}
|
|
1556
|
+
|
|
1557
|
+
.cf-ai-actions {
|
|
1558
|
+
display: flex;
|
|
1559
|
+
justify-content: flex-end;
|
|
1560
|
+
align-items: center;
|
|
1561
|
+
gap: 8px;
|
|
1562
|
+
}
|
|
1563
|
+
|
|
1564
|
+
.cf-ai-actions > .cf-ai-meta {
|
|
1565
|
+
margin-right: auto;
|
|
1566
|
+
}
|
|
1567
|
+
|
|
1568
|
+
.cf-ai-composer-hint {
|
|
1569
|
+
font-size: 10px;
|
|
1570
|
+
color: var(--ai-subtle);
|
|
1571
|
+
}
|
|
1572
|
+
|
|
1573
|
+
.cf-ai-primary, .cf-ai-secondary, .cf-ai-danger {
|
|
1574
|
+
min-height: 32px;
|
|
1575
|
+
display: inline-flex;
|
|
1576
|
+
align-items: center;
|
|
1577
|
+
justify-content: center;
|
|
1578
|
+
gap: 6px;
|
|
1579
|
+
padding: 6px 14px;
|
|
1580
|
+
border-radius: 8px;
|
|
1581
|
+
font-size: 12px;
|
|
1582
|
+
font-weight: 600;
|
|
1583
|
+
transition: all 0.15s ease;
|
|
1584
|
+
border: none;
|
|
1585
|
+
cursor: pointer;
|
|
1586
|
+
}
|
|
1587
|
+
|
|
1588
|
+
.cf-ai-primary {
|
|
1589
|
+
background: linear-gradient(135deg, var(--ai-accent), var(--ai-accent-hover));
|
|
1590
|
+
color: var(--ai-accent-contrast);
|
|
1591
|
+
box-shadow: 0 2px 8px var(--ai-accent-bg);
|
|
1592
|
+
}
|
|
1593
|
+
|
|
1594
|
+
.cf-ai-primary:hover:not(:disabled) {
|
|
1595
|
+
background: linear-gradient(135deg, var(--ai-accent-hover), color-mix(in srgb, var(--ai-accent-hover) 85%, #000000));
|
|
1596
|
+
box-shadow: 0 4px 12px var(--ai-accent-border);
|
|
1597
|
+
}
|
|
1598
|
+
|
|
1599
|
+
.cf-ai-secondary {
|
|
1600
|
+
background: var(--ai-surface-elevated);
|
|
1601
|
+
color: var(--ai-text);
|
|
1602
|
+
border: 1px solid var(--ai-border);
|
|
1603
|
+
}
|
|
1604
|
+
|
|
1605
|
+
.cf-ai-secondary:hover:not(:disabled) {
|
|
1606
|
+
background: var(--ai-surface-hover);
|
|
1607
|
+
}
|
|
1608
|
+
|
|
1609
|
+
.cf-ai-danger {
|
|
1610
|
+
background: #e11d48;
|
|
1611
|
+
color: white;
|
|
1612
|
+
}
|
|
1613
|
+
|
|
1614
|
+
.cf-ai-danger:hover:not(:disabled) {
|
|
1615
|
+
background: #be123c;
|
|
1616
|
+
}
|
|
1617
|
+
|
|
1618
|
+
/* 确认操作条 */
|
|
1619
|
+
.cf-ai-confirm {
|
|
1620
|
+
padding: 12px 14px;
|
|
1621
|
+
background: rgba(225, 29, 72, 0.14);
|
|
1622
|
+
border-top: 1px solid rgba(225, 29, 72, 0.5);
|
|
1623
|
+
flex-shrink: 0;
|
|
1624
|
+
overflow-wrap: anywhere;
|
|
1625
|
+
}
|
|
1626
|
+
|
|
1627
|
+
.cf-ai-confirm p {
|
|
1628
|
+
margin: 0 0 8px;
|
|
1629
|
+
line-height: 1.5;
|
|
1630
|
+
font-size: 12px;
|
|
1631
|
+
color: var(--ai-text);
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1634
|
+
/* 设置抽屉 */
|
|
1635
|
+
.cf-ai-settings {
|
|
1636
|
+
padding: 16px;
|
|
1637
|
+
display: flex;
|
|
1638
|
+
flex-direction: column;
|
|
1639
|
+
gap: 14px;
|
|
1640
|
+
overflow-y: auto;
|
|
1641
|
+
min-height: 0;
|
|
1642
|
+
}
|
|
1643
|
+
|
|
1644
|
+
.cf-ai-settings label {
|
|
1645
|
+
display: flex;
|
|
1646
|
+
flex-direction: column;
|
|
1647
|
+
gap: 5px;
|
|
1648
|
+
font-size: 11.5px;
|
|
1649
|
+
font-weight: 500;
|
|
1650
|
+
color: var(--ai-text-secondary);
|
|
1651
|
+
min-width: 0;
|
|
1652
|
+
}
|
|
1653
|
+
|
|
1654
|
+
.cf-ai-settings input,
|
|
1655
|
+
.cf-ai-settings select,
|
|
1656
|
+
.cf-ai-settings textarea {
|
|
1657
|
+
background: var(--ai-input-bg);
|
|
1658
|
+
border: 1px solid var(--ai-border);
|
|
1659
|
+
border-radius: 8px;
|
|
1660
|
+
color: var(--ai-text);
|
|
1661
|
+
padding: 8px 10px;
|
|
1662
|
+
outline: none;
|
|
1663
|
+
font-size: 12px;
|
|
1664
|
+
transition: border-color 0.15s;
|
|
1665
|
+
}
|
|
1666
|
+
|
|
1667
|
+
.cf-ai-settings input:focus,
|
|
1668
|
+
.cf-ai-settings select:focus,
|
|
1669
|
+
.cf-ai-settings textarea:focus {
|
|
1670
|
+
border-color: var(--ai-accent);
|
|
1671
|
+
}
|
|
1672
|
+
|
|
1673
|
+
.cf-ai-section-title {
|
|
1674
|
+
display: flex;
|
|
1675
|
+
gap: 8px;
|
|
1676
|
+
align-items: center;
|
|
1677
|
+
}
|
|
1678
|
+
|
|
1679
|
+
.cf-ai-section-title h3 {
|
|
1680
|
+
font-size: 14px;
|
|
1681
|
+
font-weight: 700;
|
|
1682
|
+
color: var(--ai-text);
|
|
1683
|
+
margin: 0;
|
|
1684
|
+
}
|
|
1685
|
+
|
|
1686
|
+
.cf-ai-secret {
|
|
1687
|
+
position: relative;
|
|
1688
|
+
}
|
|
1689
|
+
|
|
1690
|
+
.cf-ai-secret input {
|
|
1691
|
+
padding-right: 36px;
|
|
1692
|
+
width: 100%;
|
|
1693
|
+
}
|
|
1694
|
+
|
|
1695
|
+
.cf-ai-secret button {
|
|
1696
|
+
position: absolute;
|
|
1697
|
+
right: 4px;
|
|
1698
|
+
top: 4px;
|
|
1699
|
+
}
|
|
1700
|
+
|
|
1701
|
+
.cf-ai-field-row {
|
|
1702
|
+
display: grid;
|
|
1703
|
+
grid-template-columns: 1fr 1fr;
|
|
1704
|
+
gap: 10px;
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
.cf-ai-settings-fields {
|
|
1708
|
+
border: 0;
|
|
1709
|
+
padding: 0;
|
|
1710
|
+
margin: 0;
|
|
1711
|
+
display: flex;
|
|
1712
|
+
flex-direction: column;
|
|
1713
|
+
gap: 12px;
|
|
1714
|
+
min-width: 0;
|
|
1715
|
+
}
|
|
1716
|
+
|
|
1717
|
+
.cf-ai-selector-row, .cf-ai-provider-row {
|
|
1718
|
+
display: flex;
|
|
1719
|
+
align-items: flex-end;
|
|
1720
|
+
gap: 8px;
|
|
1721
|
+
min-width: 0;
|
|
1722
|
+
}
|
|
1723
|
+
|
|
1724
|
+
.cf-ai-selector-row > label, .cf-ai-provider-row > select {
|
|
1725
|
+
flex: 1;
|
|
1726
|
+
min-width: 0;
|
|
1727
|
+
}
|
|
1728
|
+
|
|
1729
|
+
.cf-ai-tabs {
|
|
1730
|
+
display: flex;
|
|
1731
|
+
border-bottom: 1px solid var(--ai-border);
|
|
1732
|
+
flex-shrink: 0;
|
|
1733
|
+
gap: 4px;
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
.cf-ai-tabs button {
|
|
1737
|
+
padding: 8px 12px;
|
|
1738
|
+
font-size: 12px;
|
|
1739
|
+
font-weight: 600;
|
|
1740
|
+
border-bottom: 2px solid transparent;
|
|
1741
|
+
color: var(--ai-muted);
|
|
1742
|
+
background: transparent;
|
|
1743
|
+
border-top: none;
|
|
1744
|
+
border-left: none;
|
|
1745
|
+
border-right: none;
|
|
1746
|
+
transition: all 0.15s;
|
|
1747
|
+
}
|
|
1748
|
+
|
|
1749
|
+
.cf-ai-tabs button:hover {
|
|
1750
|
+
color: var(--ai-text);
|
|
1751
|
+
}
|
|
1752
|
+
|
|
1753
|
+
.cf-ai-tabs button[aria-selected=true] {
|
|
1754
|
+
color: var(--ai-accent);
|
|
1755
|
+
border-color: var(--ai-accent);
|
|
1756
|
+
}
|
|
1757
|
+
|
|
1758
|
+
.cf-ai-settings label.cf-ai-checkbox, .cf-ai-checkbox {
|
|
1759
|
+
display: inline-flex;
|
|
1760
|
+
flex-direction: row;
|
|
1761
|
+
align-items: center;
|
|
1762
|
+
gap: 6px;
|
|
1763
|
+
font-size: 12px;
|
|
1764
|
+
white-space: nowrap;
|
|
1765
|
+
cursor: pointer;
|
|
1766
|
+
}
|
|
1767
|
+
|
|
1768
|
+
.cf-ai-panel .cf-ai-checkbox input {
|
|
1769
|
+
width: 14px;
|
|
1770
|
+
height: 14px;
|
|
1771
|
+
padding: 0;
|
|
1772
|
+
accent-color: var(--ai-accent);
|
|
1773
|
+
cursor: pointer;
|
|
1774
|
+
}
|
|
1775
|
+
|
|
1776
|
+
.cf-ai-efforts {
|
|
1777
|
+
display: flex;
|
|
1778
|
+
flex-wrap: wrap;
|
|
1779
|
+
gap: 8px 12px;
|
|
1780
|
+
}
|
|
1781
|
+
|
|
1782
|
+
/* Token 用量指示器 */
|
|
1783
|
+
.cf-ai-usage {
|
|
1784
|
+
color: var(--ai-muted);
|
|
1785
|
+
font-size: 11px;
|
|
1786
|
+
}
|
|
1787
|
+
|
|
1788
|
+
.cf-ai-usage summary {
|
|
1789
|
+
display: flex;
|
|
1790
|
+
flex-wrap: wrap;
|
|
1791
|
+
align-items: center;
|
|
1792
|
+
gap: 6px;
|
|
1793
|
+
cursor: pointer;
|
|
1794
|
+
list-style: none;
|
|
1795
|
+
min-height: 20px;
|
|
1796
|
+
font-weight: 500;
|
|
1797
|
+
user-select: none;
|
|
1798
|
+
}
|
|
1799
|
+
|
|
1800
|
+
.cf-ai-usage summary > svg {
|
|
1801
|
+
color: var(--ai-accent-strong);
|
|
1802
|
+
flex-shrink: 0;
|
|
1803
|
+
}
|
|
1804
|
+
|
|
1805
|
+
.cf-ai-usage summary > span:last-child {
|
|
1806
|
+
margin-left: auto;
|
|
1807
|
+
font-variant-numeric: tabular-nums;
|
|
1808
|
+
overflow-wrap: anywhere;
|
|
1809
|
+
color: var(--ai-text-secondary);
|
|
1810
|
+
}
|
|
1811
|
+
|
|
1812
|
+
.cf-ai-usage dl {
|
|
1813
|
+
display: grid;
|
|
1814
|
+
grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
|
|
1815
|
+
gap: 4px 8px;
|
|
1816
|
+
margin: 6px 0;
|
|
1817
|
+
max-height: 120px;
|
|
1818
|
+
overflow-y: auto;
|
|
1819
|
+
font-size: 10.5px;
|
|
1820
|
+
padding: 6px 8px;
|
|
1821
|
+
background: var(--ai-input-bg);
|
|
1822
|
+
border-radius: 8px;
|
|
1823
|
+
}
|
|
1824
|
+
|
|
1825
|
+
.cf-ai-usage dt, .cf-ai-usage dd {
|
|
1826
|
+
margin: 0;
|
|
1827
|
+
overflow-wrap: anywhere;
|
|
1828
|
+
}
|
|
1829
|
+
|
|
1830
|
+
.cf-ai-usage dd {
|
|
1831
|
+
text-align: right;
|
|
1832
|
+
color: var(--ai-text);
|
|
1833
|
+
font-variant-numeric: tabular-nums;
|
|
1834
|
+
font-weight: 600;
|
|
1835
|
+
}
|
|
1836
|
+
|
|
1837
|
+
.cf-ai-usage progress {
|
|
1838
|
+
display: block;
|
|
1839
|
+
width: 100%;
|
|
1840
|
+
height: 4px;
|
|
1841
|
+
appearance: none;
|
|
1842
|
+
border: 0;
|
|
1843
|
+
background: var(--ai-surface-elevated);
|
|
1844
|
+
border-radius: 999px;
|
|
1845
|
+
overflow: hidden;
|
|
1846
|
+
margin-top: 4px;
|
|
1847
|
+
}
|
|
1848
|
+
|
|
1849
|
+
.cf-ai-usage progress::-webkit-progress-bar {
|
|
1850
|
+
background: var(--ai-surface-elevated);
|
|
1851
|
+
border-radius: 999px;
|
|
1852
|
+
}
|
|
1853
|
+
|
|
1854
|
+
.cf-ai-usage progress::-webkit-progress-value {
|
|
1855
|
+
background: linear-gradient(90deg, var(--ai-accent), var(--ai-accent-strong));
|
|
1856
|
+
border-radius: 999px;
|
|
1857
|
+
}
|
|
1858
|
+
|
|
1859
|
+
.cf-ai-usage progress::-moz-progress-bar {
|
|
1860
|
+
background: var(--ai-accent);
|
|
1861
|
+
border-radius: 999px;
|
|
1862
|
+
}
|
|
1863
|
+
|
|
1864
|
+
.cf-ai-usage-warning {
|
|
1865
|
+
color: #f59e0b;
|
|
1866
|
+
}
|
|
1867
|
+
|
|
1868
|
+
.cf-ai-usage-warning progress::-webkit-progress-value {
|
|
1869
|
+
background: #f59e0b;
|
|
1870
|
+
}
|
|
1871
|
+
|
|
1872
|
+
.cf-ai-usage-warning progress::-moz-progress-bar {
|
|
1873
|
+
background: #f59e0b;
|
|
1874
|
+
}
|
|
1875
|
+
|
|
1876
|
+
.cf-ai-usage-status {
|
|
1877
|
+
margin-top: 4px;
|
|
1878
|
+
font-size: 10px;
|
|
1879
|
+
}
|
|
1880
|
+
|
|
1881
|
+
/* 尺寸缩放手柄 (保留右下角调整大小功能,不展示图标) */
|
|
1882
|
+
.cf-ai-resize {
|
|
1883
|
+
position: absolute;
|
|
1884
|
+
right: 0;
|
|
1885
|
+
bottom: 0;
|
|
1886
|
+
width: 20px;
|
|
1887
|
+
height: 20px;
|
|
1888
|
+
cursor: nwse-resize !important;
|
|
1889
|
+
touch-action: none;
|
|
1890
|
+
background: transparent;
|
|
1891
|
+
border: none;
|
|
1892
|
+
z-index: 30;
|
|
1893
|
+
}
|
|
1894
|
+
|
|
1895
|
+
.cf-ai-resize svg {
|
|
1896
|
+
display: none !important;
|
|
1897
|
+
}
|
|
1898
|
+
|
|
1899
|
+
.cf-ai-minimized .cf-ai-header {
|
|
1900
|
+
height: 48px;
|
|
1901
|
+
min-height: 48px;
|
|
1902
|
+
gap: 8px;
|
|
1903
|
+
padding-inline: 12px;
|
|
1904
|
+
border-bottom: 0;
|
|
1905
|
+
}
|
|
1906
|
+
|
|
1907
|
+
.cf-ai-config-error {
|
|
1908
|
+
padding: 10px 14px;
|
|
1909
|
+
background: rgba(225, 29, 72, 0.16);
|
|
1910
|
+
border-bottom: 1px solid rgba(225, 29, 72, 0.35);
|
|
1911
|
+
color: #fb7185;
|
|
1912
|
+
display: flex;
|
|
1913
|
+
align-items: center;
|
|
1914
|
+
gap: 8px;
|
|
1915
|
+
flex-shrink: 0;
|
|
1916
|
+
font-size: 11.5px;
|
|
1917
|
+
}
|
|
1918
|
+
|
|
1919
|
+
.cf-ai-panel[data-theme='light'] .cf-ai-config-error {
|
|
1920
|
+
background: rgba(225, 29, 72, 0.08);
|
|
1921
|
+
border-bottom-color: rgba(225, 29, 72, 0.25);
|
|
1922
|
+
color: #be123c;
|
|
1923
|
+
}
|
|
1924
|
+
|
|
1925
|
+
.cf-ai-config-error > span {
|
|
1926
|
+
flex: 1;
|
|
1927
|
+
min-width: 0;
|
|
1928
|
+
}
|
|
1929
|
+
|
|
1930
|
+
/* 会话列表抽屉 */
|
|
1931
|
+
.cf-ai-session-list {
|
|
1932
|
+
padding: 0;
|
|
1933
|
+
min-width: 0;
|
|
1934
|
+
}
|
|
1935
|
+
|
|
1936
|
+
.cf-ai-session-list .cf-ai-section-title {
|
|
1937
|
+
justify-content: space-between;
|
|
1938
|
+
margin-bottom: 8px;
|
|
1939
|
+
}
|
|
1940
|
+
|
|
1941
|
+
.cf-ai-session-storage {
|
|
1942
|
+
display: flex;
|
|
1943
|
+
align-items: center;
|
|
1944
|
+
gap: 5px;
|
|
1945
|
+
margin: 0 2px 10px;
|
|
1946
|
+
color: var(--ai-muted);
|
|
1947
|
+
font-size: 10px;
|
|
1948
|
+
line-height: 1.4;
|
|
1949
|
+
}
|
|
1950
|
+
|
|
1951
|
+
.cf-ai-session-storage svg {
|
|
1952
|
+
flex-shrink: 0;
|
|
1953
|
+
}
|
|
1954
|
+
|
|
1955
|
+
.cf-ai-session-storage strong {
|
|
1956
|
+
margin-left: auto;
|
|
1957
|
+
color: var(--ai-text-secondary);
|
|
1958
|
+
font-variant-numeric: tabular-nums;
|
|
1959
|
+
}
|
|
1960
|
+
|
|
1961
|
+
.cf-ai-session-row {
|
|
1962
|
+
display: flex;
|
|
1963
|
+
flex-wrap: wrap;
|
|
1964
|
+
align-items: center;
|
|
1965
|
+
gap: 6px;
|
|
1966
|
+
padding: 8px 10px;
|
|
1967
|
+
border-radius: 10px;
|
|
1968
|
+
margin-bottom: 4px;
|
|
1969
|
+
background: var(--ai-surface);
|
|
1970
|
+
border: 1px solid transparent;
|
|
1971
|
+
transition: all 0.15s;
|
|
1972
|
+
}
|
|
1973
|
+
|
|
1974
|
+
.cf-ai-session-row:hover {
|
|
1975
|
+
background: var(--ai-surface-hover);
|
|
1976
|
+
border-color: var(--ai-border);
|
|
1977
|
+
}
|
|
1978
|
+
|
|
1979
|
+
.cf-ai-session-active {
|
|
1980
|
+
background: var(--ai-accent-bg);
|
|
1981
|
+
border-color: var(--ai-accent-border);
|
|
1982
|
+
}
|
|
1983
|
+
|
|
1984
|
+
.cf-ai-session-select {
|
|
1985
|
+
display: flex;
|
|
1986
|
+
gap: 8px;
|
|
1987
|
+
align-items: center;
|
|
1988
|
+
flex: 1;
|
|
1989
|
+
min-width: 0;
|
|
1990
|
+
text-align: left;
|
|
1991
|
+
background: transparent;
|
|
1992
|
+
border: none;
|
|
1993
|
+
color: inherit;
|
|
1994
|
+
}
|
|
1995
|
+
|
|
1996
|
+
.cf-ai-session-select > svg {
|
|
1997
|
+
flex-shrink: 0;
|
|
1998
|
+
color: var(--ai-muted);
|
|
1999
|
+
}
|
|
2000
|
+
|
|
2001
|
+
.cf-ai-session-active .cf-ai-session-select > svg {
|
|
2002
|
+
color: var(--ai-accent-strong);
|
|
2003
|
+
}
|
|
2004
|
+
|
|
2005
|
+
.cf-ai-session-select > span {
|
|
2006
|
+
display: flex;
|
|
2007
|
+
flex-direction: column;
|
|
2008
|
+
min-width: 0;
|
|
2009
|
+
gap: 1px;
|
|
2010
|
+
}
|
|
2011
|
+
|
|
2012
|
+
.cf-ai-session-select strong {
|
|
2013
|
+
font-size: 12px;
|
|
2014
|
+
font-weight: 600;
|
|
2015
|
+
overflow: hidden;
|
|
2016
|
+
white-space: nowrap;
|
|
2017
|
+
text-overflow: ellipsis;
|
|
2018
|
+
color: var(--ai-text);
|
|
2019
|
+
}
|
|
2020
|
+
|
|
2021
|
+
.cf-ai-session-select small {
|
|
2022
|
+
display: flex;
|
|
2023
|
+
align-items: center;
|
|
2024
|
+
flex-wrap: wrap;
|
|
2025
|
+
column-gap: 6px;
|
|
2026
|
+
row-gap: 2px;
|
|
2027
|
+
font-size: 10px;
|
|
2028
|
+
color: var(--ai-muted);
|
|
2029
|
+
}
|
|
2030
|
+
|
|
2031
|
+
.cf-ai-session-image-count {
|
|
2032
|
+
display: inline-flex;
|
|
2033
|
+
align-items: center;
|
|
2034
|
+
gap: 3px;
|
|
2035
|
+
white-space: nowrap;
|
|
2036
|
+
}
|
|
2037
|
+
|
|
2038
|
+
.cf-ai-session-edit, .cf-ai-session-delete {
|
|
2039
|
+
display: flex;
|
|
2040
|
+
align-items: center;
|
|
2041
|
+
gap: 4px;
|
|
2042
|
+
width: 100%;
|
|
2043
|
+
}
|
|
2044
|
+
|
|
2045
|
+
.cf-ai-session-delete {
|
|
2046
|
+
color: #f43f5e;
|
|
2047
|
+
font-size: 11px;
|
|
2048
|
+
padding-top: 4px;
|
|
2049
|
+
}
|
|
2050
|
+
|
|
2051
|
+
.cf-ai-session-delete > span {
|
|
2052
|
+
flex: 1;
|
|
2053
|
+
min-width: 0;
|
|
2054
|
+
}
|
|
2055
|
+
|
|
2056
|
+
.cf-ai-spin {
|
|
2057
|
+
animation: cf-ai-spin 1s linear infinite;
|
|
2058
|
+
}
|
|
2059
|
+
|
|
2060
|
+
@keyframes cf-ai-spin {
|
|
2061
|
+
to { transform: rotate(360deg); }
|
|
2062
|
+
}
|
|
2063
|
+
|
|
2064
|
+
@media (max-width: 600px) {
|
|
2065
|
+
.cf-ai-header {
|
|
2066
|
+
gap: 6px;
|
|
2067
|
+
padding: 0 10px;
|
|
2068
|
+
}
|
|
2069
|
+
.cf-ai-quick-prompts {
|
|
2070
|
+
grid-template-columns: 1fr;
|
|
2071
|
+
}
|
|
2072
|
+
}
|
|
2073
|
+
|
|
2074
|
+
@media (prefers-reduced-motion: reduce) {
|
|
2075
|
+
.cf-ai-spin {
|
|
2076
|
+
animation: none;
|
|
2077
|
+
}
|
|
2078
|
+
}
|
|
2079
|
+
|
|
2080
|
+
/* 执行异常卡片与重试 */
|
|
2081
|
+
.cf-ai-error-card {
|
|
2082
|
+
animation: cf-ai-fade-in 0.2s ease-out;
|
|
2083
|
+
box-shadow: 0 4px 16px rgba(225, 29, 72, 0.12);
|
|
2084
|
+
}
|
|
2085
|
+
|
|
2086
|
+
/* AI 消息操作栏:单次 Token、复制与重新生成 */
|
|
2087
|
+
.cf-ai-message-footer {
|
|
2088
|
+
display: flex;
|
|
2089
|
+
align-items: center;
|
|
2090
|
+
gap: 8px;
|
|
2091
|
+
margin-top: 6px;
|
|
2092
|
+
margin-right: 28px;
|
|
2093
|
+
padding: 0 4px;
|
|
2094
|
+
}
|
|
2095
|
+
|
|
2096
|
+
.cf-ai-action-btn {
|
|
2097
|
+
background: transparent;
|
|
2098
|
+
border: 1px solid transparent;
|
|
2099
|
+
transition: all 0.15s ease;
|
|
2100
|
+
}
|
|
2101
|
+
|
|
2102
|
+
.cf-ai-action-btn:hover {
|
|
2103
|
+
background: var(--ai-surface-hover);
|
|
2104
|
+
border-color: var(--ai-border);
|
|
2105
|
+
}
|
|
2106
|
+
|
|
2107
|
+
.cf-ai-regenerate-btn {
|
|
2108
|
+
transition: all 0.15s ease;
|
|
2109
|
+
}
|
|
2110
|
+
|
|
2111
|
+
.cf-ai-regenerate-btn:hover:not(:disabled) {
|
|
2112
|
+
border-color: var(--ai-accent-border);
|
|
2113
|
+
box-shadow: 0 2px 8px var(--ai-accent-bg);
|
|
2114
|
+
}
|
|
2115
|
+
|
|
2116
|
+
.cf-ai-token-tag {
|
|
2117
|
+
margin-left: auto;
|
|
2118
|
+
background: var(--ai-surface);
|
|
2119
|
+
border: 1px solid var(--ai-border);
|
|
2120
|
+
transition: all 0.15s ease;
|
|
2121
|
+
}
|
|
2122
|
+
|
|
2123
|
+
.cf-ai-token-tag:hover {
|
|
2124
|
+
background: var(--ai-surface-hover);
|
|
2125
|
+
border-color: var(--ai-accent-border);
|
|
1713
2126
|
}
|