:root{
  --brand:#3b6ef6;
  --brand-2:#5b8cff;
  --brand-soft:#eef3ff;
  --price:#e8352e;
  --price-2:#ff6a3d;
  --text:#1a1d24;
  --text-2:#6b7280;
  --text-3:#9aa3af;
  --line:#eceff4;
  --bg:#f5f7fb;
  --card:#ffffff;
  --radius:14px;
  --shadow:0 2px 10px rgba(23,45,92,.06);
  --safe-b:env(safe-area-inset-bottom,0px);
}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent;}
html,body{margin:0;padding:0;}
body{
  font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Helvetica Neue","Microsoft YaHei",sans-serif;
  background:var(--bg);color:var(--text);font-size:14px;line-height:1.55;
  -webkit-font-smoothing:antialiased;
  max-width:560px;margin:0 auto;position:relative;min-height:100vh;
}
a{color:inherit;text-decoration:none;}
img{max-width:100%;display:block;border:0;}
button,input,select,textarea{font-family:inherit;font-size:14px;outline:none;}
input,textarea{-webkit-appearance:none;appearance:none;border-radius:0;}

/* ---------- 顶部栏 ---------- */
.navbar{
  position:sticky;top:0;z-index:60;
  background:linear-gradient(135deg,#3b6ef6,#5b8cff);
  color:#fff;padding:10px 14px;display:flex;align-items:center;gap:10px;
}
.navbar .nav-back{font-size:20px;width:26px;flex:none;cursor:pointer;}
.navbar .nav-title{flex:1;text-align:center;font-size:16px;font-weight:600;letter-spacing:.3px;}
.navbar .nav-right{font-size:12px;opacity:.95;flex:none;min-width:26px;text-align:right;cursor:pointer;}

/* 首页专属头部 */
.home-head{background:linear-gradient(135deg,#3b6ef6,#5b8cff);padding:14px 14px 18px;color:#fff;}
.home-head .brand-row{display:flex;align-items:center;gap:10px;}
.home-head .logo{
  width:38px;height:38px;flex:none;border-radius:11px;background:#fff;
  display:flex;align-items:center;justify-content:center;
  color:#3b6ef6;font-weight:800;font-size:19px;
}
.home-head .site-name{font-size:17px;font-weight:700;line-height:1.2;}
.home-head .site-desc{font-size:11px;opacity:.85;margin-top:1px;}
.home-head .help-btn{
  margin-left:auto;flex:none;background:rgba(255,255,255,.22);
  border:1px solid rgba(255,255,255,.35);color:#fff;
  padding:6px 12px;border-radius:20px;font-size:12px;
}
.search-bar{
  margin-top:12px;display:flex;align-items:center;gap:8px;
  background:#fff;border-radius:20px;padding:8px 14px;color:#9aa3af;
}
.search-bar input{flex:1;border:0;background:transparent;color:var(--text);font-size:14px;}
.search-bar input::placeholder{color:#b3bac6;}

/* 公告 */
.notice-bar{
  display:flex;align-items:center;gap:7px;background:#fff;color:#e0700c;
  font-size:12px;padding:8px 14px;border-bottom:1px solid var(--line);
}
.notice-bar .ico{flex:none;}
.notice-bar .txt{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

/* ---------- 排序栏 ---------- */
.sort-bar{
  display:flex;align-items:center;background:#fff;padding:9px 8px;
  border-bottom:1px solid var(--line);position:sticky;top:0;z-index:50;
}
.sort-bar .sort-item{
  flex:1;text-align:center;font-size:13px;color:var(--text-2);position:relative;cursor:pointer;
}
.sort-bar .sort-item.active{color:var(--brand);font-weight:600;}
.sort-bar .sort-item .arrow{font-size:9px;margin-left:2px;display:inline-block;transform:scale(.85);}
.sort-bar .view-toggle{
  flex:none;padding-left:12px;border-left:1px solid var(--line);
  display:flex;gap:3px;align-items:center;cursor:pointer;
}
.view-toggle i{
  display:block;width:15px;height:15px;border-radius:3px;background:#c7cdd8;
}
.view-toggle.active i{background:var(--brand);}

/* ---------- 商品列表（大卡片列表样式） ---------- */
.goods-list{padding:10px 12px 90px;display:flex;flex-direction:column;gap:10px;}
.g-card{
  background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);
  display:flex;gap:11px;padding:11px;position:relative;overflow:hidden;
}
.g-card .thumb{
  width:92px;height:92px;flex:none;border-radius:10px;overflow:hidden;background:#eef2f7;position:relative;
}
.g-card .thumb img{width:100%;height:100%;object-fit:cover;}
.g-card .info{flex:1;min-width:0;display:flex;flex-direction:column;}
.g-card .title{
  font-size:14px;font-weight:600;line-height:1.4;color:var(--text);
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
}
.g-card .intro{
  font-size:11.5px;color:var(--text-3);margin-top:3px;
  display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;
}
.g-card .meta{font-size:11.5px;color:var(--text-3);margin-top:5px;}
.g-card .meta .stock{margin-left:10px;}
.g-card .bottom{margin-top:auto;display:flex;align-items:flex-end;gap:6px;padding-top:6px;}
.price-wrap{display:flex;align-items:baseline;gap:5px;flex:1;min-width:0;}
.price{
  color:var(--price);font-weight:800;font-size:19px;letter-spacing:-.4px;
}
.price .sym{font-size:12px;font-weight:700;margin-right:1px;}
.price .unit{font-size:11px;font-weight:500;color:var(--text-2);}
.origin-price{font-size:11.5px;color:#b9c0cc;text-decoration:line-through;}
.buy-btn{
  flex:none;background:linear-gradient(135deg,#3b6ef6,#5b8cff);color:#fff;
  border:0;border-radius:8px;padding:7px 16px;font-size:13px;font-weight:600;cursor:pointer;
}
.buy-btn:active{opacity:.85;}

/* 商品标签 */
.tag{
  position:absolute;right:0;top:0;font-size:10.5px;color:#fff;
  padding:3px 9px;border-radius:0 10px 0 10px;line-height:1.4;z-index:2;
}
.tag.auto{background:linear-gradient(135deg,#2fb36f,#4fd18b);}
.tag.manual{background:linear-gradient(135deg,#f0952a,#ffb954);}
.tag.virtual{background:linear-gradient(135deg,#3a7bff,#6aa6ff);}

/* ---------- 网格卡片样式 ---------- */
.goods-grid{
  padding:10px 10px 90px;display:grid;grid-template-columns:1fr 1fr;gap:10px;
}
.g-cell{
  background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);
  overflow:hidden;display:flex;flex-direction:column;position:relative;
}
.g-cell .cover{
  width:100%;aspect-ratio:4/3;background:#eef2f7;overflow:hidden;position:relative;
}
.g-cell .cover img{width:100%;height:100%;object-fit:cover;}
.g-cell .body{padding:9px 10px 10px;display:flex;flex-direction:column;flex:1;}
.g-cell .title{
  font-size:13px;font-weight:600;line-height:1.35;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:35px;
}
.g-cell .intro{
  font-size:11px;color:var(--text-3);margin-top:3px;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.g-cell .meta{font-size:11px;color:var(--text-3);margin-top:4px;}
.g-cell .bottom{margin-top:auto;display:flex;align-items:center;gap:5px;padding-top:7px;}
.g-cell .price{font-size:17px;}

/* 空状态 */
.empty{
  padding:70px 20px;text-align:center;color:var(--text-3);font-size:13px;
}
.empty .ico{font-size:44px;opacity:.35;margin-bottom:10px;}

/* ---------- 底部导航 ---------- */
.tabbar{
  position:fixed;left:0;right:0;bottom:0;z-index:70;
  max-width:560px;margin:0 auto;
  background:#fff;border-top:1px solid var(--line);
  display:flex;padding:6px 0 calc(6px + var(--safe-b));
  box-shadow:0 -2px 14px rgba(23,45,92,.05);
}
.tabbar a{
  flex:1;display:flex;flex-direction:column;align-items:center;gap:2px;
  font-size:11px;color:var(--text-3);
}
.tabbar a .ti{font-size:19px;line-height:1;}
.tabbar a.active{color:var(--brand);font-weight:600;}
/* 图标包裹层（用于未读红点定位） */
.tabbar a .ti-wrap{position:relative;display:inline-flex;align-items:center;justify-content:center;}
.tabbar a .dot{
  position:absolute;top:-4px;right:-9px;min-width:16px;height:16px;
  padding:0 4px;border-radius:9px;background:#e8352e;color:#fff;
  font-size:10px;font-weight:700;line-height:16px;text-align:center;
  font-style:normal;box-shadow:0 0 0 1.5px #fff;
}

/* 悬浮客服 */
.float-service{
  position:fixed;right:12px;bottom:calc(86px + var(--safe-b));z-index:65;
  width:52px;text-align:center;cursor:pointer;
}
.float-service .circle{
  width:52px;height:52px;border-radius:50%;
  background:linear-gradient(135deg,#3b6ef6,#6f9bff);color:#fff;
  display:flex;align-items:center;justify-content:center;font-size:22px;
  box-shadow:0 6px 18px rgba(59,110,246,.4);
}
.float-service .lbl{
  font-size:9.5px;color:var(--brand);background:#fff;border-radius:8px;
  padding:1px 5px;display:inline-block;margin-top:2px;box-shadow:var(--shadow);
}

/* ---------- 通用卡片区 ---------- */
.section{background:#fff;margin:10px 12px;border-radius:var(--radius);box-shadow:var(--shadow);}
.section-title{
  padding:12px 14px 8px;font-size:14px;font-weight:700;display:flex;align-items:center;gap:6px;
}
.section-title .bar{width:3px;height:14px;background:var(--brand);border-radius:2px;}
.section-title .more{margin-left:auto;font-size:12px;color:var(--text-3);font-weight:400;}

/* ---------- 表单 ---------- */
.field{
  display:flex;align-items:center;gap:10px;padding:13px 14px;border-bottom:1px solid var(--line);
}
.field:last-child{border-bottom:0;}
.field .lbl{
  flex:none;width:76px;font-size:13.5px;color:var(--text);font-weight:500;
}
.field .lbl .req{color:var(--price);margin-right:2px;}
.field input[type=text],.field input[type=number],.field input[type=password],.field input[type=email],.field select{
  flex:1;border:0;background:transparent;font-size:14px;color:var(--text);min-width:0;
}
.field input::placeholder{color:#c2c8d2;}
.field .hint{font-size:11.5px;color:var(--text-3);margin-top:5px;}

/* 输入框（独立） */
.input{
  width:100%;border:1px solid var(--line);background:#fafbfd;border-radius:10px;
  padding:11px 13px;font-size:14px;
}
.input:focus{border-color:var(--brand);background:#fff;}

/* ---------- 按钮 ---------- */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:6px;
  background:linear-gradient(135deg,#3b6ef6,#5b8cff);color:#fff;border:0;
  border-radius:10px;padding:11px 18px;font-size:14px;font-weight:600;cursor:pointer;
  transition:.15s;
}
.btn:active{opacity:.86;transform:scale(.99);}
.btn.block{width:100%;}
.btn.ghost{background:#fff;color:var(--brand);border:1px solid var(--brand);}
.btn.gray{background:#f2f4f8;color:var(--text-2);}
.btn.sm{padding:7px 13px;font-size:12.5px;border-radius:8px;}
.btn[disabled]{opacity:.5;pointer-events:none;}

/* 底部结算栏 */
.pay-bar{
  position:fixed;left:0;right:0;bottom:0;z-index:70;max-width:560px;margin:0 auto;
  background:#fff;border-top:1px solid var(--line);
  padding:10px 14px calc(10px + var(--safe-b));
  display:flex;align-items:center;gap:10px;
}
.pay-bar .total{flex:none;}
.pay-bar .total .t1{font-size:11.5px;color:var(--text-3);}
.pay-bar .total .t2{color:var(--price);font-size:20px;font-weight:800;letter-spacing:-.4px;}
.pay-bar .total .t2 .sym{font-size:12px;}
.pay-bar .saved-tip{font-size:11px;color:var(--price);margin-left:6px;}
.pay-bar .btn{flex:1;max-width:150px;margin-left:auto;}

/* ---------- 弹窗 ---------- */
.modal-mask{
  position:fixed;inset:0;background:rgba(15,20,32,.45);z-index:200;
  display:flex;align-items:center;justify-content:center;padding:20px;
  opacity:0;pointer-events:none;transition:.2s;
}
.modal-mask.show{opacity:1;pointer-events:auto;}
.modal{
  background:#fff;border-radius:16px;width:100%;max-width:400px;
  max-height:82vh;overflow-y:auto;transform:translateY(12px);transition:.22s;
}
.modal-mask.show .modal{transform:translateY(0);}
.modal-head{
  background:linear-gradient(135deg,#3b6ef6,#6f9bff);color:#fff;
  padding:18px 18px 16px;border-radius:16px 16px 0 0;position:relative;overflow:hidden;
}
.modal-head h3{margin:0;font-size:19px;font-weight:700;}
.modal-head .steps{margin-top:10px;font-size:12px;opacity:.95;line-height:1.9;}
.modal-head .deco{
  position:absolute;right:14px;top:14px;font-size:52px;opacity:.18;
}
.modal-body{padding:6px 18px 4px;}
.notice-item{display:flex;gap:11px;padding:12px 0;border-bottom:1px solid var(--line);}
.notice-item:last-child{border-bottom:0;}
.notice-item .nico{
  width:34px;height:34px;flex:none;border-radius:50%;background:var(--brand-soft);
  display:flex;align-items:center;justify-content:center;font-size:16px;
}
.notice-item .nbody h4{margin:0 0 3px;font-size:14px;font-weight:700;}
.notice-item .nbody p{margin:0;font-size:12.5px;color:var(--text-2);line-height:1.6;}
.modal-foot{padding:8px 18px 18px;text-align:center;}
.modal-foot .close-link{color:var(--brand);font-size:15px;font-weight:600;cursor:pointer;}

/* Toast */
.toast{
  position:fixed;left:50%;top:46%;transform:translate(-50%,-50%) scale(.94);
  background:rgba(20,25,38,.9);color:#fff;padding:11px 20px;border-radius:10px;
  font-size:13.5px;z-index:999;opacity:0;pointer-events:none;transition:.2s;max-width:80%;
  text-align:center;
}
.toast.show{opacity:1;transform:translate(-50%,-50%) scale(1);}

/* ---------- 商品详情 ---------- */
.gallery{
  position:relative;background:#fff;
}
.gallery .swiper{
  display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;align-items:center;
}
.gallery .swiper::-webkit-scrollbar{display:none;}
.gallery .swiper img{
  width:100%;flex:none;scroll-snap-align:center;height:auto;max-height:520px;object-fit:contain;background:#eef2f7;
}
.gallery .counter{
  position:absolute;left:50%;bottom:12px;transform:translateX(-50%);
  background:rgba(0,0,0,.42);color:#fff;font-size:11.5px;padding:2px 10px;border-radius:12px;
}
/* 轮播左右切换按钮：手机端默认隐藏（可手势滑动），桌面端由 desktop.css 显示 */
.g-nav{display:none;}
.gallery .share{
  position:absolute;right:12px;top:12px;background:rgba(0,0,0,.35);color:#fff;
  padding:5px 11px;border-radius:16px;font-size:12px;cursor:pointer;
}
.detail-title{padding:14px 14px 4px;background:#fff;}
.detail-title h1{margin:0;font-size:17.5px;font-weight:700;line-height:1.42;}
.detail-title .stat{display:flex;gap:14px;font-size:12px;color:var(--text-3);margin-top:8px;}

.detail-block{background:#fff;margin-top:9px;padding:14px;}
.detail-block:last-of-type{padding-bottom:20px;}
.block-label{font-size:13.5px;font-weight:700;margin-bottom:10px;display:flex;align-items:center;gap:6px;}
.block-label .req{color:var(--price);}

/* 优惠券 */
.coupon-row{
  display:flex;align-items:center;gap:9px;border:1px solid var(--line);
  border-radius:10px;padding:11px 13px;cursor:pointer;background:#fafbfd;
}
.coupon-row.on{border-color:var(--brand);background:var(--brand-soft);}
.coupon-row .cbox{
  width:18px;height:18px;border-radius:5px;border:1.5px solid #cbd2dd;flex:none;
  display:flex;align-items:center;justify-content:center;color:#fff;font-size:12px;background:#fff;
}
.coupon-row.on .cbox{background:var(--brand);border-color:var(--brand);}
.coupon-row .ctext{flex:1;font-size:13px;}
.coupon-row .cval{color:var(--price);font-weight:700;}

/* 规格选择 */
.spec-list{display:flex;flex-wrap:wrap;gap:9px;}
.spec-item{
  min-width:74px;text-align:center;border:1px solid var(--line);background:#fafbfd;
  border-radius:9px;padding:9px 13px;cursor:pointer;position:relative;transition:.15s;
}
.spec-item.active{border-color:var(--brand);background:var(--brand-soft);color:var(--brand);font-weight:600;}
.spec-item .sname{font-size:13px;line-height:1.3;}
.spec-item .sprice{font-size:11px;color:var(--price);margin-top:2px;font-weight:600;}
.spec-item.active .sprice{color:var(--brand);}
.spec-item.disabled{opacity:.4;pointer-events:none;}
.spec-item .corner{
  position:absolute;left:0;bottom:0;width:0;height:0;
  border:9px solid transparent;border-left-color:var(--brand);border-bottom-color:var(--brand);
}

/* 数量加减 */
.stepper{display:inline-flex;align-items:center;border:1px solid var(--line);border-radius:9px;overflow:hidden;}
.stepper button{
  width:36px;height:34px;border:0;background:#f7f9fc;font-size:17px;color:var(--text-2);cursor:pointer;
}
.stepper button:active{background:#eef2f8;}
.stepper input{
  width:52px;height:34px;border:0;text-align:center;font-size:14px;font-weight:600;background:#fff;
}

/* 批发优惠提示 */
.whole-tip{
  font-size:12px;color:var(--brand);background:var(--brand-soft);
  border-radius:8px;padding:7px 11px;margin-top:9px;display:flex;gap:6px;align-items:center;
}
.whole-ladder{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px;}
.whole-ladder span{
  font-size:11.5px;background:#fff6f5;color:var(--price);border:1px solid #ffe0dd;
  border-radius:6px;padding:2px 9px;
}

/* 支付方式（仅易支付） */
.pay-methods{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:9px;}
.pay-method{
  border:1px solid var(--line);border-radius:10px;padding:11px 12px;display:flex;align-items:center;gap:8px;
  cursor:pointer;background:#fafbfd;position:relative;min-width:0;
}
.pay-method.active{border-color:var(--brand);background:var(--brand-soft);}
.pay-method.disabled{opacity:.5;cursor:not-allowed;filter:grayscale(.4);}
.pay-method .pm-sub{margin-left:auto;font-size:12.5px;font-weight:700;color:var(--price);flex:none;}
.pay-method .pm-ico{flex:none;width:20px;height:20px;display:flex;align-items:center;justify-content:center;font-size:17px;line-height:1;}
.pay-method .pm-name{font-size:12.5px;font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.pay-method .pm-check{
  position:absolute;right:6px;top:6px;width:15px;height:15px;border-radius:50%;
  background:var(--brand);color:#fff;font-size:9px;display:none;align-items:center;justify-content:center;
  padding-right:1px;
}
.pay-method.active .pm-check{display:flex;}
.pay-lock-tip{
  margin-top:9px;font-size:11.5px;color:var(--text-3);display:flex;align-items:center;gap:5px;
}

/* 邮件开关 */
.switch-row{display:flex;align-items:center;gap:10px;}
.switch-row .sw-text{flex:1;}
.switch-row .sw-text .t{font-size:13.5px;font-weight:600;}
.switch-row .sw-text .d{font-size:11.5px;color:var(--text-3);margin-top:2px;}
.switch{
  width:48px;height:27px;border-radius:14px;background:#dfe4ec;position:relative;
  flex:none;cursor:pointer;transition:.2s;
}
.switch.on{background:var(--brand);}
.switch::after{
  content:'';position:absolute;left:3px;top:3px;width:21px;height:21px;border-radius:50%;
  background:#fff;transition:.2s;box-shadow:0 1px 3px rgba(0,0,0,.15);
}
.switch.on::after{left:24px;}

/* 商品详情富文本 */
.rich{font-size:13.5px;line-height:1.85;color:#333a46;}
.rich p{margin:0 0 8px;}
.rich img{border-radius:8px;margin:8px 0;}

/* ---------- 订单 / 查单 ---------- */
.order-card{
  background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);
  margin:10px 12px;overflow:hidden;
}
.order-card .oc-head{
  display:flex;align-items:center;padding:11px 13px;border-bottom:1px solid var(--line);gap:8px;
}
.order-card .oc-no{font-size:11.5px;color:var(--text-3);flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.badge{font-size:11px;padding:2px 9px;border-radius:20px;font-weight:600;flex:none;}
.badge.paid{background:#e8f7ef;color:#1f9d5c;}
.badge.wait{background:#fff4e6;color:#e0840e;}
.badge.close{background:#f2f4f8;color:#8b929e;}
.order-card .oc-body{display:flex;gap:11px;padding:12px 13px;}
.order-card .oc-body .th{
  width:70px;height:70px;border-radius:9px;overflow:hidden;flex:none;background:#eef2f7;
}
.order-card .oc-body .th img{width:100%;height:100%;object-fit:cover;}
.order-card .oc-body .oi{flex:1;min-width:0;}
.order-card .oc-body .oi .t{
  font-size:13.5px;font-weight:600;line-height:1.4;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
}
.order-card .oc-body .oi .s{font-size:11.5px;color:var(--text-3);margin-top:5px;}
.order-card .oc-body .oi .a{color:var(--price);font-weight:800;font-size:15px;margin-top:6px;}
.order-card .oc-foot{
  padding:10px 13px;border-top:1px solid var(--line);display:flex;gap:8px;justify-content:flex-end;align-items:center;
}

/* 卡密展示 */
.card-reveal{
  background:#f7f9fc;border:1px dashed #cfd8e6;border-radius:10px;
  padding:11px 12px;margin:0 13px 12px;font-size:12.5px;font-family:ui-monospace,Menlo,Consolas,monospace;
  white-space:pre-wrap;word-break:break-all;line-height:1.85;color:#22303f;
}
.card-reveal .crt{font-size:11.5px;color:var(--text-3);display:flex;align-items:center;gap:5px;margin-bottom:6px;font-family:inherit;}

/* ---------- 我的 ---------- */
.profile-head{
  background:linear-gradient(135deg,#3b6ef6,#5b8cff);padding:20px 16px 26px;color:#fff;
  display:flex;align-items:center;gap:13px;
}
.profile-head .avatar{
  width:56px;height:56px;border-radius:50%;background:rgba(255,255,255,.24);
  display:flex;align-items:center;justify-content:center;font-size:25px;flex:none;
  border:2px solid rgba(255,255,255,.4);
}
.profile-head .pinfo{flex:1;min-width:0;}
.profile-head .pinfo .pn{font-size:16.5px;font-weight:700;}
.profile-head .pinfo .pc{font-size:11.5px;opacity:.88;margin-top:3px;word-break:break-all;}

.stat-grid{display:grid;grid-template-columns:repeat(3,1fr);background:#fff;text-align:center;}
.stat-grid .si{padding:14px 4px;cursor:pointer;}
.stat-grid .si .n{font-size:19px;font-weight:800;color:var(--brand);}
.stat-grid .si .l{font-size:11.5px;color:var(--text-3);margin-top:2px;}

.menu-list{background:#fff;margin-top:9px;}
.menu-item{
  display:flex;align-items:center;gap:11px;padding:14px;border-bottom:1px solid var(--line);cursor:pointer;
}
.menu-item:last-child{border-bottom:0;}
.menu-item .mi{
  width:32px;height:32px;border-radius:9px;background:var(--brand-soft);color:var(--brand);
  display:flex;align-items:center;justify-content:center;font-size:16px;flex:none;
}
.menu-item .mt{flex:1;font-size:14px;}
.menu-item .mt .sub{font-size:11.5px;color:var(--text-3);margin-top:2px;font-weight:400;}
.menu-item .arrow{color:#cbd2dd;font-size:15px;}

/* 分店套餐卡 */
.plan-wrap{display:flex;gap:10px;padding:10px 12px 14px;overflow-x:auto;scrollbar-width:none;}
.plan-wrap::-webkit-scrollbar{display:none;}
.plan-card{
  flex:none;width:158px;border-radius:14px;padding:14px;
  background:linear-gradient(160deg,#f2f6ff,#ffffff);
  border:1.5px solid #e3ebfb;position:relative;overflow:hidden;
  display:flex;flex-direction:column;min-height:322px;   /* 统一高度，三档卡片对齐 */
}
.plan-card.hot{background:linear-gradient(160deg,#fff5ec,#fffdfb);border-color:#ffd9ba;}
.plan-card.cur{border-color:var(--brand);box-shadow:0 4px 16px rgba(59,110,246,.16);}
.plan-card .pn{font-size:15px;font-weight:800;}
.plan-card .pp{color:var(--price);font-size:21px;font-weight:800;margin:6px 0 2px;letter-spacing:-.5px;}
.plan-card .pp .sym{font-size:12px;}
.plan-card .pp .unit{font-size:11px;color:var(--text-3);font-weight:400;}
.plan-card .pd{font-size:11px;color:var(--text-3);}
.plan-card .rights{margin:9px 0 11px;font-size:11.5px;color:var(--text-2);line-height:1.85;flex:1;}
.plan-card .rights div::before{content:'';display:inline-block;width:12px;height:12px;margin-right:5px;vertical-align:-1px;background:currentColor;-webkit-mask:url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5 10-11'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5 10-11'/%3E%3C/svg%3E") center/contain no-repeat;}
.plan-card .pbtn{
  display:block;text-align:center;background:linear-gradient(135deg,#3b6ef6,#5b8cff);color:#fff;
  border-radius:9px;padding:8px;font-size:13px;font-weight:600;margin-top:auto;   /* 按钮统一贴底 */
}
.plan-card.cur .pbtn{background:#eef2f8;color:var(--brand);}
.plan-card .ribbon{
  position:absolute;right:-1px;top:9px;background:#ff8a3d;color:#fff;font-size:10px;
  padding:2px 8px;border-radius:8px 0 0 8px;
}

/* 邀请/分销 */
.invite-box{
  margin:10px 12px;background:linear-gradient(135deg,#3b6ef6,#6f9bff);border-radius:var(--radius);
  padding:16px;color:#fff;position:relative;overflow:hidden;
}
.invite-box h3{margin:0 0 4px;font-size:15px;}
.invite-box .code-box{
  margin-top:12px;background:rgba(255,255,255,.18);border-radius:10px;padding:11px 13px;
  display:flex;align-items:center;gap:10px;border:1px dashed rgba(255,255,255,.45);
}
.invite-box .code-box .c{flex:1;font-size:19px;font-weight:800;letter-spacing:2px;}
.invite-box .code-box .cp{
  background:#fff;color:var(--brand);border-radius:7px;padding:5px 13px;font-size:12.5px;font-weight:700;cursor:pointer;
}
.fans-grid{display:grid;grid-template-columns:repeat(3,1fr);text-align:center;}
.fans-grid .fi{padding:13px 4px;}
.fans-grid .fi .n{font-size:20px;font-weight:800;color:var(--price);}
.fans-grid .fi .l{font-size:11.5px;color:var(--text-3);margin-top:3px;}

/* 表格（后台/明细） */
.tbl{width:100%;border-collapse:collapse;font-size:13px;background:#fff;}
.tbl th{background:#f7f9fc;color:var(--text-2);font-weight:600;text-align:left;padding:10px 12px;border-bottom:1px solid var(--line);white-space:nowrap;}
.tbl td{padding:11px 12px;border-bottom:1px solid var(--line);vertical-align:middle;}
.tbl tr:last-child td{border-bottom:0;}

/* 小工具 */
.flex{display:flex;align-items:center;}
.gap6{gap:6px;}.gap10{gap:10px;}
.mt6{margin-top:6px;}.mt10{margin-top:10px;}.mt14{margin-top:14px;}
.tc{text-align:center;}
.f12{font-size:12px;}.f11{font-size:11px;}
.c3{color:var(--text-3);}.c2{color:var(--text-2);}.cprice{color:var(--price);}.cbrand{color:var(--brand);}
.fw6{font-weight:600;}.fw8{font-weight:800;}
.page-pad-bottom{padding-bottom:96px;}

/* ================= 登录 / 注册 ================= */
.login-page{padding:0 14px;}

.login-logo{text-align:center;padding:26px 0 20px;}
.login-logo .mk{
  width:60px;height:60px;margin:0 auto 12px;border-radius:18px;
  background:linear-gradient(135deg,#3b6ef6,#6f9bff);
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 8px 22px rgba(59,110,246,.32);
}
.login-logo .nm{font-size:19px;font-weight:800;letter-spacing:.3px;}
.login-logo .ds{font-size:12px;color:var(--text-3);margin-top:5px;}

/* 页签 */
.seg-tabs{
  display:flex;background:#eef1f7;border-radius:11px;padding:4px;margin-bottom:14px;
}
.seg-tabs a{
  flex:1;text-align:center;padding:9px 0;font-size:13.5px;color:var(--text-2);
  border-radius:8px;transition:.15s;font-weight:500;
}
.seg-tabs a.on{background:#fff;color:var(--brand);font-weight:700;box-shadow:0 1px 4px rgba(23,45,92,.09);}

/* 表单卡片 */
.login-card{
  background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);
  padding:16px 14px 18px;margin-bottom:12px;
}
.login-card .fitem{margin-bottom:13px;}
.login-card .fitem:last-of-type{margin-bottom:0;}
.login-card .fitem > label{
  display:block;font-size:12.5px;font-weight:600;color:var(--text-2);margin-bottom:6px;
}
.login-card .fitem > label .req{color:var(--price);}

/* 密码框 + 眼睛 */
.pwd-wrap{position:relative;}
.pwd-wrap .input{padding-right:42px;}
.pwd-wrap .eye{
  position:absolute;right:2px;top:50%;transform:translateY(-50%);
  width:38px;height:38px;display:flex;align-items:center;justify-content:center;
  cursor:pointer;opacity:.55;transition:.15s;color:var(--text-3);
}
.pwd-wrap .eye:active{opacity:1;}

/* 游客进入 / 兜底查单 */
.guest-box{
  background:#fff;border-radius:var(--radius);box-shadow:var(--shadow);
  padding:14px;margin-bottom:12px;
}
.guest-box .gb-h{
  display:flex;align-items:center;gap:6px;font-size:13.5px;font-weight:700;
  color:var(--brand);margin-bottom:6px;
}
.guest-box .muted{font-size:12px;color:var(--text-3);line-height:1.7;}

.row-inline{display:flex;gap:9px;align-items:center;}
.row-inline .input{flex:1;min-width:0;}
.row-inline .btn{flex:none;white-space:nowrap;}

.clink{color:var(--brand);font-weight:600;}
.muted{color:var(--text-3);}

/* 凭据展示 */
.tip-box{
  background:linear-gradient(135deg,#eef3ff,#f7faff);
  border:1px solid #dfe8ff;border-radius:12px;padding:14px;
}
.tip-box .tip-t{
  font-size:13px;font-weight:700;color:var(--brand);margin-bottom:10px;
  display:flex;align-items:center;gap:6px;
}
.cred{
  background:#fff;border-radius:10px;padding:4px 12px;border:1px solid #e6ecf8;
}
.cred .cr{
  display:flex;align-items:center;gap:10px;padding:9px 0;border-bottom:1px dashed var(--line);
}
.cred .cr:last-child{border-bottom:0;}
.cred .cr .k{flex:none;width:38px;font-size:12.5px;color:var(--text-3);}
.cred .cr .v{
  flex:1;font-size:15px;font-weight:700;letter-spacing:.6px;
  font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
  color:var(--text);word-break:break-all;user-select:all;
}

/* 游客弹窗（.modal 变体） */
#mGuest .mbox{padding:0;}
#mGuest .mh{
  display:flex;align-items:center;gap:8px;padding:16px 18px 12px;
  font-size:16px;font-weight:700;
}
#mGuest .mb{padding:0 18px 4px;}
#mGuest .mf{
  padding:14px 18px 18px;display:flex;gap:10px;
}
#mGuest .mf .btn{flex:1;}

/* ================= 消息中心（列表） ================= */
.msg-page{padding:0 0 1px;}
.cs-card{
  display:flex;align-items:center;gap:12px;background:#f8faff;
  border:1px solid #e8eeff;border-radius:12px;padding:13px 14px;cursor:pointer;
  transition:.15s;
}
.cs-card:active{background:#f0f5ff;}
.cs-ico{
  width:44px;height:44px;flex:none;border-radius:13px;
  background:linear-gradient(135deg,#5b8cff,#3b6ef6);
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 4px 12px rgba(59,110,246,.28);
}
.cs-body{flex:1;min-width:0;}
.cs-body .cs-t{font-size:14.5px;font-weight:700;}
.cs-body .cs-d{
  font-size:11.5px;color:var(--text-3);margin-top:3px;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
}
.cs-card .arrow{color:#cbd2dd;font-size:17px;flex:none;}

/* ================= 会话窗口 ================= */
.chat-page{
  display:flex;flex-direction:column;
  height:calc(100vh - 46px);height:calc(100dvh - 46px);
  background:var(--bg);
}
.chat-head-tip{
  flex:none;display:flex;align-items:center;gap:6px;
  background:#eef3ff;color:#3b6ef6;font-size:11.5px;
  padding:8px 14px;line-height:1.5;
}
.chat-list{
  flex:1;overflow-y:auto;padding:14px 12px 16px;
  -webkit-overflow-scrolling:touch;
}
.chat-loading,.chat-empty{
  text-align:center;color:var(--text-3);font-size:12.5px;padding:40px 20px;line-height:1.8;
}

/* 气泡行 */
.chat-row{display:flex;flex-direction:column;margin-bottom:14px;}
.chat-row.me{align-items:flex-end;}
.chat-row.cs{align-items:flex-start;}
.chat-bubble{
  max-width:78%;padding:10px 13px;border-radius:14px;
  font-size:14px;line-height:1.6;word-break:break-word;white-space:pre-wrap;
}
.chat-row.me .chat-bubble{
  background:linear-gradient(135deg,#3b6ef6,#5b8cff);color:#fff;
  border-bottom-right-radius:4px;
}
.chat-row.cs .chat-bubble{
  background:#fff;color:var(--text);border-bottom-left-radius:4px;
  box-shadow:0 1px 4px rgba(23,45,92,.07);
}
.chat-time{font-size:10.5px;color:var(--text-3);margin-top:5px;padding:0 3px;}
/* 图片消息：无气泡底色/边框，缩小展示 */
.chat-bubble.img{padding:0;background:none!important;box-shadow:none;border-radius:0;color:inherit;}
.chat-img{max-width:150px;border-radius:10px;display:block;cursor:zoom-in;}

/* 买家帮助 FAQ（后台「网站设置-买家帮助文档」编辑，每行：问题|答案） */
.faq-item{border-bottom:1px solid #eceff4;}
.faq-item:last-child{border-bottom:0;}
.faq-item summary{
  list-style:none;cursor:pointer;padding:13px 14px;font-size:13.5px;font-weight:600;
  color:#333a46;display:flex;align-items:center;gap:8px;
}
.faq-item summary::-webkit-details-marker{display:none;}
.faq-item .faq-q{
  flex:none;width:18px;height:18px;border-radius:5px;background:#eef3ff;color:#3b6ef6;
  font-size:11px;font-weight:800;display:inline-flex;align-items:center;justify-content:center;
}
.faq-item .arrow{margin-left:auto;color:#c3cbd8;transition:.2s;}
.faq-item[open] .arrow{transform:rotate(90deg);}
.faq-item .faq-a{padding:0 14px 13px 40px;font-size:13px;line-height:1.8;color:#5b6472;}
.faq-plain{padding:12px 14px;border-bottom:1px solid #eceff4;font-size:13.5px;line-height:1.7;color:#333a46;}

/* 系统 / 卡密消息卡片 */
.chat-row.sys{align-items:center;}
.chat-sys-card{
  width:100%;background:#fff;border-radius:12px;padding:12px 14px;
  box-shadow:0 1px 5px rgba(23,45,92,.07);border:1px solid #eef2f8;
}
.chat-sys-card.card{background:#fffdf7;border-color:#ffe8bf;}
.chat-sys-card .csc-h{
  display:flex;align-items:center;gap:6px;
  font-size:12px;font-weight:700;color:var(--text-2);margin-bottom:8px;
}
.chat-sys-card .csc-ico{font-size:14px;}
.chat-sys-card .csc-t{margin-left:auto;font-weight:400;color:var(--text-3);font-size:10.5px;}
.chat-sys-card .csc-b{
  font-size:13px;line-height:1.75;color:#333a46;word-break:break-word;
  user-select:text;
}
.chat-sys-card .csc-copy{margin-top:10px;width:100%;}

/* 底部输入区 */
.chat-foot{
  flex:none;background:#fff;border-top:1px solid var(--line);
  padding:8px 10px calc(8px + var(--safe-b));
}
.chat-foot.sys-foot{padding:12px 14px calc(12px + var(--safe-b));}
.sys-tip{font-size:12px;color:var(--text-3);text-align:center;line-height:1.7;}
.sys-tip a{color:var(--brand);font-weight:600;}

.chat-tools{display:flex;gap:18px;padding:2px 4px 8px;}
.ctool{
  display:inline-flex;align-items:center;gap:4px;
  font-size:11.5px;color:var(--text-2);
}
.ctool:active{color:var(--brand);}

.chat-input-row{display:flex;align-items:flex-end;gap:9px;}
.chat-input-row textarea{
  flex:1;border:1px solid var(--line);background:#f7f9fc;border-radius:12px;
  padding:9px 12px;font-size:14px;line-height:1.5;resize:none;
  max-height:96px;overflow-y:auto;
}
.chat-input-row textarea:focus{background:#fff;border-color:var(--brand);}
.chat-send{flex:none;padding:9px 18px;border-radius:12px;}

/* 表情 / 快捷语面板 */
.emoji-panel,.quick-panel{
  display:none;flex-wrap:wrap;gap:6px;
  background:#f7f9fc;border-radius:12px;padding:10px;margin-bottom:9px;
  max-height:168px;overflow-y:auto;
}
.emoji-panel.show,.quick-panel.show{display:flex;}
.emoji-panel a{
  width:34px;height:34px;display:flex;align-items:center;justify-content:center;
  font-size:20px;border-radius:8px;
}
.emoji-panel a:active{background:#e9eefa;}
.quick-panel{flex-direction:column;gap:0;padding:4px 0;}
.quick-panel a{
  display:block;padding:10px 13px;font-size:13px;color:var(--text);
  border-bottom:1px solid var(--line);
}
.quick-panel a:last-child{border-bottom:0;}
.quick-panel a:active{background:#eef3ff;}

/* ---------- 桌面端顶部导航：手机端一律隐藏（必须放在 app.css，
   因 desktop.css 在手机端按 media 条件不再加载） ---------- */
.desktop-nav{display:none;}
