/* ============================================================
   乐福包小程序 · 共享设计系统（源自《乐福包小程序展示提案 v2.pdf》）
   所有颜色 token 收敛于 :root；页面内不得出现裸 hex。
   ============================================================ */
:root {
  /* 基础色 */
  --bg: #f7f3ea;
  --bg-deep: #ede6d6;
  --surface: #ffffff;
  --fg: #382a21;
  --fg-2: #5f5044;
  --muted: #796d5f;
  --border: #ebe3d2;
  --accent: #c2452f;
  --accent-deep: #a93521;
  --accent-soft: #fbeae4;
  --accent-soft-border: #f3d4c8;

  /* 分类色（家庭橙 / 女性红 / 健康绿 / 儿童黄 / 服务蓝紫） */
  --cat-family: #e2801f;
  --cat-family-2: #ef9a3d;
  --cat-female: #c9352c;
  --cat-female-2: #d95a48;
  --cat-health: #2e9e63;
  --cat-health-2: #41b478;
  --cat-child: #ee9d26;
  --cat-child-2: #f4b340;
  --cat-service: #575fd0;
  --cat-service-2: #7a80e2;

  /* 渐变 */
  --grad-banner: linear-gradient(102deg, #bf4030 0%, #d3662f 55%, #e08f3c 100%);
  --grad-brand-btn: linear-gradient(100deg, #d75f35 0%, #e8923f 100%);
  --grad-family: linear-gradient(135deg, var(--cat-family-2), var(--cat-family));
  --grad-female: linear-gradient(135deg, var(--cat-female-2), var(--cat-female));
  --grad-health: linear-gradient(135deg, var(--cat-health-2), var(--cat-health));
  --grad-child: linear-gradient(135deg, var(--cat-child-2), var(--cat-child));
  --grad-service: linear-gradient(135deg, var(--cat-service-2), var(--cat-service));

  /* 功能色底 */
  --gold-bg: #f8eed8;
  --gold-fg: #8a6526;
  --gold-border: #eddfc0;
  --tint-orange: #fdf3e2;
  --tint-orange-fg: #a95610;
  --tint-red: #fbeae4;
  --tint-red-fg: #ab3c2a;
  --disabled-fg: #a9a294;
  --disabled-bg: #b3ac9d;
  --white: #ffffff;

  /* 结构色 */
  --bezel-1: #3d3a38;
  --bezel-2: #191715;
  --hot-border: #f4e2c4;
  --hot-sub: #97795a;
  --soldout-border: #e6e0d2;
  --soldout-sponsor: #bcab84;
  --hover-border-warm: #ecd9b8;
  --code-border: #e3c9a8;
  --arrow: #c9bfae;

  /* 派生透明色（供结构组件使用） */
  --ink-shadow: rgba(46, 32, 18, 0.35);
  --fg-06: rgba(56, 42, 33, 0.07);
  --fg-10: rgba(56, 42, 33, 0.10);
  --fg-12: rgba(56, 42, 33, 0.12);
  --accent-shadow: rgba(191, 64, 48, 0.28);
  --accent-shadow-lg: rgba(191, 64, 48, 0.30);
  --accent-halo: rgba(194, 69, 47, 0.08);
  --accent-wash: rgba(194, 69, 47, 0.06);
  --btn-shadow: rgba(120, 40, 20, 0.22);
  --btn-shadow-sm: rgba(120, 40, 20, 0.20);
  --brand-btn-shadow: rgba(216, 120, 50, 0.35);
  --icon-inset: rgba(0, 0, 0, 0.10);
  --icon-drop: rgba(74, 56, 38, 0.12);
  --card-shadow-hover: rgba(74, 56, 38, 0.10);
  --toast-bg: rgba(28, 22, 18, 0.88);
  --white-22: rgba(255, 255, 255, 0.22);
  --white-30: rgba(255, 255, 255, 0.30);
  --white-72: rgba(255, 255, 255, 0.72);
  --white-88: rgba(255, 255, 255, 0.88);
  --white-35: rgba(255, 255, 255, 0.35);
  --white-14: rgba(255, 255, 255, 0.14);
  --muted-12: rgba(135, 123, 109, 0.12);
  --white-18: rgba(255, 255, 255, 0.18);
  --stage-glow: rgba(216, 130, 60, 0.10);

  /* 字体 */
  --font-body: -apple-system, BlinkMacSystemFont, "PingFang SC", "HarmonyOS Sans SC", "Source Han Sans SC", "Microsoft YaHei", sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, Menlo, monospace;

  /* 圆角 / 阴影 */
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 22px;
  --shadow-card: 0 1px 2px rgba(74, 56, 38, 0.04), 0 6px 18px rgba(74, 56, 38, 0.05);
  --shadow-pop: 0 10px 30px rgba(74, 56, 38, 0.16);
}

/* ─── 基础 ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  color: var(--fg);
  background:
    radial-gradient(1200px 600px at 50% -10%, var(--stage-glow), transparent 60%),
    var(--bg-deep);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; padding: 0; }
p, h1, h2, h3, h4 { margin: 0; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* ─── 桌面舞台 + 手机壳 ─────────────────────────────────── */
.stage {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 24px 16px;
}
.stage-caption {
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
}
.stage-caption .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--cat-family); }

.phone {
  width: 392px;
  max-width: 100%;
  height: min(844px, calc(100vh - 88px));
  min-height: 560px;
  background: linear-gradient(160deg, var(--bezel-1), var(--bezel-2));
  border-radius: 54px;
  padding: 10px;
  box-shadow: 0 24px 60px var(--ink-shadow), inset 0 1px 1px var(--white-22);
  flex: none;
}
.screen {
  position: relative;
  width: 100%;
  height: 100%;
  background: var(--bg);
  border-radius: 44px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  font-size: 14px;
  line-height: 1.5;
}
.screen-scroll {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: none;
}
.screen-scroll::-webkit-scrollbar { display: none; }
@media (max-width: 480px) {
  .stage { padding: 0; gap: 0; }
  .stage-caption { display: none; }
  .phone { width: 100%; height: 100dvh; min-height: 100dvh; border-radius: 0; padding: 0; box-shadow: none; }
  .screen { border-radius: 0; }
}

/* ─── 状态栏 / 导航（微信原生习惯） ─────────────────────── */
.statusbar {
  flex: none;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 24px 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
}
.statusbar .icons { display: flex; align-items: center; gap: 6px; }
.statusbar svg { display: block; }

.navbar {
  flex: none;
  position: relative;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.navbar .nav-title { font-size: 16px; font-weight: 600; letter-spacing: 0.02em; }
.navbar .nav-back {
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--fg);
}
.navbar .nav-back:active { background: var(--fg-06); }
.capsule {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 87px;
  height: 32px;
  border: 1px solid var(--fg-10);
  background: var(--white-72);
  border-radius: 999px;
  display: flex;
  align-items: center;
  color: var(--fg);
}
.capsule .cap-btn { flex: 1; height: 100%; display: grid; place-items: center; }
.capsule .cap-div { width: 1px; height: 18px; background: var(--fg-12); }

/* 页面主体通用内边距 */
.page-pad { padding: 0 14px; }

/* ─── 顶部预约横幅（全分类通用，取自 PDF） ───────────────── */
.banner {
  position: relative;
  margin: 6px 14px 0;
  border-radius: var(--r-lg);
  background: var(--grad-banner);
  color: var(--white);
  padding: 18px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 22px var(--accent-shadow);
  overflow: hidden;
}
.banner .banner-deco {
  flex: none;
  font-size: 30px;
  line-height: 1;
  transform: rotate(-8deg);
  align-self: center;
  filter: drop-shadow(0 2px 4px var(--btn-shadow-sm));
  pointer-events: none;
}
.banner .banner-main { flex: 1; min-width: 0; position: relative; }
.banner .banner-title { font-size: 19px; font-weight: 700; line-height: 1.32; letter-spacing: 0.02em; }
.banner .banner-sub { margin-top: 5px; font-size: 11.5px; color: color-mix(in srgb, var(--white) 88%, transparent); letter-spacing: 0.04em; }
.banner .banner-cta {
  flex: none;
  background: var(--white);
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  padding: 9px 13px;
  border-radius: 14px;
  box-shadow: 0 4px 10px var(--btn-shadow);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.banner .banner-cta:active { transform: scale(0.96); box-shadow: 0 2px 6px var(--btn-shadow-sm); }

/* ─── 区块头 ───────────────────────────────────────────── */
.section-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 22px 0 12px;
}
.section-head .bar { width: 5px; height: 17px; border-radius: 99px; background: var(--accent); flex: none; }
.section-head .sec-title { font-size: 17px; font-weight: 700; letter-spacing: 0.02em; }
.section-head .sec-pill {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  color: var(--tint-red-fg);
  background: var(--tint-red);
  border-radius: 999px;
  padding: 3px 10px;
  letter-spacing: 0.03em;
  flex: none;
}
.section-head .sec-pill.pill-orange { color: var(--tint-orange-fg); background: var(--tint-orange); }

/* ─── 卡片 ─────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-card);
}

/* ─── 礼包主卡（分类页置首） ────────────────────────────── */
.gift-card { padding: 18px 16px 16px; }
.gift-card .gift-top { display: flex; gap: 13px; align-items: flex-start; }
.gift-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 30px;
  flex: none;
  box-shadow: inset 0 -3px 6px var(--icon-inset), 0 6px 12px var(--icon-drop);
}
.gift-name { font-size: 18px; font-weight: 700; letter-spacing: 0.02em; }
.gift-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 7px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--gold-fg);
  background: var(--gold-bg);
  border: 1px solid var(--gold-border);
  border-radius: 999px;
  padding: 3px 9px;
  letter-spacing: 0.03em;
}
.chip-row { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 13px; }
.chip {
  font-size: 11.5px;
  color: var(--fg-2);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3.5px 10px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

/* 礼包卡内行动条（分类色渐变） */
.cta-banner {
  margin-top: 14px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: var(--white);
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 12px 10px;
  border-radius: var(--r-md);
  transition: filter 0.12s ease, transform 0.12s ease;
}
.cta-banner:active { filter: brightness(0.94); transform: scale(0.99); }
.cta-banner .deco { font-size: 16px; }

/* ─── 通知行 ───────────────────────────────────────────── */
.notice-stack { display: flex; flex-direction: column; gap: 9px; margin-top: 12px; }
.notice {
  border-radius: var(--r-md);
  padding: 11px 13px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--fg);
  border: 1px solid var(--border);
  background: var(--surface);
}
.notice .n-line { display: flex; gap: 8px; align-items: flex-start; }
.notice .n-emoji { flex: none; font-size: 14px; line-height: 1.4; }
.notice .n-strong { font-weight: 700; }
.notice .n-red { color: var(--accent); }
.notice .n-sub { color: var(--muted); font-size: 11.5px; margin-top: 2px; padding-left: 22px; }
.notice.hot { background: var(--tint-orange); border-color: var(--hot-border); }
.notice.hot .n-title { color: var(--tint-orange-fg); font-weight: 700; font-size: 13px; display: flex; gap: 7px; align-items: center; }
.notice.hot .n-sub { color: var(--hot-sub); text-align: center; padding-left: 0; }
.tag-demo {
  display: inline-block;
  margin-left: 6px;
  font-size: 9.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--muted-12);
  border-radius: 999px;
  padding: 1px 6px;
  vertical-align: 1px;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

/* ─── 票券行（礼券/课程，取自 PDF） ─────────────────────── */
.rule-bar {
  margin-top: 12px;
  background: var(--tint-red);
  border: 1px solid var(--accent-soft-border);
  color: var(--tint-red-fg);
  font-size: 12.5px;
  font-weight: 600;
  border-radius: var(--r-md);
  padding: 10px 13px;
  text-align: center;
  letter-spacing: 0.02em;
}
.ticket-list { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.ticket {
  position: relative;
  display: flex;
  align-items: stretch;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.ticket .stub {
  flex: none;
  width: 76px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--white);
  padding: 14px 6px;
}
.ticket .stub .stub-char { font-size: 24px; font-weight: 700; line-height: 1; }
.ticket .stub .stub-label { font-size: 9.5px; opacity: 0.85; letter-spacing: 0.12em; }
.ticket .t-body { flex: 1; min-width: 0; padding: 12px 12px 12px 16px; display: flex; flex-direction: column; justify-content: center; gap: 3px; }
.ticket .t-name { font-size: 14.5px; font-weight: 700; letter-spacing: 0.01em; }
.ticket .t-sponsor { font-size: 10.5px; color: var(--gold-fg); display: flex; align-items: center; gap: 4px; }
.ticket .t-desc { font-size: 10.5px; color: var(--muted); }
.ticket .t-action {
  flex: none;
  width: 62px;
  display: grid;
  place-items: center;
  border-left: 1px dashed var(--border);
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
  transition: background 0.12s ease;
}
.ticket .t-action:hover { background: var(--accent-soft); }
button.t-action:active { background: var(--accent-soft); }
.ticket .t-action.action-gray { color: var(--disabled-fg); font-size: 13px; }
/* 打孔 */
.ticket::before, .ticket::after {
  content: "";
  position: absolute;
  left: 76px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  transform: translateX(-50%);
  z-index: 1;
}
.ticket::before { top: -7px; }
.ticket::after { bottom: -7px; }
/* 售罄置灰 */
.ticket.soldout { border-color: var(--soldout-border); box-shadow: none; }
.ticket.soldout .stub { background: var(--disabled-bg) !important; }
.ticket.soldout .t-name { color: var(--disabled-fg); }
.ticket.soldout .t-sponsor { color: var(--soldout-sponsor); }
.ticket.soldout .t-action { color: var(--disabled-fg); }
.ticket.soldout .t-action:hover { background: transparent; }

/* ─── 底部固定条（品牌 + 预约有礼，取自 PDF） ────────────── */
.bottom-bar {
  flex: none;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 10px 14px calc(12px + env(safe-area-inset-bottom, 6px));
}
.bottom-bar .brand { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.bottom-bar .brand .heart { font-size: 20px; line-height: 1; }
.bottom-bar .brand .b-name { font-size: 13px; font-weight: 700; color: var(--accent); line-height: 1.25; }
.bottom-bar .brand .b-sub { font-size: 13px; font-weight: 700; color: var(--fg); line-height: 1.25; }
.btn-brand-cta {
  flex: none;
  min-width: 128px;
  padding: 12px 26px;
  border-radius: 999px;
  background: var(--grad-brand-btn);
  color: var(--white);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-align: center;
  box-shadow: 0 6px 14px var(--brand-btn-shadow);
  transition: filter 0.12s ease, transform 0.12s ease;
}
.btn-brand-cta:hover { filter: brightness(1.04); }
.btn-brand-cta:active { filter: brightness(0.95); transform: scale(0.98); }

/* ─── TabBar（首页/我的福利/我的） ──────────────────────── */
.tabbar {
  flex: none;
  display: flex;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 6px 8px calc(8px + env(safe-area-inset-bottom, 6px));
}
.tabbar .tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 4px 0 2px;
  color: var(--muted);
  font-size: 10.5px;
  border-radius: 10px;
  transition: color 0.12s ease, background 0.12s ease;
}
.tabbar .tab svg { display: block; }
.tabbar .tab.active { color: var(--accent); font-weight: 600; }
.tabbar .tab:hover { background: var(--accent-wash); }

/* ─── 按钮 ─────────────────────────────────────────────── */
.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 13px 16px;
  border-radius: 999px;
  background: var(--grad-banner);
  color: var(--white);
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 18px var(--accent-shadow-lg);
  transition: filter 0.12s ease, transform 0.12s ease;
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary:active { filter: brightness(0.94); transform: scale(0.99); }
.btn-ghost {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 16px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--fg-2);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.btn-ghost:hover { background: var(--tint-orange); border-color: var(--hover-border-warm); color: var(--fg); }
.btn-ghost:active { filter: brightness(0.97); }

/* ─── Toast（微信风格） ────────────────────────────────── */
.toast {
  position: absolute;
  left: 50%;
  top: 46%;
  transform: translateX(-50%) translateY(6px);
  max-width: 78%;
  background: var(--toast-bg);
  color: var(--white);
  font-size: 12.5px;
  line-height: 1.5;
  padding: 10px 16px;
  border-radius: 10px;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 90;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ─── 键值行 / 列表 ─────────────────────────────────────── */
.kv-list { display: flex; flex-direction: column; }
.kv {
  display: flex;
  gap: 12px;
  padding: 11px 2px;
  font-size: 13px;
  line-height: 1.5;
  border-bottom: 1px solid var(--border);
}
.kv:last-child { border-bottom: 0; }
.kv .k { flex: none; width: 74px; color: var(--muted); }
.kv .v { flex: 1; color: var(--fg); font-weight: 500; }
.kv .v .demo-note { color: var(--muted); font-weight: 400; font-size: 11.5px; }

/* 编号列表（使用说明） */
.ol-steps { display: flex; flex-direction: column; gap: 9px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.ol-steps li { counter-increment: step; position: relative; padding-left: 26px; font-size: 12.5px; line-height: 1.55; color: var(--fg-2); }
.ol-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 1.5px;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--tint-red);
  color: var(--tint-red-fg);
  font-size: 10.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
}

/* ─── 成功页 ───────────────────────────────────────────── */
.success-hero { text-align: center; padding: 26px 14px 6px; }
.success-mark {
  width: 72px;
  height: 72px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--grad-banner);
  display: grid;
  place-items: center;
  box-shadow: 0 0 0 10px var(--accent-halo), 0 12px 24px var(--accent-shadow-lg);
}
.success-title { margin-top: 16px; font-size: 20px; font-weight: 700; letter-spacing: 0.04em; }
.success-sub { margin-top: 6px; font-size: 12.5px; color: var(--muted); }

/* 兑换码面板 */
.code-panel {
  margin: 14px 14px 0;
  background: var(--surface);
  border: 1px dashed var(--code-border);
  border-radius: var(--r-lg);
  padding: 15px 14px 13px;
  text-align: center;
  position: relative;
}
.code-panel .code-label { font-size: 10.5px; letter-spacing: 0.22em; color: var(--muted); }
.code-panel .code-value {
  margin-top: 7px;
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.10em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.code-panel .code-copy {
  margin-top: 9px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: var(--fg-2);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 14px;
  transition: background 0.12s ease;
}
.code-panel .code-copy:hover { background: var(--tint-orange); }
.code-panel .code-copy:active { filter: brightness(0.96); }

/* ─── 温馨提示条 ───────────────────────────────────────── */
.remind {
  margin: 14px 14px 0;
  background: var(--tint-red);
  border: 1px solid var(--accent-soft-border);
  border-radius: var(--r-md);
  padding: 11px 13px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--tint-red-fg);
  display: flex;
  gap: 8px;
}
.remind .r-emoji { flex: none; }

/* ─── 页脚免责 ─────────────────────────────────────────── */
.footer-note {
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
  padding: 26px 24px calc(20px + env(safe-area-inset-bottom, 6px));
}

/* ─── 首页分类入口 ─────────────────────────────────────── */
.entry-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.entry-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  text-align: left;
}
.entry-card:hover { transform: translateY(-1px); box-shadow: 0 8px 20px var(--card-shadow-hover); }
.entry-card:active { transform: scale(0.98); }
.entry-icon {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  font-size: 24px;
  box-shadow: inset 0 -3px 5px var(--icon-inset);
}
.entry-name { font-size: 14px; font-weight: 700; }
.entry-desc { margin-top: 2px; font-size: 10.5px; color: var(--muted); line-height: 1.4; }
.entry-card.wide { grid-column: 1 / -1; }
.entry-arrow { margin-left: auto; color: var(--arrow); flex: none; }

/* ─── 流程步骤 ─────────────────────────────────────────── */
.flow { display: flex; flex-direction: column; }
.flow-item { position: relative; display: flex; gap: 12px; padding-bottom: 16px; }
.flow-item:last-child { padding-bottom: 2px; }
.flow-item::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 28px;
  bottom: 2px;
  width: 2px;
  background: var(--border);
}
.flow-item:last-child::before { display: none; }
.flow-num {
  flex: none;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: var(--accent-soft);
  border: 1px solid var(--accent-soft-border);
  color: var(--tint-red-fg);
  font-size: 13px;
  font-weight: 700;
  display: grid;
  place-items: center;
  z-index: 1;
}
.flow-body { flex: 1; min-width: 0; padding-top: 3px; }
.flow-title { font-size: 13.5px; font-weight: 700; color: var(--fg); }
.flow-desc { margin-top: 3px; font-size: 11.5px; color: var(--muted); line-height: 1.55; }

/* 按压缩放反馈 */
.pressable { transition: transform 0.1s ease; }
.pressable:active { transform: scale(0.98); }

/* ─── 第二阶段：分类主题（仅内容区 accent 联动色 → 分类色，color-mix 派生，对比度 ≥4.5:1） ── */
.theme-family, .theme-health, .theme-child, .theme-service { --accent-shadow: var(--icon-drop); }
.theme-family {
  --accent: color-mix(in srgb, var(--cat-family) 50%, var(--fg));
  --accent-deep: color-mix(in srgb, var(--cat-family) 38%, var(--fg));
  --tint-red: color-mix(in srgb, var(--cat-family) 10%, var(--surface));
  --tint-red-fg: color-mix(in srgb, var(--cat-family) 50%, var(--fg));
  --accent-soft: color-mix(in srgb, var(--cat-family) 8%, var(--surface));
  --accent-soft-border: color-mix(in srgb, var(--cat-family) 25%, var(--surface));
  --th-grad: linear-gradient(135deg, color-mix(in srgb, var(--cat-family) 55%, var(--fg)), color-mix(in srgb, var(--cat-family) 42%, var(--fg)));
  --th-grad-lg: linear-gradient(135deg, color-mix(in srgb, var(--cat-family) 75%, var(--fg)), color-mix(in srgb, var(--cat-family) 60%, var(--fg)));
}
.theme-health {
  --accent: color-mix(in srgb, var(--cat-health) 62%, var(--fg));
  --accent-deep: color-mix(in srgb, var(--cat-health) 45%, var(--fg));
  --tint-red: color-mix(in srgb, var(--cat-health) 10%, var(--surface));
  --tint-red-fg: color-mix(in srgb, var(--cat-health) 55%, var(--fg));
  --accent-soft: color-mix(in srgb, var(--cat-health) 8%, var(--surface));
  --accent-soft-border: color-mix(in srgb, var(--cat-health) 25%, var(--surface));
  --th-grad: linear-gradient(135deg, color-mix(in srgb, var(--cat-health) 60%, var(--fg)), color-mix(in srgb, var(--cat-health) 45%, var(--fg)));
  --th-grad-lg: linear-gradient(135deg, color-mix(in srgb, var(--cat-health) 78%, var(--fg)), color-mix(in srgb, var(--cat-health) 62%, var(--fg)));
}
.theme-child {
  --accent: color-mix(in srgb, var(--cat-child) 50%, var(--fg));
  --accent-deep: color-mix(in srgb, var(--cat-child) 38%, var(--fg));
  --tint-red: color-mix(in srgb, var(--cat-child) 11%, var(--surface));
  --tint-red-fg: color-mix(in srgb, var(--cat-child) 48%, var(--fg));
  --accent-soft: color-mix(in srgb, var(--cat-child) 9%, var(--surface));
  --accent-soft-border: color-mix(in srgb, var(--cat-child) 26%, var(--surface));
  --th-grad: linear-gradient(135deg, color-mix(in srgb, var(--cat-child) 55%, var(--fg)), color-mix(in srgb, var(--cat-child) 42%, var(--fg)));
  --th-grad-lg: linear-gradient(135deg, color-mix(in srgb, var(--cat-child) 75%, var(--fg)), color-mix(in srgb, var(--cat-child) 60%, var(--fg)));
}
.theme-service {
  --accent: color-mix(in srgb, var(--cat-service) 68%, var(--fg));
  --accent-deep: color-mix(in srgb, var(--cat-service) 52%, var(--fg));
  --tint-red: color-mix(in srgb, var(--cat-service) 9%, var(--surface));
  --tint-red-fg: color-mix(in srgb, var(--cat-service) 62%, var(--fg));
  --accent-soft: color-mix(in srgb, var(--cat-service) 8%, var(--surface));
  --accent-soft-border: color-mix(in srgb, var(--cat-service) 24%, var(--surface));
  --th-grad: linear-gradient(135deg, color-mix(in srgb, var(--cat-service) 70%, var(--fg)), color-mix(in srgb, var(--cat-service) 52%, var(--fg)));
  --th-grad-lg: linear-gradient(135deg, color-mix(in srgb, var(--cat-service) 85%, var(--fg)), color-mix(in srgb, var(--cat-service) 68%, var(--fg)));
}

/* ─── 分段 Tab（我的福利） ─────────────────────────────── */
.seg {
  display: flex; gap: 2px; margin: 12px 14px 0;
  background: var(--muted-12); border-radius: 999px; padding: 3px;
}
.seg .seg-btn {
  flex: 1; border-radius: 999px; padding: 8px 0; text-align: center;
  font-size: 13px; font-weight: 600; color: var(--fg-2);
  transition: background 0.12s ease, color 0.12s ease;
}
.seg .seg-btn.on {
  background: var(--surface); color: var(--accent); font-weight: 700;
  box-shadow: 0 1px 4px var(--icon-drop);
}

/* ─── 领取记录卡 ───────────────────────────────────────── */
.rec-list { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.rec-card {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 14px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow-card);
}
.rec-thumb {
  flex: none; width: 52px; height: 52px; border-radius: 14px;
  display: grid; place-items: center; font-size: 26px;
  box-shadow: inset 0 -3px 5px var(--icon-inset);
}
.rec-body { flex: 1; min-width: 0; }
.rec-name { font-size: 14px; font-weight: 700; }
.rec-meta { margin-top: 3px; font-size: 11px; color: var(--muted); line-height: 1.5; }
.rec-tag {
  display: inline-block; margin-top: 5px;
  font-size: 10px; font-weight: 600; letter-spacing: 0.04em;
  color: var(--tint-red-fg); background: var(--tint-red);
  border-radius: 999px; padding: 2px 8px;
}
.rec-go { flex: none; display: flex; align-items: center; gap: 2px; font-size: 12.5px; font-weight: 700; color: var(--accent); }
.demo-toggle {
  margin: 10px 14px 0; text-align: center;
}
.demo-toggle button {
  font-size: 10.5px; color: var(--muted);
  border: 1px dashed var(--border); border-radius: 999px;
  padding: 4px 12px; letter-spacing: 0.04em;
  transition: color 0.12s ease, border-color 0.12s ease;
}
.demo-toggle button:hover { color: var(--fg-2); border-color: var(--arrow); }

/* ─── 空状态 ───────────────────────────────────────────── */
.empty { text-align: center; padding: 46px 24px 34px; }
.empty .e-mark {
  width: 76px; height: 76px; margin: 0 auto; border-radius: 50%;
  background: var(--accent-soft); border: 1px solid var(--accent-soft-border);
  display: grid; place-items: center; font-size: 34px;
}
.empty .e-title { margin-top: 14px; font-size: 15px; font-weight: 700; color: var(--fg); }
.empty .e-sub { margin-top: 6px; font-size: 12px; color: var(--muted); line-height: 1.6; }
.empty .btn-ghost { width: auto; display: inline-flex; margin-top: 16px; padding: 10px 26px; }

/* ─── 手风琴（我的页说明区） ───────────────────────────── */
.acc-list { padding: 2px 16px; }
.acc { border-bottom: 1px solid var(--border); }
.acc:last-child { border-bottom: 0; }
.acc-head {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 14px 2px; font-size: 14px; font-weight: 600; color: var(--fg); text-align: left;
}
.acc-head .a-emoji { flex: none; font-size: 15px; }
.acc-head .acc-arrow { margin-left: auto; color: var(--arrow); transition: transform 0.15s ease; }
.acc.open .acc-arrow { transform: rotate(90deg); }
.acc-body { display: none; padding: 0 2px 14px; font-size: 12.5px; line-height: 1.75; color: var(--fg-2); }
.acc.open .acc-body { display: block; }
.acc-body p + p { margin-top: 8px; }

/* ─── 用户卡（我的页） ─────────────────────────────────── */
.user-card {
  margin: 6px 14px 0; display: flex; align-items: center; gap: 13px;
  background: var(--grad-banner); color: var(--white);
  border-radius: var(--r-xl); padding: 17px 16px;
  box-shadow: 0 10px 22px var(--accent-shadow); position: relative; overflow: hidden;
}
.user-card .u-avatar {
  flex: none; width: 54px; height: 54px; border-radius: 50%;
  background: var(--white-18); border: 1px solid var(--white-30);
  display: grid; place-items: center; font-size: 27px;
}
.user-card .u-name { font-size: 16.5px; font-weight: 700; }
.user-card .u-sub { margin-top: 3px; font-size: 11px; color: var(--white-88); }
.user-card .u-deco { position: absolute; right: -12px; bottom: -22px; font-size: 78px; opacity: 0.14; pointer-events: none; }

.stat-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 12px 14px 0; }
.stat-card {
  display: flex; align-items: center; gap: 11px;
  padding: 13px 14px; text-align: left;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow-card);
}
.stat-card .s-emoji {
  flex: none; width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; font-size: 21px;
  box-shadow: inset 0 -3px 5px var(--icon-inset);
}
.stat-card .s-num { font-size: 19px; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-card .s-label { margin-top: 2px; font-size: 11px; color: var(--muted); }

/* ─── 详情页封面（礼包/课程，沿用礼券封面语言） ─────────── */
.detail-cover {
  margin: 6px 14px 0; border-radius: var(--r-xl); color: var(--white);
  padding: 18px 16px 14px; overflow: hidden; position: relative;
}
.detail-cover .cc-top { display: flex; align-items: center; gap: 13px; }
.detail-cover .cc-mark {
  flex: none; width: 54px; height: 54px; border-radius: 15px;
  background: var(--white-18); border: 1px solid var(--white-30);
  display: grid; place-items: center; font-size: 27px;
}
.detail-cover .cc-name { font-size: 18px; font-weight: 700; letter-spacing: 0.02em; }
.detail-cover .cc-sponsor { margin-top: 5px; font-size: 11.5px; color: var(--white-88); }
.detail-cover .cc-div { border-top: 1px dashed var(--white-35); margin: 14px 0 10px; }
.detail-cover .cc-meta { display: flex; gap: 22px; font-size: 12px; }
.detail-cover .cc-meta .m-label { font-size: 10px; color: var(--white-72); letter-spacing: 0.08em; }
.detail-cover .cc-meta .m-value { margin-top: 2px; font-weight: 700; }
.detail-cover .cc-deco { position: absolute; right: -14px; bottom: -18px; font-size: 84px; opacity: 0.14; pointer-events: none; }

/* ─── 引导/确认页主视觉 ────────────────────────────────── */
.guide-hero { text-align: center; padding: 30px 14px 4px; }
.guide-hero .g-mark {
  width: 64px; height: 64px; margin: 0 auto; border-radius: 20px;
  background: var(--grad-banner); color: var(--white);
  display: grid; place-items: center;
  box-shadow: 0 0 0 9px var(--accent-halo), 0 12px 24px var(--accent-shadow-lg);
}
.guide-hero .g-title { margin-top: 16px; font-size: 21px; font-weight: 700; letter-spacing: 0.03em; }
.guide-hero .g-sub { margin-top: 8px; font-size: 12.5px; line-height: 1.7; color: var(--fg-2); }

.actions-stack { display: flex; flex-direction: column; gap: 10px; padding: 4px 14px 8px; }

/* 热门通知行：正文不拆行，放不下时「示意」标签整体换行，避免孤字 */
.notice.hot .n-title .t { white-space: nowrap; }
.notice.hot .n-title { flex-wrap: wrap; }
