/* =====================================================================
 *  Tianhong (Yates) Huang · Personal Brand Portfolio — v4
 *  方向：商业杂志 / 咨询报告式编辑排版
 *    · 暖纸白底 + 轻颗粒  · 墨色正文  · 深森林绿单一强调色
 *    · 英文标题：Newsreader（衬线）  · 中文与正文：Inter + 苹方 / 思源黑体  · 编号：IBM Plex Mono
 *  改颜色：修改下方 :root（浅色）与 [data-theme="dark"]（深色）中的变量
 * ===================================================================== */

:root {
  /* 纸张与墨色 */
  --bg: #f3f0e9;
  --bg-2: #ebe7dd;
  --surface: #f9f7f2;
  --ink: #171715;
  --ink-2: #46453f;
  --muted: #84817a;
  --rule: rgba(23, 23, 21, 0.12);
  --rule-strong: rgba(23, 23, 21, 0.34);
  /* 强调色：深森林绿 */
  --accent: #2f4a3a;
  --accent-2: #4f6e5b;
  --accent-soft: #e2e6dc;
  --accent-line: #b8c5b6;
  --on-accent: #f3f0e9;
  /* v5「活力色」Signal Orange：只用于会动的元素（像素、轮播词），不用于正文 */
  --signal: #ff5b1f;
  --signal-ink: #d4450f;   /* 文字用：在纸色上对比度 ≥ 3:1（大号标题） */
  /* 深色媒体版块（网易案例） */
  --night: #141714;
  --night-2: #1d211d;
  --night-ink: #ece8df;
  --night-muted: #9a978e;
  --night-rule: rgba(236, 232, 223, 0.14);

  --serif: "Newsreader", "Iowan Old Style", Georgia, "Songti SC", serif;
  --sans: "Inter", "PingFang SC", "Noto Sans SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --head: var(--serif);            /* 标题字体：英文用衬线 */

  --wrap: 1520px;   /* 大屏更宽（v4 是 1280px），两侧不再空 */
  --gutter: clamp(20px, 4vw, 56px);
  --nav-h: 64px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}
:root[data-theme="dark"] {
  --bg: #121412;
  --bg-2: #1a1c19;
  --surface: #1c1f1b;
  --ink: #ebe7de;
  --ink-2: #bdb9ae;
  --muted: #8d8a80;
  --rule: rgba(235, 231, 222, 0.12);
  --rule-strong: rgba(235, 231, 222, 0.3);
  --accent: #a6c2ab;
  --accent-2: #a6c2ab;
  --accent-soft: rgba(166, 194, 171, 0.1);
  --accent-line: rgba(166, 194, 171, 0.35);
  --on-accent: #121412;
  --signal-ink: #ff6a33;
  --night: #0c0e0c;
  --night-2: #161916;
}
:lang(zh) { --head: var(--sans); } /* 中文标题用无衬线 */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 8px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--sans); font-size: clamp(16px, 0.5vw + 9px, 18px); line-height: 1.65;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden; transition: background-color .5s var(--ease), color .5s var(--ease);
}
:lang(zh) body, body:lang(zh) { line-height: 1.75; }
#app { transition: opacity .22s ease; }
body.switching #app { opacity: 0; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
ul, ol, dl, dd { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p, figure { margin: 0; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -48px; z-index: 300; background: var(--ink); color: var(--bg); padding: 8px 14px; font-size: 14px; }
.skip:focus { top: 12px; }

/* 纸张颗粒 */
body::after { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 400; opacity: .05; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
:root[data-theme="dark"] body::after { mix-blend-mode: screen; opacity: .035; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.mono { font-family: var(--mono); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; }
.muted { color: var(--muted); }
.head { font-family: var(--head); font-weight: 400; letter-spacing: -.015em; }
:lang(zh) .head { font-weight: 600; letter-spacing: 0; }
em.ac { font-style: italic; color: var(--accent); white-space: nowrap; }  /* 强调词不拆行 */
/* 标题均衡换行、段落避免单字成行（支持的浏览器生效） */
.hero-title, .sec-title, .case-title, .closing h2, .gallery-title, .lead, .feat h3, .bw-title { text-wrap: balance; }
p, li, dd { text-wrap: pretty; }
:lang(zh) em.ac { font-style: normal; }

/* 个人印章 */
.seal { display: inline-grid; place-items: center; width: 30px; height: 30px; border: 1.25px solid var(--accent); color: var(--accent); font-family: var(--serif); font-size: 13px; font-weight: 500; letter-spacing: .02em; transform: rotate(-3deg); flex-shrink: 0; line-height: 1; }

/* ---------- 动效（克制） ---------- */
.rv { opacity: 0; transform: translateY(16px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--d, 0) * 70ms); }
.rv.in { opacity: 1; transform: none; }
.img-rv { clip-path: inset(0 0 100% 0); transition: clip-path 1.3s var(--ease); }
.img-rv.in { clip-path: inset(0 0 0 0); }
#progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); z-index: 200; }

/* ---------- 按钮与链接 ---------- */
.btn { display: inline-flex; align-items: center; gap: 10px; height: 46px; padding: 0 20px; border: 1px solid var(--ink); font-size: 14px; font-weight: 500; transition: background-color .3s, color .3s, border-color .3s; white-space: nowrap; }
.btn:hover { background: var(--ink); color: var(--bg); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn.primary:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn svg { transition: transform .35s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.link { display: inline-flex; align-items: center; gap: 6px; border-bottom: 1px solid var(--rule-strong); padding-bottom: 2px; transition: border-color .3s, color .3s; }
.link:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- 导航 ---------- */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--nav-h); display: flex; align-items: center; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid transparent; transition: border-color .3s, transform .5s var(--ease); }
.nav.scrolled { border-color: var(--rule); }
.nav.hidden { transform: translateY(-100%); }
.nav-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; font-size: 14px; font-weight: 500; white-space: nowrap; }
.nav-links { display: flex; gap: 30px; }
.nav-links a { display: flex; align-items: baseline; gap: 6px; font-size: 14px; color: var(--ink-2); padding: 6px 0; border-bottom: 1px solid transparent; transition: color .3s, border-color .3s; }
.nav-links a .n { font-family: var(--mono); font-size: 10px; color: var(--muted); }
.nav-links a:hover, .nav-links a.active { color: var(--ink); border-color: var(--accent); }
.nav-tools { display: flex; align-items: center; gap: 6px; }
.lang-btn { height: 32px; padding: 0 10px; font-family: var(--mono); font-size: 11.5px; letter-spacing: .06em; color: var(--muted); }
.lang-btn b { color: var(--ink); font-weight: 500; }
.icon-btn { width: 32px; height: 32px; display: grid; place-items: center; font-size: 15px; color: var(--ink-2); border-radius: 50%; transition: background-color .3s; }
.icon-btn:hover { background: var(--bg-2); }
.theme-btn .sun { display: none; }
:root[data-theme="dark"] .theme-btn .sun { display: block; }
:root[data-theme="dark"] .theme-btn .moon { display: none; }
.nav-cta { height: 34px; padding: 0 14px; border: 1px solid var(--rule-strong); display: inline-flex; align-items: center; gap: 6px; font-size: 13px; margin-left: 6px; transition: border-color .3s, background-color .3s, color .3s; }
.nav-cta:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.menu-btn { display: none; }
@media (max-width: 980px) {
  .menu-btn { display: grid; }
  .nav-cta { display: none; }
  .nav-links { position: fixed; inset: var(--nav-h) 0 auto 0; flex-direction: column; gap: 0; padding: 4px var(--gutter) 20px; background: var(--bg); border-bottom: 1px solid var(--rule); display: none; }
  .nav.open .nav-links { display: flex; }
  .nav-links a { font-size: 18px; padding: 14px 0; border-bottom: 1px solid var(--rule); }
  .brand-name { display: none; }
}

/* ---------- A. 首屏 ---------- */
.hero { position: relative; isolation: isolate; overflow: clip; padding: calc(var(--nav-h) + 20px) 0 clamp(48px, 7vw, 88px); }
.hero > .wrap { position: relative; z-index: 1; }
/* 照片宇宙：照片卡片在 3D 空间里漂浮（位置由 main.js 计算） */
.universe { position: absolute; inset: 0; z-index: 0; perspective: 1200px; pointer-events: none; }
.u-stage { position: absolute; inset: 0; transform-style: preserve-3d; }
.u-card { position: absolute; left: 0; top: 0; width: var(--cw, 180px); aspect-ratio: 4 / 3; margin: 0; opacity: 0; overflow: hidden; background: var(--bg-2); box-shadow: 0 22px 44px -22px rgba(23, 23, 21, .45); will-change: transform; }
.u-card img { width: 100%; height: 100%; object-fit: cover; }
.photos-mono .u-card img { filter: grayscale(1) contrast(1.04); }
/* 开场期间：除大标题外的首屏内容先隐藏 */
.hero.intro .hero-slogan, .hero.intro .hero-name, .hero.intro .hero-cta, .hero.intro .portrait, .hero.intro .proof { pointer-events: none; }
/* 轮播关键词 */
.rot { display: inline-block; position: relative; white-space: nowrap; }
.rot-strut { display: inline-block; width: 0; }
.rot-w { display: inline-block; transition: color .9s var(--ease); }
.rot-w:not([data-final]) { position: absolute; left: 0; top: 0; visibility: hidden; }
.rot.live .rot-w { position: absolute; left: 0; top: 0; color: var(--signal-ink); }
/* 像素印章 */
.px-seal { width: 44px; height: 44px; border: 0; }
.px-seal svg { width: 100%; height: 100%; stroke: none; overflow: visible; }
.px-seal rect { fill: var(--accent); transition: fill .8s var(--ease); }
.px-seal.charging rect { fill: var(--signal); transition: none; }
@keyframes pulse { 50% { opacity: .35; } }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-top: clamp(36px, 6vw, 88px); }
.hero-name { display: flex; align-items: center; gap: 14px; font-size: 15px; color: var(--ink-2); margin-bottom: clamp(20px, 3vw, 36px); }
.hero-name strong { color: var(--ink); font-weight: 600; }
.hero-title { font-family: var(--head); font-weight: 400; font-size: clamp(40px, 4.5vw, 70px); line-height: 1.04; letter-spacing: -.025em; max-width: 16ch; }
:lang(zh) .hero-title { font-weight: 600; font-size: clamp(34px, 4.1vw, 60px); line-height: 1.22; letter-spacing: -.005em; max-width: 13em; }
.hero-slogan { margin-top: clamp(20px, 2.4vw, 30px); font-family: var(--serif); font-size: clamp(22px, 2vw, 30px); line-height: 1.3; letter-spacing: -.01em; color: var(--ink-2); max-width: 30ch; }
.hero-slogan em.ac { font-style: italic; }
:lang(zh) .hero-slogan em.ac, :lang(zh) .foot-slogan em.ac { font-style: normal; }
:lang(zh) .hero-slogan { font-family: var(--sans); font-size: clamp(18px, 1.6vw, 22px); letter-spacing: .02em; line-height: 1.6; }
.hero-cta { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; }
/* 圆形肖像：照片宇宙的中心；虚线轨道上有一颗橙色像素慢慢绕行 */
.portrait { position: relative; justify-self: center; width: clamp(220px, 24vw, 340px); }
.portrait .frame { position: relative; aspect-ratio: 1; width: 100%; border-radius: 50%; background: var(--portrait-bg, var(--bg-2)); overflow: hidden; }
.portrait .frame.img-rv { clip-path: circle(0% at 50% 50%); }
.portrait .frame.img-rv.in { clip-path: circle(50% at 50% 50%); }
/* 照片缩小一些放在圆里，露出肩膀；照片的白底和圆的底色融为一体 */
.portrait img { position: absolute; left: 13%; top: 7%; width: 74%; height: auto; mix-blend-mode: multiply; transform-origin: 50% 30%; transition: transform 1.6s var(--ease), filter .6s; }
.orbit { position: absolute; inset: -16px; border-radius: 50%; border: 1px dashed var(--rule-strong); pointer-events: none; animation: spin 48s linear infinite; }
.orbit i { position: absolute; top: calc(50% - 4px); left: -4.5px; width: 8px; height: 8px; background: var(--signal); }
.portrait:hover img { transform: scale(1.03); }
/* 浅色模式：照片白底与纸张底色融合（保留彩色），避免「证件照贴在页面上」的生硬感 */
/* 深色模式：圆形底色用浅暖灰，照片同样能融进去 */
:root[data-theme="dark"] .portrait { --portrait-bg: #d9d5cc; }
:root[data-theme="dark"] .profile-side img { filter: brightness(.92); }
.proof { margin-top: clamp(24px, 3.4vw, 40px); display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--rule-strong); }
.proof > div { padding: 18px 20px 0 0; }
.proof > div + div { padding-left: 20px; border-left: 1px solid var(--rule); }
.proof-num { font-family: var(--serif); font-size: clamp(34px, 3.6vw, 52px); line-height: 1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.proof-num small { font-size: .5em; margin-left: .05em; color: var(--accent); }
.proof-num .pre { font-size: .62em; color: var(--muted); margin-right: .04em; }
.proof-label { margin-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.45; }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .portrait { justify-self: start; width: min(56vw, 240px); margin: 12px 0 0 16px; }   /* 手机：标题在上，肖像在下 */
  .proof { grid-template-columns: 1fr 1fr; }
  .proof > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .proof > div:nth-child(n+3) { border-top: 1px solid var(--rule); margin-top: 16px; }
}

/* ---------- 板块框架 ---------- */
.section { padding-top: clamp(80px, 11vw, 140px); }
.sec-head { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 24px clamp(24px, 4vw, 56px); padding-top: 16px; border-top: 1px solid var(--rule-strong); margin-bottom: clamp(36px, 5vw, 64px); }
.sec-num { color: var(--muted); display: flex; gap: 14px; }
.sec-num b { color: var(--accent); font-weight: 500; }
.sec-title { font-family: var(--head); font-weight: 400; font-size: clamp(38px, 4.6vw, 66px); line-height: 1.04; letter-spacing: -.02em; }
:lang(zh) .sec-title { font-weight: 600; font-size: clamp(32px, 3.6vw, 50px); line-height: 1.2; letter-spacing: 0; }
.sec-intro { margin-top: 16px; max-width: 56ch; color: var(--ink-2); font-size: 16.5px; }
@media (max-width: 760px) { .sec-head { grid-template-columns: 1fr; gap: 14px; } }

.pill { display: inline-flex; align-items: center; min-height: 24px; padding: 2px 9px; border: 1px solid var(--accent-line); color: var(--accent); font-size: 12px; font-weight: 500; line-height: 1.35; }
.tags { display: flex; flex-wrap: wrap; gap: 6px 14px; font-family: var(--mono); font-size: 11.5px; letter-spacing: .03em; color: var(--muted); }
.tags span::before { content: "— "; opacity: .5; }

/* 展开 / 收起 */
.collapse { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .55s var(--ease); }
.collapse > div { overflow: hidden; min-height: 0; }
.collapse.open { grid-template-rows: 1fr; }
.no-anim .collapse { transition: none; }
.toggle { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: var(--accent); padding: 6px 0; }
.toggle .pm { position: relative; width: 12px; height: 12px; }
.toggle .pm::before, .toggle .pm::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transition: transform .4s var(--ease); }
.toggle .pm::after { transform: rotate(90deg); }
.toggle[aria-expanded="true"] .pm::after { transform: rotate(0); }

/* ---------- B. 精选成果 ---------- */
.case { position: relative; padding: clamp(32px, 4vw, 48px) 0 clamp(48px, 6vw, 80px); border-top: 1px solid var(--rule); }
.case:first-of-type { border-top: 0; padding-top: 0; }
.case-meta { display: flex; flex-wrap: wrap; gap: 6px 22px; align-items: baseline; color: var(--muted); margin-bottom: 22px; }
.case-meta .case-no { color: var(--accent); }
.case-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.case-company { font-size: 14px; color: var(--ink-2); font-weight: 500; }
.case-title { font-family: var(--head); font-weight: 400; font-size: clamp(32px, 3.4vw, 50px); line-height: 1.06; letter-spacing: -.02em; margin-top: 6px; }
:lang(zh) .case-title { font-weight: 600; font-size: clamp(26px, 2.6vw, 38px); line-height: 1.25; letter-spacing: 0; }
.case-summary { margin-top: 18px; font-size: 16.5px; color: var(--ink-2); }
.kpis { margin-top: 28px; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--rule-strong); }
.kpi { padding: 14px 16px 14px 0; border-bottom: 1px solid var(--rule); }
.kpi:nth-child(even) { padding-left: 16px; border-left: 1px solid var(--rule); }
.kpi b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.05; letter-spacing: -.015em; white-space: nowrap; }
.kpi span { display: block; margin-top: 4px; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.case-full { padding-top: 22px; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 56px); }
.steps-list { counter-reset: s; }
.steps-list li { counter-increment: s; display: grid; grid-template-columns: 40px 1fr; padding: 14px 0; border-top: 1px solid var(--rule); font-size: 15px; color: var(--ink-2); }
.steps-list li::before { content: counter(s, decimal-leading-zero); font-family: var(--mono); font-size: 11.5px; color: var(--accent); padding-top: 3px; }
.steps-list strong { display: block; color: var(--ink); font-weight: 600; margin-bottom: 2px; }
.full-side h4 { font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.full-side .kpis { margin-top: 0; }
.full-side .outcome-text { margin-top: 16px; font-size: 14.5px; color: var(--ink-2); }
.full-side .tags { margin-top: 18px; }
@media (max-width: 900px) { .case-full { grid-template-columns: 1fr; } }

/* 案例视觉面板 */
.visual { position: relative; min-height: 100%; padding: clamp(22px, 3vw, 36px); background: var(--surface); border: 1px solid var(--rule); display: flex; flex-direction: column; }
.visual-head { display: flex; justify-content: space-between; gap: 12px; color: var(--muted); padding-bottom: 14px; border-bottom: 1px solid var(--rule); }
.visual-foot { margin-top: auto; padding-top: 16px; color: var(--muted); font-size: 13px; }
.visual-img { margin: -1px; }
.visual-img img { width: 100%; height: auto; }
.visual-img figcaption { padding-top: 8px; font-size: 13px; color: var(--muted); }
/* 柱状图 */
.bars { margin: 28px 0 24px; display: grid; gap: 22px; }
.bar-row { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; align-items: baseline; }
.bar-row .lbl { font-size: 14px; }
.bar-row .val { font-family: var(--serif); font-size: 26px; line-height: 1; }
.bar-track { grid-column: 1 / -1; height: 10px; background: var(--bg-2); }
.bar-track i { display: block; height: 100%; width: 0; background: var(--accent); transition: width 1.4s var(--ease); }
.visual.in .bar-track i { width: var(--w); }
/* 闭环图（深色） */
.loop { position: relative; width: min(100%, 420px); aspect-ratio: 1; margin: 22px auto 10px; }
.loop-ring { position: absolute; inset: 16%; border: 1px dashed currentColor; border-radius: 50%; opacity: .35; }
.loop-center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.loop-center b { font-family: var(--serif); font-weight: 400; font-size: clamp(48px, 6vw, 76px); line-height: 1; }
.loop-center span { font-size: 13px; opacity: .7; margin-top: 6px; }
.loop-step { position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; gap: 8px; padding: 6px 12px; background: var(--surface); border: 1px solid var(--rule-strong); font-size: 13px; white-space: nowrap; opacity: 0; transition: opacity .6s var(--ease); transition-delay: calc(var(--d, 0) * 160ms); }
.loop-step i { font-style: normal; font-family: var(--mono); font-size: 10.5px; color: var(--accent); }
.visual.in .loop-step { opacity: 1; }
.loop-step.p1 { left: 50%; top: 16%; } .loop-step.p2 { left: 84%; top: 50%; }
.loop-step.p3 { left: 50%; top: 84%; } .loop-step.p4 { left: 16%; top: 50%; }
.lineup { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.lineup span { padding: 4px 10px; border: 1px solid var(--rule-strong); font-size: 12.5px; }
.visual.in .loop-ring { animation: spin 80s linear infinite; }
/* 阶梯图 */
.ladder { position: relative; margin: 24px 0 8px; padding-left: 28px; }
.ladder::before { content: ""; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 1px; background: var(--accent-line); }
.ladder::after { content: ""; position: absolute; left: 6px; top: 8px; width: 1px; height: 0; background: var(--accent); transition: height 1.6s var(--ease); }
.visual.in .ladder::after { height: calc(100% - 16px); }
.ladder-end { font-family: var(--serif); line-height: 1; position: relative; }
.ladder-end::before { content: ""; position: absolute; left: -27px; top: 50%; width: 11px; height: 11px; margin-top: -5px; border-radius: 50%; background: var(--accent); }
.ladder-end.start { font-size: 30px; color: var(--muted); }
.ladder-end.start::before { background: var(--bg); border: 1.5px solid var(--accent); }
.ladder-end.end { font-size: clamp(52px, 6vw, 80px); color: var(--accent); }
.ladder-end.end small { font-family: var(--sans); font-size: 14px; color: var(--ink-2); margin-left: 10px; }
.ladder ol { margin: 18px 0; display: grid; gap: 4px; }
.ladder li { display: grid; grid-template-columns: 110px 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: 14px; color: var(--ink-2); }
.ladder li b { font-weight: 600; color: var(--ink); }

/* 案例色调 */
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- C. 职业轨迹 ---------- */
.trajectory { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-bottom: clamp(28px, 4vw, 44px); }
.trajectory .label { color: var(--muted); margin-right: 6px; }
.traj-step { display: inline-flex; align-items: baseline; gap: 8px; padding: 7px 12px; border: 1px solid var(--rule-strong); font-size: clamp(14px, .95vw, 17px); }
.traj-step i { font-style: normal; font-family: var(--mono); font-size: 10.5px; color: var(--muted); }
.traj-step:last-of-type { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.traj-step:last-of-type i { color: color-mix(in srgb, var(--on-accent) 70%, transparent); }
.traj-arrow { color: var(--muted); }
.jobs { border-top: 1px solid var(--rule-strong); }
.job { border-bottom: 1px solid var(--rule); }
.job-row { display: grid; grid-template-columns: 150px minmax(0, 2.2fr) minmax(0, 3fr) minmax(0, 2fr) 36px; gap: 20px; align-items: start; padding: 22px 0; transition: background-color .3s; }
.job-row:hover { background: color-mix(in srgb, var(--bg-2) 60%, transparent); }
.job-period { color: var(--muted); padding-top: 4px; }
.job-company { font-family: var(--head); font-size: clamp(24px, 1.6vw, 31px); line-height: 1.15; }
.job-logo { height: 30px; margin-bottom: 12px; display: flex; align-items: center; }
.job-logo img { height: 100%; width: auto; max-width: 140px; object-fit: contain; filter: grayscale(1) contrast(1.1); opacity: .8; transition: filter .4s, opacity .4s; }
.job-row:hover .job-logo img { filter: none; opacity: 1; }
:root[data-theme="dark"] .job-logo img, :root[data-theme="dark"] .job-row:hover .job-logo img { filter: grayscale(1) invert(1) brightness(1.4); opacity: .85; }
.job-logo.mono-mark { width: 30px; justify-content: center; border: 1px solid var(--rule-strong); font-family: var(--serif); font-size: 12px; letter-spacing: .02em; color: var(--ink-2); }
:lang(zh) .job-company { font-size: clamp(20px, 1.35vw, 26px); font-weight: 600; }
.job-role { font-size: clamp(14px, .9vw, 16px); color: var(--ink-2); margin-top: 4px; }
.job-loc { font-size: 13px; color: var(--muted); }
.job-line { font-size: clamp(15px, 1vw, 18px); color: var(--ink-2); }
.job-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 14px; }   /* 能力标签和「阅读案例」之间留出空隙 */
.job-kpis { display: grid; gap: 10px; }
.job-kpis b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 1.7vw, 32px); line-height: 1; }
.job-kpis span { font-size: clamp(12px, .75vw, 14px); color: var(--muted); }
.job-toggle { width: 32px; height: 32px; border: 1px solid var(--rule-strong); display: grid; place-items: center; color: var(--ink); transition: background-color .3s, color .3s; }
.job-toggle:hover { background: var(--ink); color: var(--bg); }
.job-toggle .pm { position: relative; width: 11px; height: 11px; }
.job-toggle .pm::before, .job-toggle .pm::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transition: transform .4s var(--ease); }
.job-toggle .pm::after { transform: rotate(90deg); }
.job-toggle[aria-expanded="true"] .pm::after { transform: rotate(0); }
.job-detail { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 20px; padding: 0 0 28px; }
.job-detail .steps-list { grid-column: 2; }
.job-detail-foot { grid-column: 2; display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; margin-top: 16px; }
.job-detail .extra li { padding: 10px 0 0; font-size: 14px; color: var(--muted); }
.job-detail .extra li::before { content: "+ "; }
@media (max-width: 960px) {
  .job-row { grid-template-columns: minmax(0, 1fr) 36px; gap: 10px 16px; }
  .job-row > .job-period { grid-column: 1; order: -1; }
  .job-row > .job-who, .job-row > .job-line, .job-row > .job-kpis { grid-column: 1; }
  .job-row > .job-toggle { grid-column: 2; grid-row: 1; }
  .job-kpis { grid-template-columns: 1fr 1fr; margin-top: 6px; }
  .job-detail { grid-template-columns: 1fr; }
  .job-detail .steps-list, .job-detail-foot { grid-column: 1; }
}

/* ---------- D. 工作之外 ---------- */
.bw-group { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 24px clamp(24px, 4vw, 56px); padding: 28px 0 clamp(40px, 5vw, 64px); border-top: 1px solid var(--rule); }
.bw-group:first-child { border-top: 0; padding-top: 0; }
.bw-label { color: var(--accent); }
.bw-title { font-family: var(--head); font-size: clamp(26px, 2.4vw, 34px); line-height: 1.15; margin-top: 8px; }
:lang(zh) .bw-title { font-weight: 600; font-size: clamp(22px, 2vw, 28px); }
.bw-intro { margin-top: 10px; color: var(--muted); font-size: 14.5px; max-width: 32ch; }
.feats { display: grid; gap: 0; }
.feat { padding: 22px 0 26px; border-top: 1px solid var(--rule-strong); }
.feat + .feat { border-top-color: var(--rule); }
.feat-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; color: var(--muted); }
.feat h3 { font-family: var(--head); font-weight: 400; font-size: clamp(22px, 2vw, 28px); line-height: 1.25; margin-top: 12px; }
:lang(zh) .feat h3 { font-weight: 600; font-size: clamp(19px, 1.7vw, 23px); }
.feat .role { font-size: 14px; color: var(--ink-2); margin-top: 4px; }
.feat p.desc { margin-top: 10px; font-size: 15px; color: var(--ink-2); max-width: 64ch; }
.feat .kpis { grid-template-columns: repeat(4, 1fr); margin-top: 18px; }
.feat .kpi:nth-child(even) { padding-left: 0; border-left: 0; }
.feat .kpi + .kpi { padding-left: 16px; border-left: 1px solid var(--rule); }
.feat .kpi b { font-size: 28px; }
.feat .steps-list { margin-top: 12px; }
.feat .tags, .feat .link { margin-top: 14px; }
.compact { margin-top: 8px; border-top: 1px solid var(--rule); }
.compact details { border-bottom: 1px solid var(--rule); }
.compact summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 96px minmax(0, 1fr) auto 24px; gap: 16px; align-items: baseline; padding: 14px 0; transition: color .3s; }
.compact summary::-webkit-details-marker { display: none; }
.compact summary:hover { color: var(--accent); }
.compact summary .yr { color: var(--muted); }
.compact summary .t { font-size: 15px; font-weight: 500; }
.compact summary .aw { font-size: 13px; color: var(--muted); text-align: right; }
.compact summary .pm { position: relative; width: 11px; height: 11px; justify-self: end; }
.compact summary .pm::before, .compact summary .pm::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transition: transform .4s var(--ease); }
.compact summary .pm::after { transform: rotate(90deg); }
.compact details[open] summary .pm::after { transform: rotate(0); }
.compact .body { padding: 0 0 16px 112px; font-size: 14.5px; color: var(--ink-2); }
.compact .body .tags { margin-top: 10px; }
@media (max-width: 900px) { .bw-group { grid-template-columns: 1fr; } .feat .kpis { grid-template-columns: 1fr 1fr; } .feat .kpi:nth-child(3) { padding-left: 0; border-left: 0; } }
@media (max-width: 560px) { .compact summary { grid-template-columns: minmax(0, 1fr) 24px; } .compact summary .yr { grid-column: 1; } .compact summary .aw { grid-column: 1; text-align: left; } .compact summary .pm { grid-row: 1; grid-column: 2; } .compact .body { padding-left: 0; } }

/* ---------- E. 关于我 ---------- */
.profile-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.profile-side { position: sticky; top: calc(var(--nav-h) + 24px); }
.profile-side .frame { aspect-ratio: 4 / 5; background: var(--bg-2); overflow: hidden; }
.profile-side img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }

.facts { margin-top: 20px; }
.facts > div { display: grid; grid-template-columns: 100px 1fr; gap: 12px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: 14px; }
.facts dt { color: var(--muted); padding-top: 2px; }
.lead { font-family: var(--head); font-size: clamp(24px, 2.4vw, 34px); line-height: 1.32; letter-spacing: -.01em; }
:lang(zh) .lead { font-size: clamp(20px, 1.9vw, 26px); line-height: 1.65; font-weight: 500; }
.prose { margin-top: 20px; display: grid; gap: 14px; color: var(--ink-2); max-width: 64ch; }
.sub-h { display: flex; align-items: baseline; gap: 12px; color: var(--muted); margin: clamp(44px, 5vw, 64px) 0 16px; padding-top: 14px; border-top: 1px solid var(--rule-strong); }
.sub-h b { color: var(--accent); font-weight: 500; }
.principles { display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.principle { padding: 18px 0 22px; border-top: 1px solid var(--rule); }
.principle:nth-child(-n+2) { border-top: 0; padding-top: 0; }
.principle .no { font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--accent); }
.principle h3 { font-family: var(--head); font-weight: 400; font-size: 24px; margin: 6px 0 6px; }
:lang(zh) .principle h3 { font-weight: 600; font-size: 19px; }
.principle p { font-size: 14.5px; color: var(--ink-2); }
.edu { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 18px; padding: 20px 0; border-top: 1px solid var(--rule); align-items: start; }
.edu:first-child { border-top: 0; padding-top: 0; }
.edu-logo { width: 64px; height: 64px; background: #fff; border: 1px solid var(--rule); padding: 10px; }
.edu-logo img { width: 100%; height: 100%; object-fit: contain; }
.edu h3 { font-family: var(--head); font-weight: 400; font-size: 24px; line-height: 1.2; }
:lang(zh) .edu h3 { font-weight: 600; font-size: 19px; }
.edu .alt { font-size: 13px; color: var(--muted); }
.edu .deg { margin-top: 8px; font-size: 15px; }
.edu .dept { font-size: 14px; color: var(--ink-2); }
.edu .badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.edu .note { margin-top: 10px; font-size: 14px; color: var(--ink-2); }
.edu .courses { margin-top: 10px; font-size: 13.5px; color: var(--muted); }
.edu .when { color: var(--muted); text-align: right; white-space: nowrap; }
.honours li { display: grid; grid-template-columns: 90px minmax(0, 1fr) minmax(0, 240px); gap: 16px; padding: 12px 0; border-top: 1px solid var(--rule); font-size: 14.5px; align-items: baseline; }
.honours li:first-child { border-top: 0; }
.honours .d { color: var(--muted); }
.honours .o { font-size: 13px; color: var(--muted); }
.honours .n { font-size: 13px; color: var(--muted); text-align: right; }
.kit { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.kit h4, .kv h4 { font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.kit ul { display: flex; flex-wrap: wrap; gap: 6px; }
.kit li { padding: 5px 10px; border: 1px solid var(--rule); font-size: 13px; transition: border-color .3s, color .3s; }
.kit li:hover { border-color: var(--accent); color: var(--accent); }
.kv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 28px; }
.kv li { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-top: 1px solid var(--rule); font-size: 14.5px; }
.kv li span:last-child { color: var(--muted); text-align: right; }
@media (max-width: 900px) {
  .profile-grid { grid-template-columns: 1fr; }
  .profile-side { position: static; display: grid; grid-template-columns: minmax(0, 200px) 1fr; gap: 20px; }
  .facts { margin-top: 0; }
  .kit { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .profile-side { grid-template-columns: 1fr; } .profile-side .frame { max-width: 240px; }
  .principles, .kv-grid { grid-template-columns: 1fr; } .principle:nth-child(2) { border-top: 1px solid var(--rule); padding-top: 18px; }
  .edu { grid-template-columns: 48px minmax(0, 1fr); } .edu-logo { width: 48px; height: 48px; padding: 6px; } .edu .when { grid-column: 2; text-align: left; order: -1; }
  .honours li { grid-template-columns: 1fr; gap: 2px; } .honours .n { text-align: left; }
}

/* ---------- F. 联系 ---------- */
.closing { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(28px, 5vw, 72px); align-items: end; padding-top: 16px; border-top: 1px solid var(--rule-strong); }
.closing h2 { font-family: var(--head); font-weight: 400; font-size: clamp(36px, 4.6vw, 68px); line-height: 1.06; letter-spacing: -.02em; }
:lang(zh) .closing h2 { font-weight: 600; font-size: clamp(28px, 3.2vw, 46px); line-height: 1.3; letter-spacing: 0; }
.closing .text { margin-top: 20px; color: var(--ink-2); max-width: 50ch; }
.closing .actions { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; }
.c-list li { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 13px 0; border-top: 1px solid var(--rule); font-size: 15px; }
.c-list li:last-child { border-bottom: 1px solid var(--rule); }
.c-list .k { color: var(--muted); }
.c-list .v { word-break: break-all; }
.c-act { display: flex; gap: 4px; }
.c-act button, .c-act a { width: 32px; height: 32px; display: grid; place-items: center; font-size: 14px; color: var(--ink-2); transition: background-color .3s, color .3s; }
.c-act button:hover, .c-act a:hover { background: var(--accent); color: var(--on-accent); }
@media (max-width: 900px) { .closing { grid-template-columns: 1fr; } }

/* ---------- 页脚 ---------- */
.footer { margin-top: clamp(80px, 10vw, 128px); padding: 22px 0 28px; border-top: 1px solid var(--rule); }
/* 页脚签名：印章 + 名字，旁边一行 slogan（像信末署名） */
.foot-sign { display: flex; flex-wrap: wrap; align-items: center; gap: 14px clamp(20px, 4vw, 48px); padding-bottom: 22px; margin-bottom: 18px; border-bottom: 1px solid var(--rule); }
.foot-sign .brand { color: var(--ink); font-size: 16px; }
.foot-slogan { font-family: var(--serif); font-size: clamp(18px, 1.7vw, 24px); line-height: 1.3; color: var(--ink-2); letter-spacing: -.005em; }
.foot-slogan em.ac { color: var(--accent); }
:lang(zh) .foot-slogan { font-family: var(--sans); font-size: clamp(15px, 1.3vw, 18px); letter-spacing: .02em; }
.foot-row { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; justify-content: space-between; color: var(--muted); }
.foot-links { display: flex; gap: 20px; align-items: center; }
.foot-links a, .foot-links button { transition: color .3s; }
.foot-links a:hover, .foot-links button:hover { color: var(--ink); }

/* ---------- 照片风格：meta.photoStyle = "mono" 时全站照片变黑白（悬停恢复彩色） ---------- */
.photos-mono .portrait img, .photos-mono .profile-side img, .photos-mono .ctx-photo img, .photos-mono .g-img img { filter: grayscale(1) contrast(1.04); }
.photos-mono .portrait:hover img, .photos-mono .ctx-photo:hover img, .photos-mono .g-card:hover img { filter: none; }

/* ---------- 情境照片（教育 / 项目 / 志愿者） ---------- */
.ctx-photo { margin-top: 14px; position: relative; overflow: hidden; background: var(--bg-2); cursor: zoom-in; display: block; width: 100%; max-width: 360px; }
.ctx-photo img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform 1.2s var(--ease), filter .6s; }
.ctx-photo:hover img { transform: scale(1.03); }
.ctx-photo.small { max-width: 300px; }
.ctx-photo.small img { aspect-ratio: 3 / 4; object-position: 50% 30%; }
.ctx-photo .zoom { position: absolute; right: 10px; bottom: 10px; width: 32px; height: 32px; display: grid; place-items: center; background: rgba(243, 240, 233, .92); color: #171715; font-size: 14px; opacity: 0; transition: opacity .3s; }
.ctx-photo:hover .zoom, .ctx-photo:focus-visible .zoom { opacity: 1; }

/* ---------- 生活片段：页面下方的滑动卡片 ---------- */
.gallery-sec .wrap { position: relative; }
.gallery-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; padding-top: 16px; border-top: 1px solid var(--rule-strong); }
.gallery-title { font-family: var(--head); font-weight: 400; font-size: clamp(30px, 3.2vw, 44px); line-height: 1.1; letter-spacing: -.015em; }
:lang(zh) .gallery-title { font-weight: 600; font-size: clamp(24px, 2.4vw, 32px); letter-spacing: 0; }
.gallery-intro { color: var(--muted); font-size: 14.5px; margin-top: 8px; max-width: 52ch; }
.gallery-ctrl { display: flex; align-items: center; gap: 8px; }
.gallery-ctrl button { width: 40px; height: 40px; border: 1px solid var(--rule-strong); display: grid; place-items: center; font-size: 15px; transition: background-color .3s, color .3s, opacity .3s; }
.gallery-ctrl button:hover:not(:disabled) { background: var(--ink); color: var(--bg); }
.gallery-ctrl button:disabled { opacity: .3; cursor: default; }
.gallery-ctrl .count { min-width: 70px; color: var(--muted); }
.gallery-track { display: flex; gap: 16px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 28px 0 8px; cursor: grab; }
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track.dragging { cursor: grabbing; scroll-snap-type: none; }
.gallery-track.dragging .g-card { pointer-events: none; }
.g-card { flex: 0 0 clamp(220px, 21vw, 280px); scroll-snap-align: start; background: var(--surface); border: 1px solid var(--rule); transition: transform .5s var(--ease), border-color .4s, box-shadow .5s var(--ease); }
.g-card:hover { transform: translateY(-4px); border-color: var(--rule-strong); box-shadow: 0 18px 36px -24px rgba(23, 23, 21, .45); }
.g-img { display: block; width: 100%; aspect-ratio: 3 / 4; overflow: hidden; background: var(--bg-2); cursor: zoom-in; }
.g-img img { width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; transition: transform 1s var(--ease), filter .6s; }
.g-card:hover .g-img img { transform: scale(1.04); }
.g-card figcaption { display: grid; gap: 2px; padding: 12px 14px 14px; }
.g-card figcaption .mono { color: var(--muted); font-size: 11px; }
.g-card .cap { font-size: 14.5px; font-weight: 500; }
.g-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12.5px; color: var(--accent); }
.g-link svg { transition: transform .3s var(--ease); }
.g-link:hover svg { transform: translateX(3px); }
.g-progress { height: 2px; background: var(--rule); margin-top: 18px; overflow: hidden; }
.g-progress i { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(.08); transition: transform .3s var(--ease); }
@media (max-width: 600px) { .g-card { flex-basis: 72vw; } .gallery-ctrl button { display: none; } }

/* ---------- 大图查看 ---------- */
.lightbox { border: 0; padding: 0; max-width: none; max-height: none; width: 100vw; height: 100vh; background: rgba(12, 13, 12, .92); color: #ece8df; }
.lightbox::backdrop { background: rgba(12, 13, 12, .6); }
.lightbox[open] { display: grid; grid-template-rows: auto 1fr auto; animation: lbIn .35s var(--ease); }
@keyframes lbIn { from { opacity: 0; } }
.lb-top { display: flex; justify-content: space-between; align-items: center; padding: 16px var(--gutter); font-family: var(--mono); font-size: 12px; letter-spacing: .06em; }
.lb-stage { display: grid; place-items: center; min-height: 0; padding: 0 clamp(56px, 8vw, 120px); position: relative; }
.lb-stage img { max-width: 100%; max-height: calc(100vh - 150px); object-fit: contain; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .6); }
.lb-btn { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid rgba(236, 232, 223, .3); color: #ece8df; font-size: 16px; transition: background-color .3s; }
.lb-btn:hover { background: rgba(236, 232, 223, .12); }
.lb-stage .lb-btn { position: absolute; top: 50%; transform: translateY(-50%); }
.lb-stage .lb-prev { left: clamp(8px, 2vw, 32px); } .lb-stage .lb-next { right: clamp(8px, 2vw, 32px); }
.lb-cap { padding: 14px var(--gutter) 22px; text-align: center; font-size: 14px; color: #c9c5bb; }
@media (max-width: 600px) { .lb-stage { padding: 0 8px; } .lb-stage .lb-btn { top: auto; bottom: -56px; transform: none; } .lb-cap { padding-top: 64px; } }

/* ---------- 提示 ---------- */
#toast { position: fixed; left: 50%; bottom: 28px; z-index: 300; transform: translate(-50%, 12px); opacity: 0; pointer-events: none; background: var(--ink); color: var(--bg); padding: 10px 16px; font-size: 13.5px; display: flex; gap: 8px; align-items: center; transition: opacity .3s, transform .4s var(--ease); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 编辑器预览模式：悬停 / 定位高亮 ---------- */
.is-preview .edit-hover { outline: 1.5px dashed #6d4dff; outline-offset: 4px; cursor: pointer; }
.is-preview .edit-focus { outline: 2px solid #6d4dff; outline-offset: 4px; }
.is-preview .edit-flash { animation: editFlash 1.2s ease-out; }
@keyframes editFlash { 0% { box-shadow: 0 0 0 0 rgba(109, 77, 255, .5); } 100% { box-shadow: 0 0 0 14px rgba(109, 77, 255, 0); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  .rv, .img-rv { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .loop-step { opacity: 1 !important; }
  .bar-track i { width: var(--w) !important; }
  .g-card { transform: none !important; }
  .rot-w { transition: none; }
  .ladder::after { height: calc(100% - 16px) !important; }
}

/* ---------- 经历条目 → 案例详情 ---------- */
.case-link { font-size: 14px; width: fit-content; }
.job-go { color: var(--ink); }
.job-go svg { transition: transform .35s var(--ease); }
.job-row:hover .job-go { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.job-row:hover .job-go svg { transform: translateX(2px); }

/* ---------- 案例详情页（?case=…） ---------- */
.cs { padding: calc(var(--nav-h) + clamp(28px, 4vw, 48px)) 0 0; }
.cs-back { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); margin-bottom: clamp(28px, 4vw, 48px); transition: color .3s; }
.cs-back:hover { color: var(--accent); }
.cs-head { max-width: 900px; }
.cs-title { font-family: var(--head); font-weight: 400; font-size: clamp(40px, 5.2vw, 76px); line-height: 1.02; letter-spacing: -.028em; text-wrap: balance; }
:lang(zh) .cs-title { font-weight: 600; font-size: clamp(32px, 4vw, 56px); line-height: 1.2; letter-spacing: 0; }
.cs-summary { margin-top: 22px; font-size: clamp(17px, 1.4vw, 20px); color: var(--ink-2); max-width: 60ch; }
.cs-kpis .kpis { grid-template-columns: repeat(4, 1fr); margin-top: clamp(32px, 4vw, 48px); }
.cs-kpis .kpi { padding: 16px; border-left: 1px solid var(--rule); }
.cs-kpis .kpi:nth-child(4n+1) { padding-left: 0; border-left: 0; }
.cs-visual { margin: clamp(40px, 6vw, 72px) auto 0; max-width: 920px; }
.cs-body { margin-top: clamp(48px, 7vw, 96px); }
.cs-block { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: 16px clamp(24px, 4vw, 56px); padding: clamp(24px, 3vw, 36px) 0; border-top: 1px solid var(--rule-strong); }
.cs-label { font-size: 11.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); padding-top: 4px; }
.cs-content { max-width: 760px; font-size: 16px; color: var(--ink-2); }
.cs-content .cs-lead { font-family: var(--serif); font-size: clamp(21px, 1.9vw, 27px); line-height: 1.38; color: var(--ink); letter-spacing: -.01em; }
:lang(zh) .cs-content .cs-lead { font-family: var(--sans); font-size: clamp(18px, 1.5vw, 21px); line-height: 1.7; }
.cs-content .steps-list li:first-child { border-top: 0; padding-top: 0; }
.cs-content .extra { margin-top: 16px; padding-left: 18px; list-style: disc; color: var(--muted); font-size: 14.5px; }
.cs-next { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 8px 24px; margin-top: clamp(56px, 8vw, 112px); padding: clamp(24px, 3vw, 36px) 0; border-top: 1px solid var(--rule-strong); border-bottom: 1px solid var(--rule-strong); }
.cs-next .mono { grid-column: 1 / -1; color: var(--muted); }
.cs-next b { font-family: var(--head); font-weight: 400; font-size: clamp(28px, 3.4vw, 48px); line-height: 1.08; letter-spacing: -.02em; transition: color .3s; }
:lang(zh) .cs-next b { font-weight: 600; font-size: clamp(22px, 2.6vw, 34px); }
.cs-next svg { font-size: clamp(24px, 2.6vw, 36px); transition: transform .4s var(--ease); }
.cs-next:hover b { color: var(--accent); }
.cs-next:hover svg { transform: translateX(6px); }
@media (max-width: 760px) {
  .cs-kpis .kpis { grid-template-columns: 1fr 1fr; }
  .cs-kpis .kpi:nth-child(4n+1) { padding-left: 16px; border-left: 1px solid var(--rule); }
  .cs-kpis .kpi:nth-child(odd) { padding-left: 0; border-left: 0; }
  .cs-block { grid-template-columns: 1fr; }
}

/* 手机：能力主线改为竖排、居中 */
@media (max-width: 760px) {
  .trajectory { flex-direction: column; align-items: center; gap: 8px; text-align: center; }
  .trajectory .label { margin: 0 0 4px; }
  .traj-step { justify-content: center; min-width: min(100%, 260px); }
  .traj-arrow { transform: rotate(90deg); line-height: 1; }
}
