/* ============================================================
   宠物记忆 PetMemo — 整站设计系统
   暖调品牌视觉：奶白底 + 琥珀/暖橙主色 + 深棕文字
   ============================================================ */
:root {
  /* 色板 */
  --bg: #faf6f0;
  --bg-soft: #f3ece1;
  --card: #ffffff;
  --text: #3a342c;
  --text-soft: #6f675c;
  --muted: #9a9184;
  --accent: #d97a4e;          /* 暖橙/琥珀 */
  --accent-dark: #b95c34;
  --accent-soft: #f4c4a8;
  --gold: #c99a5b;
  --border: #e8dfd2;
  --shadow: 0 10px 30px rgba(90, 60, 30, 0.08);
  --shadow-lg: 0 24px 60px rgba(90, 60, 30, 0.14);
  --radius: 18px;
  --radius-sm: 12px;

  --font: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --maxw: 1160px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 动态背景层（Canvas / video） ---------- */
#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.page-bg-layer {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}
.page-bg-layer video {
  width: 100%; height: 100%;
  object-fit: cover;
}

/* ---------- 顶栏 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 28px;
  background: rgba(250, 246, 240, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(232, 223, 210, 0.6);
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
  text-decoration: none;
}
.logo-img {
  height: 46px;
  width: auto;
  display: block;
}
.logo small {
  font-weight: 500;
  color: var(--muted);
  font-size: 0.75rem;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  text-decoration: none;
  color: var(--text-soft);
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
  padding: 4px 0;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a.active { color: var(--accent); }
.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.nav-links a.nav-cta {
  background: var(--accent);
  color: #fff;
  padding: 8px 18px;
  border-radius: 999px;
}
.nav-links a.nav-cta.active::after { display: none; }
.nav-links a.nav-cta:hover { background: var(--accent-dark); }

.lang-toggle {
  flex: none;
  margin-left: 10px; /* 与左侧货币选择器保持间距 */
  border: 1px solid rgba(217, 122, 78, 0.5);
  background: rgba(255, 255, 255, 0.5);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.lang-toggle:hover { background: var(--accent); color: #fff; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: var(--text);
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 30px;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: transform 0.15s, background 0.2s, box-shadow 0.2s;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-2px); }
.btn-secondary { background: var(--card); color: var(--accent); border: 1px solid var(--accent); }
.btn-secondary:hover { background: #fff8f4; transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--text-soft); border: 1px solid var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-lg { padding: 16px 40px; font-size: 1.05rem; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

/* ---------- 图标系统 ---------- */
.icn {
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  border-radius: 16px;
  color: var(--accent-dark);
  margin: 0 auto 16px;
}
.icn svg { color: currentColor; }
.icn-lg { width: 76px; height: 76px; border-radius: 20px; }
.icn .icn-fill { color: var(--gold); }

/* 评价星级容器 */
.stars { display: flex; gap: 3px; margin-bottom: 12px; color: var(--gold); }
.stars svg { width: 18px; height: 18px; }

/* 联系信息卡图标 */
.info-card .ic {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  background: var(--accent-soft);
  border-radius: 12px;
  color: var(--accent-dark);
  flex-shrink: 0;
}
.info-card .ic svg { width: 26px; height: 26px; }

/* 页脚社交图标 */
.footer-social { display: flex; gap: 12px; }
.footer-social a {
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: #d9d2c7;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}
.footer-social a:hover { background: var(--accent); color: #fff; }
.footer-social a svg { width: 20px; height: 20px; }

/* ---------- 通用区块（紧凑：banner 之下模块上移，减少留白） ---------- */
.section { padding: 48px 0; position: relative; z-index: 1; }
/* 首页专用：保持原间距节奏（首页保持不动） */
.section.sec-home { padding: 84px 0; }
.section.sec-home .section-head { margin: 0 auto 52px; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 32px; }
.eyebrow {
  display: inline-block;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.section-head h2 {
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  line-height: 1.25;
  margin-bottom: 14px;
  letter-spacing: -0.01em;
}
.section-head p { color: var(--text-soft); font-size: 1.05rem; }

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }

/* ---------- 业务卡片 16:9 视频头（services 页） ---------- */
.svc-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.svc-video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-soft);
  flex: none;
}
.svc-video-wrap::after { /* 底部暗角渐层：保证文字区与视频过渡自然（略加高，让标题能切入） */
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 55%;
  background: linear-gradient(to bottom, rgba(255, 250, 244, 0) 0%, var(--card) 78%);
  pointer-events: none;
}
.svc-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.svc-card-body {
  padding: 0 28px 24px;
  margin-top: -34px;        /* 让标题切入视频底部渐变区 */
  position: relative; z-index: 1;
  flex: 1;
  line-height: 1.55;        /* 卡片内文字行距收窄 */
}
.svc-card-body h2 { margin-bottom: 10px; }
.svc-card-body ul li { padding: 3px 0 3px 24px; }
@media (max-width: 760px) {
  .svc-card-body { padding: 0 18px 18px; margin-top: -26px; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 720px;
}
.hero-logo-wrap {
  position: absolute;
  top: 6%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  pointer-events: none;
}
.hero-logo {
  height: 120px;
  width: auto;
  display: block;
  filter: drop-shadow(0 4px 14px rgba(60, 50, 40, 0.22));
}
.hero h1 {
  font-size: clamp(2.4rem, 6vw, 3.8rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.hero h1 .hl { color: var(--accent); }
.hero p { font-size: 1.15rem; color: var(--text-soft); margin-bottom: 32px; max-width: 560px; }
.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; }
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border);
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-soft);
  margin-bottom: 22px;
}

/* ---------- 英文版：压缩 Hero 文字空间，避免标签与 Logo 重叠 ---------- */
/* i18n.apply() 会把 <html lang> 设为 en / zh-CN，此处只命中英文版 */
html[lang="en"] .hero-logo { height: 96px; }
html[lang="en"] .hero-eyebrow { font-size: 0.78rem; padding: 6px 13px; margin-bottom: 16px; }
html[lang="en"] .hero h1 { font-size: clamp(2.1rem, 5vw, 3.1rem); margin-bottom: 16px; }
html[lang="en"] .hero p { font-size: 1.02rem; margin-bottom: 26px; max-width: 540px; }
html[lang="en"] .hero-inner { margin-top: 88px; }

/* ---------- 数据背书 ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat { text-align: center; }
.stat .num { font-size: 2.4rem; font-weight: 800; color: var(--accent); line-height: 1; }
.stat .label { color: var(--text-soft); font-size: 0.9rem; margin-top: 8px; }

/* ---------- 流程步骤 ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding-left: 56px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-weight: 800;
  border-radius: 50%;
}
.step h3 { margin-bottom: 6px; }
.step p { color: var(--text-soft); font-size: 0.95rem; }

/* ---------- 客户评价 ---------- */
.quote { font-size: 1.15rem; color: var(--text); }
.quote .author { margin-top: 16px; color: var(--muted); font-size: 0.9rem; }

/* ---------- FAQ ---------- */
.faq { max-width: 760px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  padding: 20px 4px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.faq-q .icon { transition: transform 0.25s; color: var(--accent); font-size: 1.3rem; }
.faq-item.open .faq-q .icon { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.3s ease; color: var(--text-soft); }
.faq-item.open .faq-a { max-height: 300px; }
.faq-a p { padding: 0 4px 20px; }

/* ---------- 页脚 ---------- */
.site-footer {
  background: #2a251f;
  color: #d9d2c7;
  padding: 56px 0 28px;
  position: relative;
  z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.4fr;
  gap: 36px;
  margin-bottom: 40px;
}
.footer-grid h4 { color: #fff; font-size: 1rem; margin-bottom: 16px; }
.footer-grid p { color: #a39a8c; font-size: 0.9rem; }
.footer-grid ul { list-style: none; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: #a39a8c; text-decoration: none; font-size: 0.9rem; transition: color 0.2s; }
.footer-grid a:hover { color: var(--accent-soft); }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.85rem;
  color: #8a8075;
}
/* ---------- 联系表单 ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 0.9rem; color: var(--text-soft); font-weight: 600; }
.field input, .field select, .field textarea {
  padding: 12px 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  background: var(--card);
  color: var(--text);
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(217, 122, 78, 0.12);
}
.field .error { color: #c0392b; font-size: 0.8rem; min-height: 14px; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #c0392b; }
.form-note { color: var(--text-soft); font-size: 0.9rem; }
.form-success {
  background: #e8f5e9;
  color: #2e7d32;
  border-radius: var(--radius-sm);
  padding: 16px;
  margin-top: 16px;
  font-weight: 600;
}

/* ---------- 联系信息卡 ---------- */
.info-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.info-card h4 { font-size: 1rem; margin-bottom: 4px; }
.info-card p, .info-card a { color: var(--text-soft); font-size: 0.95rem; text-decoration: none; }
.info-card a:hover { color: var(--accent); }

/* ---------- 页内 CTA 条 ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--accent), var(--gold));
  border-radius: var(--radius);
  padding: 56px 48px;
  text-align: center;
  color: #fff;
  box-shadow: var(--shadow-lg);
}
.cta-band h2 { font-size: 1.8rem; margin-bottom: 10px; }
.cta-band p { opacity: 0.92; margin-bottom: 26px; }
.cta-band .btn-primary { background: #fff; color: var(--accent-dark); }
.cta-band .btn-primary:hover { background: #fff5ef; }

/* ---------- 创作工具（create 页） ---------- */
.creator { display: grid; gap: 20px; margin-top: 32px; }
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.upload-area.dragover { border-color: var(--accent); background: #fff8f4; }
.upload-placeholder { color: var(--muted); text-align: center; }
.upload-placeholder [data-icon] {
  width: 64px; height: 64px;
  margin-bottom: 12px;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 18px;
  display: inline-grid;
  place-items: center;
}
.upload-placeholder [data-icon] svg { width: 34px; height: 34px; }
#preview-img { width: 100%; }

.form-row { display: flex; align-items: center; gap: 12px; }
.form-row label { width: 90px; flex-shrink: 0; color: var(--text-soft); font-weight: 600; }
.form-row input {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 0.95rem;
  background: var(--card);
  font-family: inherit;
}
.template-picker h3, .merch-picker h3, .caption-editor h3 {
  font-size: 0.95rem; color: var(--text-soft); margin-bottom: 12px; font-weight: 700;
}
.template-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.sp-card {
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 8px;
  background: var(--card);
  text-align: center;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s;
}
.sp-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.sp-card.selected { border-color: var(--accent); background: #fff8f4; }
.sp-thumb {
  display: block;
  width: 100%;
  padding: 0;
  border: none;
  background: none;
  cursor: zoom-in;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  position: relative;
}
.sp-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 10px; }
.sp-meta { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; }
.sp-label { font-size: 0.85rem; font-weight: 600; color: var(--text); }
.sp-card.selected { border-color: var(--accent); background: #fff8f4; box-shadow: 0 0 0 2px var(--accent) inset; }
.sp-card.generated { border-color: var(--accent); background: #fff8f4; }
.sp-badge {
  position: absolute;
  top: 6px; right: 6px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 13px;
  line-height: 22px;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
/* 统一预览区：选中标签后显示该标签内容 + 唯一生成入口 */
.preview-panel {
  margin-top: 28px;
  padding: 22px;
  border: 2px dashed var(--accent);
  border-radius: var(--radius);
  background: var(--card);
}
.pv-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.pv-head h3 { margin: 0; font-size: 1.15rem; color: var(--accent-dark); }
.pv-chip {
  font-size: 0.72rem; font-weight: 600; color: #fff;
  background: var(--accent); border-radius: 999px; padding: 2px 10px;
}
.pv-desc { font-size: 0.92rem; color: var(--text-soft); margin: 0 0 16px; line-height: 1.5; }
.pv-stage {
  position: relative;
  min-height: 300px;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg, #faf7f3);
  border-radius: 12px;
  overflow: hidden;
  padding: 16px;
}
.pv-empty { font-size: 0.9rem; color: var(--text-soft); text-align: center; }
.pv-img { max-width: 100%; max-height: 460px; border-radius: 10px; box-shadow: var(--shadow); }
.pv-model { width: 100%; }
.pv-actions { display: flex; gap: 12px; align-items: center; margin-top: 16px; flex-wrap: wrap; }
.pv-status { font-size: 0.85rem; color: var(--text-soft); margin: 10px 0 0; min-height: 1.2em; line-height: 1.5; }

.pick-hint { font-size: 0.82rem; color: var(--text-soft); margin: 6px 0 14px; }
.gallery-item { position: relative; }
.gallery-item .g-dl {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--accent-dark);
  text-decoration: none;
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 4px 12px;
}
.gallery-item .g-dl:hover { background: var(--accent); color: #fff; }
.save-row { display: flex; gap: 12px; margin-top: 22px; flex-wrap: wrap; align-items: center; }

/* 周边物品：#merch-list 复用 .template-list 网格；.merch-card 复用 .sp-card 卡片 */
.merch-note { margin-top:12px; font-size:0.85rem; color:#8a6d1a; background:#fff7e6; border:1px solid #f5d58a; padding:8px 12px; border-radius:8px; }
.forge-status { font-size:0.9rem; color:var(--text-soft); margin:0 0 12px; line-height:1.5; }
.forge-model-wrap { margin-bottom:12px; }
.forge-model-wrap model-viewer { width:100%; height:360px; background:#f7f3ee; border-radius:10px; }
html[lang="en"] .merch-picker h3 { font-size:0.9rem; }

/* 缩略图放大查看原图 */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(20, 16, 12, 0.82);
}
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 8px; box-shadow: 0 10px 40px rgba(0,0,0,0.45); }
.lightbox-close {
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.18);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close:hover { background: rgba(255,255,255,0.32); }

/* 预览框内的「你的创想」：紧贴生成按钮上方，先写画面再点生成 */
#creative-row { margin: 16px 0 4px; }
#creative-row .cr-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px 12px; flex-wrap: wrap; margin-bottom: 8px;
}
#creative-row .cr-head h3 { margin: 0; font-size: 0.9rem; color: var(--text-soft); font-weight: 700; }
#creative-row .cr-hint { font-size: 0.75rem; color: var(--text-soft); opacity: 0.85; }
#creative-row textarea { font-size: 0.9rem; }

.caption-editor textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 0.95rem;
  resize: vertical;
  background: var(--card);
  font-family: inherit;
}
.result-card { background: var(--card); border-radius: var(--radius); padding: 28px; text-align: center; }
#result-canvas { max-width: 420px; width: 100%; border-radius: 12px; margin: 0 auto 18px; box-shadow: var(--shadow); }
.result-caption { color: var(--text-soft); font-size: 0.95rem; margin-bottom: 22px; white-space: pre-line; }
.result-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.gallery-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; margin-top: 18px; }
.gallery-item img { width: 100%; border-radius: 12px; box-shadow: var(--shadow); }
.gallery-item .g-caption { font-size: 0.82rem; color: var(--muted); margin-top: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- 关于页 ---------- */
.story-block { max-width: 720px; margin: 0 auto; }
.story-block p { font-size: 1.1rem; color: var(--text-soft); margin-bottom: 18px; }
.story-block p.lead { font-size: 1.35rem; color: var(--text); font-weight: 600; }
.value { text-align: center; }
.value h3 { margin-bottom: 8px; }
.value p { color: var(--text-soft); font-size: 0.95rem; }

/* ---------- 页内 banner（子页通用） ---------- */
.page-banner { padding: 40px 0 24px; position: relative; z-index: 1; }
.page-banner h1 { font-size: clamp(1.9rem, 4.5vw, 2.6rem); margin-bottom: 12px; }
.page-banner p { color: var(--text-soft); font-size: 1.08rem; max-width: 620px; }
.page-banner.center { text-align: center; }
.page-banner.center p { margin: 0 auto; }
.breadcrumb { color: var(--muted); font-size: 0.88rem; margin-bottom: 10px; }
.breadcrumb a { text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }

/* ---------- 响应式 ---------- */
@media (max-width: 1100px) {
  .grid-5 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .grid-4, .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--card);
    padding: 18px 24px;
    gap: 16px;
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid var(--border);
    display: none;
  }
  .logo-img { height: 40px; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; margin-left: auto; }
  .lang-toggle { margin-left: 8px; }
  .nav-links a.nav-cta { text-align: center; }
  .grid-2, .grid-4, .grid-3, .grid-5 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .section { padding: 36px 0; }
  .section.sec-home { padding: 60px 0; }
  .cta-band { padding: 40px 24px; }
  .hero { min-height: 80vh; }
}

[hidden] { display: none !important; }

/* ---------- 账户系统 ---------- */
.nav-account { display: flex; align-items: center; gap: 16px; }
.nav-lib { color: var(--accent); font-weight: 600; font-size: 0.95rem; text-decoration: none; }
.nav-lib:hover { color: var(--accent-dark); }
.nav-user { color: var(--text-soft); font-size: 0.9rem; display: flex; align-items: center; gap: 6px; }
.nav-logout-btn { background: none; border: none; color: var(--accent); cursor: pointer; font-size: 0.85rem; text-decoration: underline; padding: 0; }
.btn-sm { padding: 8px 16px; font-size: 0.85rem; }
.lib-actions { margin-top: 10px; }

/* 登录 / 注册 */
.auth-tabs { display: flex; gap: 8px; margin-bottom: 22px; }
.auth-tab { flex: 1; padding: 10px; border: 1px solid var(--border); background: var(--card); border-radius: var(--radius-sm); cursor: pointer; font-weight: 600; color: var(--text-soft); font-family: inherit; font-size: 0.95rem; }
.auth-tab.active { border-color: var(--accent); color: var(--accent); background: #fff8f4; }
.code-row { display: flex; gap: 10px; align-items: stretch; }
.code-row input { flex: 1; min-width: 0; }
.code-row .btn { flex: none; white-space: nowrap; }

/* ---------- 主页 Hero 视频背景（奔跑的柯基） ----------
   视频底色为奶油白，与品牌 --bg 一致，故 hero 文案保持深色。
   视频放大到 110% 并靠左锚定，使居中的柯基落在右侧约 2/3 处，
   左侧用奶油渐隐，既保证文案清晰，又露出奔跑的狗。 */
.hero { z-index: 1; }
.hero-video-wrap { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-video {
  position: absolute; top: 0; left: -50px;
  width: 110%; height: 100%;
  object-fit: cover;
  object-position: left center;
  transition: opacity 0.4s linear;
}
.hero-scrim {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg,
    var(--bg) 0%,
    rgba(250,246,240,0.88) 22%,
    rgba(250,246,240,0.48) 42%,
    rgba(250,246,240,0.14) 62%,
    rgba(250,246,240,0.05) 80%,
    rgba(250,246,240,0) 100%);
}
@media (max-width: 640px) {
  /* 移动端文案占满整宽：降低视频存在感；居中取景框住狗的主活动区(源x384-885) */
  .hero-video { left: 0; width: 100%; object-position: center; opacity: 0.5; }
  .hero-scrim { background: linear-gradient(180deg, rgba(250,246,240,0.55) 0%, rgba(250,246,240,0.78) 100%); }
}
/* 尊重系统「减少动态效果」偏好：不自动播放背景视频 */
@media (prefers-reduced-motion: reduce) {
  .hero-video { display: none; }
  .hero { background: radial-gradient(60% 80% at 68% 38%, var(--accent-soft), var(--bg)); }
}

/* ---------- 主页背景音乐开关（右下角浮动） ---------- */
.bgm-toggle {
  position: fixed;
  right: 22px; bottom: 22px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease, color .2s ease;
}
.bgm-toggle:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-lg);
}
.bgm-toggle .bgm-ico { display: inline-grid; line-height: 0; }
.bgm-toggle.on {
  color: var(--accent-dark);
  border-color: var(--accent-soft);
  background: rgba(244, 196, 168, 0.38);
}
.bgm-toggle.on .bgm-ico { animation: bgmPulse 1.6s ease-in-out infinite; }
@keyframes bgmPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.18); }
}
@media (max-width: 640px) {
  .bgm-toggle { right: 14px; bottom: 14px; padding: 9px 13px; font-size: 0.8rem; }
}
@media (prefers-reduced-motion: reduce) {
  .bgm-toggle.on .bgm-ico { animation: none; }
}


/* ============================================================
   货币选择器（顶栏）
   ============================================================ */
.currency-select { display: inline-flex; align-items: center; margin-left: 6px; }
.currency-select select {
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  background: rgba(255,255,255,0.8);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 10px;
  cursor: pointer;
}
.currency-select select:focus { outline: 2px solid var(--accent-soft); }

/* ============================================================
   结算页
   ============================================================ */
.checkout-page { padding-top: 36px; padding-bottom: 64px; }
.checkout-title { font-size: 2rem; margin-bottom: 8px; }
.checkout-sub { color: var(--text-soft); margin-bottom: 22px; max-width: 720px; }
.checkout-msg { text-align: center; padding: 48px 24px; }
.checkout-msg .btn { margin-top: 18px; }

.promo-banner {
  display: flex; align-items: center; gap: 12px;
  background: linear-gradient(100deg, #fff4ea, #ffe9d8);
  border: 1px solid var(--accent-soft);
  border-radius: var(--radius-sm);
  padding: 12px 18px; margin-bottom: 22px;
  box-shadow: var(--shadow);
}
.promo-tag {
  background: var(--accent); color: #fff; font-weight: 800;
  border-radius: 999px; padding: 4px 14px; font-size: 0.95rem;
}
.promo-text { color: var(--text); font-size: 0.95rem; }
.promo-text b { color: var(--accent-dark); font-variant-numeric: tabular-nums; }

.checkout-grid { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; }
.checkout-left h3, .order-summary h3, .ship-card h3 { font-size: 1.15rem; margin-bottom: 14px; }

/* 收货信息卡片（左栏，购买项目上部，与项目等宽） */
.ship-card { margin-bottom: 24px; }
.ship-hint { color: var(--muted); font-size: 0.85rem; margin: -8px 0 14px; }
.ship-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ship-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; min-width: 0; }
.ship-field > span { font-size: 0.85rem; font-weight: 600; color: var(--text-soft); }
.ship-field input, .ship-field textarea {
  width: 100%; box-sizing: border-box; min-width: 0;
  padding: 9px 12px; border: 1px solid var(--border); border-radius: 10px;
  font-family: var(--font); font-size: 0.95rem; background: #fff; color: var(--text); resize: vertical;
}
.ship-field input:disabled, .ship-field textarea:disabled { background: var(--bg-soft); color: var(--text-soft); cursor: not-allowed; }
.ship-field input:focus, .ship-field textarea:focus { outline: none; border-color: var(--accent); }
.ship-actions { display: flex; gap: 8px; }
.ship-actions .btn:disabled { opacity: 0.45; cursor: not-allowed; }
.ship-msg { font-size: 0.85rem; margin: 10px 0 0; }
.ship-msg.err { color: #c0392b; }
.ship-msg.ok { color: #2e9e6b; }

.works-picker { display: flex; flex-direction: column; gap: 18px; }
.work-pick-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.wpc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.wpc-thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; flex: none; }
.wpc-caption { font-weight: 600; }
.wpc-meta { color: var(--muted); font-size: 0.82rem; }
.wpc-items { display: flex; flex-direction: column; gap: 8px; }
.item-row {
  display: grid; grid-template-columns: auto 44px 1fr auto auto; align-items: center; gap: 12px;
  padding: 8px 10px; border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer;
}
.item-row:hover { border-color: var(--accent-soft); }
.item-check { width: 18px; height: 18px; accent-color: var(--accent); }
.item-thumb { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; background: var(--bg-soft); }
.item-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: 8px; }
.item-label { font-weight: 600; font-size: 0.95rem; display: flex; flex-direction: column; }
.item-label small { color: var(--muted); font-weight: 500; font-size: 0.75rem; }
.item-size { font-family: var(--font); padding: 5px 8px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.item-price { font-weight: 700; color: var(--accent-dark); font-variant-numeric: tabular-nums; white-space: nowrap; }

.order-summary { position: sticky; top: 24px; }
.sum-row { display: flex; justify-content: space-between; padding: 8px 0; color: var(--text-soft); }
.sum-row span:last-child { font-weight: 600; color: var(--text); }
.sum-discount span:last-child { color: #2e9e6b; }
.sum-total { border-top: 1px dashed var(--border); margin-top: 6px; padding-top: 12px; font-size: 1.15rem; }
.sum-total b { color: var(--accent-dark); }
.sum-total .struck { color: var(--muted); text-decoration: line-through; font-size: 0.95rem; margin-right: 8px; font-weight: 500; }

.coupon-row { display: flex; gap: 8px; margin: 14px 0 6px; }
.coupon-input { flex: 1; padding: 9px 12px; border: 1px solid var(--border); border-radius: 10px; font-family: var(--font); }
.coupon-msg { font-size: 0.85rem; margin-bottom: 6px; }
.coupon-msg.err { color: #c0392b; }
.coupon-msg.ok { color: #2e9e6b; }

.demo-banner { background: #fff7ed; border: 1px dashed var(--accent-soft); border-radius: var(--radius-sm); padding: 10px 12px; margin: 12px 0; }
.demo-banner b { color: var(--accent-dark); }
.demo-banner p { font-size: 0.82rem; color: var(--text-soft); margin-top: 4px; }

.pay-btn { width: 100%; margin-top: 8px; font-size: 1.05rem; padding: 14px; }
.pay-note { font-size: 0.82rem; color: var(--muted); margin-top: 8px; text-align: center; }

.checkout-result { text-align: center; padding: 56px 24px; }
.result-icon { width: 64px; height: 64px; line-height: 64px; border-radius: 50%; background: #e7f7ee; color: #2e9e6b; font-size: 2rem; margin: 0 auto 16px; }
.result-order { color: var(--text-soft); margin: 10px 0 18px; }

/* ============================================================
   我的纪念库：下载闸门 + 去结算
   ============================================================ */
.lib-toolbar { margin-bottom: 18px; }
.gallery-item .lib-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.lib-links { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.lib-badge { background: #e7f7ee; color: #2e9e6b; font-weight: 700; border-radius: 999px; padding: 3px 12px; font-size: 0.8rem; }
.lib-note { color: var(--muted); font-size: 0.85rem; }
.lib-dl { display: inline-block; background: var(--bg-soft); border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px; font-size: 0.82rem; color: var(--text); text-decoration: none; }
.lib-dl:hover { border-color: var(--accent-soft); color: var(--accent-dark); }

@media (max-width: 860px) {
  .checkout-grid { grid-template-columns: 1fr; }
  .order-summary { position: static; }
}
@media (max-width: 520px) {
  .item-row { grid-template-columns: auto 36px 1fr auto; }
  .item-thumb { width: 36px; height: 36px; }
  .item-size { grid-column: 2 / -1; justify-self: start; }
  .ship-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   业务卡片操作区 + 价格说明弹窗（业务介绍页）
   ============================================================ */
.card-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.btn-price { font-weight: 600; }
.btn-price.is-tba { color: var(--muted); border-color: var(--border); background: transparent; }
.btn-price.is-tba:hover { color: var(--accent-dark); border-color: var(--accent-soft, #e8c9b4); background: var(--bg-soft); }

/* 弹窗 */
.pm-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(60, 44, 34, 0.45);
  backdrop-filter: blur(3px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  animation: pm-fade 0.18s ease;
}
@keyframes pm-fade { from { opacity: 0; } to { opacity: 1; } }
.pm-dialog {
  width: min(520px, 100%); max-height: 86vh; overflow: auto;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 16px; box-shadow: 0 18px 50px rgba(90, 60, 40, 0.22);
  padding: 22px 24px 20px;
  animation: pm-pop 0.2s ease;
}
@keyframes pm-pop { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: none; } }
.pm-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.pm-head h3 { margin: 0; font-size: 1.12rem; color: var(--accent-dark); }
.pm-close {
  flex: none; width: 30px; height: 30px; border: none; border-radius: 50%;
  background: var(--bg-soft); color: var(--text-soft); font-size: 1.15rem; line-height: 1;
  cursor: pointer; transition: background 0.15s, color 0.15s;
}
.pm-close:hover { background: var(--accent); color: #fff; }
.pm-group { margin-bottom: 14px; }
.pm-group-title { font-size: 0.8rem; font-weight: 700; letter-spacing: 0.04em; color: var(--muted); margin-bottom: 6px; }
.pm-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
  padding: 9px 2px; border-bottom: 1px dashed var(--border);
}
.pm-row:last-child { border-bottom: none; }
.pm-name { font-size: 0.95rem; font-weight: 600; }
.pm-name small { display: block; font-size: 0.76rem; font-weight: 500; color: var(--muted); margin-top: 2px; }
.pm-price { flex: none; color: var(--accent-dark); font-weight: 700; font-variant-numeric: tabular-nums; }
.pm-note {
  margin: 12px 0 0; padding: 10px 12px; border-radius: 10px;
  background: var(--bg-soft); color: var(--text-soft); font-size: 0.82rem; line-height: 1.6;
}
.pm-foot { margin-top: 14px; text-align: right; }
/* 未定价业务（预留） */
.pm-tba { text-align: center; padding: 14px 6px 6px; }
.pm-tba-icon { font-size: 2rem; }
.pm-tba-title { font-weight: 700; margin: 8px 0 6px; }
.pm-tba-desc { color: var(--text-soft); font-size: 0.88rem; line-height: 1.7; margin: 0 0 16px; }

/* 画廊"购买后下载"按钮（替代原直链下载） */
.g-dl-btn { display: inline-block; background: var(--accent); color: #fff; border: none; border-radius: 999px; padding: 6px 14px; font-size: 0.82rem; font-weight: 600; cursor: pointer; font-family: var(--font); }
.g-dl-btn:hover { background: var(--accent-dark); }

/* 纪念库：逐 SKU 锁定/解锁 */
.lib-lock { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; color: var(--text-soft); }
.lib-buy-link { color: var(--accent-dark); font-weight: 700; text-decoration: none; }
.lib-buy-link:hover { text-decoration: underline; }
