/* =============================================================
   星野陪玩 · H5 移动端设计层
   - 仅在 <= 960px 生效，PC 布局完全不受影响
   - 设计语言：浅灰底 + 白色描边卡 + 单一靛蓝主色 + 横滑模块
   ============================================================= */

/* PC 端隐藏所有移动专属元素 */
.m-topbar,
.m-greet,
.m-quick,
.m-auth-brand,
.m-modes,
.m-sec-tip,
.m-back { display: none; }

@media (max-width: 960px) {

  :root {
    --h5-bg: #f4f4f6;
    --h5-card: #ffffff;
    --h5-line: #ececf0;
    --h5-ink: #18181b;
    --h5-muted: #8b8b94;
    --h5-brand: #4f46e5;
    --h5-r: 18px;
    --header-h: 56px;
  }

  html, body { background: var(--h5-bg); overflow-x: clip; }
  body { font-size: 14px; color: var(--h5-ink); }
  .container { padding: 0 16px; }
  .main { padding-bottom: calc(92px + env(safe-area-inset-bottom)); min-height: 70vh; }
  .site-footer { display: none !important; }

  /* ---------------------------------------------------- 顶部栏 */
  .site-header {
    background: rgba(244, 244, 246, .9);
    backdrop-filter: saturate(180%) blur(18px);
    border-bottom: none;
    padding-top: env(safe-area-inset-top);
  }
  .site-header .header-inner { display: none !important; }

  .m-topbar {
    display: flex; align-items: center; gap: 9px;
    height: var(--header-h); padding: 0 16px;
  }
  .m-brand { display: flex; align-items: center; gap: 7px; flex: none; max-width: 40%; }
  .m-logo {
    width: 30px; height: 30px; border-radius: 9px; flex: none; overflow: hidden;
    background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff;
    display: grid; place-items: center; font-size: 15px; font-weight: 800;
  }
  .m-logo img { width: 100%; height: 100%; object-fit: cover; }
  .m-brand b {
    font-size: 15.5px; font-weight: 800; letter-spacing: -.3px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .m-search {
    flex: 1; min-width: 0; height: 36px; border-radius: 999px;
    background: #fff; border: 1px solid var(--h5-line);
    display: flex; align-items: center; gap: 6px; padding: 0 12px;
    color: #9a9aa3; font-size: 12.5px;
  }
  .m-search svg { width: 15px; height: 15px; flex: none; opacity: .65; }
  .m-search span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .m-cart {
    width: 36px; height: 36px; border-radius: 50%; flex: none; position: relative;
    background: #fff; border: 1px solid var(--h5-line);
    display: grid; place-items: center; font-size: 16px;
  }
  .m-cart .badge-dot { top: -4px; right: -4px; }

  /* ---------------------------------------------------- 底部 Tab */
  .mobile-tabbar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
    height: calc(58px + env(safe-area-inset-bottom));
    padding: 0 6px env(safe-area-inset-bottom);
    background: rgba(255, 255, 255, .94);
    backdrop-filter: blur(20px) saturate(180%);
    border-top: 1px solid rgba(24, 24, 27, .06);
  }
  .mobile-tabbar a {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px; color: #a1a1aa; font-size: 10.5px; font-weight: 500; position: relative;
  }
  .mobile-tabbar a .ico {
    width: 22px; height: 22px; display: grid; place-items: center; font-size: 0;
  }
  .mobile-tabbar svg {
    width: 22px; height: 22px; stroke: currentColor; fill: none;
    stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  }
  .mobile-tabbar a.active { color: var(--h5-brand); font-weight: 700; }
  .mobile-tabbar a.center .ico {
    width: 46px; height: 46px; border-radius: 50%; color: #fff;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    transform: translateY(-13px); border: 3px solid #f4f4f6;
    box-shadow: 0 8px 18px rgba(79, 70, 229, .3);
  }
  .mobile-tabbar a.center svg { width: 22px; height: 22px; }
  .mobile-tabbar a.center .lb { transform: translateY(-8px); }

  /* ---------------------------------------------------- 首页 · 问候 */
  .m-greet {
    display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
    margin: 6px 0 14px;
  }
  .m-greet h1 { font-size: 21px; font-weight: 800; letter-spacing: -.6px; }
  .m-greet p { color: var(--h5-muted); font-size: 12px; margin-top: 3px; }
  .m-online {
    display: inline-flex; align-items: center; gap: 5px; flex: none;
    font-size: 10.5px; color: #15803d; background: #e9f9ef;
    border-radius: 999px; padding: 5px 9px; white-space: nowrap;
  }
  .m-online i {
    width: 5px; height: 5px; border-radius: 50%; background: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, .16);
  }

  /* ---------------------------------------------------- 首页 · 快捷入口 */
  .m-quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 16px; }
  .m-quick a {
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 12px 4px 10px; background: #fff; border: 1px solid var(--h5-line);
    border-radius: 16px; color: var(--h5-ink);
  }
  .m-quick a:active { background: #fafafa; }
  .m-quick .qi {
    width: 34px; height: 34px; border-radius: 11px;
    display: grid; place-items: center; font-size: 17px; background: #f4f4f6;
  }
  .m-quick b { font-size: 11.5px; font-weight: 600; color: #3f3f46; }

  /* ---------------------------------------------------- 首屏轮播 */
  .hero { margin-top: 0; }
  .hero-slider {
    min-height: 0; aspect-ratio: 16 / 9.6; border-radius: 20px; box-shadow: none;
  }
  .hero-slide { align-items: flex-end; height: 100%; }
  .hero-slide.active { height: 100%; }
  .hero-slide::after {
    background: linear-gradient(180deg, rgba(10, 8, 30, .04) 0%, rgba(10, 8, 30, .28) 48%, rgba(10, 8, 30, .8) 100%);
  }
  .hero-copy {
    position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
    padding: 0 18px 16px; max-width: 100%;
  }
  .hero-copy h1 { font-size: 19px; line-height: 1.3; letter-spacing: -.4px; }
  .hero-copy p {
    margin-top: 5px; font-size: 11.5px; line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .hero-copy .btn {
    margin-top: 11px; height: 32px; padding: 0 13px; font-size: 12px; border-radius: 9px;
    box-shadow: none;
  }
  .hero-dots { left: auto; right: 16px; bottom: 16px; gap: 5px; }
  .hero-dots i { width: 5px; height: 5px; }
  .hero-dots i.on { width: 14px; }

  .notice-bar {
    margin-top: 12px; padding: 10px 13px; border-radius: 13px;
    font-size: 12px; border: 1px solid var(--h5-line); box-shadow: none;
    white-space: nowrap; overflow: hidden;
  }
  .notice-bar > span {
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1;
  }

  /* ---------------------------------------------------- 区块标题 */
  .section { margin-top: 22px; }
  .section-head { margin-bottom: 11px; align-items: center; }
  .section-head h2 { font-size: 17px; font-weight: 800; letter-spacing: -.35px; }
  .section-head .sub { font-size: 11.5px; margin-top: 2px; }
  .link-more { font-size: 12px; font-weight: 600; }

  /* 页面标题统一收敛 */
  .m-page-head { margin-top: 12px !important; }
  .m-page-head h1 { font-size: 21px !important; letter-spacing: -.5px !important; }
  .m-page-head p { font-size: 11.5px !important; margin-top: 3px !important; color: var(--h5-muted) !important; }
  .container > div > h1[style] { font-size: 21px !important; letter-spacing: -.5px !important; }
  .container > div > p[style] { font-size: 11.5px !important; margin-top: 3px !important; }
  .container > div > h1[style] + p[style] { color: var(--h5-muted) !important; }

  /* 列表页排序条：横向滑动不换行 */
  .sort-tabs {
    display: flex !important; gap: 7px !important; overflow-x: auto;
    width: 100%; padding: 3px 0 1px; -webkit-overflow-scrolling: touch;
  }
  .sort-tabs::-webkit-scrollbar { display: none; }
  .sort-tabs .tab { flex: none; padding: 6px 13px; font-size: 12px; }

  /* ---------------------------------------------------- 游戏横滑 */
  .game-entry {
    display: flex; gap: 9px; overflow-x: auto; padding: 2px 0 4px;
    scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
    grid-template-columns: none;
  }
  .game-entry::-webkit-scrollbar { display: none; }
  .game-entry a {
    flex: 0 0 74px; padding: 9px 5px 8px; border-radius: 16px; min-width: 0;
    background: #fff; border: 1px solid var(--h5-line); box-shadow: none;
    text-align: center; scroll-snap-align: start;
  }
  .game-entry a:hover { transform: none; box-shadow: none; }
  .game-entry img { width: 44px; height: 44px; border-radius: 14px; margin: 0 auto; }
  .game-entry b {
    display: block; margin-top: 6px; font-size: 11.5px; font-weight: 600;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .game-entry span { display: none; }

  /* ---------------------------------------------------- 陪玩卡片横滑（首页） */
  .section .svc-grid {
    display: flex; gap: 11px; overflow-x: auto; padding: 2px 0 6px;
    grid-template-columns: none; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  }
  .section .svc-grid::-webkit-scrollbar { display: none; }
  .section .svc-card {
    flex: 0 0 72%; max-width: 280px; border-radius: 18px;
    border: 1px solid var(--h5-line); box-shadow: none; scroll-snap-align: start;
  }
  .section .svc-card:first-child { scroll-margin-left: 16px; }
  .svc-card:hover { transform: none; box-shadow: none; }
  .svc-cover { aspect-ratio: 4 / 3; }
  .svc-play { right: 8px; bottom: 8px; font-size: 10px; padding: 2px 7px; border-radius: 6px; }
  .svc-body { padding: 10px 12px 12px; gap: 6px; }
  .svc-title { font-size: 14px; line-height: 1.4; }
  .svc-meta { font-size: 11px; gap: 6px; }
  .svc-price-row { margin-top: 2px; }

  /* ---------------------------------------------------- 列表页卡片 */
  .svc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
  .svc-card {
    border-radius: 16px; border: 1px solid var(--h5-line); box-shadow: none;
  }
  .svc-grid .svc-body { padding: 9px 10px 11px; gap: 5px; }
  .svc-grid .svc-title { font-size: 13px; -webkit-line-clamp: 2; }
  .svc-grid .svc-meta { font-size: 10.5px; }
  .svc-grid .svc-price-row .sales { display: none; }

  /* 平台保障：移动端保持三列小卡（不横滑） */
  .section .m-why {
    display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important; overflow: visible; padding: 0;
  }
  .section .m-why > .card {
    padding: 13px 10px 12px !important; border-radius: 16px;
    border: 1px solid var(--h5-line); box-shadow: none;
  }
  .section .m-why > .card > div:first-child { font-size: 20px !important; }
  .section .m-why h3 { font-size: 12.5px !important; margin-top: 7px !important; line-height: 1.35; }
  .section .m-why p {
    font-size: 10.5px !important; line-height: 1.5 !important; margin-top: 4px !important;
    display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
  }

  /* ---------------------------------------------------- 价格 */
  .price {
    color: var(--h5-ink); font-size: 17px; font-weight: 800;
    font-variant-numeric: tabular-nums; letter-spacing: -.4px;
  }
  .price .unit { font-size: 10.5px; color: #9a9aa3; font-weight: 500; margin-left: 1px; }
  .sales { font-size: 10.5px; color: #9a9aa3; }
  .tag { font-size: 10px; padding: 2px 7px; border-radius: 6px; }
  .tag.game { font-size: 10px; }

  /* ---------------------------------------------------- 商城 */
  .mall-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; margin-top: 14px; }
  .prod-card {
    position: relative; border-radius: 16px; border: 1px solid var(--h5-line); box-shadow: none;
  }
  .prod-card:hover { transform: none; box-shadow: none; }
  .prod-cover { aspect-ratio: 1 / 1; }
  .prod-body { padding: 9px 10px 11px; }
  .prod-name { font-size: 13px; font-weight: 600; }
  .prod-sub { font-size: 10.5px; margin-top: 3px; }
  .prod-price { margin-top: 7px; }
  .prod-price .old { font-size: 10.5px; }
  .prod-mode {
    position: absolute; top: 8px; left: 8px; z-index: 2; margin: 0;
    padding: 3px 7px; border-radius: 999px; font-size: 10px; font-weight: 600;
    color: #4f46e5; background: rgba(255, 255, 255, .94);
    backdrop-filter: blur(6px); max-width: calc(100% - 16px);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }

  /* 商城 · 玩法卡（移动端主结构） */
  .m-modes {
    display: flex; gap: 9px; overflow-x: auto; padding: 2px 0 4px; margin-top: 14px;
    -webkit-overflow-scrolling: touch;
  }
  .m-modes::-webkit-scrollbar { display: none; }
  .m-mode {
    flex: 0 0 auto; display: flex; align-items: center; gap: 9px;
    padding: 8px 13px 8px 8px; border-radius: 15px; text-align: left;
    background: #fff; border: 1px solid var(--h5-line); color: var(--h5-ink);
  }
  .m-mode .mk {
    width: 34px; height: 34px; border-radius: 11px; flex: none;
    background: #f4f4f6; display: grid; place-items: center;
    font-size: 14px; font-weight: 700; color: #52525b;
  }
  .m-mode .mt b {
    display: block; font-size: 12.5px; font-weight: 600; line-height: 1.25;
    white-space: nowrap;
  }
  .m-mode .mt span { display: block; font-size: 10px; color: #9a9aa3; margin-top: 3px; }
  .m-mode.on { background: #eef2ff; border-color: #c7d2fe; }
  .m-mode.on .mk { background: #fff; color: #4f46e5; }
  .m-mode.on .mt b { color: #4f46e5; }
  .m-mode.on .mt span { color: #7c83a8; }

  /* ---------------------------------------------------- 详情/表单页：隐藏 Tab，保留返回 */
  .m-back {
    display: none; width: 36px; height: 36px; padding: 0; flex: none;
    border-radius: 50%; border: 1px solid var(--h5-line); background: #fff;
    place-items: center; color: #3f3f46;
  }
  .m-back svg { width: 19px; height: 19px; }
  html.no-tabbar .m-back { display: grid; }
  html.no-tabbar .m-brand { display: none; }
  html.no-tabbar .mobile-tabbar { display: none; }
  html.no-tabbar .main { padding-bottom: calc(104px + env(safe-area-inset-bottom)); }
  html.no-tabbar .sticky-buy {
    bottom: 0; padding-bottom: calc(10px + env(safe-area-inset-bottom));
  }

  /* 登录 / 改密：只保留返回，去掉搜索与购物车 */
  html.auth-page .m-search,
  html.auth-page .m-cart { display: none; }
  html.auth-page .m-topbar { justify-content: flex-start; }

  /* ---------------------------------------------------- 详情页 */
  .detail-layout { display: flex; flex-direction: column; margin-top: 0; }
  .detail-main { display: contents; }
  .detail-layout .gallery { order: 1; }
  .detail-layout .detail-side { order: 2; }
  .detail-main > .panel { order: 3; }
  .gallery {
    border-radius: 0; margin: 0 -16px; box-shadow: none; background: transparent;
  }
  .gallery-main { aspect-ratio: 4 / 3; }
  .gallery-thumbs { padding: 10px 16px; gap: 8px; background: #fff; }
  .gallery-thumbs img { width: 52px; height: 52px; border-radius: 9px; }
  .video-flag { left: 12px; top: 12px; font-size: 10.5px; padding: 3px 9px; }

  .info-panel {
    padding: 16px; border-radius: 18px; margin-top: 12px;
    border: 1px solid var(--h5-line); box-shadow: none;
  }
  .info-panel h1 { font-size: 19px; letter-spacing: -.3px; }
  .info-sub { font-size: 12.5px; margin-top: 5px; }
  .price-block {
    margin-top: 12px; padding: 12px 13px; border-radius: 13px;
    background: #f6f6ff; border: 1px solid #ebebff;
  }
  .price-block .price { font-size: 26px; color: #4f46e5; }
  .info-rows { margin-top: 14px; gap: 8px; font-size: 12.5px; }
  .info-rows .k { width: 62px; color: #9a9aa3; font-size: 12px; }
  .player-card { margin-top: 14px; padding: 11px; border-radius: 13px; background: #fafafa; }
  .player-card img { width: 42px; height: 42px; }

  .booking-form { margin-top: 16px; gap: 12px; }
  .field { gap: 5px; }
  .field > label { font-size: 12px; color: #8b8b94; }
  .input, .textarea, .select {
    height: 46px; border-radius: 12px; border-color: var(--h5-line);
    background: #fafafa; font-size: 14px; padding: 0 13px;
  }
  .textarea { height: auto; min-height: 74px; padding: 11px 13px; }
  .input:focus, .textarea:focus, .select:focus { background: #fff; box-shadow: 0 0 0 3px rgba(79, 70, 229, .1); }
  .stepper { border-radius: 11px; border-color: var(--h5-line); }
  .stepper button { width: 40px; height: 40px; background: #fafafa; }
  .stepper input { height: 40px; background: #fff; }
  .seg { gap: 7px; }
  .seg button { padding: 8px 14px; border-radius: 10px; font-size: 12.5px; }
  .game-fields { background: #fafafa; border-color: var(--h5-line); border-radius: 14px; padding: 12px; }
  .panel {
    padding: 16px; border-radius: 18px; margin-top: 12px;
    border: 1px solid var(--h5-line); box-shadow: none;
  }
  .panel + .panel { margin-top: 12px; }
  .panel-head { margin-bottom: 12px; }
  .panel-head h3 { font-size: 15px; }
  .rich { font-size: 13.5px; line-height: 1.8; }
  .rich img { border-radius: 12px; }

  .sticky-buy {
    bottom: calc(58px + env(safe-area-inset-bottom));
    padding: 9px 16px calc(9px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(24, 24, 27, .06);
    background: rgba(255, 255, 255, .97);
    backdrop-filter: blur(16px);
  }
  .sticky-buy .price { font-size: 20px; color: #4f46e5; }
  .sticky-buy .btn { height: 44px; border-radius: 13px; font-size: 14.5px; }

  /* ---------------------------------------------------- 订单 */
  .tabs {
    position: sticky; top: calc(var(--header-h) + env(safe-area-inset-top)); z-index: 30;
    background: var(--h5-bg); margin: 0 -16px; padding: 8px 16px;
    gap: 7px; border-bottom: none;
  }
  .tabs::-webkit-scrollbar { display: none; }
  .tab {
    padding: 7px 14px; font-size: 12.5px; border-radius: 999px;
    background: #fff; border: 1px solid transparent; color: #52525b;
  }
  .tab.on { background: #fff; border-color: #a5b4fc; color: #4f46e5; font-weight: 600; }
  .order-card {
    border-radius: 18px; border: 1px solid var(--h5-line);
    box-shadow: none; padding: 14px; margin-bottom: 11px;
  }
  .order-head { padding-bottom: 9px; border-bottom: none; gap: 8px; flex-wrap: nowrap; }
  .order-no {
    font-size: 10.5px; color: #9a9aa3; flex: 1; min-width: 0;
    display: flex; flex-direction: column; gap: 2px; line-height: 1.35;
  }
  .order-no span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .order-no span:first-child { color: #71717a; font-size: 10px; }
  .order-no i { display: none; }
  .order-head .status { flex: none; }
  .order-body { padding: 10px 0; gap: 11px; align-items: flex-start; }
  .order-body img { width: 72px; height: 72px; border-radius: 12px; }
  .order-body > div:last-child { flex: none; min-width: 58px; }
  .order-body .price { font-size: 15px; white-space: nowrap; }
  .order-title {
    font-size: 13.5px; line-height: 1.4;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  }
  .order-sub {
    font-size: 11.5px; margin-top: 4px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .order-foot { gap: 8px; padding-top: 2px; flex-wrap: nowrap; justify-content: flex-end; }
  .order-foot > span { display: none; }
  .order-actions { gap: 7px; margin-left: auto; flex-wrap: nowrap; }
  .order-actions .btn, .order-foot .btn { height: 30px; padding: 0 12px; font-size: 12px; border-radius: 9px; }
  .status { font-size: 10.5px; padding: 3px 9px; }
  .countdown { font-size: 11.5px; }

  /* ---------------------------------------------------- 个人中心 */
  .profile-head {
    margin-top: 10px !important; padding: 18px; border-radius: 20px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff;
    border: none; box-shadow: 0 10px 24px rgba(79, 70, 229, .22);
  }
  .profile-head img { width: 56px; height: 56px; border: 2px solid rgba(255, 255, 255, .55); }
  .profile-head > div { min-width: 0; }
  .profile-head h2 { font-size: 18px !important; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .profile-head p {
    color: rgba(255, 255, 255, .74) !important; font-size: 11.5px !important;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
  .profile-head .tag { background: rgba(255, 255, 255, .2); color: #fff; }
  .profile-head .tag.gray { background: rgba(255, 255, 255, .12); color: rgba(255, 255, 255, .88); }
  .profile-head .btn-line {
    background: rgba(255, 255, 255, .16); border: none; color: #fff;
    height: 30px; font-size: 11.5px; padding: 0 10px; border-radius: 9px;
  }

  .stat-row {
    margin-top: -16px; position: relative; z-index: 2;
    grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0;
    background: #fff; border-radius: 18px; padding: 14px 4px;
    border: 1px solid var(--h5-line); box-shadow: none;
  }
  .stat-cell { background: none; box-shadow: none; padding: 2px; border-radius: 0; }
  .stat-cell b { font-size: 18px; letter-spacing: -.4px; }
  .stat-cell span { font-size: 10.5px; }

  .menu-list {
    margin-top: 12px; border-radius: 18px; box-shadow: none;
    border: 1px solid var(--h5-line);
  }
  .menu-item { padding: 13px 14px; font-size: 13.5px; }
  .menu-item .ico { width: 30px; height: 30px; border-radius: 9px; background: #f4f4f6; font-size: 14px; }
  .menu-item .arrow { font-size: 16px; }

  /* ---------------------------------------------------- 登录 / 改密 */
  .m-auth-brand {
    display: flex; flex-direction: column; align-items: center; gap: 9px;
    padding: 10px 0 20px;
  }
  .m-auth-brand .lg {
    width: 54px; height: 54px; border-radius: 16px; overflow: hidden;
    background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff;
    display: grid; place-items: center; font-size: 25px; font-weight: 800;
  }
  .m-auth-brand .lg img { width: 100%; height: 100%; object-fit: cover; }
  .m-auth-brand b { font-size: 17px; font-weight: 800; letter-spacing: -.2px; }

  .auth-wrap {
    margin-top: 0; min-height: 0; border-radius: 20px; display: block;
    box-shadow: none; border: 1px solid var(--h5-line); background: #fff;
  }
  .auth-form { padding: 22px 18px 24px; }
  .auth-form h3 { font-size: 21px; letter-spacing: -.4px; }
  .auth-form .hint { font-size: 12px; margin-top: 5px; }
  .toggle-auth { margin: 16px 0 18px; padding: 3px; border-radius: 12px; background: #f4f4f6; }
  .toggle-auth button { height: 34px; font-size: 13px; border-radius: 9px; }
  .form-stack { gap: 12px; }
  .auth-or { margin: -2px 0; }
  .auth-links { font-size: 12px; }
  .auth-links a { color: var(--h5-brand); }

  /* ---------------------------------------------------- 钱包 / 充值 / VIP */
  .balance-card {
    margin-top: 10px; padding: 18px; border-radius: 20px;
    background: linear-gradient(135deg, #312e81, #4f46e5 58%, #7c3aed);
    box-shadow: 0 12px 26px rgba(49, 46, 129, .24);
  }
  .balance-num { font-size: 30px; margin: 3px 0 14px; }
  .balance-row { gap: 8px; }
  .balance-row div { padding: 9px 11px; border-radius: 11px; }
  .balance-row b { font-size: 14px; }
  .balance-actions { margin-top: 14px; gap: 8px; }
  .balance-actions .btn { height: 36px; font-size: 13px; }
  .plan-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
  .plan-card { padding: 18px 12px 14px; border-radius: 16px; box-shadow: none; border: 1px solid var(--h5-line); }
  .plan-card.hot { border-color: #ddd6fe; }
  .plan-amount { font-size: 22px; }
  .vip-card { margin-top: 10px; padding: 20px; border-radius: 20px; }
  .vip-name { font-size: 22px; }
  .vip-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .vip-level { padding: 14px 12px; border-radius: 14px; }

  /* ---------------------------------------------------- 空态 / 加载 / 分页 */
  .empty {
    padding: 44px 16px; font-size: 13px;
    border: 1px solid var(--h5-line); background: #fff; border-radius: 18px;
  }
  .empty .ico { font-size: 34px; margin-bottom: 8px; }
  .loading-bar { height: 2px; }
  .pagination { gap: 6px; margin-top: 18px; flex-wrap: wrap; }
  .pagination button { min-width: 34px; height: 34px; border-radius: 10px; font-size: 12.5px; }

  /* ---------------------------------------------------- 弹层 */
  .overlay { align-items: flex-end; padding: 0; }
  .modal {
    max-width: 100%; border-radius: 22px 22px 0 0; max-height: 92vh;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .modal-head {
    padding: 16px 18px; position: sticky; top: 0; z-index: 2;
    background: rgba(255, 255, 255, .96); backdrop-filter: blur(12px);
  }
  .modal-body { padding: 18px; }
  .modal-foot { padding: 0 18px 18px; }
  .amount-big { font-size: 32px; }
  .pay-channel { padding: 12px; border-radius: 14px; margin-bottom: 9px; }
  .pay-channel .logo { width: 32px; height: 32px; border-radius: 9px; font-size: 15px; }
  .pay-channel .logo.balance { background: linear-gradient(135deg, #4f46e5, #7c3aed); }
  .pay-channel .meta b { font-size: 13.5px; }
  .pay-channel .meta span { font-size: 11.5px; }
  .qr-wrap { padding: 14px; border-radius: 14px; }
  .qr-wrap img, .qr-wrap canvas { width: 190px; height: 190px; }
  .toast-wrap { top: auto; bottom: calc(84px + env(safe-area-inset-bottom)); }
  .toast { border-radius: 999px; font-size: 13px; padding: 9px 16px; }

  /* ---------------------------------------------------- 辅助 */
  .m-hide { display: none !important; }
  .msg-inline { font-size: 12px; }
}

/* 平板窄屏（600-960）稍作放宽，避免卡片过大 */
@media (min-width: 600px) and (max-width: 960px) {
  .container { max-width: 640px; margin: 0 auto; }
  .m-topbar { max-width: 640px; margin: 0 auto; }
  .section .svc-card { flex-basis: 44%; }
  .svc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .mall-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .m-quick { max-width: 520px; }
  .game-entry a { flex-basis: 84px; }
}

/* 招募横幅（移动端） */
@media (max-width: 960px) {
  .cta-card {
    display: block; padding: 22px 20px; border-radius: 20px; border: none;
    background: linear-gradient(135deg, #1b1440, #4c1d95 60%, #6d28d9); color: #fff;
  }
  .cta-card h2 { font-size: 19px; line-height: 1.35; }
  .cta-card p { margin-top: 8px; font-size: 12px; line-height: 1.6; color: rgba(255, 255, 255, .78); }
  .cta-card .btn {
    margin-top: 16px; height: 38px; padding: 0 18px; font-size: 13px;
    background: #fff; color: #312e81; border: none;
  }
}
