/* 数据科学：爬塔 · 共享样式（天空 + 草地 + 纸片皮肤）
   材质：剪纸。物件 = 一张纸：白色裁边（box-shadow 0 0 0 Npx 白）+ 柔和投影 + 纸纤维纹理；长文直接印在暖白卡纸上，不再套框。
   配色：四段各一套清新色，由 <body data-part="1..4"> 切换三个变量：
     --accent  主色（浅，做纸面、按钮底）   --accent2 副色（浅，做纸条、彩旗、装饰）
     --deep    主色的深色版（只用来写字：链接、加粗、标签字），对暖白卡纸的对比度都 ≥ 4.5:1
   为什么字一律是深色、浅色只做底：清新色本身都浅，白字压在上面对比度不够；深字配浅纸既清楚又不沉重。
   为什么背景全是静态的：fixed 的天空和草地各占一层合成层，滚动时不重绘；常驻动画在长文页上会掉帧。
   页面特有样式写在页内 <style>，类名加 chN- 前缀；这里的共享类名不该需要页内覆盖。 */

/* ---------- 字体（本地 woff2，按全课用字裁剪；新章写完要重跑 tools/subset_fonts.py，漏字会显示成兜底字体）----------
   正文：霞鹜文楷（Regular 正文，Medium 给小字号说明，因为 Regular 笔画细，小字发虚）；
   标题 / 标签 / 按钮：站酷快乐体（只有一个字重，声明成全范围，免得浏览器再合成假粗体）。 */
@font-face{font-family:"DS WenKai";src:url("../fonts/wenkai-regular.woff2") format("woff2");font-weight:100 499;font-style:normal;font-display:swap}
@font-face{font-family:"DS WenKai";src:url("../fonts/wenkai-medium.woff2") format("woff2");font-weight:500 900;font-style:normal;font-display:swap}
@font-face{font-family:"DS KuaiLe";src:url("../fonts/kuaile-regular.woff2") format("woff2");font-weight:100 900;font-style:normal;font-display:swap}

:root{
  --body:"DS WenKai","LXGW WenKai","KaiTi","楷体","STKaiti","Kaiti SC","PingFang SC","Microsoft YaHei",sans-serif;
  --label:"DS KuaiLe","DS WenKai","ZCOOL KuaiLe","PingFang SC","Microsoft YaHei",sans-serif;
  --mono:Consolas,"Cascadia Mono",Menlo,monospace;
  --fs:17.5px;
  --ink:#1f2638;        /* 正文字，对暖白卡纸约 14:1 */
  --ink2:#3b4358;       /* 次要文字，约 9:1 */
  --muted:#4d566c;      /* 图注、出处，约 6.6:1（不用更浅的灰） */
  --panel:#fbf6ea;      /* 暖白卡纸 */
  --edge:#fffdf7;       /* 白色裁边 */
  --kraft:#dcc9a2;      /* 牛皮纸垫层 */
  --shadow:rgba(40,70,100,.26);
  --lift:2px 4px 8px 2px rgba(40,60,90,.18);           /* 小物件的投影 */
  --ok:#2c7a46; --okbg:#d9f1c9; --no:#a8332f; --nobg:#ffdcd5; --warnbg:#fff1b8;
  --fiber:url("../img/paper/fiber.png") 0 0/256px 256px;
  /* 默认 = 第一段：天蓝 + 草绿 */
  --accent:#8fd3f4; --accent2:#a6dc7a; --deep:#1f6a96;
  /* 题头天空带（章页 .hero 顶上一条，见"章题头"一段）：--band-sky 渐变天空，--band-art 一段可横向重复的窗外小景（640×86 一格）。
     四篇各一套，从清晨走到黎明：1 清晨 云 + 风车 + 草地小花；2 午后 风筝 + 气球 + 河 + 花田；3 黄昏入夜 星星 + 月牙 + 漂浮小岛 + 淡紫远山；4 黎明 日出 + 流星 + 脚下云海。
     下面 -2/-3/-4 是后三篇的备用值，body[data-part] 换篇时把它们接到 --band-sky / --band-art 上，章节上线后自动生效。
     目录塔：--tw-wall-1…4 四段塔身的墙（浅色石砖 / 暖米砖 / 淡紫石 / 白云石），和 illus-tower.js 里塔内场景的墙同色 */
  --band-h:92px;
  --band-sky:linear-gradient(180deg,#a9dbf7 0%,#cdebfa 58%,#eef9f2 100%);
  --band-art:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 640 86%22 preserveAspectRatio=%22xMidYMax slice%22%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%2290%22 cy=%2228%22 rx=%2222%22 ry=%229%22/%3E%3Ccircle cx=%2281%22 cy=%2223%22 r=%229%22/%3E%3Ccircle cx=%2296%22 cy=%2220%22 r=%2211%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22330%22 cy=%2220%22 rx=%2217.6%22 ry=%227.2%22/%3E%3Ccircle cx=%22322.8%22 cy=%2216.0%22 r=%227.2%22/%3E%3Ccircle cx=%22334.8%22 cy=%2213.6%22 r=%228.8%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22560%22 cy=%2234%22 rx=%2219.8%22 ry=%228.1%22/%3E%3Ccircle cx=%22551.9%22 cy=%2229.5%22 r=%228.1%22/%3E%3Ccircle cx=%22565.4%22 cy=%2226.8%22 r=%229.9%22/%3E%3C/g%3E%3Cpath d=%22M0,86 L0,65.3 L20,66.7 L40,67.2 L60,66.6 L80,65.2 L100,63.4 L120,61.6 L140,60.1 L160,59.2 L180,58.9 L200,59.1 L220,59.5 L240,60.1 L260,60.6 L280,61.2 L300,61.8 L320,62.6 L340,63.5 L360,64.5 L380,65.4 L400,65.9 L420,65.7 L440,64.7 L460,63.0 L480,60.9 L500,58.9 L520,57.2 L540,56.5 L560,56.9 L580,58.4 L600,60.6 L620,63.1 L640,65.3 L640,86 Z%22 fill=%22%23c4e8a8%22/%3E%3Cpath d=%22M464 66 L476 66 L474 42 L466 42Z%22 fill=%22%23fbf3e2%22 stroke=%22%23ffffff%22 stroke-width=%221.2%22/%3E%3Cpath d=%22M464.5 42.5 L475.5 42.5 L470 34Z%22 fill=%22%23f08c7c%22/%3E%3Crect x=%22468%22 y=%2225%22 width=%224%22 height=%2216%22 fill=%22%23fffaf0%22 stroke=%22%23b49a7c%22 stroke-width=%22.6%22 transform=%22rotate(20 470 42)%22/%3E%3Crect x=%22468%22 y=%2225%22 width=%224%22 height=%2216%22 fill=%22%23fffaf0%22 stroke=%22%23b49a7c%22 stroke-width=%22.6%22 transform=%22rotate(110 470 42)%22/%3E%3Crect x=%22468%22 y=%2225%22 width=%224%22 height=%2216%22 fill=%22%23fffaf0%22 stroke=%22%23b49a7c%22 stroke-width=%22.6%22 transform=%22rotate(200 470 42)%22/%3E%3Crect x=%22468%22 y=%2225%22 width=%224%22 height=%2216%22 fill=%22%23fffaf0%22 stroke=%22%23b49a7c%22 stroke-width=%22.6%22 transform=%22rotate(290 470 42)%22/%3E%3Ccircle cx=%22470%22 cy=%2242%22 r=%221.8%22 fill=%22%238a6a4a%22/%3E%3Cpath d=%22M0,86 L0,75.9 L20,75.4 L40,74.6 L60,73.6 L80,72.7 L100,72.0 L120,71.6 L140,71.5 L160,71.4 L180,71.5 L200,71.6 L220,71.8 L240,72.1 L260,72.6 L280,73.2 L300,74.1 L320,74.9 L340,75.5 L360,75.8 L380,75.5 L400,74.6 L420,73.4 L440,71.9 L460,70.6 L480,69.7 L500,69.5 L520,70.0 L540,71.1 L560,72.6 L580,74.0 L600,75.2 L620,75.9 L640,75.9 L640,86 Z%22 fill=%22%23a6dc7a%22/%3E%3Ccircle cx=%228%22 cy=%2277%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%228%22 cy=%2277%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2231%22 cy=%2284%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%2231%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2254%22 cy=%2282%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%2254%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2277%22 cy=%2280%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%2277%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22100%22 cy=%2278%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22100%22 cy=%2278%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22123%22 cy=%2285%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22123%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22146%22 cy=%2283%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22146%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22169%22 cy=%2281%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22169%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22192%22 cy=%2279%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22192%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22215%22 cy=%2277%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22215%22 cy=%2277%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22238%22 cy=%2284%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22238%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22261%22 cy=%2282%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22261%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22284%22 cy=%2280%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22284%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22307%22 cy=%2278%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22307%22 cy=%2278%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22330%22 cy=%2285%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22330%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22353%22 cy=%2283%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22353%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22376%22 cy=%2281%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22376%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22399%22 cy=%2279%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22399%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22422%22 cy=%2277%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22422%22 cy=%2277%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22445%22 cy=%2284%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22445%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22468%22 cy=%2282%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22468%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22491%22 cy=%2280%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22491%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22514%22 cy=%2278%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22514%22 cy=%2278%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22537%22 cy=%2285%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22537%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22560%22 cy=%2283%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22560%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22583%22 cy=%2281%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22583%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22606%22 cy=%2279%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22606%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22629%22 cy=%2277%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22629%22 cy=%2277%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3C/svg%3E");
  --band-sky-2:linear-gradient(180deg,#9fe3d6 0%,#d9f4ea 58%,#ffe6cf 100%);
  --band-art-2:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 640 86%22 preserveAspectRatio=%22xMidYMax slice%22%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22520%22 cy=%2222%22 rx=%2217.6%22 ry=%227.2%22/%3E%3Ccircle cx=%22512.8%22 cy=%2218.0%22 r=%227.2%22/%3E%3Ccircle cx=%22524.8%22 cy=%2215.6%22 r=%228.8%22/%3E%3C/g%3E%3Cpath d=%22M150 66 Q170 40 168 30%22 stroke=%22%237a6a5a%22 stroke-width=%22.8%22 fill=%22none%22/%3E%3Cpath d=%22M168 12 L176 22 L168 34 L160 22Z%22 fill=%22%23ffc49b%22 stroke=%22%23fff%22 stroke-width=%221%22/%3E%3Cpath d=%22M300 35 q-3 8 1 18%22 stroke=%22%236b5a48%22 stroke-width=%22.6%22 fill=%22none%22/%3E%3Cellipse cx=%22300%22 cy=%2226%22 rx=%226.5%22 ry=%228%22 fill=%22%23f7a9bd%22 stroke=%22%23fff%22 stroke-width=%221%22/%3E%3Cpath d=%22M318 43 q-3 8 1 18%22 stroke=%22%236b5a48%22 stroke-width=%22.6%22 fill=%22none%22/%3E%3Cellipse cx=%22318%22 cy=%2234%22 rx=%226.5%22 ry=%228%22 fill=%22%23fff3a8%22 stroke=%22%23fff%22 stroke-width=%221%22/%3E%3Cpath d=%22M610 39 q-3 8 1 18%22 stroke=%22%236b5a48%22 stroke-width=%22.6%22 fill=%22none%22/%3E%3Cellipse cx=%22610%22 cy=%2230%22 rx=%226.5%22 ry=%228%22 fill=%22%239fe3c8%22 stroke=%22%23fff%22 stroke-width=%221%22/%3E%3Cpath d=%22M0,86 L0,63.1 L20,64.7 L40,65.7 L60,65.9 L80,65.4 L100,64.2 L120,62.8 L140,61.4 L160,60.3 L180,59.7 L200,59.5 L220,59.7 L240,60.2 L260,60.7 L280,61.2 L300,61.7 L320,62.1 L340,62.7 L360,63.3 L380,64.0 L400,64.5 L420,64.7 L440,64.5 L460,63.8 L480,62.5 L500,61.0 L520,59.5 L540,58.4 L560,57.9 L580,58.3 L600,59.5 L620,61.2 L640,63.1 L640,86 Z%22 fill=%22%23cfe8b8%22/%3E%3Cpath d=%22M0 68 Q160 64 320 69 T640 68 L640 72 Q480 74 320 73 T0 72Z%22 fill=%22%23a6d8ef%22/%3E%3Cpath d=%22M0,86 L0,76.2 L20,75.6 L40,75.0 L60,74.5 L80,74.2 L100,74.0 L120,73.9 L140,73.8 L160,73.7 L180,73.7 L200,73.9 L220,74.4 L240,75.0 L260,75.8 L280,76.6 L300,77.2 L320,77.4 L340,77.2 L360,76.4 L380,75.3 L400,74.1 L420,73.0 L440,72.4 L460,72.2 L480,72.7 L500,73.5 L520,74.7 L540,75.8 L560,76.6 L580,77.1 L600,77.1 L620,76.8 L640,76.2 L640,86 Z%22 fill=%22%239ad37f%22/%3E%3Ccircle cx=%228%22 cy=%2279%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%228%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2225%22 cy=%2286%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%2225%22 cy=%2286%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2242%22 cy=%2284%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%2242%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2259%22 cy=%2282%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%2259%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2276%22 cy=%2280%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%2276%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%2293%22 cy=%2287%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%2293%22 cy=%2287%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22110%22 cy=%2285%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22110%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22127%22 cy=%2283%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22127%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22144%22 cy=%2281%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22144%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22161%22 cy=%2279%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22161%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22178%22 cy=%2286%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22178%22 cy=%2286%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22195%22 cy=%2284%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22195%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22212%22 cy=%2282%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22212%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22229%22 cy=%2280%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22229%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22246%22 cy=%2287%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22246%22 cy=%2287%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22263%22 cy=%2285%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22263%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22280%22 cy=%2283%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22280%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22297%22 cy=%2281%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22297%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22314%22 cy=%2279%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22314%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22331%22 cy=%2286%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22331%22 cy=%2286%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22348%22 cy=%2284%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22348%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22365%22 cy=%2282%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22365%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22382%22 cy=%2280%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22382%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22399%22 cy=%2287%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22399%22 cy=%2287%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22416%22 cy=%2285%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22416%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22433%22 cy=%2283%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22433%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22450%22 cy=%2281%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22450%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22467%22 cy=%2279%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22467%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22484%22 cy=%2286%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22484%22 cy=%2286%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22501%22 cy=%2284%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22501%22 cy=%2284%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22518%22 cy=%2282%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22518%22 cy=%2282%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22535%22 cy=%2280%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22535%22 cy=%2280%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22552%22 cy=%2287%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22552%22 cy=%2287%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22569%22 cy=%2285%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22569%22 cy=%2285%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22586%22 cy=%2283%22 r=%222.2%22 fill=%22%23ffffff%22/%3E%3Ccircle cx=%22586%22 cy=%2283%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22603%22 cy=%2281%22 r=%222.2%22 fill=%22%23ffc49b%22/%3E%3Ccircle cx=%22603%22 cy=%2281%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22620%22 cy=%2279%22 r=%222.2%22 fill=%22%23f7a9bd%22/%3E%3Ccircle cx=%22620%22 cy=%2279%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3Ccircle cx=%22637%22 cy=%2286%22 r=%222.2%22 fill=%22%23fff3a8%22/%3E%3Ccircle cx=%22637%22 cy=%2286%22 r=%22.9%22 fill=%22%23f2bd4b%22/%3E%3C/svg%3E");
  --band-sky-3:linear-gradient(180deg,#b9aaec 0%,#dccdf5 55%,#ffe2bf 100%);
  --band-art-3:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 640 86%22 preserveAspectRatio=%22xMidYMax slice%22%3E%3Cpath d=%22M40 14 Q40 18 44 18 Q40 18 40 22 Q40 18 36 18 Q40 18 40 14Z%22 fill=%22%23fff6cf%22/%3E%3Cpath d=%22M120 31 Q120 34 123 34 Q120 34 120 37 Q120 34 117 34 Q120 34 120 31Z%22 fill=%22%23ffffff%22/%3E%3Cpath d=%22M200 8.4 Q200 12 203.6 12 Q200 12 200 15.6 Q200 12 196.4 12 Q200 12 200 8.4Z%22 fill=%22%23fff6cf%22/%3E%3Cpath d=%22M290 25.4 Q290 28 292.6 28 Q290 28 290 30.6 Q290 28 287.4 28 Q290 28 290 25.4Z%22 fill=%22%23ffffff%22/%3E%3Cpath d=%22M400 12 Q400 16 404 16 Q400 16 400 20 Q400 16 396 16 Q400 16 400 12Z%22 fill=%22%23fff6cf%22/%3E%3Cpath d=%22M470 35.4 Q470 38 472.6 38 Q470 38 470 40.6 Q470 38 467.4 38 Q470 38 470 35.4Z%22 fill=%22%23ffffff%22/%3E%3Cpath d=%22M590 16.6 Q590 20 593.4 20 Q590 20 590 23.4 Q590 20 586.6 20 Q590 20 590 16.6Z%22 fill=%22%23fff6cf%22/%3E%3Cpath d=%22M540 14 A10 10 0 1 0 540 34 A7.2 8 0 1 1 540 14Z%22 fill=%22%23fff1b8%22/%3E%3Cg%3E%3Cpath d=%22M228 46 L252 46 L244 54 L238 60 L232 54Z%22 fill=%22%23a796c9%22/%3E%3Cpath d=%22M226 47 Q240 40 254 47Z%22 fill=%22%238fd08a%22/%3E%3Crect x=%22243%22 y=%2234%22 width=%222%22 height=%229%22 fill=%22%239a6b45%22/%3E%3Ccircle cx=%22244%22 cy=%2232%22 r=%225%22 fill=%22%236fbf6a%22/%3E%3C/g%3E%3Cpath d=%22M0 50 C200 40 420 60 640 50%22 stroke=%22%23fff6d0%22 stroke-width=%223%22 opacity=%22.35%22 fill=%22none%22/%3E%3Cpath d=%22M0,86 L0,70.5 L20,71.0 L40,70.6 L60,69.3 L80,67.6 L100,65.9 L120,64.5 L140,63.6 L160,63.2 L180,63.2 L200,63.5 L220,63.9 L240,64.3 L260,64.8 L280,65.4 L300,66.2 L320,67.3 L340,68.4 L360,69.4 L380,70.0 L400,70.0 L420,69.1 L440,67.4 L460,65.3 L480,63.1 L500,61.4 L520,60.5 L540,60.8 L560,62.1 L580,64.3 L600,66.7 L620,68.9 L640,70.5 L640,86 Z%22 fill=%22%23c2b4ea%22/%3E%3Cpath d=%22M0,86 L0,77.3 L20,76.5 L40,75.8 L60,75.3 L80,75.0 L100,74.8 L120,74.6 L140,74.4 L160,74.3 L180,74.4 L200,74.7 L220,75.4 L240,76.3 L260,77.3 L280,78.3 L300,78.9 L320,79.0 L340,78.5 L360,77.4 L380,76.0 L400,74.5 L420,73.2 L440,72.6 L460,72.6 L480,73.4 L500,74.6 L520,76.0 L540,77.3 L560,78.2 L580,78.6 L600,78.5 L620,78.0 L640,77.3 L640,86 Z%22 fill=%22%23a99bdc%22/%3E%3C/svg%3E");
  --band-sky-4:linear-gradient(180deg,#f7c3bd 0%,#fde0d6 55%,#fff6ef 100%);
  --band-art-4:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 640 86%22 preserveAspectRatio=%22xMidYMax slice%22%3E%3Ccircle cx=%22430%22 cy=%2266%22 r=%2234%22 fill=%22%23fff3b8%22 opacity=%22.55%22/%3E%3Ccircle cx=%22430%22 cy=%2268%22 r=%2215%22 fill=%22%23ffd98a%22/%3E%3Cpath d=%22M120 14 l40 -14%22 stroke=%22%23ffffff%22 stroke-width=%222%22 stroke-linecap=%22round%22 opacity=%22.9%22/%3E%3Ccircle cx=%22120%22 cy=%2214%22 r=%222%22 fill=%22%23fffbe8%22/%3E%3Cpath d=%22M560 26 l26 -9%22 stroke=%22%23ffffff%22 stroke-width=%221.6%22 stroke-linecap=%22round%22 opacity=%22.8%22/%3E%3Crect x=%220%22 y=%2274%22 width=%22640%22 height=%2212%22 fill=%22%23fff9f7%22/%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%220%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22-9.450000000000001%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%226.300000000000001%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%2256%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%2246.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%2262.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22112%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22102.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22118.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22168%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22158.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22174.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22224%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22214.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22230.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22280%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22270.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22286.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22336%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22326.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22342.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22392%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22382.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22398.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22448%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22438.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22454.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22504%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22494.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22510.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22560%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22550.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22566.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22616%22 cy=%2277%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22606.55%22 cy=%2271.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22622.3%22 cy=%2268.6%22 r=%2211.55%22/%3E%3C/g%3E%3Cg fill=%22%23ffffff%22 stroke=%22%23ffffff%22 stroke-width=%220%22%3E%3Cellipse cx=%22672%22 cy=%2274%22 rx=%2223.1%22 ry=%229.450000000000001%22/%3E%3Ccircle cx=%22662.55%22 cy=%2268.75%22 r=%229.450000000000001%22/%3E%3Ccircle cx=%22678.3%22 cy=%2265.6%22 r=%2211.55%22/%3E%3C/g%3E%3C/svg%3E");
  --tw-wall-1:#e7eef1 url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2244%22 height=%2220%22 viewBox=%220 0 44 20%22%3E%3Crect width=%2244%22 height=%2220%22 fill=%22%23e7eef1%22/%3E%3Crect x=%221%22 y=%221%22 width=%2220.0%22 height=%228.0%22 fill=%22%23f3f7f9%22/%3E%3Cpath d=%22M0 .5 H44 M0 10.5 H44 M.5 0 V10.0 M22.5 10.0 V20%22 stroke=%22%23c3d1d9%22 stroke-width=%221%22/%3E%3C/svg%3E") 0 0/44px 20px;
  --tw-wall-2:#f4e3c6 url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2232%22 height=%2214%22 viewBox=%220 0 32 14%22%3E%3Crect width=%2232%22 height=%2214%22 fill=%22%23f4e3c6%22/%3E%3Crect x=%221%22 y=%221%22 width=%2214.0%22 height=%225.0%22 fill=%22%23fbefdc%22/%3E%3Cpath d=%22M0 .5 H32 M0 7.5 H32 M.5 0 V7.0 M16.5 7.0 V14%22 stroke=%22%23dcc29a%22 stroke-width=%221%22/%3E%3C/svg%3E") 0 0/32px 14px;
  --tw-wall-3:#d5caef url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2252%22 height=%2224%22 viewBox=%220 0 52 24%22%3E%3Crect width=%2252%22 height=%2224%22 fill=%22%23d5caef%22/%3E%3Crect x=%221%22 y=%221%22 width=%2224.0%22 height=%2210.0%22 fill=%22%23e3dbf7%22/%3E%3Cpath d=%22M0 .5 H52 M0 12.5 H52 M.5 0 V12.0 M26.5 12.0 V24%22 stroke=%22%23b3a4dd%22 stroke-width=%221%22/%3E%3C/svg%3E") 0 0/52px 24px;
  --tw-wall-4:#faf6f4 url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2288%22 height=%2256%22 viewBox=%220 0 88 56%22%3E%3Crect width=%2288%22 height=%2256%22 fill=%22%23faf6f4%22/%3E%3Cpath d=%22M0 .5 H88 M0 28.5 H88 M.5 0 V28 M44.5 28 V56%22 stroke=%22%23e6dbd7%22 stroke-width=%221%22/%3E%3Cpath d=%22M8 10 q8 4 14 2 t12 8 M54 38 q8 -2 16 2 t10 1%22 stroke=%22%23efcfcb%22 stroke-width=%221%22 fill=%22none%22/%3E%3C/svg%3E") 0 0/88px 56px;
}
body[data-part="2"]{--accent:#9fe3c8;--accent2:#ffc49b;--deep:#1d7457;--band-sky:var(--band-sky-2);--band-art:var(--band-art-2)}   /* 薄荷 + 蜜桃 */
body[data-part="3"]{--accent:#cbbcf2;--accent2:#fbe79a;--deep:#5e46a3;--band-sky:var(--band-sky-3);--band-art:var(--band-art-3)}   /* 淡紫 + 浅黄 */
body[data-part="4"]{--accent:#f9b0a8;--accent2:#eef4fb;--deep:#ad3f55;--band-sky:var(--band-sky-4);--band-art:var(--band-art-4)}   /* 珊瑚粉 + 云白 */

*,*::before,*::after{box-sizing:border-box}
[hidden]{display:none!important}   /* .btn 等写了 display，会把 hidden 属性盖掉 */
html{background:#cdeafa;scroll-padding-top:70px;-webkit-text-size-adjust:100%}
body{margin:0;color:var(--ink);font-family:var(--body);font-size:var(--fs);line-height:1.85;background:transparent;overflow-x:hidden}
button,input,textarea,select{font-family:var(--body);font-size:inherit;color:inherit}

/* ---------- 背景：天空渐变 + 纸片云（固定在视口）+ 视口底部的纸片草地 ----------
   body 不建层叠上下文，z-index:-1 的两个伪元素画在根背景之上、所有内容之下。 */
body::before{content:"";position:fixed;inset:0;z-index:-1;pointer-events:none;
  background:url("../img/paper/clouds.svg") center top/1600px auto no-repeat,linear-gradient(180deg,#a9dbf7 0%,#cbeafb 45%,#e8f6fd 80%,#f3fbff 100%)}
body::after{content:"";position:fixed;left:0;right:0;bottom:0;height:clamp(110px,22vh,220px);z-index:-1;pointer-events:none;
  background:url("../img/paper/hills.svg") left bottom/auto 100% repeat-x}

/* ---------- 文字 ---------- */
h1,h2,h3,h4{font-family:var(--label);font-weight:400;letter-spacing:.02em;line-height:1.35;color:var(--ink)}
h1{font-size:clamp(30px,6vw,42px);margin:.2em 0 .3em}
h2{font-size:clamp(23px,4.4vw,28px)}
h3{font-size:21px;margin:1.6em 0 .5em}
h4{font-size:18px;margin:1.2em 0 .4em}
p{margin:.7em 0}
a{color:var(--deep);text-underline-offset:.2em}
/* 加粗：文楷的粗体只略重，所以再加本段深色 + 一条波浪下划线，一眼能看出 */
b,strong{font-weight:700;color:var(--deep);text-decoration:underline wavy color-mix(in srgb,var(--accent) 85%,#7a9) 1.5px;text-underline-offset:.28em;text-decoration-skip-ink:none}
:is(.btn,.chip,.opt,.egtab,.tw-floor,.gear,.navpanel,.topbar) :is(b,strong){text-decoration:none;color:inherit}
code,kbd{font-family:var(--mono);font-size:.9em;background:#efe6d2;padding:0 .3em;border-radius:3px}
ul,ol{padding-left:1.4em}
li{margin:.25em 0}
.src,.small{font-size:14.5px;font-weight:500;color:var(--muted);line-height:1.6}
:focus-visible{outline:3px solid var(--deep);outline-offset:3px}
.sr{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* ---------- 正文窗口：暖白卡纸 + 白色裁边 + 牛皮纸垫层 + 柔和投影 ---------- */
.wrap{position:relative;max-width:820px;margin:30px auto 150px;padding:34px 46px 40px;border-radius:3px;
  background:var(--panel) url("../img/paper/fiber-soft.png") 0 0/256px 256px;
  box-shadow:0 0 0 6px var(--edge),9px 11px 0 6px var(--kraft),9px 11px 0 7px rgba(90,70,40,.22),14px 22px 36px 6px var(--shadow)}
@media(max-width:700px){
  .wrap{margin:14px 16px 120px;padding:22px 18px 28px;box-shadow:0 0 0 5px var(--edge),4px 6px 0 5px var(--kraft),6px 12px 22px 4px var(--shadow)}
}

/* ---------- 顶栏：一条白纸条（品牌、小塔导航、背包、音效）+ 阅读进度 ---------- */
.topbar{position:sticky;top:0;z-index:60;display:flex;align-items:center;gap:6px;min-height:54px;padding:4px 10px;
  background:var(--edge) var(--fiber);box-shadow:0 2px 0 #e7dcc4,0 6px 14px rgba(40,70,100,.16)}
.topbar .tb-brand{display:flex;align-items:center;gap:8px;min-height:44px;padding:0 8px;font-family:var(--label);font-size:19px;color:var(--ink);text-decoration:none;white-space:nowrap}
.topbar .tb-brand i{display:block;width:16px;height:24px;flex:none;
  background:linear-gradient(var(--edge) 0 0) 50% 0/2px 4px no-repeat,linear-gradient(#f9b0a8 0 0) 0 4px/100% 5px no-repeat,linear-gradient(#cbbcf2 0 0) 0 9.5px/100% 5px no-repeat,linear-gradient(#9fe3c8 0 0) 0 15px/100% 4px no-repeat,linear-gradient(#8fd3f4 0 0) 0 19.5px/100% 4.5px no-repeat;
  box-shadow:0 0 0 2px var(--edge),1px 2px 3px 1px rgba(40,60,90,.25)}
.topbar .tb-sp{flex:1}
.tb-btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-width:44px;min-height:44px;padding:0 12px;border:none;border-radius:3px;cursor:pointer;
  font-family:var(--label);font-size:16px;color:var(--ink);background:color-mix(in srgb,var(--accent) 45%,var(--edge));box-shadow:0 0 0 2px var(--edge),1px 2px 4px 1px rgba(40,60,90,.18)}
.tb-btn:hover{background:var(--accent)}
.tb-btn .tb-n{font-family:var(--body);font-weight:700}
a.tb-lang{text-decoration:none}/* 语言切换按钮是链接（EN / 中），去掉下划线；只在有英文版的页面出现，见 common.js EN_DONE */
.tb-dots{display:none;gap:3px;align-items:flex-end}
.tb-dots a,.tb-dots span{display:block;width:22px;border-radius:2px 2px 0 0;background:var(--c);box-shadow:0 0 0 1.5px var(--edge);text-decoration:none;position:relative}
.tb-dots span{background:#e3e1db}
.tb-dots .done::after{content:"";position:absolute;left:7px;top:4px;width:8px;height:8px;border-radius:1px;background:#ffd25e;box-shadow:0 0 5px #ffd25e}
.tb-dots .cur{outline:2.5px solid var(--deep);outline-offset:1px}
@media(min-width:1040px){.tb-dots{display:flex}}
@media(max-width:420px){.topbar .tb-brand{font-size:16px;padding:0 4px}.tb-btn{padding:0 9px;font-size:15px}}
.readbar{position:absolute;left:0;right:0;bottom:-4px;height:4px;background:transparent;pointer-events:none}
.readbar i{display:block;height:100%;width:0;background:var(--accent2);box-shadow:0 0 0 1px var(--edge)}
/* 小塔弹出面板：16 层从上往下排，当前层高亮 */
.tw-pop{position:absolute;top:calc(100% + 8px);right:8px;width:min(320px,calc(100vw - 32px));max-height:min(70vh,640px);overflow:auto;padding:12px;display:none;
  background:var(--edge) var(--fiber);border-radius:3px;box-shadow:0 0 0 4px var(--edge),4px 10px 24px 4px var(--shadow)}
.tw-pop.open{display:block}
.tw-pop h4{margin:2px 4px 8px;font-size:17px}
.tw-pop a,.tw-pop .off{display:flex;align-items:center;gap:10px;min-height:44px;padding:4px 10px;margin:3px 0;border-radius:2px;text-decoration:none;color:var(--ink);background:color-mix(in srgb,var(--c) 40%,var(--edge))}
.tw-pop a:hover{background:var(--c)}
.tw-pop .off{color:var(--muted);background:#eeece6}
.tw-pop .cur{box-shadow:inset 4px 0 0 var(--deep);font-weight:700}
.tw-pop .fl{font-family:var(--label);min-width:3.6em;font-size:15px}
.tw-pop .win{margin-left:auto;width:14px;height:14px;border-radius:2px;background:#9fb0c4;box-shadow:0 0 0 2px var(--edge)}
.tw-pop .done .win{background:#ffd25e;box-shadow:0 0 0 2px var(--edge),0 0 6px #ffd25e}

/* ---------- 章内导航：右下角目录按钮 + 面板 ---------- */
.navfab{position:fixed;right:16px;bottom:18px;z-index:55;width:52px;height:52px;border:none;border-radius:50%;cursor:pointer;font-size:22px;color:var(--ink);
  background:var(--accent) var(--fiber);box-shadow:0 0 0 4px var(--edge),3px 6px 12px 2px var(--shadow)}
.navpanel{position:fixed;right:16px;bottom:84px;z-index:56;width:min(340px,calc(100vw - 32px));max-height:min(70vh,560px);overflow:auto;padding:14px 14px 10px;display:none;
  background:var(--edge) var(--fiber);border-radius:3px;box-shadow:0 0 0 4px var(--edge),4px 10px 24px 4px var(--shadow)}
.navpanel.open{display:block}
.navpanel h4{margin:0 0 6px;font-size:17px}
.navpanel ol{margin:0;padding-left:1.6em}
.navpanel a{display:block;min-height:40px;padding:6px 6px;color:var(--ink);text-decoration:none;line-height:1.5;border-radius:2px}
.navpanel a.on{background:color-mix(in srgb,var(--accent) 55%,var(--edge));font-weight:700}
.navtools{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.navtools button{min-height:44px;padding:0 12px;border:none;border-radius:3px;cursor:pointer;font-family:var(--label);font-size:15px;background:#efe6d2;box-shadow:0 0 0 2px var(--edge),1px 2px 3px 1px rgba(40,60,90,.15)}

/* ---------- 章题头 ---------- */
.hero{display:grid;grid-template-columns:1fr minmax(0,38%);gap:26px;align-items:center;margin-bottom:10px}
.hero .txt{min-width:0}
.hero .badge{display:inline-block;padding:3px 14px 1px;font-family:var(--label);font-size:16px;color:var(--ink);background:var(--accent) var(--fiber);border-radius:2px;
  box-shadow:0 0 0 3px var(--edge),2px 3px 5px 2px rgba(40,60,90,.2);transform:rotate(-2deg)}
.hero h1{position:relative;display:inline;padding:0 4px;background:linear-gradient(transparent 68%,color-mix(in srgb,var(--accent2) 85%,#fff) 68% 92%,transparent 92%)}
.hero h1{display:block;width:fit-content;max-width:100%;text-wrap:balance}
.hero .sub{font-weight:500;color:var(--ink2);font-size:18px;margin-top:.6em}
.hero > .illus,.hero > [data-illus]{width:100%}
@media(max-width:700px){.hero{grid-template-columns:1fr}.hero > .illus,.hero > [data-illus]{max-width:320px;justify-self:center}}
/* 题头天空带：贴着卡纸顶边、横跨整张卡纸的一条当篇天空（样板 samples/art-parts.html 第一块），题头的字和插画排在它下面，所以不影响文字对比度。
   用 ::before 画（不加元素）：left/right/top 抵消 .wrap 的内边距；z-index 0，fx.css 的环境小动画（.fx-amb，云和小鸟）在它上面飘。
   天空和小景都是静止的背景图（长文页不放常驻动画）；打印时去掉 */
.hero{position:relative;padding-top:calc(var(--band-h) - 34px + 16px)}
.hero::before{content:"";position:absolute;z-index:0;left:-46px;right:-46px;top:-34px;height:var(--band-h);pointer-events:none;border-radius:3px 3px 0 0;
  background:var(--band-art) left bottom/auto 100% repeat-x,var(--band-sky);box-shadow:0 3px 0 var(--edge),0 6px 8px -2px rgba(40,60,90,.14)}
.hero > :not(.fx-amb){position:relative;z-index:1}
@media(max-width:700px){
  .hero{padding-top:calc(var(--band-h) - 22px + 4px)}
  .hero::before{left:-18px;right:-18px;top:-22px;height:calc(var(--band-h) - 14px)}
}
@media print{.hero{padding-top:0}.hero::before{display:none}}

/* ---------- 学习目标 ---------- */
.goals{position:relative;margin:26px 0;padding:18px 22px 12px;background:color-mix(in srgb,var(--accent) 22%,var(--edge)) var(--fiber);border-radius:3px;box-shadow:0 0 0 4px var(--edge),var(--lift)}
.goals h3{display:inline-block;margin:0 0 4px;font-size:19px}
.goals .time{float:right;font-family:var(--label);font-size:15px;padding:2px 12px;background:var(--edge);border-radius:20px;box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 60%,#fff)}
.goals ul{margin:.4em 0 .4em;clear:both}

/* ---------- 分节：节号是钉在纸上的纸签，下面一条剪出来的彩纸条 ---------- */
.sec{position:relative;display:flex;align-items:center;gap:14px;margin:46px 0 16px;padding:0 0 14px;cursor:pointer;user-select:none}
.sec::after{content:"";position:absolute;left:2px;right:2px;bottom:0;height:5px;background:var(--accent2);box-shadow:0 0 0 2px var(--edge),0 2px 3px 2px rgba(40,60,90,.14);
  clip-path:polygon(0 0,18% 30%,39% 0,63% 25%,84% 0,100% 20%,100% 100%,78% 75%,55% 100%,31% 72%,12% 100%,0 80%)}
body[data-part="4"] .sec::after{background:#cfe0f0}   /* 云白太浅，纸条换成淡云灰才看得见 */
.sec .n{position:relative;flex:none;display:grid;place-items:center;width:46px;height:42px;margin:6px 2px 2px;font-family:var(--label);font-size:21px;color:var(--ink);
  background:var(--accent) var(--fiber);border-radius:2px;box-shadow:0 0 0 3px var(--edge),2px 4px 5px 3px rgba(40,60,90,.22);transform:rotate(-3deg)}
.sec .n::before{content:"";position:absolute;top:-5px;left:50%;width:8px;height:8px;margin-left:-4px;border-radius:50%;
  background:radial-gradient(circle at 35% 35%,#fff 0 18%,#f39a8c 30%,#c95a4e 100%);box-shadow:0 1px 1px rgba(0,0,0,.3)}
.sec:nth-of-type(even) .n{transform:rotate(2deg)}
.sec h2{flex:1;margin:0;min-width:0}
.sec .caret{flex:none;display:grid;place-items:center;width:44px;height:44px;font-size:18px;color:var(--muted);transition:transform .2s}
.sec.folded .caret{transform:rotate(-90deg)}
.sec:hover h2{color:var(--deep)}
.sec-body.collapsed{display:none}
.sec-body > h3,main > h3{position:relative;padding-left:20px}
.sec-body > h3::before,main > h3::before{content:"";position:absolute;left:2px;top:.3em;width:9px;height:.95em;background:var(--accent);box-shadow:0 0 0 2px var(--edge),1px 2px 2px 1px rgba(40,60,90,.16);transform:rotate(-4deg)}
/* 分隔：一串纸三角彩旗 */
hr{border:none;height:22px;margin:30px 0;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='22'%3E%3Cpath d='M0 3 Q48 8 96 3' stroke='%237a8aa0' stroke-width='1.2' fill='none'/%3E%3Cg stroke='%23fffdf7' stroke-width='1.6' stroke-linejoin='round'%3E%3Cpath d='M4 4 L18 5.4 L11 19 Z' fill='%238fd3f4'/%3E%3Cpath d='M28 6 L42 6.4 L35 20 Z' fill='%23a6dc7a'/%3E%3Cpath d='M52 6.4 L66 6 L59 20 Z' fill='%23ffc49b'/%3E%3Cpath d='M76 5.4 L90 4 L83 19 Z' fill='%23cbbcf2'/%3E%3C/g%3E%3C/svg%3E") repeat-x center/96px 22px}

/* ---------- 插画框（common.js 把 <span data-illus> 换成 SVG 后加 .illus） ---------- */
.illus{display:block;line-height:0;background:#fdfaf1;border-radius:2px;box-shadow:0 0 0 5px var(--edge),3px 5px 10px 5px rgba(40,60,90,.16)}
.illus svg{display:block;width:100%;height:auto}
.illus-miss{min-height:70px;background:repeating-linear-gradient(45deg,#eef3f6 0 10px,#e3ecf2 10px 20px);box-shadow:0 0 0 3px var(--edge)}

/* ---------- 图与图注：自动编号"图 N" ---------- */
figure.fig{margin:24px 0;padding:0}
figure.fig > svg,figure.fig > img,figure.fig > canvas,figure.fig > .illus{display:block;max-width:100%;height:auto;margin:0 auto}
figure.fig > figcaption{margin-top:12px;font-size:15.5px;font-weight:500;color:var(--ink2);line-height:1.65}
figure.fig > figcaption[data-n]::before{content:"图 " attr(data-n) "　";font-family:var(--label);font-weight:400;color:var(--deep)}
figure.fig.photo{position:relative}
figure.fig.photo > img{background:#fff;padding:8px 8px 10px;box-shadow:0 0 0 1px #e8e1d0,3px 6px 12px 3px rgba(40,60,90,.2);transform:rotate(-.6deg)}
figure.fig.photo::before{content:"";position:absolute;top:-8px;left:50%;width:84px;height:22px;margin-left:-42px;z-index:1;background:color-mix(in srgb,var(--accent2) 60%,#fff);opacity:.85;transform:rotate(-3deg);box-shadow:0 1px 2px rgba(0,0,0,.12)}
@media(min-width:720px){
  figure.fig.side{float:right;width:42%;margin:6px 0 14px 24px}
  figure.fig.side ~ :not(p,ul,ol,figure.side,.term-tip){clear:both}
}

/* ---------- 图文并排：图顶端和文字对齐，文字比图长就绕到图下方从左边接着排 ---------- */
.withimg{display:flow-root;margin:18px 0}
.withimg > p:first-of-type{margin-top:0}
/* 宽屏：文字一栏、图片一栏，两栏顶端对齐，文字不绕到图下面（用户 2026-10-21：绕排留下大片空白，改成一边文字一边图）。图太高时加 .narrow 变窄 */
@media(min-width:601px){
  .withimg{display:grid;grid-template-columns:minmax(0,38%) minmax(0,1fr);column-gap:28px;align-items:start}
  .withimg.rev{grid-template-columns:minmax(0,1fr) minmax(0,38%)}
  .withimg.narrow{grid-template-columns:minmax(0,28%) minmax(0,1fr)}
  .withimg.narrow.rev{grid-template-columns:minmax(0,1fr) minmax(0,28%)}
  .withimg > .illus,.withimg > [data-illus],.withimg > img,.withimg > figure{grid-column:1;grid-row:1 / span 20;float:none;width:auto;max-width:none;margin:6px 0 12px}
  .withimg.rev > .illus,.withimg.rev > [data-illus],.withimg.rev > img,.withimg.rev > figure{grid-column:2}
  .withimg > figure.fig.side{float:none;width:auto;margin:6px 0 12px}
  .withimg > :not(.illus):not([data-illus]):not(img):not(figure){grid-column:2}
  .withimg.rev > :not(.illus):not([data-illus]):not(img):not(figure){grid-column:1}
}
/* 自动平衡（js/layout.js 量过后加类）：--wi-w 是图那一栏的宽度；wi-stack 上下排；wi-wrap 图靠边、文字绕排 */
@media(min-width:601px){
  .withimg[style*="--wi-w"]{grid-template-columns:var(--wi-w) minmax(0,1fr)}
  .withimg.rev[style*="--wi-w"]{grid-template-columns:minmax(0,1fr) var(--wi-w)}
  .withimg.wi-stack{grid-template-columns:minmax(0,1fr)}
  .withimg.wi-stack > .illus,.withimg.wi-stack > [data-illus],.withimg.wi-stack > img,.withimg.wi-stack > figure{grid-column:1;grid-row:auto;width:100%;max-width:380px;margin:6px auto 16px}
  .withimg.wi-stack > :not(.illus):not([data-illus]):not(img):not(figure){grid-column:1}
  .withimg.wi-wrap{display:flow-root}
  .withimg.wi-wrap > .illus,.withimg.wi-wrap > [data-illus],.withimg.wi-wrap > img,.withimg.wi-wrap > figure,
  .withimg.wi-wrap.rev > .illus,.withimg.wi-wrap.rev > [data-illus],.withimg.wi-wrap.rev > img,.withimg.wi-wrap.rev > figure{float:left;width:var(--wi-w,38%);max-width:none;margin:6px 28px 12px 0}
  .withimg.wi-wrap.rev > .illus,.withimg.wi-wrap.rev > [data-illus],.withimg.wi-wrap.rev > img,.withimg.wi-wrap.rev > figure{float:right;margin:6px 0 12px 28px}
}
@media(max-width:600px){.withimg > .illus,.withimg > [data-illus],.withimg > img,.withimg.rev > .illus,.withimg.rev > [data-illus],.withimg.rev > img{float:none;width:auto;max-width:340px;margin:6px auto 16px}}

/* ---------- 概念卡：核心概念讲完例子后立刻点明（用户 2026-10-21：要把概念凸显出来，读者一眼知道在讲什么）----------
   写法：<div class="concept"><span class="c-tag">概念</span><h3>概念名</h3><p class="c-def">一句话定义。</p><p class="c-eg">例子：回指刚才的例子。</p></div>
   每章 1–3 张（核心概念各一张），先例子后卡片；卡片里的话要比正文更短、更白。 */
.concept{position:relative;margin:26px 0;padding:14px 20px 12px 22px;background:#fffdf7;border-radius:3px;border-left:9px solid var(--accent2);
  box-shadow:0 0 0 3px var(--edge,#fff),3px 5px 9px 3px rgba(40,60,90,.18)}
.concept .c-tag{display:inline-block;margin:0 0 4px;padding:1px 12px 0;border-radius:2px;background:var(--accent);color:var(--ink,#1d2140);font-family:var(--label);font-size:15px;letter-spacing:.06em}
.concept h3{margin:2px 0 6px;font-size:21px;line-height:1.4}
.concept h3 .c-en{margin-left:8px;font-family:var(--body);font-size:15px;font-weight:400;letter-spacing:0;color:#4a5272}
.concept .c-lbl{display:inline-block;margin-right:8px;padding:0 9px;border-radius:2px;background:#e8f0f8;font-family:var(--label);font-size:14px;color:#2c3250;vertical-align:1px}
.concept .c-def{margin:4px 0;font-size:18px;line-height:1.8;font-weight:500;color:var(--ink,#1d2140)}
.concept .c-eg{margin:6px 0 2px;font-size:15.5px;line-height:1.7;color:#2c3250}
.concept ol,.concept ul{margin:6px 0 4px;padding-left:1.4em;font-size:17px;line-height:1.75}
/* 本章背包道具放在它对应的概念卡右上角：<span class="c-ic" data-illus="gear-01"></span> */
.concept .c-ic{float:right;width:72px;margin:0 0 6px 14px;line-height:0}
.concept .c-ic .illus{background:transparent;box-shadow:none}

/* ---------- 各种"纸片块"：有实体的才是一张纸（白边 + 投影），左上角贴一枚小标签说明它是什么 ---------- */
:is(.why-box,.philo,.misc,.reflect,.key,.tldr,.reveal,.try){position:relative;margin:26px 0;padding:18px 22px 12px;border-radius:3px}
:is(.why-box,.philo,.misc,.reflect,.key,.tldr)::before{position:absolute;top:-13px;left:14px;padding:1px 12px 0;font-family:var(--label);font-size:15px;color:var(--ink);border-radius:2px;
  box-shadow:0 0 0 2.5px var(--edge),1px 2px 4px 1px rgba(40,60,90,.18);transform:rotate(-2deg)}
.why-box{background:color-mix(in srgb,var(--accent) 16%,var(--edge)) var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift)}
.why-box::before{content:"为什么成立";background:var(--accent)}
.philo{background:#f4f0fb var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift)}
.philo::before{content:"哲学时刻";background:#d9cdf5}
.misc{background:#fff4ec;box-shadow:0 0 0 4px var(--edge),var(--lift)}
.misc::before{content:"常见误区";background:#ffc9b5}
.reflect{background:#f1f6f9;box-shadow:0 0 0 4px var(--edge),var(--lift)}
.reflect::before{content:"反思与争议";background:#cfe2ee}
.key{background:color-mix(in srgb,var(--accent2) 22%,var(--edge));box-shadow:0 0 0 4px var(--edge),var(--lift)}
.key::before{content:"要点";background:var(--accent2)}
body[data-part="4"] .key::before{background:#dbe7f3}
.tldr{padding:16px 22px;font-size:19px;background:var(--edge);box-shadow:0 0 0 4px color-mix(in srgb,var(--accent) 60%,#fff),var(--lift)}
.tldr::before{content:"一句话";background:#ffe39a}
:is(.why-box,.philo,.misc,.reflect,.key) > :first-child{margin-top:.3em}
.why-box .src,.philo .src{margin-top:10px;padding-top:8px;border-top:1.5px dashed #c9bfa8}
/* 旁注、操作提示 */
.note{margin:14px 0;padding:6px 0 6px 16px;font-size:15.5px;font-weight:500;color:var(--ink2);border-left:4px solid color-mix(in srgb,var(--accent) 80%,#fff);line-height:1.7}
.hint{position:relative;margin:10px 0;padding-left:28px;font-size:15.5px;font-weight:500;color:var(--ink2);line-height:1.7}
.hint::before{content:"";position:absolute;left:4px;top:.35em;width:16px;height:14px;background:var(--deep);clip-path:polygon(0 30%,55% 30%,55% 0,100% 50%,55% 100%,55% 70%,0 70%)}

/* ---------- 先猜后揭晓 .reveal ---------- */
.reveal{background:var(--edge) var(--fiber);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 55%,#fff),var(--lift)}
.reveal .ans{display:none;margin-top:10px;padding-top:10px;border-top:2px dashed color-mix(in srgb,var(--accent) 70%,#999)}
.reveal.open .ans{display:block}
.reveal.open [data-reveal]{background-color:#c9eab4}

/* ---------- 试试看 .try（完成后 .done） ---------- */
.try{padding:12px 18px 12px 52px;background:#fffbe6;box-shadow:0 0 0 3px var(--edge),var(--lift);transform:rotate(-.3deg)}
.try::before{content:"";position:absolute;left:14px;top:14px;width:24px;height:24px;border-radius:3px;background:var(--edge);box-shadow:0 0 0 2.5px #c9b98d}
.try.done{background:var(--okbg)}
.try.done::before{background:var(--ok);box-shadow:0 0 0 2.5px var(--edge)}
.try.done::after{content:"";position:absolute;left:20px;top:17px;width:8px;height:14px;border:solid #fff;border-width:0 3.5px 3.5px 0;transform:rotate(45deg)}
.try > b:first-child{color:var(--ink);text-decoration:none;font-family:var(--label);font-weight:400}

/* ---------- 术语：悬停 / 聚焦显示释义（释义框由 common.js 生成，fixed 定位并夹在视口内，手机不会撑出横向滚动） ---------- */
.term{text-decoration:underline dotted var(--deep) 2.5px;text-underline-offset:.28em;cursor:help;border-radius:2px}
.term:hover,.term:focus{background:color-mix(in srgb,var(--accent) 35%,transparent)}
.term-tip{position:fixed;z-index:90;max-width:min(300px,calc(100vw - 24px));padding:9px 13px;font-size:15px;font-weight:500;line-height:1.6;color:var(--ink);pointer-events:none;
  background:var(--edge) var(--fiber);border-radius:3px;box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 70%,#fff),3px 6px 14px 2px var(--shadow);display:none}
.term-tip.show{display:block}
.term-tip b{display:block;font-family:var(--label);font-weight:400;text-decoration:none;color:var(--deep)}

/* ---------- 进阶抽屉 ---------- */
details.deep{margin:26px 0;border-radius:3px;background:#f6efdf;box-shadow:0 0 0 3px var(--edge),var(--lift)}
details.deep > summary{display:flex;align-items:center;gap:10px;min-height:48px;padding:8px 16px;cursor:pointer;list-style:none;font-family:var(--label);font-size:17px}
details.deep > summary::-webkit-details-marker{display:none}
details.deep > summary::before{content:"";flex:none;width:26px;height:20px;border-radius:2px 6px 2px 2px;background:var(--kraft);box-shadow:0 0 0 2px var(--edge);clip-path:polygon(0 0,40% 0,50% 18%,100% 18%,100% 100%,0 100%)}
details.deep > summary::after{content:"▾";margin-left:auto;color:var(--muted);transition:transform .2s}
details.deep[open] > summary::after{transform:rotate(180deg)}
.deep-b{padding:4px 22px 14px;border-top:2px dashed #d6c7a4}
/* 选读：有标题和一句介绍，点按钮展开；不读也不影响后面。写法：
   <details class="deep"><summary><span class="dp-tag">选读</span><span class="dp-t"><b>标题</b><small>一句话介绍：这里讲什么，为什么值得看</small></span><span class="dp-btn" aria-hidden="true"></span></summary><div class="deep-b">…</div></details> */
details.deep > summary:has(.dp-t){align-items:center;padding:10px 16px}
details.deep > summary:has(.dp-t)::after{content:none}
.dp-tag{flex:none;padding:1px 10px 0;border-radius:2px;background:#ffe9a8;box-shadow:0 0 0 2px var(--edge);font-size:14px;line-height:22px}
.dp-t{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.dp-t b{font-family:var(--label);font-weight:400;font-size:17px;line-height:1.35}
.dp-t small{font-family:var(--body);font-size:14px;line-height:1.5;color:var(--muted)}
.dp-btn{flex:none;padding:3px 14px 2px;border-radius:999px;background:#fff;box-shadow:0 0 0 2px var(--edge);font-size:14px;line-height:22px;white-space:nowrap}
.dp-btn::before{content:"展开 ▾"}
details.deep[open] .dp-btn::before{content:"收起 ▴"}
details.deep > summary:focus-visible{outline:3px solid var(--deep);outline-offset:3px}
@media (max-width:600px){details.deep > summary:has(.dp-t){flex-wrap:wrap}.dp-t{flex-basis:calc(100% - 70px)}}
@media print{details.deep:not([open]) > .deep-b{display:block}}

/* ---------- 互动板与按钮 ---------- */
.board{position:relative;margin:26px 0;padding:18px 18px 14px;border-radius:3px;background:var(--edge) var(--fiber);
  box-shadow:0 0 0 5px var(--edge),7px 9px 0 5px var(--kraft),10px 16px 26px 4px var(--shadow)}
.board canvas,.board svg{max-width:100%;touch-action:none}
.board h4:first-child{margin-top:0}
@media(max-width:700px){.board{padding:14px 10px 10px;box-shadow:0 0 0 4px var(--edge),4px 6px 0 4px var(--kraft),6px 10px 18px 3px var(--shadow)}}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;min-width:44px;margin:8px 10px 8px 4px;padding:6px 18px 4px;border:none;border-radius:3px;cursor:pointer;
  font-family:var(--label);font-size:18px;line-height:1.35;color:var(--ink);text-decoration:none;background:var(--accent) var(--fiber);
  box-shadow:0 0 0 3px var(--edge),2px 4px 6px 2px rgba(40,60,90,.22);transition:transform .08s,box-shadow .08s}
.btn:hover{transform:translateY(-1px) rotate(-.5deg);box-shadow:0 0 0 3px var(--edge),3px 6px 9px 2px rgba(40,60,90,.24)}
.btn:active{transform:translateY(1px);box-shadow:0 0 0 3px var(--edge),1px 2px 3px 1px rgba(40,60,90,.2)}
.btn:disabled{opacity:.55;cursor:default;transform:none;filter:grayscale(.4)}
.btn.alt{background-color:#fffdf7}
.btn.green{background-color:#bfe8a6}
.btn.pink{background-color:#ffc9c0}
.btn.ghost{background:transparent;box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 70%,#999)}
.chip{display:inline-flex;align-items:center;min-height:44px;margin:5px;padding:4px 14px 2px;border:none;border-radius:22px;cursor:pointer;font-family:var(--label);font-size:16px;color:var(--ink);
  background:var(--edge);box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 70%,#aaa),1px 2px 4px 1px rgba(40,60,90,.16)}
.chip.on,.chip.right{background:#c9eab4;box-shadow:0 0 0 2px var(--ok)}
.chip.wrong{background:var(--nobg);box-shadow:0 0 0 2px var(--no)}
.chip.miss{background:var(--warnbg);outline:2px dashed #7a6a48;outline-offset:2px}
input[type=range]{width:100%;min-height:36px;accent-color:var(--deep)}
textarea{width:100%;min-height:130px;padding:12px 14px;border:none;border-radius:3px;line-height:1.9;resize:vertical;background:#fffdf7;
  background-image:repeating-linear-gradient(transparent 0 calc(1.9em - 1px),#e6dcc6 calc(1.9em - 1px) 1.9em);background-attachment:local;box-shadow:0 0 0 3px #efe6d2,inset 0 1px 3px rgba(0,0,0,.06)}

/* ---------- 例子轮播：连续的 .eg 由 common.js 合并成 .egcar ---------- */
.eg{margin:20px 0;padding:14px 18px;border-radius:3px;background:var(--edge);box-shadow:0 0 0 3px color-mix(in srgb,var(--accent) 50%,#fff)}
.eg.bad{box-shadow:0 0 0 3px #ffc9b5}
.egcar{margin:26px 0;border-radius:3px;background:var(--edge) var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift)}
.egtabs{display:flex;gap:6px;overflow-x:auto;padding:12px 12px 4px;scrollbar-width:thin}
.egtab{flex:none;min-height:44px;padding:4px 14px 2px;border:none;border-radius:3px 3px 0 0;cursor:pointer;font-family:var(--label);font-size:15.5px;color:var(--ink);background:#efe9db}
.egtab.on{background:var(--accent)}
.egtab.bad{background:#ffe2d8}
.egtab.bad.on{background:#ffb9a3}
.egstage{position:relative;display:grid;grid-template-columns:44px 1fr 44px;align-items:center;gap:4px;padding:6px 6px 0}
.egstage > .eg{grid-column:2;grid-row:1;display:none;margin:6px 0;box-shadow:none;background:transparent;padding:6px 6px}
.egstage > .eg.on{display:block}
.egnav{grid-row:1;width:44px;height:44px;border:none;border-radius:50%;cursor:pointer;font-size:15px;color:var(--ink);background:color-mix(in srgb,var(--accent) 50%,var(--edge));box-shadow:0 0 0 2px var(--edge),1px 2px 4px rgba(40,60,90,.2)}
.egnav.prev{grid-column:1}.egnav.next{grid-column:3}
.egk{display:inline-block;margin-right:8px;padding:0 9px;font-family:var(--label);font-size:14px;border-radius:2px;background:color-mix(in srgb,var(--accent) 60%,#fff);vertical-align:2px}
.eg.bad .egk{background:#ffc9b5}
.eg.hasimg.on{display:grid;grid-template-columns:minmax(0,40%) 1fr;gap:18px;align-items:start}
.eg.hasimg > .illus{margin:6px}
.egcount{padding:2px 0 10px;text-align:center;font-size:14px;font-weight:500;color:var(--muted)}
@media(max-width:600px){
  .egstage{grid-template-columns:1fr 1fr;padding:6px 8px 0}
  .egstage > .eg{grid-column:1 / -1;grid-row:1}
  .egnav{grid-row:2;justify-self:center}.egnav.prev{grid-column:1}.egnav.next{grid-column:2}
  .eg.hasimg.on{grid-template-columns:1fr}
  .eg.hasimg > .illus{max-width:320px;margin:6px auto}
}

/* ---------- 测验 DS.mountQuiz ---------- */
.quiz{margin:20px 0}
.quiz .q{margin:18px 0;padding:16px 18px 10px;border-radius:3px;background:var(--edge) var(--fiber);box-shadow:0 0 0 3px #efe6d2,var(--lift)}
.quiz .qt{margin-bottom:8px;font-weight:700;line-height:1.7}
.quiz .opt{display:block;width:100%;min-height:44px;margin:8px 0;padding:8px 14px;border:none;border-radius:3px;cursor:pointer;text-align:left;line-height:1.6;
  background:#fffdf7;box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 60%,#bbb)}
.quiz .opt:hover:not(:disabled){background:color-mix(in srgb,var(--accent) 25%,#fff)}
.quiz .opt.ok{background:var(--okbg);box-shadow:0 0 0 2.5px var(--ok);color:var(--ink)}
.quiz .opt.ok::before{content:"✓ ";color:var(--ok);font-weight:700}
.quiz .opt.no{background:var(--nobg);box-shadow:0 0 0 2px var(--no);text-decoration:line-through;text-decoration-color:var(--no)}
.quiz .opt:disabled{cursor:default;opacity:1}
.quiz .opt.no:disabled,.quiz .opt:disabled:not(.ok){color:var(--ink2)}
.quiz .why{display:none;margin:8px 0 6px;padding:10px 14px;font-size:16px;line-height:1.75;background:#f3f8ee;border-left:4px solid var(--ok)}
.quiz .why.show{display:block}
/* 练习题横向翻页：一次一题（用户 2026-10-21：重复的元素都横向翻阅） */
.quiz .qtrack{display:flex;gap:18px;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;align-items:flex-start;padding:6px 4px 12px;scrollbar-width:thin}
.quiz .qtrack:focus-visible{outline:3px dashed var(--accent2);outline-offset:2px}
.quiz .qtrack > .q{flex:0 0 100%;min-width:0;box-sizing:border-box;margin:0;scroll-snap-align:start}
.quiz .qbar{display:flex;align-items:center;gap:10px;margin:4px 0 6px}
.quiz .qnav{flex:none;min-width:44px;min-height:44px;border:0;border-radius:50%;cursor:pointer;font-size:18px;color:var(--ink);background:#fffdf7;box-shadow:0 0 0 3px var(--edge),2px 3px 5px 2px rgba(40,60,90,.2)}
.quiz .qnav:disabled{opacity:.35;cursor:default}
.quiz .qdots{flex:1;display:flex;flex-wrap:wrap;gap:8px;justify-content:center}
.quiz .qdot{min-width:40px;min-height:40px;border:0;border-radius:50%;cursor:pointer;font-family:var(--label);font-size:16px;color:var(--ink);background:#fffdf7;box-shadow:0 0 0 2px #cdbf9c}
.quiz .qdot.on{background:var(--accent);box-shadow:0 0 0 3px var(--accent2)}
.quiz .qdot.ok::after{content:"✓";margin-left:1px;color:var(--ok);font-weight:700}
.quiz .qnext{margin:6px 0 8px}
.quiz .score{margin-top:14px;font-family:var(--label);font-size:16px;color:var(--ink2)}
@media print{.quiz .qtrack{display:block;overflow:visible}.quiz .qtrack > .q{margin:12px 0}.quiz .qbar,.quiz .qnext{display:none}}
.quiz .done-badge{display:none;margin-top:10px;padding:10px 16px;font-family:var(--label);font-size:18px;background:var(--okbg);border-radius:3px;box-shadow:0 0 0 3px var(--edge),var(--lift)}
.quiz .done-badge.show{display:inline-block}

/* ---------- 先猜后看 .guess ---------- */
.guess{margin:26px 0;padding:16px 20px 12px;border-radius:3px;background:var(--edge) var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift)}
.guess .g-q{margin-top:0;font-weight:700}
.g-ctl{display:flex;flex-wrap:wrap;align-items:center;gap:4px 12px}
.g-ctl label{font-family:var(--label);font-size:15px}
.g-ctl output{font-weight:700;color:var(--deep)}
.g-track{position:relative;height:46px;margin:22px 10px 0}
.g-line{position:absolute;left:0;right:0;top:30px;height:4px;background:#e2d8c2;border-radius:2px}
.g-span{position:absolute;top:28px;height:8px;background:#ffc9b5;border-radius:3px}
.g-mk{position:absolute;top:22px;width:4px;height:20px;margin-left:-2px;border-radius:2px}
.g-mk.you{background:var(--deep)}
.g-mk.ans{display:none;background:var(--ok)}
.guess.done .g-mk.ans{display:block}
.guess:not(.done) .g-span{display:none}
.g-mk span{position:absolute;bottom:22px;left:50%;transform:translateX(-50%);white-space:nowrap;font-size:13.5px;font-weight:500;padding:0 6px;border-radius:2px;background:var(--edge);box-shadow:0 0 0 1.5px #e2d8c2}
.g-mk.ans span{bottom:auto;top:22px}
.g-mk[data-al="l"] span{left:0;transform:none}.g-mk[data-al="r"] span{left:auto;right:0;transform:none}
.g-track{margin-bottom:22px}
.g-ends{display:flex;justify-content:space-between;font-size:13.5px;font-weight:500;color:var(--muted)}
.g-res{font-weight:700;min-height:1.5em}
.guess .g-ans{display:none;margin-top:8px;padding-top:8px;border-top:2px dashed #d6c7a4}
.guess.done .g-ans{display:block}

/* ---------- 翻牌 .flip ---------- */
.flip{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:18px;margin:26px 0}
.flip-c{position:relative;min-height:150px;cursor:pointer;perspective:900px;border-radius:3px}
.f-in{position:relative;width:100%;height:100%;min-height:150px;transition:transform .45s;transform-style:preserve-3d}
.flip-c.flipped .f-in{transform:rotateY(180deg)}
.f-front,.f-back{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;padding:14px 16px;border-radius:3px;backface-visibility:hidden;-webkit-backface-visibility:hidden;line-height:1.65;
  box-shadow:0 0 0 4px var(--edge),var(--lift)}
.f-front{background:color-mix(in srgb,var(--accent) 30%,var(--edge)) var(--fiber);font-family:var(--label);font-size:18px;text-align:center}
.f-back{background:var(--edge) var(--fiber);transform:rotateY(180deg);font-size:16px}
.flip-c:focus-visible{outline:none}
.flip-c:focus-visible .f-in{outline:3px solid var(--deep);outline-offset:6px}

/* ---------- 前后对比 .compare ---------- */
.compare{margin:26px 0}
.cmp-hd{display:flex;justify-content:space-between;gap:8px;font-family:var(--label);font-size:15px;margin-bottom:8px}
.cmp-tip{color:var(--muted);font-family:var(--body);font-weight:500;font-size:14px}
.cmp-view{position:relative;overflow:hidden;border-radius:3px;box-shadow:0 0 0 4px var(--edge),var(--lift);touch-action:none;cursor:ew-resize;--pos:50%}
.cmp-a{position:relative}
.cmp-b{position:absolute;inset:0;clip-path:inset(0 0 0 var(--pos))}
.cmp-a > *,.cmp-b > *{display:block;width:100%}
.cmp-h{position:absolute;top:0;bottom:0;left:var(--pos);width:44px;margin-left:-22px;display:grid;place-items:center}
.cmp-h::before{content:"";position:absolute;top:0;bottom:0;left:50%;width:4px;margin-left:-2px;background:var(--edge);box-shadow:0 0 4px rgba(0,0,0,.25)}
.cmp-h i{position:relative;width:30px;height:30px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 3px var(--edge),0 2px 4px rgba(0,0,0,.25)}

/* ---------- 逐步 .stepper ---------- */
.stepper{margin:26px 0;padding:14px 18px 10px;border-radius:3px;background:var(--edge) var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift)}
.st-hd{font-family:var(--label);font-size:18px;margin-bottom:8px}
.st-stage{margin:6px 0 10px}
.st-stage svg{display:block;max-width:100%;height:auto;margin:0 auto}
.st-off{opacity:0;transition:opacity .3s}
.st-on{filter:drop-shadow(0 0 4px color-mix(in srgb,var(--accent) 90%,#fff))}
.st-steps{margin:0;padding:0;list-style:none}
.st-steps li{display:none;padding:8px 2px}
.st-steps li.on{display:block}
.st-steps li::before{content:attr(data-k) "　";font-family:var(--label);color:var(--deep)}
.st-bar{display:flex;flex-wrap:wrap;align-items:center;gap:6px;padding-top:8px;border-top:2px dashed #e2d8c2}
.st-bar button{min-width:44px;min-height:44px;padding:0 12px;border:none;border-radius:3px;cursor:pointer;font-family:var(--label);font-size:15px;background:color-mix(in srgb,var(--accent) 55%,var(--edge));box-shadow:0 0 0 2px var(--edge),1px 2px 4px rgba(40,60,90,.18)}
.st-bar button:disabled{opacity:.45;cursor:default}
.st-count{min-width:3.5em;text-align:center;font-weight:700}
.st-dots{display:flex;gap:4px;margin:0 6px}
.st-dots i{width:10px;height:10px;border-radius:2px;background:#e2d8c2}
.st-dots i.on{background:var(--deep)}

/* ---------- 漫画格 .comic ---------- */
.comic{display:grid;grid-template-columns:repeat(var(--n,3),minmax(0,1fr));gap:16px;margin:28px 0;padding:6px}
.comic .cm-hd{grid-column:1 / -1;font-family:var(--label);font-size:18px}
.comic .panel{display:flex;flex-direction:column;background:var(--edge);border-radius:3px;box-shadow:0 0 0 4px var(--edge),var(--lift);overflow:hidden}
.comic .panel > .illus{box-shadow:none;border-radius:0}
.comic .cap{margin:0;padding:8px 12px 10px;font-size:15.5px;font-weight:500;line-height:1.6;border-top:2px dashed #e6dcc6}
.comic .pn{display:inline-grid;place-items:center;width:22px;height:22px;margin-right:6px;font-family:var(--label);font-size:13px;border-radius:50%;background:var(--accent)}
@media(max-width:700px){.comic{grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:78%;overflow-x:auto;scroll-snap-type:x mandatory}.comic .panel{scroll-snap-align:start}.comic .cm-hd{grid-column:auto;grid-row:1}}
@media(max-width:700px){.comic:has(.cm-hd) .panel{grid-row:2}}

/* ---------- 大数字 .bignum ---------- */
.bignum{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:18px;margin:26px 0}
.bn-i{padding:14px 16px;border-radius:3px;background:var(--edge) var(--fiber);box-shadow:0 0 0 4px var(--edge),var(--lift);text-align:center}
.bn-k{font-family:var(--label);font-size:15px;color:var(--ink2)}
.bn-n{font-family:var(--label);font-size:clamp(34px,7vw,46px);line-height:1.2;color:var(--deep)}
.bn-i p{margin:.3em 0 0;font-size:15px;font-weight:500;color:var(--ink2);line-height:1.6}

/* ---------- 你的思考 ---------- */
.mythink{margin:26px 0}
.mythink h3{margin-top:0}

/* ---------- 章末翻页 ---------- */
.pager{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:8px;margin-top:40px;padding-top:20px;border-top:2px dashed #e2d8c2}
.pager a{text-decoration:none}
.pager .pager-off{display:inline-block;margin:8px 4px;font-size:15px;font-weight:500;color:var(--muted)}

/* ---------- 背包：顶栏按钮弹出的面板 + 页面里的背包展示区 ---------- */
.bag-dlg{position:fixed;inset:0;z-index:95;display:none;align-items:center;justify-content:center;padding:16px;background:rgba(160,205,235,.55)}
.bag-dlg.open{display:flex}
.bag-box{position:relative;width:min(760px,100%);max-height:88vh;overflow:auto;padding:22px 22px 18px;border-radius:3px;background:var(--panel) url("../img/paper/fiber-soft.png") 0 0/256px 256px;
  box-shadow:0 0 0 6px var(--edge),8px 10px 0 6px var(--kraft),12px 20px 34px 6px var(--shadow)}
.bag-box h3{margin:0 50px 4px 0}
.bag-box .bag-close{position:absolute;top:10px;right:10px}
.gear-sum{margin:0 0 12px;font-size:15.5px;font-weight:500;color:var(--ink2)}
.gear-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:14px;margin:8px 0}
.gear{display:grid;grid-template-columns:52px 1fr;gap:4px 10px;align-items:start;padding:10px 10px 8px;border-radius:3px;background:var(--edge);box-shadow:0 0 0 3px color-mix(in srgb,var(--c,#8fd3f4) 70%,#fff),var(--lift)}
.gear .g-ic{grid-row:span 2;width:52px;height:52px}
.gear .g-ic .illus{background:transparent;box-shadow:none}
.gear .g-ic .illus-miss{width:52px;height:52px;min-height:0;border-radius:4px;background:var(--c,#8fd3f4);box-shadow:0 0 0 3px var(--edge),1px 2px 3px rgba(0,0,0,.18)}
.gear .g-nm{font-family:var(--label);font-size:16px;line-height:1.4}
.gear .g-nm small{display:block;font-family:var(--body);font-weight:500;font-size:13px;color:var(--muted)}
.gear .g-df{grid-column:1 / -1;margin:4px 0 0;font-size:14.5px;font-weight:500;line-height:1.6;color:var(--ink2)}
.gear.off{background:#f1efe9;box-shadow:0 0 0 3px #e2ded4}
.gear.off .g-ic{filter:brightness(0) opacity(.18)}
.gear.off .g-nm{color:var(--muted)}
.gear.new{animation:ds-pop .5s ease-out}
@keyframes ds-pop{0%{transform:scale(.8)}60%{transform:scale(1.06)}100%{transform:none}}

/* 收进背包的小提示 + 纸屑 */
.ds-toast{position:fixed;left:50%;bottom:26px;z-index:99;display:flex;align-items:center;gap:12px;max-width:calc(100vw - 32px);padding:10px 18px 10px 12px;border-radius:3px;
  background:var(--edge) var(--fiber);box-shadow:0 0 0 4px color-mix(in srgb,var(--accent) 70%,#fff),4px 8px 18px 3px var(--shadow);transform:translate(-50%,0);transition:transform .3s,opacity .3s}
.ds-toast.hide{opacity:0;transform:translate(-50%,30px)}
.ds-toast .g-ic{flex:none;width:44px;height:44px}
.ds-toast .g-ic .illus{background:transparent;box-shadow:none}
.ds-toast .g-ic .illus-miss{width:44px;height:44px;min-height:0;background:var(--accent);box-shadow:0 0 0 3px var(--edge)}
.ds-toast b{font-family:var(--label);font-weight:400;text-decoration:none;color:var(--ink)}
.ds-spark{position:fixed;z-index:98;width:9px;height:7px;pointer-events:none;box-shadow:0 0 0 1.5px var(--edge);animation:ds-spark .8s ease-out forwards}
@keyframes ds-spark{to{transform:translate(var(--dx),var(--dy)) rotate(var(--r));opacity:0}}

/* ============================================================
   目录页：一座纸片塔（index.html；body[data-page="tower"]）
   ============================================================ */
.ix-intro{max-width:760px}
.ix-intro h1{margin-top:0}
.ix-intro .lead{font-size:18.5px}
.tower{position:relative;max-width:620px;margin:10px auto 0;padding:0 14px}
/* 塔顶：三角屋顶 + 小旗 */
.tw-roof{position:relative;height:96px;margin:0 -6px}
.tw-roof::before{content:"";position:absolute;left:0;right:0;bottom:0;height:72px;background:#f9b0a8 var(--fiber);clip-path:polygon(50% 0,100% 100%,0 100%);filter:drop-shadow(0 4px 4px rgba(40,60,90,.2))}
.tw-roof::after{content:"";position:absolute;left:50%;bottom:66px;width:3px;height:30px;margin-left:-1.5px;background:#7a6a58}
.tw-roof i{position:absolute;left:calc(50% + 1.5px);top:0;width:30px;height:18px;background:#ffd25e;clip-path:polygon(0 0,100% 50%,0 100%)}
.tw-body{position:relative;padding:0 12px;background:#efe3c8 var(--fiber);border-radius:2px;box-shadow:0 0 0 5px var(--edge),6px 8px 0 5px #cdb98f,10px 18px 30px 4px var(--shadow)}
/* 四段塔身各一种墙（--tw-wall-N），墙在每层的纸片之间露出来；段与段之间的纸带直接压在两段墙的交界上 */
.tw-seg{position:relative;margin:0 -12px;padding:8px 12px}
.tw-seg.p1{background:var(--tw-wall-1)}
.tw-seg.p2{background:var(--tw-wall-2)}
.tw-seg.p3{background:var(--tw-wall-3)}
.tw-seg.p4{background:var(--tw-wall-4)}
.tw-band{position:relative;z-index:1;margin:0 -26px;padding:6px 18px 4px;text-align:center;font-family:var(--label);font-size:18px;color:var(--ink);background:var(--c);
  box-shadow:0 0 0 3px var(--edge),2px 4px 6px 2px rgba(40,60,90,.2);clip-path:polygon(0 0,100% 0,97% 50%,100% 100%,0 100%,3% 50%);transform:rotate(-.6deg)}
.tw-band small{font-family:var(--body);font-weight:500;font-size:14px;color:var(--ink2);margin-right:8px}
.tw-floor{position:relative;display:grid;grid-template-columns:auto 1fr auto;gap:4px 14px;align-items:center;margin:10px 0;padding:12px 14px;border-radius:2px;color:var(--ink);text-decoration:none;
  background:color-mix(in srgb,var(--c) 38%,var(--edge)) var(--fiber);box-shadow:0 0 0 4px var(--edge),2px 4px 7px 2px rgba(40,60,90,.18);transition:transform .12s}
.tw-floor:nth-child(odd){transform:rotate(-.35deg)}
.tw-floor:nth-child(even){transform:rotate(.3deg)}
a.tw-floor:hover{transform:translateY(-2px);background-color:color-mix(in srgb,var(--c) 60%,var(--edge))}
.tw-plate{grid-row:span 2;display:grid;place-items:center;width:58px;min-height:52px;padding:4px;font-family:var(--label);font-size:14px;line-height:1.25;text-align:center;
  background:var(--edge);border-radius:2px;box-shadow:0 0 0 2px var(--c),1px 2px 3px rgba(40,60,90,.2)}
.tw-plate b{display:block;font-size:22px;font-weight:400;text-decoration:none;color:var(--ink)}
.tw-name{font-family:var(--label);font-size:20px;line-height:1.35;min-width:0}
.tw-sub{grid-column:2;font-size:15px;font-weight:500;color:var(--ink2);line-height:1.55;min-width:0}
.tw-side{grid-row:1 / span 2;grid-column:3;display:flex;flex-direction:column;align-items:center;gap:6px}
.tw-win{position:relative;width:34px;height:30px;border-radius:14px 14px 2px 2px;background:#8fa4bd;box-shadow:0 0 0 3px var(--edge),inset 0 0 0 1px rgba(0,0,0,.06)}
.tw-win::before{content:"";position:absolute;left:50%;top:3px;bottom:0;width:2px;margin-left:-1px;background:var(--edge)}
.tw-floor.done .tw-win{background:#ffd25e;box-shadow:0 0 0 3px var(--edge),0 0 14px 3px rgba(255,210,94,.75)}
.tw-gear{width:36px;height:36px}
.tw-gear .illus{background:transparent;box-shadow:none}
.tw-gear .illus-miss{width:36px;height:36px;min-height:0;border-radius:4px;background:var(--c);box-shadow:0 0 0 2px var(--edge)}
.tw-gear.off{filter:grayscale(1) opacity(.35)}
.tw-floor.next{box-shadow:0 0 0 4px var(--edge),0 0 0 7px var(--d,#1f6a96),3px 6px 10px 3px rgba(40,60,90,.22)}
.tw-floor .tw-flag{position:absolute;top:-12px;right:64px;padding:0 10px;font-family:var(--label);font-size:14px;color:var(--ink);background:#ffd25e;border-radius:2px;box-shadow:0 0 0 2px var(--edge);transform:rotate(2deg)}
.tw-floor.off{background:#ecebe6;color:var(--muted);cursor:not-allowed}
.tw-floor.off .tw-name{color:#5d6475}
.tw-floor.off .tw-plate{box-shadow:0 0 0 2px #cfcbc0}
.tw-floor.off .tw-wip{display:inline-block;margin-left:8px;padding:0 8px;font-family:var(--body);font-weight:500;font-size:13px;vertical-align:3px;color:#5d4a20;background:repeating-linear-gradient(45deg,#ffe08a 0 6px,#fff3c4 6px 12px);border-radius:2px}
/* 塔脚：草地小丘 + 门 + 勇士 */
.tw-foot{position:relative;height:150px;margin:0 -40px}
.tw-foot .tw-grass{position:absolute;left:0;right:0;bottom:0;height:70px;background:#62b763 var(--fiber);border-radius:50% 50% 0 0 / 60px 60px 0 0;box-shadow:0 -4px 0 var(--edge)}
.tw-foot .tw-door{position:absolute;left:50%;bottom:58px;width:64px;height:84px;margin-left:-32px;background:#b98a5c var(--fiber);border-radius:32px 32px 2px 2px;box-shadow:0 0 0 4px var(--edge),2px 4px 6px rgba(40,60,90,.25)}
.tw-foot .tw-door::after{content:"";position:absolute;right:12px;top:46px;width:7px;height:7px;border-radius:50%;background:#ffd25e}
.tw-foot .tw-hero{position:absolute;left:calc(50% - 170px);bottom:40px;width:130px}
.tw-foot .tw-hero .illus{background:transparent;box-shadow:none}
.tw-foot .tw-hero .illus-miss{background:none;box-shadow:none}
@media(max-width:600px){
  .tower{padding:0 6px}
  .tw-body{padding:0 8px}
  .tw-band{margin:0 -14px;font-size:16px}
  .tw-seg{margin:0 -8px;padding:6px 8px}
  .tw-floor{grid-template-columns:auto 1fr auto;gap:2px 10px;padding:10px 10px}
  .tw-plate{width:50px;min-height:46px;font-size:13px}
  .tw-name{font-size:18px}
  .tw-sub{grid-column:1 / -1;margin-top:6px}
  .tw-side{grid-row:1;gap:4px}
  .tw-foot{margin:0 -6px}   /* 只抵消 .tower 的 6px 内边距，再宽就撑出横向滚动 */
  .tw-foot .tw-hero{left:calc(50% - 140px);width:100px}
  .tw-floor .tw-flag{right:54px}
}
.ix-routes .route{display:flex;flex-wrap:wrap;align-items:center;gap:4px;margin:8px 0 14px}
.ix-routes .route h4{width:100%;margin:6px 0 2px}
.ix-routes .chip.off{opacity:.6;cursor:not-allowed;box-shadow:0 0 0 2px #d3cfc4;background:#f1efe9}
.ix-routes .chip span{font-size:13px;margin-left:4px;font-family:var(--body);font-weight:500;color:var(--muted)}

/* ---------- 打印：去掉天空草地和浮动控件，分节全展开 ---------- */
@media print{
  html,body{background:#fff!important}
  body::before,body::after,.topbar,.navfab,.navpanel,.readbar,.pager,.bag-dlg,.ds-toast,.ds-spark,.term-tip,.egnav,.egtabs,.st-bar,.g-bar{display:none!important}
  .wrap{box-shadow:none;margin:0 auto;max-width:none;background:#fff}
  .sec-body.collapsed{display:block!important}
  .egstage > .eg{display:block!important}
  .reveal .ans,.guess .g-ans,.quiz .why{display:block!important}
  .st-steps li{display:block!important}
  .st-off{opacity:1!important}
  .f-back{position:relative;transform:none}
  .f-in{transform:none!important}
}

/* ---------- 减少动态：关掉所有过渡与动画 ---------- */
@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
  .ds-spark{display:none}
}
