/* 顾客端 H5 样式 */
.page-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(245, 241, 233, .94);
  backdrop-filter: blur(10px);
  padding: 16px 18px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(232, 226, 216, .8);
}
.page-header .back {
  width: 32px; height: 32px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%; background: #fff; font-size: 18px;
  box-shadow: 0 2px 8px rgba(30,77,59,.06);
}
.page-header h1 { font-size: 17px; margin: 0; font-weight: 700; letter-spacing: .5px; }
.page-header .spacer { flex: 1; }
.page-header .mini-logo { font-size: 12px; color: var(--muted); }

main { padding: 0 16px 92px; }

/* 首页 */
.hero {
  margin: 14px 0 12px;
  border-radius: 20px;
  padding: 26px 22px 24px;
  background:
    radial-gradient(circle at 85% 15%, rgba(200,164,106,.35), transparent 42%),
    linear-gradient(135deg, #1e4d3b 0%, #2d6a50 55%, #39785c 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "足";
  position: absolute;
  right: -6px; bottom: -32px;
  font-size: 132px;
  font-weight: 800;
  color: rgba(255,255,255,.07);
  line-height: 1;
}
.wx-user {
  display: flex; align-items: center; gap: 6px;
  max-width: 46%; padding: 3px 10px 3px 3px;
  background: rgba(30,77,59,.08); border: 1px solid rgba(30,77,59,.12);
  border-radius: 999px;
  font-size: 12px; color: var(--primary); font-weight: 600;
}
.wx-user img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; background: var(--primary-soft); flex: none; }
.wx-user span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hero-brand { font-size: 12px; letter-spacing: 3px; color: rgba(255,255,255,.75); }
.hero h2 { font-size: 25px; margin: 8px 0 6px; font-weight: 700; letter-spacing: 2px; }
.hero p { margin: 0; font-size: 13px; color: rgba(255,255,255,.82); }
.hero-divider { width: 34px; height: 2px; background: var(--accent); margin: 14px 0 0; border-radius: 2px; }

.notice-bar {
  display: flex; align-items: center; gap: 8px;
  background: var(--accent-soft);
  color: #8a6b3b;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 12px;
  margin-bottom: 18px;
}
.notice-bar .dot { width: 6px; height: 6px; background: var(--accent); border-radius: 50%; flex: none; }

.tabs {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px;
  margin-bottom: 14px; scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  white-space: nowrap; padding: 8px 15px; border-radius: 999px;
  background: #fff; color: var(--muted); font-size: 13px;
  border: 1px solid var(--line);
}
.tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.product-list { display: flex; flex-direction: column; gap: 14px; }
.product-card {
  background: #fff; border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
  display: flex; flex-direction: column;
}
.product-card .thumb {
  width: 100%; height: 132px; object-fit: cover; background: var(--primary-soft);
}
.product-card .body { padding: 14px 15px 15px; }
.product-card .row { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.product-card h3 { font-size: 16px; margin: 0; font-weight: 700; }
.product-card .duration { font-size: 12px; color: var(--muted); white-space: nowrap; }
.product-card .desc { font-size: 12.5px; color: var(--muted); margin: 8px 0 10px; line-height: 1.6; }
.product-card .tags { display: flex; gap: 6px; margin-bottom: 12px; flex-wrap: wrap; }
.product-card .tag {
  font-size: 11px; color: var(--primary-2); background: var(--primary-soft);
  padding: 3px 9px; border-radius: 999px;
}
.product-card .bottom { display: flex; align-items: center; justify-content: space-between; }
.product-card .price { font-size: 22px; }
.product-card .order-btn {
  background: var(--primary); color: #fff; border-radius: 10px;
  padding: 9px 18px; font-size: 13px; font-weight: 600;
}

/* 下单页 */
.form-card { padding: 18px; margin-bottom: 14px; }
.summary-product { display: flex; gap: 12px; align-items: center; }
.summary-product img { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; }
.summary-product h3 { margin: 0 0 4px; font-size: 16px; }
.summary-product p { margin: 0; font-size: 12px; color: var(--muted); }
.field { margin-bottom: 16px; }
.field:last-child { margin-bottom: 0; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.field .hint { font-size: 11px; color: var(--muted); font-weight: 400; margin-left: 6px; }
.field input, .field textarea {
  width: 100%; border: 1px solid var(--line); background: #fcfbf8;
  border-radius: 10px; padding: 12px 13px; font-size: 15px; outline: none;
  transition: border-color .2s;
}
.field input:focus, .field textarea:focus { border-color: var(--primary-2); background: #fff; }
.field textarea { resize: none; min-height: 74px; }
.wx-nickname-btn {
  margin-top: 8px; font-size: 12px; color: var(--primary-2);
  background: var(--primary-soft); border-radius: 8px; padding: 8px 12px;
}
.check-row { display: flex; gap: 8px; align-items: flex-start; font-size: 12px; color: var(--muted); }
.check-row input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--primary); }

.bottom-bar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; z-index: 30;
  background: #fff; border-top: 1px solid var(--line);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 12px;
}
.bottom-bar .total { flex: 1; font-size: 12px; color: var(--muted); }
.bottom-bar .total b { display: block; font-size: 21px; color: #b06a35; }
.bottom-bar .btn { min-width: 150px; }

/* 支付页 */
.pay-hero { text-align: center; padding: 32px 10px 20px; }
.pay-hero .icon {
  width: 62px; height: 62px; margin: 0 auto 14px; border-radius: 50%;
  background: var(--primary-soft); color: var(--primary);
  display: flex; align-items: center; justify-content: center; font-size: 28px;
}
.pay-hero h2 { font-size: 19px; margin: 0 0 4px; }
.pay-hero p { margin: 0; color: var(--muted); font-size: 13px; }
.pay-amount { font-size: 40px; font-weight: 700; color: var(--text); margin: 10px 0 0; }
.pay-amount small { font-size: 20px; }
.pay-method { display: flex; align-items: center; gap: 12px; padding: 16px 18px; }
.pay-method .wx-icon {
  width: 38px; height: 38px; border-radius: 10px; background: #07c160;
  color: #fff; display: flex; align-items: center; justify-content: center; font-size: 21px;
}
.pay-method .grow { flex: 1; }
.pay-method .grow b { display: block; font-size: 14px; }
.pay-method .grow span { font-size: 11px; color: var(--muted); }
.demo-tip {
  background: var(--accent-soft); color: #8a6b3b; font-size: 12px;
  padding: 11px 13px; border-radius: 10px; margin: 0 0 16px; line-height: 1.6;
}

/* 成功页 */
.success-hero { text-align: center; padding: 34px 0 18px; }
.success-check {
  width: 66px; height: 66px; border-radius: 50%; margin: 0 auto 14px;
  background: var(--success); color: #fff; font-size: 34px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 22px rgba(47,125,91,.25);
}
.success-hero h2 { margin: 0 0 4px; font-size: 20px; }
.success-hero p { margin: 0; font-size: 13px; color: var(--muted); }

.qr-card { padding: 20px; text-align: center; margin-bottom: 14px; position: relative; }
.qr-card h3 { font-size: 15px; margin: 0 0 4px; }
.qr-card .sub { font-size: 12px; color: var(--muted); margin-bottom: 16px; }
.qr-box {
  width: 210px; height: 210px; margin: 0 auto 14px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 8px; display: flex; align-items: center; justify-content: center;
}
.qr-box img { width: 100%; height: 100%; }
.qr-code-no { font-size: 12px; color: var(--muted); letter-spacing: .5px; }
.qr-stamp {
  position: absolute; inset: 0; border-radius: var(--radius);
  background: rgba(255,255,255,.82); display: flex; align-items: center; justify-content: center;
}
.qr-stamp span {
  border: 3px solid var(--success); color: var(--success); font-size: 22px; font-weight: 800;
  padding: 8px 18px; border-radius: 8px; transform: rotate(-12deg);
}

.info-list { padding: 4px 18px; }
.info-row {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 13px;
}
.info-row:last-child { border-bottom: 0; }
.info-row .k { color: var(--muted); }
.info-row .v { text-align: right; font-weight: 500; word-break: break-all; }
.status-pill {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 600;
}
.status-paid { background: #e6f4ec; color: var(--success); }
.status-pending { background: #fff3e2; color: #b7791f; }
.status-redeemed { background: #eef0ef; color: #67736d; }
.status-refunding { background: #fdeee9; color: var(--danger); }
.status-refunded { background: #f0f0ef; color: #7a7f7c; }
.status-aftersale { background: #fff2e0; color: #b06a35; }

.request-box {
  background: #fcfbf8; border: 1px solid var(--line);
  border-radius: 12px; padding: 14px; margin-bottom: 18px;
  font-size: 13px; line-height: 1.8;
}
.request-box .row { display: flex; justify-content: space-between; }
.request-box .row .k { color: var(--muted); }
.sheet .field { text-align: left; margin-bottom: 16px; }
.sheet .field label { font-size: 13px; font-weight: 600; display: block; margin-bottom: 8px; }
.sheet .field select, .sheet .field textarea {
  width: 100%; border: 1px solid var(--line); background: #fcfbf8;
  border-radius: 10px; padding: 12px 13px; font-size: 15px; outline: none;
  resize: none; min-height: 76px;
}
.sheet .field select { min-height: auto; appearance: auto; }
.sheet .field select:focus, .sheet .field textarea:focus { border-color: var(--primary-2); background: #fff; }
.sheet .sheet-note { font-size: 12px; color: var(--muted); text-align: left; margin-bottom: 16px; line-height: 1.7; }
.star-picker { display: flex; justify-content: center; gap: 8px; }
.star-btn {
  border: 0; background: transparent; cursor: pointer;
  font-size: 36px; line-height: 1; color: #d5dcd6; padding: 2px 4px;
  transition: transform .12s ease, color .12s ease;
}
.star-btn.active { color: #e8a33d; transform: scale(1.08); }

.tip-line {
  font-size: 12px; color: #8a6b3b; background: var(--accent-soft);
  padding: 12px 14px; border-radius: 10px; line-height: 1.7; margin: 14px 0;
}

/* 我的订单 */
.order-list { display: flex; flex-direction: column; gap: 12px; }
.order-item { padding: 15px; }
.order-item .top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.order-item .top .no { font-size: 11px; color: var(--muted); }
.order-item .main { display: flex; gap: 12px; align-items: center; }
.order-item .main img { width: 62px; height: 62px; border-radius: 10px; object-fit: cover; }
.order-item .main .grow { flex: 1; min-width: 0; }
.order-item .main h3 { margin: 0 0 4px; font-size: 15px; }
.order-item .main p { margin: 0; font-size: 11px; color: var(--muted); }
.order-item .foot {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line);
}
.order-item .foot .price { font-size: 17px; }
.order-item .foot .btn { padding: 8px 14px; font-size: 12px; }
.empty { text-align: center; padding: 70px 20px; color: var(--muted); }
.empty .e-icon { font-size: 44px; margin-bottom: 12px; opacity: .5; }
.empty p { margin: 0 0 18px; font-size: 13px; }

/* 底部导航 */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; z-index: 30;
  background: #fff; border-top: 1px solid var(--line);
  display: flex; padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
  box-shadow: 0 -4px 20px rgba(30,77,59,.05);
}
.tabbar button { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; color: var(--muted); }
.tabbar button.active { color: var(--primary); font-weight: 700; }
.tabbar .ti { font-size: 20px; line-height: 1.2; }

/* 支付弹层 */
.sheet-mask {
  position: fixed; inset: 0; background: rgba(20,32,27,.45); z-index: 100;
  display: flex; align-items: flex-end; justify-content: center;
}
.sheet {
  width: 100%; max-width: 480px; background: #fff;
  border-radius: 20px 20px 0 0; padding: 24px 20px calc(24px + env(safe-area-inset-bottom));
  animation: slideUp .25s ease;
}
@keyframes slideUp { from { transform: translateY(30px); opacity: .5; } to { transform: translateY(0); opacity: 1; } }
.sheet h3 { text-align: center; margin: 0 0 6px; font-size: 17px; }
.sheet .sheet-amount { text-align: center; font-size: 30px; font-weight: 700; margin-bottom: 20px; }
.sheet .sheet-amount small { font-size: 17px; }

/* 下单页：右下角悬浮返回首页按钮（单手可点，避开底部支付栏） */
.back-hint {
  position: fixed;
  right: 14px;
  bottom: calc(84px + env(safe-area-inset-bottom));
  z-index: 28;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  width: 64px; padding: 8px 4px 9px; text-align: center;
  color: #fff;
  background: linear-gradient(135deg, #1e4d3b, #2d6b52);
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 36px;
  box-shadow: 0 8px 22px rgba(30,77,59,.32);
  animation: backHintIn .3s ease both;
}
@keyframes backHintIn { from { transform: translateY(14px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.back-hint-icon {
  width: 44px; height: 44px; flex: none; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.16); color: #fff;
}
.back-hint-text { display: block; font-size: 11px; line-height: 1.2; color: #fff; }
.back-hint:active { transform: scale(.94); }

/* 会员中心 */
.member-card {
  position: relative; overflow: hidden;
  margin-top: 16px; padding: 20px 18px 16px; border-radius: 20px;
  color: #fff;
  background: linear-gradient(135deg, #1e4d3b 0%, #2d6b52 58%, #39785c 100%);
  box-shadow: 0 10px 26px rgba(30,77,59,.22);
}
.member-shine {
  position: absolute; top: -60px; right: -40px;
  width: 190px; height: 190px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.16), rgba(255,255,255,0) 70%);
  pointer-events: none;
}
.member-top { position: relative; display: flex; align-items: center; gap: 12px; }
.member-avatar-box {
  flex: none; padding: 3px; border-radius: 50%;
  background: rgba(255,255,255,.32); box-shadow: 0 3px 10px rgba(0,0,0,.12);
}
.member-avatar {
  display: block; width: 56px; height: 56px; border-radius: 50%; object-fit: cover;
  background: #e8f0ea;
}
.member-info { flex: 1; min-width: 0; }
.member-name-row { display: flex; align-items: center; gap: 7px; min-width: 0; }
.member-name { font-size: 17px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.member-tag {
  flex: none; font-size: 10px; padding: 2px 7px; border-radius: 999px;
  background: rgba(255,255,255,.2); color: #fff6db; border: 1px solid rgba(255,240,200,.35);
}
.member-id { font-size: 11px; color: rgba(255,255,255,.78); margin-top: 5px; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.member-id span { font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .3px; }
.member-copy {
  flex: none; padding: 1px 7px; font-size: 10px; border-radius: 999px;
  color: #fff; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.28);
}
.member-balance { text-align: right; flex: none; }
.member-balance span { display: block; font-size: 11px; color: rgba(255,255,255,.75); }
.member-balance b { display: block; font-size: 21px; margin-top: 4px; letter-spacing: .3px; }
.member-stats {
  position: relative; display: flex; margin-top: 16px; padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.18);
}
.member-stats > div { flex: 1; text-align: center; border-right: 1px solid rgba(255,255,255,.14); }
.member-stats > div:last-child { border-right: 0; }
.member-stats b { display: block; font-size: 16px; font-weight: 700; }
.member-stats span { display: block; font-size: 10px; color: rgba(255,255,255,.72); margin-top: 3px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin: 18px 0 10px; }
.section-head .section-title { margin: 0; }
.section-meta { font-size: 11px; color: var(--muted); }
.section-meta b { color: var(--primary); }

/* 会员中心：订单状态九宫格 */
.status-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  margin-bottom: 16px;
}
.status-grid .status-cell {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 7px; padding: 15px 4px 13px; border-radius: 16px;
  background: #fff; border: 1px solid var(--line); color: var(--muted);
  font-size: 12px; white-space: nowrap; box-shadow: var(--shadow);
  transition: transform .12s ease, border-color .2s, background .2s;
}
.status-grid .status-cell .sg-ico {
  width: 38px; height: 38px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--primary-soft); color: var(--primary-2);
  font-size: 20px; line-height: 1;
}
.status-grid .status-cell.active {
  background: linear-gradient(135deg, #1e4d3b, #2d6b52);
  border-color: transparent; color: #fff; font-weight: 700;
  box-shadow: 0 8px 18px rgba(30,77,59,.24);
}
.status-grid .status-cell.active .sg-ico { background: rgba(255,255,255,.18); color: #fff; }
.status-grid .status-cell:active { transform: scale(.96); }
