/* =========================================================
   吴子幸 · 作品集
   米纸底 + 墨色字 + 深墨绿点缀
   ========================================================= */

:root {
  --paper: #ffffff;
  --paper-2: #f4f7fb;
  --ink: #141414;
  --ink-2: #2b2b2b;
  --muted: #5d6b7d;
  --muted-2: #8b97a7;
  --line: rgba(15, 48, 87, 0.12);
  --line-strong: rgba(15, 48, 87, 0.26);
  --navy: #0f3057;
  --navy-soft: #1d4d7c;
  --accent: #0f3057;
  --accent-warm: #b08a4f;

  --sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --serif: Georgia, "Times New Roman", "Songti SC", serif;

  --wrap: 1180px;
  --pad: clamp(20px, 5vw, 56px);
  --ease: cubic-bezier(0.22, 0.7, 0.2, 1);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.015em; }
h1, h2 { color: var(--navy); }
p { margin: 0; }
ul, ol, dl, dd { margin: 0; padding: 0; }
li { list-style: none; }
button { font: inherit; color: inherit; }

::selection { background: var(--ink); color: var(--paper); }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

/* ---------------- 导航 ---------------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  padding: 0 var(--pad);
  border-bottom: 1px solid transparent;
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease);
}

.nav.is-scrolled {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: var(--line);
}

.nav-brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.brand-cn { font-size: 1rem; }

.brand-en {
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  color: var(--muted);
  font-weight: 500;
}

.nav-links {
  display: flex;
  gap: clamp(16px, 3vw, 36px);
  font-size: 0.86rem;
  color: var(--ink-2);
}

.nav-links a {
  position: relative;
  padding: 4px 0;
  transition: color 0.25s;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--navy);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.35s var(--ease);
}

.nav-links a:hover::after,
.nav-links a.is-active::after { transform: scaleX(1); transform-origin: left; }

.nav-links a.is-active { color: var(--ink); font-weight: 500; }

/* ---------------- 报告封面 ---------------- */
.cover {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 104px 0 72px;
}

.doc-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
}

.doc-head-mid { letter-spacing: 0.14em; }

.cover-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 228px;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
  padding: clamp(40px, 7vw, 76px) 0;
}

.cover-kicker {
  font-size: 0.68rem;
  letter-spacing: 0.26em;
  color: var(--muted);
  margin-bottom: 30px;
}

.cover-title {
  font-size: clamp(2.1rem, 4.4vw, 3.55rem);
  line-height: 1.26;
  letter-spacing: -0.035em;
  font-weight: 600;
}

.cover-title em {
  font-style: normal;
  position: relative;
  white-space: nowrap;
}

.cover-title em::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: 5px;
  height: 0.32em;
  background: rgba(15, 48, 87, 0.12);
  z-index: -1;
}

.cover-rule {
  width: 48px;
  height: 1px;
  background: var(--ink);
  margin: 32px 0 20px;
}

.cover-sub {
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  color: var(--ink-2);
}

.cover-intro {
  margin-top: 24px;
  max-width: 31em;
  font-size: 0.92rem;
  line-height: 2;
  color: var(--muted);
}

.cover-actions { display: flex; gap: 12px; margin-top: 34px; flex-wrap: wrap; }

.cover-photo { margin: 0; width: 100%; justify-self: end; align-self: center; }

.cover-photo-inner {
  border: 1px solid var(--line-strong);
  padding: 7px;
  background: #fff;
}

.cover-photo img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: 50% 28%;
  display: block;
  filter: saturate(0.96);
}

.cover-photo figcaption {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.14);
}

.cover-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-top: clamp(32px, 5vw, 48px);
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.cover-meta dt {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  color: var(--muted-2);
  margin-bottom: 6px;
}

.cover-meta dd { font-size: 0.82rem; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 0.84rem;
  border-radius: 2px;
  border: 1px solid transparent;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
    border-color 0.3s var(--ease), transform 0.3s var(--ease);
}

.btn-solid { background: var(--navy); color: #fff; }
.btn-solid:hover { background: var(--navy-soft); transform: translateY(-2px); }

.btn-ghost { border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); background: rgba(15, 48, 87, 0.05); }

/* ---------------- 区块 ---------------- */
.section { padding: clamp(72px, 10vw, 120px) 0; }
.section-alt { background: var(--paper-2); }
.page { padding-top: clamp(96px, 12vw, 132px); padding-bottom: clamp(72px, 10vw, 120px); }

.section-head {
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: end;
  gap: 12px 28px;
  margin-bottom: clamp(36px, 5vw, 56px);
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}

.section-no {
  font-family: var(--serif);
  font-size: 0.84rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  align-self: start;
  padding-top: 12px;
}

.section-head h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.section-desc {
  grid-column: 2;
  color: var(--muted);
  font-size: 0.92rem;
  max-width: 40em;
}

/* ---------------- 目录 ---------------- */
.contents { padding: clamp(64px, 9vw, 104px) 0 clamp(72px, 10vw, 120px); }

.contents-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px 64px;
  align-items: end;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--ink);
  margin-bottom: 8px;
}

.contents-label {
  margin-top: 14px;
  font-size: 0.64rem;
  letter-spacing: 0.3em;
  color: var(--muted);
}

.contents-title h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.035em;
  line-height: 1.1;
}

.contents-note {
  font-size: 0.82rem;
  line-height: 1.95;
  color: var(--muted);
  max-width: 34em;
}

.toc-group { margin-top: clamp(36px, 5vw, 56px); }

.toc-group-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.66rem;
  letter-spacing: 0.24em;
  color: var(--muted);
  text-transform: uppercase;
}

.toc-list { margin-top: 4px; }

.toc-row {
  display: flex;
  align-items: flex-start;
  gap: clamp(10px, 1.6vw, 18px);
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  transition: padding 0.35s var(--ease), background 0.35s var(--ease);
}

.toc-row { position: relative; }
.toc-row::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 2px;
  background: var(--navy);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.3s var(--ease);
}
.toc-row:hover::before { transform: scaleY(1); }
.toc-row:hover { background: rgba(15, 48, 87, 0.035); padding-left: 12px; padding-right: 10px; }

.toc-ch {
  flex: none;
  width: 30px;
  font-family: var(--serif);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.toc-name {
  flex: none;
  max-width: 58%;
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.005em;
  transition: color 0.25s;
}

.toc-name em {
  display: block;
  margin-top: 3px;
  font-style: normal;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.toc-row:hover .toc-name { color: var(--accent); }

.toc-dots {
  flex: 1;
  min-width: 24px;
  margin-top: 14px;
  border-bottom: 1px dotted rgba(15, 48, 87, 0.35);
}

.toc-page {
  flex: none;
  width: 26px;
  text-align: right;
  font-family: var(--serif);
  font-size: 0.78rem;
  color: var(--muted);
  transition: color 0.25s;
}

.toc-row:hover .toc-page { color: var(--ink); }

.contents-foot {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: clamp(48px, 6vw, 72px);
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
  color: var(--muted);
}

.contents-foot a { border-bottom: 1px solid var(--line-strong); padding-bottom: 1px; transition: color 0.3s, border-color 0.3s; }
.contents-foot a:hover { color: var(--accent); border-color: var(--accent); }

/* ---------------- 面包屑 ---------------- */
.doc-head + .crumbs { margin-top: 30px; }

.crumbs {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: clamp(32px, 5vw, 56px);
}

.crumbs a { border-bottom: 1px solid transparent; transition: border-color 0.3s, color 0.3s; }
.crumbs a:hover { color: var(--ink); border-color: var(--ink); }
.crumbs span { opacity: 0.5; }

/* ---------------- 作品详情 ---------------- */
.detail { padding: clamp(96px, 12vw, 128px) 0 clamp(64px, 8vw, 100px); }

.detail-head { max-width: 52em; }

.detail-eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  color: var(--muted);
  margin-bottom: 14px;
}

.detail-eyebrow span { opacity: 0.5; margin: 0 4px; }

.detail-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.3;
  letter-spacing: -0.03em;
}

.detail-sub { margin-top: 12px; color: var(--muted); font-size: 1rem; }

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 32px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-size: 0.84rem;
}

.detail-meta li { display: flex; gap: 10px; align-items: baseline; }
.detail-meta span { color: var(--muted-2); font-size: 0.7rem; letter-spacing: 0.12em; }

.detail-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: clamp(36px, 5vw, 56px) 0;
  padding: clamp(16px, 3vw, 44px);
  background: var(--navy);
  border-radius: 3px;
  overflow: hidden;
}

.detail-cover img {
  width: auto;
  max-width: 100%;
  max-height: 64vh;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.detail-cover--plain {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 7;
  font-family: var(--serif);
  font-size: clamp(3rem, 8vw, 6rem);
  color: rgba(255, 255, 255, 0.22);
  letter-spacing: -0.03em;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.detail-summary { font-size: 1.02rem; line-height: 2; color: var(--ink-2); }

.detail-h2 {
  font-size: 0.74rem;
  letter-spacing: 0.22em;
  color: var(--muted);
  font-weight: 500;
  margin: 44px 0 16px;
}

.detail-points { border-top: 1px solid var(--line); }

.detail-points li {
  position: relative;
  padding: 16px 0 16px 24px;
  border-bottom: 1px solid var(--line);
  font-size: 0.9rem;
  line-height: 1.9;
  color: var(--ink-2);
}

.detail-points li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 24px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.detail-aside {
  border: 1px solid var(--line);
  padding: 24px;
  border-radius: 2px;
  position: sticky;
  top: 96px;
}

.detail-aside h3 {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 16px;
}

.detail-aside dl { display: grid; gap: 12px; }

.detail-aside dl > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--line);
}

.detail-aside dl > div:last-child { border-bottom: none; padding-bottom: 0; }
.detail-aside dt { color: var(--muted); }
.detail-aside dd { text-align: right; }

.detail-gallery {
  display: grid;
  gap: clamp(16px, 2.4vw, 24px);
  margin-top: clamp(36px, 5vw, 56px);
}

.detail-figure {
  margin: 0;
  background: var(--navy);
  border-radius: 3px;
  overflow: hidden;
}

.detail-figure img { width: 100%; height: auto; display: block; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1); }

.detail-gallery.gallery-duo {
  grid-template-columns: 1fr 1fr;
}

.detail-gallery.gallery-duo .detail-figure {
  display: flex;
  justify-content: center;
  background: #f0ede4;
}

.detail-gallery.gallery-duo img {
  width: auto;
  max-height: 620px;
}

.doc-foot {
  display: flex;
  justify-content: space-between;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
}

.detail-nav {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-top: clamp(48px, 6vw, 80px);
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.detail-nav a {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.92rem;
  max-width: 46%;
  transition: color 0.3s;
}

.detail-nav a:hover { color: var(--accent); }

.detail-nav a span {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.detail-nav .next { text-align: right; margin-left: auto; }

/* ---------------- 荣誉证书 ---------------- */
.cert-group { margin-bottom: clamp(40px, 6vw, 64px); }

.cert-group-title {
  font-size: 0.72rem;
  letter-spacing: 0.24em;
  color: var(--muted);
  font-weight: 500;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-strong);
  margin-bottom: 28px;
}

.cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr));
  gap: clamp(28px, 4vw, 44px) clamp(20px, 3vw, 32px);
}

.cert-card {
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  cursor: pointer;
}

.cert-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  height: clamp(210px, 24vw, 272px);
  background-color: #fbfcfe;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 12px;
  overflow: hidden;
  transition: box-shadow 0.4s var(--ease), transform 0.4s var(--ease),
    border-color 0.3s;
}

.cert-frame img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform 0.6s var(--ease);
}

.cert-card:hover .cert-frame {
  border-color: var(--line-strong);
  box-shadow: 0 22px 50px -30px rgba(15, 48, 87, 0.5);
  transform: translateY(-3px);
}

.cert-card:hover .cert-frame img { transform: scale(1.015); }

.cert-title {
  display: block;
  margin-top: 16px;
  font-size: 0.92rem;
  line-height: 1.55;
  font-weight: 500;
  transition: color 0.25s;
}

.cert-card:hover .cert-title { color: var(--accent); }

.cert-meta {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-top: 8px;
  font-size: 0.76rem;
  color: var(--muted);
  font-family: var(--serif);
}

.cert-meta em {
  font-family: var(--sans);
  font-style: normal;
  color: var(--accent);
  font-size: 0.74rem;
}

.cert-note { display: block; margin-top: 2px; font-size: 0.72rem; color: var(--muted-2); }

/* ---------------- 图片放大 ---------------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 2vw, 24px);
  padding: clamp(16px, 4vw, 48px);
  background: rgba(12, 11, 9, 0.965);
  opacity: 0;
  transition: opacity 0.25s var(--ease);
}

.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; }

.lb-stage { margin: 0; max-width: min(1100px, 92vw); max-height: 88svh; display: flex; flex-direction: column; align-items: center; gap: 18px; }

.lb-stage img {
  max-width: 100%;
  max-height: 78svh;
  width: auto;
  height: auto;
  object-fit: contain;
  background: #fff;
  border-radius: 2px;
  box-shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.9);
}

.lb-stage figcaption {
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.82rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.lb-stage figcaption strong { font-weight: 500; }
.lb-stage figcaption span { color: rgba(255, 255, 255, 0.55); font-size: 0.74rem; letter-spacing: 0.06em; }

.lb-close, .lb-prev, .lb-next {
  position: absolute;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.88);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}

.lb-close:hover, .lb-prev:hover, .lb-next:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.55);
  color: #fff;
}

.lb-close { top: clamp(16px, 3vw, 32px); right: clamp(16px, 3vw, 32px); }
.lb-prev { left: clamp(8px, 2vw, 28px); top: 50%; transform: translateY(-50%); }
.lb-next { right: clamp(8px, 2vw, 28px); top: 50%; transform: translateY(-50%); }

/* ---------------- 关于 ---------------- */
.about-head { max-width: 46em; margin-bottom: clamp(36px, 5vw, 56px); }

.about-head h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 8px 0 18px;
}

.about-lead { color: var(--muted); font-size: 1rem; }

.about-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(36px, 6vw, 92px);
  align-items: start;
}

.about-text p {
  font-size: 0.97rem;
  line-height: 2;
  color: var(--ink-2);
  margin-bottom: 20px;
}

.about-text p:first-child { color: var(--ink); font-size: 1.02rem; }
.about-text p:last-child { margin-bottom: 0; }
.about-goal { color: var(--muted) !important; font-size: 0.9rem !important; }

.skill-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.skill-card { background: var(--paper); padding: clamp(20px, 2.4vw, 28px); }

.skill-card h3 {
  font-size: 0.88rem;
  letter-spacing: 0.02em;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.skill-card h3::before {
  content: "";
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
}

.skill-card p { font-size: 0.8rem; line-height: 1.85; color: var(--muted); }

.honors-block { margin-top: clamp(56px, 8vw, 92px); }

.block-title {
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  letter-spacing: -0.02em;
  margin-bottom: clamp(28px, 4vw, 40px);
}

.timeline { position: relative; border-left: 1px solid var(--line); margin-left: 6px; }

.tl-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: clamp(16px, 3vw, 40px);
  padding: 0 0 clamp(30px, 4vw, 44px) clamp(22px, 3vw, 40px);
  position: relative;
}

.tl-item::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 10px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--ink);
}

.tl-item:last-child { padding-bottom: 0; }

.tl-time {
  font-family: var(--serif);
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  padding-top: 3px;
}

.tl-main h3 { font-size: 1rem; line-height: 1.5; }
.tl-org { font-size: 0.78rem; color: var(--accent); letter-spacing: 0.04em; margin-top: 4px; }
.tl-desc { font-size: 0.88rem; line-height: 1.9; color: var(--muted); margin-top: 8px; max-width: 46em; }

.more-link { margin-top: 32px; font-size: 0.86rem; }
.more-link a { border-bottom: 1px solid var(--line-strong); padding-bottom: 2px; transition: color 0.3s, border-color 0.3s; }
.more-link a:hover { color: var(--accent); border-color: var(--accent); }

/* 深色页面上的导航反色 */
body.on-dark { background: var(--navy); }
body.on-dark h1,
body.on-dark h2 { color: #fff; }

body.on-dark .nav { color: var(--paper); }
body.on-dark .nav-brand,
body.on-dark .nav-links { color: rgba(255, 255, 255, 0.72); }
body.on-dark .nav-links a.is-active { color: var(--paper); }
body.on-dark .brand-en { color: rgba(255, 255, 255, 0.5); }
body.on-dark .nav-links a::after { background: var(--paper); }
body.on-dark .doc-head {
  color: rgba(255, 255, 255, 0.55);
  border-bottom-color: rgba(255, 255, 255, 0.18);
}

body.on-dark .nav.is-scrolled {
  background: rgba(15, 48, 87, 0.9);
  border-bottom-color: rgba(255, 255, 255, 0.14);
}

/* ---------------- 联系页 ---------------- */
.section-dark { background: var(--navy); color: #fff; }

.crumbs-dark { color: rgba(255, 255, 255, 0.5); }
.crumbs-dark a:hover { color: var(--paper); border-color: var(--paper); }

.section-dark .section-no { color: rgba(255, 255, 255, 0.5); }

.contact-title {
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.03em;
  margin: 8px 0 22px;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}

.contact-lead {
  color: rgba(255, 255, 255, 0.66);
  font-size: 0.95rem;
  line-height: 2;
  max-width: 34em;
}

.contact-list { margin-top: 40px; border-top: 1px solid rgba(255, 255, 255, 0.18); }

.contact-list li {
  display: flex;
  gap: 24px;
  align-items: baseline;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 0.92rem;
}

.contact-label {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.5);
  min-width: 52px;
}

.contact-list a { border-bottom: 1px solid rgba(255, 255, 255, 0.32); padding-bottom: 1px; transition: border-color 0.3s; }
.contact-list a:hover { border-color: var(--paper); }

.contact-side { text-align: center; }

.qr-card {
  margin: 0;
  display: inline-block;
  background: var(--paper);
  padding: 18px 18px 14px;
  border-radius: 3px;
  box-shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.7);
}

.qr-card img { width: 200px; height: 200px; image-rendering: pixelated; }

.qr-card figcaption { margin-top: 10px; font-size: 0.72rem; letter-spacing: 0.16em; color: var(--muted); }

.contact-hint {
  margin: 22px auto 0;
  font-size: 0.76rem;
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.48);
  max-width: 24em;
}

/* ---------------- 页脚 ---------------- */
.footer {
  background: var(--navy);
  color: rgba(255, 255, 255, 0.48);
  font-size: 0.76rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  padding: 26px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer a { transition: color 0.3s; }
.footer a:hover { color: var(--paper); }

/* ---------------- 页面切换 ---------------- */
#app.is-entering { animation: viewIn 0.5s var(--ease) both; }

@keyframes viewIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  #app.is-entering { animation: none; }
  * { transition-duration: 0.001ms !important; }
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 980px) {
  .cover { padding-top: 88px; min-height: auto; }
  .cover-grid { grid-template-columns: 1fr; display: block; position: relative; }
  .cover-photo {
    position: absolute;
    top: 0;
    right: 0;
    width: 104px;
    margin: 0;
    justify-self: auto;
    align-self: auto;
  }
  .cover-photo-inner { padding: 5px; }
  .cover-photo figcaption { display: none; }
  .cover-kicker { padding-right: 120px; }
  .cover-meta { grid-template-columns: 1fr 1fr; }
  .contents-head { grid-template-columns: 1fr; align-items: start; }
  .about-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .contact-side { text-align: left; }
  .contact-hint { margin-left: 0; }
  .section-head { grid-template-columns: 1fr; }
  .section-head .section-no { padding-top: 0; }
  .section-desc { grid-column: 1; }
  .detail-cover--plain {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 7;
  font-family: var(--serif);
  font-size: clamp(3rem, 8vw, 6rem);
  color: rgba(255, 255, 255, 0.22);
  letter-spacing: -0.03em;
}

.detail-grid { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
}

@media (max-width: 720px) {
  .toc-name { max-width: 74%; font-size: 0.9rem; }
  .toc-dots { display: none; }
  .toc-page { margin-left: auto; }
  .toc-row { padding: 13px 0; }
  .tl-item { grid-template-columns: 1fr; gap: 6px; padding-left: 18px; }
  .tl-time { padding-top: 0; }
  .cert-frame { height: 210px; }
  .doc-foot {
  display: flex;
  justify-content: space-between;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
}

.detail-nav { flex-direction: column; gap: 20px; }
  .detail-nav a { max-width: 100%; }
  .detail-nav .next { text-align: left; margin-left: 0; }
}

@media (max-width: 640px) {
  body { font-size: 15px; }
  .nav { height: 60px; }
  .nav-links { gap: 14px; font-size: 0.8rem; }
  .brand-en { display: none; }
  .cover-meta { gap: 16px; }
  .cover-photo { width: 92px; }
  .skill-cards { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 6px; }
  .lb-prev { left: 8px; }
  .lb-next { right: 8px; }
  .lb-prev, .lb-next { width: 38px; height: 38px; }
}

/* ---------------- 问答助手 ---------------- */
.chat-fab {
  position: fixed;
  right: clamp(16px, 3vw, 28px);
  bottom: clamp(16px, 3vw, 28px);
  z-index: 90;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--navy);
  color: #fff;
  font-size: 22px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 14px 34px -12px rgba(15, 48, 87, 0.55);
  transition: transform 0.3s var(--ease), background 0.3s var(--ease);
}

.chat-fab:hover { background: var(--navy-soft); transform: translateY(-2px); }
.chat-fab.is-open { display: none; }

.chat-panel {
  position: fixed;
  right: clamp(16px, 3vw, 28px);
  bottom: clamp(16px, 3vw, 28px);
  z-index: 91;
  width: min(392px, calc(100vw - 32px));
  max-height: min(600px, calc(100svh - 48px));
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 30px 80px -30px rgba(15, 48, 87, 0.45);
  animation: chatIn 0.28s var(--ease);
}

.chat-panel[hidden] { display: none; }

@keyframes chatIn {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.chat-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 18px 20px 16px;
  background: var(--navy);
  color: #fff;
}

.chat-title { font-size: 0.95rem; font-weight: 600; letter-spacing: 0.02em; }
.chat-sub { margin-top: 4px; font-size: 0.7rem; color: rgba(255, 255, 255, 0.62); line-height: 1.5; }

.chat-close {
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  font-size: 0.85rem;
  padding: 2px 4px;
  line-height: 1;
  transition: color 0.2s;
}

.chat-close:hover { color: #fff; }

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px 18px 6px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 180px;
  background: #fbfcfe;
}

.chat-msg {
  max-width: 86%;
  padding: 11px 14px;
  border-radius: 12px;
  font-size: 0.84rem;
  line-height: 1.75;
  white-space: pre-line;
  animation: msgIn 0.26s var(--ease);
}

@keyframes msgIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.chat-msg.bot {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  border-bottom-left-radius: 4px;
}

.chat-msg.user {
  align-self: flex-end;
  background: var(--navy);
  color: #fff;
  border-bottom-right-radius: 4px;
}

.chat-msg.is-typing { display: flex; gap: 4px; align-items: center; padding: 14px; }
.chat-msg.is-typing span {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--muted-2);
  animation: dot 1s infinite ease-in-out;
}
.chat-msg.is-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-msg.is-typing span:nth-child(3) { animation-delay: 0.3s; }

@keyframes dot {
  0%, 80%, 100% { opacity: 0.3; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-2px); }
}

.chat-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.chat-chip {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 5px 11px;
  font-size: 0.72rem;
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.chat-chip:hover { border-color: var(--navy); color: var(--navy); background: #f4f7fb; }

.chat-input {
  display: flex;
  gap: 8px;
  padding: 12px 16px 14px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.chat-input input {
  flex: 1;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.84rem;
  color: var(--ink);
  outline: none;
  transition: border-color 0.2s;
}

.chat-input input:focus { border-color: var(--navy); }

.chat-input button {
  border: none;
  background: var(--navy);
  color: #fff;
  border-radius: 8px;
  padding: 0 16px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 0.2s;
}

.chat-input button:hover { background: var(--navy-soft); }

@media (max-width: 640px) {
  .chat-panel { max-height: 74svh; }
  .chat-body { min-height: 150px; }
}
