/* =========================================================
   Daisy Fang — Portfolio · Style B "Studio Index"
   改颜色、字体：只需要改下面 :root 里的变量
   ========================================================= */
:root {
  --bg: #F2F0EB;        /* 页面底色 */
  --panel: #E8E5DE;     /* 图片底板 */
  --ink: #161514;       /* 主文字、粗线 */
  --muted: #5C5853;     /* 次要文字 */
  --line: #C9C4BB;      /* 细分割线 */
  --accent: #A63F2A;    /* 强调色（锈红） */
  --white: #FFFFFF;

  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --mono: 'IBM Plex Mono', ui-monospace, Menlo, Consolas, monospace;

  --dur: .8s;                          /* 动效时长 */
  --ease: cubic-bezier(.16, 1, .3, 1); /* 顺滑减速 */
  --max: 1280px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3 { text-wrap: balance; }

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px), 4vw);
  padding-right: max(16px, env(safe-area-inset-right, 0px), 4vw);
}
@media (min-width: 1400px) { .wrap { padding-left: 56px; padding-right: 56px; } }

.mono { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.muted { color: var(--muted); }
.accent { color: var(--accent); }

/* ---------- Top bar ---------- */
.topbar {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
  gap: 10px 24px; padding-block: 22px; border-bottom: 1px solid var(--ink);
}
.topbar a { text-decoration: none; }
.topbar nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* ---------- M7: link micro-interactions ---------- */
.ul {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) left bottom / 0 1px no-repeat;
  transition: background-size .5s var(--ease);
  padding-bottom: 2px;
}
.ul:hover, .ul:focus-visible { background-size: 100% 1px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 44px; padding: 10px 18px;
  border: 1px solid var(--ink); background: transparent; color: var(--ink);
  font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
  transition: background .3s, color .3s;
}
.btn i { font-style: normal; display: inline-block; transition: transform .4s var(--ease); }
.btn:hover { background: var(--ink); color: var(--bg); }
.btn:hover i, .btn:focus-visible i { transform: translateX(6px); }
.btn-accent { border-color: var(--accent); color: var(--accent); }
.btn-accent:hover { background: var(--accent); color: var(--white); }

/* ---------- Hero ---------- */
.hero {
  display: flex; flex-wrap: wrap; align-items: flex-end;
  gap: 40px clamp(32px, 6vw, 96px);
  padding-block: clamp(56px, 9vw, 128px) clamp(56px, 8vw, 104px);
}
.hero h1 {
  flex: 999 1 560px; min-width: 0; margin: 0;
  font-weight: 300; font-size: clamp(44px, 6.4vw, 96px);
  line-height: 1.02; letter-spacing: -.025em;
}
.hero h1 em { color: var(--accent); }
.facts {
  flex: 1 1 280px; min-width: 0; margin: 0;
  display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 14px 16px;
  font-family: var(--mono); font-size: 13px; line-height: 1.5;
}
.facts dt { color: var(--muted); text-transform: uppercase; }
.facts dd { margin: 0; }

/* ---------- M1: line reveal ---------- */
.reveal .ln { display: block; overflow: hidden; padding: .12em .1em .26em; margin: -.12em -.1em -.26em; }
.reveal .ln > span { display: block; transition: transform 1s var(--ease); transition-delay: calc(var(--i, 0) * .09s); }
.js .reveal:not(.in) .ln > span { transform: translateY(110%); }

/* ---------- M2: fade up ---------- */
.js [data-fade] { opacity: 0; transform: translateY(28px); transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease); transition-delay: calc(var(--i, 0) * .12s); }
.js [data-fade].in { opacity: 1; transform: none; }

/* ---------- Project index (M3 rule draw + M4 hover preview) ---------- */
.section-head {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline;
  gap: 8px 24px; padding-block: 14px;
}
.index { position: relative; border-top: 1px solid var(--ink); }
.index-head, .row {
  display: grid; grid-template-columns: 56px minmax(0, 3fr) minmax(0, 2fr) 72px;
  gap: 16px; align-items: baseline;
}
.index-head { padding-block: 14px; color: var(--muted); border-bottom: 1px solid var(--line); }
.row {
  position: relative; padding-block: 22px; text-decoration: none; color: var(--ink);
}
.row::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--line);
  transform-origin: left; transition: transform 1.1s var(--ease); transition-delay: calc(var(--i, 0) * .1s);
}
.row.last::after { background: var(--ink); }
.row > * { transition: opacity .6s var(--ease), color .3s; transition-delay: calc(var(--i, 0) * .1s + .2s); }
.js .index:not(.in) .row::after { transform: scaleX(0); }
.js .index:not(.in) .row > * { opacity: 0; }

.row .n { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.row .t { font-size: clamp(24px, 2.6vw, 36px); line-height: 1.15; letter-spacing: -.01em; transition: transform .45s var(--ease), opacity .3s; }
.row .d, .row .y { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.row .y { text-align: right; }
.row .soon { font-family: var(--mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; margin-left: 10px; vertical-align: middle; white-space: nowrap; }
.index.settled .row > * { transition-delay: 0s; }
.index:hover .row:not(:hover) .t { opacity: .4; }
.row:hover .t, .row:focus-visible .t { transform: translateX(14px); }
.row:hover .n, .row:focus-visible .n { color: var(--accent); }

.peek {
  position: absolute; left: 0; top: 0; z-index: 3; pointer-events: none;
  width: clamp(180px, 18vw, 260px); aspect-ratio: 4 / 5;
  background: var(--panel); padding: 18px;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: translate(-50%, -50%) scale(.85);
  transition: opacity .25s, transform .4s var(--ease);
}
.peek.on { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.peek img { width: 100%; height: 100%; object-fit: contain; }
@media (hover: none) { .peek { display: none; } }

@media (max-width: 700px) {
  .index-head { display: none; }
  .row { grid-template-columns: 40px minmax(0, 1fr) auto; row-gap: 4px; }
  .row .d { grid-column: 2 / 3; grid-row: 2; }
  .row .y { grid-column: 3; grid-row: 1; }
}

/* ---------- Image grid ---------- */
.gallery {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(16px, 2vw, 28px); padding-block: clamp(56px, 8vw, 104px);
}
.fig { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.fig .frame { background: var(--panel); aspect-ratio: 1 / 1; max-width: 100%; display: flex; align-items: center; justify-content: center; padding: clamp(20px, 3vw, 40px); overflow: hidden; }
.fig .frame.white { background: var(--white); }
.fig .frame img { width: 100%; height: 100%; object-fit: contain; }
.fig .frame.cover { padding: 0; }
.fig .frame.cover img { object-fit: cover; }
.fig figcaption { display: flex; justify-content: space-between; gap: 12px; }

/* ---------- Numbers ---------- */
.numbers {
  border-top: 1px solid var(--ink);
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 32px; padding-block: 40px clamp(56px, 8vw, 104px);
}
.num { display: flex; flex-direction: column; gap: 10px; }
.num b { font-weight: 300; font-size: clamp(52px, 6vw, 88px); line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.num span { font-family: var(--mono); font-size: 13px; line-height: 1.5; color: var(--muted); }

/* ---------- About ---------- */
.about {
  border-top: 1px solid var(--ink);
  display: flex; flex-wrap: wrap; gap: 40px clamp(40px, 6vw, 96px);
  padding-block: 40px clamp(56px, 8vw, 104px);
}
.about-text { flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.about-text h2 { margin: 0; font-weight: 300; font-size: clamp(32px, 3.6vw, 48px); line-height: 1.12; letter-spacing: -.015em; }
.about-text h2 em { color: var(--accent); }
.about-text p { margin: 0; color: var(--muted); max-width: 58ch; }
.cv { flex: 1 1 380px; min-width: 0; list-style: none; margin: 0; padding: 0; }
.cv li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.cv li:first-child { border-top: 1px solid var(--line); }
.cv .role { display: flex; flex-direction: column; }
.cv .role small { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.cv .when { font-family: var(--mono); font-size: 13px; color: var(--muted); white-space: nowrap; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--ink);
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end;
  gap: 32px; padding-block: clamp(48px, 7vw, 96px) 40px;
}
.footer h2 { margin: 0; font-weight: 300; font-size: clamp(44px, 6vw, 88px); line-height: 1; letter-spacing: -.02em; }
.contact { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; font-family: var(--mono); font-size: 14px; }
.copy-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.copy-btn { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; background: none; border: 1px solid var(--line); color: var(--muted); padding: 6px 10px; min-height: 32px; cursor: pointer; }
.copy-btn:hover { border-color: var(--ink); color: var(--ink); }

/* =========================================================
   Case study pages
   ========================================================= */
.case-hero { padding-block: clamp(48px, 8vw, 112px) clamp(32px, 5vw, 64px); display: flex; flex-direction: column; gap: 24px; }
.case-hero h1 { margin: 0; font-weight: 300; font-size: clamp(48px, 7vw, 104px); line-height: 1; letter-spacing: -.03em; }
.case-hero h1 em { color: var(--accent); }
.case-hero .lede { margin: 0; font-size: clamp(20px, 2vw, 26px); line-height: 1.45; max-width: 36ch; color: var(--muted); }

.meta {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink);
}
.meta div { padding: 18px 18px 18px 0; display: flex; flex-direction: column; gap: 6px; }
.meta dt { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.meta dd { margin: 0; font-size: 17px; line-height: 1.45; }
.meta dd strong { font-weight: 500; color: var(--accent); }

.cover-img { margin: clamp(32px, 5vw, 64px) 0 0; background: var(--panel); display: flex; justify-content: center; padding: clamp(24px, 5vw, 72px); }
.cover-img img { max-height: 620px; width: auto; }

.stage-sec {
  display: flex; flex-wrap: wrap; gap: 24px clamp(32px, 6vw, 96px);
  padding-block: clamp(56px, 8vw, 104px); border-bottom: 1px solid var(--line);
}
.stage-label { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.stage-label .step { font-family: var(--mono); font-size: 13px; color: var(--accent); }
.stage-label h2 { margin: 0; font-weight: 400; font-size: clamp(32px, 3.4vw, 46px); line-height: 1.05; letter-spacing: -.015em; }
.stage-body { flex: 3 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.stage-body > p { margin: 0; max-width: 64ch; }
.stage-body .big { font-size: clamp(22px, 2.2vw, 30px); line-height: 1.35; letter-spacing: -.01em; }

.mine {
  display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px;
  padding: 16px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line);
}
.mine dt { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); padding-top: 4px; }
.mine dd { margin: 0; }
@media (max-width: 520px) { .mine { grid-template-columns: minmax(0, 1fr); gap: 6px; } }

.stats3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 24px; }
.stats3 div { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--ink); padding-top: 12px; }
.stats3 b { font-weight: 300; font-size: clamp(40px, 4.4vw, 60px); line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.stats3 span { font-family: var(--mono); font-size: 12.5px; color: var(--muted); line-height: 1.5; }

.insights { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.insights li { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--ink); padding-top: 14px; }
.insights b { font-weight: 400; font-size: 24px; line-height: 1.2; }
.insights span { color: var(--muted); font-size: 16px; }

.quote { margin: 0; padding-left: 0; font-size: clamp(24px, 2.6vw, 34px); line-height: 1.3; font-style: italic; font-weight: 300; max-width: 30ch; }
.quote cite { display: block; margin-top: 10px; font-style: normal; font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }

.funnel { display: flex; flex-wrap: wrap; align-items: stretch; border-top: 1px solid var(--ink); }
.funnel div { flex: 1 1 140px; display: flex; flex-direction: column; gap: 4px; padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); }
.funnel b { font-weight: 300; font-size: clamp(40px, 4vw, 56px); line-height: 1; }
.funnel span { font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.funnel .final b { color: var(--accent); }

.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; }
.timeline li { display: flex; flex-direction: column; gap: 12px; }
.timeline .frame { background: var(--panel); aspect-ratio: 4 / 3; max-width: 100%; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.timeline .frame img { width: 100%; height: 100%; object-fit: cover; }
.timeline .frame.contain { padding: 20px; }
.timeline .frame.contain img { object-fit: contain; }
.timeline h3 { margin: 0; font-weight: 400; font-size: 22px; line-height: 1.2; }
.timeline p { margin: 0; font-size: 16px; color: var(--muted); }

.pets { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; background: var(--panel); padding: clamp(16px, 3vw, 40px); }
.pets img { width: 100%; height: auto; }
@media (max-width: 560px) { .pets { grid-template-columns: repeat(3, minmax(0, 1fr)); } .pets img:nth-child(n+4) { display: none; } }

.duo { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }

.limit { border-left: 2px solid var(--accent); padding: 4px 0 4px 18px; color: var(--muted); font-size: 16px; max-width: 64ch; margin: 0; }

.next {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 24px;
  padding-block: clamp(48px, 7vw, 96px) 40px;
}
.next a.big-link { text-decoration: none; font-weight: 300; font-size: clamp(36px, 5vw, 72px); letter-spacing: -.02em; line-height: 1; }
.next a.big-link i { font-style: normal; display: inline-block; transition: transform .45s var(--ease); color: var(--accent); }
.next a.big-link:hover i { transform: translateX(10px); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; transition-delay: 0s !important; }
  .js .reveal:not(.in) .ln > span, .js [data-fade], .js .index:not(.in) .row > * { transform: none; opacity: 1; }
  .js .index:not(.in) .row::after { transform: none; }
}

/* =========================================================
   Coursework：文件夹卡片
   ========================================================= */
.coursework { border-top: 1px solid var(--ink); padding-bottom: clamp(56px, 8vw, 104px); }
.folders {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 56px 24px; padding-top: 44px;
}
.folder { position: relative; background: var(--panel); display: flex; flex-direction: column; }
.folder .tab {
  position: absolute; left: 0; bottom: 100%;
  height: 30px; padding: 0 30px 0 16px;
  display: flex; align-items: center;
  background: var(--panel); color: var(--ink);
  clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 100%, 0 100%);
  white-space: nowrap; max-width: 100%;
}
.folder-img { aspect-ratio: 16 / 10; max-width: 100%; display: flex; align-items: center; justify-content: center; padding: 20px; margin: 16px 16px 0; background: var(--bg); }
.folder-img.white { background: var(--white); }
.folder-img img { width: 100%; height: 100%; object-fit: contain; }
.folder-body { padding: 20px 20px 24px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.folder-body h3 { margin: 0; font-weight: 400; font-size: 26px; line-height: 1.15; letter-spacing: -.01em; }
.folder-body p { margin: 0; font-size: 16px; }
.folder-body p.mono { font-size: 11.5px; }
.kv { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.kv div { display: flex; flex-direction: column; gap: 4px; }
.kv dt { font-family: var(--mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.kv dd { margin: 0; font-size: 22px; font-weight: 300; line-height: 1.1; font-variant-numeric: tabular-nums; }

.folder-more { background: transparent; border: 1px dashed var(--line); justify-content: center; min-height: 240px; }
.folder-more .tab { background: var(--bg); color: var(--muted); border: 1px dashed var(--line); border-bottom: 0; clip-path: none; border-radius: 6px 6px 0 0; left: -1px; padding-right: 16px; }
.folder-more .folder-body { justify-content: center; flex: 0; }
.folder-more .more-title { font-size: 28px; font-style: italic; font-weight: 300; line-height: 1.2; }
.kv dd.sm { font-size: 17px; padding-top: 4px; white-space: nowrap; }

/* =========================================================
   ImpPets：封面整图、最终设计整版、PDF 链接
   ========================================================= */
.cover-img.full { padding: 0; background: none; }
.cover-img.full img { width: 100%; height: auto; max-height: none; }

.board { margin: 0; padding-block: clamp(48px, 7vw, 88px); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 20px; }
.board-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 24px; }
.board-title { flex: 1 1 320px; font-size: clamp(24px, 2.4vw, 32px); font-weight: 400; letter-spacing: -.01em; }
.board-img { display: block; cursor: zoom-in; }
.board-img img { width: 100%; height: auto; }

.doc-link {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto auto;
  column-gap: 24px; row-gap: 6px; align-items: center;
  margin-block: 0; padding: clamp(28px, 4vw, 44px) 0;
  border-bottom: 1px solid var(--ink); text-decoration: none; color: var(--ink);
}
.doc-link .mono { grid-column: 1; }
.doc-link .doc-title { grid-column: 1; font-size: clamp(30px, 4vw, 56px); font-weight: 300; line-height: 1.05; letter-spacing: -.02em; transition: transform .45s var(--ease); }
.doc-link i { grid-column: 2; grid-row: 1 / 4; font-style: normal; font-size: clamp(32px, 4vw, 56px); color: var(--accent); transition: transform .45s var(--ease); }
.doc-link:hover .doc-title, .doc-link:focus-visible .doc-title { transform: translateX(12px); }
.doc-link:hover i, .doc-link:focus-visible i { transform: translate(6px, -6px); }

/* ImpPets：品牌标识 */
.brand-logo { background: var(--white); padding: clamp(32px, 6vw, 72px); display: flex; justify-content: center; }
.brand-logo img { width: min(100%, 560px); height: auto; }
.swatches { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.swatches li { display: flex; flex-direction: column; gap: 10px; padding: 0; }
.swatches .chip { display: block; height: 64px; }
.swatches .mono { line-height: 1.5; }

/* ImpPets：宠物成长与收集 */
.growth { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.growth li { display: flex; flex-direction: column; gap: 10px; position: relative; }
.growth img { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
.growth b { color: var(--accent); font-weight: 500; margin-right: 6px; }
.collection { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.collection img { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
@media (max-width: 560px) {
  .growth { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .growth .mono { font-size: 10px; }
  .collection { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.fig .frame.app-frame { aspect-ratio: auto; padding: 0; background: #FAF8FC; }
.fig .frame.app-frame img { width: min(100%, 620px); height: auto; margin: 0 auto; }

/* ImpPets：爆炸图解说（按报告总页面排版） */
.anatomy { padding-block: clamp(48px, 7vw, 88px); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 20px; }
.anatomy-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 24px; }
.anatomy-head h3 { margin: 0; font-weight: 400; font-size: clamp(26px, 2.8vw, 36px); letter-spacing: -.01em; }
.anatomy-stage { position: relative; background: #C5C9CA; }
.anatomy-stage img { width: 100%; height: auto; }
.parts { list-style: none; margin: 0; padding: 0; }
.parts li { position: absolute; left: 4%; top: var(--y); width: calc(var(--tip) - 4%); transform: translateY(-50%); display: flex; align-items: center; gap: 10px; }
.parts .txt { display: flex; flex-direction: column; gap: 2px; max-width: 15em; flex: 0 1 auto; }
.parts b { font-family: var(--mono); font-weight: 500; font-size: clamp(11px, 1.05vw, 14px); letter-spacing: .08em; text-transform: uppercase; color: #1A2855; }
.parts i { font-family: var(--serif); font-size: clamp(12px, 1.1vw, 15px); line-height: 1.3; color: #2E3340; }
.parts .lead { flex: 1 1 24px; min-width: 24px; height: 0; border-top: 1.5px dotted #1A2855; position: relative; }
.parts .lead::after { content: ""; position: absolute; right: -4px; top: -4.5px; width: 7px; height: 7px; border-radius: 50%; background: #1A2855; }
@media (max-width: 760px) {
  .anatomy-stage { background: none; }
  .parts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; padding-top: 16px; counter-reset: part; }
  .parts li { position: static; width: auto; transform: none; }
  .parts .lead { display: none; }
  .parts i { color: var(--muted); }
}

/* ImpPets：嵌入的 App 演示 */
.try-app { padding-block: clamp(48px, 7vw, 88px); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; }
.try-app .anatomy-head a { margin-left: auto; }
.try-app iframe { width: 100%; height: 900px; border: 0; display: block; background: var(--bg); }

/* ImpPets：标题区 D 版（Logo 作标题 + 手拿手机图） */
.case-hero.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px 48px; align-items: center; }
.hero-text { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.case-hero.split h1 { font-size: clamp(44px, 5.4vw, 84px); }
.case-hero .h1-logo { display: block; width: min(100%, 420px); height: auto; margin: 0 0 18px -6px; }
.case-hero .reveal { display: block; }
.hero-photo { margin: 0; display: flex; justify-content: center; min-width: 0; }
.hero-photo img { width: 100%; max-width: 640px; height: auto; -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent); mask-image: linear-gradient(to bottom, #000 78%, transparent); }
@media (max-width: 860px) { .case-hero.split { grid-template-columns: minmax(0, 1fr); } }

/* Coursework：整张文件夹卡片都可以点开报告 */
.folder { transition: transform .45s var(--ease), box-shadow .45s var(--ease); }
.folder:has(.folder-link):hover { transform: translateY(-4px); box-shadow: 0 18px 40px -24px rgba(22,21,20,.35); }
.folder-link { align-self: flex-start; margin-top: 4px; font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); text-decoration: none; display: inline-flex; gap: 8px; align-items: center; }
.folder-link::after { content: ""; position: absolute; inset: 0; }
.folder-link i { font-style: normal; transition: transform .4s var(--ease); }
.folder:hover .folder-link i, .folder-link:focus-visible i { transform: translate(3px, -3px); }

/* ---------- small-screen tip above interactive frames ---------- */
.big-screen-note { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; padding: 10px 12px; border: 1px solid var(--line); border-left: 2px solid var(--accent); background: var(--white); font-size: 11.5px; line-height: 1.45; color: var(--muted); letter-spacing: .02em; text-transform: none; }
.big-screen-note[hidden] { display: none; }
.big-screen-note > span:first-child { color: var(--accent); font-size: 15px; line-height: 1; }
.big-screen-note > span:nth-child(2) { flex: 1; }
.big-screen-note button { border: 0; background: none; font-size: 18px; line-height: 1; color: var(--muted); cursor: pointer; padding: 4px 6px; min-width: 32px; min-height: 32px; }
