/* 首页（home）的手机覆盖样式。只在 ≤767px 生效。依据《手机适配规则.md》第〇节、work\home\plan.md。
   第 0 章（01 主打作品）：引擎当 pin（4 步），画框 4:3，姓名叠在第一个画面上；第 1–6 章（分组卡片、联系）：引擎当 text，版式在这里。 */
@media (max-width:767px){

/* ---------- 第 0 章：画面 ---------- */
/* 穿梭机：星空铺满画框，飞船放大到画框宽度的 140% 居中偏下（给姓名让位）；引擎对 .fbox img 一律 cover，这里用更高优先级改回 contain */
html.md .sp section[data-ch="0"] .fbox img.ship{position:absolute;left:50%;top:56%;right:auto;bottom:auto;width:140%;height:auto;max-width:none;aspect-ratio:2400/1004;transform:translate(-50%,-50%);object-fit:contain}
html.md .sp section[data-ch="0"] .fbox img.stars{object-fit:cover}
html.md .sp section[data-ch="0"] .fbox video{object-position:50% 50%}
html.md .sp section[data-ch="0"] .layer:nth-child(4) .fbox video,html.md .sp section[data-ch="0"] .mstep:nth-child(4) .fbox video{object-position:58% 50%}

/* ---------- 第 0 章：姓名叠在第一个画面上（home.js 把 .ov.intro 移进画框；透明度由页面脚本随滚动淡出） ---------- */
html.md .sp section[data-ch="0"] .ov.intro{position:absolute;inset:0;top:0;left:0;max-width:none;z-index:4;box-sizing:border-box;padding:16px var(--g) 0;pointer-events:none;
  background:linear-gradient(to bottom,rgba(4,5,7,.9),rgba(4,5,7,.72) 60%,rgba(4,5,7,.25))}
html.md .sp section[data-ch="0"] .ov.intro h1{font-size:36px;line-height:1.15;letter-spacing:.12em}
html.md .sp section[data-ch="0"] .ov.intro .lead{font-size:16px;margin:6px 0 0}
html.md .sp section[data-ch="0"] .ov.intro .sub{font-size:13px;line-height:1.5;margin:6px 0 0;text-wrap:balance}
/* 降级成直接展示时：姓名是第一块，静态显示 */
html.md .sp section[data-ch="0"] .mhi{margin-bottom:48px;opacity:1;transform:none}
html.md .sp section[data-ch="0"] .mhi .ov.intro{position:static;opacity:1!important;padding:0 var(--g);background:none;max-width:none}
html.md .sp section[data-ch="0"][data-m="flow"] .chap{opacity:1!important}

/* ---------- 第 0 章：说明（kw + dock.nums） ---------- */
html.md .sp section[data-ch="0"] .mcap .dock.nums{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;align-items:start;margin-top:14px}
html.md .sp section[data-ch="0"] .mcap .dock.nums small{max-width:none;margin-top:4px;font-size:12px;line-height:1.45}
html.md .sp section[data-ch="0"] .mcap .go{display:inline-flex;align-items:center;min-height:44px;margin-top:4px;font-size:15px;border-bottom:0}

/* ---------- 第 1–6 章：分组卡片、联系（引擎 text 章） ---------- */
html.md .sp section.cat[data-m="text"]{padding:96px var(--g) 0;background:#040507}
html.md .sp section.cat[data-m="text"] > .cat-head{position:sticky;top:56px;z-index:20;margin:0 calc(-1 * var(--g)) 24px!important;padding:12px var(--g) 10px!important;gap:12px;border-bottom:1px solid rgba(231,235,241,.1);background:rgba(4,5,7,.94)}
html.md .sp section.cat[data-m="text"] .cat-head .num{font-size:12px;letter-spacing:.1em}
html.md .sp section.cat[data-m="text"] .cat-head h2{font-size:22px;line-height:1.3}
html.md .sp section.cat[data-m="text"] .cat-head small{font-size:13px;flex:none;white-space:nowrap}
html.md .sp section.cat[data-m="text"] .cat-head h2{flex:1;min-width:0}
html.md .sp section.cat[data-m="text"] > .grid{padding:0!important;grid-template-columns:minmax(0,1fr);gap:48px}
html.md .sp section.cat[data-m="text"] .card{display:block}
html.md .sp section.cat[data-m="text"] .meta{margin-top:12px;row-gap:4px;column-gap:12px}
html.md .sp section.cat[data-m="text"] .meta b{font-size:20px;line-height:1.35}
html.md .sp section.cat[data-m="text"] .meta .yr,html.md .sp section.cat[data-m="text"] .meta small{font-size:14px;line-height:1.5}
html.md .sp section.cat[data-m="text"] .meta .tag{font-size:13px;align-self:start}
/* 小样视频：由 home.js 一次只播一段，播起来才显示 */
html.md .sp .card .thumb video{opacity:0;transition:opacity .25s}
html.md .sp .card.playing .thumb video{opacity:1}
html.md .sp .card:hover .thumb img{transform:none}
html.md .sp .card.mrv{opacity:0;transform:translateY(12px);transition:opacity .6s ease,transform .6s ease}
html.md .sp .card.mrv.in{opacity:1;transform:none}

/* 联系：一栏 */
html.md .sp section.cat.contact[data-m="text"]{padding-bottom:96px}
html.md .sp section.cat.contact[data-m="text"] > .cgrid{padding:0!important;grid-template-columns:minmax(0,1fr);gap:0}
html.md .sp section.cat.contact .cgrid .fact{margin-bottom:24px;font-size:14px;overflow-wrap:anywhere}
html.md .sp section.cat.contact .cgrid .fact a{display:block;padding:10px 0;margin-bottom:-10px}
}
@media (max-width:767px) and (prefers-reduced-motion:reduce){
html.md .sp .card.mrv{opacity:1;transform:none;transition:none}
}
