/* ============================================================
   澜悦荟 · 优惠券分销体系 H5 原型 — 设计系统
   主题：暖砂大地色 / Apple 式极简 / 390px 移动端
   ============================================================ */

:root {
  --bg: #f5eee1;
  --card: #fffefb;
  --ink: #2b241c;
  --ink-2: #7f7466;
  --ink-3: #b5aa9a;
  --accent: #8a6a4f;
  --accent-ink: #fdf9f4;
  --soft: #eee6da;
  --tint: rgba(138, 106, 79, 0.28);
  --line: rgba(80, 64, 44, 0.10);
  --line-strong: rgba(80, 64, 44, 0.20);
  --r-lg: 18px;
  --r-md: 12px;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display",
    "PingFang SC", "Helvetica Neue", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: #e9e9ee;
  display: flex;
  justify-content: center;
  padding: 28px 0;
  font-size: 15px;
  line-height: 1.5;
}

/* ---------- 设备框 ---------- */
.stage { display: flex; flex-direction: column; gap: 12px; }
.phone {
  width: 390px;
  height: 844px;
  background: var(--bg);
  border-radius: 44px;
  overflow-y: auto;
  overflow-x: hidden;
  position: relative;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22), 0 0 0 10px #111;
  scrollbar-width: none;
}
.phone::-webkit-scrollbar { display: none; }
.stage-note {
  width: 390px;
  text-align: center;
  color: var(--ink-2);
  font-size: 12px;
}
/* ---------- 状态栏（仅桌面原型预览用，线上已移除） ---------- */
.statusbar { display: none; }

/* 注：真机（≤480px）的布局覆盖统一放在本文件末尾，
   避免与后方同优先级的基础规则冲突（CSS 同优先级后写覆盖）。 */

/* ---------- 导航（随页面滚动，不吸顶；标题不再遮住正文） ---------- */
.navbar {
  position: relative;
  z-index: 20;
  padding: 14px 16px 10px;
  background: var(--bg);
  border-bottom: 0.5px solid var(--line);
}
.navbar.no-line { border-bottom-color: transparent; }
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 34px;
}
.nav-back {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: var(--ink);
  font-size: 16px;
  text-decoration: none;
}
.nav-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 16px;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s;
}
.navbar.scrolled .nav-center { opacity: 1; }
.large-title {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.02em;
  padding: 10px 4px 2px;
}
.nav-sub { color: var(--ink-2); font-size: 13px; padding: 0 4px; }

/* ---------- 布局 ---------- */
.page { padding-bottom: 108px; }
.section { padding: 0 16px; margin-top: 24px; }
.section-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 0 4px 10px;
}
.section-h h2 { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
.section-h .more { font-size: 13px; color: var(--accent); text-decoration: none; }

/* ---------- 底部标签栏 ---------- */
.tabbar {
  position: sticky;
  bottom: 0;
  z-index: 30;
  display: flex;
  background: color-mix(in srgb, var(--card) 90%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-top: 0.5px solid var(--line);
  padding: 6px 8px 22px;
}
.tabbar a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-decoration: none;
  color: var(--ink-3);
  font-size: 10px;
  padding: 4px 0;
}
.tabbar a i { font-size: 24px; }
.tabbar a.active { color: var(--accent); }

/* ---------- 按钮 ---------- */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  height: 50px;
  border: 0;
  border-radius: var(--r-md);
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s;
  text-decoration: none;
}
.btn:active { transform: scale(0.98); opacity: 0.9; }
.btn.ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 38%, transparent);
}
.btn.small { height: 38px; font-size: 14px; width: auto; padding: 0 18px; }
.btn.pill { border-radius: 999px; }
.btn.done { background: var(--soft); color: var(--ink-2); }

/* ---------- 卡片 ---------- */
.card {
  background: var(--card);
  border-radius: var(--r-lg);
  padding: 16px;
}

/* ---------- 分组列表 ---------- */
.list {
  background: var(--card);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  min-height: 52px;
}
.row + .row { border-top: 0.5px solid var(--line); }
.row .r-label { font-size: 15px; }
.row .r-value { font-size: 15px; color: var(--ink-2); text-align: right; }
.row .r-value.strong { color: var(--ink); font-weight: 600; }
.row a.r-link { color: var(--accent); text-decoration: none; display: flex; align-items: center; gap: 6px; }

/* ---------- 表单 ---------- */
.field { margin-bottom: 14px; }
.field label {
  display: block;
  font-size: 13px;
  color: var(--ink-2);
  margin-bottom: 6px;
}
.field input, .field select, .field textarea {
  width: 100%;
  height: 48px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-md);
  background: var(--card);
  padding: 0 14px;
  font-family: var(--sans);
  font-size: 16px;
  color: var(--ink);
  outline: none;
}
.field input:focus, .field textarea:focus { border-color: var(--ink); }
.field textarea {
  height: auto;
  min-height: 96px;
  padding: 12px 14px;
  line-height: 1.6;
  resize: vertical;
}
.field .hint { font-size: 12px; color: var(--ink-3); margin-top: 6px; }

/* 后台门店图片管理 */
.img-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}
.img-cell {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: var(--soft);
}
.img-cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.img-cell .img-badge {
  position: absolute;
  left: 4px;
  bottom: 4px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 10px;
}
.img-cell .img-del {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 20px;
  height: 20px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.img-cell .img-cover {
  position: absolute;
  inset: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.upload-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 44px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-md);
  background: var(--card);
  color: var(--accent);
  font-size: 14px;
  cursor: pointer;
}
.upload-btn:active { opacity: 0.75; }
.shop-cover {
  width: 76px;
  height: 76px;
  flex-shrink: 0;
  border-radius: 12px;
  object-fit: cover;
}
.shop-cover-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--soft);
  color: var(--ink-3);
  font-size: 24px;
}

/* ---------- 优惠券票券 ---------- */
.ticket {
  position: relative;
  display: flex;
  background: var(--card);
  border-radius: 16px;
  overflow: hidden;
}
.ticket + .ticket { margin-top: 12px; }
.t-main { flex: 1; padding: 16px; min-width: 0; }
.t-name { font-size: 15px; font-weight: 600; }
.t-meta { font-size: 12px; color: var(--ink-2); margin-top: 4px; }
.t-shop { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.t-stub {
  width: 104px;
  background: var(--accent);
  color: var(--accent-ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  border-left: 1px dashed rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
}
.t-amount { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; }
.t-amount .yen { font-size: 14px; font-weight: 600; margin-right: 1px; }
.t-stub .t-unit { font-size: 11px; opacity: 0.7; }
.ticket::before, .ticket::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg);
  right: 97px;
  z-index: 2;
}
.ticket::before { top: -7px; }
.ticket::after { bottom: -7px; }
.ticket.dim .t-main { opacity: 0.45; }
.ticket.dim .t-stub { background: var(--ink-3); }
.ticket .t-state {
  position: absolute;
  top: 10px;
  right: 116px;
  font-size: 11px;
  color: var(--ink-3);
}
.t-source { font-size: 11px; color: var(--ink-3); margin-top: 6px; }

/* ---------- 领券横滑区 ---------- */
.snap-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 2px 16px 8px;
  margin: 0 -16px;
  scrollbar-width: none;
}
.snap-row::-webkit-scrollbar { display: none; }
.snap-row .ticket {
  flex: 0 0 320px;
  scroll-snap-align: start;
}
.snap-row .ticket::before, .snap-row .ticket::after { right: 97px; }

/* ---------- 券详情 ---------- */
.qr-panel { text-align: center; padding: 28px 16px; }
.qr-box {
  display: inline-block;
  padding: 14px;
  background: #fff;
  border-radius: var(--r-md);
  border: 0.5px solid var(--line);
}
.qr-box img, .qr-box canvas { display: block; }
.coupon-no {
  font-family: var(--mono);
  font-size: 20px;
  letter-spacing: 0.14em;
  margin-top: 14px;
}
.coupon-no-label { font-size: 12px; color: var(--ink-3); margin-top: 2px; }

/* ---------- 服务展示 ---------- */
.svc {
  display: flex;
  gap: 14px;
  align-items: center;
  background: var(--card);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.svc + .svc { margin-top: 12px; }
.svc img {
  width: 108px;
  height: 108px;
  object-fit: cover;
  filter: saturate(1.04);
  flex-shrink: 0;
}
.svc .svc-body { padding: 14px 16px 14px 0; min-width: 0; }
.svc h3 { font-size: 16px; font-weight: 600; }
.svc p { font-size: 13px; color: var(--ink-2); margin-top: 4px; }
.svc .svc-tag { font-size: 11px; color: var(--ink-3); margin-top: 6px; }

/* ---------- Hero ---------- */
.hero { position: relative; height: 340px; overflow: hidden; }
.hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.06);
  display: block;
}
.hero .hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--tint) 0%, rgba(0,0,0,0) 42%, rgba(0,0,0,0.52) 100%);
}
.hero .hero-body {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  color: #fff;
}
.hero .hero-brand { font-size: 13px; letter-spacing: 0.28em; opacity: 0.85; }
.hero h1 {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-top: 6px;
  line-height: 1.15;
}
.hero p { font-size: 13px; opacity: 0.85; margin-top: 6px; }

/* ---------- 统计 ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat-grid.c2 { grid-template-columns: repeat(2, 1fr); }
.stat {
  background: var(--card);
  border-radius: var(--r-lg);
  padding: 14px;
}
.stat .s-label { font-size: 12px; color: var(--ink-2); }
.stat .s-value { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; margin-top: 4px; }
.stat .s-value .yen { font-size: 13px; font-weight: 600; }
.stat .s-unit { font-size: 12px; color: var(--ink-3); font-weight: 400; }
.stat.dark { background: var(--accent); color: var(--accent-ink); }
.stat.dark .s-label { color: rgba(255,255,255,0.6); }

/* ---------- 标签 ---------- */
.tag {
  display: inline-block;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--soft);
  color: var(--ink-2);
  margin-left: 6px;
  vertical-align: 1px;
}
.tag.dark { background: var(--accent); color: var(--accent-ink); }

/* ---------- 分段控件 ---------- */
.segmented {
  display: flex;
  background: #e4e4e9;
  border-radius: 10px;
  padding: 2px;
}
.segmented button {
  flex: 1;
  height: 32px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--ink-2);
  cursor: pointer;
}
.segmented button.on {
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

/* ---------- 二维码卡 ---------- */
.qr-card { text-align: center; padding: 24px 16px 20px; }
.qr-card .qr-holder {
  display: inline-block;
  padding: 12px;
  background: #fff;
  border: 0.5px solid var(--line);
  border-radius: var(--r-md);
}
.invite-code {
  font-family: var(--mono);
  font-size: 18px;
  letter-spacing: 0.12em;
  margin-top: 12px;
}
.invite-link {
  font-size: 12px;
  color: var(--ink-3);
  margin-top: 4px;
  word-break: break-all;
}

/* ---------- 核销取景框 ---------- */
.viewfinder {
  position: relative;
  height: 280px;
  background: #141414;
  border-radius: var(--r-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.viewfinder .vf-hint { color: rgba(255,255,255,0.55); font-size: 13px; text-align: center; }
.vf-box { position: relative; width: 190px; height: 190px; }
.vf-box span { position: absolute; width: 30px; height: 30px; }
.vf-box .tl { top: 0; left: 0; border-top: 2.5px solid #fff; border-left: 2.5px solid #fff; border-radius: 6px 0 0 0; }
.vf-box .tr { top: 0; right: 0; border-top: 2.5px solid #fff; border-right: 2.5px solid #fff; border-radius: 0 6px 0 0; }
.vf-box .bl { bottom: 0; left: 0; border-bottom: 2.5px solid #fff; border-left: 2.5px solid #fff; border-radius: 0 0 0 6px; }
.vf-box .br { bottom: 0; right: 0; border-bottom: 2.5px solid #fff; border-right: 2.5px solid #fff; border-radius: 0 0 6px 0; }
.vf-line {
  position: absolute;
  left: 12px;
  right: 12px;
  height: 1.5px;
  background: rgba(255,255,255,0.75);
  top: 24px;
}
@media (prefers-reduced-motion: no-preference) {
  .vf-line { animation: vfscan 2.4s ease-in-out infinite; }
  @keyframes vfscan {
    0%, 100% { top: 24px; opacity: 0.4; }
    50% { top: 164px; opacity: 1; }
  }
}

/* ---------- 弹层 / toast ---------- */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.42);
  z-index: 60;
  display: none;
  align-items: flex-end;
  justify-content: center;
}
.modal-mask.open { display: flex; }
.modal {
  background: var(--card);
  width: 390px;
  max-width: 100%;
  border-radius: 22px 22px 0 0;
  padding: 22px 20px 34px;
}
.modal h3 { font-size: 18px; font-weight: 700; text-align: center; }
.modal .m-sub { font-size: 13px; color: var(--ink-2); text-align: center; margin-top: 6px; }
.modal .m-btns { display: flex; gap: 10px; margin-top: 20px; }
.toast {
  position: fixed;
  left: 50%;
  bottom: 130px;
  transform: translateX(-50%) translateY(8px);
  background: rgba(29,29,31,0.92);
  color: #fff;
  font-size: 14px;
  padding: 10px 20px;
  border-radius: 999px;
  opacity: 0;
  transition: all 0.25s;
  z-index: 70;
  pointer-events: none;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 空状态 ---------- */
.empty { text-align: center; padding: 44px 0 20px; }
.empty i { font-size: 40px; color: var(--ink-3); }
.empty p { font-size: 14px; color: var(--ink-2); margin-top: 8px; }
.empty .e-sub { font-size: 12px; color: var(--ink-3); margin-top: 2px; }

/* ---------- 流水 ---------- */
.flow-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 13px 16px; }
.flow-row + .flow-row { border-top: 0.5px solid var(--line); }
.flow-row .f-title { font-size: 14px; font-weight: 600; }
.flow-row .f-sub { font-size: 12px; color: var(--ink-2); margin-top: 2px; }
.flow-row .f-sub .anon { color: var(--ink-3); font-style: normal; }
.flow-row .f-amt { font-size: 15px; font-weight: 700; white-space: nowrap; }
.flow-row .f-time { font-size: 11px; color: var(--ink-3); margin-top: 2px; text-align: right; }

/* ---------- 杂项 ---------- */
.mono { font-family: var(--mono); }
.muted { color: var(--ink-2); }
.tiny { font-size: 12px; color: var(--ink-3); }
.footnote {
  padding: 20px 24px 0;
  text-align: center;
  font-size: 11px;
  color: var(--ink-3);
  line-height: 1.7;
}
.avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 600;
  flex-shrink: 0;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--ink-2);
  background: var(--soft);
  border-radius: 999px;
  padding: 6px 14px;
}
.notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: var(--soft);
  border-radius: var(--r-md);
  padding: 12px 14px;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.55;
}
.notice i { font-size: 17px; margin-top: 1px; color: var(--accent); }

/* ============================================================
   Phase 2 新增组件（后台 / 数据可视化 / 状态块）
   ============================================================ */

/* 后台快捷导航（横向滚动 chip 行） */
.nav-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 6px;
  scrollbar-width: none;
}
.nav-scroll::-webkit-scrollbar { display: none; }
.nav-scroll .chip {
  flex: 0 0 auto;
  text-decoration: none;
  color: var(--ink-2);
  background: var(--card);
  border: 1px solid var(--line);
}
.nav-scroll .chip-on {
  color: var(--accent-ink);
  background: var(--accent);
  border-color: var(--accent);
}

/* 多选胶囊组 */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-row .chip {
  cursor: pointer;
  border: 1px solid var(--line-strong);
  background: var(--card);
  color: var(--ink-2);
  font-family: var(--sans);
  font-size: 13px;
}
.chip-row .chip-on {
  color: var(--accent-ink);
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 600;
}

/* 统计卡栅格补充列数 */
.stat-grid.c1 { grid-template-columns: 1fr; }
.stat-grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat-grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stat-grid .s-unit { font-size: 12px; font-weight: 500; opacity: 0.7; }

/* 柱状图（近 7 日走势） */
.bar-chart {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
  height: 132px;
  padding-top: 6px;
}
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; }
.bar-pair {
  flex: 1;
  display: flex;
  align-items: flex-end;
  gap: 3px;
  width: 100%;
  justify-content: center;
}
.bar { width: 8px; border-radius: 4px; min-height: 2px; }
.bar-a { background: color-mix(in srgb, var(--accent) 32%, transparent); }
.bar-b { background: var(--accent); }
.bar-date { font-size: 10px; color: var(--ink-3); margin-top: 6px; }

/* 图例圆点 */
.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin: 0 4px 0 8px;
  vertical-align: middle;
}
.dot-a { background: color-mix(in srgb, var(--accent) 32%, transparent); }
.dot-b { background: var(--accent); }

/* 券不可用状态块（券详情页） */
.state-block {
  margin-top: 22px;
  padding: 22px 0;
  border-top: 0.5px solid var(--line);
  border-bottom: 0.5px solid var(--line);
}
.state-block i { font-size: 40px; color: var(--ink-3); }
.state-block .sb-title { font-size: 17px; font-weight: 600; margin-top: 8px; }

/* 卡片内两列按钮组 */
.m-btns { display: flex; gap: 10px; }
.m-btns .btn { flex: 1; }

/* 小程序式弹层滚动（后台长表单） */
.modal { max-height: 86vh; overflow-y: auto; }

/* 列表行内小按钮 */
.btn.small { height: 38px; font-size: 14px; }

/* ============================================================
   商家详情页（shop-detail）
   ============================================================ */

/* 顶部沉浸式大图轮播 */
.shop-gallery { position: relative; background: #14100c; }
.shop-gallery .g-track {
  display: flex;
  height: 292px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.shop-gallery .g-track::-webkit-scrollbar { display: none; }
.shop-gallery .g-track img {
  flex: 0 0 100%;
  width: 100%;
  height: 292px;
  object-fit: cover;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  display: block;
}
.g-back {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 4;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 19px;
  text-decoration: none;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.g-back:active { opacity: 0.75; }
.g-count {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 4;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.g-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 14px;
  z-index: 3;
  display: flex;
  justify-content: center;
  gap: 5px;
  pointer-events: none;
}
.g-dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  transition: width 0.2s;
}
.g-dots i.on { background: #fff; width: 15px; border-radius: 3px; }

/* 缩略图条 */
.thumb-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 4px 6px;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.thumb-row::-webkit-scrollbar { display: none; }
.thumb-row button {
  flex: 0 0 auto;
  width: 64px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  overflow: hidden;
  background: var(--soft);
  cursor: pointer;
  opacity: 0.5;
  outline: 2px solid transparent;
  outline-offset: -2px;
  transition: opacity 0.18s, outline-color 0.18s;
}
.thumb-row button img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-row button.on { opacity: 1; outline-color: var(--accent); }

/* 商家头部 */
.shop-head { padding: 18px 20px 0; }
.shop-head h1 { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.25; }
.shop-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.shop-head .shop-intro {
  font-size: 14px;
  color: var(--ink-2);
  margin-top: 12px;
  line-height: 1.65;
}
.shop-detail-text {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.78;
  white-space: pre-wrap;
}
.shop-stat {
  display: flex;
  gap: 22px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 0.5px solid var(--line);
}
.shop-stat div b { font-size: 17px; font-weight: 700; }
.shop-stat div span { display: block; font-size: 11px; color: var(--ink-3); margin-top: 2px; }

/* 底部操作条（与 tabbar 同策略：桌面框内 sticky，真机改 fixed） */
.shop-actions {
  position: sticky;
  bottom: 0;
  z-index: 35;
  display: flex;
  gap: 10px;
  padding: 10px 16px 20px;
  background: color-mix(in srgb, var(--card) 92%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(18px);
  backdrop-filter: saturate(180%) blur(18px);
  border-top: 0.5px solid var(--line);
}
.shop-actions .btn { flex: 1; }
.shop-actions .btn.ghost { flex: 0 0 104px; }

/* 全屏看图 */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.96);
  display: none;
}
.lightbox.open { display: block; }
.lightbox .lb-track {
  display: flex;
  height: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}
.lightbox .lb-track::-webkit-scrollbar { display: none; }
.lightbox .lb-track img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: contain;
  scroll-snap-align: center;
  display: block;
}
.lightbox .lb-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
}
.lightbox .lb-idx {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 26px;
  text-align: center;
  color: #fff;
  font-size: 13px;
  opacity: 0.75;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   真机布局（≤480px）—— 统一收口，必须放在文件最末尾
   三条原则：
     1) 放弃「手机框内滚动」，交还给整页文档滚动；
     2) 顶部导航与页面标题随页面滚动（不吸顶），不再遮住正文；
     3) 底部标签栏 position:fixed 固定吸底，并适配 iPhone 底部安全区。
   ============================================================ */
@media (max-width: 480px) {
  body { padding: 0; display: block; background: var(--bg); }
  .stage { display: block; gap: 0; width: 100%; }
  .phone {
    width: 100%;
    max-width: 100vw;
    height: auto;
    min-height: 100vh;
    min-height: 100dvh;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
  }
  .stage-note { display: none; }
  .statusbar { display: none; }
  .navbar .nav-center { display: none; }

  .tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 45;
    padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }
  .page { padding-bottom: calc(120px + env(safe-area-inset-bottom, 0px)); }
  .toast { bottom: calc(140px + env(safe-area-inset-bottom, 0px)); }
  .modal { padding-bottom: calc(34px + env(safe-area-inset-bottom, 0px)); }

  /* 商家详情：大图高度随屏宽收放，底部操作条真固定 */
  .shop-gallery .g-track,
  .shop-gallery .g-track img { height: 68vw; max-height: 380px; }
  .shop-actions {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    padding-bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  }
}

/* ---------- 2026-09-14：商家卡电话/导航 + 昵称编辑 ---------- */
.svc { position: relative; }
.svc .svc-main { flex: 1; min-width: 0; display: flex; gap: 14px; align-items: center; }
.svc .svc-body { padding: 14px 16px 52px 0; }
.svc-acts {
  position: absolute;
  right: 10px;
  bottom: 12px;
  display: flex;
  gap: 8px;
}
.svc-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 28px;
  padding: 0 12px;
  border-radius: 14px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  font-size: 12px;
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
}
.svc-btn i { font-size: 14px; }
.svc-btn:active { background: var(--soft); }

.nick-edit {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--card);
  color: var(--ink-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}
.nick-input {
  width: 130px;
  height: 30px;
  border: 1px solid var(--ink);
  border-radius: 8px;
  padding: 0 8px;
  font-size: 14px;
  font-family: var(--sans);
  background: var(--card);
  color: var(--ink);
}
.nick-save, .nick-cancel {
  height: 28px;
  padding: 0 12px;
  border-radius: 14px;
  font-size: 12px;
  border: none;
  font-family: var(--sans);
  flex-shrink: 0;
}
.nick-save { background: var(--ink); color: var(--bg); }
.nick-cancel { background: var(--soft); color: var(--ink-2); }
