-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle.css
More file actions
983 lines (962 loc) · 33.7 KB
/
style.css
File metadata and controls
983 lines (962 loc) · 33.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
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
71
72
73
74
75
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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
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
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
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
358
359
360
361
362
363
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
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
504
505
506
507
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
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
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
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
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
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
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
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
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
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
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
:root { --bg:#0b0c10; --card:#14161d; --text:#e8e8ea; --muted:#a7a7b2; --line:#242735; --accent:#6ea8fe; --leftW: 30%; --splitW: 6px; --labelW: 170px; --uiScale: 0.80; --btnOutline: rgba(255,255,255,0.10); --btnOutline2: rgba(255,255,255,0.06); }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; }
html { overflow: clip; }
body {
margin: 0;
font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
background: var(--bg);
color: var(--text);
font-size: 11px;
height: 100%;
overflow: clip; /* no global page scroll */
display: flex;
flex-direction: column;
/* NOTE: Do NOT use transform/zoom scaling here — it breaks CodeMirror cursor mapping. */
}
button, input, select, textarea { font-family: inherit; font-size: inherit; }
.container { max-width: 1600px; margin: 0 auto; padding: 11px; }
.header { border-bottom: 1px solid var(--line); background: rgba(255,255,255,0.02); }
/* Header uses full page width (no centered max-width). */
.header .container {
max-width: none;
width: 100%;
}
.headerBar {
display: flex;
align-items: flex-end; /* buttons sit closer to header bottom */
gap: 12px;
}
.headerText { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.headerText h1 { margin: 0; }
.headerText p { margin: 0; }
.toolbar {
display: flex;
align-items: center;
gap: 8px;
margin-top: 0;
padding-top: 0;
border-top: none;
}
.toolbar button {
padding: 5px 10px;
min-height: 24px;
}
.grid { display:flex; gap: 12px; align-items: stretch; min-width: 0; }
.card { background:var(--card); border:1px solid var(--line); border-radius:14px; padding: 11px; }
.panelRight { padding-top: 8px; }
/* main area should fill remaining viewport height */
#mainGrid {
flex: 1 1 auto;
min-height: 0; /* allow children to shrink for inner scroll */
overflow: clip; /* panels handle their own scroll */
contain: layout;
}
/* Use full available page width for workspace (like jsoneditoronline). */
#mainGrid.container {
max-width: none;
width: 100%;
}
h1 { margin: 6px 0 4px; font-size: 15px; }
h2 { margin: 6px 0 6px; font-size: 12px; }
.muted { color: var(--muted); }
.small { font-size: 10px; }
.panelLeft, .panelRight { min-width: 0; min-height: 0; }
.panelLeft {
/* Slightly tighter labels in Settings area */
--labelW: 160px;
flex: 0 0 var(--leftW);
max-width: calc(100% - var(--splitW) - 24px - 360px); /* keep room for right panel */
padding: 0; /* padding moved to inner scroller */
overflow: clip; /* clip scrollbars to rounded corners */
contain: layout paint;
}
/* Extra safety: even if JS clamp fails, don't let left panel collapse too far (desktop only). */
@media (min-width: 981px) {
.panelLeft { min-width: 440px; }
}
.panelLeft .panelScroll{
height: 100%;
overflow: auto;
padding: 11px; /* same as .card default padding */
scrollbar-color: rgba(232,232,234,0.28) transparent;
scrollbar-width: thin;
}
.panelLeft .panelScroll::-webkit-scrollbar { width: 6px; height: 6px; }
.panelLeft .panelScroll::-webkit-scrollbar-track { background: transparent; border-radius: 999px; }
.panelLeft .panelScroll::-webkit-scrollbar-thumb { background: rgba(232,232,234,0.22); border-radius: 999px; border: 0; }
.panelLeft .panelScroll::-webkit-scrollbar-thumb:hover { background: rgba(232,232,234,0.32); }
.panelRight {
overflow: clip; /* avoid double scroll with CodeMirror */
display: flex;
flex-direction: column;
min-width: 360px; /* prevent width collapse during CodeMirror relayout (fold/unfold) */
flex: 1 1 0;
contain: layout paint;
}
.panelRight .editorBar,
.panelRight .jsonNav,
.panelRight .errors { flex: 0 0 auto; }
.panelLeft.dimmed {
opacity: 0.5;
pointer-events: none;
transition: opacity 0.2s ease;
}
.splitter {
width: var(--splitW);
flex: 0 0 var(--splitW);
height: 100%;
border-radius: 999px;
background: transparent;
border: none;
cursor: col-resize;
user-select: none;
position: relative;
}
.splitter::after{
content:"";
position:absolute;
left: 50%;
top: 10px;
bottom: 10px;
width: 2px;
transform: translateX(-50%);
border-radius: 999px;
background: rgba(255,255,255,0.10);
}
.splitter:hover::after { background: rgba(110,168,254,0.35); }
.splitter.dragging::after { background: rgba(110,168,254,0.55); }
.row { display:flex; align-items:center; gap:8px; margin: 4px 0; min-width: 0; }
.row label { width: var(--labelW); color: var(--muted); font-size: 11px; flex-shrink: 0; }
.row input, .row select, .row textarea {
flex: 1; padding: 5px 7px; border-radius: 10px; border:1px solid var(--line);
background:#0f1117; color:var(--text);
min-width: 0;
scrollbar-color: rgba(232,232,234,0.22) transparent;
scrollbar-width: thin;
}
.row textarea::-webkit-scrollbar { width: 6px; height: 6px; }
.row textarea::-webkit-scrollbar-track { background: transparent; border-radius: 999px; }
.row textarea::-webkit-scrollbar-thumb { background: rgba(232,232,234,0.22); border-radius: 999px; border: 0; }
.row textarea::-webkit-scrollbar-thumb:hover { background: rgba(232,232,234,0.32); }
.row textarea::-webkit-resizer { background: transparent; }
.row select{
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
padding-right: 32px;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%23A7A7B2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
background-repeat: no-repeat;
background-position: right 10px center;
background-size: 14px 14px;
}
.row textarea { min-height: 64px; resize: vertical; }
.row input:focus,
.row select:focus,
.row textarea:focus {
/* Match segmented control "selected" outline: crisp border, no outer glow/offset */
outline: none;
border-color: rgba(110,168,254,0.35);
box-shadow: inset 0 0 0 2px rgba(110,168,254,0.55);
}
/* Make number inputs match the design (native spinners are hard to theme) */
.row input[type="number"] {
-moz-appearance: textfield;
appearance: textfield;
}
.row input[type="number"]::-webkit-outer-spin-button,
.row input[type="number"]::-webkit-inner-spin-button {
-webkit-appearance: none;
margin: 0;
}
.row.sectionTitle { align-items: center; gap: 10px; }
.row.sectionTitle h2 { margin: 0; }
.spacer { flex: 1; }
.hint { color: var(--muted); font-size: 11px; white-space: nowrap; }
.commentHint { font-size: 10px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; opacity: 0.9; }
.commentHint::before { content: ""; opacity: 0.9; }
.monoHint { font-size: 10px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; opacity: 0.9; }
.hintRow .hint { flex: 1; white-space: normal; }
.hintLine { display: flex; align-items: center; gap: 6px; }
.hintLine .hint { flex: 1; white-space: normal; }
.hintCard .hintLine .hint { flex: 0 0 auto; }
.hintCard {
border: 1px solid rgba(255,255,255,0.08);
background: rgba(255,255,255,0.03);
border-radius: 10px;
padding: 8px 10px;
display: flex;
flex-direction: column;
gap: 6px;
}
.hintTitle {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 11px;
font-weight: 600;
color: rgba(232,232,234,0.82);
}
.hintCode {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 10px;
line-height: 1.45;
white-space: pre-wrap;
}
.hintCopyBtn {
width: 18px;
height: 18px;
min-width: 18px;
min-height: 18px;
padding: 0;
border-radius: 8px;
font-size: 10px;
opacity: 0.6;
background: transparent;
display: inline-flex;
align-items: center;
justify-content: center;
}
.hintCopyBtn:hover { opacity: 0.9; }
.hintCopyBtn svg { width: 12px; height: 12px; display: block; }
.targetingList { display: flex; flex-direction: column; gap: 0; }
.targetingItem { display: block; }
.targetingItem.targetingMulti {
border-left: 3px solid var(--targetingColor);
padding-left: 8px;
}
.targetingActions .fieldGroup { gap: 6px; }
.removeTargetBtn { flex: 0 0 auto; width: 24px; height: 24px; padding: 0; min-width: 24px; min-height: 24px; }
.targetingModeRow .segmented--sm {
width: var(--targetingControlW);
flex: 0 0 var(--targetingControlW);
}
.segmented--sm label { min-height: 24px; font-size: 10px; padding: 0 8px; }
.targetingModeRow { margin: 4px 0; }
.targetingActions button[data-action="add_targeting"] { width: var(--targetingControlW); }
.payloadJsonHint { display: none; font-size: 10px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; opacity: 0.9; }
.payloadJsonHint::before { content: ""; }
.inappCard.payloadIsJson .payloadJsonHint { display: inline; }
.inappCard textarea[data-f="payload"] {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 10px;
line-height: 1.45;
}
.actions { justify-content:flex-end; }
button {
padding: 5px 10px;
border-radius: 10px;
border: 1px solid var(--btnOutline);
/* Subtle always-visible outline so buttons read as clickable */
box-shadow: inset 0 0 0 1px var(--btnOutline2);
background: #0f1117;
color: var(--text);
cursor: pointer;
font-size: 11px;
font-weight: 500;
transition: all 0.2s ease;
min-height: 24px;
display: inline-flex;
align-items: center;
justify-content: center;
}
button.primary {
background: rgba(110,168,254,0.15);
border-color: rgba(110,168,254,0.35);
}
button.primary:hover {
background: rgba(110,168,254,0.22);
border-color: rgba(110,168,254,0.45);
}
button.ghost {
background: transparent;
}
button.danger {
border-color: rgba(255, 154, 162, 0.35);
background: rgba(255, 154, 162, 0.10);
}
button.danger.ghost {
background: rgba(255, 154, 162, 0.08);
}
button:active {
transform: translateY(1px);
}
button:focus-visible {
outline: 2px solid rgba(110,168,254,0.45);
outline-offset: 2px;
}
button:hover {
border-color: rgba(110,168,254,0.35);
background: rgba(110,168,254,0.08);
}
button:disabled,
button[aria-disabled="true"] {
opacity: 0.45;
cursor: not-allowed;
filter: grayscale(0.2);
}
button.danger:hover {
border-color: rgba(255, 154, 162, 0.55);
background: rgba(255, 154, 162, 0.16);
}
.divider { height:1px; background:var(--line); margin: 10px 0; }
.code { background:#0f1117; border:1px solid var(--line); border-radius: 14px; padding: 10px; overflow:hidden; min-height: 540px; min-width: 0; }
.codeEditor {
width: 100%;
height: 100%;
min-height: 0;
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 10px;
line-height: 1.45;
color: var(--text);
padding: 0 !important;
overflow: clip;
position: relative;
flex: 1 1 auto; /* fill remaining right panel height */
}
/* scrollbar (Cursor-like, consistent with design) */
.codeEditor .CodeMirror,
.codeEditor .CodeMirror-scroll,
.codeEditor .CodeMirror-sizer,
.codeEditor .CodeMirror-vscrollbar,
.codeEditor .CodeMirror-hscrollbar {
scrollbar-color: rgba(232,232,234,0.30) transparent !important;
scrollbar-width: thin !important;
}
.codeEditor .CodeMirror::-webkit-scrollbar,
.codeEditor .CodeMirror-scroll::-webkit-scrollbar,
.codeEditor .CodeMirror-sizer::-webkit-scrollbar,
.codeEditor .CodeMirror-vscrollbar::-webkit-scrollbar,
.codeEditor .CodeMirror-hscrollbar::-webkit-scrollbar {
width: 6px !important;
height: 6px !important;
}
.codeEditor .CodeMirror::-webkit-scrollbar-track,
.codeEditor .CodeMirror-scroll::-webkit-scrollbar-track,
.codeEditor .CodeMirror-sizer::-webkit-scrollbar-track,
.codeEditor .CodeMirror-vscrollbar::-webkit-scrollbar-track,
.codeEditor .CodeMirror-hscrollbar::-webkit-scrollbar-track {
background: transparent !important;
border-radius: 999px !important;
}
.codeEditor .CodeMirror::-webkit-scrollbar-thumb,
.codeEditor .CodeMirror-scroll::-webkit-scrollbar-thumb,
.codeEditor .CodeMirror-sizer::-webkit-scrollbar-thumb,
.codeEditor .CodeMirror-vscrollbar::-webkit-scrollbar-thumb,
.codeEditor .CodeMirror-hscrollbar::-webkit-scrollbar-thumb {
background: rgba(232,232,234,0.24) !important;
border-radius: 999px !important;
border: 0 !important;
}
.codeEditor .CodeMirror::-webkit-scrollbar-thumb:hover,
.codeEditor .CodeMirror-scroll::-webkit-scrollbar-thumb:hover,
.codeEditor .CodeMirror-sizer::-webkit-scrollbar-thumb:hover,
.codeEditor .CodeMirror-vscrollbar::-webkit-scrollbar-thumb:hover,
.codeEditor .CodeMirror-hscrollbar::-webkit-scrollbar-thumb:hover {
background: rgba(232,232,234,0.34) !important;
}
/* CodeMirror theme overrides (match our dark UI) */
.codeEditor .CodeMirror {
height: 100%;
width: 100%;
min-width: 100%;
background: transparent;
color: var(--text);
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 10px;
line-height: 1.45;
/* Clip CM internal scrollbars/fillers to rounded container */
border-radius: 14px;
overflow: hidden;
}
.codeEditor .CodeMirror-scroll { width: 100% !important; }
/* Keep layout stable when scrollbars appear/disappear (fold/unfold) */
/* Avoid forcing scrollbars / tiny overflows that create horizontal scroll. */
.codeEditor .CodeMirror-scroll { scrollbar-gutter: auto; }
.codeEditor .CodeMirror-sizer {
min-width: 100% !important;
/* CodeMirror default: `border-right: 50px solid transparent` on the sizer.
In our styling it turns into a small "phantom" horizontal scroll area
(you can scroll a bit even when lines fit), which looks like an empty zone. */
border-right: 0 !important;
}
.codeEditor .CodeMirror-scroll { padding: 10px 10px 10px 8px; }
/* Slightly tighter gap between gutter and code */
.codeEditor .CodeMirror pre.CodeMirror-line,
.codeEditor .CodeMirror pre.CodeMirror-line-like {
padding: 0 3px;
}
.codeEditor .CodeMirror-scrollbar-filler,
.codeEditor .CodeMirror-gutter-filler {
background: transparent !important; /* no corner background */
border-bottom-right-radius: 14px;
}
.codeEditor .CodeMirror-vscrollbar,
.codeEditor .CodeMirror-hscrollbar {
background: transparent !important; /* avoid light bars behind scrollbars */
}
.codeEditor .CodeMirror-vscrollbar { border-top-right-radius: 14px; border-bottom-right-radius: 14px; }
.codeEditor .CodeMirror-hscrollbar { border-bottom-left-radius: 14px; border-bottom-right-radius: 14px; }
.codeEditor .CodeMirror-gutters {
/* Keep gutter visually solid so code can't "slide under" line numbers area on horizontal scroll */
background: #0f1117;
border-right: 1px solid rgba(255,255,255,0.06);
border-top-left-radius: 14px;
border-bottom-left-radius: 14px;
}
/* CodeMirror places gutter background in separate layers — make them solid too */
.codeEditor .CodeMirror-gutter-background { background: #0f1117 !important; }
.codeEditor .CodeMirror-gutter-wrapper { background: #0f1117 !important; }
/* Make left gutter more compact (line numbers + fold chevrons) */
.codeEditor .CodeMirror-linenumber {
color: rgba(232,232,234,0.38);
min-width: 14px;
padding: 0 1px 0 3px;
}
.codeEditor .CodeMirror-cursor { border-left-color: var(--text); }
.codeEditor .CodeMirror-selected { background: rgba(110,168,254,0.16) !important; }
.codeEditor .CodeMirror-focused .CodeMirror-selected { background: rgba(110,168,254,0.22) !important; }
.codeEditor .CodeMirror-matchingbracket { outline: 1px solid rgba(110,168,254,0.45); color: inherit !important; }
.codeEditor .CodeMirror-foldgutter-open:after,
.codeEditor .CodeMirror-foldgutter-folded:after { color: rgba(232,232,234,0.55); }
.codeEditor .CodeMirror-foldgutter { width: 18px; }
.codeEditor .CodeMirror-foldgutter-open:hover:after,
.codeEditor .CodeMirror-foldgutter-folded:hover:after { color: rgba(110,168,254,0.75); }
.codeEditor .CodeMirror-foldmarker { color: rgba(232,232,234,0.55); }
.codeEditor .CodeMirror-foldgutter-open:after,
.codeEditor .CodeMirror-foldgutter-folded:after {
/* Minimalistic chevrons (override vendor foldgutter.css triangles) */
font-size: 10px;
line-height: 1;
font-weight: 600;
display: inline-block;
transform: translateY(-0.5px);
opacity: 0.75;
transition: opacity 120ms ease;
}
.codeEditor .CodeMirror-foldgutter-open:after { content: "⌄"; } /* open */
.codeEditor .CodeMirror-foldgutter-folded:after { content: "›"; } /* folded */
.codeEditor.isUpdating .CodeMirror-foldgutter-open:after,
.codeEditor.isUpdating .CodeMirror-foldgutter-folded:after {
opacity: 0;
}
/* Focus ring should wrap the whole JSON area (including gutter). */
.codeEditor:focus-within {
/* Stronger OUTER focus ring (consistent all around, including gutter) */
border-color: rgba(110,168,254,0.35);
box-shadow: 0 0 0 2px rgba(110,168,254,0.55);
}
/* Disable inner CM outline to avoid partial/double borders. */
.codeEditor .CodeMirror-focused { outline: none; }
/* token colors (Cursor-like JSON) */
.codeEditor .cm-s-default .cm-property { color: rgba(110,168,254,0.95) !important; } /* keys */
.codeEditor .cm-s-default .cm-string { color: rgba(124, 195, 255, 0.92) !important; } /* strings */
.codeEditor .cm-s-default .cm-number { color: rgba(255, 207, 122, 0.95) !important; } /* numbers */
/* true/false/null only: soft red + italic */
.codeEditor .cm-s-default .cm-atom { color: rgba(255, 154, 162, 0.92) !important; font-style: italic; }
.codeEditor .cm-s-default .cm-comment { color: rgba(167,167,178,0.70) !important; }
.codeEditor .cm-s-default .cm-bracket { color: rgba(250,250,252,0.96) !important; }
.codeEditor .cm-s-default .cm-error { color: #ff9aa2 !important; text-decoration: underline; }
/* subtle active line */
.codeEditor .CodeMirror-activeline-background { background: rgba(255,255,255,0.03); }
/* JSON error highlighting */
.codeEditor .jsonErrorLine .CodeMirror-line,
.codeEditor .CodeMirror-line-wrapper.jsonErrorLine .CodeMirror-line,
.codeEditor .CodeMirror-line.jsonErrorLine {
background: rgba(255,154,162,0.12) !important;
}
/* CodeMirror addLineClass(..., "background", ...) attaches to `.CodeMirror-linebackground` */
.codeEditor .CodeMirror-linebackground.jsonErrorLine {
background: rgba(255,154,162,0.12) !important;
}
.codeEditor .jsonErrorLine .CodeMirror-linenumber,
.codeEditor .CodeMirror-line-wrapper.jsonErrorLine .CodeMirror-linenumber {
color: #ff9aa2 !important;
}
/* CodeMirror search dialog (theme) */
.CodeMirror-dialog {
background: rgba(20,22,29,0.92);
border-bottom: 1px solid rgba(255,255,255,0.08);
color: var(--text);
}
.CodeMirror-dialog input {
background: #0f1117;
color: var(--text);
border: 1px solid rgba(255,255,255,0.10);
border-radius: 10px;
padding: 5px 8px;
}
.CodeMirror-dialog button {
/* Match global button style */
padding: 5px 10px;
min-height: 24px;
border-radius: 10px;
border: 1px solid var(--btnOutline);
box-shadow: inset 0 0 0 1px var(--btnOutline2);
background: #0f1117;
color: var(--text);
}
.errors,
#errors {
/* Collapsed by default; expands when error appears */
flex: 0 0 auto;
max-height: 0;
margin-top: 0;
padding: 0 10px;
border-radius: 10px;
overflow: hidden;
white-space: pre-wrap;
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 11px;
line-height: 1.25;
opacity: 0;
pointer-events: none;
transition: max-height 160ms ease, padding 160ms ease, margin-top 160ms ease, opacity 120ms ease;
}
.errors.isActive,
#errors.isActive {
opacity: 1;
pointer-events: auto;
max-height: 96px;
margin-top: 8px;
padding: 8px 10px;
background: rgba(255, 154, 162, 0.16);
border: 1px solid rgba(255, 154, 162, 0.35);
color: #ff9aa2;
}
.editorBar { margin: 0 0 6px; }
#editorStatus.isError { color: #ff9aa2; }
#editorStatus {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}
.jsonNav {
position: relative;
margin: 0 0 8px;
min-height: 24px; /* stable top zone height (matches buttons) */
/* Use same typography as other UI buttons (not monospace). */
font-family: inherit;
}
.jsonNavTags,
.jsonNavActions {
display: flex;
flex-wrap: wrap;
gap: 6px;
align-items: center;
}
.jsonNavActions {
position: absolute;
inset: 0;
justify-content: flex-start;
opacity: 0;
align-items: flex-start; /* keep baseline identical to tags */
pointer-events: none;
transition: opacity 160ms ease;
}
.jsonNavTags {
transition: opacity 160ms ease;
opacity: 1;
}
.jsonNav--manual .jsonNavTags {
opacity: 0;
pointer-events: none;
}
.jsonNav--manual .jsonNavActions {
opacity: 1;
pointer-events: auto;
}
/* Keep jsonNav buttons consistent with global `button` styles. */
.jsonNav button { min-height: 24px; }
.inappCard {
/* Much tighter label column inside in-app cards */
--labelW: 132px;
--targetingControlW: 110px;
border: 2px solid rgba(110,168,254,0.25);
border-radius: 12px;
padding: 10px;
margin: 8px 0;
background: rgba(110,168,254,0.03);
transition: border-color 0.2s ease, background 0.2s ease;
}
.inappCard:hover {
border-color: rgba(110,168,254,0.40);
background: rgba(110,168,254,0.05);
}
.inappCard[open] {
border-color: rgba(110,168,254,0.35);
}
.inappCard summary {
list-style: none;
cursor: pointer;
}
.inappCard summary::-webkit-details-marker { display: none; }
.inappSummary {
display:flex;
justify-content:space-between;
align-items:center;
gap: 8px;
cursor: pointer;
padding: 6px 0; /* stable when collapsed */
user-select: none;
width: 100%;
}
.inappCard[open] .inappSummary {
padding-bottom: 10px; /* a bit more space before first field when expanded */
}
/* Align "Add in-app" button with card action buttons (slightly inset). */
#addInappBtn { margin-right: 6px; }
.inappSummary::before {
content: "▶";
display: inline-block;
color: rgba(110,168,254,0.60);
font-size: 10px;
margin-right: 6px;
transition: transform 0.2s ease;
flex-shrink: 0;
}
.inappCard[open] > .inappSummary::before {
transform: rotate(90deg);
}
.inappTitle {
display:flex;
align-items:center;
gap: 6px;
flex: 1;
min-width: 0;
}
.dragHandle {
width: 24px;
height: 24px;
min-width: 24px;
min-height: 24px;
padding: 0;
border-radius: 10px;
line-height: 1;
cursor: grab;
user-select: none;
/* Make it clearly interactive (accent outline like other buttons) */
background: rgba(110,168,254,0.08);
border-color: rgba(110,168,254,0.35);
box-shadow: inset 0 0 0 1px rgba(110,168,254,0.14);
color: rgba(232,232,234,0.85);
}
.dragHandle:hover { border-color: rgba(110,168,254,0.50); background: rgba(110,168,254,0.14); }
.dragHandle:active { cursor: grabbing; transform: none; }
.inappCard.dragging {
opacity: 0.95;
box-shadow: 0 14px 40px rgba(0,0,0,0.45);
}
.inappDragPlaceholder {
border: 1px dashed rgba(110,168,254,0.35);
background: rgba(110,168,254,0.05);
border-radius: 14px;
margin: 8px 0;
}
.inappTitle strong {
color: rgba(110,168,254,0.85);
font-weight: 600;
}
.inappActions {
display:flex;
gap: 6px;
flex-shrink: 0;
}
.inappActions button {
padding: 5px 10px;
border-radius: 10px;
font-size: 11px;
min-width: 70px;
text-align: center;
}
.badge { font-size: 12px; color: var(--muted); }
.section {
margin-top: 0;
padding-top: 0;
border-top: none;
}
/* Keep spacing consistent between all field blocks inside a card. */
.section + .section {
margin-top: 6px; /* slightly more space BEFORE the divider line */
border-top: 1px solid rgba(255,255,255,0.08);
padding-top: 6px; /* spacing AFTER the divider line */
}
.section > .row:first-child { margin-top: 0; }
.section > .row:last-child { margin-bottom: 0; }
.sectionHeader { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 6px; }
/* input + small button */
.fieldGroup { display:flex; gap: 8px; flex: 1; min-width: 0; align-items: center; }
.fieldGroup .segmented { width: auto; }
.segmented {
/* Use grid to guarantee strict equal columns (avoids flex rounding/jitter). */
display: grid;
grid-auto-flow: column;
grid-auto-columns: minmax(0, 1fr);
gap: 0;
border: 1px solid var(--btnOutline);
box-shadow: inset 0 0 0 1px var(--btnOutline2);
border-radius: 10px;
overflow: hidden;
background: #0f1117;
width: 100%;
flex: 1;
min-width: 0;
}
.segmented > input {
position: absolute;
opacity: 0;
pointer-events: none;
}
.segmented label {
padding: 0 10px; /* fixed height; no vertical padding */
min-height: 24px;
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 11px;
font-weight: 500;
color: rgba(232,232,234,0.68); /* muted for unselected */
cursor: pointer;
user-select: none;
min-width: 0;
position: relative;
border-radius: 0;
line-height: 1;
width: 100%;
}
.segmented label .hint { color: inherit; }
.segmented label .hint,
.segmented label .monoHint { opacity: 1; }
.segmented > label:first-of-type { border-radius: 10px 0 0 10px; }
.segmented > label:last-of-type { border-radius: 0 10px 10px 0; }
.segmented label > * { position: relative; z-index: 1; }
.segmented > label:not(:first-of-type) { border-left: 1px solid rgba(255,255,255,0.08); }
.segmented > input:focus-visible + label {
outline: 2px solid rgba(110,168,254,0.45);
outline-offset: -2px;
}
.segmented > input:checked + label {
background: rgba(110,168,254,0.16);
border-color: rgba(110,168,254,0.35);
color: var(--text);
}
.segmented > input:checked + label::after {
content: "";
position: absolute;
inset: 0;
border: 2px solid rgba(110,168,254,0.55);
border-radius: inherit;
pointer-events: none;
box-sizing: border-box;
z-index: 2;
}
/* delayTime segmented: second segment contains a number input */
.segmented--delay .delaySecSeg { gap: 8px; }
.segmented--delay > label.delaySecSeg {
/* keep same height as other segmented controls */
padding: 0 8px;
min-height: 24px;
}
.segmented--delay .delaySecInput {
width: 60px;
flex: 0 0 60px;
height: 24px;
padding: 0 10px;
border-radius: 10px;
color: inherit; /* don't force white from .row input; follow segment state */
}
.segmented--delay > input:not(:checked) + label.delaySecSeg .delaySecInput {
/* make unselected segment equally muted (input has its own default styles) */
border-color: rgba(255,255,255,0.07);
background: rgba(255,255,255,0.01); /* thinner, more "embedded" */
box-shadow: none;
}
.segmented--delay > input:checked + label.delaySecSeg .delaySecInput {
border-color: rgba(110,168,254,0.35);
background: #0f1117;
box-shadow: none;
}
.segmented--delay .delaySecInput:disabled {
opacity: 0.65;
cursor: not-allowed;
}
.segmented--delay .delaySecInput:focus {
outline: none;
box-shadow: inset 0 0 0 2px rgba(110,168,254,0.35);
border-color: rgba(110,168,254,0.45);
}
/* frequency segmented: third segment contains a number input */
.segmented--freq > label.freqSecSeg { padding: 0 8px; min-height: 24px; gap: 8px; }
.segmented--freq .freqSecInput {
width: 60px;
flex: 0 0 60px;
height: 24px;
padding: 0 10px;
border-radius: 10px;
color: inherit;
}
.segmented--freq > input:not(:checked) + label.freqSecSeg .freqSecInput {
border-color: rgba(255,255,255,0.07);
background: rgba(255,255,255,0.01);
box-shadow: none;
}
.segmented--freq > input:checked + label.freqSecSeg .freqSecInput {
border-color: rgba(110,168,254,0.35);
background: #0f1117;
box-shadow: none;
}
.segmented--freq .freqSecInput:focus {
outline: none;
box-shadow: inset 0 0 0 2px rgba(110,168,254,0.35);
border-color: rgba(110,168,254,0.45);
}
.inappCard select[data-f="payloadMode"] { flex: 0 0 180px; max-width: 180px; }
.iconBtn {
/* Match global button size */
padding: 5px 10px;
border-radius: 10px;
line-height: 1;
min-height: 24px;
display: inline-flex;
align-items: center;
justify-content: center;
}
.switch { position: relative; display: inline-block; width: 44px; height: 24px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
position: absolute;
cursor: pointer;
top: 0; left: 0; right: 0; bottom: 0;
background: rgba(255,255,255,0.06);
border: 1px solid rgba(255,255,255,0.10);
transition: 0.18s ease;
border-radius: 999px;
}
.slider:before {
position: absolute;
content: "";
height: 18px; width: 18px;
left: 3px; top: 50%;
transform: translateY(-50%);
background: rgba(232,232,234,0.92);
transition: 0.18s ease;
border-radius: 999px;
}
.switch input:checked + .slider {
background: rgba(110,168,254,0.22);
border-color: rgba(110,168,254,0.40);
}
.switch input:checked + .slider:before {
transform: translate(20px, -50%);
}
.switch input:focus-visible + .slider {
outline: 2px solid rgba(110,168,254,0.45);
outline-offset: 2px;
}
/* compact switch (for snackbar margins) */
.switch.switch--sm { width: 34px; height: 18px; }
.switch.switch--sm .slider:before { width: 14px; height: 14px; left: 2px; }
.switch.switch--sm input:checked + .slider:before { transform: translate(16px, -50%); }
.iconBtn.tiny {
width: 24px;
height: 24px;
padding: 0;
min-width: 24px;
min-height: 24px;
text-align: center;
}
.iconBtn svg { display: block; }
.iconBtn.openBtn {
width: 24px;
height: 24px;
padding: 0;
min-width: 24px;
min-height: 24px;
}
.iconBtn.openBtn svg { width: 12px; height: 12px; }
.flash { box-shadow: 0 0 0 2px rgba(110,168,254,0.25); border-color: rgba(110,168,254,0.45) !important; }
.flashError { box-shadow: 0 0 0 2px rgba(255, 154, 162, 0.20); border-color: rgba(255, 154, 162, 0.55) !important; }
/* Conditional fields */
.onlySnackbar, .onlyPeriodic, .onlyGeo, .onlySegment, .onlyProductId, .onlyProductSegment, .onlyOperation, .onlyVisit, .onlyCategoryId, .onlyCategorySegment, .onlyProductIdHint, .onlyCategoryIdHint, .onlyProductSegmentHint, .onlyCategorySegmentHint { display: none; }
.inappCard.isSnackbar .onlySnackbar { display: flex; }
.inappCard.isPeriodic .onlyPeriodic { display: flex; }
.periodicInline, .periodicInlineHint { display: none; }
.inappCard.isPeriodic .periodicInline { display: block; }
.inappCard.isPeriodic .periodicInlineHint { display: inline; }
.periodicInline { flex: 1 1 0 !important; min-width: 0; }
.delaySecInput { min-width: 0; }
.targetingItem.tGeo .onlyGeo { display: flex; }
.targetingItem.tSegment .onlySegment { display: flex; }
.targetingItem.tProductId .onlyProductId { display: flex; }
.targetingItem.tProductId .onlyProductIdHint { display: flex; }
.targetingItem.tProductSegment .onlyProductSegment { display: flex; }
.targetingItem.tProductSegment .onlyProductSegmentHint { display: flex; }
.targetingItem.tOperation .onlyOperation { display: flex; }
.targetingItem.tVisit .onlyVisit { display: flex; }
.targetingItem.tCategoryId .onlyCategoryId { display: flex; }
.targetingItem.tCategoryId .onlyCategoryIdHint { display: flex; }
.targetingItem.tCategorySegment .onlyCategorySegment { display: grid; }
.targetingItem.tCategorySegment .onlyCategorySegmentHint { display: flex; }
/* Conditional rows with 2 controls: enforce strict 50/50 only when visible. */
.targetingItem.tSegment .row.onlySegment,
.targetingItem.tProductId .row.onlyProductId,
.targetingItem.tProductSegment .row.onlyProductSegment,
.targetingItem.tOperation .row.onlyOperation,
.targetingItem.tVisit .row.onlyVisit,
.targetingItem.tCategoryId .row.onlyCategoryId {
display: grid;
grid-template-columns: var(--labelW) minmax(0, 1fr) minmax(0, 1fr);
column-gap: 8px;
align-items: center;
}
.targetingItem.tSegment .row.onlySegment label,
.targetingItem.tProductId .row.onlyProductId label,
.targetingItem.tProductSegment .row.onlyProductSegment label,
.targetingItem.tOperation .row.onlyOperation label,
.targetingItem.tVisit .row.onlyVisit label,
.targetingItem.tCategoryId .row.onlyCategoryId label { width: auto; }
.targetingItem.tSegment .row.onlySegment .fieldGroup,
.targetingItem.tProductId .row.onlyProductId .fieldGroup,
.targetingItem.tProductSegment .row.onlyProductSegment .fieldGroup,
.targetingItem.tOperation .row.onlyOperation .fieldGroup,
.targetingItem.tVisit .row.onlyVisit .fieldGroup,
.targetingItem.tCategoryId .row.onlyCategoryId .fieldGroup { width: 100%; min-width: 0; }
.targetingItem.tCategorySegment .row.onlyCategorySegment {
display: grid;
grid-template-columns: var(--labelW) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
column-gap: 8px;
align-items: center;
}
.targetingItem.tCategorySegment .row.onlyCategorySegment label { width: auto; }
.targetingItem.tCategorySegment .row.onlyCategorySegment .fieldGroup { width: 100%; min-width: 0; }
/* Hide redirect/payload for push reactivation (pushPermission action) */
.inappCard.isPushReactivation .onlyRedirect { display: none; }
.inappCard.closeHidden button[data-action="random_close"] { opacity: 0.45; pointer-events: none; }
/* Snackbar close visibility toggle: keep it consistent with other buttons */
.inappCard .closeVisBtn {
min-height: 20px;
padding: 3px 7px;
border-radius: 9px;
line-height: 1;
}
.inappCard .closeVisBtn svg { width: 16px; height: 16px; }
.inappCard.closeHidden .closeVisBtn {
/* "hidden" state: slightly more muted, but still same button style */
border-color: rgba(255,255,255,0.18);
background: rgba(255,255,255,0.04);
}
.fieldError { border-color: rgba(255, 154, 162, 0.65) !important; box-shadow: 0 0 0 2px rgba(255, 154, 162, 0.15); }
@media (max-width: 980px) {
.grid { grid-template-columns: 1fr; }
.splitter { display: none; }
.row { flex-wrap: wrap; }
.row label { width: 100%; }
/* On narrow screens fall back to normal row flex wrapping */
.targetingItem.tSegment .row.onlySegment,
.targetingItem.tProductId .row.onlyProductId,
.targetingItem.tProductSegment .row.onlyProductSegment,
.targetingItem.tOperation .row.onlyOperation,
.targetingItem.tVisit .row.onlyVisit,
.targetingItem.tCategoryId .row.onlyCategoryId,
.targetingItem.tCategorySegment .row.onlyCategorySegment { display: flex; }
.hint { white-space: normal; }
/* keep independent panel scroll; editor fills panel */
.codeEditor { height: 100%; min-height: 0; }
}