@krate/simple-docs-theme 0.0.0-stage → 0.5.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/theme.css ADDED
@@ -0,0 +1,1253 @@
1
+ /*
2
+ * Simple docs theme. Prose is set in a serif at a book measure; the chrome
3
+ * (navigation, labels, tables) is set in the UI sans. Colours come from
4
+ * light-dark(), so the theme switch only has to change color-scheme.
5
+ */
6
+ .simple-page {
7
+ color-scheme: light dark;
8
+ --simple-accent: light-dark(#0f766e, #5cc4b5);
9
+ --simple-accent-strong: light-dark(#115e59, #8fdccf);
10
+ --simple-bg: light-dark(#fdfcfa, #151412);
11
+ --simple-bg-soft: light-dark(#f4f2ee, #1f1e1b);
12
+ --simple-bg-raised: light-dark(#ffffff, #1f1e1b);
13
+ --simple-fg: light-dark(#1c1b19, #ece9e2);
14
+ --simple-fg-soft: light-dark(#43403b, #cfcbc2);
15
+ --simple-muted: light-dark(#66615a, #a09a8f);
16
+ --simple-border: light-dark(#e3dfd7, #34322e);
17
+ --simple-code-bg: light-dark(#f4f2ee, #0e0d0c);
18
+ --simple-code-fg: light-dark(#1c1b19, #ece9e2);
19
+ --simple-shadow: 0 12px 32px -16px light-dark(rgba(28, 27, 25, 0.3), rgba(0, 0, 0, 0.7));
20
+ --simple-header-height: 52px;
21
+ --simple-sidebar-width: 15rem;
22
+ --simple-toc-width: 13rem;
23
+ --simple-gap: 3rem;
24
+ --simple-measure: 66ch;
25
+ --simple-radius: 6px;
26
+ --simple-font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
27
+ --simple-serif: Charter, "Bitstream Charter", "Iowan Old Style", "Sitka Text", Cambria, Georgia, "Times New Roman", serif;
28
+ --simple-mono: "JetBrains Mono", "Fira Code", ui-monospace, SFMono-Regular, Consolas, monospace;
29
+
30
+ --simple-tok-keyword: light-dark(#b42318, #ff7b72);
31
+ --simple-tok-const: light-dark(#0550ae, #79c0ff);
32
+ --simple-tok-string: light-dark(#0a3069, #a5d6ff);
33
+ --simple-tok-func: light-dark(#6639ba, #d2a8ff);
34
+ --simple-tok-class: light-dark(#953800, #ffa657);
35
+ --simple-tok-tag: light-dark(#116329, #7ee787);
36
+ --simple-tok-comment: light-dark(#59636e, #9aa3ad);
37
+
38
+ --krate-primary: var(--simple-accent);
39
+ --krate-primary-hover: var(--simple-accent-strong);
40
+ --krate-bg: var(--simple-bg);
41
+ --krate-text: var(--simple-fg);
42
+ --krate-text-muted: var(--simple-fg-soft);
43
+ --krate-border: var(--simple-border);
44
+ --krate-card-bg: var(--simple-bg-raised);
45
+ --krate-tabs-bg: var(--simple-bg-soft);
46
+ --krate-code-bg: var(--simple-code-bg);
47
+ --krate-code-text: var(--simple-code-fg);
48
+ --krate-code-title-bg: var(--simple-code-bg);
49
+ --krate-code-title-text: var(--simple-muted);
50
+ --krate-css-active: var(--simple-accent);
51
+ --krate-css-active-fg: var(--simple-accent-strong);
52
+ --krate-focus-ring: var(--simple-accent);
53
+
54
+ min-height: 100vh;
55
+ background: var(--simple-bg);
56
+ color: var(--simple-fg);
57
+ font-family: var(--simple-serif);
58
+ font-size: 18px;
59
+ line-height: 1.65;
60
+ -webkit-font-smoothing: antialiased;
61
+ text-size-adjust: 100%;
62
+ scrollbar-color: var(--simple-border) transparent;
63
+ }
64
+
65
+ .simple-page:has(> input.krc-h[value="light"]:checked) {
66
+ color-scheme: light;
67
+ }
68
+
69
+ .simple-page:has(> input.krc-h[value="dark"]:checked) {
70
+ color-scheme: dark;
71
+ }
72
+
73
+ body:has(.simple-page) {
74
+ margin: 0;
75
+ padding: 0;
76
+ }
77
+
78
+ .simple-page *,
79
+ .simple-page *::before,
80
+ .simple-page *::after {
81
+ box-sizing: border-box;
82
+ }
83
+
84
+ .simple-page ::selection {
85
+ background: color-mix(in srgb, var(--simple-accent) 28%, transparent);
86
+ }
87
+
88
+ :where(.simple-page a) {
89
+ color: var(--simple-accent);
90
+ text-decoration: none;
91
+ }
92
+
93
+ :where(.simple-page a:hover) {
94
+ color: var(--simple-accent-strong);
95
+ }
96
+
97
+ .simple-page :focus-visible {
98
+ outline: 2px solid var(--simple-accent);
99
+ outline-offset: 2px;
100
+ border-radius: 2px;
101
+ }
102
+
103
+ .simple-page kbd {
104
+ padding: 1px 5px;
105
+ border: 1px solid var(--simple-border);
106
+ border-radius: 4px;
107
+ background: var(--simple-bg-soft);
108
+ color: var(--simple-muted);
109
+ font-family: var(--simple-mono);
110
+ font-size: 11px;
111
+ }
112
+
113
+ .simple-skip {
114
+ position: absolute;
115
+ left: 1rem;
116
+ top: -100px;
117
+ z-index: 300;
118
+ padding: 8px 12px;
119
+ border-radius: var(--simple-radius);
120
+ background: var(--simple-fg);
121
+ color: var(--simple-bg);
122
+ font: 14px var(--simple-font);
123
+ }
124
+
125
+ .simple-skip:focus {
126
+ top: 1rem;
127
+ }
128
+
129
+ .simple-version-banner,
130
+ .simple-header,
131
+ .simple-sidebar,
132
+ .simple-nav-drawer,
133
+ .simple-toc,
134
+ .simple-toc-mobile,
135
+ .simple-breadcrumbs,
136
+ .simple-taxonomy,
137
+ .simple-dates,
138
+ .simple-prevnext-label,
139
+ .simple-page-footer,
140
+ .simple-hero-action,
141
+ .simple-content table {
142
+ font-family: var(--simple-font);
143
+ }
144
+
145
+ .simple-version-banner {
146
+ display: flex;
147
+ align-items: center;
148
+ justify-content: center;
149
+ gap: 0.75rem;
150
+ padding: 8px 1rem;
151
+ background: var(--simple-bg-soft);
152
+ color: var(--simple-fg-soft);
153
+ font-size: 13px;
154
+ }
155
+
156
+ /* Header */
157
+ .simple-header {
158
+ position: sticky;
159
+ top: 0;
160
+ z-index: 100;
161
+ display: flex;
162
+ align-items: center;
163
+ gap: 1rem;
164
+ height: var(--simple-header-height);
165
+ padding: 0 1.25rem;
166
+ background: color-mix(in srgb, var(--simple-bg) 94%, transparent);
167
+ border-bottom: 1px solid var(--simple-border);
168
+ }
169
+
170
+ .simple-brand {
171
+ display: inline-flex;
172
+ align-items: center;
173
+ gap: 0.5rem;
174
+ min-width: 0;
175
+ color: var(--simple-fg);
176
+ font-size: 15px;
177
+ font-weight: 650;
178
+ letter-spacing: -0.01em;
179
+ }
180
+
181
+ .simple-brand > span:last-child {
182
+ overflow: hidden;
183
+ text-overflow: ellipsis;
184
+ white-space: nowrap;
185
+ }
186
+
187
+ .simple-brand-mark {
188
+ display: inline-flex;
189
+ flex: 0 0 auto;
190
+ color: var(--simple-accent);
191
+ }
192
+
193
+ .simple-header-actions {
194
+ display: flex;
195
+ align-items: center;
196
+ gap: 0.4rem;
197
+ margin-left: auto;
198
+ min-width: 0;
199
+ }
200
+
201
+ .simple-search-link {
202
+ display: inline-flex;
203
+ align-items: center;
204
+ gap: 0.45rem;
205
+ height: 32px;
206
+ max-width: 220px;
207
+ padding: 0 0.65rem;
208
+ border: 1px solid var(--simple-border);
209
+ border-radius: var(--simple-radius);
210
+ color: var(--simple-muted);
211
+ font-size: 13px;
212
+ }
213
+
214
+ .simple-search-link:hover {
215
+ background: var(--simple-bg-soft);
216
+ color: var(--simple-fg);
217
+ }
218
+
219
+ .simple-search-link span {
220
+ overflow: hidden;
221
+ text-overflow: ellipsis;
222
+ white-space: nowrap;
223
+ }
224
+
225
+ .simple-header-switchers,
226
+ .simple-nav-drawer-switchers {
227
+ display: flex;
228
+ align-items: center;
229
+ gap: 0.35rem;
230
+ }
231
+
232
+ .simple-icon-link,
233
+ .simple-icon-button {
234
+ display: inline-flex;
235
+ align-items: center;
236
+ justify-content: center;
237
+ width: 32px;
238
+ height: 32px;
239
+ padding: 0;
240
+ border: 0;
241
+ border-radius: var(--simple-radius);
242
+ background: transparent;
243
+ color: var(--simple-muted);
244
+ cursor: pointer;
245
+ font: inherit;
246
+ }
247
+
248
+ .simple-icon-link:hover,
249
+ .simple-icon-button:hover {
250
+ background: var(--simple-bg-soft);
251
+ color: var(--simple-fg);
252
+ }
253
+
254
+ .simple-social {
255
+ display: none;
256
+ align-items: center;
257
+ gap: 0.2rem;
258
+ }
259
+
260
+ .simple-theme-switch {
261
+ display: inline-flex;
262
+ align-items: center;
263
+ padding: 2px;
264
+ border: 1px solid var(--simple-border);
265
+ border-radius: calc(var(--simple-radius) + 2px);
266
+ }
267
+
268
+ .simple-theme-option {
269
+ display: inline-flex;
270
+ align-items: center;
271
+ justify-content: center;
272
+ width: 28px;
273
+ height: 28px;
274
+ padding: 0;
275
+ border: 0;
276
+ border-radius: var(--simple-radius);
277
+ background: var(--krate-active-bg, transparent);
278
+ color: var(--simple-muted);
279
+ cursor: pointer;
280
+ font: inherit;
281
+ }
282
+
283
+ .simple-theme-option:hover {
284
+ color: var(--simple-fg);
285
+ }
286
+
287
+ .simple-nav-open {
288
+ display: none;
289
+ }
290
+
291
+ /* Switchers */
292
+ .simple-switcher {
293
+ position: relative;
294
+ }
295
+
296
+ .simple-switcher summary {
297
+ display: inline-flex;
298
+ align-items: center;
299
+ gap: 0.3rem;
300
+ height: 32px;
301
+ padding: 0 0.55rem;
302
+ border: 1px solid var(--simple-border);
303
+ border-radius: var(--simple-radius);
304
+ color: var(--simple-fg-soft);
305
+ cursor: pointer;
306
+ font-size: 13px;
307
+ list-style: none;
308
+ }
309
+
310
+ .simple-switcher summary::-webkit-details-marker {
311
+ display: none;
312
+ }
313
+
314
+ .simple-switcher-menu {
315
+ position: absolute;
316
+ right: 0;
317
+ top: calc(100% + 6px);
318
+ z-index: 150;
319
+ min-width: 160px;
320
+ padding: 4px;
321
+ border: 1px solid var(--simple-border);
322
+ border-radius: var(--simple-radius);
323
+ background: var(--simple-bg-raised);
324
+ box-shadow: var(--simple-shadow);
325
+ font-family: var(--simple-font);
326
+ }
327
+
328
+ .simple-switcher-menu a {
329
+ display: block;
330
+ padding: 6px 9px;
331
+ border-radius: 4px;
332
+ color: var(--simple-fg-soft);
333
+ font-size: 13px;
334
+ }
335
+
336
+ .simple-switcher-menu a:hover {
337
+ background: var(--simple-bg-soft);
338
+ }
339
+
340
+ .simple-switcher-menu a.is-active {
341
+ color: var(--simple-accent);
342
+ font-weight: 600;
343
+ }
344
+
345
+ /* Nav drawer (small screens) */
346
+ .simple-nav-panel {
347
+ display: none;
348
+ }
349
+
350
+ .simple-nav-backdrop {
351
+ position: fixed;
352
+ inset: 0;
353
+ background: rgba(0, 0, 0, 0.42);
354
+ }
355
+
356
+ .simple-nav-drawer {
357
+ position: fixed;
358
+ inset: 0 auto 0 0;
359
+ z-index: 1;
360
+ width: min(320px, 88vw);
361
+ overflow-y: auto;
362
+ padding: 1rem;
363
+ background: var(--simple-bg);
364
+ border-right: 1px solid var(--simple-border);
365
+ box-shadow: var(--simple-shadow);
366
+ }
367
+
368
+ .simple-nav-drawer-head {
369
+ display: flex;
370
+ align-items: center;
371
+ justify-content: space-between;
372
+ gap: 1rem;
373
+ margin-bottom: 0.9rem;
374
+ font-weight: 650;
375
+ }
376
+
377
+ .simple-nav-drawer-switchers {
378
+ margin-bottom: 1rem;
379
+ }
380
+
381
+ /* Shell */
382
+ .simple-shell {
383
+ display: grid;
384
+ grid-template-columns: var(--simple-sidebar-width) minmax(0, var(--simple-measure)) var(--simple-toc-width);
385
+ justify-content: center;
386
+ gap: var(--simple-gap);
387
+ width: 100%;
388
+ margin: 0 auto;
389
+ padding: 0 1.5rem;
390
+ }
391
+
392
+ .simple-page[data-toc="false"] .simple-shell {
393
+ grid-template-columns: var(--simple-sidebar-width) minmax(0, var(--simple-measure));
394
+ }
395
+
396
+ .simple-sidebar {
397
+ position: sticky;
398
+ top: var(--simple-header-height);
399
+ align-self: start;
400
+ max-height: calc(100vh - var(--simple-header-height));
401
+ overflow-y: auto;
402
+ padding: 2.25rem 0.5rem 2rem 0;
403
+ }
404
+
405
+ .simple-nav {
406
+ display: flex;
407
+ flex-direction: column;
408
+ gap: 2px;
409
+ font-family: var(--simple-font);
410
+ font-size: 14px;
411
+ line-height: 1.4;
412
+ }
413
+
414
+ .simple-nav-link,
415
+ .simple-nav-summary {
416
+ display: flex;
417
+ align-items: center;
418
+ gap: 0.45rem;
419
+ min-height: 30px;
420
+ padding: 5px 0;
421
+ color: var(--simple-fg-soft);
422
+ cursor: pointer;
423
+ }
424
+
425
+ .simple-nav-link:hover,
426
+ .simple-nav-summary:hover {
427
+ color: var(--simple-fg);
428
+ text-decoration: underline;
429
+ text-decoration-thickness: 1px;
430
+ text-underline-offset: 3px;
431
+ }
432
+
433
+ .simple-nav-summary {
434
+ color: var(--simple-fg);
435
+ font-weight: 600;
436
+ }
437
+
438
+ .simple-nav-link.is-active,
439
+ .simple-nav-section.is-active > .simple-nav-summary {
440
+ color: var(--simple-accent);
441
+ font-weight: 600;
442
+ }
443
+
444
+ .simple-nav-text {
445
+ cursor: default;
446
+ }
447
+
448
+ .simple-nav-icon {
449
+ display: inline-flex;
450
+ flex: 0 0 auto;
451
+ color: var(--simple-muted);
452
+ }
453
+
454
+ .simple-nav-label {
455
+ min-width: 0;
456
+ overflow: hidden;
457
+ text-overflow: ellipsis;
458
+ white-space: nowrap;
459
+ }
460
+
461
+ .simple-nav-badge {
462
+ margin-left: auto;
463
+ padding: 1px 6px;
464
+ border-radius: 999px;
465
+ background: var(--simple-bg-soft);
466
+ color: var(--simple-muted);
467
+ font-size: 11px;
468
+ font-weight: 600;
469
+ }
470
+
471
+ .simple-nav-badge-tip,
472
+ .simple-nav-badge-success {
473
+ background: color-mix(in srgb, #10b981 14%, transparent);
474
+ color: light-dark(#047857, #6ee7b7);
475
+ }
476
+
477
+ .simple-nav-badge-warning {
478
+ background: color-mix(in srgb, #f59e0b 16%, transparent);
479
+ color: light-dark(#92400e, #fcd34d);
480
+ }
481
+
482
+ .simple-nav-badge-danger {
483
+ background: color-mix(in srgb, #ef4444 14%, transparent);
484
+ color: light-dark(#b91c1c, #fca5a5);
485
+ }
486
+
487
+ .simple-nav-section > summary {
488
+ list-style: none;
489
+ }
490
+
491
+ .simple-nav-section > summary::-webkit-details-marker {
492
+ display: none;
493
+ }
494
+
495
+ .simple-nav-chevron {
496
+ display: inline-flex;
497
+ margin-left: auto;
498
+ color: var(--simple-muted);
499
+ transition: transform 0.15s ease;
500
+ }
501
+
502
+ .simple-nav-section[open] > summary .simple-nav-chevron {
503
+ transform: rotate(180deg);
504
+ }
505
+
506
+ .simple-nav-children {
507
+ display: flex;
508
+ flex-direction: column;
509
+ gap: 1px;
510
+ margin: 0 0 0.6rem 2px;
511
+ padding-left: 12px;
512
+ border-left: 1px solid var(--simple-border);
513
+ }
514
+
515
+ .simple-nav-index {
516
+ color: var(--simple-muted);
517
+ }
518
+
519
+ /* Table of contents */
520
+ .simple-toc {
521
+ position: sticky;
522
+ top: var(--simple-header-height);
523
+ align-self: start;
524
+ max-height: calc(100vh - var(--simple-header-height));
525
+ overflow-y: auto;
526
+ padding: 2.25rem 0 2rem;
527
+ font-size: 13px;
528
+ line-height: 1.4;
529
+ }
530
+
531
+ .simple-toc-title {
532
+ margin-bottom: 0.6rem;
533
+ color: var(--simple-fg);
534
+ font-size: 13px;
535
+ font-weight: 650;
536
+ }
537
+
538
+ .simple-toc-list {
539
+ margin: 0;
540
+ padding: 0;
541
+ list-style: none;
542
+ }
543
+
544
+ .simple-toc-list a {
545
+ display: block;
546
+ padding: 4px 0 4px 12px;
547
+ border-left: 1px solid var(--simple-border);
548
+ color: var(--simple-muted);
549
+ }
550
+
551
+ .simple-toc-list a:hover {
552
+ border-left-color: var(--simple-accent);
553
+ color: var(--simple-fg);
554
+ }
555
+
556
+ .simple-toc-depth-3 a {
557
+ padding-left: 24px;
558
+ }
559
+
560
+ .simple-toc-depth-4 a {
561
+ padding-left: 36px;
562
+ }
563
+
564
+ .simple-toc-mobile {
565
+ display: none;
566
+ margin: 0 0 1.5rem;
567
+ border-block: 1px solid var(--simple-border);
568
+ }
569
+
570
+ .simple-toc-mobile summary {
571
+ cursor: pointer;
572
+ padding: 10px 0;
573
+ color: var(--simple-fg);
574
+ font-size: 14px;
575
+ font-weight: 600;
576
+ }
577
+
578
+ .simple-toc-mobile .simple-toc-list {
579
+ padding: 0 0 10px;
580
+ font-size: 14px;
581
+ }
582
+
583
+ .simple-main {
584
+ min-width: 0;
585
+ padding: 2.25rem 0 5rem;
586
+ }
587
+
588
+ .simple-content {
589
+ min-width: 0;
590
+ }
591
+
592
+ .simple-breadcrumbs {
593
+ margin-bottom: 1.25rem;
594
+ font-size: 13px;
595
+ line-height: 1.4;
596
+ }
597
+
598
+ .simple-breadcrumbs ol {
599
+ display: flex;
600
+ flex-wrap: wrap;
601
+ gap: 0.35rem;
602
+ margin: 0;
603
+ padding: 0;
604
+ list-style: none;
605
+ color: var(--simple-muted);
606
+ }
607
+
608
+ .simple-breadcrumbs li + li::before {
609
+ content: "/";
610
+ margin-right: 0.35rem;
611
+ }
612
+
613
+ .simple-breadcrumbs a {
614
+ color: var(--simple-muted);
615
+ }
616
+
617
+ .simple-breadcrumbs a:hover {
618
+ text-decoration: underline;
619
+ }
620
+
621
+ .simple-description {
622
+ margin: 0 0 1.5rem;
623
+ color: var(--simple-muted);
624
+ font-size: 1.15rem;
625
+ font-style: italic;
626
+ line-height: 1.5;
627
+ text-wrap: pretty;
628
+ }
629
+
630
+ /* The description sits under the page title when the plugin passes the title
631
+ separately. */
632
+ .simple-title h1 {
633
+ margin-bottom: 0.35em;
634
+ }
635
+
636
+ /* Hero */
637
+ .simple-hero {
638
+ margin-bottom: 1rem;
639
+ padding: 1rem 0 0.5rem;
640
+ }
641
+
642
+ .simple-hero h1 {
643
+ margin: 0;
644
+ font-size: clamp(2.5rem, 7vw, 3.75rem);
645
+ font-weight: 600;
646
+ line-height: 1.05;
647
+ letter-spacing: -0.03em;
648
+ text-wrap: balance;
649
+ }
650
+
651
+ .simple-hero-tagline {
652
+ margin: 1rem 0 0;
653
+ color: var(--simple-fg-soft);
654
+ font-size: 1.3rem;
655
+ line-height: 1.5;
656
+ text-wrap: pretty;
657
+ }
658
+
659
+ .simple-hero-image {
660
+ display: block;
661
+ max-width: 100%;
662
+ margin-top: 1.5rem;
663
+ border-radius: var(--simple-radius);
664
+ }
665
+
666
+ .simple-hero-actions {
667
+ display: flex;
668
+ flex-wrap: wrap;
669
+ align-items: center;
670
+ gap: 0.5rem 1.25rem;
671
+ margin-top: 1.5rem;
672
+ }
673
+
674
+ .simple-hero-action {
675
+ display: inline-flex;
676
+ align-items: center;
677
+ min-height: 40px;
678
+ color: var(--simple-fg);
679
+ font-size: 15px;
680
+ font-weight: 600;
681
+ text-decoration: underline;
682
+ text-decoration-thickness: 1px;
683
+ text-underline-offset: 4px;
684
+ }
685
+
686
+ .simple-hero-action:hover {
687
+ color: var(--simple-accent);
688
+ }
689
+
690
+ .simple-hero-action-primary {
691
+ padding: 0 1.1rem;
692
+ border-radius: var(--simple-radius);
693
+ background: var(--simple-fg);
694
+ color: var(--simple-bg);
695
+ text-decoration: none;
696
+ }
697
+
698
+ .simple-hero-action-primary:hover {
699
+ background: var(--simple-accent-strong);
700
+ color: var(--simple-bg);
701
+ }
702
+
703
+ /* Prose */
704
+ .simple-content h1,
705
+ .simple-content h2,
706
+ .simple-content h3,
707
+ .simple-content h4,
708
+ .simple-content h5,
709
+ .simple-content h6 {
710
+ position: relative;
711
+ color: var(--simple-fg);
712
+ font-weight: 600;
713
+ line-height: 1.2;
714
+ letter-spacing: -0.015em;
715
+ text-wrap: balance;
716
+ scroll-margin-top: calc(var(--simple-header-height) + 1.5rem);
717
+ }
718
+
719
+ .simple-content h1 {
720
+ margin: 0 0 0.5em;
721
+ font-size: 2.5rem;
722
+ line-height: 1.1;
723
+ letter-spacing: -0.025em;
724
+ }
725
+
726
+ .simple-content h2 {
727
+ margin: 1.9em 0 0.5em;
728
+ font-size: 1.65rem;
729
+ }
730
+
731
+ .simple-content h3 {
732
+ margin: 1.6em 0 0.4em;
733
+ font-size: 1.3rem;
734
+ }
735
+
736
+ .simple-content :is(h4, h5, h6) {
737
+ margin: 1.8em 0 0.4em;
738
+ font-size: 1rem;
739
+ letter-spacing: 0;
740
+ }
741
+
742
+ .simple-content :where(p, ul, ol, pre, table, blockquote, details) {
743
+ margin-block: 1.1em;
744
+ }
745
+
746
+ .simple-content p,
747
+ .simple-content li {
748
+ text-wrap: pretty;
749
+ }
750
+
751
+ .simple-content ul,
752
+ .simple-content ol {
753
+ padding-left: 1.3em;
754
+ }
755
+
756
+ .simple-content li {
757
+ margin: 0.35em 0;
758
+ padding-left: 0.2em;
759
+ }
760
+
761
+ .simple-content li::marker {
762
+ color: var(--simple-muted);
763
+ }
764
+
765
+ .simple-content li > :is(ul, ol) {
766
+ margin-block: 0.35em;
767
+ }
768
+
769
+ .simple-content strong {
770
+ font-weight: 650;
771
+ color: var(--simple-fg);
772
+ }
773
+
774
+ .simple-content a:not([class]) {
775
+ text-decoration: underline;
776
+ text-decoration-thickness: 1px;
777
+ text-decoration-color: color-mix(in srgb, currentColor 40%, transparent);
778
+ text-underline-offset: 0.2em;
779
+ }
780
+
781
+ .simple-content a:not([class]):hover {
782
+ text-decoration-color: currentColor;
783
+ }
784
+
785
+ .simple-content :not(pre) > code {
786
+ padding: 0.1em 0.35em;
787
+ border-radius: 4px;
788
+ background: var(--simple-bg-soft);
789
+ color: var(--simple-fg);
790
+ font-family: var(--simple-mono);
791
+ font-size: 0.82em;
792
+ overflow-wrap: anywhere;
793
+ }
794
+
795
+ .simple-content pre {
796
+ padding: 1rem 1.25rem;
797
+ overflow-x: auto;
798
+ border-radius: var(--simple-radius);
799
+ background: var(--simple-code-bg);
800
+ color: var(--simple-code-fg);
801
+ font-family: var(--simple-mono);
802
+ font-size: 13.5px;
803
+ line-height: 1.65;
804
+ tab-size: 4;
805
+ }
806
+
807
+ .simple-content pre code {
808
+ padding: 0;
809
+ background: transparent;
810
+ color: inherit;
811
+ font: inherit;
812
+ }
813
+
814
+ .simple-content .krate-code-block {
815
+ position: relative;
816
+ margin-block: 1.4em;
817
+ overflow: hidden;
818
+ border: 0;
819
+ border-radius: var(--simple-radius);
820
+ background: var(--simple-code-bg);
821
+ }
822
+
823
+ .simple-content .krate-code-block pre,
824
+ .simple-content .krate-code-block code {
825
+ background: transparent;
826
+ font-family: var(--simple-mono);
827
+ font-size: 13.5px;
828
+ line-height: 1.65;
829
+ }
830
+
831
+ .simple-content .krate-code-block pre {
832
+ margin: 0;
833
+ padding: 1rem 1.25rem;
834
+ border-radius: 0;
835
+ }
836
+
837
+ .simple-content .krate-code-block code {
838
+ overflow: visible;
839
+ }
840
+
841
+ .simple-content .krate-code-header {
842
+ min-height: 0;
843
+ padding: 0.35rem 0.75rem 0;
844
+ border: 0;
845
+ background: transparent;
846
+ font-family: var(--simple-font);
847
+ }
848
+
849
+ .simple-content .krate-code-header:has(.krate-code-title:empty) {
850
+ position: absolute;
851
+ top: 0.25rem;
852
+ right: 0.25rem;
853
+ z-index: 1;
854
+ padding: 0;
855
+ }
856
+
857
+ .simple-content .krate-code-copy {
858
+ color: var(--simple-muted);
859
+ }
860
+
861
+ .simple-content .krate-code-copy:hover {
862
+ background: var(--simple-border);
863
+ color: var(--simple-fg);
864
+ }
865
+
866
+ .simple-content .chroma .err {
867
+ color: inherit;
868
+ }
869
+
870
+ .simple-content .chroma :is(.k, .kd, .kn, .kr, .kt, .nn, .o, .ow, .or, .gt) {
871
+ color: var(--simple-tok-keyword);
872
+ }
873
+
874
+ .simple-content .chroma :is(.kc, .kp, .bp, .no, .nl, .py, .nv, .vc, .vg, .vi, .vm, .sa, .dl, .se, .sh, .sr, .ld, .gh, .gu) {
875
+ color: var(--simple-tok-const);
876
+ }
877
+
878
+ .simple-content .chroma :is(.l, .s, .sb, .sc, .sd, .s2, .si, .sx, .s1, .ss, .m, .mb, .mf, .mh, .mi, .il, .mo) {
879
+ color: var(--simple-tok-string);
880
+ }
881
+
882
+ .simple-content .chroma :is(.nd, .nf, .fm) {
883
+ color: var(--simple-tok-func);
884
+ }
885
+
886
+ .simple-content .chroma :is(.nc, .ne, .ni) {
887
+ color: var(--simple-tok-class);
888
+ }
889
+
890
+ .simple-content .chroma .nt {
891
+ color: var(--simple-tok-tag);
892
+ }
893
+
894
+ .simple-content .chroma :is(.c, .ch, .cm, .c1, .cs, .cp, .cpf, .go, .gp, .ln, .lnt) {
895
+ color: var(--simple-tok-comment);
896
+ }
897
+
898
+ .simple-content blockquote {
899
+ padding-left: 1.25rem;
900
+ border-left: 1px solid var(--simple-border);
901
+ color: var(--simple-fg-soft);
902
+ font-style: italic;
903
+ }
904
+
905
+ .simple-content blockquote > :first-child {
906
+ margin-top: 0;
907
+ }
908
+
909
+ .simple-content blockquote > :last-child {
910
+ margin-bottom: 0;
911
+ }
912
+
913
+ .simple-content hr {
914
+ margin-block: 2.5rem;
915
+ border: 0;
916
+ border-top: 1px solid var(--simple-border);
917
+ }
918
+
919
+ .simple-content img,
920
+ .simple-content video {
921
+ max-width: 100%;
922
+ height: auto;
923
+ border-radius: var(--simple-radius);
924
+ }
925
+
926
+ /* Tables scroll inside themselves */
927
+ .simple-content table {
928
+ display: block;
929
+ width: max-content;
930
+ max-width: 100%;
931
+ overflow-x: auto;
932
+ border-collapse: collapse;
933
+ font-size: 14.5px;
934
+ line-height: 1.5;
935
+ font-variant-numeric: tabular-nums;
936
+ }
937
+
938
+ .simple-content th,
939
+ .simple-content td {
940
+ padding: 0.5rem 1rem 0.5rem 0;
941
+ border-bottom: 1px solid var(--simple-border);
942
+ text-align: left;
943
+ vertical-align: top;
944
+ }
945
+
946
+ .simple-content th {
947
+ border-bottom-color: var(--simple-fg-soft);
948
+ color: var(--simple-fg);
949
+ font-weight: 650;
950
+ white-space: nowrap;
951
+ }
952
+
953
+ .simple-content td code {
954
+ font-size: 0.88em;
955
+ }
956
+
957
+ .simple-content .heading-anchor {
958
+ position: absolute;
959
+ right: 100%;
960
+ padding-right: 0.4em;
961
+ color: var(--simple-muted);
962
+ font-weight: 400;
963
+ opacity: 0;
964
+ }
965
+
966
+ .simple-content :is(h2, h3, h4):hover .heading-anchor,
967
+ .simple-content .heading-anchor:focus {
968
+ opacity: 1;
969
+ }
970
+
971
+ /* Admonitions */
972
+ .simple-content .krate-aside {
973
+ margin-block: 1.4em;
974
+ padding: 0.9rem 1.1rem;
975
+ border-radius: var(--simple-radius);
976
+ background: color-mix(in srgb, var(--krate-aside-accent) 7%, var(--simple-bg));
977
+ font-size: 16px;
978
+ line-height: 1.55;
979
+ }
980
+
981
+ .simple-content .krate-aside-title {
982
+ margin-bottom: 0.35rem;
983
+ font-family: var(--simple-font);
984
+ font-size: 13px;
985
+ font-weight: 650;
986
+ }
987
+
988
+ .simple-content .krate-aside-content,
989
+ .simple-content .krate-aside-content p {
990
+ margin-block: 0.5em 0;
991
+ color: var(--simple-fg);
992
+ }
993
+
994
+
995
+ .simple-content .krate-card {
996
+ background: var(--simple-bg-raised);
997
+ }
998
+
999
+ /* After the content */
1000
+ .simple-taxonomy {
1001
+ display: flex;
1002
+ flex-wrap: wrap;
1003
+ gap: 0.4rem;
1004
+ margin-top: 3rem;
1005
+ }
1006
+
1007
+ .simple-chip {
1008
+ padding: 2px 9px;
1009
+ border: 1px solid var(--simple-border);
1010
+ border-radius: 999px;
1011
+ color: var(--simple-muted);
1012
+ font-size: 12.5px;
1013
+ }
1014
+
1015
+ .simple-chip:hover {
1016
+ border-color: var(--simple-accent);
1017
+ color: var(--simple-accent);
1018
+ }
1019
+
1020
+ .simple-chip-category {
1021
+ border-style: dashed;
1022
+ }
1023
+
1024
+ .simple-dates {
1025
+ display: flex;
1026
+ flex-wrap: wrap;
1027
+ gap: 0.25rem 1.25rem;
1028
+ margin-top: 1.25rem;
1029
+ color: var(--simple-muted);
1030
+ font-size: 13px;
1031
+ }
1032
+
1033
+ .simple-prevnext {
1034
+ display: grid;
1035
+ grid-template-columns: 1fr 1fr;
1036
+ gap: 1rem;
1037
+ margin-top: 3rem;
1038
+ padding-top: 1.25rem;
1039
+ border-top: 1px solid var(--simple-border);
1040
+ }
1041
+
1042
+ .simple-prevnext-link {
1043
+ display: flex;
1044
+ flex-direction: column;
1045
+ gap: 0.15rem;
1046
+ color: var(--simple-fg);
1047
+ }
1048
+
1049
+ .simple-prevnext-link:hover .simple-prevnext-title {
1050
+ color: var(--simple-accent);
1051
+ text-decoration: underline;
1052
+ text-underline-offset: 0.2em;
1053
+ }
1054
+
1055
+ .simple-prevnext-next {
1056
+ text-align: right;
1057
+ }
1058
+
1059
+ .simple-prevnext-label {
1060
+ color: var(--simple-muted);
1061
+ font-size: 13px;
1062
+ }
1063
+
1064
+ .simple-prevnext-title {
1065
+ font-size: 1.15rem;
1066
+ line-height: 1.3;
1067
+ }
1068
+
1069
+ .simple-page-footer {
1070
+ display: flex;
1071
+ flex-wrap: wrap;
1072
+ align-items: center;
1073
+ justify-content: space-between;
1074
+ gap: 1rem;
1075
+ margin-top: 1.5rem;
1076
+ color: var(--simple-muted);
1077
+ font-size: 13px;
1078
+ }
1079
+
1080
+ .simple-edit-link {
1081
+ display: inline-flex;
1082
+ align-items: center;
1083
+ gap: 0.35rem;
1084
+ color: var(--simple-muted);
1085
+ }
1086
+
1087
+ .simple-edit-link:hover {
1088
+ color: var(--simple-accent);
1089
+ }
1090
+
1091
+ .simple-feedback {
1092
+ display: flex;
1093
+ align-items: center;
1094
+ gap: 0.25rem;
1095
+ }
1096
+
1097
+ .simple-feedback .simple-icon-button {
1098
+ width: 28px;
1099
+ height: 28px;
1100
+ }
1101
+
1102
+ /* Responsive */
1103
+ @media (min-width: 760px) {
1104
+ .simple-social {
1105
+ display: flex;
1106
+ }
1107
+ }
1108
+
1109
+ @media (max-width: 1180px) {
1110
+ .simple-shell,
1111
+ .simple-page[data-toc="false"] .simple-shell {
1112
+ grid-template-columns: var(--simple-sidebar-width) minmax(0, var(--simple-measure));
1113
+ }
1114
+
1115
+ .simple-toc {
1116
+ display: none;
1117
+ }
1118
+
1119
+ .simple-toc-mobile {
1120
+ display: block;
1121
+ }
1122
+ }
1123
+
1124
+ @media (max-width: 900px) {
1125
+ .simple-header {
1126
+ padding: 0 0.9rem;
1127
+ }
1128
+
1129
+ .simple-header-switchers,
1130
+ .simple-social,
1131
+ .simple-search-link,
1132
+ .simple-sidebar,
1133
+ .simple-content .heading-anchor {
1134
+ display: none;
1135
+ }
1136
+
1137
+ .simple-nav-open {
1138
+ display: inline-flex;
1139
+ }
1140
+
1141
+ .simple-shell,
1142
+ .simple-page[data-toc="false"] .simple-shell {
1143
+ grid-template-columns: minmax(0, var(--simple-measure));
1144
+ gap: 0;
1145
+ padding: 0 1.25rem;
1146
+ }
1147
+
1148
+ .simple-main {
1149
+ padding-top: 1.5rem;
1150
+ }
1151
+
1152
+ .simple-nav-panel {
1153
+ display: block;
1154
+ position: fixed;
1155
+ inset: 0;
1156
+ z-index: 200;
1157
+ }
1158
+ }
1159
+
1160
+ @media (max-width: 600px) {
1161
+ .simple-page {
1162
+ font-size: 17px;
1163
+ }
1164
+
1165
+ .simple-content h1 {
1166
+ font-size: 2.1rem;
1167
+ }
1168
+
1169
+ .simple-content h2 {
1170
+ font-size: 1.45rem;
1171
+ }
1172
+
1173
+ .simple-prevnext {
1174
+ grid-template-columns: minmax(0, 1fr);
1175
+ }
1176
+
1177
+ .simple-prevnext-next {
1178
+ text-align: left;
1179
+ }
1180
+
1181
+ .simple-header-actions {
1182
+ gap: 0.2rem;
1183
+ }
1184
+ }
1185
+
1186
+ @media (prefers-reduced-motion: reduce) {
1187
+ .simple-page *,
1188
+ .simple-page *::before,
1189
+ .simple-page *::after {
1190
+ scroll-behavior: auto !important;
1191
+ transition-duration: 0.01ms !important;
1192
+ }
1193
+ }
1194
+
1195
+ @media print {
1196
+ .simple-page {
1197
+ --simple-bg: #fff;
1198
+ --simple-fg: #000;
1199
+ --simple-fg-soft: #222;
1200
+ --simple-muted: #444;
1201
+ --simple-code-bg: #f4f4f4;
1202
+ --simple-code-fg: #000;
1203
+ background: #fff;
1204
+ font-size: 11pt;
1205
+ }
1206
+
1207
+ .simple-skip,
1208
+ .simple-version-banner,
1209
+ .simple-header,
1210
+ .simple-nav-panel,
1211
+ .simple-sidebar,
1212
+ .simple-toc,
1213
+ .simple-toc-mobile,
1214
+ .simple-prevnext,
1215
+ .simple-page-footer,
1216
+ .simple-content .krate-code-copy {
1217
+ display: none !important;
1218
+ }
1219
+
1220
+ .simple-shell {
1221
+ display: block;
1222
+ padding: 0;
1223
+ }
1224
+
1225
+ .simple-main {
1226
+ padding: 0;
1227
+ }
1228
+
1229
+ .simple-content pre,
1230
+ .simple-content .krate-code-block {
1231
+ border: 1px solid #ccc;
1232
+ white-space: pre-wrap;
1233
+ overflow-wrap: anywhere;
1234
+ break-inside: avoid;
1235
+ }
1236
+
1237
+ .simple-content table,
1238
+ .simple-content blockquote,
1239
+ .simple-content img {
1240
+ break-inside: avoid;
1241
+ }
1242
+
1243
+ .simple-content :is(h1, h2, h3, h4) {
1244
+ break-after: avoid;
1245
+ }
1246
+
1247
+ .simple-content a:not([class])[href^="http"]::after {
1248
+ content: " (" attr(href) ")";
1249
+ color: var(--simple-muted);
1250
+ font-size: 0.85em;
1251
+ overflow-wrap: anywhere;
1252
+ }
1253
+ }