/* =============================================
   新美业积分系统 — 全新 UI 设计 v2
   设计方向：黑白灰绿·潮流会员·高对比界面
   ============================================= */

/* --- 字体 --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Noto+Serif+SC:wght@400;500;600;700&display=swap');

/* --- 设计令牌 --- */
:root {
  --c-bg: #F3F5F2;
  --c-surface: #FFFFFF;
  --c-primary: #050505;
  --c-accent: #8CFF3F;
  --c-accent-deep: #2FBA24;
  --c-accent-light: #DFFFD0;
  --c-ink: #050505;
  --c-muted: #565B56;
  --c-muted-light: #8B918A;
  --c-border: #DDE3DD;
  --c-danger: #D14343;
  --c-success: #3B8C5A;
  --c-overlay: rgba(28, 25, 23, 0.45);

  --font-display: 'Noto Serif SC', 'Songti SC', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'PingFang SC', sans-serif;

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-full: 9999px;

  --shadow-xs: 0 1px 2px rgba(28,25,23,0.04);
  --shadow-sm: 0 2px 8px rgba(28,25,23,0.06);
  --shadow-md: 0 4px 20px rgba(28,25,23,0.08);
  --shadow-lg: 0 8px 40px rgba(28,25,23,0.10);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 180ms;
  --dur-normal: 250ms;
}

/* --- 重置 --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
button, input { font: inherit; border: none; outline: none; background: none; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

html, body {
  font-family: var(--font-body);
  background: var(--c-bg);
  color: var(--c-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  font-size: 15px;
}

/* --- 排版 --- */
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.01em; }
h1 { font-size: 28px; line-height: 1.2; }
h2 { font-size: 20px; line-height: 1.3; }
.text-muted { color: var(--c-muted); font-size: 13px; }
.text-xs { font-size: 12px; color: var(--c-muted-light); }
.eyebrow { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--c-muted); }

/* --- 工具类 --- */
.row { display: flex; align-items: center; justify-content: space-between; }

/* --- 外壳 --- */
.shell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(145deg, rgba(5, 5, 5, 0.92), rgba(22, 24, 22, 0.78)),
    linear-gradient(160deg, #050505 0%, #1C211C 48%, #8CFF3F 100%);
  padding: 20px;
}

.side { display: none; }

.phone {
  width: 390px;
  max-width: 100vw;
  height: 844px;
  max-height: 100vh;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.46), rgba(255, 255, 255, 0) 220px),
    var(--c-bg);
  border-radius: var(--radius-xl);
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(28,25,23,0.06);
  display: flex;
  flex-direction: column;
}

.phone:has(#view-profile.active) {
  background: var(--c-bg);
}

.phone:has(#view-profile.active) .status-bar {
  background: var(--c-bg);
  color: var(--c-primary);
}

/* --- 状态栏 --- */
.status-bar {
  height: 44px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  color: var(--c-primary);
  flex-shrink: 0;
}

/* --- 视图 --- */
.view {
  display: none;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0 20px 92px;
  scroll-behavior: smooth;
}
.view.active { display: block; }
.view::-webkit-scrollbar { width: 0; }

.login-mode .view { padding-bottom: 20px; }
.login-mode .tabs { display: none; }

/* =============================================
   登录页
   ============================================= */
.login-hero {
  min-height: 330px;
  background:
    linear-gradient(90deg, rgba(5, 5, 5, 0.92) 0%, rgba(22, 24, 22, 0.70) 54%, rgba(140, 255, 63, 0.24) 100%),
    radial-gradient(circle at 78% 28%, rgba(140, 255, 63, 0.42), transparent 20%),
    linear-gradient(135deg, #8CFF3F 0%, #161816 48%, #050505 100%);
  border-radius: var(--radius-lg);
  padding: 118px 28px 74px;
  position: relative;
  overflow: hidden;
  margin-bottom: -120px;
  box-shadow: 0 24px 56px rgba(5, 5, 5, 0.18);
}
.login-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 5, 5, 0.72) 0 58%, transparent 58%);
  z-index: 0;
}
.login-hero::after {
  content: '';
  position: absolute;
  right: -28px;
  bottom: -18px;
  width: 208px;
  height: 294px;
  border-radius: 999px 999px 34px 34px;
  background:
    radial-gradient(circle at 55% 30%, #8CFF3F 0 18%, transparent 19%),
    linear-gradient(146deg, #050505 0 28%, #242824 29% 49%, #8CFF3F 50% 100%);
  opacity: 0.82;
  z-index: 0;
}
.login-hero p,
.login-hero h1,
.login-hero span { position: relative; z-index: 1; }
.login-hero h1 {
  font-family: var(--font-display);
  font-size: 52px;
  line-height: 1;
  font-weight: 700;
  color: #FFFFFF;
  margin: 12px 0 14px;
  letter-spacing: 0.04em;
}
.login-hero p {
  color: rgba(255,235,229,0.88);
  font-size: 14px;
  font-weight: 800;
}
.login-hero span {
  max-width: 270px;
  color: rgba(255,255,255,0.78);
  font-size: 14px;
  line-height: 1.5;
  margin-top: 0;
  display: block;
}

.login-card {
  background: var(--c-surface);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow-md);
  position: relative;
  z-index: 1;
}
.login-card .login-tip {
  font-size: 13px;
  color: var(--c-muted);
  margin-bottom: 16px;
  line-height: 1.6;
}
.login-card input {
  width: 100%;
  height: 52px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-md);
  padding: 0 18px;
  font-size: 16px;
  background: var(--c-bg);
  margin-bottom: 16px;
  transition: border-color var(--dur-fast) var(--ease-out);
  box-sizing: border-box;
}
.login-card input:focus { border-color: var(--c-accent); background: #FFF; }
.login-card p:last-child {
  font-size: 12px;
  color: var(--c-muted-light);
  text-align: center;
  margin-top: 12px;
}

/* --- 按钮 --- */
.btn-primary {
  width: 100%;
  height: 52px;
  background: var(--c-primary);
  color: #FFF;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-md);
  letter-spacing: 0.02em;
  transition: transform var(--dur-fast) var(--ease-out), opacity var(--dur-fast) var(--ease-out);
}
.btn-primary:active { transform: scale(0.97); opacity: 0.9; }
.btn-accent {
  width: 100%;
  height: 48px;
  background: #8CFF3F;
  color: #050505;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-md);
  letter-spacing: 0.02em;
  box-shadow: 0 10px 24px rgba(65,217,38,0.26);
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.btn-accent:active { transform: scale(0.97); box-shadow: 0 4px 12px rgba(65,217,38,0.22); }
.btn-text {
  font-size: 14px;
  font-weight: 500;
  color: var(--c-accent);
  padding: 4px 0;
}
.btn-sm {
  height: 36px;
  padding: 0 16px;
  background: var(--c-primary);
  color: #FFF;
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: transform var(--dur-fast) var(--ease-out);
}
.btn-sm:active { transform: scale(0.96); }

/* =============================================
   首页
   ============================================= */
.hero {
  min-height: 276px;
  background:
    url('./assets/generated/home-hero-cartoon.png') center / cover no-repeat,
    #050505;
  border-radius: var(--radius-lg);
  padding: 96px 28px 34px;
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  background-size: cover;
  background-position: center;
  box-shadow: 0 24px 52px rgba(5, 5, 5, 0.18);
}
.hero::before {
  content: none;
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 5, 5, 0.66) 0 58%, transparent 58%);
  z-index: 0;
}
.hero::after {
  content: none;
  position: absolute;
  right: -26px;
  bottom: -28px;
  width: 174px;
  height: 246px;
  border-radius: 999px 999px 30px 30px;
  background:
    radial-gradient(circle at 55% 30%, #8CFF3F 0 18%, transparent 19%),
    linear-gradient(146deg, #050505 0 28%, #242824 29% 49%, #8CFF3F 50% 100%);
  opacity: 0.8;
  z-index: 0;
}
.hero p,
.hero h1,
.hero-meta { display: none; }
.hero h1 {
  font-family: var(--font-display);
  font-size: 50px;
  line-height: 1;
  font-weight: 700;
  color: #FFF;
  letter-spacing: 0.06em;
}
.hero p { color: rgba(255,235,229,0.86); font-size: 14px; margin-top: 0; font-weight: 800; }
.hero-meta {
  color: rgba(255,255,255,0.78);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  margin-top: 20px;
  text-transform: uppercase;
}
.hero.has-image::before,
.hero.has-image::after {
  content: none;
}

.pay-panel {
  background: var(--c-surface);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid rgba(5, 5, 5, 0.08);
  box-shadow: 0 16px 34px rgba(5, 5, 5, 0.07);
}
.pay-panel .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.pay-panel h2 { font-size: 17px; }
.yuan {
  font-family: var(--font-display);
  font-size: 28px;
  color: var(--c-accent);
  font-weight: 500;
}
.amount-input {
  width: 100%;
  height: 56px;
  font-size: 24px;
  font-family: var(--font-display);
  font-weight: 600;
  text-align: center;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-md);
  background: var(--c-bg);
  color: var(--c-primary);
  margin-bottom: 16px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.amount-input:focus { border-color: var(--c-accent); background: #FFF; box-shadow: 0 0 0 4px rgba(140,255,63,0.14); }
.amount-input::placeholder { color: var(--c-muted-light); }

/* =============================================
   商品页
   ============================================= */
#view-orders {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0) 220px),
    var(--c-bg);
}

/* --- 商品双排 --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 4px;
}

.product-card {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(5, 5, 5, 0.06);
  border-radius: 20px;
  background: #FFFFFF;
  box-shadow: 0 14px 34px rgba(5, 5, 5, 0.07);
}

.product-hero-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.product-hero-img.custom {
  background: transparent;
}

.product-hero-img.coffee { background: linear-gradient(145deg, #FDFEFC 0%, #EAF7E4 48%, #C9F7AF 100%); }
.product-hero-img.drink { background: linear-gradient(145deg, #FFFFFF 0%, #EDF7EA 48%, #DFFFD0 100%); }
.product-hero-img.meal { background: linear-gradient(145deg, #FFFFFF 0%, #F1F5EF 46%, #BDF78D 100%); }
.product-hero-img.card { background: linear-gradient(145deg, #FFFFFF 0%, #F4F6F3 48%, #D7DED5 100%); }

.product-card-body {
  padding-top: 12px;
}

.product-card-body span {
  color: var(--c-muted-light);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.product-card-body h2 {
  margin-top: 5px;
  color: var(--c-ink);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: 0;
  cursor: pointer;
}

.product-card-body strong {
  display: block;
  margin-top: 8px;
  color: var(--c-accent-deep);
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 900;
}

.coupon-art {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
  z-index: 2;
  border-radius: inherit;
  box-shadow: none;
  clip-path: none;
  transform: none;
}
.coupon-copy {
  position: relative;
  z-index: 3;
  display: grid;
  gap: 8px;
}
.coupon-copy span {
  font-size: 11px;
  letter-spacing: 0.12em;
  color: #505750;
}
.coupon-copy strong {
  color: #111511;
  font-size: 16px;
  letter-spacing: 0;
  line-height: 1;
}
.coupon-mark {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(5,5,5,0.08);
  color: #303630;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  letter-spacing: 0;
  position: relative;
  z-index: 3;
}
.coupon-thumb {
  position: absolute;
  right: 14px;
  top: 50%;
  width: 48px !important;
  height: 48px !important;
  border-radius: 50%;
  transform: translateY(-50%);
  border: 2px solid rgba(255,255,255,0.55);
  box-shadow: 0 8px 18px rgba(23,18,22,0.16);
  z-index: 4;
}

.product-detail .product-img {
  min-height: 150px;
  margin: 0 0 18px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 16px;
  color: rgba(255, 255, 255, 0.78);
  position: relative;
  overflow: hidden;
}

.product-detail .product-img.custom {
  padding: 0;
  background: #261817;
}

.product-detail .product-img.coffee { background: linear-gradient(135deg, #F5F7F4 0%, #8CFF3F 48%, #161816 100%); }
.product-detail .product-img.drink { background: linear-gradient(135deg, #F3F5F2 0%, #B8FF82 50%, #2D332D 100%); }
.product-detail .product-img.meal { background: linear-gradient(135deg, #FFFFFF 0%, #8CFF3F 50%, #2FBA24 100%); }
.product-detail .product-img.card { background: linear-gradient(135deg, #E8ECE8 0%, #9AA19A 50%, #050505 100%); }

.product-detail .coupon-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-detail-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  margin-bottom: 14px;
}

.product-detail-row span {
  color: var(--c-muted);
  font-size: 14px;
}

.product-detail-row strong {
  color: var(--c-accent-deep);
  font-size: 18px;
  font-family: var(--font-display);
}

/* =============================================
   我的页面
   ============================================= */
#view-profile {
  background: var(--c-bg);
  padding-top: 0;
}

#view-profile .profile-title {
  color: var(--c-primary);
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 800;
  margin: 2px 0 24px;
}

.profile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0 18px;
}
.profile-header .avatar-group {
  display: flex;
  align-items: center;
  gap: 14px;
}
.avatar {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, #8CFF3F 0%, #8CFF3F 54%, #161816 55%, #050505 100%);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 900;
  color: #050505;
  font-family: var(--font-display);
  border: 2px solid rgba(255,255,255,0.18);
  box-shadow: 0 8px 22px rgba(140,255,63,0.18);
  cursor: pointer;
}
.avatar:active { transform: scale(0.96); }
.profile-header .name-row {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}
.profile-header h2 {
  color: var(--c-primary);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 800;
}
.member-badge {
  color: var(--c-primary);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  padding: 5px 9px;
  border-radius: var(--radius-full);
  background: rgba(5,5,5,0.06);
  border: 1px solid rgba(5,5,5,0.08);
}
.profile-header p { font-size: 12px; color: #6F766F; margin-top: 4px; }
/* --- 会员卡 --- */
.member-card {
  background:
    radial-gradient(circle at 90% 10%, rgba(140,255,63,0.34), transparent 30%),
    linear-gradient(135deg, #171917 0%, #111311 55%, #242824 100%);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-bottom: 14px;
  box-shadow: 0 20px 46px rgba(0, 0, 0, 0.24);
  border: 1px solid rgba(255,255,255,0.08);
}
.member-card .row { display: flex; align-items: center; justify-content: space-between; }
.member-card h2 {
  font-size: 17px;
  color: #FFF1C7;
  font-family: var(--font-body);
  font-weight: 800;
}
.member-card p {
  font-size: 13px;
  color: rgba(255,255,255,0.68);
  margin-top: 4px;
}
.member-points {
  display: block;
  margin-top: 8px;
  color: var(--c-accent);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 800;
}
.benefit-pill {
  min-width: 80px;
  height: 32px;
  padding: 0 14px;
  border-radius: var(--radius-full);
  background: var(--c-accent);
  color: #050505;
  font-size: 12px;
  font-weight: 700;
}

/* --- 面板 --- */
.panel {
  background: #FAFBF9;
  border-radius: var(--radius-md);
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 9px 24px rgba(0, 0, 0, 0.22);
  margin-bottom: 14px;
}
.panel .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.panel h2 { font-size: 16px; }

.order-overview {
  margin-bottom: 14px;
}

.order-overview .btn-text {
  color: #050505;
  font-weight: 700;
}

/* --- 订单状态网格 --- */
.order-status-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}
.order-status-grid > button {
  text-align: center;
  padding: 12px 4px 4px;
  border-radius: var(--radius-sm);
  background: transparent;
  transition: transform var(--dur-fast) var(--ease-out);
}
.order-status-grid > button:active { transform: scale(0.96); }
.order-status-grid .ico-status {
  color: #050505;
  font-size: 22px;
  margin-bottom: 6px;
  display: block;
  font-weight: 800;
}
.order-status-grid span {
  font-size: 12px;
  color: #323532;
  font-weight: 600;
}

/* --- 服务宫格 --- */
.service-panel {
  background: #FAFBF9;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-bottom: 14px;
  box-shadow: 0 9px 24px rgba(0, 0, 0, 0.22);
}
.service-panel h2 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 800;
}
.service-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  row-gap: 17px;
}
.service-grid > button {
  min-height: 50px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: #202320;
  font-size: 12px;
  font-weight: 650;
  text-align: center;
  transition: opacity var(--dur-fast);
}
.service-grid > button:active { opacity: 0.7; }
.service-icon {
  color: #111;
  font-size: 22px;
  line-height: 1;
  font-weight: 800;
}

/* --- 联系客服 --- */
.contact-card {
  width: 100%;
  color: inherit;
  text-align: left;
  background: var(--c-surface);
  border: 1px solid rgba(5, 5, 5, 0.08);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 7px 20px rgba(5, 5, 5, 0.04);
}
.contact-card > div {
  display: flex;
  align-items: center;
  gap: 12px;
}
.contact-card .contact-icon,
.contact-card > strong {
  color: #050505;
  font-size: 22px;
  line-height: 1;
}
.contact-card b {
  display: block;
  color: #171917;
  font-size: 14px;
}
.contact-card small {
  display: block;
  color: var(--c-muted-light);
  font-size: 12px;
  margin-top: 2px;
}

/* --- 最近订单 --- */
.mini-order {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--c-border);
}
.mini-order:last-child { border-bottom: none; }
.mini-order b { font-size: 14px; font-weight: 600; }
.mini-order span { font-size: 12px; color: var(--c-muted-light); }
.mini-order strong { color: var(--c-primary); font-family: var(--font-display); }

/* =============================================
   底部导航
   ============================================= */
.tabs {
  display: flex;
  margin: 0;
  border-top: 0;
  border-radius: 0;
  background: transparent;
  padding: 5px 10px;
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  box-shadow: none;
  flex-shrink: 0;
}
.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  font-size: 16px;
  color: #6F766F;
  font-weight: 600;
  padding: 2px 0 0;
  transition: color var(--dur-fast) var(--ease-out);
}
.tab::before {
  display: none;
}
.tab.active { color: #8CFF3F; font-weight: 700; }
.phone:has(#view-profile.active) .tab.active,
.phone:has(#view-orders.active) .tab.active,
.phone:has(#view-home.active) .tab.active {
  color: #8CFF3F;
}
.tab.active::before {
  display: none;
}

/* =============================================
   模态框
   ============================================= */
.modal {
  display: none;
  position: absolute;
  inset: 0;
  background: var(--c-overlay);
  z-index: 100;
  align-items: flex-end;
  justify-content: center;
}
.modal.show { display: flex; }
.modal-card {
  width: 100%;
  background: var(--c-surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  padding: 28px 24px 40px;
  box-shadow: 0 -8px 40px rgba(28,25,23,0.15);
}
.modal-close {
  float: right;
  font-size: 22px;
  color: var(--c-muted-light);
  width: 32px; height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
}
.modal-card h2 { font-size: 20px; margin-bottom: 16px; }
.modal-body { margin-top: 8px; }
.modal-body p { font-size: 14px; color: var(--c-muted); line-height: 1.6; margin-bottom: 12px; }

.code-box {
  background: var(--c-bg);
  border: 1.5px dashed var(--c-accent);
  border-radius: var(--radius-md);
  padding: 16px;
  text-align: center;
  font-family: monospace;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--c-primary);
  margin: 12px 0;
}

.wechat-pay-btn {
  width: 100%;
  height: 52px;
  background: #07C160;
  color: #FFF;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-md);
  margin-top: 8px;
}
.wechat-pay-btn:active { opacity: 0.9; transform: scale(0.98); }

.modal-btn {
  width: 100%;
  height: 48px;
  background: var(--c-primary);
  color: #FFF;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-md);
  margin-top: 8px;
}
.modal-btn:active { transform: scale(0.97); }

button:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid rgba(140, 255, 63, 0.75);
  outline-offset: 3px;
}

/* --- Toast --- */
.toast {
  position: absolute;
  top: 60px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: var(--c-primary);
  color: #FFF;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 24px;
  border-radius: var(--radius-full);
  opacity: 0;
  transition: all var(--dur-normal) var(--ease-out);
  pointer-events: none;
  z-index: 200;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* =============================================
   手机真实预览
   ============================================= */
@media (max-width: 520px) {
  html,
  body {
    width: 100%;
    min-height: 100dvh;
    background: var(--c-bg);
    overflow: hidden;
  }

  .shell {
    min-height: 100dvh;
    padding: 0;
    display: block;
    background: var(--c-bg);
  }

  .phone {
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    border-radius: 0;
    box-shadow: none;
  }

  .status-bar {
    display: none;
  }

  .view {
    padding: 18px 20px 20px;
  }

  .login-mode .view {
    padding-top: 0;
  }

  .hero {
    margin-top: 0;
  }

  .tabs {
    min-height: 76px;
    padding-top: 8px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));
  }

  .modal {
    position: fixed;
    inset: 0;
  }

  .modal-card {
    padding: 22px 20px max(24px, calc(18px + env(safe-area-inset-bottom)));
    border-radius: 22px 22px 0 0;
  }

  .modal-card h2 {
    font-size: 18px;
    margin-bottom: 12px;
  }

  .modal-body p {
    font-size: 13px;
    margin-bottom: 18px;
  }

  .wechat-pay-btn {
    height: 48px;
    border-radius: 16px;
    font-size: 15px;
    margin-top: 4px;
  }
}

/* --- 空态提示 --- */
.hint { font-size: 13px; color: var(--c-muted-light); text-align: center; padding: 20px 0; }
