-
Notifications
You must be signed in to change notification settings - Fork 69
/
epub3.css
1266 lines (1066 loc) · 26.8 KB
/
epub3.css
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
@import url("epub3-fonts.css");
*, *:before, *:after {
box-sizing: border-box;
}
/* educate older readers about tags introduced in HTML5 */
article, aside, details, figcaption, figure,
footer, header, nav, section, summary {
display: block;
}
/* html and body declarations must be separate entries for some readers */
html {
margin: 0 !important;
padding: 0 !important;
/* set the em base (and relative em anchor) by setting the font-size on html */
/* TODO set font-size > 100% except for Kindle */
font-size: 100%;
-webkit-text-size-adjust: 100%;
}
/* don't set margin on body as that's how many readers frame reading area */
/* can't set the font-family on body in Kindle */
body {
padding: 0 !important;
/* add margin to ~ match Kindle's narrow setting */
/* don't use !important on margin as it interferes with reader overrides (Calibre and Kindle) */
margin: 0;
font-size: 100%;
/* NOTE putting optimizeLegibility on the body slows down rendering considerably */
text-rendering: optimizeSpeed;
/* -webkit-font-smoothing has no noticable effect and is controversial, so leaving it off */
}
/* disables night mode in Aldiko, hoo-ha! */
html body {
background-color: #FFFFFF;
}
/* @page only applies to EPUB2 readers; not supported by EPUB3 readers such as Kindle and Gitden */
@page {
/* sets minimum margin permitted */
/* pushes the top & bottom margins down in Aldiko to emulate Kindle (Kindle uses ~ 10% of screen by default )*/
margin: 1cm;
}
div, p, blockquote, pre, figure, figcaption,
h1, h2, h3, h4, h5, h6,
dl, dt, dd, ol, ul, li,
table, caption, thead, tfoot, tbody, tr, th, td {
margin: 0;
padding: 0;
font-size: 100%;
vertical-align: baseline;
}
a, abbr, address, cite, code, em, kbd, span, strong {
font-size: 100%;
}
a {
background: transparent;
}
a:active, a:hover {
outline: 0;
}
abbr[title] {
border-bottom: 1px dotted;
}
address {
white-space: pre-line;
}
b, strong {
font-weight: bold;
}
b.button {
font-weight: normal;
text-shadow: 1px 0 0 #666665;
color: #191918;
white-space: nowrap;
}
b.button .label {
padding: 0 0.25em;
}
kbd {
display: inline-block;
font-size: 0.8em;
line-height: 1;
background-color: #F7F7F7; /* #FAFAFA */
border: 1px solid #BEBEBC;
-webkit-border-radius: 3px;
border-radius: 3px;
-webkit-box-shadow: 1px 1px 0 rgba(102, 102, 101, 0.25), 0 0 0 1px white inset;
box-shadow: 1px 1px 0 rgba(102, 102, 101, 0.25), 0 0 0 1px white inset;
margin: 0 0.15em;
padding: 0.25em 0.4em 0.2em 0.4em;
vertical-align: 0.15em;
}
.keyseq {
white-space: nowrap;
}
.menuseq .caret {
/*
font-family: "FontAwesome";
font-size: 0.7em;
line-height: 1;
font-weight: bold;
vertical-align: 0.08rem;
*/
font-weight: bold;
}
.menuseq span[class~="caret"] {
visibility: hidden;
}
.menuseq .caret::before {
font-family: "FontAwesome";
content: "\f054";
font-size: 0.6em;
vertical-align: 0.15em;
visibility: visible;
display: inline-block;
width: 0;
padding-right: 0.15em;
}
img {
border: 0;
max-width: 100%;
}
mark {
background-color: #FFC14F;
color: #191918;
}
small {
font-size: 80%;
}
sub, sup {
font-size: 0.75em;
line-height: 1;
}
sup {
/* position: relative not permitted on Kindle */
/*
position: relative;
top: -0.5em;
*/
/* alternate approach #1 */
/*
display: inline-block;
vertical-align: text-top;
padding-top: .25em;
*/
/* alternate approach #2 */
line-height: 1;
vertical-align: text-top;
}
sub {
/* position: relative not permitted on Kindle */
/*
position: relative;
bottom: -0.25em;
*/
/* alternate approach #1 */
/*
display: inline-block;
vertical-align: text-bottom;
padding-bottom: .5em;
*/
/* alternate approach #2 */
line-height: 1;
vertical-align: text-bottom;
}
table {
border-collapse: collapse;
border-spacing: 0;
}
td, th {
padding: 0;
}
body a:link {
color: #333332;
/* hack for font color in iBooks and Gitden (though Gitden would accept color !important too) */
-webkit-text-fill-color: #333332;
/* Kindle requires the !important on text-decoration */
/* In night mode, the only indicator of a link is the underline, so we need it or a background image */
text-decoration: none !important;
border-bottom: 1px dashed #666665;
/* allow URLs to break anywhere if they don't fit on a line; but how do we know it's a URL? */
/*
word-break: break-all;
*/
}
body:first-of-type a:link {
border-bottom: none;
background-repeat: no-repeat;
background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 0%, #666665 5%, #666665 95%, rgba(255,255,255,0) 100%);
background-image: linear-gradient(to right, rgba(255,255,255,0) 0%, #666665 5%, #666665 95%, rgba(255,255,255,0) 100%);
background-size: 100% 1px;
background-position: 0 1.2em;
}
body a:visited {
color: #666665;
/* hack for font color in iBooks */
-webkit-text-fill-color: #666665;
}
code.literal {
/* don't let it affect line spacing */
/* disable since M+ 1mn won't interrupt line height */
/*line-height: 1;*/
/*
white-space: nowrap;
*/
word-wrap: break-word;
}
h1, h2, h3, h4, h5, h6 {
font-family: "M+ 1p", sans-serif;
font-weight: 400;
letter-spacing: -0.01em;
/* NOTE Kindle doesn't allow the line-height to be less than the font size (refer to heading font sizes) */
line-height: 1.4; /* or 1.2125 */
text-align: left;
-webkit-hyphens: none; /* disable hyphenation where supported (e.g., iBooks) */
word-wrap: break-word; /* break in middle of long word if no other break opportunities are available */
/* avoiding page breaks does not seem to work in Kindle */
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
-webkit-column-break-after: avoid;
page-break-after: avoid;
}
/* Aldiko requires a higher precedence rule to set margin and text-indent, hence the body prefix */
/* We'll just use the stronger rule for all paragraph-related stuff to be sure */
body p {
margin: 1em 0 0 0;
text-align: justify;
text-indent: 0;
widows: 2;
orphans: 2;
}
body p,
ul, ol, li, dl, dt, dd, footer,
div.verse .attribution, table.table th, table.table td,
figcaption, caption {
color: #333332;
/* NOTE iBooks will forcefully override font-family of text inside div, p and span elements when font other than Original is selected */
/* NOTE iBooks honors Original font for prose text if declared in display-options.xml */
font-family: "Noto Serif", serif;
}
body p, li, dt, dd, footer {
line-height: 1.6;
}
code, kbd, pre {
color: #191918;
font-family: "M+ 1mn", monospace;
-webkit-hyphens: none; /* disable hyphenation where supported (e.g., iBooks) */
}
/* QUESTION should we kern preformatted text blocks? */
h1, h2, h3, h4, h5, h6,
body p, li, dd, blockquote > footer,
th, td, figcaption, caption {
/* forward-compatible CSS to enable kerning (if we want ligatures, add "liga" and "dlig") */
/* WebKits that don't recognize these properties don't kern well, hence why we don't simply enable kerning via text-rendering */
-webkit-font-feature-settings: "kern";
font-feature-settings: "kern";
font-kerning: normal;
/* NOTE see Kindle hack in epub3-css3-only.css for additional kerning settings (disabled) */
}
p.last::after {
color: #57AD68;
display: inline-block;
font-family: "FontAwesome";
font-size: 1em;
content: "\f121"; /* i.e., </> */
margin-left: 0.25em;
}
ul li, ol li {
/* minimum margin in case there is no paragraph content */
margin-top: 0.4em;
}
/* use paragraph-size gaps between list items */
.complex > ul > li,
.complex > ol > li {
margin-top: 1em;
}
/* squeeze content in complex lists */
/*
li > figure,
li > p {
margin-top: 0.4em;
}
*/
dl {
margin-top: 0;
margin-bottom: 0;
}
dt {
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
-webkit-column-break-after: avoid;
page-break-after: avoid;
}
dt > span.term {
font-style: italic;
}
/*
dt > span.term > code.literal {
font-style: normal;
}
*/
dt {
margin-top: 0.75em; /* balances 0.25em to term */
}
dl dd {
/* minimum margin in case there is no paragraph content */
margin-top: 0.25em;
}
div.callout-list {
margin-top: 0.5em;
}
div.callout-list ol {
font-size: 80%;
margin-left: 1.5em !important;
list-style-type: none;
}
div.callout-list ol li {
text-align: left;
}
i.conum {
color: #468C54;
font-family: "M+ 1mn", monospace;
font-style: normal;
}
/* don't let conum affect line spacing; REVIEW may not need this! */
/*pre i.conum {
line-height: 1;
}*/
div.callout-list li > i.conum {
float: left;
margin-left: -1.25em;
display: block;
width: 1.25em;
}
div.itemized-list, div.ordered-list, div.description-list {
margin-top: 1em;
padding-bottom: 0.25em; /* REVIEW maybe, maybe not */
}
/* QUESTION should we add the class "list" so we can style these generically? */
div.itemized-list div.itemized-list,
div.itemized-list div.ordered-list,
div.itemized-list div.description-list,
div.ordered-list div.itemized-list,
div.ordered-list div.ordered-list,
div.ordered-list div.description-list {
margin-top: 0;
}
/*div.description-list div.itemized-list,
div.description-list div.ordered-list,
div.description-list div.description-list {
}*/
h3.list-heading {
font-size: 1em;
font-family: "Noto Serif", serif;
font-weight: bold;
line-height: 1.6;
margin-top: 1em;
margin-bottom: -0.25em;
letter-spacing: 0;
}
div.stack li strong.subject,
div.stack-subject li strong.subject {
display: block;
}
ul {
/* QUESTION do we need important here? */
margin-left: 1em !important;
list-style-type: square;
}
ul ul {
list-style-type: circle;
}
ul ul ul {
list-style-type: disc;
}
/* disable list style type for CSS3-enabled clients */
body:first-of-type ul,
body:first-of-type ul ul,
body:first-of-type ul ul ul {
list-style-type: none;
}
ul > li::before {
float: left;
margin-left: -1em;
margin-top: -0.05em;
padding-left: 0.25em;
/* guarantee it's out of the flow */
width: 0;
display: block;
}
ul > li::before {
content: "\25AA"; /* small black square */
color: #666665;
}
ul ul > li::before {
content: "\25E6"; /* small white circle */
color: #57AD68;
}
ul ul ul > li::before {
content: "\2022"; /* small black circle */
color: #666665;
}
ul ul ul ul > li::before {
content: "\25AB"; /* small white square */
color: #57AD68;
}
ol {
margin-left: 1.75em !important;
}
ol {
list-style-type: decimal;
}
ol ol {
list-style-type: lower-alpha;
}
ol ol ol {
list-style-type: lower-roman;
}
/* REVIEW */
dd {
margin-left: 1.5rem !important;
}
/* Kindle does not justify list-item element, must wrap in nested block element */
li > span.principal, dd > span.principal {
display: block;
text-align: justify;
}
ol.brief > li > span.principal,
ul.brief > li > span.principal {
text-align: left;
}
/* REVIEW still considering keeping this one */
/* disable justify within a link */
/*
li strong.subject a:link {
white-space: pre-wrap;
word-spacing: 0.1em;
}*/
/*
.bibliography ul li,
.references ul li {
text-align: left;
}
*/
ul.bibliography > li > span.principal,
ul.references > li > span.principal {
text-align: left;
}
/* sized based on the major third modular scale (4:5, 16px, 24px) */
h1, h2 {
color: #333332;
font-size: 1.5em;
word-spacing: -0.075em;
margin-top: 1em; /* 1.5rem */
margin-bottom: -0.3333em; /* -0.5rem, 0.5rem to content */
}
h3 {
color: #333332;
font-size: 1.25em;
margin-top: 0.84em; /* 1.05rem */
margin-bottom: -0.5em; /* -0.625rem, 0.375rem to content */
}
h4 {
color: #4F4F4C;
font-weight: 200;
font-size: 1.1em;
margin-top: 1em; /* 1.1rem */
margin-bottom: -0.818em; /* -0.9rem, 0.1rem to content */
font-size: 1.2em;
margin-top: .917em; /* 1.1rem */
margin-top: 0.875em; /* 1.05rem */
/*margin-bottom: -0.75em;*/ /* -0.9rem, 0.1rem to content */
margin-bottom: -0.625em; /* -0.75rem, 0.25rem to content */
}
h5 {
color: #666665;
/*
font-size: 1em;
text-transform: uppercase;
margin-top: 1em;
margin-bottom: -1em;
*/
font-size: 0.9em;
font-weight: 700;
text-transform: uppercase; /* not supported in Adobe Digital Editions */
margin-top: 1.11em; /* 1rem */
margin-bottom: -0.972em; /* -0.875rem */
}
h1 code, h2 code, h3 code, h4 code, h5 code, h6 code {
color: inherit;
}
h5 code {
text-transform: none;
}
/* Kindle strips (or unwraps) <header> tags, so we use an inner div to style */
.chapter-header {
/* NOTE div must have at least 1px top padding for background to fill */
/* would like to use vh units for top and bottom padding */
/*padding: 0.75em 1.5em 0.25em 1.5em;*/
padding: 0.25em 0;
margin-bottom: 2.5em;
border-bottom: 1px solid #666665;
/* TODO maybe what we need to get articles to start in left column
-webkit-column-break-before: left;
page-break-before: left;
*/
}
h1.chapter-title {
font-weight: 200;
font-size: 1.2em;
margin-top: 3.5em; /* 4.2rem - would like to use 9vh */
margin-bottom: 0;
padding-bottom: 0.8333em; /* 1.2rem */
color: #666665;
text-transform: uppercase; /* not supported in Adobe Digital Editions */
word-spacing: -0.075em;
letter-spacing: -0.01em;
}
h1.chapter-title .subtitle {
font-weight: 400;
color: #333332;
display: block;
font-size: 1.5em;
margin: 0 0 0 0.75em; /* would like to use 2vw */
line-height: 1.2; /* line-height will remain 1.4 on Kindle, see hack in media query */
}
h1.chapter-title em {
color: #57AD68;
font-style: normal;
}
h1.chapter-title b {
font-weight: inherit;
}
.chapter-header p.byline {
color: #333332;
/* float left and height 0 takes this line out of the flow */
float: left;
height: 0;
width: 100%;
text-align: right;
margin-top: 0;
line-height: 2;
}
.chapter-header p.byline b {
font-weight: normal;
padding-left: 0.2em; /* 0.25rem */
font-size: 0.8em;
line-height: 2.5; /* 2rem */
}
.chapter-header p.byline img {
-webkit-border-radius: 0.5em;
border-radius: 0.5em;
vertical-align: middle;
/* some readers like to resize images; we don't want the author images resized */
height: 2em !important;
width: 2em !important;
}
div.abstract {
margin: 5% 1.5em 2.5em 1.5em;
}
div.abstract > p {
color: #666665;
font-size: 1.05em; /* or 1.1em? */
line-height: 1.75;
}
div.abstract > p a:link {
color: #666665;
/* hack for font color in iBooks */
-webkit-text-fill-color: #666665;
}
div.abstract > p:first-child::first-line {
font-weight: bold;
-webkit-font-feature-settings: "kern" off;
font-feature-settings: "kern" off;
font-kerning: none;
/* and for Kindle... */
text-rendering: optimizeSpeed;
}
div.abstract p strong {
font-weight: inherit;
font-style: italic;
}
p.lead {
font-size: 1.05em;
line-height: 1.75;
}
hr.thematicbreak {
display: none;
}
hr.thematicbreak + p {
margin-top: 1.5em;
}
/* TODO finish layout of first-letter */
hr.thematicbreak + p::first-letter {
font-size: 200%;
}
p.stack > strong.head,
p.stack-head > strong.head {
display: block;
}
p.signature {
font-size: 0.9em;
}
figure,
aside.sidebar {
margin-top: 1em;
}
/*
aside.sidebar {
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
float: left;
margin-bottom: 1em;
}
*/
figure.image {
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
}
figure.image img {
display: block;
margin: 0 auto;
}
figure.coalesce {
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
}
figcaption,
caption {
font-size: 0.9em;
font-style: italic;
color: #666665;
letter-spacing: -0.01em;
line-height: 1.4;
text-align: left;
padding-left: 0.1em;
page-break-inside: avoid;
-webkit-column-break-after: avoid;
page-break-after: avoid;
}
figure.image figcaption {
padding-left: 0;
margin-top: 0.2em;
-webkit-column-break-after: auto;
page-break-after: auto;
}
p + figure.listing,
span.principal + figure.listing {
margin-top: 0.75em; /* 0.75rem */
}
figure.listing > pre {
margin-top: 0;
}
/* REVIEW TODO put margin bottom on the figcaption instead */
figure.listing > figcaption + pre {
margin-top: 0.294em; /* 0.25rem */
}
aside.sidebar {
border: 1px solid #B3B3B1;
padding: 0 1.5em;
font-size: 0.9em;
background-color: #F2F2F2;
text-align: right; /* aligns heading to right */
/*
-webkit-box-shadow: 0px 1px 1px rgba(102, 102, 101, 0.15);
box-shadow: 0px 1px 1px rgba(102, 102, 101, 0.15);
*/
}
body:first-of-type aside.sidebar {
background-color: rgba(0, 0, 0, 0.05); /* using transparency is night-mode friendly */
/*background-color: rgba(51, 51, 50, 0.06);*/ /* using transparency is night-mode friendly */
}
/* a bit of a cheat; could use aside.sidebar[title] instead, but not on Aldiko */
aside.sidebar.titled {
margin-top: 2em;
}
aside.sidebar > h2 {
text-transform: uppercase; /* not supported in Adobe Digital Editions */
font-size: 1em;
/*
font-weight: 700;
*/
font-weight: 400;
letter-spacing: 0;
display: inline-block;
white-space: nowrap; /* for some reason it's wrapping prematurely */
border: 1px solid #B3B3B1;
padding: 1.5em .75em .5em .75em;
margin: -1em 0.5em -0.25em 0.5em;
background-color: #FFFFFF;
/*
-webkit-box-shadow: 0px 1px 1px rgba(102, 102, 101, 0.1);
box-shadow: 0px 1px 1px rgba(102, 102, 101, 0.1);
*/
}
/* doesn't work
body:first-of-type aside.sidebar > h2 {
background-color: rgba(255, 255, 255, 1);
}
*/
aside.sidebar > div.content {
margin-bottom: 1em;
text-align: justify; /* restore text alignment in content */
}
/* QUESTION same for ordered-list? */
aside.sidebar > div.content > div.itemized-list > ul {
margin-left: 0.5em !important;
}
div.blockquote {
padding: 0 1em;
margin: 1.25em auto;
}
/* display: table causes quotes to be repeated in Aldiko, so we hide this part */
div[class~="blockquote"] {
display: table;
}
blockquote > p {
color: #191918;
font-style: italic;
/*
font-size: 1.2em;
word-spacing: 0.1em;
*/
font-size: 1.15em;
word-spacing: 0.1em;
margin-top: 0;
line-height: 1.75;
}
blockquote > p:first-of-type::before {
display: inline-block;
color: #666665;
text-shadow: 0 1px 2px rgba(102, 102, 101, 0.3);
/* using serif quote from entypo */
font-family: "FontIcons";
/*content: "\f10e";*/ /* quote-right from Entypo */
/*
-webkit-transform: rotate(180deg);
transform: rotate(180deg);
padding-left: .3em;
padding-right: .2em;
*/
content: "\f10d"; /* quote-left, a flipped version of the quote-right from Entypo */
padding-right: .5em;
font-size: 1.5em;
line-height: 1.3;
margin-top: -0.5em;
vertical-align: text-bottom;
}
blockquote footer {
font-size: 0.9em;
font-style: italic;
margin-top: 0.5rem;
text-align: right;
}
blockquote footer .context {
font-size: 0.9em;
letter-spacing: -0.05em;
color: #666665;
}
pre {
text-align: left; /* fix for Namo */
margin-top: 1em; /* 0.85rem */
/*margin-top: 1.176em;*/ /* 1rem */
white-space: pre-wrap;
overflow-wrap: break-word; /* break in middle of long word if no other break opportunities are available */
font-size: 0.85em;
line-height: 1.4; /* matches what Kindle uses and can't go less */
background-color: #F2F2F2;
padding: 0.5rem 0.75rem;
/*
border-top: 3px solid #DCDCDE;
*/
/* QUESTION #B3B3B1? */
border-top: 1px solid #DCDCDE;
border-right: 1px solid #DCDCDE;
}
body:first-of-type pre {
background-color: rgba(0, 0, 0, 0.05); /* using transparency is night-mode friendly */
/*background-color: rgba(51, 51, 50, 0.06);*/ /* using transparency is night-mode friendly */
}
/* TODO what we really want is for pre w/o caption to be unbreakable */
pre.screen {
/*
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
*/
orphans: 3;
widows: 3; /* widows doesn't seem to work here */
}
pre.source {
orphans: 3;
widows: 3; /* widows doesn't seem to work here */
}
div.verse {
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
}
/* TODO we may want to reenable hyphens here, but not for kf8 */
div.verse > pre {
background-color: transparent;
border: none;
font-size: 1.2em;
text-align: center;
}
div.verse .attribution {
display: block;
margin-top: 1.4em;
}
aside.admonition {
margin-top: 1em;
padding: 1em;
border-left: 0.5em solid transparent;
-webkit-column-break-inside: avoid;
page-break-inside: avoid;
}
/* overrides for CSS3-enabled clients */
aside[class~="admonition"] {
margin: 1.5em 2em; /* even if admonition is at bottom of block, we want that extra space below */
padding: 0;
border-width: 0;
background: none !important;
}
aside.note {
border-left-color: #FFC14F;
background-color: #FFF0D4; /* 25% opacity of border */
}
aside.tip {
border-left-color: #40403E;
background-color: #D0D0CF; /* 25% opacity of border */
}
aside.caution {
border-left-color: #7F7F7D;
background-color: #DFDFDF; /* 25% opacity of border */
}
aside.warning {
border-left-color: #C83737;
background-color: #F1CECE; /* 25% opacity of border */
}
aside.important {
border-left-color: #F2642A;
background-color: #FCD9CA; /* 25% opacity of border */
}
aside.admonition::before {
display: block;
font-family: "FontAwesome";
font-size: 2em;
line-height: 1;