Repository navigation
Expand file tree
/
Copy pathsankey_builder.css
More file actions
1189 lines (1095 loc) · 30.4 KB
/
Copy pathsankey_builder.css
File metadata and controls
1189 lines (1095 loc) · 30.4 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
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/* Design tokens + pricing card styles shared with the marketing landing
page (index2.html) — kept in sync so the in-app pricing modal (see
#pricingModal / renderPricingCards in sankeybuilder.js) looks like the
same product as the "Simple, Transparent Pricing" section there. */
:root {
--primary: #2B4EFF;
--primary-dk: #1A38E0;
--surface: #FFFFFF;
--surface-2: #F5F4F0;
--border: #E2E0D8;
--ink: #0F1117;
--ink-3: #5A5F7A;
--ink-4: #8B90A8;
--gold: #E8A020;
--bronze: #A9702F;
--silver: #8A93A6;
--platinum: #6B4FBB;
}
.plan-card {
background: var(--surface);
border: 1.5px solid var(--border);
border-radius: 12px;
padding: 1.5rem;
height: 100%;
position: relative;
transition: all 0.25s;
}
.plan-card.tier-bronze { border-color: var(--bronze); }
.plan-card.tier-silver { border-color: var(--silver); }
.plan-card.tier-gold { border-color: var(--gold); }
.plan-card.tier-platinum { border-color: var(--platinum); }
.plan-badge {
position: absolute;
top: -12px;
left: 50%;
transform: translateX(-50%);
display: inline-block;
padding: 0.25rem 0.9rem;
border-radius: 20px;
font-size: 0.7rem;
font-weight: 700;
letter-spacing: 0.02em;
text-transform: uppercase;
white-space: nowrap;
}
.plan-badge.tier-free { background: var(--surface-2); color: var(--ink-3); border: 1.5px solid var(--border); }
.plan-badge.tier-bronze { background: var(--bronze); color: #fff; }
.plan-badge.tier-silver { background: var(--silver); color: #fff; }
.plan-badge.tier-gold { background: var(--gold); color: #3A2A00; }
.plan-badge.tier-platinum { background: var(--platinum); color: #fff; }
.plan-price {
font-size: 1.9rem;
font-weight: 900;
color: var(--ink);
margin: 0.5rem 0;
}
.btn-plan {
width: 100%;
padding: 0.6rem;
border-radius: 6px;
font-weight: 700;
text-align: center;
cursor: pointer;
transition: all 0.2s;
border: none;
}
.btn-plan-primary {
background: var(--primary);
color: white;
}
.btn-plan-primary:hover { background: var(--primary-dk); }
.btn-plan-secondary {
background: var(--surface-2);
border: 1.5px solid var(--border);
color: var(--ink);
}
.btn-plan-gold {
background: var(--gold);
color: #3A2A00;
}
.btn-plan-gold:hover { background: #d69214; }
.btn-plan-secondary:hover { background: var(--border); }
.btn-plan:disabled {
opacity: 0.6;
cursor: default;
}
.ui,.fullscreen-btn {
display: none;
}
/* Fallback in case the loaded Bootstrap build ever lacks this utility —
matches Bootstrap 5's own .visually-hidden. Used on .fullscreen-hide-row
to hide the toolbar/nav row on entering fullscreen without display:none,
which was causing a Chrome-only (not Brave) fullscreen centering bug. */
.visually-hidden:not(caption) {
position: absolute !important;
width: 1px !important;
height: 1px !important;
padding: 0 !important;
margin: -1px !important;
overflow: hidden !important;
clip: rect(0, 0, 0, 0) !important;
white-space: nowrap !important;
border: 0 !important;
}
.floating-msg {
position: fixed; /* Position the element relative to the viewport */
bottom: 74px; /* Sit above the fixed footer toolbar instead of overlapping it */
left: 50%; /* Set the left position to 50% */
transform: translateX(-50%); /* Offset by half its width to center horizontally */
z-index: 9999; /* Ensure it appears above other content */
display: none;
}
.btn_background2{
background-color: rgba(0, 0, 0, 0.8);
border-radius: 10px;
width: 100%;
padding:10px;
margin-top:10px;
color:white;
}
.invalid-input {
border: 3px solid red !important;
border-radius: 10px;
transition: all 0.3s ease;
}
.nav-scroll-container {
flex-shrink: 0; /* Prevent nav from shrinking */
position: sticky;
top: 0;
background: white;
z-index: 10;
border-bottom: 1px solid #dee2e6;
padding: 0.5rem 1rem;
box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
#section-content {
flex: 1;
overflow-y: auto;
padding: 1rem;
-webkit-overflow-scrolling: touch;
}
.section-content {
min-height: 100%;
}
/* Ensure form controls are responsive */
.form-control, .form-select, .btn {
font-size: 0.9rem;
}
/* Nav improvements */
.nav-link {
white-space: nowrap;
padding: 0.5rem 1rem;
font-size: 0.9rem;
}
.nav-scroll-container .nav-link.active {
background-color: #0d6efd;
color: white !important;
border-radius: 0.25rem;
}
.nav-link-plan {
background-color: #ffc107;
color: #000;
border: none;
border-radius: 0.25rem;
cursor: pointer;
}
.nav-link-plan:hover {
background-color: #ffca2c;
color: #000;
}
.scroll-container {
display: flex;
flex-direction: column;
width: 100%;
box-sizing: border-box;
}
.wide-toolbar-container {
width: 100%;
max-width: 100%;
box-sizing: border-box;
overflow-x: auto;
overflow-y: hidden;
white-space: nowrap;
padding: 10px 0;
}
/* Mobile: overflow-x:auto containers with min-width:max-content children
can get sized by their scrolling content instead of the parent's width
on some mobile browsers. Force these to fill the viewport. */
@media (max-width: 767px) {
.scroll-container,
.nav-scroll-container,
.wide-toolbar-container,
.scroll-section,
.scroll-content,
.section-content {
width: 100% !important;
max-width: 100% !important;
box-sizing: border-box;
}
/* Keep the toolbar pinned in place and let the diagram scroll
(both directions) in its own region below it. */
html, body {
height: 100%;
margin: 0;
overflow: hidden;
}
body {
display: flex;
flex-direction: column;
}
.container.ui {
flex: 0 0 auto;
max-height: 55vh;
overflow-y: auto;
-webkit-overflow-scrolling: touch;
}
/* Wrapper around #diagram-section (the d-flex div right after the
fullscreen button) becomes the independently scrolling diagram pane.
It already carries Bootstrap's align-items-center class; combined with
overflow:auto that clips anything taller than the pane at the top
(classic flex centering + overflow bug — the "safe" keyword isn't
reliably supported, so use auto margins on the child instead, which
center it when there's room and collapse to 0 / top-align + fully
scroll when there isn't). */
body > .d-flex {
flex: 1 1 auto;
min-height: 0; /* required for a flex child to scroll instead of overflow the page */
overflow: auto;
-webkit-overflow-scrolling: touch;
align-items: flex-start !important;
}
body > .d-flex > #diagram-section {
margin-top: auto;
margin-bottom: auto;
}
/* Guaranteed-visible sizing, independent of any JS width measurement
or resize timing: the SVG's viewBox (see drawSankey in
sankeybuilder.js) is pinned to its native size, so simply capping
width here makes the browser scale the whole diagram down to fit
proportionally, rather than clipping it. Excluded from fullscreen
(its own centering/scrolling scheme) and from .sankey-zoomed (once
scroll-wheel zoom is active, it needs its own real pixel
width/height instead of being forced back down to fit). */
#diagram-section:not(.fullscreen-mode) .sankey-container:not(.sankey-zoomed) #sankey {
width: 100% !important;
height: auto !important;
}
#diagram-section:not(.fullscreen-mode) .sankey-container:not(.sankey-zoomed) #sankey svg {
width: 100% !important;
height: auto !important;
max-width: 100% !important;
transform: none !important;
}
/* Same guarantee for fullscreen (the embed view auto-enters this) --
cap the SVG to the viewport in both directions, letting its viewBox
scale it down proportionally to fit rather than overflowing. Also
excluded once scroll-zoomed, same reasoning as above. */
#diagram-section.fullscreen-mode .sankey-container:not(.sankey-zoomed) #sankey svg {
width: auto !important;
height: auto !important;
max-width: 100vw !important;
max-height: 100vh !important;
transform: none !important;
}
}
.toolbar-row {
display: flex;
flex-wrap: nowrap;
align-items: center;
gap: 1.5rem;
min-width: max-content;
padding: 0 1rem;
}
.toolbar-section {
display: flex;
align-items: center;
flex-shrink: 0;
min-height: 38px;
}
.toolbar-btn {
white-space: nowrap;
min-width: 100px;
}
.node rect {
fill-opacity: 0.9;
shape-rendering: crispEdges;
stroke: #000;
stroke-width: 1.5px;
cursor: move;
}
.node text {
pointer-events: none;
text-shadow: 0 1px 0 #fff;
}
/* ---------------------------------------------------------------------
Dark Mode (Layout tab, next to Scroll Zoom)
Vars + the dark-mode-canvas flag live on <html>/<body> rather than on
#diagramScrollPane or #sankey directly: in fullscreen, #diagram-section
(see .fullscreen-mode below) becomes its own position:fixed, full-
viewport box with a hardcoded white background — it's no longer
visually "inside" #diagramScrollPane at all, just still its DOM
descendant. A body-level class lets one flag reach every one of these
separately-backgrounded pieces (the scroll pane, the fullscreen
overlay, and its pinned paging header row) instead of just whichever
box happens to be visible outside fullscreen.
Label <text> elements are drawn with fill:inherit (see
createLabelText()/createCombinedLabelText() in sankeybuilder.js), so
setting --diagram-text-color on body is enough to recolor every label
via normal DOM inheritance — that still works fine even inside the
fixed-position fullscreen overlay, since CSS inheritance follows the
DOM tree, not layout/positioning. */
body {
--diagram-text-color: #000000;
--diagram-text-muted: #666666;
}
#sankey svg {
fill: var(--diagram-text-color);
}
/* Backstop: if the fixed .fullscreen-mode box ever falls short of the
true visible viewport (stale 100vh behind a mobile toolbar, an outer
page/iframe taller than the box, etc.), whatever's behind it is html/
body themselves — keeping those the same gradient as the diagram
canvas means the worst case is an on-brand dark sliver, never a flat
black one or a white one. background-attachment:fixed anchors the
gradient to the viewport rather than stretching/repeating across
html/body's full (possibly much taller than one screen) content
height. */
html.dark-mode-canvas,
body.dark-mode-canvas {
background: #05070f radial-gradient(ellipse at top, #101c34 0%, #0a1120 60%, #05070f 100%) !important;
background-attachment: fixed !important;
}
/* Dark Mode is a DIAGRAM CANVAS feature, not a whole-app theme — the
tab bar (Layout/Labels/Flow/Node/Data) and each tab's own horizontal
toolbar row of controls sit on top of body, so without this they'd
inherit body's new dark background too. Force them back to the
normal light UI regardless of Dark Mode. */
body.dark-mode-canvas .container.ui {
background: #fff !important;
}
body.dark-mode-canvas #diagramScrollPane,
body.dark-mode-canvas .fullscreen-mode {
background: #05070f radial-gradient(ellipse at top, #101c34 0%, #0a1120 60%, #05070f 100%) !important;
transition: background 0.25s ease;
}
/* Transparent (not their own flat color) in dark mode: #viewerPagingBar
is only actually painted white via .fullscreen-mode #viewerPagingBar
below when paging is enabled and visible — transparent here lets the
parent .fullscreen-mode gradient show straight through it instead of
a separate flat-colored bar creating a seam. */
body.dark-mode-canvas #viewerPagingBar {
background: transparent !important;
}
body.dark-mode-canvas .node text {
text-shadow: 0 0 6px currentColor, 0 1px 2px rgba(0, 0, 0, 0.9);
}
body.dark-mode-canvas .app-footer-toolbar,
body.dark-mode-canvas .fullscreen-btn {
background: rgba(10, 17, 32, 0.92) !important;
border-color: rgba(255, 255, 255, 0.15) !important;
}
body.dark-mode-canvas .footer-toolbar-btn {
color: var(--diagram-text-color, #39ff14) !important;
}
.link {
fill: none;
stroke-opacity: 0.3;
}
.link:hover {
stroke-opacity: 0.6;
}
/* Click-to-highlight (see highlightConnectedFlows in sankeybuilder.js):
everything not connected to the clicked node washes out to near-white so
the connected flows/nodes stand out clearly. */
.link.flow-dimmed {
stroke: #ffffff !important;
stroke-opacity: 0.45 !important;
}
.link.flow-highlighted {
stroke-opacity: 0.5 !important;
}
.node.node-dimmed rect {
fill: #ffffff !important;
stroke: #ffffff !important;
fill-opacity: 0.45 !important;
stroke-opacity: 0.2 !important;
}
.node.node-dimmed .node-label {
opacity: 0.3;
}
#sankey.diagram-highlighting .link {
marker-end: none !important;
}
.sankey-container {
margin: 0 auto;
padding-left: 0 !important;
width: 100%;
min-height: 400px; /* Changed from height to min-height */
height: auto; /* Allow dynamic height */
position: relative;
display: flex;
align-items: flex-start;
justify-content: center;
}
#sankey {
width: auto;
height: auto;
min-height: 400px; /* Ensure minimum height */
margin: auto; /* centers when there's room, collapses to 0 (top/left-aligned, fully scrollable) when content overflows */
overflow: hidden;
}
.app-footer-toolbar,
.fullscreen-btn {
position: fixed;
bottom: 14px;
left: 50%;
transform: translateX(-50%);
z-index: 10000;
display: flex;
align-items: center;
gap: 0.4rem;
background: rgba(255, 255, 255, 0.96);
border: 1px solid #dee2e6;
border-radius: 999px;
padding: 6px;
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
}
.footer-toolbar-btn {
display: flex;
align-items: center;
justify-content: center;
width: 40px;
height: 40px;
border: none;
border-radius: 50%;
background: transparent;
color: #0d6efd;
font-size: 1.05rem;
cursor: pointer;
transition: background 0.15s ease;
}
.footer-toolbar-btn:hover {
background: #e9ecef;
}
.footer-toolbar-btn:active {
background: #dbe4ff;
}
.flow-info {
position: absolute;
background: white;
border: 1px solid #ccc;
border-radius: 4px;
padding: 8px;
font-size: 12px;
pointer-events: none;
box-shadow: 2px 2px 6px rgba(0,0,0,0.1);
z-index: 10000;
}
.upload-area {
padding: 8px 20px;
text-align: center;
margin-bottom: 0;
}
.data-table-container {
max-height: 100px;
overflow: auto;
}
.table th {
position: sticky;
top: 0;
background-color: #f8f9fa;
z-index: 10;
}
.column-selector {
margin-bottom: 15px;
}
.card {
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
#diagram-section {
display: none;
}
/* Fullscreen mode */
.fullscreen-mode {
position: fixed !important;
top: 0 !important;
left: 0 !important;
right: 0 !important;
bottom: 0 !important;
width: 100% !important;
height: 100vh !important;
height: 100dvh !important; /* modern browsers: true visible viewport, not the stale 100vh some browsers keep behind a toolbar/URL bar */
background: white !important;
z-index: 9999 !important;
padding: 0 !important;
margin: 0 !important;
display: flex !important;
flex-direction: column !important;
}
#viewerPagingBar {
padding-top: 8px;
}
.fullscreen-mode #viewerPagingBar {
flex: 0 0 auto;
background: white;
}
/* .container{
overflow: auto !important;
} */
.fullscreen-mode .row {
padding-left: 0 !important;
margin: 0 !important;
width: 100% !important;
}
.col-12{ padding-left: 0 !important;}
.fullscreen-mode .col-12 {
padding: 0 !important;
max-width: 100% !important;
}
.fullscreen-mode .sankey-container {
flex: 1 1 auto;
min-height: 0; /* required for a flex child to be allowed to shrink and scroll internally instead of overflowing */
height: auto;
width: 100% !important;
margin: 0 !important;
padding: 0 !important;
box-sizing: border-box !important;
overflow: auto !important; /* Enable scrolling on the container */
display: grid !important;
place-items: center !important;
}
.fullscreen-mode .sankey-container:not(.sankey-zoomed) {
scrollbar-width: none; /* Firefox */
-ms-overflow-style: none; /* old Edge/IE */
}
.fullscreen-mode .sankey-container:not(.sankey-zoomed)::-webkit-scrollbar {
/* A visible scrollbar reserves width on one side only, which skews
centering asymmetrically — and whether Chromium actually shows one
at any given moment depends on whether the diagram happens to be
just barely taller than the viewport, so it isn't even consistent
between reloads, let alone between browsers/settings that differ in
overlay vs. classic scrollbar behavior. Hidden here since
wheel/touch/keyboard scrolling still works without it. Once scroll-
zoomed in (.sankey-zoomed), the scrollbar is shown again on purpose —
it's the visible/draggable cue that there's more to pan to. */
display: none;
width: 0;
height: 0;
}
.fullscreen-mode #sankey {
width: auto !important;
height: auto !important;
}
.fullscreen-mode .controls-section {
display: none;
}
.container {
max-width: 100% !important;
}
.modal{
z-index: 9999 !important
}
/* Diagrams div-table (My Diagrams modal) */
.diagrams-table {
display: flex;
flex-direction: column;
border: 1px solid #e9ecef;
border-radius: 8px;
overflow: hidden;
}
.diagrams-table-row {
display: flex;
align-items: center;
gap: 0.6rem;
padding: 0.5rem 0.75rem;
border-bottom: 1px solid #f0f0f0;
background: white;
transition: background 0.15s ease;
}
.diagrams-table-row:last-child {
border-bottom: none;
}
.diagrams-table-row:hover {
background: #f8f9fa;
}
.diagram-row-btn {
flex: 0 0 auto;
width: 32px;
height: 32px;
border: none;
border-radius: 6px;
background: transparent;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
transition: background 0.15s ease;
}
.diagram-row-btn.btn-edit {
color: #0d6efd;
}
.diagram-row-btn.btn-edit:hover {
background: #e7f1ff;
}
.diagram-row-btn.btn-share {
color: #1e7e34;
}
.diagram-row-btn.btn-share:hover {
background: #e7f6ec;
}
.diagram-row-btn.btn-delete {
color: #dc3545;
}
.diagram-row-btn.btn-delete:hover {
background: #fde2e2;
}
.diagram-row-badge {
flex: 0 0 auto;
display: inline-flex;
align-items: center;
gap: 0.3rem;
font-size: 0.65rem;
font-weight: 600;
padding: 0.2rem 0.5rem;
border-radius: 20px;
white-space: nowrap;
}
.diagram-row-badge.badge-linked {
background: #e7f6ec;
color: #1e7e34;
}
.diagram-row-badge.badge-data {
background: #e3f2fd;
color: #0d6efd;
}
.diagram-row-badge.badge-expired {
background: #fde2e2;
color: #dc3545;
}
.diagram-row-name {
flex: 1 1 auto;
min-width: 0;
border: 1px solid transparent;
border-radius: 6px;
padding: 0.35rem 0.5rem;
font-size: 0.85rem;
font-weight: 500;
color: #1e293b;
background: transparent;
}
.diagram-row-name:hover {
border-color: #dee2e6;
}
.diagram-row-name:focus {
outline: none;
border-color: #0d6efd;
background: white;
box-shadow: 0 0 0 2px rgba(13, 110, 253, 0.15);
}
.diagram-row-name.just-saved {
background: #e7f6ec;
border-color: #1e7e34;
}
@media (max-width: 480px) {
.diagram-row-badge span.badge-text {
display: none;
}
}
/* Loading state */
#diagramsLoading {
min-height: 200px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
/* The "Load" control on the Data tab is a <label> styled as a button (so
it can trigger a hidden file input), which means the native `disabled`
attribute on a <button> doesn't apply to it — this covers that case when
a linked/API diagram is open, where Save/Load don't apply. */
.loadConfig.disabled-label {
pointer-events: none;
opacity: 0.5;
}
/* Insights modal */
.ai-insight-card {
border: 1px solid #e9ecef;
border-left: 4px solid #cbd5e1;
border-radius: 8px;
padding: 0.85rem 1rem;
margin-bottom: 0.6rem;
background: #fff;
}
.ai-insight-card:last-child {
margin-bottom: 0;
}
.ai-insight-card.ai-sev-red { border-left-color: #dc2626; }
.ai-insight-card.ai-sev-yellow { border-left-color: #d97706; }
.ai-insight-card.ai-sev-green { border-left-color: #94a3b8; }
.ai-insight-header {
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
margin-bottom: 0.4rem;
}
.ai-insight-left {
display: flex;
align-items: center;
gap: 7px;
min-width: 0;
}
.ai-insight-number {
flex: none;
width: 20px;
height: 20px;
border-radius: 50%;
background: #2563eb;
color: #fff;
display: flex;
align-items: center;
justify-content: center;
font-size: 0.7rem;
font-weight: 800;
line-height: 1;
}
.ai-insight-category {
font-size: 0.78rem;
font-weight: 700;
letter-spacing: 0.02em;
color: #212529;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.ai-severity-pill {
flex: none;
display: inline-flex;
align-items: center;
gap: 4px;
height: 20px;
font-size: 0.65rem;
font-weight: 800;
letter-spacing: 0.03em;
border-radius: 20px;
padding: 0 0.55rem;
white-space: nowrap;
}
.ai-sevpill-red { background: #fee2e2; color: #b91c1c; }
.ai-sevpill-yellow { background: #fef3c7; color: #92400e; }
.ai-sevpill-green { background: #e5e7eb; color: #111827; }
.ai-insight-title {
font-weight: 700;
font-size: 0.95rem;
margin-bottom: 0.2rem;
}
.ai-insight-text {
font-size: 0.88rem;
color: #333;
line-height: 1.4;
}
.ai-hypothesis {
display: flex;
align-items: flex-start;
gap: 6px;
margin-top: 0.6rem;
background: #fffbeb;
border: 1px solid #fde68a;
border-radius: 6px;
padding: 0.5rem 0.75rem;
}
.ai-hypothesis i {
color: #d97706;
font-size: 0.85rem;
margin-top: 2px;
flex: none;
}
.ai-hypothesis > div {
display: flex;
flex-direction: column;
gap: 0.3rem;
min-width: 0;
}
.ai-hypothesis span {
font-size: 0.85rem;
line-height: 1.45;
color: #78350f;
}
.ai-hypothesis strong {
color: #78350f;
}
.ai-confidence {
display: inline-block;
align-self: flex-start;
font-size: 0.65rem;
font-weight: 700;
letter-spacing: 0.02em;
text-transform: uppercase;
padding: 0.15rem 0.5rem;
border-radius: 20px;
}
.ai-conf-high { background: #d1fae5; color: #065f46; }
.ai-conf-medium { background: #fef3c7; color: #92400e; }
.ai-conf-low { background: #fee2e2; color: #b91c1c; }
/* Priority Matrix */
.ai-priority-row {
display: flex;
align-items: flex-start;
gap: 10px;
border: 1px solid #e9ecef;
border-left: 4px solid #cbd5e1;
border-radius: 8px;
padding: 0.75rem 0.9rem;
margin-bottom: 0.6rem;
background: #fff;
}
.ai-priority-row:last-child { margin-bottom: 0; }
.ai-priority-row.ai-ptier-high { border-left-color: #ea580c; }
.ai-priority-row.ai-ptier-medium { border-left-color: #d97706; }
.ai-priority-row.ai-ptier-low { border-left-color: #94a3b8; }
.ai-priority-row.ai-ptier-investigate { border-left-color: #4f46e5; }
.ai-priority-rank {
flex: none;
width: 20px;
height: 20px;
border-radius: 50%;
background: #212529;
color: #fff;
display: flex;
align-items: center;
justify-content: center;
font-size: 0.7rem;
font-weight: 800;
margin-top: 1px;
}
.ai-priority-body { flex: 1; min-width: 0; }
.ai-priority-top {
display: flex;
align-items: center;
gap: 7px;
margin-bottom: 0.3rem;
flex-wrap: wrap;
}
.ai-priority-tier-badge {
flex: none;
font-size: 0.62rem;
font-weight: 800;
letter-spacing: 0.04em;
padding: 0.1rem 0.5rem;
border-radius: 20px;
}
.ai-ptierbadge-high { background: #ffedd5; color: #9a3412; }
.ai-ptierbadge-medium { background: #fef3c7; color: #92400e; }
.ai-ptierbadge-low { background: #e5e7eb; color: #374151; }
.ai-ptierbadge-investigate { background: #e0e7ff; color: #3730a3; }
.ai-priority-title {
font-size: 0.88rem;
font-weight: 700;
color: #212529;
}
.ai-priority-meta {
display: flex;
gap: 0.9rem;
font-size: 0.75rem;
color: #6c757d;
margin-bottom: 0.3rem;
}
.ai-priority-action {
font-size: 0.85rem;
line-height: 1.45;
color: #333;
}
.ai-priority-action strong {
color: #212529;
}
.ai-priority-riskscore {
font-size: 0.75rem;
font-weight: 600;
color: #475569;
background: #f1f5f9;
display: inline-block;
padding: 0.15rem 0.5rem;
border-radius: 6px;
margin-bottom: 0.4rem;
font-variant-numeric: tabular-nums;
}
.ai-priority-riskscore strong {
color: #0f172a;
}
.ai-priority-riskscore.ai-riskscore-na {
color: #94a3b8;
background: #f8fafc;
font-weight: 500;
font-style: italic;
}
.ai-priority-normscore {
color: #94a3b8;
font-weight: 500;
}
.ai-quicksummary {
border: 1px solid #cbd5e1;
border-radius: 10px;
background: #f8fafc;
padding: 0.85rem 1rem;
margin-bottom: 1rem;
}
.ai-quicksummary-title {
font-size: 0.72rem;