-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathcustom.css
More file actions
1241 lines (1092 loc) · 31.8 KB
/
custom.css
File metadata and controls
1241 lines (1092 loc) · 31.8 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
:root {
/* Core surfaces */
--uplt-color-panel-bg: #ffffff; /* page bg (light) */
--uplt-color-sidebar-bg: #f4f4f4; /* TOC + notebook cell bg (light) */
--uplt-color-card-bg: #f4f4f4; /* used by .card-img-top background */
--uplt-color-white: #ffffff;
/* Borders & shadows */
--uplt-color-border-muted: #e1e4e5;
--uplt-color-button-border: #c5c5c5;
--uplt-color-shadow: rgba(0, 0, 0, 0.1);
/* Text */
--uplt-color-text-main: #404040;
--uplt-color-text-strong: #333333;
--uplt-color-text-secondary: #555555;
--uplt-color-text-muted: #606060;
/* Accent */
--uplt-color-accent: #0f766e;
--uplt-color-accent-hover: rgba(15, 118, 110, 0.1);
--uplt-color-accent-active: rgba(15, 118, 110, 0.15);
--uplt-color-accent-grad-start: rgba(15, 118, 110, 0.1);
--uplt-color-accent-grad-end: rgba(15, 118, 110, 0.02);
--uplt-color-accent-shadow-strong: rgba(15, 118, 110, 0.2);
--uplt-color-accent-shadow-soft: rgba(15, 118, 110, 0.1);
--uplt-color-plot-panel-bg: #f2f4f6;
--uplt-color-plot-panel-border: #d9dde2;
--uplt-color-gallery-plot-bg: #ffffff;
--uplt-color-gallery-plot-border: #d9dde2;
--uplt-color-gallery-plot-shadow: rgba(15, 23, 42, 0.08);
/* Scrollbar */
--uplt-color-scrollbar-track: #f1f1f1;
--uplt-color-scrollbar-thumb: #cdcdcd;
--uplt-color-scrollbar-thumb-hover: #9e9e9e;
--uplt-color-code-bg: var(--uplt-color-sidebar-bg); /* same as page */
--uplt-color-code-fg: #6a6a6a; /* gray code text (light) */
--uplt-color-inset-highlight: rgba(255, 255, 255, 0.5);
--code-block-background: var(--uplt-color-code-bg);
--sy-c-link: var(--uplt-color-accent);
--sy-c-link-hover: #0b5f59;
--uplt-color-toc-bg: #e9e9e9;
}
.sy-main .yue a,
.globaltoc a,
.localtoc a,
.sy-breadcrumbs a {
color: var(--sy-c-link);
}
.sy-main .yue a:hover,
.globaltoc a:hover,
.localtoc a:hover,
.sy-breadcrumbs a:hover {
color: var(--sy-c-link-hover);
}
.sy-main .yue a:not(.headerlink) {
border-bottom-color: transparent !important;
text-decoration: none !important;
}
.sy-main .yue a:not(.headerlink):hover {
border-bottom-color: transparent !important;
text-decoration: underline !important;
text-decoration-color: var(--sy-c-link-hover);
text-decoration-thickness: 0.08em;
text-underline-offset: 0.14em;
}
.sy-head .sy-head-links {
justify-content: flex-start !important;
column-gap: 1.8rem !important;
padding-left: 1.25rem !important;
padding-right: 1.25rem !important;
}
/* ── iOS Safari compositing fix ─────────────────────────────────────────────
Shibuya's .sy-head-blur uses -webkit-backdrop-filter: blur(12px), which
creates a GPU compositing layer. On iOS Safari this disrupts rendering of
two distinct things in sibling/adjacent sticky elements:
1. -webkit-background-clip: text → gradient text goes invisible
Fix: isolation: isolate on .sy-head-brand (creates its own stacking
context, shielding the gradient-clip composite from the blur layer).
2. Plain text rendering in .sy-breadcrumbs → link text goes invisible
while CSS-mask icons in the same bar remain visible (icons use
background-color + mask, a different GPU path than text).
Fix: transform: translateZ(0) on .sy-breadcrumbs-inner forces it into
its own compositing layer so text renders independently of the header.
────────────────────────────────────────────────────────────────────────── */
.sy-head .sy-head-brand {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.2rem 0.04rem 0.2rem;
line-height: 1.25;
isolation: isolate;
transform: translateZ(0);
}
.sy-breadcrumbs-inner {
transform: translateZ(0);
}
.sy-head .sy-head-brand strong {
font-size: 0.74rem;
font-weight: 700;
letter-spacing: 0.065em;
text-transform: uppercase;
line-height: 1.25;
color: #138a73;
transform: translateZ(0);
background-image: linear-gradient(
90deg,
#0f6d5f 0%,
#11806b 12%,
#139378 24%,
#15a685 36%,
#17b793 48%,
#19a988 60%,
#1a9c7d 72%,
#1c8f73 84%,
#1e8268 100%
);
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
}
@media (min-width: 768px) {
.sy-head .sy-head-links > ul {
display: flex !important;
align-items: center;
justify-content: flex-start;
column-gap: 2.8rem !important;
margin: 0 !important;
padding: 0 !important;
text-align: left;
}
.sy-head .sy-head-links > ul > li.link {
margin: 0 !important;
padding: 0 !important;
}
}
.sy-head .sy-head-links a {
border: 0 !important;
border-bottom: 2px solid transparent !important;
border-radius: 0;
padding: 0.2rem 0.04rem 0.2rem;
line-height: 1.25;
font-size: 0.74rem;
font-weight: 600;
letter-spacing: 0.065em;
text-transform: uppercase;
color: var(--uplt-color-text-main);
background: transparent !important;
text-decoration: none !important;
transition:
border-bottom-color 0.2s ease,
color 0.2s ease,
opacity 0.2s ease;
}
.sy-head .sy-head-links a:hover {
border-bottom-color: rgba(15, 118, 110, 0.35) !important;
color: var(--uplt-color-accent);
opacity: 1;
}
.sy-head .sy-head-links a[href="#"],
.sy-head .sy-head-links a[aria-current="page"] {
color: var(--uplt-color-accent) !important;
border-bottom-color: var(--uplt-color-accent) !important;
opacity: 1;
}
@media (min-width: 768px) {
.sy-head,
.sy-breadcrumbs,
.sy-lside {
transition:
opacity 0.24s ease,
transform 0.24s ease;
will-change: opacity, transform;
}
html.uplt-chrome-hidden .sy-head,
html.uplt-chrome-hidden .sy-breadcrumbs {
opacity: 0;
transform: translateY(-14px);
pointer-events: none;
}
html.uplt-chrome-hidden .sy-lside {
opacity: 0;
transform: translateX(-14px);
pointer-events: none;
}
}
/* Content heading hierarchy */
.sy-main .yue h1 {
font-size: clamp(2rem, 2.6vw, 2.5rem);
line-height: 1.12;
font-weight: 740;
letter-spacing: -0.018em;
margin: 0 0 1.1rem;
padding-bottom: 0.38rem;
display: grid;
grid-template-columns: auto 1fr;
align-items: center;
column-gap: 0.7rem;
row-gap: 0.25rem;
color: var(--sy-c-heading);
}
.sy-main .yue h1::before {
content: "";
grid-row: 1;
grid-column: 1;
width: 0.5rem;
height: 1.05em;
border-radius: 999px;
background: linear-gradient(180deg, var(--uplt-color-accent) 0%, #0a5f58 100%);
box-shadow: 0 0 0 1px var(--uplt-color-accent-shadow-soft);
}
.sy-main .yue h1::after {
content: "";
display: block;
grid-row: 2;
grid-column: 2;
width: clamp(2.8rem, 8vw, 4.2rem);
height: 0.2rem;
border-radius: 999px;
background: linear-gradient(90deg, var(--uplt-color-accent) 0%, #0a5f58 100%);
}
.sy-main .yue h2 {
font-size: clamp(1.35rem, 1.8vw, 1.65rem);
line-height: 1.25;
font-weight: 650;
margin: 2.2rem 0 0.8rem;
padding-bottom: 0.35rem;
border-bottom: 1px solid var(--sy-c-divider);
box-shadow: inset 0 -2px 0 0 var(--uplt-color-accent-hover);
color: var(--sy-c-heading);
}
.sy-main .yue h3 {
font-size: 1.08rem;
line-height: 1.3;
font-weight: 620;
margin: 1.45rem 0 0.5rem;
padding-left: 0.55rem;
border-left: 3px solid var(--uplt-color-accent);
color: var(--sy-c-heading);
}
.sy-main .yue h4,
.sy-main .yue h5,
.sy-main .yue h6 {
font-size: 0.98rem;
font-weight: 600;
margin: 1.1rem 0 0.35rem;
color: var(--sy-c-text);
}
html.dark .sy-head .sy-head-links a,
html.dark-theme .sy-head .sy-head-links a,
[data-color-mode="dark"] .sy-head .sy-head-links a {
color: #dbe6e5;
opacity: 0.96;
}
html.dark .sy-head .sy-head-brand strong,
html.dark-theme .sy-head .sy-head-brand strong,
[data-color-mode="dark"] .sy-head .sy-head-brand strong {
color: #6ee0c8;
background-image: linear-gradient(
90deg,
#47cdb2 0%,
#53d6bc 12%,
#5fdec6 24%,
#6be6d0 36%,
#77edd9 48%,
#6be6d0 60%,
#5fdec6 72%,
#53d6bc 84%,
#47cdb2 100%
);
}
html.dark .sy-head .sy-head-links a:hover,
html.dark-theme .sy-head .sy-head-links a:hover,
[data-color-mode="dark"] .sy-head .sy-head-links a:hover {
color: #66d0c6;
border-bottom-color: rgba(102, 208, 198, 0.55) !important;
}
html.dark .sy-head .sy-head-links a[href="#"],
html.dark-theme .sy-head .sy-head-links a[href="#"],
[data-color-mode="dark"] .sy-head .sy-head-links a[href="#"],
html.dark .sy-head .sy-head-links a[aria-current="page"],
html.dark-theme .sy-head .sy-head-links a[aria-current="page"],
[data-color-mode="dark"] .sy-head .sy-head-links a[aria-current="page"] {
color: #8be0d9 !important;
border-bottom-color: #8be0d9 !important;
}
@media screen and (max-width: 1200px) {
.sy-head .sy-head-links {
column-gap: 3.8rem !important;
padding-left: 1rem !important;
padding-right: 1rem !important;
}
}
.yue :not(pre) > code,
.yue code.docutils.literal.notranslate,
.yue code.docutils.literal.notranslate .pre {
color: var(--sy-c-link);
background-color: var(--uplt-color-accent-hover);
border: 1px solid var(--uplt-color-border-muted);
border-radius: 0.2rem;
padding: 0.06rem 0.28rem;
}
html.dark,
html.dark-theme,
[data-color-mode="dark"] {
--uplt-color-panel-bg: #181b1e;
--uplt-color-sidebar-bg: #20252a;
--uplt-color-card-bg: #20252a;
--uplt-color-border-muted: #333b43;
--uplt-color-button-border: #45515d;
--uplt-color-shadow: rgba(0, 0, 0, 0.45);
--uplt-color-text-main: #d8dee5;
--uplt-color-text-strong: #f2f5f7;
--uplt-color-text-secondary: #b7c0c8;
--uplt-color-text-muted: #97a3ad;
--uplt-color-accent: #1aa89a;
--uplt-color-accent-hover: rgba(26, 168, 154, 0.14);
--uplt-color-accent-active: rgba(26, 168, 154, 0.22);
--uplt-color-accent-grad-start: rgba(26, 168, 154, 0.16);
--uplt-color-accent-grad-end: rgba(26, 168, 154, 0.04);
--uplt-color-accent-shadow-strong: rgba(26, 168, 154, 0.26);
--uplt-color-accent-shadow-soft: rgba(26, 168, 154, 0.14);
--uplt-color-plot-panel-bg: #1b2024;
--uplt-color-plot-panel-border: #313940;
--uplt-color-gallery-plot-bg: #ffffff;
--uplt-color-gallery-plot-border: #d5dbe3;
--uplt-color-gallery-plot-shadow: rgba(15, 23, 42, 0.12);
--sy-c-link: #58d5c9;
--sy-c-link-hover: #84e8df;
--uplt-color-code-bg: #141414;
--uplt-color-inset-highlight: rgba(255, 255, 255, 0.04);
--code-block-background: #141414;
--syntax-dark-background: #141414;
--syntax-dark-highlight: #2a2f2f;
--uplt-color-toc-bg: #171717;
}
@media (prefers-color-scheme: dark) {
html:not(.light):not(.light-theme):not([data-color-mode="light"]) {
--uplt-color-panel-bg: #181b1e;
--uplt-color-sidebar-bg: #20252a;
--uplt-color-card-bg: #20252a;
--uplt-color-border-muted: #333b43;
--uplt-color-button-border: #45515d;
--uplt-color-shadow: rgba(0, 0, 0, 0.45);
--uplt-color-text-main: #d8dee5;
--uplt-color-text-strong: #f2f5f7;
--uplt-color-text-secondary: #b7c0c8;
--uplt-color-text-muted: #97a3ad;
--uplt-color-code-bg: #141414;
--uplt-color-inset-highlight: rgba(255, 255, 255, 0.04);
--code-block-background: #141414;
--syntax-dark-background: #141414;
--syntax-dark-highlight: #2a2f2f;
--uplt-color-toc-bg: #171717;
}
}
.grid-item-card .card-img-top {
height: 100%;
object-fit: cover;
width: 100%;
background-color: var(--uplt-color-card-bg);
}
/* Make all cards with this class use flexbox for vertical layout */
.card-with-bottom-text {
display: flex !important;
flex-direction: column !important;
height: 100% !important;
border: 1px solid var(--uplt-color-border-muted) !important;
border-radius: 0.8rem !important;
background: linear-gradient(
180deg,
var(--uplt-color-white) 0%,
var(--uplt-color-sidebar-bg) 100%
) !important;
box-shadow: 0 4px 14px var(--uplt-color-shadow);
transition:
transform 0.18s ease,
box-shadow 0.18s ease,
border-color 0.18s ease;
}
.card-with-bottom-text:hover {
transform: translateY(-2px);
border-color: var(--uplt-color-accent) !important;
box-shadow: 0 10px 22px var(--uplt-color-accent-shadow-soft);
}
/* Style the card content areas */
.card-with-bottom-text .sd-card-body {
display: flex !important;
flex-direction: column !important;
flex-grow: 1 !important;
gap: 0.25rem;
padding: 0.85rem 1rem 1rem !important;
}
.card-with-bottom-text .sd-card-header {
background: linear-gradient(
135deg,
var(--uplt-color-accent) 0%,
#0a5f58 100%
) !important;
color: #ffffff !important;
border-bottom: 0 !important;
border-top-left-radius: 0.8rem !important;
border-top-right-radius: 0.8rem !important;
padding: 0.72rem 1rem !important;
}
.card-with-bottom-text .sd-card-header .sd-card-text,
.card-with-bottom-text .sd-card-header strong {
color: #ffffff !important;
}
.card-with-bottom-text .sd-card-title {
margin-bottom: 0.35rem;
font-weight: 650;
letter-spacing: -0.01em;
}
/* Make images not grow or shrink */
.card-with-bottom-text img {
flex-shrink: 0 !important;
margin-bottom: 0.5rem !important;
border-radius: 0.45rem;
border: 1px solid var(--uplt-color-border-muted);
background: var(--uplt-color-card-bg);
}
/* Push the last paragraph to the bottom */
.card-with-bottom-text .sd-card-body > p:last-child {
margin-top: auto !important;
padding-top: 0.5rem !important;
text-align: center !important;
}
html.dark .card-with-bottom-text,
html.dark-theme .card-with-bottom-text,
[data-color-mode="dark"] .card-with-bottom-text {
background: linear-gradient(180deg, #252525 0%, #1f1f1f 100%) !important;
box-shadow: 0 7px 20px rgba(0, 0, 0, 0.3);
}
html.dark .card-with-bottom-text .sd-card-header,
html.dark-theme .card-with-bottom-text .sd-card-header,
[data-color-mode="dark"] .card-with-bottom-text .sd-card-header {
background: linear-gradient(135deg, #178f84 0%, #0f6f67 100%) !important;
}
.img-container img {
object-fit: cover;
width: 100%;
height: 100%;
}
.right-toc-header {
display: flex;
justify-content: space-between;
align-items: center;
padding: 12px 15px;
border-bottom: 1px solid var(--uplt-color-border-muted);
}
.right-toc-title {
font-weight: 600;
font-size: 1.1em;
color: var(--uplt-color-accent);
}
.right-toc-buttons {
display: flex;
align-items: center;
}
.right-toc-toggle-btn {
background: none;
border: none;
color: var(--uplt-color-accent);
font-size: 16px;
cursor: pointer;
width: 24px;
height: 24px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 3px;
padding: 0;
transition: background-color 0.2s;
}
.right-toc-toggle-btn:hover {
background-color: var(--uplt-color-accent-hover);
}
.right-toc-content {
padding: 15px 15px 15px 20px;
overflow-y: auto;
max-height: calc(100vh - 200px);
}
.right-toc-list {
list-style-type: none;
padding-left: 0;
margin: 0;
}
.right-toc-link {
display: block;
padding: 5px 0;
text-decoration: none;
color: var(--uplt-color-text-main);
border-radius: 4px;
transition: all 0.2s ease;
margin-bottom: 3px;
}
.right-toc-link:hover {
background-color: var(--uplt-color-accent-hover);
padding-left: 5px;
color: var(--uplt-color-accent);
}
.right-toc-level-h1 {
font-weight: 600;
font-size: 1em;
}
.right-toc-level-h2 {
padding-left: 1.2em;
font-size: 0.95em;
}
.right-toc-level-h3 {
padding-left: 2.4em;
font-size: 0.9em;
color: var(--uplt-color-text-muted);
}
.right-toc-subtoggle {
background: none;
border: none;
color: var(--uplt-color-accent);
cursor: pointer;
font-size: 0.9em;
margin-right: 0.3em;
padding: 0;
}
.right-toc-sublist {
list-style-type: none;
margin: 0.2em 0 0.4em 0;
padding-left: 1.2em;
}
/* Active TOC item highlighting */
.right-toc-link.active {
background-color: var(--uplt-color-accent-active);
color: var(--uplt-color-accent);
font-weight: 500;
padding-left: 5px;
}
/* Collapsed state */
.right-toc-collapsed {
width: auto;
border-left-width: 0;
}
.right-toc-collapsed .right-toc-header {
border-bottom: none;
padding: 8px 12px;
}
/* Scrollbar styling */
.right-toc-content::-webkit-scrollbar {
width: 5px;
}
.right-toc-content::-webkit-scrollbar-track {
background: var(--uplt-color-scrollbar-track);
border-radius: 10px;
}
.right-toc-content::-webkit-scrollbar-thumb {
background: var(--uplt-color-scrollbar-thumb);
border-radius: 10px;
}
.right-toc-content::-webkit-scrollbar-thumb:hover {
background: var(--uplt-color-scrollbar-thumb-hover);
}
.toc-wrapper {
position: relative;
display: flex;
max-width: 1100px; /* match .rst-content if needed */
margin: 0 auto;
gap: 20px;
}
.rst-content {
flex: 1;
}
.right-toc {
position: fixed;
top: 90px;
width: 280px;
left: 1125px;
font-size: 0.9em;
background-color: var(--uplt-color-panel-bg);
z-index: 100;
border-radius: 6px;
box-shadow: 0 4px 10px var(--uplt-color-shadow);
border-left: 3px solid var(--uplt-color-accent);
transition: all 0.3s ease;
max-height: calc(100vh - 150px);
}
.gallery-filter-controls {
margin: 1rem 0 2rem;
padding: 1rem 1.2rem 1.25rem;
border-radius: 18px;
position: relative;
overflow: hidden;
background: var(--uplt-color-panel-bg);
border: 1px solid var(--uplt-color-border-muted);
box-shadow:
0 14px 34px var(--uplt-color-shadow),
0 2px 8px var(--uplt-color-accent-shadow-soft);
}
.gallery-filter-controls::before {
content: "";
position: absolute;
inset: 0 0 auto 0;
height: 4px;
background: linear-gradient(
90deg,
var(--uplt-color-accent),
#0a5f58
);
}
.gallery-filter-bar {
display: flex;
flex-wrap: wrap;
gap: 0.5rem;
margin-bottom: 1rem;
padding: 0.9rem;
border-radius: 14px;
background: var(--uplt-color-sidebar-bg);
border: 1px solid var(--uplt-color-border-muted);
box-shadow: inset 0 1px 0 var(--uplt-color-inset-highlight);
}
.gallery-filter-button {
border: 1px solid var(--uplt-color-button-border);
background-color: var(--uplt-color-panel-bg);
color: var(--uplt-color-text-strong);
padding: 0.35rem 0.85rem;
border-radius: 999px;
font-size: 0.9em;
font-weight: 600;
cursor: pointer;
box-shadow: 0 1px 3px var(--uplt-color-shadow);
transition:
background-color 0.2s ease,
color 0.2s ease,
border-color 0.2s ease,
transform 0.2s ease,
box-shadow 0.2s ease;
}
.gallery-filter-button:hover {
transform: translateY(-1px);
border-color: var(--uplt-color-accent);
box-shadow: 0 6px 14px var(--uplt-color-accent-shadow-soft);
}
.gallery-filter-button.is-active {
background-color: var(--uplt-color-accent);
border-color: var(--uplt-color-accent);
color: var(--uplt-color-white);
box-shadow: 0 8px 18px var(--uplt-color-accent-shadow-strong);
}
.gallery-filter-controls .gallery-unified {
position: relative;
z-index: 1;
}
.sy-main .yue .sphx-glr-thumbnails .sphx-glr-thumbcontainer > img {
display: block;
width: 100%;
box-sizing: border-box;
padding: 0.9rem 0.9rem 0.55rem;
background: var(--uplt-color-gallery-plot-bg);
border-bottom: 1px solid var(--uplt-color-gallery-plot-border);
box-shadow: inset 0 0 0 1px var(--uplt-color-gallery-plot-shadow);
}
.gallery-filter-controls .gallery-unified .sphx-glr-thumbcontainer {
background: var(--uplt-color-panel-bg);
border: 1px solid var(--uplt-color-border-muted);
border-radius: 18px;
box-shadow: 0 10px 24px var(--uplt-color-shadow);
overflow: hidden;
transition:
transform 0.2s ease,
box-shadow 0.2s ease,
border-color 0.2s ease;
}
.gallery-filter-controls .gallery-unified .sphx-glr-thumbcontainer:hover {
transform: translateY(-3px);
border-color: var(--uplt-color-accent);
box-shadow: 0 16px 30px var(--uplt-color-accent-shadow-soft);
}
.gallery-filter-controls .gallery-unified .sphx-glr-thumbnail-title {
padding: 0.2rem 0.95rem 1rem;
color: var(--uplt-color-text-strong);
font-weight: 600;
}
.gallery-section-hidden {
display: none;
}
body.gallery-filter-active .sphx-glr-thumbnails:not(.gallery-unified) {
display: none;
}
body.gallery-filter-active .gallery-section-header,
body.gallery-filter-active .gallery-section-description {
display: none;
}
body.whats_new .wy-menu-vertical li.toctree-l1.current > ul {
display: none;
}
body.whats_new .wy-menu-vertical li.toctree-l2,
body.whats_new .wy-menu-vertical li.toctree-l3,
body.whats_new .wy-menu-vertical li.toctree-l4 {
display: none;
}
body.whats_new .wy-menu-vertical a[href^="#"] {
display: none;
}
body.whats_new .wy-menu-vertical li:has(> a[href^="#"]) {
display: none;
}
/* Hide gallery subsections from left TOC */
body.wy-body-for-nav
.wy-menu-vertical
.wy-menu-vertical-2
a:is(
[href="#layouts"],
[href="#legends-and-colorbars"],
[href="#geoaxes"],
[href="#plot-types"],
[href="#colors-and-cycles"]
),
body.wy-body-for-nav
.wy-menu-vertical
.wy-menu-vertical-2
a:is(
[href="#layouts"],
[href="#legends-and-colorbars"],
[href="#geoaxes"],
[href="#plot-types"],
[href="#colors-and-cycles"]
)
+ ul,
body.wy-body-for-nav
.wy-menu-vertical
.wy-menu-vertical-2
li[class*="toctree-l1"]:has(
:is(
a[href="#layouts"],
a[href="#legends-and-colorbars"],
a[href="#geoaxes"],
a[href="#plot-types"],
a[href="#colors-and-cycles"]
)
) {
display: none !important;
}
/* Hide the section containers themselves */
.gallery-section {
margin: 1.5em 0;
}
:is(
section#layouts,
section#legends-and-colorbars,
section#geoaxes,
section#plot-types,
section#colors-and-cycles
)
> :is(h1, p) {
display: none;
}
/* Style for gallery section headers */
.gallery-section-header {
font-size: 1.5em;
font-weight: bold;
display: block;
margin: 1.5em 0 0.5em 0;
border-bottom: 2px solid var(--uplt-color-accent);
padding-bottom: 0.3em;
color: var(--uplt-color-accent);
}
.gallery-section-description {
margin: 0 0 1em 0;
color: var(--uplt-color-text-secondary);
}
/* Gallery example pages: collapsible source code */
.yue details.uplt-code-details {
margin-top: 0.9rem;
border: 1px solid var(--uplt-color-border-muted);
border-radius: 0.35rem;
background: var(--uplt-color-panel-bg);
}
.yue details.uplt-code-details > summary.uplt-code-summary {
list-style: none;
cursor: pointer;
user-select: none;
padding: 0.45rem 0.7rem;
font-size: 0.8rem;
font-weight: 600;
letter-spacing: 0.03em;
color: var(--sy-c-link);
}
.yue details.uplt-code-details > summary.uplt-code-summary::-webkit-details-marker {
display: none;
}
.yue details.uplt-code-details[open] > summary.uplt-code-summary {
border-bottom: 1px solid var(--uplt-color-border-muted);
}
.yue details.uplt-code-details > .highlight-Python {
margin: 0;
border: 0;
border-radius: 0 0 0.35rem 0.35rem;
}
.yue details.uplt-code-details > .nbinput.docutils.container {
margin: 0;
border: 0;
border-radius: 0 0 0.35rem 0.35rem;
}
.yue details.uplt-code-details > .nbinput.docutils.container div.input_area {
border-radius: 0 0 0.35rem 0.35rem;
border-top: 0;
}
/* Responsive adjustments */
@media screen and (max-width: 1200px) {
.right-toc {
width: 230px;
}
}
@media screen and (max-width: 992px) {
.right-toc {
display: none; /* Hide on smaller screens */
}
}
.output_area.docutils.container {
text-align: center; /* Centers inline or inline-block children horizontally */
}
/* Optional: Ensure image respects container boundaries */
.output_area.docutils.container img {
width: 100%;
height: auto;
display: block;
}
/* Shibuya: unify sidebar and notebook cell backgrounds */
.sy-lside,
.sy-lside-inner,
.sy-rside,
.sy-rside-inner,
.sy-scrollbar {
background-color: var(--uplt-color-toc-bg);
}
.yue div.nbinput.container > div.input_area,
.yue .highlight,
.yue .highlight pre {
background-color: var(--code-block-background) !important;
}
.yue div.nboutput.container {
display: block !important;
}
.yue div.nboutput.container > div.prompt {
display: none !important;
}
.yue div.nboutput.container > div.output_area {
background-color: var(--uplt-color-plot-panel-bg) !important;
border: 1px solid var(--uplt-color-plot-panel-border);
border-radius: 0.45rem;
padding: 0.4rem;
width: 100%;
max-width: 100%;
margin: 0.25rem 0 !important;
overflow: visible;
}
.yue div.nboutput.container > div.output_area > * {
margin-left: auto;
margin-right: auto;
}
/* Shibuya right TOC: collapse sub-H1 headings under each H1 section */
.sy-rside .localtoc {
margin-left: 0.55rem;
border: 1px solid var(--uplt-color-border-muted);
border-radius: 0.5rem;
padding: 0.7rem 0.75rem;
background: var(--uplt-color-panel-bg);
box-shadow: 0 1px 6px var(--uplt-color-shadow);
}
.sy-rside .sy-rside-inner > div:empty {
display: none;
}
.sy-rside .localtoc > h3 {
color: var(--sy-c-light);
font-family: var(--sy-f-heading);
font-size: 0.86rem;
font-weight: 500;
letter-spacing: 0.4px;
text-transform: uppercase;
margin: 0 0 0.5rem 0;
padding: 0 0 0.45rem 0;
border-bottom: 1px solid var(--sy-c-divider);
}
.sy-rside .localtoc > .uplt-toc-head {
display: flex;
align-items: center;
justify-content: space-between;
gap: 0.45rem;
margin: 0 0 0.5rem 0;