lit-reader 1.2.0__py3-none-any.whl

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.
lit_reader/reader.css ADDED
@@ -0,0 +1,443 @@
1
+ /* lit_reader: reading versions of papers.
2
+ ~65 characters a line, ~20px body, 1.5 line spacing, ragged right,
3
+ light or sepia by default, notes and page numbers in the margins. */
4
+
5
+ :root {
6
+ --bg: #fbfaf7; --fg: #1f1f1f; --muted: #6b6760; --faint: #e6e2da;
7
+ --accent: #8a3b12; --card: #ffffff; --mark: #fff3b0; --done: #2f6b2f;
8
+ --size: 20px; --lh: 1.5; --measure: 54ch;
9
+ --font: "Literata", "Iowan Old Style", Charter, Georgia, serif;
10
+ --ui: -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
11
+ --toc-w: 16rem; --margin-w: 15rem; --gap: 3.5rem;
12
+ --bar-h: 2.75rem;
13
+ }
14
+ @media (pointer: coarse) { :root { --bar-h: 3.25rem; } } /* room for 44px buttons */
15
+ :root[data-theme="sepia"] {
16
+ --bg: #f4ecd8; --fg: #3b2f22; --muted: #6f604c; --faint: #e3d7bd;
17
+ --accent: #8a3b12; --card: #fbf5e6; --mark: #f1dd8f; --done: #2f6b2f;
18
+ }
19
+ :root[data-theme="dark"] {
20
+ --bg: #1b1b1d; --fg: #dad7d0; --muted: #9a958c; --faint: #34332f;
21
+ --accent: #e0a37a; --card: #252527; --mark: #5a4b1c; --done: #6fbf73;
22
+ }
23
+ @media (prefers-color-scheme: dark) {
24
+ :root:not([data-theme]) {
25
+ --bg: #1b1b1d; --fg: #dad7d0; --muted: #9a958c; --faint: #34332f;
26
+ --accent: #e0a37a; --card: #252527; --mark: #5a4b1c; --done: #6fbf73;
27
+ }
28
+ }
29
+ :root[data-font="iowan"] { --font: "Iowan Old Style", Charter, Georgia, serif; }
30
+ :root[data-font="charter"] { --font: Charter, "Bitstream Charter", Georgia, serif; }
31
+ :root[data-font="sans"] { --font: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif; }
32
+
33
+ * { box-sizing: border-box; }
34
+ html { background: var(--bg); color: var(--fg); scroll-padding-top: calc(var(--bar-h) + 1.25rem); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
35
+ body {
36
+ margin: 0; background: var(--bg); color: var(--fg);
37
+ font-family: var(--font); font-size: var(--size); line-height: var(--lh);
38
+ font-optical-sizing: auto; -webkit-font-smoothing: antialiased;
39
+ font-kerning: normal; font-variant-ligatures: common-ligatures;
40
+ }
41
+ a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
42
+ a:focus-visible, button:focus-visible, summary:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
43
+ main:focus, main[tabindex]:focus-visible { outline: none; } /* the whole column; [tabindex]:focus-visible above would otherwise outline it after a key press */
44
+ .sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
45
+ .skip { position: fixed; top: -5rem; left: 1rem; z-index: 60; padding: .5rem .8rem; background: var(--card); border: 1px solid var(--accent); border-radius: 6px; font: 14px var(--ui); }
46
+ .skip:focus { top: .35rem; }
47
+
48
+ /* ---------- layout: contents | text | margin ---------- */
49
+ .layout {
50
+ display: grid;
51
+ grid-template-columns: var(--toc-w) minmax(0, var(--measure)) var(--margin-w);
52
+ column-gap: var(--gap);
53
+ justify-content: center;
54
+ padding: 0 1.5rem;
55
+ }
56
+ main { grid-column: 2; padding: calc(var(--bar-h) + 2.25rem) 0 8rem; min-width: 0; }
57
+
58
+ /* ---------- top bar ---------- */
59
+ .bar {
60
+ position: fixed; inset: 0 0 auto 0; height: var(--bar-h); z-index: 20;
61
+ display: flex; align-items: center; gap: .75rem; padding: 0 1rem;
62
+ background: color-mix(in srgb, var(--bg) 92%, transparent);
63
+ backdrop-filter: blur(6px);
64
+ font: 13px/1.2 var(--ui); color: var(--muted);
65
+ border-bottom: 1px solid var(--faint);
66
+ }
67
+ .bar .where { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
68
+ .bar button, .bar a.btn {
69
+ font: inherit; color: var(--fg); background: none; border: 1px solid var(--muted);
70
+ border-radius: 6px; padding: .3rem .6rem; cursor: pointer; text-decoration: none;
71
+ }
72
+ .bar a.btn, .bar a.nojs-toc { display: inline-flex; align-items: center; }
73
+ .bar a.btn { gap: .3em; } /* a flex item drops the label's leading space */
74
+ .bar a.nojs-toc { font: inherit; color: var(--fg); border: 1px solid var(--muted); border-radius: 6px; padding: .3rem .6rem; text-decoration: none; }
75
+
76
+ /* ---------- where no script runs (an iPhone's attachment preview):
77
+ links instead of buttons that would do nothing ---------- */
78
+ :root.js .nojs-toc { display: none; }
79
+ :root:not(.js) #toc-toggle, :root:not(.js) #aa, :root:not(.js) #clips,
80
+ :root:not(.js) .done-box, :root:not(.js) .au-toggle { display: none; }
81
+ :root:not(.js) .au-rest[hidden] { display: inline; }
82
+ @media (min-width: 981px) { :root:not(.js) .nojs-toc { display: none; } } /* the contents are already beside the text */
83
+ .bar button:hover { border-color: var(--muted); }
84
+ .progress { position: fixed; top: var(--bar-h); left: 0; height: 2px; background: var(--accent); width: 0; z-index: 21; }
85
+
86
+ /* ---------- settings panel ---------- */
87
+ .panel {
88
+ position: fixed; top: calc(var(--bar-h) + .5rem); right: 1rem; z-index: 30; width: min(21rem, calc(100vw - 2rem));
89
+ max-height: calc(100vh - var(--bar-h) - 1.5rem); max-height: calc(100dvh - var(--bar-h) - 1.5rem); overflow-y: auto; /* a phone held sideways */
90
+ background: var(--card); color: var(--fg); border: 1px solid var(--faint); border-radius: 10px;
91
+ padding: .9rem 1rem; font: 13px/1.4 var(--ui); box-shadow: 0 8px 30px rgba(0,0,0,.15);
92
+ }
93
+ .panel[hidden] { display: none; }
94
+ .panel .row { display: flex; align-items: center; justify-content: space-between; margin: .45rem 0; gap: .5rem; }
95
+ .panel .seg { display: flex; gap: .25rem; flex-wrap: wrap; justify-content: flex-end; align-items: center; }
96
+ .panel .seg button {
97
+ font: inherit; color: var(--fg); background: none; border: 1px solid var(--muted);
98
+ border-radius: 5px; padding: .2rem .5rem; cursor: pointer;
99
+ }
100
+ .panel .seg button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent); color: var(--bg); font-weight: 600; }
101
+ .panel .note { color: var(--muted); font-size: 12px; margin-top: .6rem; }
102
+
103
+ /* ---------- saved quotes ---------- */
104
+ .clips-panel { width: min(26rem, calc(100vw - 2rem)); }
105
+ .clip-removed { display: flex; align-items: center; gap: .6rem; color: var(--muted); border-top: 1px solid var(--faint); margin-top: .6rem; padding-top: .6rem; }
106
+ .clips-head { font-weight: 600; margin-bottom: .3rem; }
107
+ .clips-panel button {
108
+ font: inherit; color: var(--fg); background: none; border: 1px solid var(--muted);
109
+ border-radius: 5px; padding: .2rem .5rem; cursor: pointer;
110
+ }
111
+ .clips-panel .row { justify-content: flex-start; }
112
+ .clips-panel button.primary { border-color: var(--accent); color: var(--accent); font-weight: 600; }
113
+ .clips-kept { margin: 0 0 .2rem; }
114
+ .done-quotes { margin: .7rem 0 0; }
115
+ ol.clips { list-style: none; margin: .6rem 0 0; padding: 0; }
116
+ ol.clips li { border-top: 1px solid var(--faint); padding: .7rem 0; }
117
+ ol.clips blockquote { margin: 0; font-family: var(--font, inherit); font-size: 14px; line-height: 1.45; }
118
+ ol.clips .note { margin-top: .35rem; }
119
+ ol.clips .acts { display: flex; gap: .3rem; margin-top: .45rem; }
120
+ .clip-save {
121
+ position: absolute; z-index: 35; font: 600 13px/1 var(--ui); color: var(--bg); background: var(--accent);
122
+ border: 0; border-radius: 999px; padding: .45rem .8rem; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.2);
123
+ }
124
+ #clip-count:empty { display: none; }
125
+ @media print { .clip-save { display: none !important; } }
126
+
127
+ /* ---------- contents sidebar ---------- */
128
+ nav.toc {
129
+ grid-column: 1; position: sticky; top: var(--bar-h); align-self: start;
130
+ max-height: calc(100vh - var(--bar-h)); max-height: calc(100dvh - var(--bar-h)); overflow-y: auto;
131
+ padding: 2rem 0 2rem; font: 13.5px/1.35 var(--ui);
132
+ }
133
+ nav.toc ol { list-style: none; margin: 0; padding: 0; }
134
+ nav.toc li { margin: 0; }
135
+ nav.toc a {
136
+ display: flex; gap: .5rem; justify-content: space-between;
137
+ color: var(--muted); text-decoration: none; padding: .28rem .5rem; border-radius: 5px;
138
+ border-left: 2px solid transparent;
139
+ }
140
+ nav.toc a:hover { color: var(--fg); background: var(--faint); }
141
+ nav.toc a.current { color: var(--fg); border-left-color: var(--accent); background: color-mix(in srgb, var(--faint) 60%, transparent); }
142
+ nav.toc .l3 a { padding-left: 1.4rem; font-size: 12.5px; }
143
+ nav.toc .mins { flex: none; font-variant-numeric: tabular-nums; font-size: 11.5px; padding-top: .1rem; }
144
+ nav.toc .back { margin-top: .8rem; }
145
+ .toc-tools { display: none; } /* phones only, below */
146
+ nav.toc .toc-head { font-weight: 600; color: var(--fg); padding: 0 .5rem .6rem; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
147
+
148
+ /* ---------- header card ---------- */
149
+ header.paper { margin-bottom: 2.5rem; }
150
+ header.paper .kicker { font: 12px/1.4 var(--ui); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
151
+ header.paper h1 { font-size: 1.75em; line-height: 1.2; margin: .3em 0 .5em; font-weight: 600; text-wrap: balance; }
152
+ header.paper .authors { color: var(--fg); margin: 0 0 .5em; font-family: var(--ui); font-size: .78em; line-height: 1.45; }
153
+ .au-toggle { display: inline-flex; align-items: center; gap: .45em; margin-left: .25em; padding: .12em .7em; white-space: nowrap;
154
+ font: inherit; font-size: .9em; color: var(--fg); background: var(--card); border: 1px solid var(--muted); border-radius: 999px; cursor: pointer; }
155
+ .au-toggle:hover { background: var(--faint); }
156
+ .au-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
157
+ .au-chevron { width: .42em; height: .42em; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-.12em) rotate(45deg); }
158
+ .au-toggle[aria-expanded="true"] .au-chevron { transform: translateY(.12em) rotate(-135deg); }
159
+ @media print { .au-rest[hidden] { display: inline !important; } .au-toggle { display: none; } }
160
+ header.paper .part { font: 600 16px/1.45 var(--ui); color: var(--fg); margin: -.2em 0 .6em; }
161
+ header.paper .meta { font: 14px/1.5 var(--ui); color: var(--muted); }
162
+
163
+ /* ---------- body text ---------- */
164
+ main p, main li { hyphens: manual; -webkit-hyphens: manual; text-wrap: pretty; text-align: left; }
165
+ main p { margin: 0 0 .9em; }
166
+ main p, main li, figcaption, section.references li { overflow-wrap: break-word; }
167
+ main a { overflow-wrap: anywhere; }
168
+ main h2, main h3, main h4 { line-height: 1.25; text-wrap: balance; font-weight: 600; }
169
+ main h2 { font-size: 1.3em; margin: 2.2em 0 .6em; }
170
+ main h3 { font-size: 1.08em; margin: 1.8em 0 .5em; }
171
+ main h4 { font-size: 1em; font-style: italic; font-weight: 500; margin: 1.4em 0 .4em; }
172
+ .secno { color: var(--muted); font-weight: 400; margin-right: .35em; }
173
+ section.abstract {
174
+ background: var(--card); border: 1px solid var(--faint); border-radius: 8px;
175
+ padding: 1rem 1.25rem .4rem; margin: 0 0 2rem; font-size: .95em;
176
+ }
177
+ section.abstract h2 { margin: 0 0 .5rem; font: 600 12px/1.4 var(--ui); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
178
+ main ul, main ol { padding-left: 1.4em; margin: 0 0 .9em; }
179
+ main ul.plain { list-style: none; padding-left: 0; }
180
+ main li { margin: .2em 0; }
181
+ pre.listing {
182
+ font: 13px/1.45 ui-monospace, Menlo, monospace; white-space: pre-wrap; background: var(--card);
183
+ border: 1px solid var(--faint); border-radius: 6px; padding: .8rem 1rem; overflow-x: auto;
184
+ }
185
+ .eq { overflow-x: auto; margin: 0 0 .9em; text-align: center; }
186
+ .eq img { display: inline-block; max-width: 100%; height: auto; background: #fff; border-radius: 3px; }
187
+ math { font-size: 1em; }
188
+ math[display="block"] { display: block; max-width: 100%; overflow-x: auto; overflow-y: hidden; }
189
+ .eq math[display="block"] { display: inline-block; vertical-align: middle; }
190
+ .appendix-start { border-top: 1px solid var(--faint); margin-top: 4rem; padding-top: 1rem; }
191
+
192
+ /* ---------- citations ---------- */
193
+ a.cite { text-decoration: none; color: var(--accent); border-bottom: 1px dotted color-mix(in srgb, var(--accent) 60%, transparent); }
194
+ a.cite:hover { border-bottom-style: solid; }
195
+ .cite-card {
196
+ position: absolute; z-index: 40; max-width: 26rem; background: var(--card); color: var(--fg);
197
+ border: 1px solid var(--faint); border-radius: 8px; padding: .7rem .9rem;
198
+ font: 13.5px/1.45 var(--ui); box-shadow: 0 8px 30px rgba(0,0,0,.18);
199
+ }
200
+ .cite-card .go { display: block; margin-top: .4rem; font-size: 12px; }
201
+ .cite-card + .cite-card { margin-top: .3rem; }
202
+
203
+ /* ---------- sidenotes and page numbers (Tufte-style margins) ---------- */
204
+ .sn-mark { font: 600 .7em/0 var(--ui); color: var(--accent); cursor: pointer; vertical-align: super; padding: .35em .3em;
205
+ text-decoration: underline dotted; text-decoration-thickness: 1px; text-underline-offset: 2px; } /* tappable, like a citation */
206
+ .quiet-focus:focus { outline: none; } /* focus moved by a tap or click, not the keyboard */
207
+ .ref-back { display: block; margin-top: .4rem; font: 13px var(--ui); color: var(--accent); background: none; border: 1px solid var(--accent); border-radius: 6px; padding: .3rem .7rem; cursor: pointer; }
208
+ @media (pointer: coarse) { .ref-back { min-height: 2.75rem; } }
209
+ .sidenote {
210
+ float: right; clear: right; width: var(--margin-w);
211
+ margin-right: calc(-1 * (var(--margin-w) + var(--gap)));
212
+ font: 13px/1.45 var(--ui); color: var(--muted); margin-top: .25rem; margin-bottom: .8rem;
213
+ hyphens: manual;
214
+ }
215
+ td .sidenote, th .sidenote { float: none; display: block; width: auto; margin: .3rem 0 0; }
216
+ .sidenote.flash { background: var(--mark); color: var(--fg); }
217
+ .sidenote .n { color: var(--accent); font-weight: 600; margin-right: .3em; }
218
+ .pg {
219
+ float: left; clear: left; width: 3.2rem; margin-left: calc(-3.2rem - 1rem);
220
+ text-align: right; font: 11.5px/2 var(--ui); color: var(--muted);
221
+ user-select: none;
222
+ }
223
+ .pg a { color: inherit; text-decoration: none; }
224
+ .pg a:hover { text-decoration: underline; }
225
+
226
+ /* the printed page, offered where text may not have come through */
227
+ details.orig-page, details.table-text { margin: .4em 0 1.1em; font: 13px/1.4 var(--ui); color: var(--muted); }
228
+ details.table-text { margin: -1em 0 1.8em; } /* tucked under the figure it belongs to */
229
+ details.orig-page summary, details.table-text summary { cursor: pointer; display: inline-block; padding: .2rem .6rem; border: 1px solid var(--muted); border-radius: 999px; color: var(--fg); }
230
+ details.orig-page[open] summary, details.table-text[open] summary { margin-bottom: .5rem; }
231
+ details.orig-page .orig-note, details.table-text .orig-note { margin: 0 0 .5rem; }
232
+ details.table-text table.data { color: var(--fg); margin: 0; }
233
+ @media print { details.table-text { display: none; } }
234
+ details.orig-page img { display: block; max-width: 100%; height: auto; border: 1px solid var(--faint); border-radius: 4px; background: #fff; }
235
+ @media print { details.orig-page { display: none; } }
236
+
237
+ /* ---------- figures and tables ---------- */
238
+ figure { margin: 1.8em 0; }
239
+ figure img { display: block; max-width: 100%; height: auto; margin: 0 auto; border-radius: 4px; background: #fff; }
240
+ .fig-zoom { display: block; width: 100%; margin: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: zoom-in; }
241
+ figure.wide .fig-zoom { cursor: zoom-out; }
242
+
243
+ /* a figure full screen, on screens with no margin to widen into */
244
+ .viewer { position: fixed; inset: 0; z-index: 70; display: flex; flex-direction: column; background: var(--bg); color: var(--fg); }
245
+ .viewer-bar { display: flex; align-items: center; gap: .6rem; min-height: var(--bar-h); padding: 0 .75rem; border-bottom: 1px solid var(--faint); font: 14px/1.2 var(--ui); }
246
+ .viewer-title { flex: 1; font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
247
+ .viewer-bar button { font: inherit; color: var(--fg); background: none; border: 1px solid var(--muted); border-radius: 6px; padding: .3rem .7rem; cursor: pointer; min-height: 2.25rem; }
248
+ @media (pointer: coarse) { .viewer-bar button { min-height: 2.75rem; } }
249
+ .viewer-body { flex: 1; min-height: 0; overflow: auto; display: flex; padding: .75rem; }
250
+ .viewer-body img { display: block; margin: auto; max-width: 100%; max-height: 100%; width: auto; height: auto; background: #fff; border-radius: 4px; }
251
+ .viewer.full .viewer-body img { max-width: none; max-height: none; height: auto; }
252
+ figure.wide { margin-left: calc(-1 * var(--gap)); margin-right: calc(-1 * (var(--margin-w) + var(--gap))); }
253
+ figcaption .tnote { display: block; margin-top: .3em; font-size: .9em; }
254
+ figcaption { font: 14px/1.5 var(--ui); color: var(--muted); margin-top: .6rem; hyphens: manual; }
255
+ figcaption strong, figcaption b { font-weight: inherit; }
256
+ figcaption .label { font-weight: 600; color: var(--fg); margin-right: .3em; }
257
+ figcaption .pdf-link { white-space: nowrap; font-size: 12.5px; }
258
+ .missing-figure {
259
+ border: 1px dashed var(--faint); border-radius: 6px; padding: 1rem; font: 13px/1.4 var(--ui); color: var(--muted); text-align: center;
260
+ }
261
+ .tablewrap { overflow-x: auto; }
262
+ table.data { border-collapse: collapse; font: 13.5px/1.4 var(--ui); margin: 0 auto; }
263
+ table.data th, table.data td { border-bottom: 1px solid var(--faint); padding: .3rem .6rem; text-align: left; vertical-align: top; }
264
+ table.data thead th { border-bottom: 2px solid var(--muted); }
265
+ table.data table.data { margin: 0; font: inherit; } /* a label set as a table inside a cell */
266
+ table.data table.data td { border: 0; padding: 0; font-weight: 400; }
267
+
268
+ /* ---------- references ---------- */
269
+ section.references ol { font-size: .82em; line-height: 1.45; padding-left: 2.2em; }
270
+ section.references li { margin: 0 0 .55em; hyphens: none; }
271
+ section.references li:target, section.references li.flash { background: var(--mark); }
272
+ section.references summary { cursor: pointer; font: 14px var(--ui); color: var(--muted); margin-bottom: 1rem; }
273
+
274
+ /* ---------- end matter ---------- */
275
+ .done-box { margin: 3rem 0 0; padding: 1rem 1.2rem; border: 1px solid var(--faint); border-radius: 8px; font: 14px/1.5 var(--ui); color: var(--muted); }
276
+ .done-box button { font: inherit; padding: .35rem .8rem; border-radius: 6px; border: 1px solid var(--accent); background: none; color: var(--accent); cursor: pointer; }
277
+ footer.source { margin-top: 2rem; font: 12.5px/1.5 var(--ui); color: var(--muted); }
278
+ .toast {
279
+ position: fixed; bottom: 1.2rem; left: 50%; transform: translateX(-50%); z-index: 50;
280
+ width: max-content; max-width: calc(100vw - 2rem);
281
+ background: var(--card); border: 1px solid var(--faint); border-radius: 8px; padding: .55rem .9rem;
282
+ font: 13px var(--ui); box-shadow: 0 6px 20px rgba(0,0,0,.15);
283
+ }
284
+ .toast button { font: inherit; color: var(--accent); background: none; border: 0; cursor: pointer; text-decoration: underline; }
285
+ .flash-block { animation: flash 1.6s ease-out; }
286
+ @keyframes flash { from { background: var(--mark); } to { background: transparent; } }
287
+
288
+ /* ---------- narrower screens: margins fold in ---------- */
289
+ @media (max-width: 1260px) {
290
+ .layout { grid-template-columns: var(--toc-w) minmax(0, var(--measure)); }
291
+ .sidenote { display: none; float: none; width: auto; margin: .4rem 0 .8rem; padding: .5rem .8rem; background: var(--card); border-radius: 6px; }
292
+ .sidenote.open, :root:not(.js) .sidenote { display: block; } /* no script to open them: show them under their paragraph */
293
+ figure.wide { margin-right: 0; }
294
+ }
295
+ @media (max-width: 980px) {
296
+ .layout { grid-template-columns: minmax(0, var(--measure)); }
297
+ main { grid-column: 1; }
298
+ nav.toc {
299
+ position: fixed; top: var(--bar-h); left: 0; bottom: 0; width: 18rem; z-index: 25; max-height: none;
300
+ align-self: stretch; /* Chrome aligns fixed boxes too: "start" would size the drawer to its contents, past the screen */
301
+ background: var(--card); border-right: 1px solid var(--faint); padding: 1rem; transform: translateX(-105%);
302
+ transition: transform .2s ease;
303
+ }
304
+ nav.toc { visibility: hidden; }
305
+ nav.toc.open, :root:not(.js) nav.toc:target { transform: none; visibility: visible; } /* :target: opened by the plain link */
306
+ nav.toc.open ~ main { cursor: pointer; } /* iOS Safari passes a tap on text to the page's listener only on a clickable element */
307
+ .pg { float: none; display: block; width: auto; margin: 0; text-align: left; }
308
+ .pg::before { content: ""; display: block; border-top: 1px dashed var(--faint); margin: .3rem 0 0; }
309
+ figure.wide { margin-left: 0; }
310
+ }
311
+
312
+ /* ---------- wide screens: the contents can be put away ----------
313
+ Its column stays, empty, so the text doesn't move. */
314
+ @media (min-width: 981px) {
315
+ :root[data-toc="hidden"] nav.toc { display: none; }
316
+ }
317
+
318
+ /* ---------- phones ---------- */
319
+ @media (max-width: 600px) {
320
+ :root { --size: 18px; } /* the script sets the same default, or the reader's own choice */
321
+ .layout { padding: 0 1rem; }
322
+ main { padding: calc(var(--bar-h) + 1.25rem) 0 6rem; }
323
+ header.paper { margin-bottom: 2rem; }
324
+ header.paper h1 { font-size: 1.45em; }
325
+ /* The top bar is only the contents button and where you are, as thin as a finger allows.
326
+ All papers, Quotes and Aa sit at the top of the contents drawer instead. */
327
+ :root { --bar-h: 2.5rem; }
328
+ .bar { gap: .2rem; padding: 0 .75rem 0 0; }
329
+ .bar a.btn:not(.back-from), .bar #clips, body:not(.index) .bar #aa { display: none; } /* the index has no drawer: it keeps Aa */
330
+ .bar #toc-toggle, .bar a.nojs-toc { border: 0; border-radius: 0; min-height: var(--bar-h); min-width: 2.75rem; padding: 0; justify-content: center; font-size: 17px; }
331
+ #toc-toggle .lbl, .nojs-toc .lbl { display: none; }
332
+ .toc-tools { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 0 .9rem; margin: 0 0 .9rem; border-bottom: 1px solid var(--faint); }
333
+ .toc-tools button, .toc-tools a.btn {
334
+ font: 14px/1.2 var(--ui); color: var(--fg); background: none; border: 1px solid var(--muted); border-radius: 6px;
335
+ min-height: 2.75rem; min-width: 2.75rem; padding: .35rem .55rem; justify-content: center; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: .3em;
336
+ }
337
+ .toc-tools a.tools-all { flex-basis: 100%; justify-content: flex-start; } /* its own row: the three don't fit on one */
338
+ .toc-tools .place { color: var(--muted); }
339
+ .toc-tools .lbl + .place::before { content: "·"; margin-right: .3em; }
340
+ :root:not(.js) .toc-tools button { display: none; }
341
+ :root:not(.js) .toc-tools:not(:has(a)) { display: none; } /* a single file without its script: nothing left in the row */
342
+ .index .bar #aa { min-height: 2.25rem; padding-top: 0; padding-bottom: 0; } /* inside the thinner bar */
343
+ .panel .row-width { display: none; } /* the screen is already narrower than any line length */
344
+ nav.toc { width: min(20rem, 85vw); }
345
+ .cite-card { /* a sheet along the bottom, clear of the text being read */
346
+ position: fixed; top: auto !important; left: 0 !important; right: 0; bottom: 0; z-index: 55;
347
+ max-width: none; max-height: 60vh; overflow-y: auto; border-radius: 12px 12px 0 0;
348
+ padding: 1rem 1.1rem 1.4rem; font-size: 15px;
349
+ }
350
+ }
351
+
352
+ /* ---------- touch: targets big enough for a finger ---------- */
353
+ @media (pointer: coarse) {
354
+ .bar button, .bar a.btn, .bar a.nojs-toc { min-height: 2.75rem; min-width: 2.75rem; padding: .35rem .7rem; justify-content: center; }
355
+ .panel .seg button, .clips-panel button { min-height: 2.75rem; min-width: 2.75rem; padding: .3rem .65rem; }
356
+ .panel .row { margin: .6rem 0; }
357
+ nav.toc a { padding: .55rem .5rem; }
358
+ .sn-mark { padding: .6em .45em; }
359
+ .clip-save { padding: .75rem 1.1rem; font-size: 15px; }
360
+ .cite-card .go { padding: .5rem 0; }
361
+ details.orig-page summary, details.table-text summary { padding: .45rem .8rem; min-height: 2.75rem; display: inline-flex; align-items: center; }
362
+ }
363
+
364
+ @media (prefers-reduced-motion: reduce) {
365
+ nav.toc, .bar, .progress { transition: none; }
366
+ .flash-block { animation: none; }
367
+ }
368
+
369
+ /* ---------- index page ---------- */
370
+ .index main { grid-column: 1 / -1; max-width: 46rem; margin: 0 auto; }
371
+ .index .layout { display: block; }
372
+ .list h2 { font-size: 1.15em; margin: 2.2em 0 .3em; }
373
+ .list .listnote { font: 14px/1.5 var(--ui); color: var(--muted); margin: 0 0 1rem; }
374
+ .list ol { list-style: none; padding: 0; margin: 0; }
375
+ .list li { display: grid; grid-template-columns: 2rem 1fr auto; gap: .2rem .8rem; padding: .9rem 0; border-top: 1px solid var(--faint); }
376
+ .list .n { font: 600 14px/1.9 var(--ui); color: var(--muted); }
377
+ .list .t { font-weight: 600; line-height: 1.3; }
378
+ .list .t a { color: var(--fg); text-decoration: none; }
379
+ .list .t a:hover { color: var(--accent); }
380
+ .list .d { grid-column: 2; font: 13.5px/1.45 var(--ui); color: var(--muted); }
381
+ .list .s { grid-row: 1; grid-column: 3; font: 12px/1.9 var(--ui); color: var(--muted); white-space: nowrap; }
382
+ .list .s.started { color: var(--accent); }
383
+ .list .s.done { color: var(--done); } /* 6.2:1 light, 5.5:1 sepia, 7.7:1 dark */
384
+ .list .nofile .t { color: var(--muted); font-weight: 500; }
385
+ .bundle-quotes h2 { font-size: 1.15em; margin: 2.6em 0 .3em; }
386
+ .bundle-quotes .listnote { font: 14px/1.5 var(--ui); color: var(--muted); margin: 0 0 .8rem; }
387
+ .bundle-quotes .row { display: flex; flex-wrap: wrap; gap: .5rem; }
388
+ .bundle-quotes button {
389
+ font: 14px/1.2 var(--ui); color: var(--fg); background: none; border: 1px solid var(--muted);
390
+ border-radius: 6px; padding: .4rem .8rem; cursor: pointer;
391
+ }
392
+ .bundle-quotes button.primary { border-color: var(--accent); color: var(--accent); font-weight: 600; }
393
+ @media (pointer: coarse) { .bundle-quotes button { min-height: 2.75rem; } }
394
+
395
+ /* ---------- bundles: a paper's place, and references to the other papers ---------- */
396
+ .bar a.btn .place { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
397
+ .bar a.btn .lbl + .place::before { content: "·"; margin-right: .3em; }
398
+ .in-bundle { display: block; margin-top: .2rem; font: 13px/1.4 var(--ui); color: var(--muted); }
399
+ .in-bundle a { color: var(--accent); }
400
+
401
+ /* ---------- print ---------- */
402
+ @media print {
403
+ .bar, .progress, nav.toc, .panel, .toast, .done-box, .cite-card, .ref-back, .viewer { display: none !important; }
404
+ .layout { display: block; padding: 0; }
405
+ main { padding: 0; }
406
+ body { font-size: 11pt; background: #fff; color: #000; }
407
+ .sidenote { display: block; float: none; width: auto; margin: .2rem 0 .6rem 1.5rem; color: #333; }
408
+ .pg { float: none; display: inline; margin: 0; width: auto; font-size: 8pt; }
409
+ .pg::before { content: "["; display: inline; border: 0; margin: 0; } .pg::after { content: "]"; }
410
+ a { color: #000; text-decoration: none; }
411
+ figure { break-inside: avoid; }
412
+ }
413
+
414
+ /* ---------- shorter paragraphs ----------
415
+ Long paragraphs are split at sentence ends when the page is built. A split
416
+ gets a smaller gap than a real paragraph break, so the published structure
417
+ stays visible. "As published" in the settings joins them back. */
418
+ main p, section.abstract p { margin-bottom: 1.15em; }
419
+ .chunk { display: block; }
420
+ .chunk + .chunk { margin-top: .5em; }
421
+ :root[data-para="orig"] .chunk { display: inline; }
422
+ :root[data-para="orig"] .chunk + .chunk { margin-top: 0; }
423
+ :root[data-para="orig"] main p { margin-bottom: .9em; }
424
+
425
+ /* ---------- on a phone the bar steps aside while reading on (reader.js) ---------- */
426
+ @media (prefers-reduced-motion: no-preference) {
427
+ .bar { transition: transform .2s ease; }
428
+ .progress { transition: top .2s ease; }
429
+ }
430
+ :root.bar-away .bar { transform: translateY(-100%); }
431
+ :root.bar-away .progress { top: 0; }
432
+
433
+ /* ---------- the way back after following a reference to another paper of the bundle ---------- */
434
+ .bar a.back-from { color: var(--accent); border-color: var(--accent); white-space: nowrap; max-width: 14rem; overflow: hidden; text-overflow: ellipsis; display: inline-block; }
435
+
436
+ /* ---------- the index on a phone: off the edge, and titles get the width ---------- */
437
+ @media (max-width: 600px) {
438
+ .index .bar { padding: 0 .6rem 0 1rem; }
439
+ .list li { grid-template-columns: 1.6rem 1fr; }
440
+ .list .s { grid-row: auto; grid-column: 2; }
441
+ .list .s:empty { display: none; }
442
+ .bar a.back-from { min-height: 2.25rem; min-width: 0; padding: .45rem .55rem; max-width: 45vw; margin-left: .5rem; } /* inside the thinner bar, off the screen's edge */
443
+ }