/* 赛博太医 · 宫廷问诊主题层。只覆盖大屏首页与部位选择页。 */
@font-face {
  font-family: 'ImperialGold';
  src: url('/js/assets/imperial-gold.woff?v=20261016') format('woff');
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  --palace-red: #7c1f1c;
  --palace-red-light: #a43b2e;
  --palace-gold: #c8a15a;
  --palace-gold-pale: #ead6a2;
  --palace-night: #0b171a;
  --palace-jade: #1f514d;
}

/* 大屏统一使用 1600 × 900 的 16:9 设计画布。user.js 按相同尺寸等比缩放。 */
.stage { width: 1600px; height: 900px; }

/* 用户提供的俱乐部签牌：固定在顶栏下方的左上安全区，不占用内容布局。 */
.ai-club-corner-tag {
  position: absolute;
  left: 25px;
  top: 0;
  z-index: 118;
  display: block;
  width: 72px;
  height: auto;
  pointer-events: none;
  user-select: none;
  opacity: .94;
  filter: drop-shadow(0 5px 7px rgba(46, 27, 14, .24));
}

.palace-home {
  display: block;
  padding: 0;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at 50% 19%, rgba(237, 200, 126, .2), transparent 15%),
    linear-gradient(180deg, #071215 0%, #142529 46%, #281d18 100%);
  color: #f5e8c9;
  perspective: 1700px;
}

.palace-home::before {
  inset: 15px;
  border-color: rgba(223, 187, 110, .28);
  box-shadow: inset 0 0 100px rgba(0, 0, 0, .45);
  z-index: 20;
}

.palace-home::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 16;
  pointer-events: none;
  opacity: .42;
  background-image: repeating-linear-gradient(105deg, rgba(255,255,255,.025) 0 1px, transparent 1px 7px);
  mix-blend-mode: soft-light;
}

.palace-home + * { position: relative; }
.palace-home ~ .legal-note { color: rgba(238, 219, 176, .58); }

.palace-night { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.palace-night::before {
  content: '';
  position: absolute;
  width: 134px;
  height: 134px;
  top: 76px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 50%;
  background: #e1c484;
  box-shadow: 0 0 65px rgba(225, 196, 132, .3);
}
.palace-night::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 100%, transparent 0 27%, rgba(2, 9, 11, .42) 76%);
}
.palace-night span { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: #ead69b; box-shadow: 0 0 8px #ead69b; }
.palace-night span:nth-child(1) { left: 17%; top: 17%; }
.palace-night span:nth-child(2) { right: 19%; top: 22%; opacity: .75; }
.palace-night span:nth-child(3) { left: 29%; top: 31%; opacity: .45; }

.palace-silhouette {
  position: absolute;
  left: -6%;
  right: -6%;
  bottom: 0;
  height: 47%;
  z-index: 1;
  opacity: .82;
  background:
    linear-gradient(150deg, transparent 0 37%, #050b0c 37.5% 43%, transparent 43.5%) left 34% bottom 61% / 47% 31% no-repeat,
    linear-gradient(210deg, transparent 0 37%, #050b0c 37.5% 43%, transparent 43.5%) right 34% bottom 61% / 47% 31% no-repeat,
    repeating-linear-gradient(90deg, transparent 0 8.5%, #070d0e 8.5% 9.5%, transparent 9.5% 17%) center bottom / 78% 55% no-repeat,
    linear-gradient(180deg, transparent 0 48%, #070d0e 48% 100%);
  filter: drop-shadow(0 -8px 18px rgba(0,0,0,.45));
}

.home-ceremony {
  position: absolute;
  left: 104px;
  top: 144px;
  width: 430px;
  z-index: 13;
  text-shadow: 0 2px 18px rgba(0,0,0,.8);
  transition: opacity .45s ease, transform .7s ease;
}
.palace-home .home-eyebrow { margin-bottom: 25px; color: #d9c79f; }
.palace-home .live-dot { background: #d5ad5a; box-shadow: 0 0 0 4px rgba(213, 173, 90, .14), 0 0 17px rgba(213,173,90,.6); }
.home-kicker { margin-bottom: 13px; font-family: var(--font-display); color: var(--palace-gold); font-size: 18px; letter-spacing: .42em; }
.palace-home .home-title { line-height: .96; }
.palace-home .home-title-ink { font-size: 80px; color: #f5e8c9; letter-spacing: .08em; }
.palace-home .home-title-teal { margin-top: 18px; font-family: Georgia, serif; font-size: 43px; color: #d5ad5a; letter-spacing: .1em; }
.palace-home .home-subtitle { margin-top: 22px; color: rgba(244, 231, 200, .78); font-size: 18px; letter-spacing: .08em; }
.palace-home .doctor-note { margin-top: 31px; max-width: 410px; border-color: rgba(215, 180, 105, .3); padding: 17px 0; }
.palace-home .doctor-note p { color: #f4e9cf; font-size: 23px; line-height: 1.55; }
.palace-home .note-seal { color: #f0c778; border-color: #c89949; background: rgba(91, 24, 19, .5); }
.home-start-cta { display: flex; align-items: center; gap: 15px; margin-top: 31px; width: 410px; color: #f0d48f; font-family: var(--font-display); font-size: 20px; letter-spacing: .18em; }
.cta-rule { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, rgba(226,187,100,.7)); }
.cta-rule:last-child { transform: scaleX(-1); }
.palace-home .home-small { margin-top: 14px; color: rgba(233, 218, 184, .5); letter-spacing: .06em; }

.imperial-gate {
  position: absolute;
  right: 104px;
  top: 82px;
  width: 760px;
  height: 780px;
  z-index: 8;
  transform-style: preserve-3d;
  filter: drop-shadow(0 24px 35px rgba(0,0,0,.5));
}
.gate-opening {
  position: absolute;
  left: 93px;
  right: 93px;
  top: 175px;
  bottom: 78px;
  overflow: hidden;
  background: #11110c;
  border: 14px solid #351710;
  box-shadow: inset 0 0 60px #000;
}
.inner-hall {
  position: absolute;
  inset: 0;
  background: #160d09 url('/js/assets/emperor-bedchamber-v1.webp?v=20261015') center center / cover no-repeat;
  filter: saturate(.92) contrast(1.04) brightness(.82);
  transform: scale(1.015);
}
.inner-hall::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 42%, rgba(9,4,3,.48) 100%);
  box-shadow: inset 0 0 34px rgba(0,0,0,.75);
}
.gate-door {
  position: absolute;
  top: 189px;
  bottom: 92px;
  width: 278px;
  z-index: 4;
  background-color: #76231c;
  background-image:
    radial-gradient(circle, #c49a4e 0 5px, #704a20 6px 7px, transparent 8px),
    linear-gradient(90deg, rgba(255,255,255,.05), transparent 9%, rgba(0,0,0,.13) 10%, transparent 12%);
  background-size: 62px 62px, 46px 100%;
  border: 10px solid #4a190f;
  box-shadow: inset 0 0 0 3px #b17d39, inset 0 0 35px rgba(0,0,0,.45);
  transition: transform .28s cubic-bezier(.52,.05,.22,1), filter .24s ease;
  backface-visibility: hidden;
}
.gate-door::before { content: ''; position: absolute; inset: 17px; border: 2px solid rgba(211,163,77,.55); }
.gate-door-left { left: 101px; transform-origin: left center; }
.gate-door-right { right: 101px; transform-origin: right center; }
.door-ring { position: absolute; top: 49%; width: 47px; height: 47px; border: 7px solid #c69a4b; border-radius: 50%; box-shadow: 0 3px 7px rgba(0,0,0,.6); }
.gate-door-left .door-ring { right: 17px; }
.gate-door-right .door-ring { left: 17px; }
.gate-door-left .door-ring::before, .gate-door-right .door-ring::before { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; background: #d4aa59; top: -15px; left: 8px; }
.gate-beam { position: absolute; left: 19px; right: 19px; top: 70px; height: 136px; z-index: 7; background: linear-gradient(#83271e, #5d1a15); border: 9px solid #35130d; box-shadow: inset 0 -14px rgba(0,0,0,.17); }
.gate-beam::before { content: ''; position: absolute; left: -61px; right: -61px; top: -45px; height: 60px; background: #162d2a; clip-path: polygon(4% 60%, 15% 42%, 25% 45%, 32% 20%, 68% 20%, 75% 45%, 85% 42%, 96% 60%, 86% 75%, 14% 75%); border-bottom: 8px solid #b48a42; }
.gate-beam span { position: absolute; top: 35px; width: 18px; height: 52px; border-radius: 9px; background: #c29b50; box-shadow: inset 0 0 0 4px #6e4a21; }
.gate-beam span:nth-child(1) { left: 10%; }.gate-beam span:nth-child(2) { left: 30%; }.gate-beam span:nth-child(3) { left: 49%; }.gate-beam span:nth-child(4) { left: 69%; }.gate-beam span:nth-child(5) { left: 88%; }
.gate-plaque { position: absolute; top: 94px; left: 261px; width: 238px; height: 95px; z-index: 9; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #123c38; color: #e3c780; border: 5px solid #c0994e; outline: 2px solid #392614; box-shadow: 0 7px 15px rgba(0,0,0,.5); transform: rotate(-1deg); }
.gate-plaque small { font-size: 8px; letter-spacing: .22em; opacity: .7; }
.gate-plaque strong { margin-top: 6px; font-family: var(--font-display); font-size: 29px; letter-spacing: .25em; transform: translateX(.12em); }
.gate-threshold { position: absolute; left: 53px; right: 53px; bottom: 47px; height: 48px; z-index: 6; background: linear-gradient(#80674d, #2c221b); clip-path: polygon(4% 0,96% 0,100% 100%,0 100%); border-top: 5px solid #aa8b62; }

.palace-home.opening .gate-door-left { transform: rotateY(-105deg); filter: brightness(.7); }
.palace-home.opening .gate-door-right { transform: rotateY(105deg); filter: brightness(.7); }
.palace-home.opening .home-ceremony { opacity: 0; transform: translateX(-35px); }
.palace-home.opening .imperial-gate { animation: gate-enter .28s cubic-bezier(.45,.02,.2,1) both; }
.palace-home.pressed:not(.opening) .imperial-gate { transform: scale(.994); }
@keyframes gate-enter { to { transform: scale(1.08); filter: drop-shadow(0 24px 35px rgba(0,0,0,.25)) brightness(1.12); } }

/* 入宫择仪：开始游戏前必须先选择问诊身份。 */
.gender-rite {
  position: absolute;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: default;
  background:
    radial-gradient(circle at 50% 45%, rgba(112, 48, 30, .18), transparent 34%),
    rgba(3, 9, 10, .79);
  backdrop-filter: blur(5px) saturate(.8);
  animation: gender-rite-fade .24s ease-out both;
}
.gender-rite-scroll {
  position: relative;
  width: 810px;
  min-height: 490px;
  box-sizing: border-box;
  padding: 62px 82px 45px;
  overflow: hidden;
  color: #4b2b1c;
  text-align: center;
  background:
    linear-gradient(90deg, rgba(114,65,31,.15), transparent 7% 93%, rgba(114,65,31,.15)),
    repeating-linear-gradient(0deg, rgba(91,56,27,.025) 0 1px, transparent 1px 6px),
    #e8d29d;
  border: 2px solid #b28a45;
  box-shadow:
    0 30px 80px rgba(0,0,0,.68),
    inset 0 0 0 9px rgba(104,47,25,.1),
    inset 0 0 70px rgba(111,66,29,.18);
  clip-path: polygon(3% 0, 97% 0, 100% 4%, 98.5% 50%, 100% 96%, 97% 100%, 3% 100%, 0 96%, 1.5% 50%, 0 4%);
  animation: gender-scroll-enter .38s cubic-bezier(.2,.78,.24,1) both;
}
.gender-rite-scroll::before,
.gender-rite-scroll::after {
  content: '';
  position: absolute;
  left: 34px;
  right: 34px;
  height: 12px;
  border-top: 2px solid #9e3426;
  border-bottom: 1px solid rgba(126,73,31,.55);
}
.gender-rite-scroll::before { top: 24px; }
.gender-rite-scroll::after { bottom: 24px; }
.gender-rite-kicker {
  margin: 0 0 13px;
  color: #8d3528;
  font-family: 'ImperialGold', STKaiti, KaiTi, serif;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: .42em;
}
.gender-rite h2 {
  margin: 0;
  color: #332419;
  font-family: 'ImperialGold', STKaiti, KaiTi, serif;
  font-size: 42px;
  font-weight: 700;
  letter-spacing: .18em;
  text-shadow: 0 1px rgba(255,244,201,.75);
}
.gender-rite-copy {
  margin: 13px 0 31px;
  color: #735337;
  font-family: STKaiti, KaiTi, serif;
  font-size: 19px;
  letter-spacing: .09em;
}
.gender-rite-options {
  display: grid;
  grid-template-columns: 1fr 48px 1fr;
  align-items: center;
  gap: 13px;
}
.gender-rite-option {
  position: relative;
  display: grid;
  grid-template-columns: 62px 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  min-height: 142px;
  padding: 20px 24px;
  color: #f2d98f;
  font-family: 'ImperialGold', STKaiti, KaiTi, serif;
  text-align: left;
  background:
    linear-gradient(135deg, rgba(255,220,133,.13), transparent 34%),
    #6f231d;
  border: 2px solid #a67937;
  outline: 1px solid rgba(94,35,23,.62);
  outline-offset: 5px;
  box-shadow: inset 0 0 25px rgba(28,8,5,.42), 0 10px 18px rgba(75,36,17,.22);
  cursor: pointer;
  transition: transform .18s ease, filter .18s ease, box-shadow .18s ease;
}
.gender-rite-option:hover,
.gender-rite-option:focus-visible {
  transform: translateY(-4px);
  filter: brightness(1.12);
  box-shadow: inset 0 0 25px rgba(28,8,5,.32), 0 15px 25px rgba(75,36,17,.3), 0 0 0 3px rgba(215,173,84,.22);
}
.gender-rite-option:active { transform: translateY(0) scale(.985); }
.gender-rite-mark {
  grid-row: 1 / 3;
  display: flex;
  width: 52px;
  height: 52px;
  align-items: center;
  justify-content: center;
  color: #f4dd9e;
  font-size: 31px;
  background: #8e3025;
  border: 2px solid #ca9d4d;
  box-shadow: inset 0 0 0 3px #702019;
  transform: rotate(-2deg);
}
.gender-rite-option strong {
  align-self: end;
  font-size: 33px;
  font-weight: 700;
  letter-spacing: .2em;
}
.gender-rite-option small {
  align-self: start;
  margin-top: 6px;
  color: rgba(244,222,163,.76);
  font-family: STKaiti, KaiTi, serif;
  font-size: 16px;
  letter-spacing: .35em;
}
.gender-rite-divider {
  display: flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  color: #efe0b1;
  font-family: 'ImperialGold', STKaiti, KaiTi, serif;
  font-size: 20px;
  background: #913429;
  border: 2px solid #a97836;
  box-shadow: inset 0 0 0 2px #e0b960;
  transform: rotate(45deg);
}
.gender-rite-divider::first-letter { transform: rotate(-45deg); }
.gender-rite-note {
  margin: 28px 0 0;
  color: #8d3528;
  font-family: 'ImperialGold', STKaiti, KaiTi, serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .3em;
}
.gender-rite-cloud { position: absolute; width: 130px; height: 46px; opacity: .18; border: 3px solid #7f3828; border-radius: 50%; }
.gender-rite-cloud-left { left: -34px; top: 72px; }
.gender-rite-cloud-right { right: -38px; bottom: 63px; }
@keyframes gender-rite-fade { from { opacity: 0; } }
@keyframes gender-scroll-enter { from { opacity: 0; transform: translateY(18px) scale(.96); } }

/* 御前问诊：保留人体命中区，仅重构空间与层级。 */
.page-part {
  padding: 126px 70px 54px;
  background:
    linear-gradient(90deg, rgba(49,19,14,.96) 0 4.5%, transparent 4.5% 95.5%, rgba(49,19,14,.96) 95.5%),
    linear-gradient(180deg, rgba(22,67,61,.92) 0 15%, rgba(239,226,194,.97) 15% 100%);
}
.part-exam-shell {
  display: flex;
  flex: 1;
  min-height: 0;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateY(24px) scale(.965);
  transition: opacity .58s ease .22s, transform .72s cubic-bezier(.2,.75,.2,1) .18s;
}
.part-exam-shell.visible { opacity: 1; pointer-events: auto; transform: none; }
.part-cinematic {
  position: absolute;
  inset: 0;
  z-index: 30;
  overflow: hidden;
  color: #f6e5bd;
  background: #160c08;
}
.part-cinematic-trigger {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
  font-family: var(--font-copy);
  text-align: left;
}
.part-cinematic-trigger:focus-visible { outline: 4px solid #d9b66a; outline-offset: -12px; }
.part-cinematic-scene,
.part-cinematic-vignette {
  position: absolute;
  inset: 0;
  display: block;
}
.part-cinematic-scene {
  background: #1b0d09 url('/js/assets/han-emperor-throne-intro-v1.webp?v=20261015') center / cover no-repeat;
}
.page-part.gender-female .part-cinematic-scene {
  background-image: url('/js/assets/han-empress-throne-intro-v1.webp?v=20261016-empress-v1');
}
.part-cinematic-scene {
  transition: opacity .82s ease, transform 1.05s cubic-bezier(.2,.72,.18,1), filter .82s ease;
}
.part-cinematic-vignette {
  z-index: 3;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(10,4,3,.28), transparent 30% 65%, rgba(8,3,2,.72)),
    linear-gradient(90deg, rgba(7,3,2,.7), transparent 27% 73%, rgba(7,3,2,.7));
  box-shadow: inset 0 0 110px rgba(0,0,0,.55);
  transition: opacity .72s ease;
}
.part-cinematic-copy {
  position: absolute;
  left: 88px;
  bottom: 68px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-shadow: 0 3px 20px #000;
  transition: opacity .4s ease, transform .58s ease;
}
.part-cinematic-copy small { color: #d4ad61; font-size: 15px; letter-spacing: .34em; }
.part-cinematic-copy strong { margin-top: 11px; font-family: var(--font-display); font-size: 43px; font-weight: 600; letter-spacing: .12em; }
.part-cinematic-copy em { margin-top: 15px; padding: 9px 17px; border: 1px solid rgba(220,180,100,.65); color: #efd59b; background: rgba(48,21,14,.62); font-size: 17px; font-style: normal; letter-spacing: .14em; }
.part-cinematic-pulse {
  position: absolute;
  left: 50%;
  top: 49%;
  z-index: 4;
  width: 350px;
  height: 690px;
  border: 1px solid rgba(227,189,109,.38);
  transform: translate(-50%,-50%);
  box-shadow: 0 0 0 0 rgba(220,179,94,.18), inset 0 0 50px rgba(222,181,95,.06);
  animation: emperor-invite 2.15s ease-in-out infinite;
  pointer-events: none;
}
.part-cinematic.is-transforming .part-cinematic-scene { opacity: 0; transform: scale(1.035); filter: blur(3px) brightness(1.18); }
.part-cinematic.is-transforming .part-cinematic-vignette { opacity: 0; }
.part-cinematic.is-transforming .part-cinematic-copy { opacity: 0; transform: translateY(18px); }
.part-cinematic.is-transforming .part-cinematic-pulse { animation: none; opacity: 0; }
@keyframes emperor-invite {
  0%,100% { opacity: .42; box-shadow: 0 0 0 0 rgba(220,179,94,.18); }
  50% { opacity: .9; box-shadow: 0 0 0 18px rgba(220,179,94,0); }
}
.part-exam-shell.visible .painted-body-image { animation: sleep-robe-arrive .72s cubic-bezier(.22,.78,.2,1) .18s both; }
@keyframes sleep-robe-arrive {
  from { opacity: 0; transform: translateY(-8px) scale(.94); filter: brightness(1.65) sepia(.25); }
  to { opacity: 1; transform: none; filter: none; }
}
.page-part::before {
  content: '';
  position: absolute;
  inset: 94px 24px 25px;
  z-index: -1;
  border: 1px solid rgba(190,148,73,.5);
  background:
    linear-gradient(90deg, transparent 0 7%, rgba(115,38,27,.13) 7% 8%, transparent 8% 92%, rgba(115,38,27,.13) 92% 93%, transparent 93%),
    repeating-linear-gradient(90deg, transparent 0 118px, rgba(124,31,28,.055) 118px 120px);
  box-shadow: inset 0 0 65px rgba(85,45,23,.12);
}
.court-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 35px; }
.court-kicker { margin-bottom: 7px; color: var(--palace-red); font-family: var(--font-display); font-size: 15px; letter-spacing: .25em; }
.page-part .page-title { color: #203c35; font-size: 36px; }
.page-part .page-intro { color: #74644f; font-size: 16px; }
.court-progress { display: flex; align-items: center; gap: 8px; min-width: 600px; padding: 15px 20px; color: #897a63; border-top: 1px solid #cbb783; border-bottom: 1px solid #cbb783; font-size: 13px; letter-spacing: .08em; white-space: nowrap; }
.court-progress i { flex: 1; min-width: 20px; height: 1px; background: #c9b98f; }
.court-progress span { position: relative; }
.court-progress .done, .court-progress .active { color: var(--palace-red); }
.court-progress .active { font-weight: 700; }
.court-progress .active::before { content: ''; position: absolute; width: 6px; height: 6px; left: 50%; top: -17px; transform: rotate(45deg); background: #a43b2e; }
.page-part .part-layout { gap: 35px; margin-top: 18px; }
.page-part .part-card { width: 930px; position: relative; padding: 16px 34px 12px; background: rgba(255,250,236,.92); border-color: #bda36c; box-shadow: 0 18px 42px rgba(48,31,17,.16), inset 0 0 0 5px rgba(190,158,91,.08); }
.page-part .part-card::before, .page-part .part-card::after { content: ''; position: absolute; width: 34px; height: 34px; border-color: #a47a3d; border-style: solid; opacity: .7; }
.page-part .part-card::before { left: 11px; top: 11px; border-width: 2px 0 0 2px; }
.page-part .part-card::after { right: 11px; bottom: 11px; border-width: 0 2px 2px 0; }
.page-part .seg-control { z-index: 2; background: #e5d6b8; border-color: #c5a86f; }
.page-part .seg-btn.active { background: #723025; }
.page-part .part-figure-wrap .body-figure { height: 452px; }
.page-part .part-side { position: relative; padding: 30px 30px 25px; justify-content: center; background: rgba(46,74,64,.93); color: #f4e8cb; border: 1px solid #a88a51; box-shadow: 0 18px 42px rgba(30,22,14,.2); }
.page-part .part-side::before { content: '御\A医\A案'; white-space: pre; position: absolute; top: 22px; right: 21px; color: rgba(222,190,119,.28); font-family: var(--font-display); font-size: 31px; line-height: 1.2; }
.page-part .side-label { color: #d9bd81; }
.page-part .side-part { color: #fff1d2; }
.page-part .side-note { color: rgba(245,233,206,.72); }
.page-part .side-divider { background: rgba(218,190,132,.35); }
.page-part .side-tip { color: rgba(238,221,185,.55); }
.page-part .btn-primary { background: #9a3b2d; border-color: #d0a256; }
.page-part .btn-primary:disabled { background: rgba(231,219,191,.18); color: rgba(239,224,193,.45); border-color: rgba(208,162,86,.25); }

/* 轻量古医书人物：替代 2.1MB 写实 PNG，同时保留原轮廓与点击热区。 */
.ancient-body-base {
  fill: #e7c77d;
  stroke: #6f3325;
  stroke-width: 2.2;
  stroke-linejoin: round;
  filter: drop-shadow(0 5px 5px rgba(78,45,22,.18));
}
.painted-body-image { pointer-events: none; }
.body-figure .ancient-body-base, .body-figure .ancient-art { display: none; }
.ancient-art { stroke-linecap: round; stroke-linejoin: round; }
.ancient-hair, .ancient-topknot { fill: #28251f; stroke: #6b3427; stroke-width: 1.4; }
.ancient-topknot { fill: #254f4b; }
.ancient-feature, .ancient-detail { fill: none; stroke: #71382a; stroke-width: 2; }
.ancient-beard { fill: #33261e; stroke: #71382a; stroke-width: 1.3; }
.ancient-sash { fill: #245b55; stroke: #6c3327; stroke-width: 2.2; }
.ancient-sash-knot { fill: #a64032; stroke: #6c3327; stroke-width: 2; }
.ancient-meridian { fill: none; stroke: #a54131; stroke-width: 1.75; opacity: .92; }
.ancient-points { fill: #7c1f1c; stroke: #f0d597; stroke-width: .6; }
.page-part .body-figure .outline { opacity: 0; }
.page-part .body-figure .regions path.clickable:hover { fill: rgba(164,61,46,.19); }
.page-part .body-figure .leader-line { stroke: #9d6f43; stroke-width: 1.35; }
.page-part .body-figure .leader-anchor { fill: #8b3429; stroke: #f4deb0; stroke-width: 1.25; }
.page-part .body-figure .leader-pill { fill: #f4e5bf; stroke: #a77d48; }
.page-part .body-figure .leader-text { fill: #643a29; font-family: var(--font-display); }

.stage:has(.palace-home) .topbar { color: #f3e4c4; }
.stage:has(.palace-home) .app-logo { opacity: 0; }
.stage:has(.palace-home) .edition-mark { color: rgba(238,218,175,.65); }
.stage:has(.page-part) .topbar { color: #f4e7c9; }
.stage:has(.page-part) .brand-signature span { color: rgba(245,231,197,.62); }
.stage:has(.page-part) .progress-pill { color: #eed9a8; border-color: rgba(222,188,112,.45); }
.stage:has(.page-part) .app-logo-svg { box-shadow: 0 0 0 1px rgba(231,199,131,.35); }
.stage:has(.page-part) .legal-note { color: #8c7a5f; }

/* 全流程统一为五代工笔重彩与绢本宫廷视觉。 */
.stage:not(:has(.palace-home)) {
  background-color: #dfc99c;
  background-image:
    linear-gradient(90deg, rgba(99,35,27,.92) 0 25px, transparent 25px calc(100% - 25px), rgba(99,35,27,.92) calc(100% - 25px)),
    radial-gradient(ellipse at 50% 34%, rgba(255,249,224,.78), rgba(218,190,137,.54) 72%),
    repeating-linear-gradient(94deg, rgba(92,61,34,.035) 0 1px, transparent 1px 7px);
}
.stage:not(:has(.palace-home))::before { inset: 16px; border-color: rgba(109,54,33,.5); box-shadow: inset 0 0 0 4px rgba(203,161,82,.13); }
.stage:not(:has(.palace-home)) .topbar {
  height: 102px;
  padding-top: 18px;
  color: #f1dfb6;
  background: linear-gradient(180deg, #173f3b 0, #214c46 76%, #bf9851 77%, #6f251e 82%, transparent 83%);
}
.stage:not(:has(.palace-home)) .brand-signature { color: #f1dfb6; }
.stage:not(:has(.palace-home)) .brand-signature span { color: rgba(242,222,178,.62); }
.stage:not(:has(.palace-home)) .progress-pill { color: #efd7a3; border-color: rgba(222,185,105,.55); background: rgba(42,31,20,.16); }
.stage:not(:has(.palace-home)) .page:not(.page-part):not(.page-buff) {
  background:
    linear-gradient(90deg, rgba(117,42,31,.09), transparent 10% 90%, rgba(117,42,31,.09)),
    repeating-linear-gradient(0deg, transparent 0 47px, rgba(112,75,37,.026) 47px 48px);
}
.stage:not(:has(.palace-home)) .page-title { color: #243f37; text-shadow: 0 1px rgba(255,249,225,.7); }
.stage:not(:has(.palace-home)) .page-intro { color: #735b40; }
.stage:not(:has(.palace-home)) .tag-chip { background: #e7d2a5; border-color: #b58c4c; color: #65382a; }
.stage:not(:has(.palace-home)) .btn-primary { background: #91372b; border-color: #bb8e46; color: #fff0ce; }
.stage:not(:has(.palace-home)) .btn-primary:not(:disabled):hover { background: #76271f; }
.stage:not(:has(.palace-home)) .opt-chip,
.stage:not(:has(.palace-home)) .btn-option,
.stage:not(:has(.palace-home)) .summary-card,
.stage:not(:has(.palace-home)) .qr-paper,
.stage:not(:has(.palace-home)) .report-summary,
.stage:not(:has(.palace-home)) .report-detail-card,
.stage:not(:has(.palace-home)) .report-taskbar,
.stage:not(:has(.palace-home)) .scan-card {
  background-color: rgba(246,230,193,.9);
  border-color: #b69254;
  box-shadow: 7px 9px 0 rgba(101,59,29,.1), inset 0 0 0 3px rgba(255,248,222,.22);
}
.stage:not(:has(.palace-home)) .opt-chip.selected,
.stage:not(:has(.palace-home)) .btn-option.selected { background: #ddc396; border-color: #8d3328; color: #7b281f; }
.stage:not(:has(.palace-home)) .quiz-progress { background: #cbb58a; }
.stage:not(:has(.palace-home)) .quiz-progress-fill { background: #8e3429; }
.stage:not(:has(.palace-home)) .summary-table th { color: #876b48; border-color: #c6a972; }
.stage:not(:has(.palace-home)) .summary-table td { color: #3f4537; border-color: #ccb17d; }
.stage:not(:has(.palace-home)) .report-suggestions.list .sug-slot { background: rgba(41,82,73,.1); border-left-color: #7b3027; }
.stage:not(:has(.palace-home)) .source-chip { background: #d9c69b; color: #4f5d43; }
.stage:not(:has(.palace-home)) .countdown-wrap::before { border-color: #9f7541; }
.stage:not(:has(.palace-home)) .ring-bg { stroke: #cbb58b; }
.stage:not(:has(.palace-home)) .ring-fg { stroke: #8f352a; }
.page-buff { background: radial-gradient(ellipse at 50% 38%, #f7e8bd 0, #d8bc7f 62%, #b18b4e 100%); }
.page-buff.glow { background: radial-gradient(ellipse at 50% 38%, #fff0c7, #d7b873 66%, #9c7139); }
.page-buff::before { content: ''; position: absolute; inset: 34px; border: 1px solid rgba(104,47,28,.42); box-shadow: inset 0 0 0 5px rgba(126,45,34,.08); pointer-events: none; }

/* 全流程纯手绘国风：绢本底、墨线框、朱砂印与卷轴式控件。 */
.stage:not(:has(.palace-home)) {
  color: #342a20;
  background-color: #d9bd84;
  background-image:
    radial-gradient(ellipse at 18% 12%, rgba(255,248,213,.52), transparent 31%),
    radial-gradient(ellipse at 83% 78%, rgba(105,67,36,.13), transparent 38%),
    repeating-linear-gradient(96deg, rgba(68,45,26,.035) 0 1px, transparent 1px 8px),
    repeating-linear-gradient(7deg, transparent 0 13px, rgba(255,248,214,.045) 13px 14px);
  font-family: STKaiti, KaiTi, FangSong, serif;
}
.stage:not(:has(.palace-home))::before {
  inset: 14px;
  border: 2px solid rgba(76,43,27,.54);
  outline: 1px solid rgba(154,103,53,.42);
  outline-offset: -7px;
  box-shadow: inset 0 0 70px rgba(62,38,22,.18);
}
.stage:not(:has(.palace-home)) .topbar {
  color: #ead8ac;
  background:
    repeating-linear-gradient(94deg, rgba(255,255,255,.025) 0 1px, transparent 1px 9px),
    linear-gradient(180deg, rgba(25,61,54,.98) 0 73%, rgba(92,39,29,.96) 74% 82%, transparent 83%);
  filter: saturate(.82);
}
.stage:not(:has(.palace-home)) .topbar::after {
  content: '';
  position: absolute;
  left: 48px;
  right: 48px;
  bottom: 14px;
  height: 2px;
  opacity: .62;
  background: linear-gradient(90deg, transparent, #c9a45e 9% 91%, transparent);
}
.stage:not(:has(.palace-home)) .progress-pill,
.stage:not(:has(.palace-home)) .tag-chip,
.stage:not(:has(.palace-home)) .source-chip {
  border-radius: 1px;
  font-family: STKaiti, KaiTi, serif;
  box-shadow: inset 0 0 0 2px rgba(255,244,207,.16);
}
.stage:not(:has(.palace-home)) .progress-pill {
  color: #f0d697;
  border: 1px solid #c79b50;
  background: rgba(71,27,22,.46);
  transform: rotate(-1deg);
}
.stage:not(:has(.palace-home)) .page-title {
  position: relative;
  color: #243932;
  font-family: STKaiti, KaiTi, serif;
  font-weight: 700;
  letter-spacing: .09em;
  text-shadow: 1px 1px rgba(255,247,214,.72);
}
.stage:not(:has(.palace-home)) .page-title::after {
  content: '';
  display: block;
  width: 84px;
  height: 5px;
  margin-top: 7px;
  opacity: .65;
  background: linear-gradient(90deg, #75291f, rgba(117,41,31,.15), transparent);
  clip-path: polygon(0 35%, 92% 0, 100% 48%, 87% 74%, 4% 100%);
}
.stage:not(:has(.palace-home)) .page-intro,
.stage:not(:has(.palace-home)) .page-desc { color: #69523a; font-family: FangSong, STKaiti, serif; }
.stage:not(:has(.palace-home)) .tag-chip {
  color: #722b23;
  border: 1px solid rgba(125,48,35,.72);
  background: rgba(225,197,143,.74);
  transform: rotate(.35deg);
}
.stage:not(:has(.palace-home)) .btn,
.stage:not(:has(.palace-home)) .opt-chip,
.stage:not(:has(.palace-home)) .seg-btn {
  border-radius: 1px;
  font-family: STKaiti, KaiTi, serif;
  letter-spacing: .06em;
}
.stage:not(:has(.palace-home)) .btn-primary {
  color: #f5e5bd;
  border: 1px solid #713025;
  outline: 1px solid rgba(187,141,72,.62);
  outline-offset: -5px;
  background:
    repeating-linear-gradient(96deg, rgba(255,255,255,.025) 0 1px, transparent 1px 7px),
    #87362b;
  box-shadow: 3px 4px 0 rgba(79,40,24,.18);
  clip-path: polygon(1% 3%, 99% 0, 100% 94%, 97% 100%, 2% 98%, 0 8%);
}
.stage:not(:has(.palace-home)) .btn-primary:not(:disabled):hover { background-color: #6f281f; filter: saturate(.88); }
.stage:not(:has(.palace-home)) .btn-primary:disabled { opacity: .48; filter: grayscale(.35); }
.stage:not(:has(.palace-home)) .opt-chip,
.stage:not(:has(.palace-home)) .btn-option,
.stage:not(:has(.palace-home)) .summary-card,
.stage:not(:has(.palace-home)) .qr-paper,
.stage:not(:has(.palace-home)) .report-summary,
.stage:not(:has(.palace-home)) .report-detail-card,
.stage:not(:has(.palace-home)) .report-taskbar,
.stage:not(:has(.palace-home)) .scan-card,
.stage:not(:has(.palace-home)) .queue-panel {
  border-radius: 0;
  border: 1px solid rgba(116,78,42,.72);
  outline: 1px solid rgba(255,246,211,.48);
  outline-offset: -7px;
  background-color: rgba(239,218,173,.93);
  background-image:
    repeating-linear-gradient(97deg, rgba(81,56,32,.035) 0 1px, transparent 1px 8px),
    radial-gradient(ellipse at 28% 15%, rgba(255,250,224,.5), transparent 48%);
  box-shadow: 8px 10px 0 rgba(80,47,27,.09), inset 0 0 30px rgba(112,75,37,.07);
  clip-path: polygon(.4% 1%, 99.5% 0, 100% 98.7%, 98.8% 100%, .2% 99.2%, 0 2%);
}
.stage:not(:has(.palace-home)) .opt-chip.selected,
.stage:not(:has(.palace-home)) .btn-option.selected {
  color: #70261f;
  border-color: #873127;
  background-color: #dbc08c;
  box-shadow: inset 5px 0 0 #8b3428, 6px 8px 0 rgba(80,47,27,.09);
}
.stage:not(:has(.palace-home)) .edit-link {
  color: #792c23;
  font-family: STKaiti, KaiTi, serif;
  text-decoration: none;
  border-bottom: 1px solid rgba(121,44,35,.62);
}
.stage:not(:has(.palace-home)) .quiz-progress {
  height: 7px;
  border: 1px solid rgba(84,56,31,.35);
  background: rgba(93,67,41,.16);
  clip-path: polygon(0 28%, 100% 0, 99.6% 82%, .2% 100%);
}
.stage:not(:has(.palace-home)) .quiz-progress-fill { background: #7d2c23; box-shadow: 0 0 5px rgba(91,36,28,.22); }
.stage:not(:has(.palace-home)) .summary-table th,
.stage:not(:has(.palace-home)) .summary-table td { border-color: rgba(125,88,49,.38); }
.stage:not(:has(.palace-home)) .summary-table tr:nth-child(even) td { background: rgba(128,84,42,.035); }
.stage:not(:has(.palace-home)) .report-suggestions.list .sug-slot {
  border: 0;
  border-left: 5px solid #773025;
  background: rgba(43,75,61,.075);
  box-shadow: none;
}
.stage:not(:has(.palace-home)) .sug-num,
.stage:not(:has(.palace-home)) .paper-eyebrow,
.stage:not(:has(.palace-home)) .reading-caption,
.stage:not(:has(.palace-home)) .task-meta { color: #7d3027; font-family: STKaiti, KaiTi, serif; }
.stage:not(:has(.palace-home)) .pairing-code { color: #263e35; font-family: STKaiti, KaiTi, serif; letter-spacing: .22em; }
.stage:not(:has(.palace-home)) .countdown-wrap::before { border: 1px solid rgba(118,75,38,.58); box-shadow: inset 0 0 35px rgba(100,63,32,.1); }
.stage:not(:has(.palace-home)) .ring-bg { stroke: rgba(115,84,48,.24); }
.stage:not(:has(.palace-home)) .ring-fg { stroke: #793128; stroke-linecap: butt; }
.stage:not(:has(.palace-home)) .countdown-number { color: #273d35; font-family: STKaiti, KaiTi, serif; }
.stage:not(:has(.palace-home)) .scan-line { opacity: .58; background: linear-gradient(90deg, transparent, #7a3026 18% 82%, transparent); box-shadow: none; }
.page-part .seg-control { border-radius: 0; background: rgba(208,181,129,.62); }
.page-part .seg-btn.active { background: #773026; outline: 1px solid #bc914c; outline-offset: -4px; }
.page-part .part-card { background-image: repeating-linear-gradient(96deg, rgba(78,49,25,.028) 0 1px, transparent 1px 8px); }
.page-part .part-side {
  border-radius: 0;
  background:
    repeating-linear-gradient(95deg, rgba(255,255,255,.025) 0 1px, transparent 1px 8px),
    rgba(38,69,58,.95);
  outline: 1px solid rgba(210,175,102,.42);
  outline-offset: -8px;
  clip-path: polygon(1% 0, 99% 1%, 100% 98%, 97% 100%, 0 99%, .5% 3%);
}
.page-buff,
.page-buff.glow {
  background-color: #dbc18b;
  background-image:
    radial-gradient(ellipse at 50% 36%, rgba(255,246,208,.68), transparent 52%),
    repeating-linear-gradient(96deg, rgba(73,49,27,.036) 0 1px, transparent 1px 8px);
}

/* 辨部位页 v11：寝宫全景 + 独立绢本诊案，修正标题、进度和左右栏排版。 */
.page-part:not(.part-intro-active) {
  padding: 116px 48px 42px;
  isolation: isolate;
  background:
    linear-gradient(180deg, rgba(25,12,8,.26), rgba(25,12,8,.48)),
    url('/js/assets/emperor-bedchamber-v1.webp?v=20261015') center 44% / cover no-repeat;
}
.page-part:not(.part-intro-active)::before {
  display: block;
  inset: 104px 32px 27px;
  z-index: -1;
  border: 1px solid rgba(224,188,114,.54);
  background: transparent;
  box-shadow: inset 0 0 70px rgba(0,0,0,.24), 0 0 0 7px rgba(51,24,15,.18);
}
.page-part:not(.part-intro-active) .part-exam-shell {
  position: relative;
  padding: 24px 30px 20px;
  overflow: hidden;
  border: 1px solid rgba(118,74,38,.78);
  outline: 1px solid rgba(255,244,204,.55);
  outline-offset: -8px;
  background:
    repeating-linear-gradient(97deg, rgba(88,57,30,.025) 0 1px, transparent 1px 9px),
    rgba(239,220,178,.91);
  box-shadow: 0 18px 55px rgba(20,8,5,.36), inset 0 0 38px rgba(92,54,27,.09);
  clip-path: polygon(.25% .6%, 99.7% 0, 100% 99%, 99.2% 100%, .1% 99.4%, 0 1.2%);
}
.page-part:not(.part-intro-active) .part-exam-shell::before {
  content: '';
  position: absolute;
  right: -16px;
  bottom: -28px;
  width: 490px;
  height: 285px;
  z-index: 0;
  opacity: .075;
  background: url('/js/assets/emperor-bedchamber-v1.webp?v=20261015') center / cover no-repeat;
  filter: sepia(.5) saturate(.7);
  pointer-events: none;
  mask-image: linear-gradient(135deg, transparent 5%, #000 48%, #000 100%);
}
.page-part:not(.part-intro-active) .part-exam-shell > * { position: relative; z-index: 1; }
.page-part:not(.part-intro-active) .court-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 610px;
  align-items: end;
  gap: 34px;
  min-height: 104px;
  padding: 0 8px 16px;
  border-bottom: 1px solid rgba(129,86,45,.38);
}
.page-part:not(.part-intro-active) .court-kicker {
  margin: 0 0 6px;
  color: #7a2c23;
  font-size: 13px;
  line-height: 1.35;
  letter-spacing: .28em;
}
.page-part:not(.part-intro-active) .page-title {
  margin: 0;
  color: #233c34;
  font-size: 32px;
  line-height: 1.24;
  letter-spacing: .07em;
  white-space: nowrap;
}
.page-part:not(.part-intro-active) .page-title::after { width: 66px; height: 4px; margin-top: 5px; }
.page-part:not(.part-intro-active) .page-intro {
  margin-top: 7px;
  color: #6d573e;
  font-size: 14px;
  line-height: 1.45;
  letter-spacing: .03em;
}
.page-part:not(.part-intro-active) .court-progress {
  width: 100%;
  min-width: 0;
  height: 48px;
  margin: 0 0 4px;
  padding: 11px 16px;
  gap: 8px;
  color: #7e6a4f;
  border-color: rgba(155,112,59,.44);
  font-size: 12px;
  line-height: 1;
  letter-spacing: .04em;
}
.page-part:not(.part-intro-active) .court-progress i { min-width: 22px; background: rgba(151,113,67,.45); }
.page-part:not(.part-intro-active) .court-progress .active::before { top: -15px; }
.page-part:not(.part-intro-active) .part-layout {
  display: grid;
  grid-template-columns: 860px minmax(0, 1fr);
  flex: 1;
  min-height: 0;
  gap: 28px;
  margin-top: 15px;
}
.page-part:not(.part-intro-active) .part-card {
  width: auto;
  min-width: 0;
  padding: 14px 28px 10px;
  border-color: rgba(146,104,56,.66);
  background-color: rgba(250,241,216,.88);
  box-shadow: 6px 8px 0 rgba(70,39,22,.1), inset 0 0 0 4px rgba(164,118,58,.07);
}
.page-part:not(.part-intro-active) .seg-control { margin-top: 0; }
.page-part:not(.part-intro-active) .seg-btn { min-width: 150px; padding: 8px 44px; font-size: 16px; }
.page-part:not(.part-intro-active) .part-figure-wrap { padding-top: 5px; }
.page-part:not(.part-intro-active) .part-figure-wrap .body-figure { height: 470px; }
.page-part:not(.part-intro-active) .part-side {
  min-width: 0;
  padding: 54px 42px 34px;
  justify-content: center;
  background:
    linear-gradient(90deg, rgba(105,41,30,.2) 0 2px, transparent 2px calc(25% - 1px), rgba(111,65,33,.13) 25%, transparent calc(25% + 1px) calc(50% - 1px), rgba(111,65,33,.13) 50%, transparent calc(50% + 1px) calc(75% - 1px), rgba(111,65,33,.13) 75%, transparent calc(75% + 1px)),
    repeating-linear-gradient(96deg, rgba(87,54,27,.035) 0 1px, transparent 1px 9px),
    linear-gradient(135deg, #f2dfaa 0%, #e8c981 48%, #f0d99d 100%);
  color: #4b3020;
  border: 0;
  border-left: 10px solid #7b2b22;
  border-right: 10px solid #7b2b22;
  outline: 1px solid rgba(255,239,185,.76);
  outline-offset: -17px;
  box-shadow:
    10px 12px 0 rgba(49,24,15,.2),
    0 20px 34px rgba(34,16,10,.23),
    inset 15px 0 22px rgba(91,47,22,.08),
    inset -15px 0 22px rgba(91,47,22,.08);
  clip-path: polygon(2% 0, 96% 1%, 100% 5%, 99% 94%, 94% 100%, 5% 99%, 0 95%, 1% 5%);
}
.page-part:not(.part-intro-active) .part-side::before {
  content: '御前诊奏';
  top: 26px;
  right: 27px;
  width: 42px;
  padding: 13px 4px 12px;
  color: #ead497;
  background: #782b22;
  border: 1px solid #b98745;
  box-shadow: inset 0 0 0 3px rgba(255,224,145,.1), 3px 4px 0 rgba(76,35,21,.16);
  font-size: 20px;
  line-height: 1.08;
  letter-spacing: .09em;
  text-align: center;
  writing-mode: vertical-rl;
  white-space: normal;
  opacity: 1;
}
.page-part:not(.part-intro-active) .part-side::after {
  content: '御\A医';
  white-space: pre;
  position: absolute;
  right: 35px;
  bottom: 92px;
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  color: rgba(255,232,188,.9);
  background: rgba(139,40,31,.84);
  border: 2px solid rgba(121,34,26,.9);
  outline: 1px solid rgba(139,40,31,.55);
  outline-offset: 3px;
  font-family: var(--font-display);
  font-size: 16px;
  line-height: 1.05;
  text-align: center;
  transform: rotate(-7deg);
  opacity: .9;
}
.page-part:not(.part-intro-active) .side-label {
  margin: 0;
  color: #7b2c23;
  font-family: var(--font-display);
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: .2em;
}
.page-part:not(.part-intro-active) .side-part {
  min-height: 58px;
  margin-top: 13px;
  color: #243f35;
  font-family: var(--font-display);
  font-size: 42px;
  line-height: 1.25;
  text-shadow: 0 1px rgba(255,248,219,.6);
}
.page-part:not(.part-intro-active) .side-note {
  margin-top: 15px;
  color: #6e5030;
  font-size: 17px;
  line-height: 1.72;
}
.page-part:not(.part-intro-active) .side-divider {
  width: calc(100% - 8px);
  height: 1px;
  margin: 22px 0;
  background: linear-gradient(90deg, #8c3429, rgba(140,52,41,.15));
}
.page-part:not(.part-intro-active) .btn-block {
  min-height: 58px;
  padding: 13px 22px;
  color: #f7e8bc;
  background: #7a2d24;
  border-color: #b87f3c;
  box-shadow: inset 0 0 0 3px rgba(236,204,127,.1), 4px 5px 0 rgba(87,45,25,.16);
  font-size: 20px;
}
.page-part:not(.part-intro-active) .btn-block:disabled {
  color: rgba(78,52,31,.5);
  background: rgba(126,83,43,.12);
  border-color: rgba(124,76,36,.3);
  box-shadow: none;
}
.page-part:not(.part-intro-active) .side-tip {
  margin-top: 13px;
  padding-right: 62px;
  color: rgba(91,61,34,.72);
  font-size: 12px;
}

/* 辨部位页 v13：鎏金大字与均衡排版。 */
.stage:has(.page-part:not(.part-intro-active)) {
  --font-display: 'ImperialGold', 'Noto Serif CJK SC', STKaiti, KaiTi, serif;
  --font-copy: 'ImperialGold', 'Noto Serif CJK SC', STKaiti, KaiTi, serif;
}
.stage:has(.page-part:not(.part-intro-active)) .brand-signature {
  color: #f2d58d;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: .1em;
  text-shadow: 0 1px #6e3b1d, 0 0 10px rgba(245,205,105,.22);
}
.stage:has(.page-part:not(.part-intro-active)) .brand-signature span {
  margin-top: 4px;
  color: #cfad68;
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: .18em;
}
.stage:has(.page-part:not(.part-intro-active)) .progress-pill {
  min-width: 138px;
  padding: 12px 22px;
  color: #f2d58d;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .14em;
  text-align: center;
  text-shadow: 0 1px #5f321c;
}
.page-part:not(.part-intro-active) .court-heading {
  grid-template-columns: minmax(0, 1fr) 650px;
  min-height: 116px;
  padding: 0 10px 18px;
  gap: 42px;
}
.page-part:not(.part-intro-active) .court-kicker {
  margin-bottom: 8px;
  color: #8b3327;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: .3em;
  text-shadow: 0 1px #f6dfaa;
}
.page-part:not(.part-intro-active) .page-title {
  color: #1f4137;
  font-family: var(--font-display);
  font-size: 39px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: .1em;
  text-shadow: 0 1px #fff2c8, 1px 2px rgba(137,91,36,.22);
}
.page-part:not(.part-intro-active) .page-intro {
  margin-top: 10px;
  color: #6b4c2c;
  font-family: var(--font-copy);
  font-size: 18px;
  line-height: 1.55;
  letter-spacing: .07em;
}
.page-part:not(.part-intro-active) .court-progress {
  height: 58px;
  padding: 13px 19px;
  gap: 10px;
  color: #796044;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .08em;
}
.page-part:not(.part-intro-active) .court-progress .done,
.page-part:not(.part-intro-active) .court-progress .active {
  color: #913429;
  text-shadow: 0 1px #efd59a;
}
.page-part:not(.part-intro-active) .part-layout { margin-top: 18px; }
.page-part:not(.part-intro-active) .seg-control {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: 100%;
}
.page-part:not(.part-intro-active) .seg-btn {
  width: 100%;
  min-width: 0;
  padding: 11px 20px;
  color: #69472d;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .18em;
}
.page-part:not(.part-intro-active) .seg-btn.active {
  color: #f4d78e;
  text-shadow: 0 1px #4f2518;
}
.page-part:not(.part-intro-active) .part-figure-wrap .body-figure { height: 482px; }
.page-part:not(.part-intro-active) .body-figure .leader-text {
  fill: #6e3b24;
  stroke: rgba(255,232,168,.75);
  stroke-width: .45px;
  paint-order: stroke fill;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: .06em;
  filter: drop-shadow(0 1px 0 rgba(255,247,213,.7));
}
.page-part:not(.part-intro-active) .body-figure .leader-pill {
  fill: rgba(246,225,173,.96);
  stroke: #a87036;
  stroke-width: 1.15px;
}
.page-part:not(.part-intro-active) .body-figure .leader-line { stroke-width: 1.65; }
.page-part:not(.part-intro-active) .body-figure .regions path {
  vector-effect: non-scaling-stroke;
  transition: fill .18s ease, fill-opacity .18s ease, stroke .18s ease, filter .18s ease;
}
.page-part:not(.part-intro-active) .body-figure .regions path.clickable:hover {
  fill: rgba(177,87,54,.2);
  stroke: rgba(126,57,36,.62);
  stroke-width: 1.15;
}
.page-part:not(.part-intro-active) .body-figure .regions path.selected {
  stroke: #8d3529;
  stroke-width: 2.2;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 3px rgba(239,196,104,.82));
}
.page-part:not(.part-intro-active) .side-label {
  color: #8d3327;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .23em;
  text-shadow: 0 1px #f5dfa9;
}
.page-part:not(.part-intro-active) .side-part {
  min-height: 68px;
  margin-top: 16px;
  color: #23483b;
  font-family: var(--font-display);
  font-size: 50px;
  letter-spacing: .12em;
  text-shadow: 0 1px #fff0bd, 1px 2px rgba(112,70,27,.2);
}
.page-part:not(.part-intro-active) .side-note {
  margin-top: 18px;
  color: #684527;
  font-family: var(--font-copy);
  font-size: 22px;
  font-weight: 700;
  line-height: 1.8;
  letter-spacing: .08em;
}
.page-part:not(.part-intro-active) .side-divider { margin: 25px 0; }
.page-part:not(.part-intro-active) .btn-block {
  min-height: 68px;
  padding: 16px 24px;
  color: #f3d487;
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: .12em;
  text-shadow: 0 1px #4f2418;
}
.page-part:not(.part-intro-active) .side-tip {
  margin-top: 17px;
  color: #725033;
  font-family: var(--font-copy);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: .05em;
}
.page-part:not(.part-intro-active) .part-side::before {
  width: 47px;
  padding: 15px 5px 14px;
  color: #f1d27f;
  font-family: var(--font-display);
  font-size: 23px;
  font-weight: 700;
  text-shadow: 0 1px #4b2217;
}
.page-part:not(.part-intro-active) .part-side::after {
  width: 60px;
  height: 60px;
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
}
.stage:has(.page-part:not(.part-intro-active)) .legal-note {
  font-family: var(--font-copy);
  font-size: 14px;
  letter-spacing: .07em;
}
.stage:has(.page-part:not(.part-intro-active)) .legal-note { bottom: 17px; color: rgba(247,226,184,.78); text-shadow: 0 1px 3px #2a140d; }

@media (prefers-reduced-motion: reduce) {
  .gate-door, .home-ceremony { transition-duration: .01ms; }
  .palace-home.opening .imperial-gate { animation: none; }
  .gender-rite, .gender-rite-scroll { animation: none; }
  .part-cinematic *, .part-exam-shell, .part-exam-shell.visible .painted-body-image { animation: none !important; transition-duration: .01ms !important; transition-delay: 0ms !important; }
}

@media (max-width: 760px) {
  .narrow-screen .palace-home { min-height: 100dvh; }
  .narrow-screen .home-ceremony { left: 8%; right: 8%; top: 13vh; width: auto; text-align: center; }
  .narrow-screen .palace-home .home-eyebrow, .narrow-screen .home-start-cta { justify-content: center; width: 100%; }
  .narrow-screen .palace-home .home-title-ink { font-size: clamp(48px, 16vw, 76px); }
  .narrow-screen .palace-home .home-title-teal { font-size: clamp(27px, 9vw, 42px); }
  .narrow-screen .palace-home .doctor-note { margin-left: auto; margin-right: auto; text-align: left; }
  .narrow-screen .imperial-gate { width: 760px; right: 50%; top: 36vh; transform: translateX(50%) scale(.7); transform-origin: top center; opacity: .52; }
  .narrow-screen .palace-home.opening .imperial-gate { animation: none; }
  .narrow-screen .gender-rite-scroll { width: min(88vw, 620px); min-height: 0; padding: 52px 42px 39px; }
  .narrow-screen .gender-rite h2 { font-size: clamp(29px, 7vw, 39px); letter-spacing: .1em; }
  .narrow-screen .gender-rite-copy { margin-bottom: 24px; font-size: 17px; }
  .narrow-screen .gender-rite-options { grid-template-columns: 1fr; gap: 17px; }
  .narrow-screen .gender-rite-divider { display: none; }
  .narrow-screen .gender-rite-option { min-height: 104px; }
  .narrow-screen .gender-rite-option strong { font-size: 28px; }
  .narrow-screen .court-heading { display: block; }
  .narrow-screen .court-progress { min-width: 0; width: 100%; margin-top: 20px; overflow: hidden; }
  .narrow-screen .part-cinematic { position: fixed; }
  .narrow-screen .part-cinematic-copy { left: 28px; right: 28px; bottom: 48px; }
  .narrow-screen .part-cinematic-copy strong { font-size: 30px; }
  .narrow-screen .part-cinematic-pulse { width: 48vw; height: 68vh; }
  .narrow-screen .page-part .part-card { width: 100%; }
  .narrow-screen .page-part .part-side { padding: 25px; }
}

/* U06 · 手机御医召见：居中的双奏章布局 */
.page-subjective {
  max-width: 1460px;
  margin: 0 auto;
  padding-bottom: 34px;
}
.page-subjective .page-head-row {
  align-items: center;
  margin-bottom: 4px;
}
.page-subjective .page-intro {
  max-width: 1080px;
  margin-bottom: 24px;
}
.page-subjective .subjective-layout {
  grid-template-columns: minmax(360px, 470px) minmax(520px, 650px);
  justify-content: center;
  align-items: stretch;
  gap: clamp(42px, 5vw, 82px);
  width: min(100%, 1220px);
  min-height: 0;
  margin: 18px auto 0;
}
.page-subjective .qr-paper,
.page-subjective .subjective-instructions {
  position: relative;
  box-sizing: border-box;
  min-height: 520px;
  padding: 30px 42px 28px;
  border: 1px solid rgba(119, 72, 34, .56);
  background:
    linear-gradient(90deg, rgba(121, 75, 35, .08), transparent 9% 91%, rgba(121, 75, 35, .08)),
    repeating-linear-gradient(96deg, rgba(78, 49, 25, .025) 0 1px, transparent 1px 8px),
    rgba(248, 231, 186, .74);
  box-shadow: inset 0 0 0 6px rgba(255, 247, 216, .24), 10px 13px 0 rgba(80, 47, 27, .09);
  clip-path: polygon(.6% 1%, 99.4% 0, 100% 98.5%, 98.7% 100%, .3% 99%, 0 2%);
}
.page-subjective .qr-paper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
}
.page-subjective .paper-eyebrow {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: .12em;
}
.page-subjective .subjective-qr {
  width: 286px;
  height: 286px;
  margin: 22px auto 15px;
  border: 12px solid #fffdf5;
  box-shadow: 0 5px 18px rgba(73, 43, 22, .14);
}
.page-subjective .mobile-entry-link {
  display: inline-block;
  max-width: 300px;
  padding: 6px 12px;
  color: #743027;
  border-bottom: 1px solid rgba(116, 48, 39, .42);
  font-family: STKaiti, KaiTi, serif;
  font-size: 15px;
  line-height: 1.4;
  letter-spacing: .06em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.page-subjective .qr-fixed-note {
  margin: 15px 0 0;
  color: #81684a;
  font-size: 14px;
  letter-spacing: .04em;
}
.page-subjective .subjective-instructions {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 42px 58px 34px;
}
.page-subjective .pairing-code {
  margin: 20px 0 13px;
  color: #233e34;
  font-size: clamp(76px, 5vw, 94px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: .3em;
  text-align: center;
  text-indent: .3em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 2px 0 rgba(255, 248, 218, .6);
}
.page-subjective .subjective-state {
  align-self: center;
  margin: 10px 0 25px;
  font-size: 17px;
  letter-spacing: .08em;
}
.page-subjective .subjective-copy {
  margin: 0;
  padding: 17px 20px;
  color: #5e4b38;
  border-top: 1px solid rgba(120, 76, 39, .3);
  border-bottom: 1px solid rgba(120, 76, 39, .3);
  font-size: 17px;
  line-height: 1.85;
  letter-spacing: .035em;
}
.page-subjective .subjective-deadline {
  margin: 17px 0 0;
  font-size: 15px;
  line-height: 1.65;
}
.page-subjective .subjective-actions { margin-top: 16px; }
.page-subjective .subjective-note {
  margin: auto 0 0;
  padding-top: 18px;
  color: #897052;
  font-size: 13px;
  line-height: 1.6;
  letter-spacing: .04em;
}

@media (max-width: 1180px) {
  .page-subjective .subjective-layout {
    grid-template-columns: minmax(320px, 420px) minmax(440px, 1fr);
    gap: 32px;
  }
  .page-subjective .qr-paper,
  .page-subjective .subjective-instructions { min-height: 485px; }
  .page-subjective .subjective-qr { width: 250px; height: 250px; }
  .page-subjective .subjective-instructions { padding-inline: 38px; }
}

.narrow-screen .page-subjective .subjective-layout {
  grid-template-columns: 1fr;
  width: min(100%, 650px);
}
.narrow-screen .page-subjective .qr-paper,
.narrow-screen .page-subjective .subjective-instructions { min-height: 0; }

/* U07 · 可疑方向与四类调养诊方 */
.page-report { overflow-y: auto; padding-bottom: 34px; }
.page-report .report-reading {
  grid-template-columns: 1fr;
  height: 168px;
  margin-top: 12px;
}
.page-report .report-quick { display: none; }
.page-report .report-detail-card { padding: 18px 26px; }
.page-report .detail-reading { font-size: 17px; line-height: 1.65; }
.care-prescription {
  flex: none;
  margin-top: 12px;
  padding: 16px 22px 13px;
  color: #3f3023;
  border: 1px solid rgba(120, 75, 38, .48);
  background:
    repeating-linear-gradient(96deg, rgba(83,55,31,.025) 0 1px, transparent 1px 8px),
    rgba(242, 222, 176, .88);
  box-shadow: inset 0 0 0 4px rgba(255,247,218,.2), 6px 7px 0 rgba(80,47,27,.07);
}
.care-prescription-head {
  display: grid;
  grid-template-columns: minmax(280px, .8fr) minmax(0, 1.7fr);
  align-items: center;
  gap: 22px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(118, 73, 36, .28);
}
.care-prescription-head .reading-caption { margin: 0 0 3px; font-size: 13px; }
.care-prescription-head h3 { margin: 0; color: #263e35; font: 700 24px/1.25 STKaiti, KaiTi, serif; letter-spacing: .06em; }
.care-prescription-head > p { margin: 0; color: #69513b; font: 15px/1.55 FangSong, STKaiti, serif; }
.care-prescription-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 11px;
}
.care-prescription-item {
  display: grid;
  grid-template-columns: 35px 1fr;
  gap: 9px;
  min-width: 0;
  padding: 10px 11px;
  border-left: 3px solid #7d3027;
  background: rgba(255, 248, 222, .48);
}
.care-prescription-item > span {
  color: #8a3027;
  font: 700 16px/1.2 STKaiti, KaiTi, serif;
  writing-mode: vertical-rl;
  letter-spacing: .08em;
}
.care-prescription-item strong { display: block; color: #263e35; font: 700 17px/1.25 STKaiti, KaiTi, serif; }
.care-prescription-item p { margin: 4px 0 0; color: #65503d; font-size: 13px; line-height: 1.45; }
.care-prescription-review { margin: 9px 0 0; color: #7b5b3b; font-size: 12px; line-height: 1.4; }
.report-medical-disclaimer {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  margin: 16px 0 4px;
  padding: 18px 24px;
  border: 3px double #9a3028;
  border-radius: 4px;
  background: linear-gradient(100deg, rgba(112,25,21,.12), rgba(250,229,174,.96) 18%, rgba(248,235,198,.96));
  box-shadow: 0 7px 18px rgba(76,38,21,.18), inset 0 0 0 1px rgba(255,248,220,.8);
}
.report-disclaimer-seal {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border: 2px solid #8d2923;
  color: #8d2923;
  font: 700 38px/1 STKaiti, KaiTi, serif;
  box-shadow: inset 0 0 0 4px rgba(154,48,40,.1);
}
.report-medical-disclaimer strong {
  display: block;
  color: #83271f;
  font: 700 25px/1.3 STKaiti, KaiTi, serif;
  letter-spacing: .08em;
}
.report-medical-disclaimer p {
  margin: 7px 0 0;
  color: #4f3429;
  font: 700 16px/1.65 FangSong, STKaiti, serif;
}
.report-download-panel {
  display: grid;
  grid-template-columns: 154px minmax(0, 1fr) 210px;
  align-items: center;
  gap: 20px;
  margin-top: 16px;
  padding: 16px 20px;
  border: 2px solid #7f3027;
  background:
    linear-gradient(90deg, rgba(120,42,31,.12), transparent 18% 82%, rgba(37,75,64,.1)),
    rgba(247,230,188,.96);
  box-shadow: inset 0 0 0 4px rgba(255,248,221,.35), 7px 8px 0 rgba(73,42,24,.08);
}
.report-download-qr { position: relative; padding: 8px; border: 1px solid #a2733c; background: #fff9e8; }
.report-download-qr img { display: block; width: 136px; height: 136px; }
.report-download-qr span { position: absolute; left: 50%; bottom: -10px; padding: 3px 10px; color: #f7e5b3; background: #84271f; font: 700 12px/1.2 STKaiti,KaiTi,serif; transform: translateX(-50%); white-space: nowrap; }
.report-download-copy .reading-caption { margin: 0 0 4px; }
.report-download-copy h3 { margin: 0; color: #29473d; font: 700 25px/1.3 STKaiti,KaiTi,serif; letter-spacing: .05em; }
.report-download-copy > p:not(.reading-caption) { margin: 7px 0; color: #614936; font-size: 14px; line-height: 1.55; }
.report-download-copy a { color: #812a22; font-size: 12px; }
.report-finish-button {
  min-height: 58px;
  padding: 10px 16px;
  color: #6c2d22;
  border: 1px solid #9c6d37;
  background: rgba(255,247,216,.78);
  font: 700 17px/1.35 STKaiti,KaiTi,serif;
  cursor: pointer;
}
.report-finish-button:hover { color: #fff0c3; border-color: #6d1d18; background: #892d24; }
.page-report .report-taskbar,
.page-report.compact .report-taskbar { min-height: 92px; margin-top: 12px; padding-block: 12px; }

@media (max-width: 980px) {
  .care-prescription-grid { grid-template-columns: 1fr 1fr; }
  .care-prescription-head { grid-template-columns: 1fr; gap: 7px; }
  .report-medical-disclaimer { grid-template-columns: 54px minmax(0, 1fr); padding: 14px 16px; gap: 12px; }
  .report-disclaimer-seal { width: 48px; height: 48px; font-size: 30px; }
  .report-medical-disclaimer strong { font-size: 20px; }
  .report-medical-disclaimer p { font-size: 14px; }
  .report-download-panel { grid-template-columns: 130px minmax(0,1fr); }
  .report-download-qr img { width: 112px; height: 112px; }
  .report-finish-button { grid-column: 1 / -1; }
}

/* U09 · 取消数字倒计时，统一为5秒汉家五式舒展。 */
.page-task {
  overflow: hidden;
  padding-top: 118px;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 55%, rgba(255,246,211,.86), transparent 48%),
    linear-gradient(180deg, rgba(30,67,59,.18) 0 18%, transparent 18% 100%);
}
.page-task .page-title { margin-bottom: 5px; font-size: 42px; letter-spacing: .16em; }
.page-task .page-intro { margin: 0 auto 8px; font-size: 17px; }
.imperial-exercise {
  position: relative;
  width: min(720px, 72vw);
  height: 430px;
  margin: 2px auto 0;
  overflow: hidden;
  border: 1px solid rgba(105,61,32,.48);
  outline: 1px solid rgba(177,130,66,.4);
  outline-offset: -8px;
  background:
    linear-gradient(90deg, rgba(105,34,27,.12), transparent 16% 84%, rgba(105,34,27,.12)),
    radial-gradient(ellipse at 50% 74%, rgba(255,247,213,.9), rgba(208,177,118,.74));
  box-shadow: 9px 11px 0 rgba(76,46,27,.09), inset 0 0 48px rgba(83,52,29,.12);
}
.exercise-hall { position: absolute; inset: 0; opacity: .62; }
.exercise-hall::before,
.exercise-hall::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 43px;
  width: 82px;
  border-inline: 13px solid #762f26;
  background: repeating-linear-gradient(0deg, rgba(197,151,75,.65) 0 7px, transparent 7px 42px);
}
.exercise-hall::before { left: 35px; }
.exercise-hall::after { right: 35px; }
.exercise-hall i { position: absolute; top: 38px; bottom: 62px; width: 2px; background: rgba(43,76,65,.24); }
.exercise-hall i:nth-child(1) { left: 28%; }
.exercise-hall i:nth-child(2) { left: 50%; }
.exercise-hall i:nth-child(3) { right: 28%; }
.exercise-aura {
  position: absolute;
  left: 50%;
  top: 46%;
  width: 330px;
  height: 330px;
  border: 1px solid rgba(122,48,37,.19);
  border-radius: 50%;
  transform: translate(-50%,-50%);
  animation: exercise-breath 5s ease-in-out both;
}
.exercise-aura::before,
.exercise-aura::after { content: ''; position: absolute; inset: 22px; border: 1px dashed rgba(38,70,59,.2); border-radius: 50%; }
.exercise-aura::after { inset: 52px; border-style: solid; }
.exercise-figure {
  position: absolute;
  left: 50%;
  bottom: 23px;
  z-index: 2;
  width: 206px;
  height: 371px;
  transform: translateX(-50%);
  transform-origin: 50% 92%;
}
.exercise-puppet {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  mix-blend-mode: multiply;
  filter: saturate(.72) contrast(1.03) drop-shadow(0 7px 5px rgba(63,39,24,.16));
}
.exercise-puppet g { transform-box: view-box; }
.puppet-core { transform-origin: 160px 585px; animation: puppet-core-five-form 5s cubic-bezier(.42,0,.3,1) both; }
.puppet-left-arm { transform-origin: 112px 154px; animation: puppet-left-arm-five-form 5s cubic-bezier(.42,0,.3,1) both; }
.puppet-right-arm { transform-origin: 208px 154px; animation: puppet-right-arm-five-form 5s cubic-bezier(.42,0,.3,1) both; }
.puppet-left-leg { transform-origin: 135px 380px; animation: puppet-left-leg-five-form 5s ease-in-out both; }
.puppet-right-leg { transform-origin: 185px 380px; animation: puppet-right-leg-five-form 5s ease-in-out both; }
.exercise-demo-badge {
  position: absolute;
  top: 18px;
  right: 22px;
  padding: 6px 12px;
  color: #f9e9b7;
  border: 1px solid rgba(239,210,139,.72);
  background: rgba(111,38,31,.88);
  font: 700 14px/1.2 STKaiti, KaiTi, serif;
  letter-spacing: .12em;
  box-shadow: 0 3px 8px rgba(58,29,18,.2);
}
.motion-arc { position: absolute; top: 108px; width: 82px; height: 150px; border: 2px solid transparent; border-top-color: rgba(125,48,37,.48); border-radius: 50%; opacity: 0; }
.motion-arc-left { right: 84%; transform: rotate(-25deg); animation: motion-left 5s ease both; }
.motion-arc-right { left: 84%; transform: rotate(25deg); animation: motion-right 5s ease both; }
.exercise-floor { position: absolute; left: 17%; right: 17%; bottom: 20px; height: 28px; border-top: 2px solid rgba(92,54,31,.38); border-radius: 50%; background: radial-gradient(ellipse, rgba(80,50,29,.16), transparent 66%); }
.exercise-forms { display: flex; justify-content: center; gap: 9px; margin: 9px auto 0; }
.exercise-forms span { min-width: 62px; padding: 5px 11px; color: #6f4932; border: 1px solid rgba(125,82,42,.36); background: rgba(248,235,199,.72); font: 700 15px/1.25 STKaiti, KaiTi, serif; }
.exercise-forms span:nth-child(1) { animation: form-seal-one 5s both; }
.exercise-forms span:nth-child(2) { animation: form-seal-two 5s both; }
.exercise-forms span:nth-child(3) { animation: form-seal-three 5s both; }
.exercise-forms span:nth-child(4) { animation: form-seal-four 5s both; }
.exercise-forms span:nth-child(5) { animation: form-seal-five 5s both; }
.page-task .task-line { max-width: 760px; margin: 8px auto 0; color: #765b40; font-size: 13px; }
@keyframes puppet-core-five-form {
  0%,18% { transform: translateY(2px) scale(1,.99); }
  20%,38% { transform: translateY(-3px) scale(.995,1.012); }
  42%,58% { transform: translate(-9px,-2px) rotate(-4deg); }
  62%,78% { transform: translate(9px,-2px) rotate(4deg); }
  82%,100% { transform: translate(0,0) rotate(0) scale(1); }
}
@keyframes puppet-left-arm-five-form {
  0%,18% { transform: rotate(0); }
  22%,38% { transform: rotate(52deg); }
  42%,58% { transform: rotate(78deg) translate(-2px,-2px); }
  62%,78% { transform: rotate(24deg); }
  82%,100% { transform: rotate(0); }
}
@keyframes puppet-right-arm-five-form {
  0%,18% { transform: rotate(0); }
  22%,38% { transform: rotate(-52deg); }
  42%,58% { transform: rotate(-24deg); }
  62%,78% { transform: rotate(-78deg) translate(2px,-2px); }
  82%,100% { transform: rotate(0); }
}
@keyframes puppet-left-leg-five-form {
  0%,38%,82%,100% { transform: rotate(0) translate(0,0); }
  42%,58% { transform: rotate(2deg) translate(-3px,0); }
  62%,78% { transform: rotate(-1deg) translate(2px,0); }
}
@keyframes puppet-right-leg-five-form {
  0%,38%,82%,100% { transform: rotate(0) translate(0,0); }
  42%,58% { transform: rotate(1deg) translate(-2px,0); }
  62%,78% { transform: rotate(-2deg) translate(3px,0); }
}
@keyframes exercise-breath { 0%,100% { transform: translate(-50%,-50%) scale(.9); opacity:.35; } 45% { transform: translate(-50%,-50%) scale(1.08); opacity:.82; } }
@keyframes motion-left { 28%,43% { opacity:.72; transform: translate(-9px,-13px) rotate(-37deg) scale(1.08); } 0%,20%,52%,100% { opacity:0; } }
@keyframes motion-right { 46%,62% { opacity:.72; transform: translate(9px,-13px) rotate(37deg) scale(1.08); } 0%,38%,70%,100% { opacity:0; } }
@keyframes form-seal-one { 0%,18% { color:#fff0c9; border-color:#9e372b; background:#873027; transform:translateY(-2px); } 21%,100% { transform:none; } }
@keyframes form-seal-two { 0%,19%,41%,100% { transform:none; } 21%,38% { color:#fff0c9; border-color:#9e372b; background:#873027; transform:translateY(-2px); } }
@keyframes form-seal-three { 0%,39%,61%,100% { transform:none; } 41%,58% { color:#fff0c9; border-color:#9e372b; background:#873027; transform:translateY(-2px); } }
@keyframes form-seal-four { 0%,59%,81%,100% { transform:none; } 61%,78% { color:#fff0c9; border-color:#9e372b; background:#873027; transform:translateY(-2px); } }
@keyframes form-seal-five { 0%,79% { transform:none; } 81%,100% { color:#fff0c9; border-color:#9e372b; background:#873027; transform:translateY(-2px); } }
.reduced-motion .puppet-core { animation: exercise-puppet-gentle 5s ease-in-out both; }
.reduced-motion .puppet-arm, .reduced-motion .puppet-leg { animation: none; }
.reduced-motion .motion-arc { display: none; }
@keyframes exercise-puppet-gentle { 0%,100% { transform:translateY(0); } 50% { transform:translateY(-5px); } }

/* U10 · 游戏结束：宫帷合拢、御印落款、自动重启至宫门 */
.page-buff,
.page-buff.glow {
  isolation: isolate;
  overflow: hidden;
  padding-top: 112px;
  background:
    radial-gradient(circle at 50% 42%, rgba(255,244,197,.92), transparent 38%),
    linear-gradient(180deg, #183f38 0 17%, #d8ba7c 17% 100%);
}
.page-buff::before {
  z-index: 0;
  border: 2px solid rgba(102, 43, 26, .56);
  outline: 1px solid rgba(190, 143, 65, .46);
  outline-offset: -8px;
}
.ending-content {
  position: relative;
  z-index: 4;
  display: flex;
  align-items: center;
  flex-direction: column;
  width: min(880px, 84%);
  margin: 0 auto;
  animation: ending-content-reveal 9s both;
}
.ending-kicker {
  margin: 0 0 7px;
  color: #8d3026;
  font: 700 18px/1.4 STKaiti, KaiTi, serif;
  letter-spacing: .48em;
}
.ending-title {
  margin: 0 0 13px;
  color: #203f36;
  font: 700 48px/1.12 STKaiti, KaiTi, serif;
  letter-spacing: .14em;
  text-shadow: 0 2px rgba(255,245,206,.8);
}
.page-buff .buff-eyebrow { margin: 0 0 9px; font-size: 16px; }
.page-buff .buff-name { margin-top: 5px; font-size: 36px; }
.page-buff .buff-text { margin-top: 8px; font-size: 20px; }
.page-buff .buff-reward { margin-top: 11px; font-size: 16px; }
.page-buff .buff-countdown {
  margin-top: 19px;
  padding: 10px 27px;
  color: #5c4936;
  border: 1px solid rgba(121, 75, 36, .46);
  border-radius: 0;
  background: rgba(255, 247, 216, .55);
}
.page-buff .buff-countdown strong { color: #8d3026; font-size: 25px; }
.ending-skip {
  margin-top: 10px;
  padding: 6px 14px;
  color: #7a3027;
  border: 0;
  border-bottom: 1px solid rgba(122,48,39,.45);
  background: transparent;
  font: 700 15px/1.4 STKaiti, KaiTi, serif;
  letter-spacing: .12em;
  cursor: pointer;
}
.ending-curtain {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 8;
  width: 51%;
  background:
    linear-gradient(90deg, rgba(52,12,12,.32), transparent 18% 82%, rgba(52,12,12,.38)),
    repeating-linear-gradient(90deg, rgba(255,222,143,.08) 0 3px, transparent 3px 42px),
    linear-gradient(180deg, #7e211d, #a43b2c 48%, #661714);
  box-shadow: inset 0 0 0 5px rgba(222,171,78,.25), 0 0 40px rgba(35,12,9,.5);
  pointer-events: none;
}
.ending-curtain::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 18px;
  background: linear-gradient(90deg, #75411f, #d2a34f 48%, #6e391b);
}
.ending-curtain-left { left: 0; animation: ending-curtain-left 9s both; }
.ending-curtain-left::after { right: 0; }
.ending-curtain-right { right: 0; animation: ending-curtain-right 9s both; }
.ending-curtain-right::after { left: 0; }
.ending-cloud {
  position: absolute;
  z-index: 2;
  width: 360px;
  height: 100px;
  opacity: .2;
  border: 4px solid #7d3027;
  border-radius: 50%;
  pointer-events: none;
}
.ending-cloud-left { left: -110px; bottom: 95px; animation: ending-cloud-drift 6s ease-in-out infinite alternate; }
.ending-cloud-right { right: -120px; top: 180px; animation: ending-cloud-drift 7s ease-in-out infinite alternate-reverse; }
@keyframes ending-curtain-left {
  0%, 8% { transform: translateX(-102%); }
  22%, 31% { transform: translateX(0); }
  43%, 78% { transform: translateX(-102%); }
  94%, 100% { transform: translateX(0); }
}
@keyframes ending-curtain-right {
  0%, 8% { transform: translateX(102%); }
  22%, 31% { transform: translateX(0); }
  43%, 78% { transform: translateX(102%); }
  94%, 100% { transform: translateX(0); }
}
@keyframes ending-content-reveal {
  0%, 30% { opacity: 0; transform: translateY(18px) scale(.96); }
  43%, 80% { opacity: 1; transform: none; }
  91%, 100% { opacity: 0; transform: scale(.98); }
}
@keyframes ending-cloud-drift { to { transform: translateX(80px); } }

@media (prefers-reduced-motion: reduce) {
  .ending-content { animation: none; }
  .ending-curtain { display: none; }
  .ending-cloud { animation: none; }
}

/* 游戏内常驻设置与 ESC 暂停奏章 */
.topbar-actions {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 18px;
  pointer-events: auto;
}
.game-limit-pill {
  min-width: 112px;
  padding: 9px 14px;
  color: #efd7a3;
  border: 1px solid rgba(222,185,105,.55);
  background: rgba(42,31,20,.22);
  font: 700 16px/1.25 STKaiti, KaiTi, serif;
  letter-spacing: .08em;
  text-align: center;
}
.game-settings-button {
  position: relative;
  z-index: 3;
  min-width: 154px;
  height: 50px;
  padding: 0 20px;
  border: 1px solid #c79b50;
  border-radius: 2px;
  color: #f3d996;
  background: linear-gradient(180deg, rgba(112,43,34,.94), rgba(72,25,22,.96));
  box-shadow: inset 0 0 0 2px rgba(255,231,173,.13), 0 4px 12px rgba(24,14,9,.22);
  font-family: var(--font-display), STKaiti, KaiTi, serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .12em;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
}
.stage .topbar { z-index: 120; }
.game-settings-button span { margin-right: 8px; color: #e6bd65; }
.game-settings-button:hover,
.game-settings-button:focus-visible { color: #fff0c5; border-color: #e4bf70; transform: translateY(-1px); }

.pause-overlay {
  position: absolute;
  inset: 0;
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 44%, rgba(15,43,39,.72), rgba(9,17,17,.9));
  backdrop-filter: blur(5px) saturate(.72);
}
.pause-scroll {
  position: relative;
  width: 590px;
  min-height: 590px;
  box-sizing: border-box;
  padding: 72px 82px 54px;
  text-align: center;
  color: #49301f;
  background:
    linear-gradient(90deg, rgba(106,55,28,.14), transparent 8% 92%, rgba(106,55,28,.14)),
    repeating-linear-gradient(96deg, rgba(83,55,31,.035) 0 1px, transparent 1px 8px),
    #ead5a4;
  border: 2px solid #8c5a2f;
  box-shadow: inset 0 0 0 7px rgba(255,244,205,.28), 0 24px 70px rgba(0,0,0,.48);
}
.pause-scroll::before,
.pause-scroll::after {
  content: '';
  position: absolute;
  left: -28px;
  right: -28px;
  height: 25px;
  border: 2px solid #6f3b25;
  border-radius: 14px;
  background: linear-gradient(180deg, #b38345, #6c3d26 48%, #c29450 55%, #70402a);
  box-shadow: 0 5px 12px rgba(36,20,13,.28);
}
.pause-scroll::before { top: -14px; }
.pause-scroll::after { bottom: -14px; }
.pause-seal {
  position: absolute;
  top: 39px;
  right: 45px;
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  border: 2px solid #9a3529;
  color: #963328;
  font: 700 31px/1 STKaiti, KaiTi, serif;
  transform: rotate(6deg);
}
.pause-kicker { margin: 0 0 16px; color: #8d3328; font: 700 17px/1.4 STKaiti, KaiTi, serif; letter-spacing: .35em; }
.pause-scroll h2 { margin: 0; color: #203f37; font: 700 42px/1.25 STKaiti, KaiTi, serif; letter-spacing: .13em; }
.pause-copy { min-height: 58px; margin: 22px 0 28px; font: 700 18px/1.75 FangSong, STKaiti, serif; letter-spacing: .05em; }
.pause-music {
  width: 390px;
  box-sizing: border-box;
  margin: -8px auto 24px;
  padding: 15px 18px 13px;
  border: 1px solid rgba(117, 69, 38, .42);
  background: rgba(255, 244, 207, .43);
  box-shadow: inset 0 0 0 3px rgba(255,255,255,.15);
  text-align: left;
}
.pause-music-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.pause-music-heading span { display: flex; flex-direction: column; gap: 2px; }
.pause-music-heading small { color: #856746; font: 13px/1.3 sans-serif; letter-spacing: .13em; }
.pause-music-heading strong { color: #274c42; font: 700 19px/1.35 STKaiti, KaiTi, serif; letter-spacing: .12em; }
.pause-music-heading button {
  min-width: 106px;
  padding: 8px 10px;
  border: 1px solid #956a3c;
  color: #78553a;
  background: rgba(255,255,255,.3);
  font: 700 15px/1.25 STKaiti, KaiTi, serif;
  letter-spacing: .08em;
  cursor: pointer;
}
.pause-music-heading button.active { border-color: #9e392d; color: #fff0c4; background: #9e392d; }
.pause-music label { display: grid; grid-template-columns: 42px 1fr 48px; align-items: center; gap: 11px; margin-top: 12px; color: #634631; font: 700 15px/1.2 STKaiti, KaiTi, serif; }
.pause-music label.disabled { opacity: .45; }
.pause-music input { width: 100%; accent-color: #9e392d; cursor: pointer; }
.pause-music output { text-align: right; font-family: sans-serif; font-size: 13px; }
.pause-actions { display: grid; gap: 13px; width: 330px; margin: 0 auto; }
.pause-actions .btn { min-height: 56px; font-family: STKaiti, KaiTi, serif; font-size: 20px; letter-spacing: .14em; }
.pause-exit { padding: 9px; border: 0; color: #7d392d; background: transparent; font: 700 17px/1.4 STKaiti, KaiTi, serif; letter-spacing: .12em; cursor: pointer; }
.pause-exit:hover { color: #a12e25; text-decoration: underline; text-underline-offset: 5px; }
.pause-hint { margin: 20px 0 0; color: #856746; font: 14px/1.4 sans-serif; letter-spacing: .13em; }

@media (max-width: 760px) {
  .topbar-actions { gap: 8px; }
  .game-limit-pill { min-width: 88px; padding-inline: 8px; font-size: 14px; }
  .game-settings-button { min-width: 112px; height: 44px; padding: 0 12px; font-size: 15px; }
  .pause-scroll { width: min(82vw, 590px); min-height: 0; padding: 56px 38px 42px; }
  .pause-scroll h2 { font-size: 34px; }
  .pause-music { width: min(100%, 390px); }
  .pause-actions { width: min(100%, 330px); }
}

/* D01 · 晴日宫廷：以晨光、晴空、朱墙金瓦替代夜景与重暗角。 */
:root {
  --palace-night: #a8d9e8;
}

.palace-home {
  color: #48291c;
  background:
    radial-gradient(circle at 72% 14%, rgba(255, 248, 194, .98) 0 4.5%, rgba(255, 235, 147, .46) 8%, transparent 18%),
    linear-gradient(180deg, #8fd0e6 0%, #cce9eb 43%, #f4dfaf 74%, #d7a85e 100%);
}
.palace-home::before {
  border-color: rgba(153, 83, 42, .34);
  box-shadow: inset 0 0 70px rgba(129, 76, 31, .12);
}
.palace-home::after {
  opacity: .24;
  background-image: repeating-linear-gradient(105deg, rgba(255,255,255,.18) 0 1px, transparent 1px 8px);
  mix-blend-mode: soft-light;
}
.palace-night::before {
  width: 112px;
  height: 112px;
  top: 68px;
  left: 72%;
  background: #fff5b4;
  border: 3px solid rgba(255, 248, 211, .75);
  box-shadow: 0 0 34px 13px rgba(255, 229, 122, .5), 0 0 100px 28px rgba(255, 240, 175, .34);
}
.palace-night::after {
  background:
    linear-gradient(180deg, rgba(255,255,255,.08), transparent 40%),
    radial-gradient(ellipse at 50% 100%, transparent 0 36%, rgba(165, 105, 49, .12) 100%);
}
.palace-night span {
  width: 128px;
  height: 22px;
  border-radius: 50%;
  opacity: .72;
  background: rgba(255, 255, 255, .76);
  box-shadow:
    28px -12px 0 3px rgba(255,255,255,.73),
    63px -3px 0 7px rgba(255,255,255,.66),
    91px 5px 0 -1px rgba(255,255,255,.58);
  filter: blur(.2px);
}
.palace-night span:nth-child(1) { left: 10%; top: 16%; animation: daylight-cloud 16s ease-in-out infinite alternate; }
.palace-night span:nth-child(2) { right: 22%; top: 29%; opacity: .52; transform: scale(.72); animation: daylight-cloud 20s ease-in-out infinite alternate-reverse; }
.palace-night span:nth-child(3) { left: 34%; top: 38%; opacity: .42; transform: scale(.56); animation: daylight-cloud 18s ease-in-out infinite alternate; }
@keyframes daylight-cloud { to { translate: 36px 0; } }

.palace-silhouette {
  opacity: .88;
  background:
    linear-gradient(150deg, transparent 0 37%, #a85138 37.5% 43%, transparent 43.5%) left 34% bottom 61% / 47% 31% no-repeat,
    linear-gradient(210deg, transparent 0 37%, #a85138 37.5% 43%, transparent 43.5%) right 34% bottom 61% / 47% 31% no-repeat,
    repeating-linear-gradient(90deg, transparent 0 8.5%, #8f3c30 8.5% 9.5%, transparent 9.5% 17%) center bottom / 78% 55% no-repeat,
    linear-gradient(180deg, transparent 0 48%, #a6533d 48% 62%, #c98d51 62% 100%);
  filter: drop-shadow(0 -8px 15px rgba(101, 58, 30, .18));
}

.home-ceremony { text-shadow: 0 2px 12px rgba(255, 247, 213, .68); }
.palace-home .home-eyebrow { color: #4a5741; }
.palace-home .live-dot { background: #b63e2e; box-shadow: 0 0 0 4px rgba(182,62,46,.13); }
.home-kicker { color: #8a3528; }
.palace-home .home-title-ink { color: #713026; text-shadow: 0 2px 0 rgba(255,240,190,.78); }
.palace-home .home-title-teal { color: #275d55; text-shadow: 0 2px 0 rgba(255,244,199,.68); }
.palace-home .home-subtitle { color: #664b35; }
.palace-home .doctor-note {
  padding: 17px 16px;
  border-color: rgba(139, 76, 39, .38);
  background: rgba(255, 244, 207, .5);
  box-shadow: inset 0 0 22px rgba(255,255,255,.22);
}
.palace-home .doctor-note p { color: #49392b; }
.palace-home .note-seal { color: #fff0c5; border-color: #9e3a2b; background: rgba(143, 45, 35, .9); }
.home-start-cta { color: #743126; }
.cta-rule { background: linear-gradient(90deg, transparent, rgba(135,56,38,.68)); }
.palace-home .home-small { color: rgba(73, 54, 39, .7); }
.stage:has(.palace-home) .topbar { color: #603b27; text-shadow: 0 1px rgba(255,247,216,.7); }
.stage:has(.palace-home) .edition-mark { color: rgba(85,60,40,.78); }

.imperial-gate { filter: drop-shadow(0 24px 28px rgba(95, 50, 25, .28)) brightness(1.08); }
.gate-opening { background: #d9a858; box-shadow: inset 0 0 35px rgba(83, 35, 17, .22); }
.inner-hall { filter: brightness(1.38) saturate(.86) contrast(.88); }
.inner-hall::after {
  background: linear-gradient(180deg, rgba(255,244,196,.17), transparent 58%, rgba(117,58,26,.09));
  box-shadow: inset 0 0 22px rgba(255, 236, 175, .24);
}
.gate-door { filter: brightness(1.13) saturate(.94); box-shadow: inset 0 0 0 3px #cf9a4a, inset 0 0 24px rgba(92,35,20,.22); }
.gate-beam { filter: brightness(1.15) saturate(.9); }
.gate-threshold { filter: brightness(1.28); }
.palace-home.opening .gate-door-left,
.palace-home.opening .gate-door-right { filter: brightness(.92) saturate(.9); }

.gender-rite {
  background: radial-gradient(circle at 50% 45%, rgba(255, 237, 181, .36), transparent 45%), rgba(80, 113, 104, .38);
  backdrop-filter: blur(4px) saturate(.92);
}
.gender-rite-scroll { box-shadow: 0 26px 70px rgba(75,45,24,.3), inset 0 0 0 9px rgba(104,47,25,.08), inset 0 0 70px rgba(255,240,191,.28); }

.part-cinematic { color: #fff0c6; background: #ddba79; }
.part-cinematic-scene { filter: brightness(1.3) saturate(.88) contrast(.9); }
.part-cinematic-vignette {
  background:
    linear-gradient(180deg, rgba(255,239,187,.12), transparent 38% 72%, rgba(66,29,17,.38)),
    linear-gradient(90deg, rgba(73,35,20,.28), transparent 24% 76%, rgba(73,35,20,.28));
  box-shadow: inset 0 0 70px rgba(91, 48, 22, .18);
}
.part-cinematic-copy { text-shadow: 0 3px 15px rgba(48,23,13,.82); }
.part-cinematic-copy em { color: #fff0c4; background: rgba(105,43,28,.72); }

.stage:not(:has(.palace-home)) {
  background-color: #edd9aa;
  background-image:
    linear-gradient(90deg, rgba(154,61,43,.76) 0 25px, transparent 25px calc(100% - 25px), rgba(154,61,43,.76) calc(100% - 25px)),
    radial-gradient(ellipse at 50% 32%, rgba(255,253,233,.96), rgba(235,211,163,.7) 72%),
    repeating-linear-gradient(94deg, rgba(92,61,34,.025) 0 1px, transparent 1px 7px);
}
.stage:not(:has(.palace-home))::before { border-color: rgba(142,77,42,.42); box-shadow: inset 0 0 0 4px rgba(235,196,112,.16), inset 0 0 50px rgba(139,87,41,.08); }
.stage:not(:has(.palace-home)) .topbar {
  color: #fff1c8;
  background: linear-gradient(180deg, #397a6d 0, #4a8b7b 76%, #d3aa5e 77%, #a14335 82%, transparent 83%);
  filter: none;
}
.stage:not(:has(.palace-home)) .brand-signature { color: #fff2ce; }
.stage:not(:has(.palace-home)) .brand-signature span { color: rgba(255,244,213,.82); }
.stage:not(:has(.palace-home)) .progress-pill,
.game-limit-pill { color: #fff1c1; background: rgba(114,44,32,.38); }
.game-settings-button { background: linear-gradient(180deg, #ad4b3d, #843229); }
.stage:not(:has(.palace-home)) .opt-chip,
.stage:not(:has(.palace-home)) .btn-option,
.stage:not(:has(.palace-home)) .summary-card,
.stage:not(:has(.palace-home)) .qr-paper,
.stage:not(:has(.palace-home)) .report-summary,
.stage:not(:has(.palace-home)) .report-detail-card,
.stage:not(:has(.palace-home)) .report-taskbar,
.stage:not(:has(.palace-home)) .scan-card,
.stage:not(:has(.palace-home)) .queue-panel { background-color: rgba(255,244,215,.94); box-shadow: 7px 9px 0 rgba(118,70,30,.08), inset 0 0 0 3px rgba(255,253,233,.38); }
.page-part .part-side { background: rgba(65, 124, 108, .94); }

.page-buff,
.page-buff.glow {
  background:
    radial-gradient(circle at 50% 33%, rgba(255,255,225,.98), transparent 39%),
    linear-gradient(180deg, #70b6bf 0 17%, #f0d699 17% 100%);
}
.pause-overlay {
  background: radial-gradient(circle at 50% 44%, rgba(242,220,166,.48), rgba(54,91,82,.62));
  backdrop-filter: blur(5px) saturate(.88);
}

@media (prefers-reduced-motion: reduce) {
  .palace-night span { animation: none; }
}

/* D02 · 晴日早朝喜剧场：男女帝王自然含笑，殿内以晨光代替肃穆烛夜。 */
.part-cinematic {
  background: #f0d79b;
}
.part-cinematic-scene {
  filter: brightness(1.48) saturate(.78) contrast(.82) sepia(.04);
  transform: scale(1.012);
}
.part-cinematic-daylight {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: .82;
  background:
    linear-gradient(108deg, rgba(255,252,220,.66) 0 9%, transparent 28%),
    linear-gradient(252deg, rgba(255,249,210,.56) 0 8%, transparent 26%),
    radial-gradient(ellipse at 50% 10%, rgba(255,242,171,.3), transparent 42%);
  mix-blend-mode: screen;
}
.part-cinematic-vignette {
  background:
    linear-gradient(180deg, rgba(255,248,213,.08), transparent 48% 76%, rgba(105,55,28,.22)),
    linear-gradient(90deg, rgba(112,63,32,.12), transparent 17% 83%, rgba(112,63,32,.12));
  box-shadow: inset 0 0 38px rgba(132, 75, 35, .1);
}

.part-cinematic-banter {
  position: absolute;
  top: 128px;
  right: 92px;
  z-index: 6;
  display: flex;
  width: 330px;
  min-height: 112px;
  box-sizing: border-box;
  padding: 20px 28px;
  flex-direction: column;
  justify-content: center;
  color: #5c3324;
  text-align: center;
  background:
    repeating-linear-gradient(98deg, rgba(89,54,30,.025) 0 1px, transparent 1px 7px),
    rgba(255,247,216,.93);
  border: 2px solid rgba(139,82,42,.66);
  border-radius: 48% 45% 44% 46%;
  box-shadow: 0 9px 22px rgba(89,49,25,.14), inset 0 0 18px rgba(255,255,255,.5);
  transform: rotate(1.4deg);
  animation: imperial-banter-float 2.8s ease-in-out infinite alternate;
}
.part-cinematic-banter::after {
  content: '';
  position: absolute;
  left: 28px;
  bottom: -23px;
  width: 32px;
  height: 28px;
  background: rgba(255,247,216,.93);
  border-left: 2px solid rgba(139,82,42,.66);
  clip-path: polygon(0 0, 100% 0, 0 100%);
  transform: rotate(13deg);
}
.part-cinematic-banter small {
  margin-bottom: 7px;
  color: #a13b2d;
  font: 700 14px/1.2 STKaiti, KaiTi, serif;
  letter-spacing: .3em;
}
.part-cinematic-banter strong {
  font: 700 20px/1.55 STKaiti, KaiTi, serif;
  letter-spacing: .05em;
}
.part-cinematic-banter.is-empress { right: 88px; transform: rotate(-1.2deg); }
@keyframes imperial-banter-float { to { translate: 0 -7px; } }

.part-cinematic-copy {
  padding: 18px 24px 17px;
  background: linear-gradient(90deg, rgba(83,40,24,.7), rgba(83,40,24,.36), transparent);
  border-left: 4px solid #dfb65f;
  text-shadow: 0 2px 10px rgba(43,19,11,.7);
}
.part-cinematic-copy small { color: #ffe5a5; }
.part-cinematic-copy strong { font-size: 39px; }
.part-cinematic-copy em { background: rgba(143,57,39,.82); }
.part-cinematic-pulse {
  border-color: rgba(255,226,137,.58);
  box-shadow: 0 0 0 0 rgba(255,219,115,.2), inset 0 0 50px rgba(255,239,178,.1);
}
.part-cinematic.is-transforming .part-cinematic-daylight,
.part-cinematic.is-transforming .part-cinematic-banter { opacity: 0; transition: opacity .38s ease; }

@media (prefers-reduced-motion: reduce) {
  .part-cinematic-banter { animation: none; }
}

/* D03 · 晴日诙谐太医院宫门：翘角琉璃瓦、笑狮、宫灯与养生竖联。 */
.imperial-gate {
  right: 76px;
  top: 58px;
  width: 810px;
  height: 814px;
  filter: drop-shadow(0 25px 27px rgba(98,55,25,.25)) brightness(1.08);
}
.imperial-gate::before {
  content: '';
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 43px;
  z-index: 0;
  height: 560px;
  background:
    linear-gradient(90deg,#f1d59a 0 7%,#a63f31 7% 10%,#f8e6b8 10% 90%,#a63f31 90% 93%,#f1d59a 93%),
    #f4dfac;
  border: 3px solid #9c5a32;
  box-shadow: inset 0 0 0 8px rgba(255,249,219,.3);
}
.gate-roof-ridge {
  position: absolute;
  left: 29px;
  right: 29px;
  top: 5px;
  z-index: 12;
  height: 84px;
  border-top: 8px solid #d5a84f;
  border-radius: 50% 50% 12% 12%;
  background:
    repeating-linear-gradient(90deg, rgba(255,238,163,.24) 0 3px, transparent 3px 22px),
    linear-gradient(180deg,#35756a 0,#1d554f 58%,#17423f 100%);
  box-shadow: inset 0 -9px 0 #c58f3e, 0 9px 0 #87362b, 0 16px 22px rgba(77,45,25,.18);
  clip-path: polygon(7% 8%,93% 8%,100% 54%,91% 66%,74% 58%,62% 75%,38% 75%,26% 58%,9% 66%,0 54%);
}
.gate-roof-ridge::before,
.gate-roof-ridge::after {
  content: '';
  position: absolute;
  top: 14px;
  width: 88px;
  height: 24px;
  border-top: 6px solid #e2b95f;
  border-radius: 50%;
}
.gate-roof-ridge::before { left: 13px; transform: rotate(-13deg); }
.gate-roof-ridge::after { right: 13px; transform: rotate(13deg); }
.gate-roof-ridge i {
  position: absolute;
  top: -21px;
  width: 22px;
  height: 29px;
  border: 3px solid #8e5a29;
  border-radius: 55% 55% 45% 45%;
  background: #e0b356;
  transform-origin: 50% 100%;
}
.gate-roof-ridge i:nth-child(1){left:13%;transform:rotate(-12deg)}.gate-roof-ridge i:nth-child(2){left:30%;transform:rotate(-5deg)}.gate-roof-ridge i:nth-child(3){left:49%;height:36px;top:-28px}.gate-roof-ridge i:nth-child(4){right:30%;transform:rotate(5deg)}.gate-roof-ridge i:nth-child(5){right:13%;transform:rotate(12deg)}

.gate-beam {
  left: 50px;
  right: 50px;
  top: 80px;
  height: 133px;
  border-color: #6f2a20;
  background:
    repeating-linear-gradient(90deg, rgba(255,225,141,.08) 0 2px, transparent 2px 31px),
    linear-gradient(#be5542,#8f3329);
  box-shadow: inset 0 -13px rgba(102,36,29,.18),0 9px 0 #d3a14b;
}
.gate-beam::before {
  left: -82px;
  right: -82px;
  top: -34px;
  height: 66px;
  background: linear-gradient(180deg,#397c70,#1f554e);
  border-bottom-color:#e0b65d;
  clip-path: polygon(0 52%,8% 35%,20% 39%,29% 13%,71% 13%,80% 39%,92% 35%,100% 52%,92% 72%,8% 72%);
}
.gate-plaque {
  top: 98px;
  left: 274px;
  width: 262px;
  height: 99px;
  background: linear-gradient(150deg,#28665e,#174e49);
  color: #ffe296;
  border-color: #e0b45b;
  transform: rotate(-1.4deg);
  box-shadow: 0 8px 0 rgba(89,42,24,.25),inset 0 0 0 3px rgba(255,239,172,.14);
  animation: gate-plaque-bob 4.5s ease-in-out infinite alternate;
}
.gate-plaque strong { font-size: 33px; text-shadow: 0 2px #6b3a22; }
.gate-day-banner {
  position: absolute;
  left: 50%;
  top: 205px;
  z-index: 11;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 7px 18px 8px;
  color: #7c3025;
  background: #f8e8b9;
  border: 2px solid #b77538;
  box-shadow: 3px 5px 0 rgba(96,51,28,.13);
  font-family: STKaiti,KaiTi,serif;
  transform: translateX(-50%) rotate(1deg);
  white-space: nowrap;
}
.gate-day-banner strong{font-size:18px;letter-spacing:.13em}.gate-day-banner small{padding-left:12px;border-left:1px solid #c6914e;font-size:13px;letter-spacing:.1em}

.gate-opening {
  left: 121px;
  right: 121px;
  top: 211px;
  bottom: 75px;
  border: 12px solid #7c3025;
  border-top-width: 18px;
  background:#edc875;
  box-shadow:inset 0 0 30px rgba(83,35,17,.18),0 0 0 5px #d3a451;
}
.gate-door {
  top: 229px;
  bottom: 91px;
  width: 269px;
  border: 8px solid #7b2c23;
  background-color:#b94737;
  background-image:
    radial-gradient(circle,#f2c763 0 5px,#9b602b 6px 7px,transparent 8px),
    linear-gradient(90deg,rgba(255,239,179,.12),transparent 22%,rgba(111,35,28,.16) 23% 25%,transparent 26% 74%,rgba(111,35,28,.14) 75% 77%,transparent 78%),
    linear-gradient(180deg,#c85441,#a33b31);
  background-size:58px 58px,100% 100%,100% 100%;
  box-shadow:inset 0 0 0 4px #e1ad51,inset 0 0 28px rgba(92,35,20,.16),0 8px 13px rgba(78,36,24,.18);
}
.gate-door-left { left:129px; }.gate-door-right { right:129px; }
.gate-door::before { inset:14px;border-color:rgba(255,219,125,.7);border-width:3px; }
.door-ring {
  width:51px;height:51px;border-color:#f0c45e;background:rgba(144,51,38,.5);
  box-shadow:0 4px 8px rgba(81,37,22,.28),inset 0 0 0 4px rgba(255,236,165,.12);
  animation: gate-ring-chuckle 2.8s ease-in-out infinite;
}
.gate-door-left .door-ring{right:19px}.gate-door-right .door-ring{left:19px;animation-delay:.25s}
.door-couplet {
  position:absolute;
  top:72px;
  bottom:70px;
  display:flex;
  align-items:center;
  justify-content:center;
  width:37px;
  padding:8px 2px;
  color:#703026;
  background:linear-gradient(90deg,#f1d17e,#ffe8a7,#d8a951);
  border:2px solid #8d4c2a;
  box-shadow:3px 4px 0 rgba(85,40,23,.15);
  font:700 18px/1.25 STKaiti,KaiTi,serif;
  letter-spacing:.12em;
  writing-mode:vertical-rl;
}
.gate-door-left .door-couplet{left:20px}.gate-door-right .door-couplet{right:20px}
.gate-threshold{left:82px;right:82px;bottom:43px;height:55px;background:linear-gradient(#dbc18f,#80674d);border-top-color:#f0d6a0;filter:none}

.gate-lantern {
  position:absolute;
  top:190px;
  z-index:15;
  display:grid;
  place-items:center;
  width:55px;
  height:78px;
  color:#ffeab0;
  border:4px solid #703027;
  border-radius:24px 24px 16px 16px;
  background:linear-gradient(90deg,#a33a2f,#d45e47 50%,#9a332b);
  box-shadow:inset 0 0 0 4px rgba(255,207,102,.25),0 7px 10px rgba(82,39,22,.18);
  font:700 25px/1 STKaiti,KaiTi,serif;
  transform-origin:50% -35px;
  animation: gate-lantern-sway 3.4s ease-in-out infinite alternate;
}
.gate-lantern::before{content:'';position:absolute;left:50%;top:-39px;width:2px;height:38px;background:#6e3024}.gate-lantern::after{content:'';position:absolute;left:50%;bottom:-25px;width:4px;height:24px;background:#d2a247;box-shadow:-8px 2px #b84235,8px 2px #b84235}
.gate-lantern-left{left:41px}.gate-lantern-right{right:41px;animation-direction:alternate-reverse}

.gate-smile-lion {
  position:absolute;
  bottom:61px;
  z-index:16;
  width:73px;
  height:66px;
  border:3px solid #87512c;
  border-radius:48% 48% 38% 38%;
  background:radial-gradient(circle at 36% 38%,#443328 0 3px,transparent 4px),radial-gradient(circle at 64% 38%,#443328 0 3px,transparent 4px),linear-gradient(#f0cf7d,#c99a4d);
  box-shadow:inset 0 0 0 6px rgba(255,240,177,.24),0 7px 9px rgba(77,42,24,.14);
  animation: gate-lion-nod 3s ease-in-out infinite alternate;
}
.gate-smile-lion::before,.gate-smile-lion::after{content:'';position:absolute;top:-10px;width:25px;height:25px;border:3px solid #87512c;border-radius:50%;background:#ddb866;z-index:-1}.gate-smile-lion::before{left:-8px}.gate-smile-lion::after{right:-8px}
.gate-smile-lion i{position:absolute;left:25px;top:31px;width:22px;height:10px;border-bottom:3px solid #7f3a29;border-radius:0 0 50% 50%}.gate-smile-lion b{position:absolute;left:50%;bottom:-23px;color:#7b3025;font:700 15px STKaiti,KaiTi,serif;transform:translateX(-50%)}
.gate-smile-lion-left{left:22px}.gate-smile-lion-right{right:22px;animation-delay:.35s}

.palace-home.pressed:not(.opening) .door-ring { transform:translateY(5px) rotate(9deg); }
.palace-home.opening .gate-lantern,.palace-home.opening .gate-smile-lion,.palace-home.opening .gate-day-banner{opacity:0;transition:opacity .2s ease}
@keyframes gate-ring-chuckle{0%,100%{transform:rotate(-3deg)}50%{transform:rotate(5deg) translateY(2px)}}
@keyframes gate-lantern-sway{to{transform:rotate(4deg)}}
@keyframes gate-lion-nod{to{transform:translateY(3px) rotate(2deg)}}
@keyframes gate-plaque-bob{to{transform:rotate(.7deg) translateY(2px)}}

@media (prefers-reduced-motion:reduce){.gate-plaque,.door-ring,.gate-lantern,.gate-smile-lion{animation:none}}

/* U09-R2 · 完整矢量骨架动作，替代静态人物图片切片。 */
.exercise-rig{display:block;width:100%;height:100%;overflow:visible;filter:drop-shadow(0 7px 5px rgba(63,39,24,.18))}.exercise-rig path,.exercise-rig ellipse{vector-effect:non-scaling-stroke}.rig-shadow{fill:rgba(74,43,25,.13)}.rig-legs{fill:#ead9af;stroke:#633a2d;stroke-width:3}.rig-shoe{fill:#6f3028}.rig-left-arm,.rig-right-arm,.rig-core,.rig-head{transform-box:view-box}.rig-left-arm{transform-origin:124px 166px;animation:rig-left-arm-five 8s cubic-bezier(.42,0,.3,1) infinite}.rig-right-arm{transform-origin:196px 166px;animation:rig-right-arm-five 8s cubic-bezier(.42,0,.3,1) infinite}.rig-core{transform-origin:160px 590px;animation:rig-core-five 8s cubic-bezier(.42,0,.3,1) infinite}.rig-head{transform-origin:160px 148px;animation:rig-head-five 8s ease-in-out infinite}.rig-sleeve,.rig-torso,.rig-lower-robe{fill:#efe1bd;stroke:#6f3a2d;stroke-width:4;stroke-linejoin:round}.exercise-female .rig-sleeve,.exercise-female .rig-torso,.exercise-female .rig-lower-robe{fill:#f2ddc2}.rig-hand,.rig-face,.rig-neck{fill:#e8c691;stroke:#6e3d2e;stroke-width:3}.rig-hair{fill:#292721;stroke:#61362a;stroke-width:3}.rig-collar{fill:#9b4135;stroke:#67352b;stroke-width:3}.exercise-female .rig-collar{fill:#a94e59}.rig-sash{fill:#2f6c62;stroke:#67362c;stroke-width:4}.rig-robe-line,.rig-brow,.rig-eyes,.rig-smile{fill:none;stroke:#744034;stroke-width:3;stroke-linecap:round}.rig-beard{fill:#312720;stroke:#674034;stroke-width:2}.rig-crown{fill:#273f39;stroke:#b88840;stroke-width:4}.rig-crown path+path,.rig-crown circle{fill:#ddb85f;stroke:#7f522a;stroke-width:2}.rig-headdress{fill:#d5a74e;stroke:#80402d;stroke-width:4}.rig-headdress circle{fill:#a43d38}.rig-female-only{display:none}.exercise-female .rig-female-only{display:block}.exercise-female .rig-male-only{display:none}
@keyframes rig-left-arm-five{0%,16%,100%{transform:rotate(0)}20%,36%{transform:rotate(72deg)}40%,56%{transform:rotate(151deg)}60%,76%{transform:rotate(25deg)}82%,96%{transform:rotate(0)}}
@keyframes rig-right-arm-five{0%,16%,100%{transform:rotate(0)}20%,36%{transform:rotate(-72deg)}40%,56%{transform:rotate(-25deg)}60%,76%{transform:rotate(-151deg)}82%,96%{transform:rotate(0)}}
@keyframes rig-core-five{0%,16%,82%,100%{transform:translateY(0) rotate(0) scale(1)}20%,36%{transform:translateY(-8px) scale(1.015)}40%,56%{transform:translate(13px,-4px) rotate(5deg)}60%,76%{transform:translate(-13px,-4px) rotate(-5deg)}}
@keyframes rig-head-five{0%,16%,82%,100%{transform:rotate(0)}20%,36%{transform:translateY(-2px)}40%,56%{transform:rotate(4deg)}60%,76%{transform:rotate(-4deg)}}
.exercise-rig+.motion-arc-left{animation-duration:8s;animation-iteration-count:infinite}.exercise-rig+.motion-arc-left+.motion-arc-right{animation-duration:8s;animation-iteration-count:infinite}.exercise-forms span{animation-duration:8s!important;animation-iteration-count:infinite!important}
.reduced-motion .exercise-rig .rig-left-arm,.reduced-motion .exercise-rig .rig-right-arm,.reduced-motion .exercise-rig .rig-core,.reduced-motion .exercise-rig .rig-head{animation:none}

/* U09-R3 · Seedance 图生视频取代骨架拼接动画。 */
.imperial-exercise:has(.exercise-video){
  width:min(752px,76vw);
  height:min(560px,61vh);
  background:#f1dfb8;
}
.exercise-video{
  position:absolute;
  inset:0;
  z-index:1;
  width:100%;
  height:100%;
  display:none;
  object-fit:contain;
  background:#f1dfb8;
}
.exercise-male .exercise-video-male,.exercise-female .exercise-video-female{display:block}
.imperial-exercise:has(.exercise-video) .exercise-demo-badge{z-index:3}
.page-task:has(.exercise-video){padding-top:96px}
.page-task:has(.exercise-video) .page-title{font-size:36px}
.page-task:has(.exercise-video) .page-intro{font-size:16px}

/* U06-R5 · 扫码问诊页增大全部说明字号，便于大屏远距离阅读。 */
.page-subjective .page-intro{max-width:1280px;margin-bottom:18px;font-size:21px;line-height:1.65;letter-spacing:.045em}
.page-subjective .tag-chip{padding:10px 18px;font-size:19px;letter-spacing:.08em}
.page-subjective .paper-eyebrow{font-size:27px;line-height:1.35;letter-spacing:.11em}
.page-subjective .mobile-entry-link{max-width:360px;padding:8px 14px;font-size:19px;line-height:1.45}
.page-subjective .qr-fixed-note{margin-top:16px;font-size:17px;line-height:1.55;letter-spacing:.045em}
.page-subjective .subjective-state{font-size:21px;line-height:1.45}
.page-subjective .subjective-copy{padding:18px 22px;font-size:21px;line-height:1.72;letter-spacing:.04em}
.page-subjective .subjective-deadline{font-size:18px;line-height:1.6}
.page-subjective .subjective-actions .edit-link{font-size:20px;line-height:1.45}
.page-subjective .subjective-note{padding-top:15px;font-size:17px;line-height:1.55}

/* U07-R4 · 将一页完整诊单预览真正接入游戏结果页。 */
.page-report.report-sheet-v2{
  display:block;
  overflow:hidden;
  padding:112px 42px 30px;
  background:radial-gradient(circle at 50% 18%,rgba(255,249,221,.8),rgba(232,202,145,.65) 78%)!important;
}
.live-report-sheet{
  position:relative;
  height:754px;
  padding:16px 22px 14px;
  border:2px solid #995838;
  color:#3e3026;
  background:linear-gradient(90deg,rgba(130,50,36,.055),transparent 7% 93%,rgba(130,50,36,.055)),repeating-linear-gradient(96deg,rgba(79,50,28,.026) 0 1px,transparent 1px 8px),rgba(250,237,200,.96);
  box-shadow:10px 12px 0 rgba(76,43,25,.12),inset 0 0 0 7px rgba(255,250,227,.35);
}
.live-report-sheet:before,.live-report-sheet:after{content:'';position:absolute;width:28px;height:28px;pointer-events:none}
.live-report-sheet:before{left:10px;top:10px;border-left:4px solid #9a4931;border-top:4px solid #9a4931}
.live-report-sheet:after{right:10px;bottom:10px;border-right:4px solid #9a4931;border-bottom:4px solid #9a4931}
.live-report-head{display:grid;grid-template-columns:1fr auto;align-items:end;height:67px;padding:0 7px 10px;border-bottom:2px solid rgba(127,72,36,.34)}
.live-report-head p,.live-report-label{margin:0 0 4px;color:#94342a;font:700 13px/1.25 STKaiti,KaiTi,serif;letter-spacing:.22em}
.live-report-head h2{margin:0;color:#27483e;font:700 32px/1.1 STKaiti,KaiTi,serif;letter-spacing:.1em}
.live-report-stamp{display:grid;width:78px;height:58px;place-items:center;color:#9b3028;border:3px double #9b3028;font:700 18px/1.1 STKaiti,KaiTi,serif;text-align:center;transform:rotate(-3deg)}
.live-report-meta{display:flex;height:57px;margin-top:9px;border:1px solid rgba(127,78,39,.4);background:rgba(255,250,227,.55);overflow:hidden}
.live-report-meta>div{flex:1;min-width:0;padding:7px 14px;border-right:1px solid rgba(127,78,39,.25)}
.live-report-meta>div:last-child{border-right:0}.live-report-meta small{display:block;color:#846548;font-size:11px}.live-report-meta strong{display:block;margin-top:2px;overflow:hidden;color:#49352a;font:700 15px/1.25 STKaiti,KaiTi,serif;white-space:nowrap;text-overflow:ellipsis}
.live-report-main{display:grid;grid-template-columns:1.03fr 2.08fr 270px;gap:11px;height:424px;margin-top:10px}
.live-report-direction,.live-report-save{min-width:0;padding:14px 16px;border:1px solid rgba(126,78,39,.42);background:rgba(255,249,223,.58);box-shadow:inset 0 0 0 3px rgba(255,255,255,.25);overflow:hidden}
.live-report-direction>h3{margin:0;color:#28473e;font:700 24px/1.24 STKaiti,KaiTi,serif}
.live-report-soft-tag{display:inline-block;margin:8px 0 3px;padding:3px 8px;color:#7b3a2d;border:1px solid #b78549;background:#f3dfad;font-size:11px}
.live-report-direction>p:not(.live-report-label):not(.inline-error){margin:7px 0 0;color:#5e4938;font-size:13px;line-height:1.48}
.live-report-detail{margin-top:10px;padding:9px 10px;border-left:4px solid #a13b30;background:rgba(226,191,126,.28)}
.live-report-detail strong{display:block;color:#7e3028;font:700 15px STKaiti,KaiTi,serif}.live-report-detail p{margin:4px 0 0;color:#584235;font-size:12px;line-height:1.46}
.live-report-direction .retry-link{margin-top:7px;font-size:12px}.live-report-direction .inline-error{margin:7px 0 0;font-size:11px}
.live-report-advice{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr 1fr;gap:9px;min-width:0}
.live-report-advice article{display:grid;grid-template-columns:40px minmax(0,1fr);gap:9px;min-width:0;padding:11px 12px;border:1px solid rgba(137,89,43,.33);background:linear-gradient(115deg,rgba(235,207,151,.64),rgba(255,250,226,.62));overflow:hidden}
.live-report-advice article>b{display:grid;place-items:center;color:#fff1c9;background:#8e342a;font:700 17px STKaiti,KaiTi,serif;writing-mode:vertical-rl;letter-spacing:.1em}
.live-report-advice h3{margin:0;color:#2c493f;font:700 18px/1.22 STKaiti,KaiTi,serif}.live-report-advice p{margin:5px 0 0;color:#5b4738;font-size:12px;line-height:1.47}
.live-report-save{display:flex;align-items:center;flex-direction:column;text-align:center;background:linear-gradient(180deg,rgba(255,250,228,.84),rgba(230,199,137,.5))}
.live-report-save h3{margin:0;color:#2b4a40;font:700 21px STKaiti,KaiTi,serif}.live-report-save>p:not(.live-report-label){margin:5px 0 8px;color:#76543c;font-size:11px;line-height:1.4}
.live-report-qr{display:grid;width:174px;height:174px;place-items:center;padding:7px;border:1px solid #9d6b36;background:#fffef7;box-shadow:0 7px 14px rgba(75,44,25,.12)}.live-report-qr img{display:block;width:158px;height:158px}.live-report-qr-loading{color:#846548;font:700 16px STKaiti,KaiTi,serif}
.live-report-save>a{margin:6px 0;color:#812a22;font-size:11px}.live-report-exercise{width:100%;min-height:43px;margin-top:auto;padding:8px 10px;font-size:15px}.live-report-finish{margin-top:7px;color:#743328;border:0;border-bottom:1px solid rgba(116,51,40,.5);background:transparent;font:700 12px STKaiti,KaiTi,serif;cursor:pointer}
.live-report-bottom{display:grid;grid-template-columns:1.05fr 2fr;gap:11px;height:100px;margin-top:10px}.live-report-bottom>div,.live-report-bottom>aside{display:flex;align-items:center;padding:11px 14px;border:1px solid rgba(129,78,38,.42);background:rgba(245,225,180,.68);overflow:hidden}.live-report-bottom>div>strong{flex:0 0 auto;margin-right:10px;color:#8c3228;font:700 17px STKaiti,KaiTi,serif}.live-report-bottom p{margin:0;color:#5a4536;font-size:12px;line-height:1.5}.live-report-bottom>aside{border:2px double #9b3028;background:rgba(148,48,39,.07)}.live-report-bottom aside i{display:grid;flex:0 0 50px;height:50px;margin-right:11px;place-items:center;color:#922f28;border:2px solid #922f28;font:700 29px STKaiti,KaiTi,serif;font-style:normal}.live-report-bottom aside strong{color:#822b24}

/* V38 · 去掉顶部绿色横条，让每页宫廷底图直铺到屏幕顶端。 */
.stage .topbar,
.stage:not(:has(.palace-home)) .topbar,
.stage:has(.palace-home) .topbar {
  height: auto;
  min-height: 78px;
  padding-top: 20px;
  background: transparent;
  filter: none;
}
.stage .topbar::before,
.stage .topbar::after,
.stage:not(:has(.palace-home)) .topbar::before,
.stage:not(:has(.palace-home)) .topbar::after {
  display: none;
  content: none;
}
.stage:not(:has(.palace-home)) .brand-signature {
  color: #6f3026;
  text-shadow: 0 1px 5px rgba(255,246,211,.92);
}
.stage:not(:has(.palace-home)) .brand-signature span { color: #705c43; }
.stage:not(:has(.palace-home)) .progress-pill,
.stage:not(:has(.palace-home)) .game-limit-pill {
  color: #fff1c7;
  border-color: rgba(151,80,46,.72);
  background: rgba(112,43,32,.82);
  box-shadow: 0 3px 10px rgba(70,39,23,.14), inset 0 0 0 2px rgba(255,238,188,.12);
}

/* V39 · 宫门屋顶只保留一层完整琉璃檐，移除错位悬空的重复瓦顶。 */
.imperial-gate .gate-roof-ridge { display: none; }
.imperial-gate .gate-beam::before {
  left: -74px;
  right: -74px;
  top: -49px;
  height: 76px;
  border-bottom: 7px solid #e0b65d;
  background:
    repeating-linear-gradient(96deg, rgba(255,235,158,.16) 0 3px, transparent 3px 34px),
    linear-gradient(180deg,#4a9181 0,#34796e 48%,#1f574f 100%);
  clip-path: polygon(0 66%,7% 42%,23% 27%,39% 17%,61% 17%,77% 27%,93% 42%,100% 66%,91% 80%,9% 80%);
  filter: drop-shadow(0 7px 5px rgba(86,45,25,.2));
}

/* V40 · 内页彻底取消顶栏色块与占位，仅保留右上角悬浮游戏控件。 */
.stage:not(:has(.palace-home)) .topbar {
  top: 18px;
  left: 28px;
  right: 28px;
  width: auto;
  height: 54px;
  min-height: 0;
  padding: 0;
  border: 0;
  outline: 0;
  background: none !important;
  box-shadow: none !important;
  backdrop-filter: none;
}
.stage:not(:has(.palace-home)) .topbar .app-logo { display: none; }
.stage:not(:has(.palace-home)) .topbar-actions { margin-left: auto; }
.stage:not(:has(.palace-home)) .page-part {
  background:
    linear-gradient(90deg, rgba(49,19,14,.82) 0 4.5%, transparent 4.5% 95.5%, rgba(49,19,14,.82) 95.5%),
    radial-gradient(ellipse at 50% 25%, rgba(255,249,222,.98), rgba(231,207,160,.94) 76%);
}
.stage:not(:has(.palace-home)) .page-part:not(.part-intro-active) {
  background:
    linear-gradient(180deg, rgba(25,12,8,.26), rgba(25,12,8,.48)),
    url('/js/assets/emperor-bedchamber-v1.webp?v=20261015') center 44% / cover no-repeat;
}
.stage:not(:has(.palace-home)) .page-task {
  background:
    radial-gradient(ellipse at 50% 55%, rgba(255,246,211,.86), transparent 48%),
    linear-gradient(180deg, #eddaae 0%, #e6c98e 100%);
}

/* V42 · 结尾两页取消顶部蓝色分区，统一为连续暖色宫廷绢本。 */
.stage .page-task,
.stage .page-buff,
.stage .page-buff.glow {
  background:
    radial-gradient(circle at 50% 35%, rgba(255,251,220,.96), transparent 43%),
    linear-gradient(180deg, #f0dca9 0%, #dfbd79 100%) !important;
}
.stage:has(.page-task) .topbar,
.stage:has(.page-buff) .topbar {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}
