/* ============================================================
   天坛旅拍商拍作品集 · 移动端优先视觉系统
   ——墨黑 · 朱红 · 金线 · 宣纸白
   ============================================================ */

:root {
  --ink: #12100d;
  --ink-2: #1d1712;
  --ink-3: #2a2218;
  --paper: #f5efe3;
  --paper-2: #ded2bd;
  --paper-3: #bab0a0;
  --red: #8f241b;
  --red-deep: #4e1612;
  --gold: #c6a15b;
  --gold-soft: #d4bc82;
  --line: rgba(222, 210, 189, 0.18);
  --line-strong: rgba(198, 161, 91, 0.45);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --shadow-gold: 0 8px 32px rgba(198, 161, 91, 0.2);
  --serif: "Songti SC", "STSong", "Noto Serif CJK SC", "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;

  /* Motion toggle to avoid unused (占位，用于后续扩展空间) */
}

/* ========== 基础重置 ========== */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--serif);
  font-size: 15px;
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  padding-top: env(safe-area-inset-top, 0);
  padding-bottom: env(safe-area-inset-bottom, 0);
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  background: transparent;
  border: none;
  cursor: pointer;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

/* ========== 动态背景层：水墨晕染、颗粒、浮动元素 ========== */

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.08;
  background-image:
    radial-gradient(circle at 20% 30%, #000 0.5px, transparent 0.5px),
    radial-gradient(circle at 80% 70%, #000 0.5px, transparent 0.5px);
  background-size: 4px 4px, 5px 5px;
  mix-blend-mode: overlay;
}

.ink-wash {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.ink-wash span {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.25;
  animation: ink-drift 25s ease-in-out infinite;
}

.ink-wash span:nth-child(1) {
  width: 60vw;
  height: 60vw;
  top: -10vw;
  left: -20vw;
  background: radial-gradient(circle, var(--red) 0%, transparent 70%);
  animation-duration: 30s;
}

.ink-wash span:nth-child(2) {
  width: 70vw;
  height: 70vw;
  top: 40vh;
  right: -30vw;
  background: radial-gradient(circle, #3a2a1a 0%, transparent 70%);
  animation-duration: 35s;
  animation-delay: -10s;
}

.ink-wash span:nth-child(3) {
  width: 50vw;
  height: 50vw;
  bottom: -10vw;
  left: 30vw;
  background: radial-gradient(circle, var(--gold) 0%, transparent 70%);
  animation-duration: 40s;
  animation-delay: -20s;
  opacity: 0.12;
}

@keyframes ink-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(3vw, 5vh) scale(1.1); }
  66% { transform: translate(-4vw, -3vh) scale(0.9); }
}

/* 花瓣/金点浮动元素 */

.floating-petals {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}

/* ========== 顶部导航栏 ========== */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  background: linear-gradient(180deg, rgba(18, 16, 13, 0.9) 0%, rgba(18, 16, 13, 0) 85%, transparent);
  backdrop-filter: blur(14px) saturate(180%);
  -webkit-backdrop-filter: blur(14px) saturate(180%);
  padding-top: calc(env(safe-area-inset-top, 0) + 14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--sans);
  color: var(--paper);
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--gold);
  font-family: var(--serif);
  font-size: 16px;
  letter-spacing: 0;
  box-shadow: 0 0 0 0 rgba(198, 161, 91, 0);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.brand:active .brand-mark {
  transform: scale(0.96);
  box-shadow: 0 0 16px 2px rgba(198, 161, 91, 0.4);
}

.brand-text {
  font-size: 13px;
  letter-spacing: 0.1em;
  max-width: 45vw;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.site-header nav {
  display: none; /* 桌面端再显示 */
}

.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--paper-2);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.1em;
  transition: all 0.25s ease;
}

.lang-toggle span {
  padding: 1px 2px;
  opacity: 0.5;
  transition: opacity 0.25s ease, color 0.25s ease;
}

.lang-toggle span.is-active {
  color: var(--gold);
  opacity: 1;
}

.lang-toggle:active {
  transform: scale(0.96);
  border-color: var(--gold);
}

/* ========== 移动端 Tab Bar 导航 ========== */

.mobile-nav {
  position: fixed;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99;
  display: flex;
  gap: 2px;
  padding: 6px;
  background: rgba(18, 16, 13, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow);
  padding-bottom: calc(env(safe-area-inset-bottom, 0) + 6px);
}

.mobile-nav-item {
  display: grid;
  place-items: center;
  padding: 10px 16px;
  font-family: var(--serif);
  font-size: 16px;
  letter-spacing: 0.15em;
  color: var(--paper-2);
  border-radius: 999px;
  transition: all 0.35s ease;
  position: relative;
}

.mobile-nav-item.is-active {
  color: var(--gold);
  background: rgba(198, 161, 91, 0.08);
}

.mobile-nav-item.is-active::after {
  content: "";
  position: absolute;
  bottom: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  background: var(--gold);
  border-radius: 50%;
  box-shadow: 0 0 8px 2px rgba(198, 161, 91, 0.6);
}

/* ========== HERO 首屏 ========== */

main {
  position: relative;
  z-index: 5;
}

.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding: 84px 18px 24px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 10%, rgba(143, 36, 27, 0.2), transparent 60%),
    radial-gradient(circle at 80% 90%, rgba(198, 161, 91, 0.08), transparent 60%),
    linear-gradient(180deg, transparent 60%, rgba(18, 16, 13, 0.4) 100%);
  pointer-events: none;
  z-index: 0;
}

.hero-copy {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.vertical-title {
  writing-mode: vertical-rl;
  color: var(--gold);
  font-size: 13px;
  letter-spacing: 0.35em;
  margin-bottom: 18px;
  align-self: flex-start;
  line-height: 1.6;
  opacity: 0.9;
}

.hero-text {
  max-width: 100%;
}

.eyebrow {
  display: inline-block;
  font-family: var(--sans);
  color: var(--gold-soft);
  font-size: 11px;
  letter-spacing: 0.3em;
  margin-bottom: 20px;
  padding: 6px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
}

h1 {
  font-size: clamp(32px, 9vw, 48px);
  line-height: 1.25;
  color: var(--paper);
  font-weight: 500;
  margin-bottom: 18px;
  letter-spacing: 0.02em;
}

.hero-lede {
  color: var(--paper-2);
  font-size: 15px;
  line-height: 1.9;
  margin-bottom: 32px;
  max-width: 100%;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border: 1px solid var(--gold);
  background: linear-gradient(135deg, rgba(198, 161, 91, 0.12), transparent);
  color: var(--gold);
  font-family: var(--sans);
  font-size: 14px;
  letter-spacing: 0.15em;
  border-radius: 2px;
  box-shadow: 0 4px 24px rgba(198, 161, 91, 0.15);
  transition: all 0.35s ease;
}

.hero-cta svg {
  width: 18px;
  height: 18px;
}

.hero-cta:active {
  transform: translateY(1px);
  background: rgba(198, 161, 91, 0.2);
}

.hero-image {
  position: relative;
  margin-top: 28px;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 2px;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.9) contrast(1.05);
  transition: transform 1.2s ease;
}

.hero-image::after {
  content: "";
  position: absolute;
  width: 40vw;
  height: 40vw;
  right: -10%;
  top: 10%;
  border: 1px solid rgba(198, 161, 91, 0.3);
  border-radius: 50%;
  pointer-events: none;
  animation: pulse-ring 6s ease-in-out infinite;
}

@keyframes pulse-ring {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.08); opacity: 0.7; }
}

.hero-image figcaption {
  position: absolute;
  bottom: 16px;
  left: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--paper);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero-image figcaption .no {
  color: var(--gold);
  font-size: 12px;
}

/* 滚动指示器 */

.scroll-indicator {
  position: absolute;
  bottom: 92px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.scroll-indicator span {
  width: 1px;
  height: 18px;
  background: linear-gradient(180deg, transparent, var(--gold));
  animation: scroll-fade 2.4s ease-in-out infinite;
}

.scroll-indicator span:nth-child(2) { animation-delay: 0.3s; }
.scroll-indicator span:nth-child(3) { animation-delay: 0.6s; }

@keyframes scroll-fade {
  0%, 100% { opacity: 0.2; transform: scaleY(0.5); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ========== 通用 section-index ========== */

.section-index {
  display: inline-block;
  color: var(--gold);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.35em;
  margin-bottom: 24px;
}

/* ========== 策展陈述 ========== */

.manifesto {
  padding: 80px 20px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}

.manifesto h2,
.section-heading h2,
.gallery-intro h2,
.service h2 {
  color: var(--paper);
  font-size: clamp(24px, 6.5vw, 32px);
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}

.manifesto-grid {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.manifesto-grid p {
  color: var(--paper-2);
  font-size: 15px;
  line-height: 2;
}

.ornate-seal {
  position: absolute;
  right: 20px;
  bottom: 30px;
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  color: var(--red);
  font-family: var(--serif);
  font-size: 18px;
  writing-mode: vertical-rl;
  letter-spacing: 0.2em;
  border: 1.5px solid var(--red);
  border-radius: 4px;
  opacity: 0.7;
  transform: rotate(-2deg);
  box-shadow: inset 0 0 0 1px var(--red), 2px 2px 0 rgba(198, 161, 91, 0.2);
}

/* ========== 精选作品横条 ========== */

.feature-strip {
  display: flex;
  gap: 12px;
  padding: 40px 14px 20px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.feature-strip::-webkit-scrollbar { display: none; }

.feature-card {
  flex: 0 0 78vw;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  scroll-snap-align: center;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  border-radius: 2px;
  position: relative;
}

.feature-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.04);
  transition: transform 0.8s ease;
}

/* ========== 四重叙事章节卡 ========== */

.chapters {
  padding: 80px 20px;
  position: relative;
  background:
    linear-gradient(180deg, transparent 0%, rgba(18, 16, 13, 0.6) 100%);
}

.section-heading {
  margin-bottom: 44px;
}

.chapter-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.chapter-card {
  padding: 28px 22px 32px;
  background: linear-gradient(135deg, rgba(198, 161, 91, 0.04), rgba(18, 16, 13, 0.6));
  border: 1px solid var(--line);
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s ease, border-color 0.4s ease;
}

.chapter-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  height: 0;
  background: var(--gold);
  transition: height 0.6s ease;
}

.chapter-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.chapter-num {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: var(--gold);
  border: 1px solid var(--line-strong);
  font-size: 16px;
  font-family: var(--serif);
}

.chapter-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--line-strong), transparent);
}

.chapter-card h3 {
  font-size: 22px;
  font-weight: 500;
  color: var(--paper);
  margin-bottom: 12px;
  letter-spacing: 0.04em;
}

.chapter-card p {
  color: var(--paper-2);
  font-size: 14px;
  line-height: 2;
}

/* ========== 作品墙 ========== */

.gallery-section {
  padding: 80px 18px 60px;
  background: var(--paper);
  color: var(--ink);
}

.gallery-section .section-index {
  color: var(--red);
}

.gallery-intro {
  margin-bottom: 30px;
}

.gallery-intro h2 {
  color: var(--ink);
}

.gallery-intro p {
  color: #5d5143;
  font-size: 14px;
  line-height: 1.9;
}

.gallery-tools {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  padding-bottom: 10px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.gallery-tools::-webkit-scrollbar { display: none; }

.filter {
  flex-shrink: 0;
  padding: 8px 16px;
  border: 1px solid rgba(18, 16, 13, 0.18);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.1em;
  transition: all 0.3s ease;
}

.filter:focus-visible {
  outline: none;
  border-color: var(--gold);
}

.filter.is-active {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
  box-shadow: 0 4px 14px rgba(18, 16, 13, 0.25);
}

.category-collection {
  display: flex;
  flex-direction: column;
  gap: 52px;
}

.category-block {
  position: relative;
}

.category-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(18, 16, 13, 0.14);
}

.category-kicker {
  display: inline-block;
  margin-bottom: 8px;
  color: var(--red);
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
}

.category-head h3 {
  color: var(--ink);
  font-size: clamp(22px, 6vw, 34px);
  font-weight: 500;
  line-height: 1.25;
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}

.category-head p {
  color: #675a4a;
  font-size: 13px;
  line-height: 1.8;
}

.category-grid,
.masonry {
  column-count: 2;
  column-gap: 10px;
}

.gallery-empty {
  padding: 36px 0;
  color: #675a4a;
  text-align: center;
}

.photo-card {
  position: relative;
  width: 100%;
  margin: 0 0 10px;
  break-inside: avoid;
  background: #d9d1c5;
  border-radius: 2px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(18, 16, 13, 0.15);
  cursor: zoom-in;
  transition: transform 0.3s ease;
  display: block;
}

.photo-card img {
  display: block;
  transition: transform 0.8s ease, filter 0.8s ease;
}

.photo-card:active {
  transform: scale(0.98);
}

.photo-card span {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 3px 8px;
  background: rgba(18, 16, 13, 0.75);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.15em;
}

/* ========== 商拍服务 ========== */

.service {
  padding: 80px 20px;
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.service-card {
  position: relative;
  padding: 36px 24px 40px;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(143, 36, 27, 0.15), transparent 60%),
    rgba(245, 239, 227, 0.03);
  border-radius: 2px;
}

.seal {
  display: inline-grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin-bottom: 22px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--gold);
  font-size: 13px;
  letter-spacing: 0.2em;
  writing-mode: vertical-rl;
  box-shadow: 0 0 20px rgba(198, 161, 91, 0.15);
}

.service-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 8px;
}

.service-list p {
  color: var(--paper-2);
  font-size: 14px;
  line-height: 1.9;
}

.service-list strong {
  color: var(--gold-soft);
  font-weight: 600;
  margin-right: 4px;
}

.service-image {
  aspect-ratio: 3 / 4;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 2px;
  box-shadow: var(--shadow);
}

.service-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95) contrast(1.03);
}

/* ========== 页脚 ========== */

.site-footer {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 40px 20px 120px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--paper-2);
}

/* ========== 灯箱 ========== */

.lightbox {
  width: min(100vw, 100vw);
  max-height: 100svh;
  height: 100svh;
  border: 0;
  padding: 0;
  background: rgba(18, 16, 13, 0.96);
  color: var(--paper);
  inset: 0;
}

.lightbox::backdrop {
  background: rgba(18, 16, 13, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.lightbox figure {
  margin: 0;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
}

.lightbox img {
  width: auto;
  max-width: calc(100% - 40px);
  max-height: calc(100svh - 140px);
  object-fit: contain;
  box-shadow: var(--shadow);
  border-radius: 2px;
  animation: lightbox-in 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes lightbox-in {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.lightbox figcaption {
  margin-top: 16px;
  text-align: center;
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 0.15em;
  color: var(--paper-2);
}

.close,
.light-nav {
  position: fixed;
  z-index: 3;
  border: 1px solid rgba(245, 239, 227, 0.28);
  background: rgba(18, 16, 13, 0.72);
  color: var(--paper);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.close {
  top: calc(env(safe-area-inset-top, 0) + 20px);
  right: 20px;
  font-size: 28px;
  line-height: 1;
}

.light-nav {
  top: auto;
  bottom: calc(env(safe-area-inset-bottom, 0) + 80px);
  width: 50px;
  height: 50px;
  transform: translateY(-50%);
  font-size: 36px;
  border-radius: 50%;
}

.light-nav.prev { left: 16px; }
.light-nav.next { right: 16px; }

.close:active,
.light-nav:active {
  transform: scale(0.92);
  border-color: var(--gold);
}

/* ========== 浮动音乐播放器 ========== */

.music-toggle {
  position: fixed;
  right: 18px;
  bottom: calc(env(safe-area-inset-bottom, 0) + 80px);
  z-index: 95;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(18, 16, 13, 0.85);
  border: 1px solid var(--line-strong);
  display: grid;
  place-items: center;
  color: var(--gold);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 6px 24px rgba(18, 16, 13, 0.4);
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.music-icon {
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

.music-toggle.is-playing .music-icon {
  animation: music-spin 4s linear infinite;
  color: var(--gold);
}

@keyframes music-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.music-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  opacity: 0;
  pointer-events: none;
}

.music-toggle.is-playing .music-ring {
  opacity: 1;
  animation: ring-pulse 2.4s ease-out infinite;
}

@keyframes ring-pulse {
  0% { transform: scale(0.85); opacity: 0.8; }
  100% { transform: scale(1.4); opacity: 0; }
}

.music-toggle:active { transform: scale(0.94); }

/* ========== 回到顶部 ========== */

.back-top {
  position: fixed;
  right: 18px;
  bottom: calc(env(safe-area-inset-bottom, 0) + 150px);
  z-index: 94;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(18, 16, 13, 0.78);
  border: 1px solid var(--line);
  color: var(--paper-2);
  display: grid;
  place-items: center;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease, border-color 0.35s ease, color 0.35s ease;
}

.back-top svg {
  width: 18px;
  height: 18px;
}

.back-top.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.back-top:active {
  transform: scale(0.94);
  color: var(--gold);
  border-color: var(--gold);
}

/* ========== 滚动进入动画 (scroll-triggered) ========== */

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1), transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal[data-reveal="fade-up"] { transform: translateY(40px); }
.reveal[data-reveal="slide-up"] { transform: translateY(50px); }
.reveal[data-reveal="zoom-in"] { transform: scale(0.92); opacity: 0; }

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Stagger delays for children */

.chapter-list .chapter-card:nth-child(1).reveal { transition-delay: 0.05s; }
.chapter-list .chapter-card:nth-child(2).reveal { transition-delay: 0.15s; }
.chapter-list .chapter-card:nth-child(3).reveal { transition-delay: 0.25s; }
.chapter-list .chapter-card:nth-child(4).reveal { transition-delay: 0.35s; }

.feature-strip .feature-card:nth-child(1).reveal { transition-delay: 0s; }
.feature-strip .feature-card:nth-child(2).reveal { transition-delay: 0.15s; }
.feature-strip .feature-card:nth-child(3).reveal { transition-delay: 0.3s; }

/* ========== 平板 / 桌面端增强 (768px+) ========== */

@media (min-width: 768px) {
  body {
    font-size: 16px;
  }

  .site-header {
    padding: 28px 40px;
    padding-top: calc(env(safe-area-inset-top, 0) + 28px);
  }

  .site-header nav {
    display: flex;
    align-items: center;
    gap: 28px;
  }

  .site-header nav a {
    color: var(--paper-2);
    font-family: var(--sans);
    font-size: 13px;
    letter-spacing: 0.15em;
    transition: color 0.3s ease;
  }

  .site-header nav a:hover {
    color: var(--gold);
  }

  .brand-mark {
    width: 44px;
    height: 44px;
    font-size: 18px;
  }

  .brand-text {
    font-size: 14px;
    max-width: 100%;
  }

  .mobile-nav {
    display: none;
  }

  .hero {
    min-height: 100svh;
    display: grid;
    grid-template-columns: minmax(300px, 1fr) minmax(360px, 1.1fr);
    gap: 40px;
    align-items: center;
    padding: 140px 40px 80px;
  }

  .hero-copy {
    flex-direction: row;
    align-items: flex-start;
    gap: 40px;
  }

  .vertical-title {
    font-size: 15px;
    margin-bottom: 0;
    margin-right: 20px;
  }

  .eyebrow {
    font-size: 12px;
    margin-bottom: 30px;
  }

  h1 {
    font-size: clamp(48px, 6vw, 88px);
    margin-bottom: 28px;
    max-width: 12em;
  }

  .hero-lede {
    font-size: 17px;
    max-width: 480px;
    margin-bottom: 40px;
  }

  .hero-cta {
    padding: 16px 36px;
    font-size: 15px;
  }

  .hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(198, 161, 91, 0.3);
  }

  .hero-image {
    margin-top: 0;
    aspect-ratio: 4 / 5;
    max-height: 80vh;
  }

  .hero-image::after {
    width: 28vw;
    height: 28vw;
  }

  .scroll-indicator {
    display: none;
  }

  .manifesto,
  .chapters,
  .gallery-section,
  .service {
    padding: 120px 40px;
  }

  .manifesto h2,
  .section-heading h2,
  .gallery-intro h2,
  .service h2 {
    font-size: clamp(36px, 4.5vw, 56px);
    margin-bottom: 32px;
  }

  .manifesto-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 48px;
    align-items: start;
  }

  .manifesto-grid p {
    font-size: 16px;
    line-height: 2.1;
  }

  .feature-strip {
    gap: 16px;
    padding: 60px 40px 40px;
  }

  .feature-card {
    flex: 0 0 32vw;
    aspect-ratio: 4 / 5;
  }

  .section-heading {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 40px;
    align-items: start;
  }

  .chapter-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .chapter-card {
    padding: 40px 32px;
  }

  .chapter-card::before {
    width: 3px;
  }

  .chapter-card:hover::before {
    height: 100%;
  }

  .chapter-card h3 {
    font-size: 28px;
  }

  .chapter-card p {
    font-size: 15px;
  }

  .gallery-intro {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: end;
    margin-bottom: 40px;
  }

  .gallery-tools {
    gap: 10px;
    margin-bottom: 40px;
  }

  .filter {
    padding: 10px 22px;
    font-size: 13px;
  }

  .category-collection {
    gap: 76px;
  }

  .category-head {
    display: grid;
    grid-template-columns: minmax(220px, 0.45fr) minmax(320px, 0.55fr);
    align-items: end;
    margin-bottom: 24px;
  }

  .category-head p {
    max-width: 520px;
    font-size: 14px;
  }

  .category-grid,
  .masonry {
    column-count: 3;
    column-gap: 16px;
  }

  .photo-card {
    margin-bottom: 16px;
  }

  .photo-card span {
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.35s ease, transform 0.35s ease;
  }

  .photo-card:hover img {
    transform: scale(1.03);
    filter: saturate(1.05) contrast(1.05);
  }

  .photo-card:hover span {
    opacity: 1;
    transform: translateY(0);
  }

  .service {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 60px;
    align-items: stretch;
    flex-direction: row;
  }

  .service-card {
    padding: 60px 48px;
  }

  .service-image {
    margin: 0;
  }

  .service-image img {
    min-height: 100%;
  }

  .site-footer {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
    padding: 50px 40px 60px;
  }

  .lightbox {
    width: min(1120px, calc(100vw - 60px));
    max-height: calc(100svh - 60px);
    height: auto;
    inset: 50% auto auto 50%;
    transform: translate(-50%, -50%);
  }

  .lightbox img {
    max-width: calc(100% - 80px);
    max-height: calc(100svh - 200px);
  }

  .close {
    top: 24px;
    right: 24px;
  }

  .light-nav {
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
  }

  .music-toggle {
    right: 30px;
    bottom: 30px;
    width: 56px;
    height: 56px;
  }

  .back-top {
    right: 30px;
    bottom: 100px;
  }
}

/* ========== 大屏优化 (1200px+) ========== */

@media (min-width: 1200px) {
  .site-header {
    padding: 32px 64px;
  }

  .hero {
    padding: 160px 64px 100px;
    gap: 80px;
  }

  .manifesto,
  .chapters,
  .gallery-section,
  .service {
    padding: 160px 64px;
  }

  .category-grid,
  .masonry {
    column-count: 4;
    column-gap: 20px;
  }

  .photo-card {
    margin-bottom: 20px;
  }
}

/* ========== 动画减少偏好 ========== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    animation: none !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ========== 视口高度校正 ========== */

@media (max-height: 600px) {
  .hero {
    min-height: auto;
    padding-top: 100px;
  }

  .scroll-indicator {
    display: none;
  }
}
