pi-scenes 0.11.1 → 0.13.0
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/README.md +17 -1
- package/assets/scene-prompts/learning/notes.md +20 -0
- package/assets/scene-prompts/productivity/task-review.md +10 -0
- package/assets/scene-skills/data/validate-data/SKILL.md +383 -0
- package/assets/scene-skills/data/write-query/SKILL.md +122 -0
- package/assets/scene-skills/learning/course-book/SKILL.md +157 -0
- package/assets/scene-skills/learning/course-book/annotate.js +522 -0
- package/assets/scene-skills/learning/course-book/assets/book.css +1167 -0
- package/assets/scene-skills/learning/course-book/assets/paging.js +234 -0
- package/assets/scene-skills/learning/course-book/book.css +1167 -0
- package/assets/scene-skills/learning/course-book/build.py +277 -0
- package/assets/scene-skills/learning/course-book/paging.js +234 -0
- package/assets/scene-skills/learning/eli5/SKILL.md +26 -0
- package/assets/scene-skills/pm/sprint-planning/SKILL.md +94 -0
- package/assets/scene-skills/pm/write-spec/SKILL.md +250 -0
- package/assets/scene-skills/productivity/task-management/SKILL.md +91 -0
- package/extensions/scenes.ts +256 -8
- package/package.json +35 -35
|
@@ -0,0 +1,1167 @@
|
|
|
1
|
+
/* course-book · 经典版画风格技术书排版 + 打印规则
|
|
2
|
+
* 类目契约见 SKILL.md;颜色体系:暖白纸面 + 锈红强调 + 沙色代码底
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
:root {
|
|
6
|
+
--paper: #fffdf8;
|
|
7
|
+
--ink: #191714;
|
|
8
|
+
--ink-soft: #4a453d;
|
|
9
|
+
--ink-faint: #8a8272;
|
|
10
|
+
--accent: #a03b2a; /* 锈红 */
|
|
11
|
+
--accent-deep: #7c2d20;
|
|
12
|
+
--sand: #f5f0e4; /* 代码底 */
|
|
13
|
+
--rule: #d9d2c0; /* 分隔线 */
|
|
14
|
+
--note-bg: #eef2f6; --note-bar: #3d5a73;
|
|
15
|
+
--tip-bg: #edf5ec; --tip-bar: #3f7a3f;
|
|
16
|
+
--warn-bg: #faf0e6; --warn-bar: #b0541f;
|
|
17
|
+
--serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia,
|
|
18
|
+
"Noto Serif SC", "Source Han Serif SC", "Songti SC", SimSun, serif;
|
|
19
|
+
--sans: "Avenir Next", "Segoe UI", "Helvetica Neue", Arial,
|
|
20
|
+
"PingFang SC", "Microsoft YaHei", sans-serif;
|
|
21
|
+
--mono: ui-monospace, "SF Mono", Menlo, Consolas, "Cascadia Mono",
|
|
22
|
+
"Noto Sans Mono CJK SC", monospace;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
* { box-sizing: border-box; }
|
|
26
|
+
|
|
27
|
+
body {
|
|
28
|
+
margin: 0; background: var(--paper); color: var(--ink);
|
|
29
|
+
font: 17px/1.85 var(--serif);
|
|
30
|
+
text-rendering: optimizeLegibility;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/* ---------- 书页容器 ---------- */
|
|
34
|
+
.book { max-width: 46em; margin: 0 auto; padding: 4rem 1.5rem 6rem; }
|
|
35
|
+
|
|
36
|
+
/* ---------- 封面 ---------- */
|
|
37
|
+
.cover { padding: 6rem 0 4rem; border-bottom: 3px double var(--ink); }
|
|
38
|
+
.cover .book-kicker { font: 600 13px/1 var(--sans); letter-spacing: .35em;
|
|
39
|
+
text-transform: uppercase; color: var(--accent); margin: 0 0 2.2rem; }
|
|
40
|
+
.cover h1 { font: 800 clamp(34px, 6vw, 52px)/1.15 var(--sans); margin: 0 0 1rem;
|
|
41
|
+
letter-spacing: -0.01em; }
|
|
42
|
+
.cover .subtitle { font: italic 400 20px/1.5 var(--serif); color: var(--ink-soft);
|
|
43
|
+
margin: 0 0 3rem; }
|
|
44
|
+
.cover .authors { font: 14px/1.9 var(--sans); color: var(--ink-soft); }
|
|
45
|
+
.cover .edition { font: 12px/1 var(--sans); color: var(--ink-faint);
|
|
46
|
+
margin-top: 4rem; letter-spacing: .08em; }
|
|
47
|
+
.cover-mark { display: inline-block; width: 54px; height: 54px; margin-bottom: 2.4rem;
|
|
48
|
+
border: 3px solid var(--accent); border-radius: 50%;
|
|
49
|
+
background: radial-gradient(circle at 38% 34%, var(--accent) 0 26%, transparent 27%),
|
|
50
|
+
conic-gradient(from 210deg, transparent 0 22%, var(--accent) 23% 26%,
|
|
51
|
+
transparent 27% 48%, var(--accent) 49% 52%, transparent 53% 74%,
|
|
52
|
+
var(--accent) 75% 78%, transparent 79%); }
|
|
53
|
+
|
|
54
|
+
/* ---------- 目录 ---------- */
|
|
55
|
+
nav.toc { padding: 2.5rem 0; border-bottom: 1px solid var(--rule); }
|
|
56
|
+
nav.toc h2 { font: 700 13px/1 var(--sans); letter-spacing: .3em; text-transform: uppercase;
|
|
57
|
+
color: var(--ink-faint); margin: 0 0 1.2rem; }
|
|
58
|
+
nav.toc ol { list-style: none; margin: 0; padding: 0; }
|
|
59
|
+
nav.toc li { margin: .45rem 0; }
|
|
60
|
+
nav.toc a { color: var(--ink); text-decoration: none; border-bottom: 1px dotted var(--rule); }
|
|
61
|
+
nav.toc a:hover { color: var(--accent); }
|
|
62
|
+
nav.toc .toc-status { font: 600 10px/1 var(--sans); color: var(--warn-bar);
|
|
63
|
+
letter-spacing: .1em; margin-left: .6em; vertical-align: 2px; }
|
|
64
|
+
|
|
65
|
+
/* ---------- 章 ---------- */
|
|
66
|
+
.chapter { padding-top: 1rem; }
|
|
67
|
+
.chapter-opener { margin: 4.5rem 0 2.5rem; }
|
|
68
|
+
.kicker { font: 700 13px/1 var(--sans); letter-spacing: .35em; text-transform: uppercase;
|
|
69
|
+
color: var(--accent); margin: 0 0 1rem; }
|
|
70
|
+
.chapter-opener h1 { font: 800 30px/1.25 var(--sans); margin: 0 0 1rem;
|
|
71
|
+
letter-spacing: -0.01em; }
|
|
72
|
+
.abstract { font: italic 400 17px/1.7 var(--serif); color: var(--ink-soft);
|
|
73
|
+
margin: 0; padding-left: 1.2rem; border-left: 3px solid var(--accent); }
|
|
74
|
+
|
|
75
|
+
h2 { font: 700 20px/1.4 var(--sans); margin: 2.8rem 0 1rem; letter-spacing: .01em; }
|
|
76
|
+
h3 { font: 700 16.5px/1.4 var(--sans); margin: 2rem 0 .8rem; }
|
|
77
|
+
p { margin: 0 0 1.1rem; }
|
|
78
|
+
a { color: var(--accent-deep); }
|
|
79
|
+
strong { font-weight: 700; }
|
|
80
|
+
hr { border: 0; border-top: 1px solid var(--rule); margin: 2.5rem 0; }
|
|
81
|
+
|
|
82
|
+
/* ---------- 学习目标 ---------- */
|
|
83
|
+
.lo { background: var(--sand); border: 1px solid var(--rule); border-radius: 6px;
|
|
84
|
+
padding: 1rem 1.4rem; margin: 0 0 2rem; }
|
|
85
|
+
.lo-title { font: 700 12px/1 var(--sans); letter-spacing: .25em; text-transform: uppercase;
|
|
86
|
+
color: var(--accent-deep); margin: 0 0 .6rem; }
|
|
87
|
+
.lo ul { margin: 0; padding-left: 1.2em; }
|
|
88
|
+
.lo li { margin: .25rem 0; }
|
|
89
|
+
|
|
90
|
+
/* ---------- 例题与代码 ---------- */
|
|
91
|
+
.example { margin: 1.8rem 0; }
|
|
92
|
+
.ex-head { font: 700 12.5px/1.4 var(--sans); color: var(--ink-soft);
|
|
93
|
+
margin: 0 0 .4rem; letter-spacing: .04em; }
|
|
94
|
+
pre { font: 13.5px/1.65 var(--mono); background: var(--sand);
|
|
95
|
+
border: 1px solid var(--rule); border-left: 3px solid var(--accent);
|
|
96
|
+
border-radius: 4px; padding: .9rem 1.1rem; overflow-x: auto; margin: 0; }
|
|
97
|
+
code { font: 0.92em var(--mono); background: var(--sand);
|
|
98
|
+
padding: .08em .35em; border-radius: 3px; }
|
|
99
|
+
pre code { background: none; padding: 0; }
|
|
100
|
+
samp { font: 0.92em var(--mono); color: var(--ink-soft); }
|
|
101
|
+
|
|
102
|
+
/* ---------- callout ---------- */
|
|
103
|
+
.callout { border-radius: 4px; padding: .9rem 1.2rem; margin: 1.6rem 0;
|
|
104
|
+
border-left: 4px solid; }
|
|
105
|
+
.callout .co-label { font: 700 12px/1 var(--sans); letter-spacing: .25em;
|
|
106
|
+
text-transform: uppercase; margin: 0 0 .5rem; }
|
|
107
|
+
.callout p:last-child { margin-bottom: 0; }
|
|
108
|
+
.callout.note { background: var(--note-bg); border-color: var(--note-bar); }
|
|
109
|
+
.callout.note .co-label { color: var(--note-bar); }
|
|
110
|
+
.callout.tip { background: var(--tip-bg); border-color: var(--tip-bar); }
|
|
111
|
+
.callout.tip .co-label { color: var(--tip-bar); }
|
|
112
|
+
.callout.warning { background: var(--warn-bg); border-color: var(--warn-bar); }
|
|
113
|
+
.callout.warning .co-label { color: var(--warn-bar); }
|
|
114
|
+
|
|
115
|
+
/* ---------- 练习 ---------- */
|
|
116
|
+
.exercise { border: 1.5px solid var(--rule); border-radius: 6px;
|
|
117
|
+
padding: 1.1rem 1.4rem; margin: 2rem 0; background: #fffefb; }
|
|
118
|
+
.exercise .ex-head { color: var(--accent-deep); font-size: 13.5px; }
|
|
119
|
+
.exercise ol, .exercise ul { margin: .4rem 0 .6rem; padding-left: 1.4em; }
|
|
120
|
+
details.answer { margin-top: .8rem; border-top: 1px dashed var(--rule); padding-top: .7rem; }
|
|
121
|
+
details.answer summary { font: 600 13px/1 var(--sans); color: var(--ink-faint);
|
|
122
|
+
cursor: pointer; letter-spacing: .05em; }
|
|
123
|
+
details.answer[open] summary { color: var(--accent-deep); margin-bottom: .6rem; }
|
|
124
|
+
|
|
125
|
+
/* ---------- 图与表 ---------- */
|
|
126
|
+
.figure { margin: 2rem 0; text-align: center; }
|
|
127
|
+
.figure pre { text-align: left; display: inline-block; min-width: 60%; }
|
|
128
|
+
.figure figcaption, .tablewrap caption { font: italic 400 13.5px/1.5 var(--serif);
|
|
129
|
+
color: var(--ink-soft); margin-top: .7rem; text-align: center; }
|
|
130
|
+
.tablewrap { margin: 2rem 0; overflow-x: auto; }
|
|
131
|
+
table { border-collapse: collapse; margin: 0 auto; font-size: 15px; }
|
|
132
|
+
th { font: 700 13px/1.4 var(--sans); text-align: left; padding: .5rem .9rem;
|
|
133
|
+
border-top: 2.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); }
|
|
134
|
+
td { padding: .45rem .9rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
|
|
135
|
+
tr:last-child td { border-bottom: 2.5px solid var(--ink); }
|
|
136
|
+
|
|
137
|
+
/* ---------- 数学公式块 ---------- */
|
|
138
|
+
.formula-block {
|
|
139
|
+
text-align: center;
|
|
140
|
+
margin: 1.6rem auto;
|
|
141
|
+
padding: .9rem 1.4rem;
|
|
142
|
+
background: var(--paper-warm);
|
|
143
|
+
border: 1px solid var(--rule);
|
|
144
|
+
border-radius: 6px;
|
|
145
|
+
font: 500 18px/1.8 var(--serif);
|
|
146
|
+
color: var(--ink);
|
|
147
|
+
letter-spacing: .02em;
|
|
148
|
+
}
|
|
149
|
+
.formula-block .frac {
|
|
150
|
+
display: inline-block;
|
|
151
|
+
vertical-align: middle;
|
|
152
|
+
text-align: center;
|
|
153
|
+
font-size: 0.88em;
|
|
154
|
+
margin: 0 .35em;
|
|
155
|
+
line-height: 1.1;
|
|
156
|
+
}
|
|
157
|
+
.formula-block .frac .num {
|
|
158
|
+
display: block;
|
|
159
|
+
border-bottom: 1.5px solid var(--ink);
|
|
160
|
+
padding: 0 .25em .15em;
|
|
161
|
+
}
|
|
162
|
+
.formula-block .frac .den {
|
|
163
|
+
display: block;
|
|
164
|
+
padding: .15em .25em 0;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* ---------- 小结与术语 ---------- */
|
|
168
|
+
.summary { border-top: 2.5px solid var(--ink); margin-top: 3rem; padding-top: 1rem; }
|
|
169
|
+
.summary h2 { margin-top: .4rem; font-size: 17px; }
|
|
170
|
+
.vocab { display: grid; grid-template-columns: max-content 1fr; gap: .45rem 1.4rem;
|
|
171
|
+
margin: 2rem 0 0; font-size: 15px; }
|
|
172
|
+
.vocab dt { font-weight: 700; }
|
|
173
|
+
.vocab dd { margin: 0; color: var(--ink-soft); }
|
|
174
|
+
|
|
175
|
+
/* ---------- 屏幕专用 ---------- */
|
|
176
|
+
.build-bar { font: 12px/1 var(--sans); color: var(--ink-faint); text-align: right;
|
|
177
|
+
padding: 1rem 0; letter-spacing: .05em; }
|
|
178
|
+
|
|
179
|
+
/* ---------- 打印 ---------- */
|
|
180
|
+
@media print {
|
|
181
|
+
@page { size: A4; margin: 22mm 17mm 20mm; }
|
|
182
|
+
body { font-size: 10.5pt; line-height: 1.68; background: #fff; }
|
|
183
|
+
.book { max-width: none; padding: 0; }
|
|
184
|
+
.build-bar { display: none; }
|
|
185
|
+
.cover { page-break-after: always; padding: 60mm 0 0; border-bottom: none; }
|
|
186
|
+
nav.toc { page-break-after: always; border-bottom: none; }
|
|
187
|
+
.chapter { page-break-before: always; }
|
|
188
|
+
.chapter-opener { margin-top: 0; }
|
|
189
|
+
h2, h3, h4 { page-break-after: avoid; }
|
|
190
|
+
.lo, .callout, .exercise, .figure, .tablewrap { page-break-inside: avoid; }
|
|
191
|
+
.example .ex-head { page-break-after: avoid; }
|
|
192
|
+
p { orphans: 3; widows: 3; }
|
|
193
|
+
pre { font-size: 8.8pt; line-height: 1.5; white-space: pre-wrap; }
|
|
194
|
+
a { color: inherit; text-decoration: none; }
|
|
195
|
+
nav.toc .toc-status { display: none; }
|
|
196
|
+
details.answer { display: none; } /* 学生版打印;教师版注释掉此行 */
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
/* ---------- 标注层(annotate.js 运行时注入的 DOM) ---------- */
|
|
200
|
+
mark.cb-anno {
|
|
201
|
+
background: color-mix(in srgb, var(--anno-color, #b0541f) 16%, transparent);
|
|
202
|
+
color: inherit; padding: .05em .15em; border-radius: 3px;
|
|
203
|
+
border-bottom: 2px solid color-mix(in srgb, var(--anno-color) 55%, transparent);
|
|
204
|
+
cursor: pointer;
|
|
205
|
+
}
|
|
206
|
+
mark.cb-anno:hover { background: color-mix(in srgb, var(--anno-color) 28%, transparent); }
|
|
207
|
+
mark.cb-anno.resolved {
|
|
208
|
+
background: transparent; border-bottom: 2px dotted color-mix(in srgb, var(--anno-color) 40%, transparent);
|
|
209
|
+
opacity: .75;
|
|
210
|
+
}
|
|
211
|
+
@keyframes cb-flash-k { 0%,100% { box-shadow: none; } 25% { box-shadow: 0 0 0 5px color-mix(in srgb, var(--anno-color) 35%, transparent); } }
|
|
212
|
+
mark.cb-anno.cb-flash { animation: cb-flash-k 1.5s ease; }
|
|
213
|
+
|
|
214
|
+
.cb-float {
|
|
215
|
+
position: absolute; z-index: 60; padding: .45rem .9rem; border: none; border-radius: 999px;
|
|
216
|
+
background: var(--ink); color: var(--paper); font: 600 13px/1 var(--sans);
|
|
217
|
+
box-shadow: 0 4px 14px rgba(0,0,0,.25); cursor: pointer;
|
|
218
|
+
}
|
|
219
|
+
.cb-float:hover { background: var(--accent-deep); }
|
|
220
|
+
|
|
221
|
+
.cb-dialog {
|
|
222
|
+
position: fixed; inset: 0; z-index: 100; background: rgba(25,23,20,.45);
|
|
223
|
+
display: grid; place-items: center; backdrop-filter: blur(2px);
|
|
224
|
+
}
|
|
225
|
+
.cb-card {
|
|
226
|
+
width: min(560px, calc(100vw - 2.5rem)); background: var(--paper); border-radius: 10px;
|
|
227
|
+
padding: 1.4rem 1.6rem; box-shadow: 0 18px 50px rgba(0,0,0,.35);
|
|
228
|
+
border-top: 4px solid var(--accent);
|
|
229
|
+
}
|
|
230
|
+
.cb-quote {
|
|
231
|
+
font: italic 400 13.5px/1.6 var(--serif); color: var(--ink-soft);
|
|
232
|
+
margin: 0 0 .9rem; padding: .5rem .8rem; background: var(--sand); border-radius: 5px;
|
|
233
|
+
max-height: 5.2em; overflow: auto;
|
|
234
|
+
}
|
|
235
|
+
.cb-types { display: flex; gap: .45rem; flex-wrap: wrap; margin-bottom: .7rem; }
|
|
236
|
+
.cb-type {
|
|
237
|
+
border: 1.5px solid var(--rule); background: #fff; border-radius: 999px;
|
|
238
|
+
padding: .35rem .8rem; font: 600 12.5px/1 var(--sans); color: var(--ink-soft); cursor: pointer;
|
|
239
|
+
}
|
|
240
|
+
.cb-type.on { border-color: var(--accent); color: var(--accent-deep); background: var(--sand); }
|
|
241
|
+
.cb-note {
|
|
242
|
+
width: 100%; min-height: 96px; resize: vertical; border: 1.5px solid var(--rule); border-radius: 6px;
|
|
243
|
+
padding: .7rem .9rem; font: 15px/1.7 var(--serif); background: #fff; color: var(--ink);
|
|
244
|
+
}
|
|
245
|
+
.cb-note:focus { outline: 2px solid var(--accent); border-color: transparent; }
|
|
246
|
+
.cb-dispo { display: flex; align-items: center; gap: .7rem; margin: .8rem 0 0; }
|
|
247
|
+
.cb-lbl { font: 600 12px/1 var(--sans); color: var(--ink-faint); letter-spacing: .08em; }
|
|
248
|
+
.cb-dispo-sel {
|
|
249
|
+
flex: 1; border: 1.5px solid var(--rule); border-radius: 6px; padding: .45rem .6rem;
|
|
250
|
+
font: 13.5px/1 var(--sans); background: #fff; color: var(--ink);
|
|
251
|
+
}
|
|
252
|
+
.cb-hint { font: 12px/1.5 var(--sans); color: var(--ink-faint); margin: .6rem 0 0; }
|
|
253
|
+
.cb-actions { display: flex; justify-content: flex-end; gap: .6rem; margin-top: 1rem; }
|
|
254
|
+
.cb-btn {
|
|
255
|
+
border: none; border-radius: 6px; padding: .55rem 1.1rem; font: 600 13.5px/1 var(--sans);
|
|
256
|
+
cursor: pointer;
|
|
257
|
+
}
|
|
258
|
+
.cb-btn.ghost { background: transparent; color: var(--ink-soft); border: 1.5px solid var(--rule); }
|
|
259
|
+
.cb-btn.primary { background: var(--accent); color: #fff; }
|
|
260
|
+
.cb-btn.primary:hover { background: var(--accent-deep); }
|
|
261
|
+
|
|
262
|
+
.cb-panel { position: fixed; top: 0; right: 0; z-index: 70; font-family: var(--sans); }
|
|
263
|
+
.cb-toggle {
|
|
264
|
+
position: fixed; top: 1.1rem; right: 1.1rem; z-index: 71; border: 1.5px solid var(--rule);
|
|
265
|
+
background: var(--paper); border-radius: 999px; padding: .5rem .95rem; cursor: pointer;
|
|
266
|
+
font: 600 14px/1 var(--sans); color: var(--ink-soft); box-shadow: 0 3px 10px rgba(0,0,0,.12);
|
|
267
|
+
}
|
|
268
|
+
.cb-count { display: inline-block; min-width: 1.2em; text-align: center; }
|
|
269
|
+
.cb-count.any {
|
|
270
|
+
background: var(--accent); color: #fff; border-radius: 999px; padding: .1rem .45rem;
|
|
271
|
+
font-size: 11.5px; animation: cb-pulse 2s ease infinite;
|
|
272
|
+
}
|
|
273
|
+
@keyframes cb-pulse { 50% { transform: scale(1.12); } }
|
|
274
|
+
.cb-body {
|
|
275
|
+
position: fixed; top: 0; right: 0; height: 100vh; width: 340px; overflow-y: auto;
|
|
276
|
+
background: var(--paper); border-left: 1.5px solid var(--rule); box-shadow: -8px 0 24px rgba(0,0,0,.08);
|
|
277
|
+
padding: 1.1rem 1.2rem; transform: translateX(100%); transition: transform .25s ease;
|
|
278
|
+
}
|
|
279
|
+
.cb-panel.open .cb-body { transform: none; }
|
|
280
|
+
.cb-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: .6rem; }
|
|
281
|
+
.cb-head strong { font-size: 15px; }
|
|
282
|
+
.cb-sum { font: 12px/1 var(--sans); color: var(--ink-faint); }
|
|
283
|
+
.cb-list { list-style: none; margin: 0; padding: 0; }
|
|
284
|
+
.cb-list li {
|
|
285
|
+
border: 1.5px solid var(--rule); border-left: 4px solid var(--anno-color, var(--rule));
|
|
286
|
+
border-radius: 6px; padding: .7rem .85rem; margin: .55rem 0; cursor: pointer; background: #fffefb;
|
|
287
|
+
}
|
|
288
|
+
.cb-list li:hover { border-color: var(--anno-color); }
|
|
289
|
+
.cb-list li.resolved { opacity: .68; border-left-style: dotted; background: transparent; }
|
|
290
|
+
.cb-li-head { display: flex; gap: .5rem; align-items: baseline; font: 600 12.5px/1 var(--sans); margin: 0 0 .35rem; }
|
|
291
|
+
.cb-li-dispo { color: var(--ink-faint); font-weight: 500; }
|
|
292
|
+
.cb-li-time { margin-left: auto; color: var(--ink-faint); font-weight: 400; font-size: 11px; }
|
|
293
|
+
.cb-li-note { font: 13.5px/1.6 var(--serif); margin: 0; color: var(--ink); }
|
|
294
|
+
.cb-res { font: 12.5px/1.5 var(--sans); color: var(--tip-bar); margin: .45rem 0 0; }
|
|
295
|
+
|
|
296
|
+
.cb-lost {
|
|
297
|
+
display: inline-block; margin: .4rem .3rem; padding: .25rem .6rem; border-radius: 4px;
|
|
298
|
+
background: var(--warn-bg); color: var(--warn-bar); font: 600 12px/1.3 var(--sans); cursor: pointer;
|
|
299
|
+
}
|
|
300
|
+
.cb-answer-btn {
|
|
301
|
+
display: block; margin: .7rem 0 0; border: 1.5px dashed var(--tip-bar); background: transparent;
|
|
302
|
+
color: var(--tip-bar); border-radius: 6px; padding: .45rem .9rem;
|
|
303
|
+
font: 600 13px/1 var(--sans); cursor: pointer;
|
|
304
|
+
}
|
|
305
|
+
.cb-answer-btn:hover { background: var(--tip-bg); }
|
|
306
|
+
|
|
307
|
+
/* 读者问答 callout(AI 处理 sidebar 型备注后烧录进章节,永久+可打印) */
|
|
308
|
+
.callout.qa { background: #f4f0fa; border-color: #6b5b95; }
|
|
309
|
+
.callout.qa .co-label { color: #6b5b95; }
|
|
310
|
+
|
|
311
|
+
/* 标注层打印中性化 */
|
|
312
|
+
@media print {
|
|
313
|
+
mark.cb-anno { background: transparent; border-bottom: none; opacity: 1; padding: 0; }
|
|
314
|
+
.cb-panel, .cb-float, .cb-dialog, .cb-lost, .cb-answer-btn, .cb-toggle { display: none !important; }
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
/* 轻提示 toast */
|
|
318
|
+
.cb-toast {
|
|
319
|
+
position: fixed; left: 50%; bottom: 2.2rem; transform: translate(-50%, 12px);
|
|
320
|
+
z-index: 120; background: var(--ink); color: var(--paper);
|
|
321
|
+
font: 600 13px/1 var(--sans); padding: .65rem 1.1rem; border-radius: 999px;
|
|
322
|
+
opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s;
|
|
323
|
+
box-shadow: 0 6px 18px rgba(0,0,0,.3);
|
|
324
|
+
}
|
|
325
|
+
.cb-toast.show { opacity: 1; transform: translate(-50%, 0); }
|
|
326
|
+
@media print { .cb-toast { display: none !important; } }
|
|
327
|
+
|
|
328
|
+
/* ---------- 左侧固定目录(宽屏) ---------- */
|
|
329
|
+
.book-nav {
|
|
330
|
+
position: fixed; top: 0; left: 0; bottom: 0; width: 250px; overflow-y: auto;
|
|
331
|
+
border-right: 1px solid var(--rule); background: var(--paper);
|
|
332
|
+
padding: 2.2rem 1rem 3rem 1.4rem; font-family: var(--sans);
|
|
333
|
+
display: none; scrollbar-width: thin; z-index: 40;
|
|
334
|
+
}
|
|
335
|
+
.book-nav h2 { font: 700 12px/1 var(--sans); letter-spacing: .3em; text-transform: uppercase;
|
|
336
|
+
color: var(--ink-faint); margin: 0 0 1.2rem; }
|
|
337
|
+
.book-nav ol { list-style: none; margin: 0; padding: 0; }
|
|
338
|
+
.book-nav li { margin: .25rem 0; }
|
|
339
|
+
.book-nav a { display: block; padding: .45rem .7rem; border-radius: 5px;
|
|
340
|
+
color: var(--ink-soft); text-decoration: none; font-size: 13.5px; line-height: 1.5;
|
|
341
|
+
border-left: 3px solid transparent; }
|
|
342
|
+
.book-nav a:hover { background: var(--sand); color: var(--ink); }
|
|
343
|
+
.book-nav a.on { background: var(--sand); color: var(--accent-deep); font-weight: 700;
|
|
344
|
+
border-left-color: var(--accent); }
|
|
345
|
+
.book-nav .toc-status { font: 600 10px/1 var(--sans); color: var(--warn-bar);
|
|
346
|
+
letter-spacing: .1em; margin-left: .5em; vertical-align: 2px; }
|
|
347
|
+
|
|
348
|
+
@media screen and (min-width: 1100px) {
|
|
349
|
+
.book-nav { display: block; }
|
|
350
|
+
nav.toc { display: none; } /* 宽屏用侧栏,顶部目录让位 */
|
|
351
|
+
.book { margin-left: 250px; margin-right: auto; padding-left: 2rem; }
|
|
352
|
+
}
|
|
353
|
+
@media screen and (min-width: 1500px) {
|
|
354
|
+
.book { margin-left: max(250px, calc((100vw - 46em) / 2)); } /* 剩余空间内居中 */
|
|
355
|
+
}
|
|
356
|
+
@media print { .book-nav { display: none !important; } }
|
|
357
|
+
|
|
358
|
+
/* ---------- 目录开关(任何宽度可用;宽屏自动显示侧栏) ---------- */
|
|
359
|
+
.cb-nav-toggle {
|
|
360
|
+
position: fixed; top: 1.1rem; left: 1.1rem; z-index: 71; border: 1.5px solid var(--rule);
|
|
361
|
+
background: var(--paper); border-radius: 999px; padding: .5rem .95rem; cursor: pointer;
|
|
362
|
+
font: 600 14px/1 var(--sans); color: var(--ink-soft); box-shadow: 0 3px 10px rgba(0,0,0,.12);
|
|
363
|
+
}
|
|
364
|
+
.cb-nav-toggle:hover { color: var(--ink); border-color: var(--ink-faint); }
|
|
365
|
+
body.nav-open .book-nav { display: block; z-index: 70; box-shadow: 8px 0 24px rgba(0,0,0,.15); }
|
|
366
|
+
@media screen and (max-width: 1099px) {
|
|
367
|
+
body.nav-open::after { content: ""; position: fixed; inset: 0;
|
|
368
|
+
background: rgba(25,23,20,.28); z-index: 60; }
|
|
369
|
+
}
|
|
370
|
+
@media print { .cb-nav-toggle { display: none !important; } }
|
|
371
|
+
|
|
372
|
+
/* ---------- 代码块一键复制 ---------- */
|
|
373
|
+
pre { position: relative; }
|
|
374
|
+
.cb-copy-btn {
|
|
375
|
+
position: absolute; top: .45rem; right: .5rem; z-index: 5;
|
|
376
|
+
border: 1px solid var(--rule); background: rgba(255,253,248,.95); color: var(--ink-soft);
|
|
377
|
+
border-radius: 5px; padding: .28rem .65rem; font: 600 11.5px/1 var(--sans);
|
|
378
|
+
cursor: pointer; opacity: 0; transition: opacity .15s, color .15s;
|
|
379
|
+
}
|
|
380
|
+
pre:hover .cb-copy-btn, .cb-copy-btn:focus-visible { opacity: 1; }
|
|
381
|
+
.cb-copy-btn:hover { color: var(--accent-deep); border-color: var(--accent); }
|
|
382
|
+
.cb-copy-btn.ok { color: var(--tip-bar); border-color: var(--tip-bar); opacity: 1; }
|
|
383
|
+
@media print { .cb-copy-btn { display: none !important; } }
|
|
384
|
+
|
|
385
|
+
|
|
386
|
+
/* ==========================================================================
|
|
387
|
+
经典版画出版级排印规范与双面印刷系统 (Paged Media & Table of Contents)
|
|
388
|
+
========================================================================== */
|
|
389
|
+
|
|
390
|
+
/* 1. 经典动物版画封面装帧 */
|
|
391
|
+
.classic-woodcut-cover {
|
|
392
|
+
padding: 3rem 2rem 4rem 2rem;
|
|
393
|
+
background: #faf9f5;
|
|
394
|
+
border-bottom: 2px solid #e5e0d8;
|
|
395
|
+
page-break-after: always;
|
|
396
|
+
}
|
|
397
|
+
.cover-frame {
|
|
398
|
+
max-width: 820px;
|
|
399
|
+
margin: 0 auto;
|
|
400
|
+
border: 1px solid #1a1a1a;
|
|
401
|
+
padding: 2.5rem 3rem;
|
|
402
|
+
background: #fff;
|
|
403
|
+
box-shadow: 0 4px 20px rgba(0,0,0,0.04);
|
|
404
|
+
}
|
|
405
|
+
.cover-top-band {
|
|
406
|
+
border-bottom: 3px double #1a1a1a;
|
|
407
|
+
padding-bottom: 0.8rem;
|
|
408
|
+
margin-bottom: 2rem;
|
|
409
|
+
}
|
|
410
|
+
.series-name {
|
|
411
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
412
|
+
font-size: 0.85rem;
|
|
413
|
+
font-weight: 700;
|
|
414
|
+
letter-spacing: 0.15em;
|
|
415
|
+
text-transform: uppercase;
|
|
416
|
+
color: #cf222e;
|
|
417
|
+
}
|
|
418
|
+
.cover-animal-box {
|
|
419
|
+
text-align: center;
|
|
420
|
+
margin: 2rem 0;
|
|
421
|
+
}
|
|
422
|
+
.animal-woodcut {
|
|
423
|
+
max-width: 360px;
|
|
424
|
+
height: auto;
|
|
425
|
+
margin: 0 auto;
|
|
426
|
+
display: block;
|
|
427
|
+
}
|
|
428
|
+
.animal-caption {
|
|
429
|
+
font-size: 0.85rem;
|
|
430
|
+
color: #555;
|
|
431
|
+
margin-top: 0.8rem;
|
|
432
|
+
line-height: 1.4;
|
|
433
|
+
font-style: italic;
|
|
434
|
+
}
|
|
435
|
+
.cover-text-group {
|
|
436
|
+
margin: 2.5rem 0 2rem 0;
|
|
437
|
+
text-align: left;
|
|
438
|
+
}
|
|
439
|
+
.cover-text-group .main-title {
|
|
440
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Serif SC", serif;
|
|
441
|
+
font-size: 2.4rem;
|
|
442
|
+
line-height: 1.25;
|
|
443
|
+
color: #111;
|
|
444
|
+
font-weight: 800;
|
|
445
|
+
letter-spacing: -0.02em;
|
|
446
|
+
margin-bottom: 0.8rem;
|
|
447
|
+
border-bottom: none;
|
|
448
|
+
padding-bottom: 0;
|
|
449
|
+
}
|
|
450
|
+
.cover-text-group .en-title {
|
|
451
|
+
font-family: Georgia, "Times New Roman", serif;
|
|
452
|
+
font-size: 1.05rem;
|
|
453
|
+
color: #555;
|
|
454
|
+
font-style: italic;
|
|
455
|
+
margin-bottom: 1.2rem;
|
|
456
|
+
}
|
|
457
|
+
.cover-subtitle {
|
|
458
|
+
font-size: 1.15rem;
|
|
459
|
+
line-height: 1.6;
|
|
460
|
+
color: #333;
|
|
461
|
+
border-top: 1px solid #eee;
|
|
462
|
+
padding-top: 1rem;
|
|
463
|
+
}
|
|
464
|
+
.cover-meta-grid {
|
|
465
|
+
display: grid;
|
|
466
|
+
grid-template-columns: 1fr 1fr;
|
|
467
|
+
gap: 2rem;
|
|
468
|
+
margin-top: 2.5rem;
|
|
469
|
+
padding-top: 1.5rem;
|
|
470
|
+
border-top: 2px solid #1a1a1a;
|
|
471
|
+
}
|
|
472
|
+
.meta-label {
|
|
473
|
+
display: block;
|
|
474
|
+
font-size: 0.75rem;
|
|
475
|
+
font-weight: 700;
|
|
476
|
+
text-transform: uppercase;
|
|
477
|
+
letter-spacing: 0.1em;
|
|
478
|
+
color: #888;
|
|
479
|
+
margin-bottom: 0.3rem;
|
|
480
|
+
}
|
|
481
|
+
.meta-val {
|
|
482
|
+
font-size: 0.9rem;
|
|
483
|
+
line-height: 1.5;
|
|
484
|
+
color: #222;
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
/* 2. 出版扉页与版权页 (Colophon) */
|
|
488
|
+
.colophon-box {
|
|
489
|
+
max-width: 720px;
|
|
490
|
+
margin: 4rem auto;
|
|
491
|
+
padding: 2.5rem;
|
|
492
|
+
background: #fdfdfc;
|
|
493
|
+
border: 1px solid #e8e4dc;
|
|
494
|
+
font-size: 0.9rem;
|
|
495
|
+
line-height: 1.7;
|
|
496
|
+
color: #444;
|
|
497
|
+
}
|
|
498
|
+
.colophon-title {
|
|
499
|
+
font-size: 1.4rem;
|
|
500
|
+
color: #111;
|
|
501
|
+
margin-bottom: 1rem;
|
|
502
|
+
border-bottom: 2px solid #111;
|
|
503
|
+
padding-bottom: 0.5rem;
|
|
504
|
+
}
|
|
505
|
+
.cip-block {
|
|
506
|
+
background: #f4f2ed;
|
|
507
|
+
border-left: 3px solid #888;
|
|
508
|
+
padding: 1rem 1.2rem;
|
|
509
|
+
margin: 1.5rem 0;
|
|
510
|
+
font-family: monospace;
|
|
511
|
+
font-size: 0.85rem;
|
|
512
|
+
}
|
|
513
|
+
.cip-header {
|
|
514
|
+
font-weight: bold;
|
|
515
|
+
margin-bottom: 0.4rem;
|
|
516
|
+
}
|
|
517
|
+
.rights-reserved {
|
|
518
|
+
margin-top: 2rem;
|
|
519
|
+
font-size: 0.8rem;
|
|
520
|
+
color: #777;
|
|
521
|
+
border-top: 1px dashed #ddd;
|
|
522
|
+
padding-top: 0.8rem;
|
|
523
|
+
}
|
|
524
|
+
|
|
525
|
+
/* 3. 两级深度出版级目录 (带点导线 Dots Leader) */
|
|
526
|
+
.toc-full {
|
|
527
|
+
max-width: 820px;
|
|
528
|
+
margin: 3rem auto;
|
|
529
|
+
padding: 2rem;
|
|
530
|
+
background: #fff;
|
|
531
|
+
border: 1px solid #ece8e1;
|
|
532
|
+
}
|
|
533
|
+
.toc-heading {
|
|
534
|
+
font-size: 1.8rem;
|
|
535
|
+
font-weight: 800;
|
|
536
|
+
color: #111;
|
|
537
|
+
border-bottom: 2px solid #111;
|
|
538
|
+
padding-bottom: 0.6rem;
|
|
539
|
+
margin-bottom: 2rem;
|
|
540
|
+
letter-spacing: 0.05em;
|
|
541
|
+
}
|
|
542
|
+
.toc-list {
|
|
543
|
+
list-style: none;
|
|
544
|
+
padding: 0;
|
|
545
|
+
margin: 0;
|
|
546
|
+
}
|
|
547
|
+
.toc-chapter {
|
|
548
|
+
margin-bottom: 1.4rem;
|
|
549
|
+
}
|
|
550
|
+
.toc-chapter > a, .toc-sub > a {
|
|
551
|
+
display: flex;
|
|
552
|
+
align-items: baseline;
|
|
553
|
+
text-decoration: none;
|
|
554
|
+
color: #1a1a1a;
|
|
555
|
+
transition: color 0.15s ease;
|
|
556
|
+
}
|
|
557
|
+
.toc-chapter > a:hover, .toc-sub > a:hover {
|
|
558
|
+
color: #cf222e;
|
|
559
|
+
}
|
|
560
|
+
.toc-chapter > a .toc-title {
|
|
561
|
+
font-size: 1.05rem;
|
|
562
|
+
font-weight: 700;
|
|
563
|
+
color: #111;
|
|
564
|
+
}
|
|
565
|
+
.toc-leader {
|
|
566
|
+
flex-grow: 1;
|
|
567
|
+
border-bottom: 1px dotted #aaa;
|
|
568
|
+
margin: 0 0.5rem;
|
|
569
|
+
height: 1px;
|
|
570
|
+
}
|
|
571
|
+
.toc-page {
|
|
572
|
+
font-family: monospace;
|
|
573
|
+
font-size: 0.9rem;
|
|
574
|
+
color: #666;
|
|
575
|
+
}
|
|
576
|
+
.toc-sublist {
|
|
577
|
+
list-style: none;
|
|
578
|
+
padding-left: 1.8rem;
|
|
579
|
+
margin: 0.5rem 0 0.8rem 0;
|
|
580
|
+
}
|
|
581
|
+
.toc-sub {
|
|
582
|
+
margin-bottom: 0.45rem;
|
|
583
|
+
}
|
|
584
|
+
.toc-sub .toc-title {
|
|
585
|
+
font-size: 0.9rem;
|
|
586
|
+
color: #444;
|
|
587
|
+
font-weight: 400;
|
|
588
|
+
}
|
|
589
|
+
|
|
590
|
+
/* 4. 印刷级 CSS Paged Media 物理分页系统 (@media print) */
|
|
591
|
+
@page {
|
|
592
|
+
size: A4 portrait;
|
|
593
|
+
margin: 25mm 20mm 25mm 20mm;
|
|
594
|
+
}
|
|
595
|
+
|
|
596
|
+
/* 偶数页 (左页) 页眉页脚 */
|
|
597
|
+
@page :left {
|
|
598
|
+
@top-left {
|
|
599
|
+
content: "通过 Google Colab / Kaggle 学习模型微调";
|
|
600
|
+
font-size: 8pt;
|
|
601
|
+
color: #666;
|
|
602
|
+
font-family: sans-serif;
|
|
603
|
+
}
|
|
604
|
+
@bottom-left {
|
|
605
|
+
content: counter(page);
|
|
606
|
+
font-size: 9pt;
|
|
607
|
+
font-weight: bold;
|
|
608
|
+
font-family: sans-serif;
|
|
609
|
+
}
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
/* 奇数页 (右页) 页眉页脚 */
|
|
613
|
+
@page :right {
|
|
614
|
+
@top-right {
|
|
615
|
+
content: "开源极客深度实战系列 · 随课生长版";
|
|
616
|
+
font-size: 8pt;
|
|
617
|
+
color: #666;
|
|
618
|
+
font-family: sans-serif;
|
|
619
|
+
}
|
|
620
|
+
@bottom-right {
|
|
621
|
+
content: counter(page);
|
|
622
|
+
font-size: 9pt;
|
|
623
|
+
font-weight: bold;
|
|
624
|
+
font-family: sans-serif;
|
|
625
|
+
}
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
@media print {
|
|
629
|
+
/* 隐藏屏幕端交互部件 */
|
|
630
|
+
.book-nav, .build-bar, #ann-bar, .ann-marker, .ann-badge, .ann-counter {
|
|
631
|
+
display: none !important;
|
|
632
|
+
}
|
|
633
|
+
|
|
634
|
+
body {
|
|
635
|
+
background: #fff !important;
|
|
636
|
+
color: #000 !important;
|
|
637
|
+
font-size: 10.5pt !important;
|
|
638
|
+
line-height: 1.55 !important;
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
.chapter {
|
|
642
|
+
page-break-before: always; /* 每章另起新页 */
|
|
643
|
+
break-before: page;
|
|
644
|
+
}
|
|
645
|
+
|
|
646
|
+
.front-matter {
|
|
647
|
+
page-break-after: always;
|
|
648
|
+
break-after: page;
|
|
649
|
+
}
|
|
650
|
+
|
|
651
|
+
.formula-block, .example, .figure, .tablewrap {
|
|
652
|
+
page-break-inside: avoid; /* 公式与核心代码块绝不跨页撕裂 */
|
|
653
|
+
break-inside: avoid;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
/* 目录打印时利用 target-counter 自动捕获真实页码 */
|
|
657
|
+
.toc-sub a::after, .toc-chapter > a::after {
|
|
658
|
+
content: target-counter(attr(href), page);
|
|
659
|
+
font-family: sans-serif;
|
|
660
|
+
font-size: 9pt;
|
|
661
|
+
color: #333;
|
|
662
|
+
float: right;
|
|
663
|
+
}
|
|
664
|
+
}
|
|
665
|
+
|
|
666
|
+
|
|
667
|
+
/* ==========================================================================
|
|
668
|
+
三级树状大纲排印:模块 (Part) ➔ 章节 (Chapter) ➔ 小节 (Section)
|
|
669
|
+
========================================================================== */
|
|
670
|
+
|
|
671
|
+
/* 1. 侧边栏树状层级 */
|
|
672
|
+
.nav-tree {
|
|
673
|
+
list-style: none;
|
|
674
|
+
padding: 0;
|
|
675
|
+
margin: 0;
|
|
676
|
+
}
|
|
677
|
+
.nav-module-title {
|
|
678
|
+
font-size: 0.75rem;
|
|
679
|
+
font-weight: 800;
|
|
680
|
+
text-transform: uppercase;
|
|
681
|
+
letter-spacing: 0.08em;
|
|
682
|
+
color: #cf222e;
|
|
683
|
+
background: #fbf0f0;
|
|
684
|
+
padding: 0.35rem 0.6rem;
|
|
685
|
+
margin: 1.1rem 0 0.4rem 0;
|
|
686
|
+
border-radius: 4px;
|
|
687
|
+
border-left: 3px solid #cf222e;
|
|
688
|
+
}
|
|
689
|
+
.nav-module-title:first-child {
|
|
690
|
+
margin-top: 0;
|
|
691
|
+
}
|
|
692
|
+
.nav-chapter-item {
|
|
693
|
+
padding-left: 0.6rem;
|
|
694
|
+
margin-bottom: 0.35rem;
|
|
695
|
+
font-size: 0.85rem;
|
|
696
|
+
}
|
|
697
|
+
.nav-chapter-item a {
|
|
698
|
+
color: #333;
|
|
699
|
+
text-decoration: none;
|
|
700
|
+
line-height: 1.4;
|
|
701
|
+
display: block;
|
|
702
|
+
}
|
|
703
|
+
.nav-chapter-item a:hover {
|
|
704
|
+
color: #0969da;
|
|
705
|
+
}
|
|
706
|
+
|
|
707
|
+
/* 2. 正式出版目录 (Contents) 模块层级 */
|
|
708
|
+
.toc-module-list {
|
|
709
|
+
list-style: none;
|
|
710
|
+
padding: 0;
|
|
711
|
+
margin: 0;
|
|
712
|
+
}
|
|
713
|
+
.toc-module {
|
|
714
|
+
margin-bottom: 2.2rem;
|
|
715
|
+
padding-bottom: 1.5rem;
|
|
716
|
+
border-bottom: 1px solid #eee;
|
|
717
|
+
}
|
|
718
|
+
.toc-module:last-child {
|
|
719
|
+
border-bottom: none;
|
|
720
|
+
}
|
|
721
|
+
.toc-module-header {
|
|
722
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
723
|
+
font-size: 1.15rem;
|
|
724
|
+
font-weight: 800;
|
|
725
|
+
color: #111;
|
|
726
|
+
background: #f6f5f0;
|
|
727
|
+
padding: 0.6rem 1rem;
|
|
728
|
+
border-left: 4px solid #1a1a1a;
|
|
729
|
+
margin-bottom: 1.2rem;
|
|
730
|
+
letter-spacing: 0.02em;
|
|
731
|
+
}
|
|
732
|
+
.toc-chapter-list {
|
|
733
|
+
list-style: none;
|
|
734
|
+
padding-left: 1rem;
|
|
735
|
+
margin: 0;
|
|
736
|
+
}
|
|
737
|
+
.toc-chapter {
|
|
738
|
+
margin-bottom: 1.1rem;
|
|
739
|
+
}
|
|
740
|
+
.toc-chapter > a .toc-title {
|
|
741
|
+
font-size: 1.02rem;
|
|
742
|
+
font-weight: 700;
|
|
743
|
+
color: #1a1a1a;
|
|
744
|
+
}
|
|
745
|
+
.toc-sublist {
|
|
746
|
+
list-style: none;
|
|
747
|
+
padding-left: 2rem;
|
|
748
|
+
margin: 0.4rem 0 0.8rem 0;
|
|
749
|
+
}
|
|
750
|
+
.toc-sub {
|
|
751
|
+
margin-bottom: 0.35rem;
|
|
752
|
+
}
|
|
753
|
+
.toc-sub .toc-title {
|
|
754
|
+
font-size: 0.88rem;
|
|
755
|
+
color: #555;
|
|
756
|
+
font-weight: 400;
|
|
757
|
+
}
|
|
758
|
+
|
|
759
|
+
|
|
760
|
+
/* ==========================================================================
|
|
761
|
+
正文纸质精装书排印与单页装帧规范 (Book Paper Frame)
|
|
762
|
+
========================================================================== */
|
|
763
|
+
|
|
764
|
+
/* 全局背景:雅致的深灰工作台/阅读桌台面质感 */
|
|
765
|
+
body {
|
|
766
|
+
background: #eae6df !important;
|
|
767
|
+
color: #24292f;
|
|
768
|
+
margin: 0;
|
|
769
|
+
padding: 0;
|
|
770
|
+
}
|
|
771
|
+
|
|
772
|
+
.book {
|
|
773
|
+
max-width: 960px;
|
|
774
|
+
margin: 2rem auto;
|
|
775
|
+
padding: 0 1rem;
|
|
776
|
+
}
|
|
777
|
+
|
|
778
|
+
/* 每一章正文、封面与大纲,均封装进统一的精装纸质书页 (Paper Frame) */
|
|
779
|
+
.chapter, .cover, .front-matter {
|
|
780
|
+
background: #ffffff;
|
|
781
|
+
border: 1px solid #d0c9bc;
|
|
782
|
+
border-radius: 2px;
|
|
783
|
+
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0,0,0,0.05);
|
|
784
|
+
margin-bottom: 3.5rem;
|
|
785
|
+
padding: 3.5rem 4rem 4rem 4rem;
|
|
786
|
+
position: relative;
|
|
787
|
+
box-sizing: border-box;
|
|
788
|
+
}
|
|
789
|
+
|
|
790
|
+
/* 典雅的版芯内双线饰边(正文与封面完全统一风格) */
|
|
791
|
+
.chapter::before, .front-matter::before {
|
|
792
|
+
content: "";
|
|
793
|
+
position: absolute;
|
|
794
|
+
top: 12px;
|
|
795
|
+
left: 12px;
|
|
796
|
+
right: 12px;
|
|
797
|
+
bottom: 12px;
|
|
798
|
+
border: 1px solid #f0ece1;
|
|
799
|
+
pointer-events: none;
|
|
800
|
+
}
|
|
801
|
+
|
|
802
|
+
/* 章节顶部页眉装饰带 */
|
|
803
|
+
.chapter-opener {
|
|
804
|
+
border-bottom: 2px solid #1a1a1a;
|
|
805
|
+
padding-bottom: 1.5rem;
|
|
806
|
+
margin-bottom: 2.5rem;
|
|
807
|
+
position: relative;
|
|
808
|
+
}
|
|
809
|
+
|
|
810
|
+
.chapter-opener .kicker {
|
|
811
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
812
|
+
font-size: 0.82rem;
|
|
813
|
+
font-weight: 800;
|
|
814
|
+
letter-spacing: 0.12em;
|
|
815
|
+
text-transform: uppercase;
|
|
816
|
+
color: #cf222e;
|
|
817
|
+
background: #fbf0f0;
|
|
818
|
+
display: inline-block;
|
|
819
|
+
padding: 0.25rem 0.6rem;
|
|
820
|
+
border-radius: 3px;
|
|
821
|
+
margin-bottom: 0.8rem;
|
|
822
|
+
}
|
|
823
|
+
|
|
824
|
+
.chapter-opener h1 {
|
|
825
|
+
font-size: 2.1rem;
|
|
826
|
+
font-weight: 800;
|
|
827
|
+
color: #111;
|
|
828
|
+
line-height: 1.3;
|
|
829
|
+
margin: 0.5rem 0 1rem 0;
|
|
830
|
+
letter-spacing: -0.02em;
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
.chapter-opener .abstract {
|
|
834
|
+
font-size: 1.05rem;
|
|
835
|
+
line-height: 1.7;
|
|
836
|
+
color: #444;
|
|
837
|
+
font-style: italic;
|
|
838
|
+
margin: 0;
|
|
839
|
+
}
|
|
840
|
+
|
|
841
|
+
/* 页面底部物理书脚标识 */
|
|
842
|
+
.chapter::after {
|
|
843
|
+
content: "随课生长深度实战系列 · Feng-H 著";
|
|
844
|
+
display: block;
|
|
845
|
+
text-align: right;
|
|
846
|
+
font-size: 0.75rem;
|
|
847
|
+
color: #999;
|
|
848
|
+
border-top: 1px solid #f0ece1;
|
|
849
|
+
margin-top: 4rem;
|
|
850
|
+
padding-top: 0.8rem;
|
|
851
|
+
letter-spacing: 0.05em;
|
|
852
|
+
}
|
|
853
|
+
|
|
854
|
+
/* 翻页模式专用样式 (Page Mode) */
|
|
855
|
+
body.paged-mode .chapter,
|
|
856
|
+
body.paged-mode .cover,
|
|
857
|
+
body.paged-mode .front-matter {
|
|
858
|
+
display: none; /* 默认隐藏所有页,仅显示当前活动页 */
|
|
859
|
+
margin-bottom: 0;
|
|
860
|
+
min-height: 85vh;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
body.paged-mode .chapter.active-page,
|
|
864
|
+
body.paged-mode .cover.active-page,
|
|
865
|
+
body.paged-mode .front-matter.active-page {
|
|
866
|
+
display: block;
|
|
867
|
+
animation: pageFade 0.25s cubic-bezier(0.16, 1, 0.3, 1);
|
|
868
|
+
}
|
|
869
|
+
|
|
870
|
+
@keyframes pageFade {
|
|
871
|
+
from { opacity: 0; transform: translateY(4px); }
|
|
872
|
+
to { opacity: 1; transform: translateY(0); }
|
|
873
|
+
}
|
|
874
|
+
|
|
875
|
+
/* 悬浮翻页控制台 (Floating Book Controller) */
|
|
876
|
+
.page-controller {
|
|
877
|
+
position: fixed;
|
|
878
|
+
bottom: 24px;
|
|
879
|
+
left: 50%;
|
|
880
|
+
transform: translateX(-50%);
|
|
881
|
+
background: rgba(26, 26, 26, 0.92);
|
|
882
|
+
backdrop-filter: blur(10px);
|
|
883
|
+
-webkit-backdrop-filter: blur(10px);
|
|
884
|
+
color: #fff;
|
|
885
|
+
padding: 0.6rem 1.2rem;
|
|
886
|
+
border-radius: 30px;
|
|
887
|
+
display: flex;
|
|
888
|
+
align-items: center;
|
|
889
|
+
gap: 1.2rem;
|
|
890
|
+
box-shadow: 0 10px 30px rgba(0,0,0,0.3);
|
|
891
|
+
z-index: 99999;
|
|
892
|
+
font-size: 0.85rem;
|
|
893
|
+
}
|
|
894
|
+
|
|
895
|
+
.page-btn {
|
|
896
|
+
background: #333;
|
|
897
|
+
color: #fff;
|
|
898
|
+
border: 1px solid #555;
|
|
899
|
+
border-radius: 20px;
|
|
900
|
+
padding: 0.35rem 0.9rem;
|
|
901
|
+
font-size: 0.82rem;
|
|
902
|
+
cursor: pointer;
|
|
903
|
+
transition: all 0.2s ease;
|
|
904
|
+
display: flex;
|
|
905
|
+
align-items: center;
|
|
906
|
+
gap: 0.4rem;
|
|
907
|
+
}
|
|
908
|
+
.page-btn:hover:not(:disabled) {
|
|
909
|
+
background: #cf222e;
|
|
910
|
+
border-color: #cf222e;
|
|
911
|
+
}
|
|
912
|
+
.page-btn:disabled {
|
|
913
|
+
opacity: 0.3;
|
|
914
|
+
cursor: not-allowed;
|
|
915
|
+
}
|
|
916
|
+
|
|
917
|
+
.page-info {
|
|
918
|
+
font-family: monospace;
|
|
919
|
+
font-size: 0.9rem;
|
|
920
|
+
color: #ddd;
|
|
921
|
+
}
|
|
922
|
+
.page-mode-toggle {
|
|
923
|
+
background: transparent;
|
|
924
|
+
border: 1px solid #666;
|
|
925
|
+
color: #aaa;
|
|
926
|
+
border-radius: 15px;
|
|
927
|
+
padding: 0.25rem 0.7rem;
|
|
928
|
+
font-size: 0.75rem;
|
|
929
|
+
cursor: pointer;
|
|
930
|
+
}
|
|
931
|
+
.page-mode-toggle:hover {
|
|
932
|
+
color: #fff;
|
|
933
|
+
border-color: #fff;
|
|
934
|
+
}
|
|
935
|
+
|
|
936
|
+
|
|
937
|
+
/* 物理书页 (Book Leaf) 专用精装装帧 */
|
|
938
|
+
.book-leaf {
|
|
939
|
+
background: #ffffff;
|
|
940
|
+
border: 1px solid #d0c9bc;
|
|
941
|
+
border-radius: 2px;
|
|
942
|
+
box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0,0,0,0.05);
|
|
943
|
+
margin-bottom: 2.5rem;
|
|
944
|
+
padding: 3rem 3.5rem 3.5rem 3.5rem;
|
|
945
|
+
position: relative;
|
|
946
|
+
box-sizing: border-box;
|
|
947
|
+
}
|
|
948
|
+
|
|
949
|
+
.book-leaf::before {
|
|
950
|
+
content: "";
|
|
951
|
+
position: absolute;
|
|
952
|
+
top: 10px;
|
|
953
|
+
left: 10px;
|
|
954
|
+
right: 10px;
|
|
955
|
+
bottom: 10px;
|
|
956
|
+
border: 1px solid #f0ece1;
|
|
957
|
+
pointer-events: none;
|
|
958
|
+
}
|
|
959
|
+
|
|
960
|
+
.book-leaf::after {
|
|
961
|
+
content: "随课生长深度实战系列 · Feng-H 著";
|
|
962
|
+
display: block;
|
|
963
|
+
text-align: right;
|
|
964
|
+
font-size: 0.72rem;
|
|
965
|
+
color: #999;
|
|
966
|
+
border-top: 1px solid #f0ece1;
|
|
967
|
+
margin-top: 3rem;
|
|
968
|
+
padding-top: 0.6rem;
|
|
969
|
+
letter-spacing: 0.05em;
|
|
970
|
+
}
|
|
971
|
+
|
|
972
|
+
/* 翻页模式下隐藏未激活页 */
|
|
973
|
+
body.paged-mode .book-leaf {
|
|
974
|
+
display: none;
|
|
975
|
+
min-height: 80vh;
|
|
976
|
+
}
|
|
977
|
+
body.paged-mode .book-leaf.active-page {
|
|
978
|
+
display: block !important;
|
|
979
|
+
animation: pageFade 0.2s ease-out;
|
|
980
|
+
}
|
|
981
|
+
|
|
982
|
+
|
|
983
|
+
/* ==========================================================================
|
|
984
|
+
真·A4 物理纸张出版级排印规范 (A4 Fixed Layout & Running Headers)
|
|
985
|
+
========================================================================== */
|
|
986
|
+
|
|
987
|
+
/* 工作台环境质感 */
|
|
988
|
+
body {
|
|
989
|
+
background: #525659 !important; /* 经典 PDF / 专业阅读器深色工作台底色 */
|
|
990
|
+
margin: 0;
|
|
991
|
+
padding: 20px 0 80px 0;
|
|
992
|
+
}
|
|
993
|
+
|
|
994
|
+
.book {
|
|
995
|
+
max-width: 860px;
|
|
996
|
+
margin: 0 auto;
|
|
997
|
+
}
|
|
998
|
+
|
|
999
|
+
/* 隐藏原始未拆解的长章节容器(由 JS 流式重新拆入 .a4-page) */
|
|
1000
|
+
.chapter-raw-source {
|
|
1001
|
+
display: none !important;
|
|
1002
|
+
}
|
|
1003
|
+
|
|
1004
|
+
/* 标准 A4 纸物理尺寸规格 (794px × 1123px,比例 1 : 1.414) */
|
|
1005
|
+
.a4-page {
|
|
1006
|
+
width: 794px;
|
|
1007
|
+
height: 1123px;
|
|
1008
|
+
max-height: 1123px;
|
|
1009
|
+
margin: 20px auto 30px auto;
|
|
1010
|
+
background: #ffffff;
|
|
1011
|
+
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35), 0 0 1px rgba(0, 0, 0, 0.5);
|
|
1012
|
+
box-sizing: border-box;
|
|
1013
|
+
padding: 40px 55px 35px 55px; /* 上下左右版心边距 */
|
|
1014
|
+
position: relative;
|
|
1015
|
+
display: flex;
|
|
1016
|
+
flex-direction: column;
|
|
1017
|
+
overflow: hidden; /* 物理纸张绝不溢出滚动条 */
|
|
1018
|
+
page-break-after: always;
|
|
1019
|
+
break-after: page;
|
|
1020
|
+
}
|
|
1021
|
+
|
|
1022
|
+
/* 偶数页与奇数页微调装订线 (左偶右奇) */
|
|
1023
|
+
.a4-page.even-page {
|
|
1024
|
+
padding-left: 60px;
|
|
1025
|
+
padding-right: 50px;
|
|
1026
|
+
}
|
|
1027
|
+
.a4-page.odd-page {
|
|
1028
|
+
padding-left: 50px;
|
|
1029
|
+
padding-right: 60px;
|
|
1030
|
+
}
|
|
1031
|
+
|
|
1032
|
+
/* A4 页眉 (Running Header) */
|
|
1033
|
+
.a4-header {
|
|
1034
|
+
height: 26px;
|
|
1035
|
+
border-bottom: 1px solid #1a1a1a;
|
|
1036
|
+
display: flex;
|
|
1037
|
+
justify-content: space-between;
|
|
1038
|
+
align-items: center;
|
|
1039
|
+
font-size: 7.5pt;
|
|
1040
|
+
line-height: 26px;
|
|
1041
|
+
color: #555;
|
|
1042
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
1043
|
+
letter-spacing: 0.03em;
|
|
1044
|
+
margin-bottom: 20px;
|
|
1045
|
+
flex-shrink: 0;
|
|
1046
|
+
white-space: nowrap !important;
|
|
1047
|
+
overflow: hidden;
|
|
1048
|
+
}
|
|
1049
|
+
.a4-header .hdr-left {
|
|
1050
|
+
max-width: 72%;
|
|
1051
|
+
white-space: nowrap !important;
|
|
1052
|
+
overflow: hidden;
|
|
1053
|
+
text-overflow: ellipsis;
|
|
1054
|
+
display: block;
|
|
1055
|
+
}
|
|
1056
|
+
.a4-header .hdr-right {
|
|
1057
|
+
flex-shrink: 0;
|
|
1058
|
+
white-space: nowrap !important;
|
|
1059
|
+
font-size: 7.2pt;
|
|
1060
|
+
color: #888;
|
|
1061
|
+
letter-spacing: 0.05em;
|
|
1062
|
+
}
|
|
1063
|
+
.a4-header .hdr-module {
|
|
1064
|
+
font-weight: 700;
|
|
1065
|
+
color: #cf222e;
|
|
1066
|
+
}
|
|
1067
|
+
.a4-header .hdr-sep {
|
|
1068
|
+
margin: 0 4px;
|
|
1069
|
+
color: #999;
|
|
1070
|
+
}
|
|
1071
|
+
.a4-header .hdr-chapter {
|
|
1072
|
+
color: #222;
|
|
1073
|
+
}
|
|
1074
|
+
.a4-header .hdr-module {
|
|
1075
|
+
font-weight: 700;
|
|
1076
|
+
color: #cf222e;
|
|
1077
|
+
}
|
|
1078
|
+
.a4-header .hdr-chapter {
|
|
1079
|
+
color: #222;
|
|
1080
|
+
}
|
|
1081
|
+
|
|
1082
|
+
/* A4 净版心内容区 (流式填充) */
|
|
1083
|
+
.a4-body {
|
|
1084
|
+
flex-grow: 1;
|
|
1085
|
+
overflow: hidden;
|
|
1086
|
+
font-size: 10pt;
|
|
1087
|
+
line-height: 1.6;
|
|
1088
|
+
color: #24292f;
|
|
1089
|
+
}
|
|
1090
|
+
|
|
1091
|
+
.a4-body h1 {
|
|
1092
|
+
font-size: 1.6rem;
|
|
1093
|
+
margin: 0.5rem 0 1rem 0;
|
|
1094
|
+
border-bottom: 2px solid #1a1a1a;
|
|
1095
|
+
padding-bottom: 0.4rem;
|
|
1096
|
+
}
|
|
1097
|
+
.a4-body h2 {
|
|
1098
|
+
font-size: 1.2rem;
|
|
1099
|
+
margin: 1.2rem 0 0.6rem 0;
|
|
1100
|
+
border-bottom: 1px solid #e1ded8;
|
|
1101
|
+
padding-bottom: 0.3rem;
|
|
1102
|
+
}
|
|
1103
|
+
.a4-body h3 {
|
|
1104
|
+
font-size: 1.05rem;
|
|
1105
|
+
margin: 1rem 0 0.4rem 0;
|
|
1106
|
+
}
|
|
1107
|
+
.a4-body p {
|
|
1108
|
+
margin: 0.5rem 0 0.8rem 0;
|
|
1109
|
+
text-align: justify;
|
|
1110
|
+
}
|
|
1111
|
+
.a4-body .example, .a4-body .figure, .a4-body .tablewrap, .a4-body .formula-block {
|
|
1112
|
+
margin: 0.8rem 0;
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1115
|
+
/* A4 页脚 (Running Footer) */
|
|
1116
|
+
.a4-footer {
|
|
1117
|
+
height: 25px;
|
|
1118
|
+
border-top: 1px solid #e5e0d8;
|
|
1119
|
+
display: flex;
|
|
1120
|
+
justify-content: space-between;
|
|
1121
|
+
align-items: center;
|
|
1122
|
+
font-size: 8pt;
|
|
1123
|
+
color: #777;
|
|
1124
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
|
|
1125
|
+
margin-top: 15px;
|
|
1126
|
+
flex-shrink: 0;
|
|
1127
|
+
}
|
|
1128
|
+
.a4-footer .ftr-page-num {
|
|
1129
|
+
font-weight: bold;
|
|
1130
|
+
font-family: monospace;
|
|
1131
|
+
font-size: 9pt;
|
|
1132
|
+
color: #111;
|
|
1133
|
+
}
|
|
1134
|
+
|
|
1135
|
+
/* 翻页模式专用(A4 纸张切换) */
|
|
1136
|
+
body.paged-mode .a4-page {
|
|
1137
|
+
display: none;
|
|
1138
|
+
}
|
|
1139
|
+
body.paged-mode .a4-page.active-page {
|
|
1140
|
+
display: flex !important;
|
|
1141
|
+
animation: a4PaperTurn 0.18s ease-out;
|
|
1142
|
+
}
|
|
1143
|
+
|
|
1144
|
+
@keyframes a4PaperTurn {
|
|
1145
|
+
from { opacity: 0.4; transform: scale(0.995); }
|
|
1146
|
+
to { opacity: 1; transform: scale(1); }
|
|
1147
|
+
}
|
|
1148
|
+
|
|
1149
|
+
/* 打印模式 (@media print) 原生 1:1 输出 */
|
|
1150
|
+
@media print {
|
|
1151
|
+
body {
|
|
1152
|
+
background: none !important;
|
|
1153
|
+
padding: 0 !important;
|
|
1154
|
+
}
|
|
1155
|
+
.a4-page {
|
|
1156
|
+
box-shadow: none !important;
|
|
1157
|
+
margin: 0 !important;
|
|
1158
|
+
width: 100% !important;
|
|
1159
|
+
height: 100vh !important;
|
|
1160
|
+
page-break-after: always !important;
|
|
1161
|
+
break-after: page !important;
|
|
1162
|
+
display: flex !important;
|
|
1163
|
+
}
|
|
1164
|
+
.page-controller, .book-nav, .build-bar {
|
|
1165
|
+
display: none !important;
|
|
1166
|
+
}
|
|
1167
|
+
}
|