/* 謎漫工作室 MIST STUDIO：霧面紙色 + 暗房夜色，黃銅與燈光作為點綴 */
:root {
  --bg: #ECEDE8;
  --surface: #F6F6F2;
  --surface-2: #DFE1DA;
  --ink: #17191B;
  --muted: #565B5A;
  --brass: #86673A;
  --lamp: #E0A95A;
  --night: #15120F;
  --night-ink: #EDE6D8;
  --night-muted: #B3AA9A;
  --line: rgba(23, 25, 27, .14);
  --ok: #2F6B45;
  --full: #8B3A2E;
  --paused: #6F716C;
  --focus: #B0833F;
  --serif: "Noto Serif TC", "Songti TC", "PMingLiU", serif;
  --sans: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  --latin: "Cinzel", "Trajan Pro", Georgia, serif;
  --mono: var(--sans);
  --glass: rgba(220, 222, 214, .94);
  --haze: rgba(236, 237, 232, .8);
  --mist: rgba(246, 246, 242, .85);
  --strip: rgba(246, 246, 242, .7);
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1160px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121412; --surface: #1A1D1B; --surface-2: #242824; --ink: #E7E6DF; --muted: #A2A6A1;
    --brass: #D2A866; --line: rgba(231, 230, 223, .14); --ok: #7FC195; --full: #E38B7B; --paused: #9A9C96;
    --night: #0C0A08; --glass: rgba(18, 20, 18, .88); --haze: rgba(18, 20, 18, .8); --mist: rgba(26, 29, 27, .85); --strip: rgba(26, 29, 27, .7); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #121412; --surface: #1A1D1B; --surface-2: #242824; --ink: #E7E6DF; --muted: #A2A6A1;
  --brass: #D2A866; --line: rgba(231, 230, 223, .14); --ok: #7FC195; --full: #E38B7B; --paused: #9A9C96;
  --night: #0C0A08; --glass: rgba(18, 20, 18, .88); --haze: rgba(18, 20, 18, .8); --mist: rgba(26, 29, 27, .85); --strip: rgba(26, 29, 27, .7); color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.8 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 900; line-height: 1.3; text-wrap: balance; margin: 0; }
p { margin: 0; }
.wrap { max-width: var(--max); margin: 0 auto; padding-inline: var(--gutter); }
.eyebrow { font: 600 12px/1.4 var(--latin); letter-spacing: .28em; text-transform: uppercase; color: var(--brass); }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--surface); padding: 8px 12px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  background: var(--glass);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { width: 34px; height: auto; }
.brand .logo-light { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .brand .logo-ink { display: none; } :root:not([data-theme="light"]) .brand .logo-light { display: block; } }
:root[data-theme="dark"] .brand .logo-ink { display: none; }
:root[data-theme="dark"] .brand .logo-light { display: block; }
.brand-text { display: grid; line-height: 1.2; }
.brand-text b { font: 900 17px/1.2 var(--serif); letter-spacing: .12em; }
.brand-text small { font: 600 10px/1.2 var(--latin); letter-spacing: .3em; color: var(--muted); }
.nav { display: flex; align-items: center; gap: clamp(12px, 2vw, 28px); }
.nav ul { display: flex; gap: clamp(12px, 2vw, 26px); list-style: none; margin: 0; padding: 0; }
.nav ul a { text-decoration: none; font-size: 15px; color: var(--muted); padding: 6px 0; border-bottom: 1px solid transparent; }
.nav ul a:hover, .nav ul a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--brass); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); color: var(--ink); border-radius: 2px; padding: 6px 10px; font: 500 14px/1 var(--sans); cursor: pointer; }
@media (max-width: 820px) {
  .menu-btn { display: inline-flex; }
  .nav ul { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px; }
  .nav.open ul { display: flex; }
  .nav ul a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav .btn { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 24px;
  font: 500 15px/1 var(--sans); letter-spacing: .1em;
  text-decoration: none; cursor: pointer;
  border: 1px solid var(--ink); border-radius: 2px;
  background: var(--ink); color: var(--bg);
  transition: background .2s, color .2s, border-color .2s;
}
.btn:hover { background: var(--brass); border-color: var(--brass); color: #fff; }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { border-color: var(--brass); color: var(--brass); background: transparent; }
.btn.small { min-height: 36px; padding: 0 14px; font-size: 13px; letter-spacing: .06em; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn.lamp { background: var(--lamp); border-color: var(--lamp); color: #1A1206; }
.btn.lamp:hover { background: #EDBD76; border-color: #EDBD76; }

/* ---------- Page heads & sections ---------- */
.page-head { padding-block: clamp(40px, 7vw, 80px) clamp(24px, 4vw, 40px); border-bottom: 1px solid var(--line); }
.page-head h1 { font-size: clamp(32px, 5vw, 52px); margin-top: 10px; letter-spacing: .04em; }
.page-head p.lede { margin-top: 14px; color: var(--muted); max-width: 60ch; }
.section { padding-block: clamp(48px, 8vw, 96px); }
.section + .section { border-top: 1px solid var(--line); }
.section-title { display: grid; gap: 10px; margin-bottom: clamp(24px, 4vw, 40px); }
.section-title h2 { font-size: clamp(26px, 3.6vw, 38px); letter-spacing: .04em; }
.prose { max-width: 62ch; display: grid; gap: 1em; }
.prose p { color: var(--ink); }

/* ---------- Home hero ---------- */
.hero { position: relative; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: clamp(40px, 7vw, 88px); }
.hero h1 { font-size: clamp(34px, 4.8vw, 62px); letter-spacing: .06em; line-height: 1.25; }
.hero h1 span { display: block; white-space: nowrap; }
.hero .copy { display: grid; gap: 22px; position: relative; z-index: 2; }
.hero .lede { color: var(--muted); max-width: 30em; }
.hero .cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero .dates { display: flex; flex-wrap: wrap; gap: 10px 24px; font-size: 14px; color: var(--muted); }
.hero .dates b { color: var(--ink); font-weight: 500; }
.keyhole {
  position: relative;
  width: min(100%, 440px);
  max-width: 100%;
  aspect-ratio: 3 / 4;
  justify-self: center;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 400'%3E%3Ccircle cx='150' cy='118' r='112'/%3E%3Cpath d='M92 196 L208 196 L262 400 L38 400 Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 400'%3E%3Ccircle cx='150' cy='118' r='112'/%3E%3Cpath d='M92 196 L208 196 L262 400 L38 400 Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  background: var(--night);
}
.keyhole img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; animation: peer 18s ease-in-out infinite alternate; }
@keyframes peer { from { transform: scale(1.06) translateY(0); } to { transform: scale(1.16) translateY(-3%); } }
.fog { position: absolute; inset: -20%; pointer-events: none; z-index: 1; }
.fog i {
  position: absolute; width: 70%; height: 45%; border-radius: 50%;
  background: radial-gradient(closest-side, var(--haze), transparent);
  filter: blur(18px); opacity: .7;
  animation: drift 26s ease-in-out infinite alternate;
}
.fog i:nth-child(1) { left: 40%; top: 20%; }
.fog i:nth-child(2) { left: 50%; top: 55%; animation-duration: 34s; animation-direction: alternate-reverse; }
.fog i:nth-child(3) { left: -10%; top: 70%; width: 90%; animation-duration: 40s; }
@keyframes drift { from { transform: translateX(-12%); } to { transform: translateX(14%); } }

/* ---------- Theme feature (dark band) ---------- */
.band { background: var(--night); color: var(--night-ink); }
.band .eyebrow { color: var(--lamp); }
.band .muted { color: var(--night-muted); }
.feature.about { grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); align-items: start; }
.feature { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.feature .poster { box-shadow: 0 30px 60px rgba(0, 0, 0, .45); max-width: 420px; width: 100%; }
.feature h2 { font-size: clamp(32px, 4.6vw, 54px); letter-spacing: .08em; margin: 10px 0 16px; }
.feature .hook { font: 600 clamp(17px, 1.9vw, 21px)/1.7 var(--serif); color: var(--night-ink); max-width: 30em; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: rgba(237, 230, 216, .16); border: 1px solid rgba(237, 230, 216, .16); margin: 28px 0; }
.facts div { background: var(--night); padding: 14px 16px; display: grid; gap: 2px; }
.facts dt { font-size: 12px; letter-spacing: .12em; color: var(--night-muted); }
.facts dd { margin: 0; font-size: 17px; font-weight: 500; }
.stars { letter-spacing: .12em; color: var(--lamp); }
.stars .off { color: rgba(237, 230, 216, .25); }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: step; list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.steps li { counter-increment: step; padding: 22px 20px 0 0; display: grid; gap: 8px; align-content: start; }
.steps li::before { content: counter(step, decimal-leading-zero); font: 500 13px/1 var(--mono); color: var(--brass); }
.steps b { font: 700 18px/1.4 var(--serif); }
.steps p { color: var(--muted); font-size: 15px; }

/* ---------- Info grid ---------- */
.info { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 48px); }
.info h3 { font-size: 19px; margin-bottom: 10px; }
.info p, .info li { color: var(--muted); font-size: 15px; }
.info ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.info a { color: var(--ink); text-underline-offset: 3px; }

/* ---------- Definition tables ---------- */
.spec { display: grid; grid-template-columns: max-content 1fr; border-top: 1px solid var(--line); margin: 0; }
.spec dt, .spec dd { padding: 12px 0; border-bottom: 1px solid var(--line); margin: 0; }
.spec dt { color: var(--muted); font-size: 14px; padding-right: 28px; }
.spec dd { font-weight: 500; }

/* ---------- Rules ---------- */
.rules { display: grid; gap: clamp(32px, 5vw, 48px); max-width: 760px; }
.rules h2 { font-size: 22px; margin-bottom: 12px; }
.rules ul { margin: 0; padding-left: 1.2em; display: grid; gap: 8px; }
.rules li::marker { color: var(--brass); }
.callout { border: 1px solid var(--line); background: var(--surface); padding: 18px 20px; display: grid; gap: 6px; }
.callout b { font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: var(--night-muted); padding-block: 48px calc(32px + env(safe-area-inset-bottom, 0px)); font-size: 14px; }
.site-footer .wrap { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.site-footer h2 { font: 700 15px/1.4 var(--sans); color: var(--night-ink); margin-bottom: 10px; letter-spacing: .08em; }
.site-footer a { color: var(--night-ink); text-underline-offset: 3px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.site-footer .foot-brand { display: grid; gap: 12px; }
.site-footer .foot-brand img { width: 44px; }
.social { display: flex; flex-wrap: wrap; gap: 10px; }
.social-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--ink); color: var(--bg); transition: background .2s, transform .2s; }
.social-btn svg { width: 22px; height: 22px; fill: currentColor; }
.social-btn:hover { background: var(--brass); color: #fff; transform: translateY(-2px); }
.social-btn:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }
.site-footer .social { padding-top: 4px; }
.site-footer .social-btn { background: var(--night-ink); color: var(--night); }
.site-footer .social-btn:hover { background: var(--brass); color: #fff; }
.site-footer .legal { grid-column: 1 / -1; border-top: 1px solid rgba(237, 230, 216, .14); padding-top: 18px; font-size: 12px; }

/* ---------- Forms ---------- */
label { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
input, select, textarea {
  font: 400 16px/1.4 var(--sans); color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: 2px;
  padding: 11px 12px; width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--focus); outline-offset: 0; }
.check { display: flex; gap: 10px; align-items: flex-start; color: var(--ink); font-size: 15px; }
.check input { width: 18px; height: 18px; margin-top: 4px; flex: none; accent-color: var(--brass); }
.error { color: var(--full); font-size: 14px; }
.notice { border-left: 3px solid var(--brass); background: var(--surface); padding: 12px 16px; font-size: 15px; }

@media (max-width: 900px) {
  .hero .wrap, .feature, .feature.about { grid-template-columns: minmax(0, 1fr); }
  .keyhole { width: min(78%, 360px); }
  .feature .poster { max-width: 340px; margin-inline: auto; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 20px; }
  .info, .site-footer .wrap { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .spec { grid-template-columns: minmax(0, 1fr); }
  .spec dt { border-bottom: 0; padding-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .keyhole img, .fog i { animation: none; }
}

/* =====================================================================
   動態視覺層：霧、燈光、顆粒、顯影字、3D 舞台
   ===================================================================== */

/* ---------- 首頁 hero（夜色） ---------- */
.hx {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: var(--bg);
  color: var(--ink);
}
.hx .layer { position: absolute; inset: 0; pointer-events: none; }
.hx .parallax { transform: translate3d(calc(var(--px, 0) * -22px), calc(var(--py, 0) * -14px), 0); transition: transform .8s cubic-bezier(.2, .7, .2, 1); }
.hx .leak { position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%; filter: blur(30px); }
.hx .leak.a { right: -20vmax; top: -28vmax; background: radial-gradient(circle, rgba(224, 169, 90, .16), rgba(224, 169, 90, .05) 45%, transparent 68%); animation: leak-a 21s ease-in-out infinite alternate; }
.hx .leak.b { left: -28vmax; bottom: -36vmax; background: radial-gradient(circle, rgba(154, 116, 64, .12), rgba(154, 116, 64, .04) 45%, transparent 68%); animation: leak-b 26s ease-in-out infinite alternate; }
@keyframes leak-a { to { transform: translate(-8vmax, 6vmax) scale(1.12); opacity: .7; } }
@keyframes leak-b { to { transform: translate(7vmax, -5vmax) scale(.9); opacity: .8; } }
@keyframes sweep { from { background-position: 130% 0; } to { background-position: -30% 0; } }
.hx .mistband { position: absolute; left: -20%; width: 140%; height: 38%; background: radial-gradient(closest-side, var(--mist), transparent); filter: blur(24px); animation: mistband 30s ease-in-out infinite alternate; }
.hx .mistband.m1 { top: 52%; }
.hx .mistband.m2 { top: 70%; animation-duration: 38s; animation-direction: alternate-reverse; opacity: .8; }
.hx .mistband.m3 { top: 8%; height: 30%; animation-duration: 46s; opacity: .5; }
@keyframes mistband { from { transform: translateX(-10%); } to { transform: translateX(10%); } }
.grain-canvas { position: absolute; inset: 0; width: 100%; height: 100%; mix-blend-mode: overlay; opacity: .5; pointer-events: none; z-index: 3; }

.hx-grid { position: relative; z-index: 4; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(20px, 4vw, 56px); align-items: center; padding-block: clamp(36px, 6vw, 72px) clamp(28px, 4vw, 48px); }
.hx .eyebrow { color: var(--brass); }
.hx h1 { font-size: clamp(36px, 5vw, 66px); letter-spacing: .06em; line-height: 1.28; color: var(--ink); }
.hx h1 .line { display: block; white-space: nowrap; }
.hx .copy { display: grid; gap: 22px; }
.hx .rotator { min-height: 1.8em; font: 600 clamp(16px, 1.6vw, 19px)/1.8 var(--serif); color: var(--brass); }
.hx .lede { color: var(--muted); max-width: 30em; }
.hx .cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hx .dates { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 14px; color: var(--muted); }
.hx .dates b { color: var(--ink); font-weight: 500; }

/* 逐字顯影 */
.develop-chars .ch { display: inline-block; animation: develop 1.7s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(var(--i) * 110ms + 200ms); }
.develop-once { animation: develop 1.3s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes develop {
  0% { opacity: .15; filter: blur(12px) brightness(2.2); transform: translateY(.06em); }
  55% { filter: blur(2.5px) brightness(1.3); }
  100% { opacity: 1; filter: none; transform: none; }
}

/* 3D 舞台 */
.stage3d { position: relative; width: 100%; max-width: 100%; aspect-ratio: 1 / .95; }
.stage3d canvas {
  display: block; width: 100%; height: 100%; outline: none;
  /* 霧氣到舞台邊緣淡出，避免看到方框 */
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent), linear-gradient(transparent, #000 9%, #000 91%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent), linear-gradient(transparent, #000 9%, #000 91%, transparent);
  mask-composite: intersect;
}
.stage3d canvas { touch-action: pan-y; }  /* 手機：左右滑轉相機，上下仍可捲頁 */
.stage3d.fine canvas { cursor: grab; touch-action: none; }
.stage3d.fine canvas.dragging { cursor: grabbing; }
.stage3d canvas:focus-visible { outline: 1px dashed rgba(224, 169, 90, .6); outline-offset: -10px; }
.stage3d .fallback { display: none; }
.stage3d.nogl canvas { display: none; }
.stage3d.nogl .fallback { display: grid; place-items: center; height: 100%; }
.stage3d.nogl .fallback img { width: 46%; }
.hud { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; font: 400 12px/1.4 var(--mono); letter-spacing: .12em; color: var(--night-muted); }
.hud .pill-btn { font: 500 13px/1 var(--sans); letter-spacing: .12em; color: var(--night-ink); background: rgba(13, 11, 9, .4); border: 1px solid rgba(237, 230, 216, .3); border-radius: 999px; padding: 10px 16px; cursor: pointer; }
.hud .pill-btn:hover { border-color: var(--lamp); color: var(--lamp); }
.hud .count { color: var(--lamp); font-variant-numeric: tabular-nums; }

/* 跑馬燈資訊條 */
.ticker { position: relative; z-index: 4; overflow: hidden; border-top: 1px solid var(--line); background: var(--strip); }
.ticker .track { display: inline-flex; white-space: nowrap; padding-block: 12px; font: 500 12px/1 var(--mono); letter-spacing: .22em; color: var(--muted); animation: roll 60s linear infinite; }
.ticker .track span { padding-inline: 18px; }
.ticker .track i { color: var(--brass); font-style: normal; }
@keyframes roll { to { transform: translateX(-50%); } }

/* ---------- 深色區塊的手電筒光 ---------- */
[data-flashlight] { position: relative; isolation: isolate; }
[data-flashlight]::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(420px circle at var(--fx, 70%) var(--fy, 30%), rgba(224, 169, 90, .16), transparent 70%);
  transition: background-position .2s;
}

/* ---------- 海報傾斜與反光 ---------- */
.tilt { position: relative; transform-style: preserve-3d; transition: transform .5s cubic-bezier(.2, .7, .2, 1); will-change: transform; }
.tilt::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(60% 50% at var(--gx, 30%) var(--gy, 20%), rgba(255, 240, 210, .22), transparent 60%);
  mix-blend-mode: soft-light; opacity: var(--go, 0); transition: opacity .4s;
}
.tilt-wrap { perspective: 1000px; }
@media (hover: none) { .tilt { animation: float 7s ease-in-out infinite; } }
@keyframes float { 50% { transform: translateY(-8px) rotateX(2deg) rotateY(-2deg); } }

/* ---------- 捲動顯影 ---------- */
.reveal.pre { opacity: .001; filter: blur(10px); transform: translateY(18px); }
.reveal { transition: opacity 1s cubic-bezier(.2, .7, .2, 1), filter 1.2s cubic-bezier(.2, .7, .2, 1), transform 1s cubic-bezier(.2, .7, .2, 1); transition-delay: var(--d, 0s); }

/* ---------- 主題頁：暗房相機 ---------- */
.darkroom { background: radial-gradient(80% 90% at 70% 40%, #3a1a14 0%, #1a0f0c 45%, #0c0807 100%); color: var(--night-ink); overflow: hidden; position: relative; isolation: isolate; }
.darkroom .eyebrow { color: #E58A6B; }
.darkroom .wrap { position: relative; z-index: 4; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.darkroom h2 { font-size: clamp(28px, 3.8vw, 44px); letter-spacing: .06em; margin: 10px 0 16px; }
.darkroom p { color: var(--night-muted); }
.prints { display: flex; gap: 10px; min-height: 80px; align-items: flex-end; margin-top: 18px; }
.prints .empty { font-size: 14px; color: var(--night-muted); align-self: center; }
.print { margin: 0; padding: 4px 4px 14px; background: #EDE6D8; box-shadow: 0 6px 18px rgba(0, 0, 0, .4); rotate: var(--r, 0deg); animation: drop .5s cubic-bezier(.2, .9, .3, 1.2) both; position: relative; }
.print img { width: 88px; height: 58px; object-fit: cover; animation: print-dev 3.4s ease-out both; }
.print figcaption { position: absolute; bottom: 1px; right: 5px; font: 500 8px/1 var(--mono); color: #6b5a44; }
@keyframes drop { from { transform: translateY(-24px); opacity: 0; } }
@keyframes print-dev { 0% { filter: sepia(1) brightness(2.6) contrast(.25) blur(2px); } 100% { filter: sepia(.5) contrast(1.08); } }
.flash { position: absolute; inset: 0; background: #FFF8EC; opacity: 0; pointer-events: none; z-index: 9; }
.flash.go { animation: flash .7s cubic-bezier(.1, .6, .3, 1); }
@keyframes flash { 0% { opacity: .9; } 100% { opacity: 0; } }

@media (max-width: 900px) {
  .hx-grid, .darkroom .wrap { grid-template-columns: minmax(0, 1fr); }
  .stage3d { aspect-ratio: 1 / .9; }
}
@media (max-width: 520px) {
  .hx h1 { font-size: clamp(30px, 9.6vw, 40px); }
  .print img { width: 64px; height: 43px; }
}
@media (prefers-reduced-motion: reduce) {
  .hx .leak, .hx .mistband, .ticker .track, .develop-chars .ch, .develop-once, .tilt, .print, .print img, .flash.go { animation: none !important; }
  .hx .parallax { transition: none; transform: none; }
  .reveal.pre { opacity: 1; filter: none; transform: none; }
}

/* ---------- 首頁鑰匙孔：點擊後拉進孔洞，強光轉場到主題頁 ---------- */
.keyhole-link { -webkit-tap-highlight-color: transparent; display: grid; justify-items: center; gap: 18px; text-decoration: none; color: var(--muted); cursor: pointer; }
.keyhole-link .kh-glow { display: block; width: min(100%, 400px); filter: drop-shadow(0 18px 36px rgba(60, 40, 20, .18)); transition: filter .6s, transform .6s cubic-bezier(.2, .7, .2, 1); }
.keyhole-link .keyhole { display: block; width: 100%; }
.keyhole-link:hover .kh-glow, .keyhole-link:focus-visible .kh-glow { filter: drop-shadow(0 22px 48px rgba(134, 103, 58, .35)); transform: scale(1.03); }
.keyhole-link:focus-visible { outline: none; }
.keyhole-link:focus-visible .keyhole-hint { outline: 2px solid var(--focus); outline-offset: 4px; }
.keyhole .glint {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 38%, rgba(255, 236, 200, .28) 50%, transparent 62%) no-repeat;
  background-size: 260% 100%;
  animation: sweep 6.5s linear infinite;
  mix-blend-mode: screen;
}
.keyhole-hint { font: 500 14px/1.4 var(--sans); letter-spacing: .14em; color: var(--ink); display: inline-flex; gap: 8px; align-items: center; }
.keyhole-hint span { color: var(--brass); transition: transform .3s; }
.keyhole-link:hover .keyhole-hint span { transform: translateX(4px); }

.portal-dim { position: fixed; inset: 0; z-index: 998; background: #050403; opacity: 0; pointer-events: none; }
.portal-vignette { position: fixed; inset: 0; z-index: 997; pointer-events: none; opacity: 0; background: radial-gradient(circle at 50% 50%, transparent 30%, rgba(5, 4, 3, .75) 100%); }
/* 推進鑰匙孔時，先關掉會跟著放大而拖慢畫面的模糊、陰影與顆粒 */
.portal-active main { will-change: transform; }
.portal-active .hx .layer, .portal-active .grain-canvas, .portal-active .ticker { visibility: hidden; }
.portal-active .kh-glow, .portal-active .keyhole .kh-rim { filter: none !important; animation: none !important; }
.portal-active .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; }
.portal-warp { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 999; pointer-events: none; opacity: 0; }
.portal-clone { position: fixed; z-index: 999; margin: 0; pointer-events: none; will-change: transform; }
.portal-light { position: fixed; inset: 0; z-index: 1000; opacity: 0; pointer-events: none; background: radial-gradient(circle at var(--lx, 50%) var(--ly, 40%), #fffdf8 0%, #fff4e0 35%, #f3dcb2 100%); }

/* 抵達主題頁：刺眼的光慢慢退去 */
html.entering body::after {
  content: ""; position: fixed; inset: 0; z-index: 2000; pointer-events: none;
  background: radial-gradient(circle at 50% 40%, #fffdf8 0%, #fff4e0 40%, #f3dcb2 100%);
  animation: light-out 1.5s cubic-bezier(.3, .6, .3, 1) .1s forwards;
}
html.entering main { animation: eyes-adjust 1.8s cubic-bezier(.3, .6, .3, 1) both; }
@keyframes light-out { to { opacity: 0; visibility: hidden; } }
@keyframes eyes-adjust { from { filter: brightness(1.8) blur(6px); transform: scale(1.04); } to { filter: none; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .keyhole .glint { animation: none; }
  html.entering body::after { display: none; }
  html.entering main { animation: none; }
}

.hx .grain-canvas { opacity: .22; mix-blend-mode: multiply; }

/* ---------- 線上預約（日曆、場次、表單） ---------- */
  .book { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
  .panel-title { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; }
  .panel-title .step { font: 500 13px/1 var(--mono); color: var(--brass); }
  .panel-title h2 { font-size: 21px; }
  .cal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
  .cal-head b { font: 700 18px/1 var(--serif); letter-spacing: .06em; }
  .cal-nav { display: flex; gap: 8px; }
  .cal-nav button { width: 38px; height: 38px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; border-radius: 2px; font-size: 16px; }
  .cal-nav button[disabled] { opacity: .35; cursor: not-allowed; }
  .cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
  .cal .dow { font-size: 12px; color: var(--muted); text-align: center; padding: 4px 0; }
  .day {
    position: relative; aspect-ratio: 1 / .9; min-height: 44px;
    border: 1px solid var(--line); background: var(--surface); color: var(--ink);
    border-radius: 2px; cursor: pointer; font: 500 15px/1 var(--mono);
    display: grid; place-items: center; padding: 0;
  }
  .day small { position: absolute; bottom: 5px; left: 0; right: 0; font: 400 10px/1 var(--sans); color: var(--ok); }
  .day.full small { color: var(--full); }
  .day:hover:not([disabled]) { border-color: var(--brass); }
  .day[disabled] { background: transparent; color: var(--muted); opacity: .45; cursor: default; }
  .day.full { color: var(--muted); }
  .day[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
  .day[aria-pressed="true"] small { color: var(--bg); }
  .legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; font-size: 13px; color: var(--muted); }
  .legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }
  .slots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .slot {
    border: 1px solid var(--line); background: var(--surface); color: var(--ink);
    padding: 12px 8px; border-radius: 2px; cursor: pointer; display: grid; gap: 4px; text-align: center;
  }
  .slot b { font: 500 18px/1 var(--mono); }
  .slot span { font-size: 12px; }
  .slot.available span { color: var(--ok); }
  .slot.full span { color: var(--full); }
  .slot.paused span { color: var(--paused); }
  .slot[disabled] { cursor: not-allowed; opacity: .6; }
  .slot[disabled] b { text-decoration: line-through; text-decoration-thickness: 1px; }
  .slot:hover:not([disabled]) { border-color: var(--brass); }
  .slot[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
  .slot[aria-pressed="true"] span { color: var(--bg); }
  .form-card { position: sticky; top: calc(84px + env(safe-area-inset-top, 0px)); border: 1px solid var(--line); background: var(--surface); padding: clamp(18px, 3vw, 28px); display: grid; gap: 16px; }
  .summary { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 15px; margin: 0; }
  .summary dt { color: var(--muted); }
  .summary dd { margin: 0; text-align: right; font-weight: 500; }
  .summary .total { border-top: 1px solid var(--line); padding-top: 8px; }
  .summary .pay-now { color: var(--brass); font-size: 18px; }
  .fields { display: grid; gap: 12px; }
  .empty-state { padding: 24px; border: 1px dashed var(--line); color: var(--muted); text-align: center; }
  @media (max-width: 900px) {
    .book { grid-template-columns: minmax(0, 1fr); }
    .form-card { position: static; }
  }
  @media (max-width: 520px) { .slots { grid-template-columns: repeat(2, minmax(0, 1fr)); } .day { font-size: 13px; } .day small { display: none; } }

/* =====================================================================
   主題頁（一頁式）：主視覺 → 故事／地點價格／時刻表 → 場景 → 預告 → 相機 → 預約
   整頁使用照相館的夜色，所有元件透過色票自動套用
   ===================================================================== */
body.theme-page, body.night-page {
  /* 取自海報：深木色暗部、泛黃相紙、窗光的琥珀金 */
  --bg: #1A120C; --surface: #251A12; --surface-2: #33241A; --ink: #F1E4CB; --muted: #C4AE8C;
  --brass: #E6B566; --lamp: #E8B86A; --line: rgba(241, 228, 203, .14); --ok: #A9D39A; --full: #E99C82; --paused: #A08E76;
  --focus: #E8B86A; --night: #120C08; --night-ink: #F1E4CB; --night-muted: #C4AE8C;
  color-scheme: dark;
  background: var(--bg);
  color: var(--ink);
}
body.theme-page .site-header, body.night-page .site-header { background: rgba(26, 18, 12, .88); }
body.theme-page .brand .logo-ink, body.night-page .brand .logo-ink { display: none; }
body.theme-page .brand .logo-light, body.night-page .brand .logo-light { display: block; }
body.theme-page .btn, body.night-page .btn { background: var(--ink); color: #1A120C; border-color: var(--ink); }
body.theme-page .btn:hover, body.night-page .btn:hover { background: var(--lamp); border-color: var(--lamp); color: #1A1206; }
body.theme-page .btn.lamp, body.night-page .btn.lamp { background: var(--lamp); border-color: var(--lamp); color: #1A1206; }
body.theme-page .btn.lamp:hover, body.night-page .btn.lamp:hover { background: #EDBD76; border-color: #EDBD76; }
body.theme-page .section + .section, body.night-page .section + .section { border-top: 1px solid var(--line); }
.stars { color: var(--lamp); letter-spacing: .12em; }
.stars .off { opacity: .25; }

/* 1. 主視覺 */
.tp-hero { position: relative; overflow: hidden; isolation: isolate; }
.tp-hero-bg {
  position: absolute; inset: -40px; z-index: -2;
  background: url("../img/poster-photo-studio.webp?v=1127b") center 30% / cover no-repeat;
  filter: blur(22px) brightness(.35) saturate(1.1);
  transform: scale(1.1);
}
.tp-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(12, 10, 8, .92) 0%, rgba(12, 10, 8, .6) 55%, rgba(12, 10, 8, .35) 100%); pointer-events: none; }
.tp-hero-grid { position: relative; z-index: 4; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding-block: clamp(40px, 7vw, 88px); }
.tp-hero-copy { display: grid; gap: 20px; }
.tp-hero .eyebrow { color: var(--lamp); }
.tp-hero h1 { font-size: clamp(46px, 7vw, 92px); letter-spacing: .1em; }
.tp-hero .hook { font: 600 clamp(18px, 2vw, 22px)/1.7 var(--serif); max-width: 26em; }
.tp-facts { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: rgba(12, 10, 8, .55); border: 1px solid var(--line); backdrop-filter: blur(4px); }
.tp-facts li { display: grid; justify-items: center; align-content: start; gap: 6px; padding: 18px 10px; text-align: center; }
.tp-facts li + li { border-left: 1px solid var(--line); }
.tp-facts svg { width: 34px; height: 34px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 4px; }
.tp-facts b { font-size: 17px; }
.tp-facts span { font-size: 13px; color: var(--muted); line-height: 1.5; }
.tp-hero-side { position: relative; display: grid; justify-items: end; }
.tp-poster { width: min(100%, 360px); box-shadow: 0 30px 60px rgba(0, 0, 0, .55); }
.price-card {
  position: relative; margin-top: -90px; margin-right: clamp(0px, 16%, 200px);
  width: min(100%, 250px); display: grid; justify-items: center; gap: 6px; text-align: center;
  padding: 22px 20px; background: rgba(21, 18, 15, .9); border: 1px solid var(--lamp); border-radius: 18px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .45); backdrop-filter: blur(6px);
}
.price-card .per { font: 700 18px/1 var(--sans); letter-spacing: .2em; }
.price-card .amount { font: 700 clamp(34px, 3.4vw, 44px)/1.1 var(--sans); color: var(--ink); }
.price-card .note { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.price-card .btn { width: 100%; border-radius: 10px; }

/* 2. 故事／地點價格／時刻表 */
.tp-info-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, .5fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
.tp-story { display: grid; gap: 18px; }
.tp-story h2 { font-size: clamp(24px, 2.8vw, 34px); color: var(--brass); letter-spacing: .04em; }
.story { font: 400 clamp(16px, 1.5vw, 18px)/2 var(--serif); }
.story p + p { margin-top: .6em; }
.story .last { font-weight: 700; }
.warn-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; color: #E9A15F; font-size: 15px; }
.warn-btn { justify-self: start; gap: 8px; }
.warn-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
body.theme-page .warn-btn, body.night-page .warn-btn { background: #E9A15F; border-color: #E9A15F; color: #1A1206; }
body.theme-page .warn-btn:hover, body.night-page .warn-btn:hover { background: #F2B77A; border-color: #F2B77A; }
.where-head { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.where-head svg { width: 40px; height: 40px; fill: none; stroke: #E58A6B; stroke-width: 1.6; }
.where-head h3 { font-size: 22px; margin-bottom: 6px; }
.where-head p { color: var(--muted); font-size: 15px; }
.where-head .links { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 8px; }
.where-head .links a { color: var(--brass); text-underline-offset: 3px; }
.price-block { padding-top: 22px; display: grid; gap: 12px; }
.price-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; }
.price-line b { font: 700 30px/1 var(--sans); }
.price-line span { color: var(--muted); font-size: 14px; }
.price-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.price-table th, .price-table td { padding: 8px 0; border-bottom: 1px solid var(--line); text-align: right; }
.price-table th:first-child, .price-table td:first-child { text-align: left; }
.price-table th { font-size: 12px; font-weight: 500; letter-spacing: .1em; color: var(--muted); }
.price-block .fine { font-size: 13px; color: var(--muted); }
.price-block .pack { font-weight: 700; }
.tp-times h3 { font-size: 17px; text-align: center; padding-bottom: 10px; border-bottom: 1px solid var(--line); margin-bottom: 8px; letter-spacing: .1em; }
.tp-times ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; text-align: center; }
.tp-times li { font-size: 18px; font-weight: 500; padding: 6px 0; }
.tp-times p { margin-top: 10px; font-size: 13px; color: var(--muted); text-align: center; }

/* 3. 場景（照片拍攝中） */
.scene-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.scene-slot {
  margin: 0; aspect-ratio: 4 / 5; max-width: 100%; display: grid; place-content: center; justify-items: center; gap: 12px; text-align: center;
  border: 1px dashed rgba(237, 230, 216, .25); border-radius: 6px; color: var(--muted);
  background: radial-gradient(80% 60% at 50% 35%, rgba(224, 169, 90, .08), transparent), var(--surface);
}
.scene-slot svg { width: 44px; height: 44px; fill: none; stroke: currentColor; stroke-width: 1.3; opacity: .7; }
.scene-slot small { font-size: 12px; opacity: .8; }

/* 4. 預告影片（製作中） */
.video-slot {
  aspect-ratio: 16 / 9; max-width: 100%; display: grid; place-content: center; justify-items: center; gap: 14px;
  border: 1px dashed rgba(237, 230, 216, .25); border-radius: 6px; color: var(--muted);
  background: radial-gradient(60% 70% at 50% 45%, rgba(224, 169, 90, .1), transparent), #0F0D0B;
}
.video-slot svg { width: 72px; height: 72px; fill: none; stroke: var(--lamp); stroke-width: 1.2; }

/* 6. 預約 */
.book-steps { list-style: none; margin: 0 0 20px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; counter-reset: bs; }
.book-steps li {
  counter-increment: bs; position: relative; display: grid; gap: 2px; padding: 14px 26px 14px 18px;
  background: var(--surface-2); clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%, 14px 50%);
}
.book-steps li:first-child { clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 50%, calc(100% - 14px) 100%, 0 100%); }
.book-steps li:last-child { background: #6E2A22; }
.book-steps li::before { content: "Step " counter(bs); font: 500 11px/1 var(--mono); letter-spacing: .12em; color: var(--brass); }
.book-steps li:last-child::before { color: #F2C2B4; }
.book-steps b { font-size: 16px; }
.book-steps span { font-size: 12px; color: var(--muted); }
.book-steps li:last-child span { color: #F2D8CF; }
.book-lede { color: var(--muted); margin-bottom: 28px; }
.book-lede a { color: var(--brass); text-underline-offset: 3px; }

@media (max-width: 980px) {
  .tp-info-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tp-times { grid-column: 1 / -1; }
  .tp-times ol { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .tp-hero-grid { grid-template-columns: minmax(0, 1fr); }
  .tp-hero-side { justify-items: center; }
  .price-card { margin-right: 0; }
  .book-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .book-steps li, .book-steps li:first-child { clip-path: none; }
}
@media (max-width: 640px) {
  .tp-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tp-facts li:nth-child(3) { border-left: 0; }
  .tp-facts li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .tp-info-grid { grid-template-columns: minmax(0, 1fr); }
  .scene-row { grid-template-columns: repeat(3, 72%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
  .scene-slot, .scene-shot { scroll-snap-align: start; }
}
#book { scroll-margin-top: 72px; }

/* ---------- 主題頁 v2：價格條、故事、資訊卡、海報色調 ---------- */
.tp-hero::after { background: linear-gradient(90deg, rgba(20, 12, 7, .94) 0%, rgba(26, 16, 9, .66) 55%, rgba(40, 24, 12, .4) 100%); }
.tp-hero-bg { filter: blur(22px) brightness(.42) saturate(1.25) sepia(.25); }
.tp-poster { width: min(100%, 380px); }
.price-bar {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px 24px;
  padding: 18px 22px; border: 1px solid rgba(232, 184, 106, .55); border-radius: 14px;
  background: linear-gradient(120deg, rgba(58, 36, 20, .75), rgba(26, 18, 12, .75)); backdrop-filter: blur(4px);
}
.price-bar .amount { display: flex; align-items: baseline; gap: 10px; font: 700 clamp(30px, 3vw, 40px)/1 var(--sans); color: var(--ink); }
.price-bar .per { font-size: 15px; font-weight: 500; letter-spacing: .2em; color: var(--muted); }
.price-bar .note { font-size: 13px; color: var(--muted); line-height: 1.6; }
.price-bar .btn { border-radius: 10px; min-width: 150px; }

.tp-story-grid { display: grid; gap: 14px; }
.tp-story-grid .story { max-width: 46em; }
.story-year { color: var(--brass); font: 700 1.5em/1 var(--serif); letter-spacing: .02em; }
.story-year .num { font: 600 1.25em/1 var(--latin); }
.tp-story-grid h2 { font-size: clamp(28px, 3.4vw, 42px); color: var(--brass); letter-spacing: .04em; line-height: 1.45; margin-top: 12px; }
.tp-story-grid .story { font-size: clamp(17px, 1.6vw, 19px); line-height: 2.1; color: var(--ink); }
.tp-story-grid .story p + p { margin-top: 1em; }
.tp-story-grid .story { letter-spacing: .08em; }
.story-sfx { font-size: 1.9em; margin-right: .1em; vertical-align: -.08em; letter-spacing: 0; }
.tp-notice { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 32px; padding: 22px 26px; border: 1px solid rgba(233, 161, 95, .35); border-radius: 12px; background: rgba(233, 161, 95, .06); }
.tp-notice .warn-list { font-size: 16px; gap: 6px; }

.info-cards { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.1fr) minmax(0, .8fr); gap: 20px; align-items: stretch; }
.info-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: clamp(22px, 2.5vw, 32px); display: grid; align-content: start; gap: 18px; }
.info-card .card-title { font: 700 13px/1 var(--sans); letter-spacing: .24em; color: var(--brass); }
.info-card .where-head { border-bottom: 0; padding-bottom: 0; }
.info-card .where-head p { font-size: 16px; line-height: 1.8; }
.info-card .price-block { padding-top: 0; gap: 14px; }
.info-card .price-table td, .info-card .price-table th { padding: 10px 0; }
.info-card .tp-times ol { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; }
.info-card .tp-times li { font-size: 19px; padding: 10px 0; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); }
.info-card .tp-times p { line-height: 1.7; }

body.theme-page .darkroom, body.night-page .darkroom { background: radial-gradient(80% 90% at 70% 40%, #4A2C16 0%, #24160D 45%, #120C08 100%); }
body.theme-page .darkroom .eyebrow, body.night-page .darkroom .eyebrow { color: var(--lamp); }
body.theme-page .book-steps li:last-child, body.night-page .book-steps li:last-child { background: #7A3A1E; }
body.theme-page .scene-slot, body.theme-page .video-slot, body.night-page .scene-slot, body.night-page .video-slot { border-color: rgba(232, 184, 106, .3); }

@media (max-width: 980px) {
  .info-cards { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .info-cards .info-card:last-child { grid-column: 1 / -1; }
  .info-card .tp-times ol { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .info-cards { grid-template-columns: minmax(0, 1fr); }
  .price-bar { grid-template-columns: 1fr auto; }
  .price-bar .btn { grid-column: 1 / -1; }
  .info-card .tp-times ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 快門截圖：照片可點開放大、下載 */
.print .print-btn { display: block; padding: 0; border: 0; background: none; cursor: zoom-in; }
.shot-viewer { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 24px 16px; background: rgba(8, 5, 3, .86); backdrop-filter: blur(4px); }
.shot-viewer figure { margin: 0; display: grid; gap: 14px; justify-items: center; max-width: min(1100px, 100%); }
.shot-viewer img { max-height: 76vh; width: auto; border: 8px solid #EDE6D8; border-bottom-width: 28px; box-shadow: 0 20px 60px rgba(0, 0, 0, .6); }
.shot-viewer figcaption { display: flex; gap: 10px; }

/* 注意事項：入場前請留意（主題頁按鈕直接跳到這裡） */
#notice { scroll-margin-top: 88px; }
.notice-block { border: 1px solid var(--brass); background: var(--surface); padding: clamp(20px, 3vw, 28px); border-radius: 10px; }
.notice-block h2 { color: var(--brass); }
.notice-block ul { list-style: none; padding: 0; gap: 12px; }
.notice-block li { display: block; }
.notice-block .age-tag { margin: 0 4px; }
.age-tag { display: inline-block; font: 700 12px/1 var(--mono); letter-spacing: .08em; padding: 5px 8px; border: 1px solid currentColor; border-radius: 4px; margin-right: 6px; vertical-align: 1px; }

/* =====================================================================
   首頁 v3：黑色鑰匙孔（霧、微光、浮塵）、遊戲主題卡片、活動頁
   ===================================================================== */
.keyhole.void { background: radial-gradient(55% 40% at 50% 64%, #2b1d12 0%, #120d09 55%, #050403 100%); }
.keyhole.void .kh-core {
  position: absolute; left: 50%; top: 62%; width: 70%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%;
  background: radial-gradient(circle, rgba(232, 184, 106, .55) 0%, rgba(232, 184, 106, .14) 30%, transparent 62%);
  filter: blur(6px); animation: kh-breathe 5.5s ease-in-out infinite, kh-flicker 7s steps(1) infinite;
}
@keyframes kh-breathe { 0%, 100% { transform: scale(.82); opacity: .55; } 50% { transform: scale(1.08); opacity: 1; } }
@keyframes kh-flicker { 0%, 40%, 44%, 100% { filter: blur(6px) brightness(1); } 42% { filter: blur(6px) brightness(.55); } 43% { filter: blur(6px) brightness(1.2); } }
.keyhole.void .kh-mist { position: absolute; inset: 0; }
.keyhole.void .kh-mist i {
  position: absolute; left: -40%; width: 180%; height: 34%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(214, 208, 196, .2), transparent);
  filter: blur(10px); animation: kh-mist 16s ease-in-out infinite alternate;
}
.keyhole.void .kh-mist i:nth-child(1) { top: 46%; }
.keyhole.void .kh-mist i:nth-child(2) { top: 66%; animation-duration: 21s; animation-direction: alternate-reverse; opacity: .8; }
.keyhole.void .kh-mist i:nth-child(3) { top: 20%; height: 26%; animation-duration: 27s; opacity: .55; }
@keyframes kh-mist { from { transform: translateX(-14%); } to { transform: translateX(14%); } }
.keyhole.void .kh-dust { position: absolute; inset: 0; width: 100%; height: 100%; }
.keyhole-link:hover .kh-core { animation-duration: 2.6s, 7s; }

.btn.ghost-night { background: transparent; color: var(--night-ink); border-color: rgba(237, 230, 216, .4); }
.btn.ghost-night:hover { color: var(--lamp); border-color: var(--lamp); background: transparent; }

.theme-list { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); gap: 20px; align-items: stretch; }
.theme-feature { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 56px); align-items: center; padding: clamp(20px, 3vw, 36px); border: 1px solid rgba(237, 230, 216, .14); border-radius: 14px; background: rgba(255, 255, 255, .02); }
.theme-feature .tilt-wrap { display: block; }
.theme-feature .poster { width: 100%; max-width: 380px; box-shadow: 0 30px 60px rgba(0, 0, 0, .45); }
.theme-feature .tf-body { display: grid; gap: 14px; }
.theme-feature h3 { font-size: clamp(30px, 3.6vw, 46px); letter-spacing: .08em; }
.theme-feature .hook { font: 600 clamp(16px, 1.6vw, 19px)/1.8 var(--serif); color: var(--night-ink); }
.theme-feature .facts { margin: 6px 0; }
.theme-feature .facts dd small { display: block; font-size: 12px; font-weight: 400; color: var(--night-muted); margin-top: 2px; }
.theme-soon {
  display: grid; align-content: center; justify-items: center; gap: 10px; text-align: center; padding: 28px 20px;
  border: 1px dashed rgba(237, 230, 216, .25); border-radius: 14px; color: var(--night-muted);
  background: radial-gradient(70% 50% at 50% 40%, rgba(232, 184, 106, .08), transparent);
}
.theme-soon h3 { font-size: 20px; color: var(--night-ink); }
.soon-mark { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; border: 1px solid currentColor; font: 700 28px/1 var(--serif); color: var(--lamp); }

.themes-page { position: relative; overflow: hidden; min-height: 70vh; }
.themes-page h1 { font-size: clamp(34px, 5vw, 60px); letter-spacing: .08em; }
.themes-page .lede { color: var(--muted); margin-top: 6px; }
body.night-page .band, body.night-page .themes-page { background: var(--bg); }

.news-empty { max-width: 640px; margin: 0 auto; display: grid; justify-items: center; gap: 14px; text-align: center; padding: clamp(32px, 6vw, 64px) 20px; border: 1px dashed var(--line); border-radius: 14px; background: var(--surface); }
.news-empty h2 { font-size: clamp(24px, 3vw, 32px); }
.news-empty p { color: var(--muted); max-width: 32em; }
.news-empty .soon-mark { color: var(--brass); }
.news-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 8px; }

@media (max-width: 900px) {
  .theme-list, .theme-feature { grid-template-columns: minmax(0, 1fr); }
  .theme-feature .poster { max-width: 300px; margin-inline: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .keyhole.void .kh-core, .keyhole.void .kh-mist i { animation: none; }
}

/* =====================================================================
   v4：全站統一使用首頁的霧面紙色底，鑰匙孔保持純黑
   ===================================================================== */
.grain-canvas { opacity: .2; mix-blend-mode: multiply; }

/* 鑰匙孔：純黑，細霧與浮塵，內框沿著孔的形狀 */
.keyhole.void { background: #000; }
.keyhole.void .kh-mist i { background: radial-gradient(closest-side, rgba(200, 200, 196, .12), transparent); }
.keyhole .kh-outline { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; }
.keyhole .kh-outline path { fill: none; stroke: rgba(216, 174, 110, .6); stroke-width: 1.4; vector-effect: non-scaling-stroke; transition: stroke .5s; }
.keyhole-link:hover .kh-outline path, .keyhole-link:focus-visible .kh-outline path { stroke: rgba(232, 190, 120, .95); }
.keyhole-hint { gap: 12px; }
.key-icon { width: 34px; height: 17px; fill: none; stroke: var(--brass); stroke-width: 1.6; stroke-linecap: round; transition: transform .35s cubic-bezier(.2, .7, .2, 1); }
.keyhole-link:hover .key-icon, .keyhole-link:focus-visible .key-icon { transform: translateX(6px); }

/* 遊戲主題卡：只有海報與三個重點，點海報進入主題介紹 */
.theme-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 320px)); gap: clamp(20px, 3vw, 36px); align-items: start; }
.theme-card { display: grid; gap: 14px; text-decoration: none; color: var(--ink); }
.theme-card .tilt-wrap { display: block; }
.theme-card .poster { width: 100%; box-shadow: 0 22px 44px rgba(40, 28, 16, .28); transition: box-shadow .4s; }
.theme-card:hover .poster { box-shadow: 0 28px 56px rgba(40, 28, 16, .38); }
.theme-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; font-size: 15px; font-weight: 500; }
.theme-meta > span { display: inline-flex; align-items: center; gap: 6px; }
.theme-meta svg { width: 20px; height: 20px; fill: none; stroke: var(--brass); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.theme-meta .stars { color: var(--brass); letter-spacing: .08em; }
.theme-meta .stars .off { opacity: .28; }
.theme-soon { aspect-ratio: 600 / 826; max-width: 100%; color: var(--muted); border-color: var(--line); background: var(--surface); }
.theme-soon h3 { color: var(--ink); }
.theme-soon .soon-mark { color: var(--brass); }
.themes-page { min-height: 0; }
.themes-page .lede { color: var(--muted); }

/* 主題介紹頁：淺色底 */
.tp-hero-bg, .tp-hero::after { display: none; }
.tp-hero .eyebrow { color: var(--brass); }
.tp-facts { background: var(--surface); backdrop-filter: none; }
.tp-facts svg { stroke: var(--brass); }
.stars { color: var(--brass); }
.price-bar { background: var(--surface); border-color: var(--brass); backdrop-filter: none; }
.tp-story-grid h2 { color: var(--brass); }
.tp-story-grid .story { color: var(--ink); }

.tp-location .loc-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.tp-location h2 { font-size: clamp(26px, 3.4vw, 38px); margin: 10px 0 24px; }
.tp-location .where-head { border-bottom: 0; padding-bottom: 0; }
.tp-location .where-head svg { stroke: var(--brass); }
.tp-location .where-head p { font-size: 16px; line-height: 1.8; color: var(--muted); }
.tp-location .where-head .links a { color: var(--ink); }
.loc-map { aspect-ratio: 16 / 10; max-width: 100%; border: 1px solid var(--line); background: var(--surface-2); border-radius: 10px; overflow: hidden; }
.loc-map iframe { width: 100%; height: 100%; border: 0; display: block; }

.darkroom { background: var(--bg); color: var(--ink); }
.darkroom .eyebrow { color: var(--brass); }
.darkroom p, .darkroom .hud, .prints .empty { color: var(--muted); }
.darkroom .hud .count { color: var(--brass); }
.darkroom .pill-btn { color: var(--ink); background: var(--surface); border-color: var(--line); }
.darkroom .pill-btn:hover { color: var(--brass); border-color: var(--brass); }
.video-slot { background: var(--surface-2); }
.video-slot svg { stroke: var(--brass); }
.scene-slot, .video-slot { border-color: var(--line); color: var(--muted); }

@media (max-width: 900px) { .tp-location .loc-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .theme-list { grid-template-columns: minmax(0, 1fr); } .theme-card, .theme-soon { max-width: 340px; margin-inline: auto; width: 100%; } }

/* =====================================================================
   v5：銀河鑰匙孔、黑白轉彩色海報與「即刻預約」、五星難度、大畫幅相機
   ===================================================================== */
/* 鑰匙孔：無限延伸的銀河，孔緣隱約發光 */
.keyhole .kh-galaxy { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.keyhole .kh-rim { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; filter: blur(7px); }
.keyhole .kh-rim path { fill: none; stroke: rgba(236, 206, 150, .5); stroke-width: 26; vector-effect: non-scaling-stroke; animation: rim-breathe 6s ease-in-out infinite; }
@keyframes rim-breathe { 0%, 100% { stroke: rgba(236, 206, 150, .28); } 50% { stroke: rgba(236, 206, 150, .6); } }
.keyhole-link:hover .kh-rim path { stroke: rgba(246, 222, 170, .75); animation-duration: 3s; }

/* 難度星號：五顆，亮兩顆，其餘只留框線 */
.stars { display: inline-flex; gap: 2px; vertical-align: -3px; }
.stars i { display: inline-flex; }
.stars svg { width: 16px; height: 16px; stroke: var(--brass); stroke-width: 1.4; stroke-linejoin: round; }
.stars .on svg { fill: var(--brass); }
.stars .off svg { fill: none; opacity: 1; }
.stars .off { opacity: 1; }
.tp-facts .stars svg { width: 15px; height: 15px; }

/* 主題海報卡：平時是黑白老照片，滑過變彩色並出現「即刻預約」 */
.poster-frame { position: relative; display: block; overflow: hidden; box-shadow: 0 22px 44px rgba(40, 28, 16, .28); }
.poster-frame .poster { width: 100%; box-shadow: none; filter: grayscale(1) sepia(.18) contrast(1.05) brightness(.95); transition: filter .9s ease, transform .9s cubic-bezier(.2, .7, .2, 1); }
.snap-btn {
  position: absolute; left: 50%; bottom: 4.5%; translate: -50% 12px; opacity: 0;
  padding: 12px 26px; background: var(--ink); color: var(--bg); font: 500 15px/1 var(--sans); letter-spacing: .16em; border-radius: 2px;
  transition: opacity .45s ease, translate .45s cubic-bezier(.2, .7, .2, 1); pointer-events: none; white-space: nowrap;
}
.poster-frame:hover .poster, .poster-frame:focus-visible .poster { filter: none; transform: scale(1.03); }
.poster-frame:hover .snap-btn, .poster-frame:focus-visible .snap-btn { opacity: 1; translate: -50% 0; }
@media (hover: none) {
  .poster-frame .poster { filter: none; }
  .snap-btn { opacity: 1; translate: -50% 0; }
}
/* 快門葉片：按下時上下合起再打開 */
.shutter-blades { position: absolute; inset: 0; pointer-events: none; }
.shutter-blades i { position: absolute; left: 0; right: 0; height: 50%; background: #050403; transform: scaleY(0); }
.shutter-blades i:first-child { top: 0; transform-origin: top; }
.shutter-blades i:last-child { bottom: 0; transform-origin: bottom; }
.poster-frame.snapping .shutter-blades i { animation: blade .26s cubic-bezier(.6, 0, .4, 1); }
@keyframes blade { 0% { transform: scaleY(0); } 45%, 55% { transform: scaleY(1); } 100% { transform: scaleY(0); } }
.snap-flash { position: fixed; inset: 0; z-index: 1001; background: #fffdf8; pointer-events: none; opacity: 0; }
.snap-clone { position: fixed; z-index: 1000; margin: 0; pointer-events: none; will-change: transform, filter; object-fit: cover; }
.snap-dim { position: fixed; inset: 0; z-index: 999; background: #0a0806; opacity: 0; pointer-events: none; }

/* 暗房相機區：大畫幅相機含三腳架，舞台改為直向 */
.darkroom .stage3d { aspect-ratio: 1 / 1.12; max-height: 70vh; justify-self: center; width: min(90%, 504px); }
@media (prefers-reduced-motion: reduce) { .keyhole .kh-rim path { animation: none; } }

/* v6：鑰匙孔縮小到 70%、內部深黑，孔緣微光 */
.keyhole-link .kh-glow { width: min(70%, 280px); }
.keyhole.void { background: radial-gradient(60% 50% at 50% 55%, #050507 0%, #000 100%); }
.keyhole .kh-rim { filter: blur(6px); }
.keyhole .kh-rim path { stroke-width: 30; }
@keyframes rim-breathe { 0%, 100% { stroke: rgba(240, 212, 160, .35); } 50% { stroke: rgba(240, 212, 160, .72); } }
@media (max-width: 900px) { .keyhole-link .kh-glow { width: min(70%, 260px); } }

/* ---------- v7：場景示意圖、預告影片 ---------- */
.scene-shot { margin: 0; position: relative; overflow: hidden; border-radius: 6px; background: #120c08; box-shadow: 0 18px 40px -24px rgba(20, 12, 4, .55); }
.scene-shot img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; transition: transform 1.2s cubic-bezier(.2, .7, .2, 1), filter .6s; filter: saturate(.85) brightness(.95); }
.scene-shot:hover img { transform: scale(1.04); filter: saturate(1) brightness(1.05); }
.scene-shot figcaption { position: absolute; inset: auto 0 0 0; display: flex; justify-content: space-between; align-items: baseline; padding: 40px 16px 14px; color: #F1E6D0; background: linear-gradient(transparent, rgba(10, 6, 3, .82)); }
.scene-shot figcaption span { font-family: var(--serif, "Noto Serif TC", serif); font-weight: 700; font-size: 18px; letter-spacing: .2em; }
.scene-shot figcaption small { font-size: 11px; letter-spacing: .15em; opacity: .75; border: 1px solid rgba(241, 230, 208, .45); padding: 2px 8px; border-radius: 99px; }
.scene-note { margin-top: 14px; font-size: 13px; color: var(--muted); text-align: center; }
.trailer { position: relative; aspect-ratio: 16 / 9; border-radius: 6px; overflow: hidden; background: #000; box-shadow: 0 24px 60px -30px rgba(20, 12, 4, .6); }
.trailer video { display: block; width: 100%; height: 100%; object-fit: cover; background: #000; }
.trailer-note { margin-top: 12px; font-size: 13px; color: var(--muted); text-align: center; }

/* 手機排版：layout.js 把段落切成「句」(.ps) 與「子句」(.pc)。
   手機上每句、每個子句都不拆開，放不下就整句（或整個子句）換到下一行；
   電腦版維持一般排版，不受影響 */
@media (max-width: 820px) {
  .ps, .pc, .pt, .nb { display: inline-block; vertical-align: top; }
  /* 主題頁副標：兩句話各佔一行，字級隨螢幕寬度縮放 */
  .tp-hero-copy { container-type: inline-size; }
  .tp-hero .hook { font-size: min(18px, 100cqi / 22.5); }
}

/* 手機（觸控）動態：捲動到畫面中央時，海報由黑白轉彩色、「即刻預約」浮出；場景圖緩慢推近；鑰匙孔輕輕呼吸邀請點擊 */
@media (hover: none) and (prefers-reduced-motion: no-preference) {
  .poster-frame .poster { filter: grayscale(1) sepia(.18) contrast(1.05) brightness(.95); transition: filter 1.6s ease, transform 2.4s cubic-bezier(.2, .7, .2, 1); }
  .poster-frame.in-view .poster { filter: none; transform: scale(1.03); }
  .poster-frame .snap-btn { opacity: 0; translate: -50% 14px; transition: opacity .6s ease .7s, translate .6s cubic-bezier(.2, .7, .2, 1) .7s; }
  .poster-frame.in-view .snap-btn { opacity: 1; translate: -50% 0; }
  .scene-shot.in-view img { animation: ken-burns 9s cubic-bezier(.2, .6, .3, 1) forwards; filter: saturate(1) brightness(1.02); }
  @keyframes ken-burns { from { transform: scale(1); } to { transform: scale(1.09); } }
  .keyhole-link .kh-glow { animation: kh-invite 3.6s ease-in-out infinite; }
  @keyframes kh-invite { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.035); filter: drop-shadow(0 22px 48px rgba(134, 103, 58, .35)); } }
  .keyhole-link .key-icon { animation: key-nudge 3.6s ease-in-out infinite; }
  @keyframes key-nudge { 0%, 60%, 100% { transform: translateX(0); } 75% { transform: translateX(5px); } }
  .keyhole-link:active .kh-glow { transform: scale(.97); }
}

/* 穿越鑰匙孔短片：點擊後蓋滿畫面播放 */
.portal-intro { position: fixed; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 999; background: #050403; opacity: 0; pointer-events: none; transition: opacity .25s; }
.portal-intro.on { opacity: 1; }

/* 場景示意圖：滑過出現遮罩＋VIEW、放大鏡游標；點擊開大圖預覽 */
.scene-shot { cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 32 32'%3E%3Ccircle cx='13' cy='13' r='9' fill='rgba(10,6,3,.35)' stroke='%23F1E6D0' stroke-width='2'/%3E%3Cpath d='M13 9v8M9 13h8M20 20l8 8' stroke='%23F1E6D0' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") 13 13, zoom-in; }
.scene-shot::after { content: ""; position: absolute; inset: 0; background: rgba(8, 5, 3, .55); opacity: 0; transition: opacity .4s; pointer-events: none; }
.scene-view { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 6px; color: #F1E6D0; font: 600 15px/1 var(--sans); letter-spacing: .22em; opacity: 0; transform: translateY(6px); transition: opacity .4s, transform .4s; pointer-events: none; }
.scene-view i { font-style: normal; font-size: 17px; }
.scene-shot:hover::after, .scene-shot:focus-visible::after { opacity: 1; }
.scene-shot:hover .scene-view, .scene-shot:focus-visible .scene-view { opacity: 1; transform: none; }
.scene-shot figcaption { z-index: 1; }
.scene-shot:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }
.scene-viewer { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 56px 16px 24px; background: rgba(6, 4, 2, .92); backdrop-filter: blur(4px); opacity: 0; transition: opacity .3s; }
.scene-viewer.open { opacity: 1; }
.scene-viewer img { max-width: min(1000px, 100%); max-height: calc(100vh - 110px); width: auto; height: auto; border-radius: 4px; box-shadow: 0 24px 70px rgba(0, 0, 0, .7); transform: scale(.97); transition: transform .3s; }
.scene-viewer.open img { transform: none; }
.scene-viewer p { margin: 12px 0 0; color: #F1E6D0; font-size: 14px; letter-spacing: .2em; text-align: center; }
.scene-viewer .close { position: absolute; top: 14px; right: 16px; width: 40px; height: 40px; border: 0; background: none; color: #F1E6D0; font-size: 26px; line-height: 1; cursor: pointer; opacity: .8; }
.scene-viewer .close:hover { opacity: 1; }

/* =====================================================================
   試用：墨黑劇場風（取自謎漫管理台深色主題）。html.ink 啟用，網址加 ?ink=1 開、?ink=0 關
   ===================================================================== */
html.ink {
  --bg: #0B0A09; --surface: #141210; --surface-2: #1C1916; --ink: #EDE7DA; --muted: #9A9284;
  --brass: #F4C261; --lamp: #F4C261; --line: rgba(237, 231, 218, .12); --ok: #7FC195; --full: #E38B7B; --paused: #8A8378;
  --focus: #F4C261; --night: #080706; --night-ink: #EDE7DA; --night-muted: #9A9284;
  --glass: rgba(11, 10, 9, .9); --haze: rgba(11, 10, 9, .8); --mist: rgba(20, 18, 16, .85); --strip: rgba(20, 18, 16, .7);
  color-scheme: dark;
}
html.ink body { background: var(--bg); color: var(--ink); }
html.ink .site-header { background: rgba(11, 10, 9, .9); border-color: var(--line); }
html.ink .brand .logo-ink { display: none; }
html.ink .brand .logo-light { display: block; }
html.ink .btn { background: var(--ink); color: #0B0A09; border-color: var(--ink); }
html.ink .btn:hover { background: var(--lamp); border-color: var(--lamp); color: #0B0A09; }
html.ink .btn.lamp { background: var(--lamp); border-color: var(--lamp); color: #0B0A09; }
html.ink .btn.ghost, html.ink .btn.line { background: transparent; color: var(--ink); border-color: var(--line); }
html.ink .section + .section { border-top: 1px solid var(--line); }
html.ink .scene-shot { box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .9); }

/* 預約完成頁：私訊 IG 粉專 */
.ig-dm { border-color: var(--brass); }
.ig-dm-btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }

/* 相機快門：黑一下 → 白閃 → 照片滿版 → 縮進相片盒 */
.shot-pop { position: fixed; inset: 0; z-index: 1300; display: grid; place-items: center; padding: 6vmin; pointer-events: none; background: #000; }
.shot-pop img { max-width: min(1100px, 100%); max-height: 82vh; border: 8px solid #EDE6D8; border-bottom-width: 28px; box-shadow: 0 20px 60px rgba(0, 0, 0, .6); opacity: 0; transform-origin: center; }
.shot-pop .shot-white { position: absolute; inset: 0; background: #FFF8EC; opacity: 0; }

/* ---------- 鑰匙孔：白芯銅邊動態光芒（定案＝c 光束掃過＋浮塵） ---------- */
html[data-kh] .hx { background: #060504; }
html[data-kh] .hx .leak { display: none; }
html[data-kh] .hx .mistband { opacity: .25; }
html[data-kh] .kh-rays { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; mix-blend-mode: screen; }
html[data-kh] .keyhole-link .kh-glow { width: min(58%, 229px); margin-block: clamp(30px, 6vw, 80px); filter: drop-shadow(0 0 3px rgba(255, 252, 244, .8)) drop-shadow(0 0 16px rgba(255, 240, 215, .4)) drop-shadow(0 0 40px rgba(200, 170, 130, .22)); }
html[data-kh] .keyhole-link:hover .kh-glow { filter: drop-shadow(0 0 4px rgba(255, 252, 244, .9)) drop-shadow(0 0 22px rgba(255, 240, 215, .55)) drop-shadow(0 0 54px rgba(200, 170, 130, .32)); transform: scale(1.03); }
html[data-kh] .keyhole.void { animation: kh-breathe 7s ease-in-out infinite; background: radial-gradient(80% 65% at 50% 30%, #fffefc 0%, #fffaf0 60%, #fbf0dc 100%); }
html[data-kh] .keyhole .kh-outline, html[data-kh] .keyhole .kh-rim, html[data-kh] .keyhole .kh-mist, html[data-kh] .keyhole .kh-dust, html[data-kh] .keyhole .kh-core { display: none; }

@keyframes kh-breathe { 0%, 100% { filter: brightness(.9); } 50% { filter: brightness(1); } }
@media (prefers-reduced-motion: reduce) { html[data-kh] .keyhole.void { animation: none; } }

/* =====================================================================
   試作：復古紙質皮（參考 100days-of-deception 照相館）。html.paper 啟用：?skin=paper 開、?skin=off 關
   深褐夜色底＋羊皮紙卡片、黃銅細框、酒紅膠囊按鈕；材質圖（紙紋／銅角花）待 Codex 交件後補上
   ===================================================================== */
html.paper body, html.paper body.theme-page, html.paper body.night-page {
  --bg: #1E1610; --surface: #2A1F16; --surface-2: #362819; --ink: #EFE3C8; --muted: #BFA98A;
  --brass: #C8A165; --lamp: #D9B274; --line: rgba(200, 161, 101, .22); --focus: #D9B274;
  --night: #140E09; --night-ink: #EFE3C8; --night-muted: #BFA98A; --ok: #A9D39A; --full: #E99C82; --paused: #A08E76;
  --glass: rgba(20, 14, 9, .92); --haze: rgba(30, 22, 16, .8); --mist: rgba(42, 31, 22, .85); --strip: rgba(42, 31, 22, .7);
  --wine: #7A1F1F; --parch: #EFE3C8; --hand: var(--serif);
  color-scheme: dark; background: var(--bg); color: var(--ink);
}
html.paper .site-header { background: rgba(20, 14, 9, .92); border-bottom: 1px solid rgba(200, 161, 101, .35); }
html.paper .brand .logo-ink { display: none; }
html.paper .brand .logo-light { display: block; }
html.paper .nav ul a:hover, html.paper .nav ul a[aria-current="page"] { color: var(--parch); border-bottom-color: var(--brass); }

/* 字：標題宋體不變，副標／導言改手寫感 */
html.paper .lede, html.paper .page-head p.lede, html.paper .rotator, html.paper .story-year { font-family: var(--hand); letter-spacing: .02em; }
html.paper .page-head { border-bottom: 1px solid var(--line); }
html.paper .section + .section { border-top: 1px solid var(--line); }

/* 按鈕：酒紅膠囊＋黃銅細邊 */
html.paper body .btn { background: var(--wine); color: var(--parch); border: 1px solid var(--brass); border-radius: 999px; padding-inline: 26px; box-shadow: inset 0 0 0 2px rgba(20, 14, 9, .35), 0 8px 20px -10px rgba(0, 0, 0, .9); transition: background .25s, border-color .25s, transform .2s; }
html.paper body .btn:hover { background: #932A28; border-color: #E2C08A; color: #FFF6E4; }
html.paper body .btn:active { transform: translateY(1px) scale(.98); }
html.paper body .btn.ghost, html.paper body .btn.line { background: transparent; color: var(--parch); border-color: var(--brass); box-shadow: none; }
html.paper body .btn.ghost:hover, html.paper body .btn.line:hover { background: rgba(200, 161, 101, .12); color: #FFF6E4; }
html.paper body .btn.lamp { background: var(--brass); border-color: #E2C08A; color: #1E1610; }

/* 羊皮紙卡片：在卡片內把色票換成深墨字，裡面元件自動跟著變 */
html.paper .callout {
  --ink: #2A1D14; --muted: #6B5640; --line: rgba(42, 29, 20, .2); --brass: #8A5A24; --surface: #E6D6B4;
  background: var(--parch); color: var(--ink); border: 1px solid #B88D52; border-radius: 2px;
  box-shadow: inset 0 0 0 4px var(--parch), inset 0 0 0 5px rgba(138, 90, 36, .45), 0 18px 40px -20px rgba(0, 0, 0, .9);
  padding: 22px 24px;
}
html.paper .callout b { font-family: var(--serif); }
html.paper .callout .btn.ghost { color: #2A1D14; border-color: #8A5A24; }
html.paper .callout .btn.ghost:hover { background: rgba(138, 90, 36, .12); color: #2A1D14; }

/* 表單 */
html.paper input, html.paper select, html.paper textarea { background: #2A1F16; color: var(--ink); border-color: rgba(200, 161, 101, .35); }

/* 頁尾 */
html.paper .site-footer { border-top: 1px solid rgba(200, 161, 101, .3); }
html.paper .site-footer .social-btn { background: var(--brass); color: #1E1610; }

/* 點擊：黃銅漣漪 */
.pp-ripple { position: fixed; z-index: 2100; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; pointer-events: none; border: 1.5px solid rgba(226, 192, 138, .9); box-shadow: 0 0 12px rgba(226, 192, 138, .5); animation: pp-ripple .55s cubic-bezier(.2, .7, .3, 1) forwards; }
@keyframes pp-ripple { to { transform: scale(7); opacity: 0; } }

/* 換頁：紙色從點擊處展開；進場時由中央收起 */
html.paper body::after {
  content: ""; position: fixed; inset: 0; z-index: 2000; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%, #3A2A1C 0%, #1E1610 60%, #120C08 100%);
  clip-path: circle(0 at var(--pp-x, 50%) var(--pp-y, 50%));
  transition: clip-path .42s cubic-bezier(.65, 0, .35, 1);
}
html.paper.pp-leaving body::after, html.paper.pp-enter body::after { clip-path: circle(150% at var(--pp-x, 50%) var(--pp-y, 50%)); }
html.paper.pp-enter body::after { transition-duration: .5s; }
html.paper.pp-arm body::after { transition: none; }
@media (prefers-reduced-motion: reduce) { html.paper body::after { display: none; } }

/* ---------- 全站游標：小畫筆（筆尖在左下角） ---------- */
html, a, button, label, select, summary, [role="button"], .btn, .keyhole-link, .day, .slot, .scene-shot {
  cursor: url("/assets/img/ui/cursor-brush.png") 0 0, auto;
  cursor: image-set(url("/assets/img/ui/cursor-brush.png") 1x, url("/assets/img/ui/cursor-brush@2x.png") 2x) 0 0, auto;
}
input:not([type="button"]):not([type="submit"]):not([type="checkbox"]):not([type="radio"]), textarea { cursor: text; }
.btn[disabled], .day[disabled], .slot[disabled], .cal-nav button[disabled] { cursor: not-allowed; }

/* ---------- 復古紙質皮：G2 素材（材質／頁首橫幅／探索場景） ---------- */
.pp-explore { display: none; }
html.paper body { background: linear-gradient(rgba(30, 22, 16, .86), rgba(30, 22, 16, .86)), var(--bg) url("/assets/img/paper/tex-damask.webp") 0 0 / 360px repeat; }
html.paper .hx { background-color: #060504; }

/* 羊皮紙卡片換真紙紋＋四角銅飾 */
html.paper .callout { position: relative; background: var(--parch) url("/assets/img/paper/tex-paper.webp") 0 0 / 420px repeat; }
html.paper .callout::before, html.paper .callout::after { content: ""; position: absolute; width: 42px; height: 42px; pointer-events: none; background: url("/assets/img/paper/ui-corner.png") center / contain no-repeat; }
html.paper .callout::before { top: -6px; left: -6px; }
html.paper .callout::after { right: -6px; bottom: -6px; transform: rotate(180deg); }

/* 分頁頁首：橫幅圖，左側暗處疊字，下緣撕紙 */
html.paper .page-head, html.paper .themes-page { position: relative; }
html.paper .page-head {
  background: linear-gradient(90deg, rgba(20, 14, 9, .92) 0%, rgba(20, 14, 9, .7) 38%, rgba(20, 14, 9, .1) 75%), var(--hd, none) 70% 50% / cover no-repeat;
  padding-block: clamp(70px, 12vw, 150px) clamp(48px, 7vw, 90px); border-bottom: 0;
}
html.paper .themes-page::before {
  content: ""; position: absolute; inset: 0 0 auto; height: clamp(320px, 42vw, 560px); z-index: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(30, 22, 16, 0) 55%, var(--bg) 100%), linear-gradient(90deg, rgba(20, 14, 9, .9) 0%, rgba(20, 14, 9, .55) 40%, rgba(20, 14, 9, .1) 80%), var(--hd, none) 70% 50% / cover no-repeat;
}

html.paper .page-head .wrap { position: relative; z-index: 1; }
html.paper .page-head h1, html.paper .themes-page h1 { text-shadow: 0 2px 18px rgba(0, 0, 0, .8); }

/* 首頁探索場景 */
html.paper .pp-explore { display: block; padding-bottom: 0; }
html.paper .pp-explore h2 { font-size: clamp(26px, 4vw, 40px); margin-top: 10px; }
.pp-scene { --scene: url("/assets/img/paper/scene-explore-desktop.webp"); position: relative; margin-top: clamp(24px, 4vw, 40px); aspect-ratio: 16 / 9; overflow: hidden; border-block: 1px solid rgba(200, 161, 101, .35); }
.pp-scene picture img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* 物件層：同一張場景圖沿物件輪廓裁出來疊在原位，游標靠近時整塊浮起＋投影（仿 100days 照相館） */
.pp-obj { position: absolute; inset: 0; padding: 0; border: 0; background: none; pointer-events: none; transition: filter .35s; }
/* 每件物件拆成獨立小塊，各自以自身中心放大，蓋住原圖不露邊 */
.pp-cut { position: absolute; inset: 0; pointer-events: auto; background: var(--scene) 0 0 / 100% 100% no-repeat; clip-path: var(--c); transform-origin: var(--o); transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.pp-cut.m { display: none; }
.pp-obj:hover, .pp-obj:focus-visible { z-index: 2; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, .55)) drop-shadow(0 0 10px rgba(240, 205, 140, .3)) brightness(1.08); outline: none; }
.pp-obj:hover .pp-cut, .pp-obj:focus-visible .pp-cut { transform: scale(1.04); }
.pp-obj.hint { z-index: 1; filter: drop-shadow(0 0 12px rgba(240, 205, 140, .45)) brightness(1.06); transition-duration: .55s; }
.pp-obj.hint .pp-cut { transform: scale(1.02); transition-duration: .55s; }
@media (max-width: 700px) {
  .pp-scene { --scene: url("/assets/img/paper/scene-explore-mobile.webp"); aspect-ratio: 9 / 16; }
  .pp-cut.d { display: none; }
  .pp-cut.m { display: block; }
}

/* 點物件跳出的特寫卡片 */
.pp-card {
  width: min(92vw, 560px); padding: 0; border: 1px solid #B88D52; border-radius: 2px; color: #2A1D14; overflow: visible;
  background: #EFE3C8 url("/assets/img/paper/tex-paper.webp") 0 0 / 420px repeat; box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .95);
}
.pp-card::backdrop { background: rgba(12, 8, 5, .72); backdrop-filter: blur(3px); }
.pp-card[open] { animation: pp-card-in .35s cubic-bezier(.2, .7, .2, 1); }
@keyframes pp-card-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }
.pp-card-img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.pp-card-body { position: relative; padding: 20px 24px 24px; display: grid; gap: 10px; justify-items: start; }
.pp-card h3 { font-family: var(--serif); font-size: 22px; letter-spacing: .06em; }
.pp-card-text { font-family: var(--hand, var(--serif)); font-size: 17px; line-height: 1.8; color: #4A3826; }
.pp-card .btn { margin-top: 6px; }
.pp-card-body::before { content: ""; position: absolute; left: 0; right: 0; top: -18px; height: 20px; pointer-events: none; background: url("/assets/img/paper/ui-torn-edge.png") center top / 100% 100% no-repeat; transform: scaleY(-1); }   /* 紙面撕邊壓在特寫圖下緣 */
.pp-card-close { position: absolute; top: 8px; right: 10px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(20, 14, 9, .65); color: #EFE3C8; font-size: 24px; line-height: 1; }
/* 酒紅膠囊按鈕換成 G2 的漆面按鈕圖（兩端各切半圓，中段拉伸） */
html.paper body .btn:not(.ghost):not(.line):not(.lamp) {
  border: 0; border-style: solid; border-image: url("/assets/img/paper/ui-btn-wine.png") 0 100 fill / 0 24px / 0 stretch;
  background: none; box-shadow: none; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .55));
}
html.paper body .btn:not(.ghost):not(.line):not(.lamp):hover { background: none; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .55)) brightness(1.15); }

/* ---------- 首頁鑰匙孔背後：場景橫向輪播（佔位圖，之後換正式場景照） ---------- */
.hx-reel { position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.hx-reel::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(6, 5, 4, .9) 0%, rgba(6, 5, 4, .62) 45%, rgba(6, 5, 4, .7) 100%), radial-gradient(ellipse at 70% 50%, transparent 20%, rgba(6, 5, 4, .55) 75%); }
.hx-track { display: flex; height: 100%; transition: transform 1.6s cubic-bezier(.65, 0, .35, 1); }
.hx-track.snap { transition: none; }
.hx-slide { flex: 0 0 100%; height: 100%; background: var(--img) center / cover no-repeat; filter: sepia(.25) saturate(.85); }
@media (max-width: 700px) { .hx-reel::after { background: rgba(6, 5, 4, .7); } }

/* ---------- 背景音樂開關（頁首右上角） ---------- */
.bgm-btn { flex: none; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: transparent; color: var(--ink); padding: 0; transition: border-color .2s, color .2s; }
.bgm-btn:hover { border-color: var(--brass); color: var(--brass); }
.bgm-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.bgm-btn .off, .bgm-btn[aria-pressed="true"] .on { display: none; }
.bgm-btn[aria-pressed="true"] .off { display: block; }
.bgm-btn .wave { animation: bgm-wave 1.6s ease-in-out infinite; transform-origin: 9px 12px; }
.bgm-btn:not(.playing) .wave { animation: none; opacity: .45; }
@keyframes bgm-wave { 50% { opacity: .35; } }
.site-header .nav { margin-left: auto; }

/* ---------- 色調試作：復古老壁紙（參考金褐大馬士革紋）。?tone=a｜b｜c 切換，?tone=off 回原深褐 ---------- */
html.paper.tone-a body { /* A 舊壁紙金褐：中明度，像照片裡那張壁紙 */
  --bg: #BC9C72; --surface: #C9AB82; --surface-2: #B08E64; --ink: #26180C; --muted: #45301C;
  --brass: #7A4E1E; --lamp: #8A5A24; --line: rgba(46, 30, 16, .3); --focus: #7A4E1E;
  --strip: rgba(150, 118, 80, .55); --fade: 188, 156, 114; --wash: rgba(188, 156, 114, .62); --hdr: rgba(160, 128, 88, .94);
  color-scheme: light;
}
html.paper.tone-b body { /* B 褪色相紙：淺米黃，最亮最好讀 */
  --bg: #D8C4A0; --surface: #E3D2B2; --surface-2: #CDB690; --ink: #33241A; --muted: #6A5039;
  --brass: #84561F; --lamp: #9A6A2C; --line: rgba(51, 36, 26, .22); --focus: #84561F;
  --strip: rgba(196, 170, 128, .6); --fade: 216, 196, 160; --wash: rgba(216, 196, 160, .78); --hdr: rgba(200, 176, 136, .95);
  color-scheme: light;
}
html.paper.tone-c body { /* C 暗金老宅：壁紙壓暗，保留夜感但轉金褐 */
  --bg: #6E5034; --surface: #7C5C3D; --surface-2: #5E432A; --ink: #F4E7CC; --muted: #DCC4A0;
  --brass: #E0B676; --lamp: #E8C58C; --line: rgba(240, 220, 180, .22); --focus: #E8C58C;
  --strip: rgba(70, 50, 32, .6); --fade: 110, 80, 52; --wash: rgba(110, 80, 52, .74); --hdr: rgba(70, 50, 32, .94);
}
html.paper[class*="tone-"] body { background: linear-gradient(var(--wash), var(--wash)), var(--bg) url("/assets/img/paper/tex-damask.webp") 0 0 / 360px repeat; }
html.paper[class*="tone-"] .site-header { background: var(--hdr); border-bottom-color: var(--line); }
html.paper[class*="tone-"] .nav ul a:hover, html.paper[class*="tone-"] .nav ul a[aria-current="page"] { color: var(--ink); }
html.paper[class*="tone-"] input, html.paper[class*="tone-"] select, html.paper[class*="tone-"] textarea { background: var(--surface); color: var(--ink); border-color: var(--line); }
html.paper[class*="tone-"] .site-footer { border-top-color: var(--line); }
html.paper[class*="tone-"] .pp-scene { border-block-color: var(--line); }
/* 淺色版：深字、深色 logo、鏤空按鈕改深字；頁首橫幅改用底色漸層承接 */
html.paper.tone-a .brand .logo-ink, html.paper.tone-b .brand .logo-ink { display: block; }
html.paper.tone-a .brand .logo-light, html.paper.tone-b .brand .logo-light { display: none; }
html.paper.tone-a body .btn.ghost, html.paper.tone-a body .btn.line, html.paper.tone-b body .btn.ghost, html.paper.tone-b body .btn.line { color: var(--ink); }
html.paper[class*="tone-"] .page-head { background: linear-gradient(90deg, rgba(var(--fade), .96) 0%, rgba(var(--fade), .78) 38%, rgba(var(--fade), .05) 78%), var(--hd, none) 70% 50% / cover no-repeat; }
html.paper[class*="tone-"] .themes-page::before { background: linear-gradient(180deg, rgba(var(--fade), 0) 55%, rgb(var(--fade)) 100%), linear-gradient(90deg, rgba(var(--fade), .95) 0%, rgba(var(--fade), .6) 40%, rgba(var(--fade), .05) 80%), var(--hd, none) 70% 50% / cover no-repeat; }
html.paper.tone-a .page-head h1, html.paper.tone-a .themes-page h1, html.paper.tone-b .page-head h1, html.paper.tone-b .themes-page h1 { text-shadow: 0 1px 12px rgba(var(--fade), .9); }
/* 首頁鑰匙孔區維持暗場（電影感），字色固定淺色 */
html.paper.tone-a .hx, html.paper.tone-b .hx { --ink: #EFE3C8; --muted: #CDB894; }
html.paper[class*="tone-"] body::after { background: radial-gradient(120% 90% at 50% 45%, rgb(var(--fade)) 0%, var(--bg) 60%, var(--surface-2) 100%); }
html.paper.tone-a body { --night: #5A3F25; }
html.paper.tone-b body { --night: #6A5036; }
html.paper.tone-c body { --night: #3E2B1A; }
html.paper[class*="tone-"] body { --night-ink: #F4E7CC; --night-muted: #DCC6A2; }

/* ---------- 首頁入口：照相館場景定焦滿版（仿 100days 首頁：一進站就是一整個畫面，滑鼠移過物件點選） ---------- */
html.paper body.home #main > section:not(.pp-explore), html.paper body.home .site-footer { display: none; }
html.paper body.home .pp-explore { position: relative; height: 100vh; height: 100svh; min-height: 480px; overflow: hidden; padding: 0; border: 0; background: #0E0A07; }
html.paper body.home .pp-explore > .wrap { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }   /* 標題留給讀屏，畫面上不顯示 */
html.paper body.home .pp-scene { position: absolute; left: 50%; top: 50%; margin: 0; border: 0; width: max(100vw, 177.78vh); width: max(100vw, 177.78svh); transform: translate(-50%, -50%); }
html.paper body.home .pp-explore::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(14, 10, 7, .7) 0%, rgba(14, 10, 7, 0) 18%, rgba(14, 10, 7, 0) 78%, rgba(14, 10, 7, .55) 100%); }
/* 頁首疊在畫面上：透明底、放大 LOGO 與名稱 */
html.paper body.home .site-header { position: fixed; top: 0; left: 0; right: 0; background: none; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; --ink: #F4E7CC; --muted: #E2CDA8; }
html.paper body.home .brand .logo-ink { display: none; }
html.paper body.home .brand .logo-light { display: block; width: 46px; }
html.paper body.home .brand-text b { font-size: 22px; color: #F4E7CC; text-shadow: 0 2px 10px rgba(0, 0, 0, .7); }
html.paper body.home .brand-text small { font-size: 11px; color: #E2CDA8; text-shadow: 0 1px 8px rgba(0, 0, 0, .7); }
html.paper body.home .nav ul a { text-shadow: 0 1px 8px rgba(0, 0, 0, .8); }
html.paper body.home .menu-btn, html.paper body.home .bgm-btn { color: #F4E7CC; border-color: rgba(244, 231, 204, .45); background: rgba(14, 10, 7, .35); }
/* 底部提示 */
.pp-tip { display: none; }
html.paper body.home .pp-tip { display: block; position: absolute; z-index: 3; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); margin: 0; pointer-events: none; white-space: nowrap; font: 500 14px/1 var(--serif); letter-spacing: .2em; color: #F4E7CC; text-shadow: 0 1px 10px rgba(0, 0, 0, .9); animation: pp-tip 3.2s ease-in-out infinite; }
html.paper body.home .pp-tip-m { display: none; }
@keyframes pp-tip { 50% { opacity: .45; } }
@media (hover: none), (max-width: 700px) { html.paper body.home .pp-tip-d { display: none; } html.paper body.home .pp-tip-m { display: inline; } }
@media (max-width: 700px) {
  html.paper body.home .pp-scene { width: max(100vw, 56.25vh); width: max(100vw, 56.25svh); }
  html.paper body.home .brand .logo-light { width: 36px; }
  html.paper body.home .brand-text b { font-size: 18px; }
}

/* ---------- 色調 M：管理台淺米色（#FAF7F0 底、白卡、金色重點），目前預設 ---------- */
html.paper.tone-m body {
  --bg: #FAF7F0; --surface: #FFFFFF; --surface-2: #F0EDE8; --ink: #1A1815; --muted: #6E6A64;
  --brass: #B08530; --lamp: #C79A3A; --line: #E4DFD6; --focus: #C79A3A;
  --strip: #F0EDE8; --fade: 250, 247, 240; --wash: rgba(250, 247, 240, .94); --hdr: rgba(250, 247, 240, .94);
  --night: #F0EDE8; --night-ink: #1A1815; --night-muted: #6E6A64; --parch: #FFFFFF; --wine: #C79A3A;
  color-scheme: light;
}
html.paper.tone-m .brand .logo-ink { display: block; }
html.paper.tone-m .brand .logo-light { display: none; }
html.paper.tone-m .page-head h1, html.paper.tone-m .themes-page h1 { text-shadow: 0 1px 12px rgba(250, 247, 240, .9); }
html.paper.tone-m .hx { --ink: #EFE3C8; --muted: #CDB894; }
html.paper.tone-m .site-footer .social-btn { background: var(--ink); color: var(--bg); }
/* 按鈕：管理台金色實心、圓角 10px */
html.paper.tone-m body .btn, html.paper.tone-m body .btn:not(.ghost):not(.line):not(.lamp) { border: 1px solid #C79A3A; border-image: none; border-radius: 10px; background: #C79A3A; color: #1A1815; box-shadow: none; filter: none; padding-inline: 22px; }
html.paper.tone-m body .btn:hover, html.paper.tone-m body .btn:not(.ghost):not(.line):not(.lamp):hover { background: #B08530; border-color: #B08530; color: #1A1815; filter: none; }
html.paper.tone-m body .btn.ghost, html.paper.tone-m body .btn.line { background: #FFFFFF; color: var(--ink); border-color: var(--line); }
html.paper.tone-m body .btn.ghost:hover, html.paper.tone-m body .btn.line:hover { background: #F0EDE8; color: var(--ink); }
/* 卡片：白底細框圓角，像管理台面板 */
html.paper.tone-m .callout { --ink: #1A1815; --muted: #6E6A64; --line: #E4DFD6; --brass: #B08530; --surface: #F0EDE8; background: #FFFFFF; border: 1px solid #E4DFD6; border-radius: 14px; box-shadow: 0 6px 24px -14px rgba(26, 24, 21, .25); }
html.paper.tone-m .callout::before, html.paper.tone-m .callout::after { display: none; }
html.paper.tone-m .callout .btn.ghost { color: var(--ink); border-color: var(--line); }
html.paper.tone-m input, html.paper.tone-m select, html.paper.tone-m textarea { background: #FFFFFF; border-color: #E4DFD6; border-radius: 8px; }
/* 首頁場景上的頁首維持淺字（疊在照片上） */
html.paper.tone-m body.home .brand .logo-ink { display: none; }
html.paper.tone-m body.home .brand .logo-light { display: block; }
html.paper.tone-m body.home .nav ul a { color: #F4E7CC; }
html.paper.tone-m body.home .nav ul a:hover, html.paper.tone-m body.home .nav ul a[aria-current="page"] { color: #FFFFFF; border-bottom-color: #C79A3A; }
@media (max-width: 820px) { html.paper.tone-m body.home .nav ul { background: #FAF7F0; } html.paper.tone-m body.home .nav ul a { color: #1A1815; text-shadow: none; } }

/* ---------- 色調 M：管理台淺米色（#FAF7F0 底、白卡、金色重點），目前預設 ---------- */
html.paper.tone-m body {
  --bg: #FAF7F0; --surface: #FFFFFF; --surface-2: #F0EDE8; --ink: #1A1815; --muted: #6E6A64;
  --brass: #B08530; --lamp: #C79A3A; --line: #E4DFD6; --focus: #C79A3A;
  --strip: #F0EDE8; --fade: 250, 247, 240; --wash: rgba(250, 247, 240, .94); --hdr: rgba(250, 247, 240, .94);
  --night: #F0EDE8; --night-ink: #1A1815; --night-muted: #6E6A64; --parch: #FFFFFF; --wine: #C79A3A;
  color-scheme: light;
}
html.paper.tone-m .brand .logo-ink { display: block; }
html.paper.tone-m .brand .logo-light { display: none; }
html.paper.tone-m .page-head h1, html.paper.tone-m .themes-page h1 { text-shadow: 0 1px 12px rgba(250, 247, 240, .9); }
html.paper.tone-m .hx { --ink: #EFE3C8; --muted: #CDB894; }
html.paper.tone-m .site-footer .social-btn { background: var(--ink); color: var(--bg); }
/* 按鈕：管理台金色實心、圓角 10px */
html.paper.tone-m body .btn, html.paper.tone-m body .btn:not(.ghost):not(.line):not(.lamp) { border: 1px solid #C79A3A; border-image: none; border-radius: 10px; background: #C79A3A; color: #1A1815; box-shadow: none; filter: none; padding-inline: 22px; }
html.paper.tone-m body .btn:hover, html.paper.tone-m body .btn:not(.ghost):not(.line):not(.lamp):hover { background: #B08530; border-color: #B08530; color: #1A1815; filter: none; }
html.paper.tone-m body .btn.ghost, html.paper.tone-m body .btn.line { background: #FFFFFF; color: var(--ink); border-color: var(--line); }
html.paper.tone-m body .btn.ghost:hover, html.paper.tone-m body .btn.line:hover { background: #F0EDE8; color: var(--ink); }
/* 卡片：白底細框圓角，像管理台面板 */
html.paper.tone-m .callout { --ink: #1A1815; --muted: #6E6A64; --line: #E4DFD6; --brass: #B08530; --surface: #F0EDE8; background: #FFFFFF; border: 1px solid #E4DFD6; border-radius: 14px; box-shadow: 0 6px 24px -14px rgba(26, 24, 21, .25); }
html.paper.tone-m .callout::before, html.paper.tone-m .callout::after { display: none; }
html.paper.tone-m .callout .btn.ghost { color: var(--ink); border-color: var(--line); }
html.paper.tone-m input, html.paper.tone-m select, html.paper.tone-m textarea { background: #FFFFFF; border-color: #E4DFD6; border-radius: 8px; }
/* 首頁場景上的頁首維持淺字（疊在照片上） */
html.paper.tone-m body.home .brand .logo-ink { display: none; }
html.paper.tone-m body.home .brand .logo-light { display: block; }
html.paper.tone-m body.home .nav ul a { color: #F4E7CC; }
html.paper.tone-m body.home .nav ul a:hover, html.paper.tone-m body.home .nav ul a[aria-current="page"] { color: #FFFFFF; border-bottom-color: #C79A3A; }
@media (max-width: 820px) { html.paper.tone-m body.home .nav ul { background: #FAF7F0; } html.paper.tone-m body.home .nav ul a { color: #1A1815; text-shadow: none; } }

/* ---------- 色調 V：復古金褐壁紙（參考韓劇官網相簿頁；底圖＝G2 大馬士革紋改色），目前預設 ---------- */
html.paper.tone-v body {
  --bg: #AB8E73; --surface: #D6BB9C; --surface-2: #C2A485; --ink: #2B1D12; --muted: #3F2D1F;
  --brass: #5A3E26; --lamp: #6B4A2E; --line: rgba(43, 29, 18, .28); --focus: #4A3A2F;
  --strip: rgba(88, 72, 61, .25); --fade: 171, 142, 115; --hdr: rgba(62, 49, 40, .95);
  --night: #3E3128; --night-ink: #F1E2CC; --night-muted: #CDB596; --parch: #D6BB9C; --wine: #4A3A2F;
  color-scheme: light;
}
html.paper.tone-v body { background: #AB8E73 url("/assets/img/paper/tex-damask-tan.webp") 0 0 / 420px repeat; }
/* 頁首：深咖啡底＋米色字，像參考圖的深色頁籤 */
html.paper.tone-v .site-header { background: var(--hdr); border-bottom: 1px solid rgba(214, 187, 156, .25); --ink: #F1E2CC; --muted: #D9C3A4; }
html.paper.tone-v .brand .logo-ink { display: none; }
html.paper.tone-v .brand .logo-light { display: block; }
html.paper.tone-v .nav ul a:hover, html.paper.tone-v .nav ul a[aria-current="page"] { color: #FFF3DF; border-bottom-color: #D6BB9C; }
@media (max-width: 820px) { html.paper.tone-v .nav ul { background: #3E3128; } }
html.paper.tone-v .bgm-btn { color: #F1E2CC; border-color: rgba(241, 226, 204, .4); }
/* 按鈕：深咖啡膠囊＋米字；次要按鈕＝淺米膠囊＋深字（參考圖頁籤一深一淺） */
html.paper.tone-v body .btn, html.paper.tone-v body .btn:not(.ghost):not(.line):not(.lamp) { border: 1px solid #2B1D12; border-image: none; border-radius: 999px; background: linear-gradient(#5E4C40, #44362C); color: #F1E2CC; box-shadow: inset 0 1px 0 rgba(255, 240, 215, .15), 0 4px 10px -4px rgba(30, 20, 12, .6); filter: none; padding-inline: 24px; }
html.paper.tone-v body .btn:hover, html.paper.tone-v body .btn:not(.ghost):not(.line):not(.lamp):hover { background: linear-gradient(#6E5A4C, #514034); color: #FFF3DF; filter: none; }
html.paper.tone-v body .btn.ghost, html.paper.tone-v body .btn.line { background: linear-gradient(#DCC3A6, #C4A786); color: #2B1D12; border-color: #6B4A2E; box-shadow: none; }
html.paper.tone-v body .btn.ghost:hover, html.paper.tone-v body .btn.line:hover { background: linear-gradient(#E6D0B6, #CFB394); color: #2B1D12; }
/* 卡片：舊紙＋木框（參考圖標題牌） */
html.paper.tone-v .callout { --ink: #2B1D12; --muted: #4F3B2A; --line: rgba(43, 29, 18, .22); --brass: #5A3E26; --surface: #E2CBAE; background: #D9BF9F url("/assets/img/paper/tex-paper.webp") 0 0 / 420px repeat; background-blend-mode: multiply; border: 3px solid #6B4A2E; border-radius: 2px; box-shadow: inset 0 0 0 2px #3A2716, inset 0 0 18px rgba(90, 60, 30, .35), 0 10px 24px -12px rgba(30, 20, 12, .7); }
html.paper.tone-v .callout .btn.ghost { color: #2B1D12; }
html.paper.tone-v input, html.paper.tone-v select, html.paper.tone-v textarea { background: #E2CBAE; color: #2B1D12; border-color: rgba(43, 29, 18, .35); }
/* 分頁頁首橫幅：左側用壁紙色承接標題 */
html.paper.tone-v .page-head { background: linear-gradient(90deg, rgba(171, 142, 115, .97) 0%, rgba(171, 142, 115, .8) 38%, rgba(171, 142, 115, .05) 78%), var(--hd, none) 70% 50% / cover no-repeat; }
html.paper.tone-v .themes-page::before { background: linear-gradient(180deg, rgba(171, 142, 115, 0) 55%, #AB8E73 100%), linear-gradient(90deg, rgba(171, 142, 115, .95) 0%, rgba(171, 142, 115, .6) 40%, rgba(171, 142, 115, .05) 80%), var(--hd, none) 70% 50% / cover no-repeat; }
html.paper.tone-v .page-head h1, html.paper.tone-v .themes-page h1 { text-shadow: 0 1px 10px rgba(214, 187, 156, .7); }
html.paper.tone-v .hx { --ink: #EFE3C8; --muted: #CDB894; }
html.paper.tone-v .site-footer .social-btn { background: #D6BB9C; color: #2B1D12; }
html.paper.tone-v body::after { background: #AB8E73 url("/assets/img/paper/tex-damask-tan.webp") 0 0 / 420px repeat; }
/* 首頁照相館畫面：頁首改透明疊在照片上 */
html.paper.tone-v body.home .site-header { background: linear-gradient(rgba(30, 22, 16, .55), rgba(30, 22, 16, 0)); border: 0; }
html.paper.tone-v .site-header .brand-text b { color: #F1E2CC; } html.paper.tone-v .site-header .brand-text small { color: #D9C3A4; }

/* 雲影：只在畫面本身受光處，用預先壓暗的同一張圖＋緩慢漂移的柔邊雲遮罩 */
.pp-cloud { position: absolute; inset: 0; z-index: 1; pointer-events: none; background: url("/assets/img/paper/scene-cloud-desktop.webp") 0 0 / 100% 100% no-repeat;
  -webkit-mask: url("/assets/img/paper/cloud-mask.png") 0 0 / 150% 100% repeat-x; mask: url("/assets/img/paper/cloud-mask.png") 0 0 / 150% 100% repeat-x;
  animation: pp-cloud-drift 95s linear infinite; }
@keyframes pp-cloud-drift { from { -webkit-mask-position: 0% 0; mask-position: 0% 0; } to { -webkit-mask-position: -300% 0; mask-position: -300% 0; } }
@media (max-width: 700px) {
  .pp-cloud { background-image: url("/assets/img/paper/scene-cloud-mobile.webp"); -webkit-mask-size: 300% 100%; mask-size: 300% 100%; animation-name: pp-cloud-drift-m; animation-duration: 120s; }
  @keyframes pp-cloud-drift-m { from { -webkit-mask-position: 0% 0; mask-position: 0% 0; } to { -webkit-mask-position: -150% 0; mask-position: -150% 0; } }
}
@media (prefers-reduced-motion: reduce) { .pp-cloud { animation: none; } }

/* G2 去背圖層：pp-cut 只當點擊熱區，浮起的是真實輪廓圖層 */
.pp-cut { background: none !important; transform: none !important; }
.pp-lay, .pp-lamp { position: absolute; height: auto; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.pp-lay { opacity: 0; transform-origin: var(--o); transition: opacity .2s, transform .35s cubic-bezier(.2,.7,.2,1); }
.pp-obj:hover .pp-lay, .pp-obj:focus-visible .pp-lay, .pp-obj.hint .pp-lay { opacity: 1; transform: translateY(-.35%) scale(1.025); }
.pp-obj.hint .pp-lay { transform: scale(1.012); transition-duration: .55s; }
.pp-lamp { z-index: 3; }
.pp-lay.m, .pp-lamp.m { display: none; }
@media (max-width: 700px) { .pp-lay.d, .pp-lamp.d { display: none; } .pp-lay.m, .pp-lamp.m { display: block; } }

/* 預約月曆（tone v）：日期改米白，與棕底拉開對比 */
html.paper.tone-v .day { background: #5A4536; border-color: #3E3128; color: #F4E7CC; }
html.paper.tone-v .day[disabled] { background: rgba(62, 49, 40, .35); border-color: rgba(244, 231, 204, .25); color: #F4E7CC; opacity: .6; }
html.paper.tone-v .day.full { color: #E6D3B3; }
html.paper.tone-v .day:hover:not([disabled]) { border-color: #F4E7CC; }
html.paper.tone-v .day[aria-pressed="true"] { background: #F4E7CC; color: #2B1D12; border-color: #F4E7CC; }
html.paper.tone-v .day[aria-pressed="true"] small { color: #2B1D12; }
html.paper.tone-v .cal .dow { color: #F4E7CC; }

/* 手機：頂部選單跟著頁面捲走，不固定 */
@media (max-width: 700px) {
  .site-header { position: relative; top: 0; }
}

/* 鑰匙孔開場（首次進站）：鑰匙孔頁蓋在照相館之上，點擊推進後淡出 */
html.paper.kh-intro body.home #main > .hx { display: grid; align-content: center; position: fixed; inset: 0; z-index: 80; overflow: hidden auto; }
html.paper.kh-intro body.home .hx .ticker { position: absolute; left: 0; right: 0; bottom: 0; }
html.paper body.home .hx { transition: transform 1.4s cubic-bezier(.7, 0, .25, 1), opacity .6s ease .85s; }
html.paper.kh-zoom body.home .hx { transform: scale(9); opacity: 0; pointer-events: none; }
html.paper.kh-return body.home .hx { opacity: 0; transition: none; }
html.paper.kh-intro body.home .pp-scene { transform: translate(-50%, -50%) scale(1.06); filter: brightness(.55) blur(2px); }
html.paper body.home .pp-scene { transition: transform 1.6s cubic-bezier(.2, .7, .2, 1) .25s, filter 1.2s ease .3s; }
html.paper.kh-intro body.home .site-header { visibility: hidden; }
.kh-skip { position: absolute; right: clamp(16px, 3vw, 32px); top: clamp(16px, 3vw, 28px); z-index: 6; padding: 8px 16px; border: 1px solid rgba(239, 227, 200, .45); border-radius: 999px; background: rgba(20, 14, 10, .45); color: #EFE3C8; font: 500 13px/1 var(--sans); letter-spacing: .12em; cursor: pointer; }
.kh-skip:hover, .kh-skip:focus-visible { background: rgba(20, 14, 10, .75); border-color: #EFE3C8; outline: none; }
.pp-replay { display: none; }
html.paper body.home .pp-replay { display: block; position: absolute; left: clamp(16px, 3vw, 32px); bottom: clamp(18px, 3vw, 28px); z-index: 4; padding: 8px 16px; border: 1px solid rgba(244, 231, 204, .4); border-radius: 999px; background: rgba(20, 14, 10, .4); color: #F4E7CC; font: 500 13px/1 var(--sans); letter-spacing: .12em; cursor: pointer; }
html.paper body.home .pp-replay:hover, html.paper body.home .pp-replay:focus-visible { background: rgba(20, 14, 10, .7); outline: none; }
@media (prefers-reduced-motion: reduce) {
  html.paper body.home .hx { transition: opacity .4s; }
  html.paper.kh-zoom body.home .hx { transform: none; }
  html.paper body.home .pp-scene { transition: none; }
}
/* 手機開場：內容由上往下排、可上下滑動，不再上下被裁；跑馬燈回到內容底部 */
@media (max-width: 700px) {
  html.paper.kh-intro body.home #main > .hx { display: block; height: 100%; height: 100dvh; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; touch-action: pan-y; }
  html.paper.kh-intro body.home .hx .hx-grid { padding-top: calc(64px + env(safe-area-inset-top, 0px)); padding-bottom: 32px; }
  html.paper.kh-intro body.home .hx .ticker { position: relative; bottom: auto; }
  html.paper.kh-intro body.home .hx .keyhole-link .kh-glow { width: min(72%, 300px); }
  html.paper.kh-intro body.home .kh-skip { position: fixed; top: calc(14px + env(safe-area-inset-top, 0px)); }
  html.paper.kh-intro, html.paper.kh-intro body { overflow: hidden; }
  html.paper.kh-intro body.home .hx .hx-reel, html.paper.kh-intro body.home .hx .layer, html.paper.kh-intro body.home .hx .grain-canvas { position: fixed; }
  /* 2026-10-25：開場整頁收進一個畫面（不用滑動、上下不被裁）；文字與鑰匙孔依螢幕高度縮放 */
  html.paper.kh-intro body.home #main > .hx { display: flex; flex-direction: column; overflow: hidden; }
  html.paper.kh-intro body.home .hx .hx-grid { flex: 1; min-height: 0; display: flex; flex-direction: column; justify-content: space-evenly; gap: 2dvh; padding-top: calc(56px + env(safe-area-inset-top, 0px)); padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px)); }
  html.paper.kh-intro body.home .hx .copy { gap: min(14px, 1.4dvh); }
  html.paper.kh-intro body.home .hx h1 { font-size: min(9.6vw, 40px, 6dvh); }
  html.paper.kh-intro body.home .hx .rotator { font-size: min(16px, 2.5dvh); min-height: 0; }
  html.paper.kh-intro body.home .hx .lede { font-size: min(15px, 2.4dvh); }
  html.paper.kh-intro body.home .hx .cta, html.paper.kh-intro body.home .hx .ticker { display: none; }
  html.paper.kh-intro body.home .hx .keyhole-link { gap: 1.6dvh; }
  html.paper.kh-intro body.home .hx .keyhole-link .kh-glow { width: min(62vw, 250px, 24dvh); }
}
@media (max-width: 700px) and (max-height: 620px) {
  html.paper.kh-intro body.home .hx .rotator { display: none; }
}

/* 預約場次（tone v）：與月曆同一套深咖底＋米白字 */
html.paper.tone-v .slot { background: #5A4536; border-color: #3E3128; color: #F4E7CC; }
html.paper.tone-v .slot.available span { color: #B9E2A6; }
html.paper.tone-v .slot.full span { color: #F2A894; }
html.paper.tone-v .slot.paused span { color: #D9CBB4; }
html.paper.tone-v .slot:hover:not([disabled]) { border-color: #F4E7CC; }
html.paper.tone-v .slot[aria-pressed="true"] { background: #F4E7CC; color: #2B1D12; border-color: #F4E7CC; }
html.paper.tone-v .slot[aria-pressed="true"] span { color: #2B1D12; }
html.paper.tone-v .day small { color: #B9E2A6; }
html.paper.tone-v .day.full small { color: #F2A894; }

/* 鑰匙孔背景輪播：整條軌道交給 GPU 合成，去掉逐格重繪的濾鏡與模糊動畫，橫移才順 */
.hx-track { will-change: transform; transform: translate3d(0, 0, 0); backface-visibility: hidden; }
.hx-slide { filter: none; backface-visibility: hidden; }
.hx-reel::before { content: ""; position: absolute; inset: 0; z-index: 1; background: rgba(70, 45, 20, .14); pointer-events: none; }
html.paper body.home .hx .layer, html.paper body.home .hx .grain-canvas { display: none; }
/* 開場期間後方照相館靜止：雲影暫停、不做模糊，避免與前景輪播搶效能 */
html.paper.kh-intro body.home .pp-cloud { animation-play-state: paused; }
html.paper.kh-intro body.home .pp-scene { filter: brightness(.55); }
/* 開場短片片尾慢慢淡出，露出照相館；備援推進時先把開場頁交給 GPU */
.portal-intro.pp-long { transition: opacity .9s ease; }
html.paper.kh-zoom body.home .hx { will-change: transform, opacity; }

/* 老鑰匙（G2）：跟櫃台圖層同框，櫃台浮起時一起動；本身是「重看開場」按鈕 */
.pp-keybox { position: absolute; z-index: 5; pointer-events: none; transform-origin: var(--o); transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.pp-keybox.m { display: none; }
.pp-key-wrap { position: absolute; display: block; }
.pp-key { position: relative; display: block; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; pointer-events: auto; -webkit-tap-highlight-color: transparent; }
.pp-key::after { content: ""; position: absolute; left: 50%; top: 50%; width: max(100%, 44px); height: max(100%, 44px); transform: translate(-50%, -50%); }
.pp-key img { display: block; width: 100%; height: auto; transform-origin: 30% 60%; animation: pp-key-glint 7s ease-in-out 2s infinite; transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.pp-key:hover img, .pp-key:focus-visible img { animation: none; transform: translateY(-10%) rotate(-5deg) scale(1.18); filter: drop-shadow(0 0 6px rgba(255, 214, 140, .9)) brightness(1.18); }
.pp-key:focus-visible { outline: none; }
@keyframes pp-key-glint { 0%, 86%, 100% { filter: none; } 92% { filter: drop-shadow(0 0 5px rgba(255, 220, 150, .85)) brightness(1.25); } }
.pp-obj[data-hs="counter"]:hover ~ .pp-keybox, .pp-obj[data-hs="counter"]:focus-visible ~ .pp-keybox { transform: translateY(-.35%) scale(1.025); }
.pp-obj[data-hs="counter"].hint ~ .pp-keybox { transform: scale(1.012); transition-duration: .55s; }
@media (max-width: 700px) { .pp-keybox.d { display: none; } .pp-keybox.m { display: block; } }
@media (prefers-reduced-motion: reduce) { .pp-key img { animation: none; } }
/* 輪播影片鋪滿每格 */
.hx-slide video { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 首頁場景左上角「回到開場」按鈕（開場播放中隱藏） */
.pp-back { display: none; }
html.paper body.home .pp-back { display: grid; place-items: center; position: fixed; top: calc(72px + env(safe-area-inset-top, 0px)); left: 16px; z-index: 60; width: 38px; height: 38px; padding: 0; border: 1px solid rgba(244, 231, 204, .45); border-radius: 50%; background: rgba(20, 14, 10, .5); color: #F4E7CC; cursor: pointer; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
html.paper body.home .pp-back svg { pointer-events: none; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
html.paper body.home .pp-back:hover, html.paper body.home .pp-back:focus-visible { background: rgba(20, 14, 10, .78); border-color: #F4E7CC; outline: none; }
html.paper.kh-intro body.home .pp-back { display: none; }

/* 物件提示光暈加強（2026-10-25 Mr.P：原本太微弱；參照《100일의 거짓말》照相館頁的暖金色外光），時間不變 */
.pp-obj.hint { filter: drop-shadow(0 0 4px rgba(255, 222, 160, .95)) drop-shadow(0 0 16px rgba(245, 196, 110, .8)) drop-shadow(0 0 34px rgba(230, 170, 80, .45)) brightness(1.14); }
.pp-obj:hover, .pp-obj:focus-visible { filter: drop-shadow(0 0 4px rgba(255, 222, 160, .95)) drop-shadow(0 0 18px rgba(245, 196, 110, .85)) drop-shadow(0 10px 14px rgba(0, 0, 0, .45)) brightness(1.12); }

/* 2026-11-07 Mr.P：實景圖與宣傳片完成前，以 COMING SOON 佔位 */
.coming-soon { display: grid; place-items: center; width: 100%; background: var(--surface-2, #CDB690); color: var(--ink, #33241A); border: 1px solid rgba(51, 36, 26, .22); box-sizing: border-box; }
.coming-soon b { font-family: "Cinzel", serif; font-weight: 600; font-size: clamp(16px, 2.2vw, 26px); letter-spacing: .22em; text-align: center; }
.poster.coming-soon { display: grid; filter: none !important; text-decoration: none; }
.poster-frame, .poster-frame:hover { text-decoration: none; }
.coming-soon b { text-decoration: none; display: inline-block; }
.scene-soon { aspect-ratio: 3 / 1; }
@media (max-width: 720px) { .scene-soon { aspect-ratio: 16 / 9; } }
.trailer.coming-soon { background: var(--surface-2, #CDB690); }
.stars .half svg { fill: url(#star-half); }
.price-bar .amount { flex-wrap: wrap; }
.price-later { display: block; flex-basis: 100%; margin-top: 4px; font-family: inherit; font-size: 13px; font-weight: 500; letter-spacing: .02em; white-space: nowrap; }

/* 後台分頁：場次管理／所有預約 */
.admin-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line, rgba(0, 0, 0, .18)); margin-bottom: 16px; }
.admin-tabs a { padding: 10px 18px; font-weight: 500; font-size: 15px; color: inherit; opacity: .6; text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.admin-tabs a:hover { opacity: 1; }
.admin-tabs a[aria-current="page"] { opacity: 1; font-weight: 700; border-bottom-color: currentColor; }

/* 2026-11-10 首頁卡頓修正：鑰匙孔的三層光暈陰影不再逐格重算（孔內呼吸亮度動畫會迫使外層陰影每格重畫），
   光暈層、跑馬燈各自交給 GPU 合成 */
html[data-kh] .keyhole.void { animation: none; filter: none; }
html[data-kh] .keyhole-link .kh-glow { will-change: transform; }
@keyframes kh-invite { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.035); } }
.ticker .track { will-change: transform; transform: translate3d(0, 0, 0); }
@keyframes roll { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }

/* 開場期間後方照相館完全被鑰匙孔頁蓋住：停止繪製，避免濾鏡逐格重算拖慢輪播與跑馬燈（重看開場時等鑰匙孔頁淡入完才隱藏） */
html.paper.kh-intro:not(.kh-zoom) body.home .pp-scene { visibility: hidden; transition: transform 1.6s cubic-bezier(.2, .7, .2, 1) .25s, filter 1.2s ease .3s, visibility 0s linear 1.5s; }
.en-brand { font-family: var(--latin); font-weight: 600; letter-spacing: .14em; }
/* 英文品牌字：依 LOGO 動畫定稿（幾何無襯線，MIST 粗／STUDIO 細） */
.en-logo, .brand-text small.en-logo { font-family: "Jost", "Futura", sans-serif; font-weight: 300; letter-spacing: .16em; text-transform: uppercase; }
.en-logo b { font-weight: 600; }
.brand-text small.en-logo { font-size: 11px; }
.brand-text small.en-logo b { font: 600 11px/1.2 "Jost", "Futura", sans-serif; letter-spacing: .16em; }
/* 手機：老鑰匙的 44px 觸控區會蓋到左側轉盤電話，點電話卻回到開場 → 觸控區縮回鑰匙本體 */
@media (max-width: 700px) { .pp-keybox.m .pp-key::after { width: 100%; height: 100%; } }

/* 主題頁年齡卡：只放放大的 12+ 圖示，置中 */
.tp-facts li.tp-age { align-content: center; }
.tp-facts li.tp-age svg { width: 68px; height: 68px; margin: 0; }

/* 11-19 實景照片：直式 3:4 */
.tp-gallery .scene-shot img { aspect-ratio: 3 / 4; }

/* 11-19 場景照：不寫場景名，改英文短句；滑過金邊＋VIEW；大圖左右切換 */
.tp-gallery .scene-shot { outline: 1px solid transparent; outline-offset: -1px; transition: outline-color .4s; }
.tp-gallery .scene-shot:hover { outline-color: var(--brass); }
.scene-shot figcaption .scene-en { font-family: var(--latin, Georgia, serif); font-weight: 600; font-size: 14px; letter-spacing: .06em; font-style: italic; }
.scene-viewer .nav { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 64px; border: 0; background: none; color: #F1E6D0; font-size: 44px; line-height: 1; cursor: pointer; opacity: .75; }
.scene-viewer .nav:hover { opacity: 1; }
.scene-viewer .prev { left: 8px; } .scene-viewer .next { right: 8px; }
.scene-viewer p { font-family: var(--latin, Georgia, serif); }
.scene-shot figcaption .scene-en { font-style: normal; font-size: 13px; letter-spacing: .04em; }
.scene-shot figcaption small { white-space: nowrap; flex-shrink: 0; margin-left: 10px; }
.scene-shot figcaption { align-items: flex-end; }
.scene-shot figcaption .scene-en { line-height: 1.5; padding-right: 6px; }
.scene-shot figcaption { padding-left: 14px; padding-right: 12px; }
.scene-shot figcaption .scene-en { font-size: 12.5px; letter-spacing: .01em; white-space: nowrap; overflow: hidden; text-overflow: clip; padding-right: 0; }
.scene-shot figcaption small { margin-left: 8px; }
.scene-shot figcaption .scene-en { white-space: normal; overflow: visible; text-wrap: balance; }
