:root {
  --teal: #128a78;
  --teal-d: #0a6b5c;
  --teal-l: #e4f3ee;
  --teal-ll: #f1f9f6;
  --deep: #0b3b34;
  --ink: #1f302b;
  --muted: #7b8a85;
  --line: #e6eeea;
  --bg: #f4f8f6;
  --card: #ffffff;
  --amber: #d98618;
  --amber-l: #fdf1de;
  --red: #d64b4b;
  --red-l: #fdeaea;
  --blue: #4a7bd6;
  --blue-l: #eaf0fc;
  --shadow: 0 2px 10px rgba(16, 60, 50, .055), 0 1px 3px rgba(16, 40, 34, .045);
  --shadow-lg: 0 10px 28px rgba(16, 70, 58, .13), 0 2px 8px rgba(16, 40, 34, .05);
  --r: 16px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #e9f0ed; color: var(--ink); line-height: 1.5; -webkit-font-smoothing: antialiased;
}
.hidden { display: none !important; }
.app-shell { max-width: 520px; margin: 0 auto; min-height: 100vh; background: var(--bg); position: relative; padding-bottom: 78px; }
@media (min-width: 900px) { .app-shell { max-width: 960px; box-shadow: 0 0 48px rgba(11, 59, 52, .07); } }

.page { min-height: 100vh; }
button, input, select, textarea { font-family: inherit; }
button { cursor: pointer; }

/* ---------- 首页头部 ---------- */
.home-head { background: radial-gradient(120% 85% at 12% -5%, rgba(255,255,255,.16) 0%, transparent 46%), radial-gradient(85% 65% at 92% 105%, rgba(3,52,44,.5) 0%, transparent 58%), linear-gradient(150deg, #17a38d 0%, #0d7566 48%, #08463d 100%); padding: 18px 18px 20px; color: #fff; position: relative; overflow: hidden; border-radius: 0 0 24px 24px; }
.home-head::before { content: ''; position: absolute; width: 230px; height: 230px; border-radius: 50%; background: rgba(255,255,255,.06); top: -125px; right: -65px; }
.home-head::after { content: ''; position: absolute; width: 170px; height: 170px; border-radius: 50%; background: rgba(255,255,255,.04); bottom: -105px; left: -45px; }
.home-head > * { position: relative; z-index: 1; }
.brand-row { display: flex; align-items: center; gap: 11px; }
.brand-mark { width: 38px; height: 38px; flex: none; border-radius: 11px; background: linear-gradient(145deg, #ffffff, #d7efe7); color: var(--teal-d); display: grid; place-items: center; font-weight: 900; font-size: 19px; box-shadow: 0 3px 10px rgba(0,0,0,.13), inset 0 1px 1px rgba(255,255,255,.9); position: relative; overflow: hidden; }
.home-head .brand-mark::after { content: ''; position: absolute; top: -60%; left: -80%; width: 55%; height: 220%; background: linear-gradient(90deg, transparent, rgba(255,255,255,.75), transparent); transform: rotate(25deg); animation: markShine 4.5s ease-in-out infinite; }
@keyframes markShine { 0%, 62% { left: -80%; } 82%, 100% { left: 150%; } }
.brand-txt { display: flex; flex-direction: column; line-height: 1.15; }
.brand-txt b { font-size: 18px; letter-spacing: .5px; }
.brand-txt small { font-size: 9.5px; opacity: .75; letter-spacing: 1.6px; }
.head-admin { margin-left: auto; border: 1px solid rgba(255,255,255,.38); background: rgba(255,255,255,.16); backdrop-filter: blur(4px); color: #fff; border-radius: 20px; padding: 6px 15px; font-size: 12.5px; font-weight: 600; transition: .15s; }
.head-admin:hover { background: rgba(255,255,255,.28); }
.search-row { margin-top: 16px; display: flex; align-items: center; background: #fff; border-radius: 24px; padding: 0 15px; height: 42px; color: var(--muted); box-shadow: 0 5px 16px rgba(0,0,0,.12); transition: box-shadow .2s, transform .2s; }
.search-row:focus-within { box-shadow: 0 6px 20px rgba(0,0,0,.18), 0 0 0 3px rgba(255,255,255,.35); transform: translateY(-1px); }
.search-ico { font-size: 22px; margin-right: 7px; color: var(--teal); }
.search-row input { flex: 1; min-width: 0; border: 0; outline: 0; font-size: 14px; color: var(--ink); background: transparent; }
.search-clear { flex: none; width: 22px; height: 22px; padding: 0; margin-left: 4px; border: 0; border-radius: 50%; background: #eaf1ee; color: #7b8a85; font-size: 11px; display: grid; place-items: center; }
.search-clear:active { background: #d9e8e2; color: var(--teal-d); }
.metric-strip { margin-top: 14px; display: flex; align-items: center; background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.2); border-radius: 15px; padding: 11px 6px; backdrop-filter: blur(8px); box-shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 4px 14px rgba(0,0,0,.06); }
.hm-item { flex: 1; text-align: center; display: flex; flex-direction: column; gap: 3px; }
.hm-item b { font-size: 19px; font-weight: 800; letter-spacing: .3px; line-height: 1; background: linear-gradient(180deg, #fff, #d9f3ea); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hm-item span { font-size: 10.5px; opacity: .8; }
.hm-sep { width: 1px; height: 28px; background: linear-gradient(180deg, transparent, rgba(255,255,255,.3), transparent); flex: none; }
.notice { margin-top: 12px; background: rgba(255,255,255,.95); border-radius: 10px; padding: 9px 11px; display: flex; align-items: center; gap: 8px; color: #4a5c56; font-size: 11.5px; cursor: pointer; transition: .15s; }
.notice:hover { background: #fff; transform: translateY(-1px); }
.notice-tag { flex: none; background: linear-gradient(135deg, #ff9f5a, #e2682c); color: #fff; font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 5px; box-shadow: 0 2px 6px rgba(226,104,44,.28); position: relative; overflow: hidden; }
.notice-tag::after { content: ''; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.45) 50%, transparent 65%); transform: translateX(-100%); animation: tagSheen 3.6s ease-in-out infinite; }
@keyframes tagSheen { 0%, 70% { transform: translateX(-100%); } 88%, 100% { transform: translateX(100%); } }
.notice-text { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; flex: 1; }
.notice-more { color: var(--muted); font-size: 18px; line-height: 1; }

/* ---------- 首页主体：分类 + 商品（白色面板上叠头部，底部圆角收口，与下方板块自然衔接） ---------- */
.home-body { display: flex; align-items: stretch; background: var(--card); border-radius: 24px 24px 22px 22px; overflow: hidden; position: relative; z-index: 2; margin: -14px 0 0; box-shadow: 0 -2px 0 rgba(255,255,255,.5), 0 10px 24px rgba(16,60,50,.07); }
.home-body::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, #e2ece8 18%, #e2ece8 82%, transparent); }
.cat-side { width: 94px; flex: none; background: #f2f8f5; padding: 10px 0 16px; align-self: stretch; border-right: 1px solid #eaf1ee; }
.cat-item { width: 100%; border: 0; background: transparent; padding: 14px 6px; font-size: 12.5px; color: #5e6e69; position: relative; transition: .15s; }
.cat-item:hover { color: var(--teal-d); }
.cat-item.active { background: var(--card); color: var(--teal-d); font-weight: 700; }
.cat-item.active::before { content: ''; position: absolute; left: 0; top: 20%; height: 60%; width: 3px; background: var(--teal); border-radius: 0 3px 3px 0; }
.cat-item .ci-ico { display: block; font-size: 16px; margin-bottom: 3px; }
.prod-area { flex: 1; min-width: 0; padding: 14px 14px 18px; overflow: hidden; background: linear-gradient(180deg, #ffffff 0%, #fcfefd 100%); }
.prod-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.prod-card { background: var(--card); border-radius: var(--r); padding: 10px; display: flex; flex-direction: column; gap: 8px; min-width: 0; box-shadow: var(--shadow); border: 1px solid #edf3f0; transition: transform .18s, box-shadow .18s, border-color .18s; cursor: pointer; position: relative; animation: cardIn .35s ease both; animation-delay: calc(var(--i, 0) * 35ms); overflow: hidden; }
.prod-card::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 1px; background: linear-gradient(90deg, transparent, rgba(43,183,159,.5), transparent); opacity: 0; transition: opacity .18s; }
@keyframes cardIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.prod-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #cfe7de; }
.prod-card:hover::before { opacity: 1; }
.prod-thumb { width: 100%; height: 94px; flex: none; border-radius: 11px; overflow: hidden; display: grid; place-items: center; background: radial-gradient(circle at 30% 25%, #e6f6f0, #bfe3d8); position: relative; }
.prod-thumb::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 50% -10%, rgba(255,255,255,.35), transparent 60%); pointer-events: none; }
.prod-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.prod-card:hover .prod-thumb img { transform: scale(1.06); }
.prod-thumb .ph { font-size: 30px; }
.prod-tag { position: absolute; top: 6px; left: 6px; background: linear-gradient(135deg, #ff9d4b, #ef6c22); color: #fff; font-size: 9px; font-weight: 700; padding: 2px 7px; border-radius: 6px; box-shadow: 0 2px 6px rgba(239,108,34,.3); letter-spacing: .3px; }
.prod-info { flex: 1; min-width: 0; width: 100%; display: flex; flex-direction: column; }
@media (min-width: 900px) {
  .prod-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .prod-card { flex-direction: row; align-items: flex-start; gap: 12px; padding: 12px; }
  .prod-thumb { width: 64px; height: 64px; }
  .prod-thumb .ph { font-size: 26px; }
  .prod-tag { font-size: 8px; padding: 1px 5px; }
  .prod-go { display: none; }
}
.prod-name { font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prod-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin-top: 6px; min-height: 18px; }
.prod-stock { display: inline-block; margin: 0; white-space: nowrap; font-size: 10.5px; line-height: 1.5; color: var(--amber); background: var(--amber-l); padding: 2px 8px; border-radius: 5px; }
.prod-price { margin-top: auto; padding: 7px 10px 0; display: flex; align-items: center; flex-wrap: nowrap; gap: 6px; white-space: nowrap; background: linear-gradient(180deg, transparent, rgba(253,241,222,.55)); border-radius: 10px; }
.prod-price small { font-size: 12px; }
.pp-lbl { flex: none; line-height: 1; font-size: 10.5px; color: #b17a2e; font-weight: 600; }
.prod-price b { color: #c9760c; font-weight: 800; font-size: 19px; line-height: 1.1; letter-spacing: -.4px; text-shadow: 0 1px 0 rgba(255,255,255,.8); }
.prod-go { display: flex; align-items: center; justify-content: center; gap: 4px; margin-top: 2px; padding: 8px; border-radius: 9px; background: linear-gradient(135deg, #17a68f, #0d7a68); color: #fff; font-size: 11.5px; font-weight: 700; box-shadow: 0 3px 9px rgba(18,138,120,.22); transition: filter .16s; }
.prod-card:hover .prod-go { filter: brightness(1.08); }
.prod-go span { font-size: 14px; line-height: 1; }
.empty-box { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty-ill { font-size: 42px; opacity: .35; }

/* ---------- 首页平台化板块 ---------- */
.home-extra { margin: 18px 12px 0; }
.sec-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 11px; }
.sec-head b { display: inline-flex; align-items: center; gap: 7px; font-size: 15px; font-weight: 800; letter-spacing: .3px; }
.sec-head b::before { content: ''; width: 3px; height: 14px; border-radius: 3px; background: linear-gradient(180deg, #2bb79f, #0d7569); }
.sec-head span { font-size: 11.5px; color: var(--teal); cursor: pointer; }
.flow-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; background: var(--card); border-radius: var(--r); padding: 16px 8px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.fs-item { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 5px; position: relative; }
.fs-item i { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, #24b29b, #0d7569); color: #fff; display: grid; place-items: center; font-style: normal; font-size: 13px; font-weight: 800; box-shadow: 0 3px 10px rgba(21,143,126,.32), inset 0 1px 1px rgba(255,255,255,.4); position: relative; z-index: 1; }
.fs-item:not(:last-child)::after { content: ''; position: absolute; top: 16px; left: calc(50% + 22px); width: calc(100% - 44px); height: 1px; background: repeating-linear-gradient(90deg, #b9ddd1 0 4px, transparent 4px 8px); }
.fs-item b { font-size: 11.5px; }
.fs-item span { font-size: 9.5px; color: var(--muted); }
.guard-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.gd-item { background: var(--card); border: 1px solid #edf3f0; border-radius: 14px; padding: 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 3px; }
.gd-ico { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; color: #fff; font-size: 16px; margin-bottom: 6px; box-shadow: inset 0 1px 1px rgba(255,255,255,.4), 0 3px 8px rgba(16,60,50,.12); }
.g1 { background: linear-gradient(135deg, #4ac4ab, #12826f); } .g2 { background: linear-gradient(135deg, #7cb6ee, #3f78c8); }
.g3 { background: linear-gradient(135deg, #f3c46c, #dc8f24); } .g4 { background: linear-gradient(135deg, #b4a4ee, #7a63cc); }
.gd-item b { font-size: 13px; }
.gd-item small { font-size: 10.5px; color: var(--muted); }
.help-entries { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.help-entries button { position: relative; background: var(--card); border: 1px solid #edf3f0; border-radius: 14px; padding: 14px 8px; display: flex; flex-direction: column; align-items: center; gap: 4px; box-shadow: var(--shadow); transition: .15s; }
.help-entries button:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.he-ico { width: 34px; height: 34px; border-radius: 11px; background: linear-gradient(145deg, #e4f5ee, #cdeade); color: var(--teal-d); display: grid; place-items: center; font-size: 17px; font-weight: 800; box-shadow: inset 0 1px 1px rgba(255,255,255,.9); }
.help-entries b { font-size: 11.5px; }
.help-entries small { font-size: 9.5px; color: var(--muted); }
.help-entries i { position: absolute; right: 8px; top: 7px; font-style: normal; color: #b8c7c1; font-size: 14px; }
.home-foot { text-align: center; padding: 28px 20px 18px; color: #8fa39b; }
.foot-brand { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--ink); margin-bottom: 8px; font-size: 14px; }
.brand-mark.sm { width: 26px; height: 26px; border-radius: 8px; font-size: 13px; background: linear-gradient(145deg, #1aa08c, #0d7569); color: #fff; box-shadow: none; }
.home-foot p { margin: 4px 0; font-size: 11px; }
.foot-links { color: var(--teal); }
.foot-links span { cursor: pointer; }
.foot-links span:hover { text-decoration: underline; }
.foot-copy { font-size: 10px; opacity: .8; margin-top: 10px; }
@media (min-width: 900px) {
  .home-extra { margin: 22px 16px 0; }
  .guard-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- 简单页头 ---------- */
.simple-head { padding: 22px 18px 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.simple-head h2 { display: inline-flex; align-items: center; gap: 8px; margin: 0; font-size: 21px; font-weight: 800; letter-spacing: .3px; }
.simple-head h2::before { content: ''; width: 4px; height: 18px; border-radius: 4px; background: linear-gradient(180deg, #2bb79f, #0d7569); }
.head-sub { margin: 3px 0 0; font-size: 11.5px; color: var(--muted); font-weight: 400; }
.head-chip { background: var(--teal-l); color: var(--teal-d); font-size: 11px; font-weight: 700; padding: 5px 11px; border-radius: 20px; white-space: nowrap; }
.head-refresh { width: 36px; height: 36px; flex: none; border: 1px solid var(--line); background: var(--card); border-radius: 11px; color: var(--teal); font-size: 19px; box-shadow: var(--shadow); transition: transform .25s, background .15s; }
.head-refresh:hover { transform: rotate(60deg); background: var(--teal-l); }

/* ---------- 统计页 ---------- */
.stats-body, .orders-body { padding: 0 16px 20px; }
.seg { display: flex; background: #e9f0ed; border-radius: 11px; padding: 4px; gap: 4px; margin-bottom: 14px; }
.seg button { flex: 1; border: 0; background: transparent; padding: 8px 3px; border-radius: 8px; font-size: 12.5px; color: #64766f; transition: .15s; white-space: nowrap; }
.seg button.active { background: #fff; color: var(--teal-d); font-weight: 700; box-shadow: 0 1px 5px rgba(0,0,0,.07); }
.seg-count { display: inline-block; margin-left: 3px; min-width: 15px; padding: 0 4px; border-radius: 9px; background: #d8e8e2; color: #4a6b61; font-size: 9.5px; font-weight: 700; line-height: 15px; }
.seg button.active .seg-count { background: var(--teal-l); color: var(--teal-d); }
.total-card { background: radial-gradient(120% 90% at 8% 0%, rgba(255,255,255,.14), transparent 50%), linear-gradient(150deg, #1aa78f, #0b6d5e); color: #fff; border-radius: var(--r); padding: 20px; position: relative; overflow: hidden; box-shadow: 0 8px 22px rgba(11,109,94,.24); }
.total-card::after { content: ''; position: absolute; width: 150px; height: 150px; border-radius: 50%; background: rgba(255,255,255,.08); right: -50px; top: -70px; }
.total-card::before { content: ''; position: absolute; width: 90px; height: 90px; border-radius: 50%; border: 14px solid rgba(255,255,255,.05); right: 26px; bottom: -46px; }
.total-lbl { font-size: 12px; opacity: .85; }
.total-val { font-size: 33px; font-weight: 800; margin: 4px 0; letter-spacing: -.5px; }
.total-sub { font-size: 12px; opacity: .85; }
.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 14px 0; }
.mini-stat { background: var(--card); border-radius: 12px; padding: 13px 11px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.mini-stat .ms-val { font-size: 19px; font-weight: 800; color: var(--teal-d); }
.mini-stat .ms-lbl { font-size: 11px; color: var(--muted); margin-top: 2px; }
.rank-card { background: var(--card); border-radius: var(--r); padding: 16px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.rank-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 14px; }
.rank-head span { font-size: 11px; color: var(--muted); }
.rank-row { margin: 12px 0; }
.rank-top { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 5px; gap: 8px; }
.rank-top > span:first-child { display: flex; align-items: center; gap: 6px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-no { width: 17px; height: 17px; flex: none; border-radius: 5px; background: var(--teal-l); color: var(--teal-d); display: grid; place-items: center; font-style: normal; font-size: 10px; font-weight: 800; }
.rank-bar { height: 8px; background: #eef3f1; border-radius: 6px; overflow: hidden; }
.rank-bar i { display: block; height: 100%; background: linear-gradient(90deg, #2bb79f, #0d7569); border-radius: 6px; transition: width .5s ease; }
.rank-empty { color: var(--muted); font-size: 13px; text-align: center; padding: 24px 0; }

/* ---------- 订单页 ---------- */
.order-search { display: flex; align-items: center; gap: 8px; background: var(--card); border-radius: 12px; padding: 8px 10px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.order-search span { color: var(--teal); font-size: 20px; }
.order-search input { flex: 1; border: 0; outline: 0; font-size: 13.5px; min-width: 0; }
.order-tip { font-size: 11.5px; color: var(--muted); margin: 8px 2px 14px; }
.order-list { display: flex; flex-direction: column; gap: 12px; }
.order-card { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); border: 1px solid #edf3f0; overflow: hidden; animation: cardIn .35s ease both; animation-delay: calc(var(--i, 0) * 45ms); transition: box-shadow .18s; }
.order-card:hover { box-shadow: 0 8px 22px rgba(16,60,50,.12); }
.oc-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; background: #f8fbfa; border-bottom: 1px solid var(--line); }
.oc-head-l { font-size: 11.5px; color: var(--muted); font-weight: 600; letter-spacing: .5px; }
.oc-top { display: flex; align-items: center; gap: 11px; padding: 14px; }
.oc-thumb { width: 46px; height: 46px; border-radius: 10px; background: linear-gradient(145deg,#d8efe8,#bfe3d8); display: grid; place-items: center; overflow: hidden; font-size: 20px; flex: none; }
.oc-thumb img { width: 100%; height: 100%; object-fit: cover; }
.oc-main { flex: 1; min-width: 0; }
.oc-name { font-weight: 700; font-size: 14px; }
.oc-meta { font-size: 11px; color: var(--muted); margin-top: 3px; }
.oc-amt { margin-left: auto; font-weight: 800; color: var(--amber); font-size: 17px; white-space: nowrap; }
.oc-no { display: flex; align-items: center; gap: 8px; padding: 0 14px; font-size: 11px; color: var(--muted); }
.oc-no > span { word-break: break-all; }
.copy-mini { border: 0; background: var(--teal-l); color: var(--teal-d); border-radius: 6px; font-size: 10px; font-weight: 700; padding: 3px 9px; flex: none; transition: .15s; }
.copy-mini:hover { background: #d3ece4; }
.oc-time { padding: 7px 14px 0; font-size: 11px; color: var(--muted); }
.steps { display: flex; justify-content: space-between; margin: 14px; padding-top: 13px; border-top: 1px dashed var(--line); position: relative; }
.steps::before { content: ''; position: absolute; left: 8%; right: 8%; top: 18px; height: 2px; background: #e6ece9; }
.step { position: relative; text-align: center; flex: 1; font-size: 10px; color: var(--muted); }
.step i { display: block; width: 12px; height: 12px; border-radius: 50%; background: #d8e2de; margin: 0 auto 5px; position: relative; z-index: 1; }
.step.done { color: var(--teal-d); font-weight: 600; }
.step.done i { background: var(--teal); }
.step.cancel i { background: var(--red); }
.step.cancel { color: var(--red); }

/* ---------- 加载骨架 / 状态占位 ---------- */
.sk { background: linear-gradient(90deg, #eaf1ee 25%, #f7faf9 50%, #eaf1ee 75%); background-size: 200% 100%; animation: shimmer 1.3s linear infinite; border-radius: 6px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.sk-card { background: var(--card); border: 1px solid #edf3f0; border-radius: var(--r); padding: 14px; box-shadow: var(--shadow); }
.sk-row { display: flex; align-items: center; gap: 11px; margin-bottom: 12px; }
.sk-thumb { width: 46px; height: 46px; border-radius: 10px; flex: none; }
.sk-thumb.big { width: 100%; height: 92px; border-radius: 11px; margin-bottom: 12px; }
.sk-col { flex: 1; display: flex; flex-direction: column; gap: 7px; }
.sk-l { height: 11px; margin: 6px 0; }
.sk-l.sk-sm { height: 9px; }
.sk-amt { width: 56px; height: 18px; flex: none; }
.sk-prod { display: flex; flex-direction: column; gap: 5px; }
.sk-tr td { padding: 13px 12px; }
.sk-tr .sk-l { margin: 0; }
.grid-full { grid-column: 1 / -1; }
.state-box { text-align: center; padding: 34px 18px; background: var(--card); border: 1px dashed #d7e6e0; border-radius: var(--r); }
.state-ill { width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 16px; background: var(--teal-l); color: var(--teal); display: grid; place-items: center; font-size: 26px; }
.state-title { font-size: 14px; font-weight: 700; color: var(--ink); }
.state-desc { font-size: 11.5px; color: var(--muted); margin: 6px 0 16px; line-height: 1.65; }
.state-box.in-table { border: 0; background: transparent; padding: 18px; }
.stat-full { grid-column: 1 / -1; }

/* ---------- 底部导航 ---------- */
.bottom-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 520px; background: rgba(255,255,255,.96); backdrop-filter: blur(10px); border-top: 1px solid var(--line); display: flex; padding: 7px 0 calc(7px + env(safe-area-inset-bottom)); z-index: 30; box-shadow: 0 -3px 16px rgba(0,0,0,.05); }
.bn { flex: 1; border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; color: #8b9994; padding: 4px 0; transition: color .15s; position: relative; }
.bn-ico { font-size: 20px; line-height: 1; transition: transform .15s; }
.bn.active { color: var(--teal-d); font-weight: 700; }
.bn.active .bn-ico { transform: translateY(-1px) scale(1.08); }
.bn.active::before { content: ''; position: absolute; top: -7px; width: 18px; height: 3px; border-radius: 0 0 3px 3px; background: var(--teal); }
@media (min-width: 900px) { .bottom-nav { max-width: 960px; } }
/* 回到顶部：固定在内容区右下角，不遮挡底部导航 */
.back-top { position: fixed; bottom: calc(88px + env(safe-area-inset-bottom)); right: max(16px, calc((100vw - 520px) / 2 + 16px)); width: 42px; height: 42px; border: 1px solid #d6e9e2; border-radius: 50%; background: rgba(255,255,255,.95); color: var(--teal-d); font-size: 20px; font-weight: 800; box-shadow: var(--shadow-lg); z-index: 25; display: grid; place-items: center; backdrop-filter: blur(6px); padding: 0; }
.back-top:active { transform: scale(.92); }
@media (min-width: 900px) { .back-top { right: max(16px, calc((100vw - 960px) / 2 + 16px)); } }

/* ---------- 登录 / 个人中心 ---------- */
.admin-auth { display: flex; justify-content: center; padding: 40px 16px; }
.auth-card { width: min(400px, 100%); background: var(--card); border-radius: var(--r); padding: 26px; box-shadow: var(--shadow-lg); border: 1px solid #edf3f0; }
.auth-card h2 { margin: 0 0 18px; font-size: 20px; text-align: center; font-weight: 800; }
.auth-tabs { display: flex; gap: 5px; background: #eef3f1; padding: 4px; border-radius: 10px; margin-bottom: 20px; }
.auth-tab { flex: 1; border: 0; background: transparent; padding: 8px; border-radius: 7px; color: var(--muted); font-size: 13.5px; }
.auth-tab.active { background: #fff; color: var(--teal-d); font-weight: 700; box-shadow: 0 1px 4px rgba(0,0,0,.07); }
.field { display: block; margin-bottom: 16px; }
.label { display: block; font-size: 12.5px; font-weight: 600; margin-bottom: 7px; color: #3f504a; }
.field-hint { font-size: 11.5px; color: var(--muted); margin-top: 6px; }
.avatar-edit-row { display: flex; align-items: center; gap: 14px; }
.avatar-edit-preview { width: 76px; height: 76px; flex: none; border: 2px solid var(--line); border-radius: 50%; display: grid; place-items: center; overflow: hidden; background: #f0f6f4; font-size: 30px; color: var(--teal); }
.avatar-edit-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=search], textarea, select {
  width: 100%; border: 1px solid var(--line); background: #f8fbfa; border-radius: 10px; padding: 10px 12px; font-size: 14px; color: var(--ink); outline: 0; transition: .15s;
}
input:focus, textarea:focus, select:focus { border-color: var(--teal); background: #fff; box-shadow: 0 0 0 3px rgba(18,138,120,.11); }
textarea { resize: vertical; line-height: 1.6; }
.inline-field { display: flex; gap: 8px; margin-bottom: 16px; }
.inline-field input { flex: 1; }
.inline-field .btn { width: auto; white-space: nowrap; }
.link-btn { border: 0; background: transparent; color: var(--teal); font-size: 13px; }
.link-btn.center { display: block; margin: 12px auto 0; }
.admin-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 24px 18px 20px; background: linear-gradient(140deg, #128a78 0%, #0b6a5c 58%, #0a4f46 100%); color: #fff; border-radius: 0 0 22px 22px; position: relative; overflow: hidden; margin-bottom: 14px; box-shadow: 0 10px 24px rgba(10,90,76,.18); }
.admin-bar::before { content: ''; position: absolute; width: 200px; height: 200px; border-radius: 50%; background: rgba(255,255,255,.07); top: -110px; right: -50px; }
.admin-bar > * { position: relative; z-index: 1; }
.admin-bar-l h2 { margin: 0; font-size: 20px; font-weight: 800; letter-spacing: .4px; }
.admin-bar-l p { margin: 4px 0 0; font-size: 11.5px; opacity: .78; }
.admin-bar .btn-ghost { background: rgba(255,255,255,.16); color: #fff; border: 1px solid rgba(255,255,255,.24); }
.admin-bar .btn-ghost:hover { background: rgba(255,255,255,.26); }
.uc-body { padding: 4px 16px 24px; }
.uc-account { display: flex; align-items: center; gap: 12px; background: linear-gradient(150deg,#1aa08c,#0e786b); color: #fff; border-radius: var(--r); padding: 16px; margin-bottom: 14px; }
.uc-avatar { width: 44px; height: 44px; flex: none; border-radius: 50%; background: rgba(255,255,255,.2); display: grid; place-items: center; font-size: 22px; cursor: pointer; overflow: hidden; }
.uc-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.uc-email { font-size: 15px; font-weight: 700; word-break: break-all; }
.uc-sub { font-size: 11.5px; opacity: .85; margin-top: 3px; }
.uc-hint { font-size: 12px; color: var(--muted); margin: -4px 0 14px; }
.uc-hero { display: flex; align-items: center; gap: 14px; background: linear-gradient(135deg,#169b86,#0b6a5c); color: #fff; margin: 4px 12px 12px; border-radius: 18px; padding: 20px 18px; box-shadow: 0 8px 24px rgba(11,106,92,.22); position: relative; overflow: hidden; }
.uc-hero::after { content: ''; position: absolute; width: 160px; height: 160px; border-radius: 50%; background: rgba(255,255,255,.07); right: -60px; top: -80px; }
.uc-hero > * { position: relative; z-index: 1; }
.uc-hero .uc-avatar { width: 56px; height: 56px; background: rgba(255,255,255,.22); border: 2px solid rgba(255,255,255,.5); font-size: 28px; }
.uc-hero-main { flex: 1; min-width: 0; }
.uc-nick { font-size: 17px; font-weight: 800; word-break: break-all; }
.uc-idline { font-size: 11px; opacity: .85; margin-top: 4px; letter-spacing: .5px; }
.uc-credit { text-align: center; background: rgba(255,255,255,.16); border-radius: 12px; padding: 8px 12px; }
.uc-credit-val { font-size: 22px; font-weight: 800; line-height: 1; }
.uc-credit-lbl { font-size: 10px; opacity: .9; margin-top: 4px; }
.uc-assets { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 12px 12px; }
.uc-asset { text-align: left; background: linear-gradient(150deg,#e8f7f2,#d9f0e8); border: 1px solid #cfe9df; border-radius: 14px; padding: 14px 16px; transition: .15s; }
.uc-asset:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.uc-asset-lbl { font-size: 11.5px; color: #4a7d71; }
.uc-asset-val { font-size: 22px; font-weight: 800; color: var(--teal-d); margin-top: 6px; }
.uc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 0 12px 12px; background: var(--card); border-radius: 14px; padding: 16px 8px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.uc-gi { border: 0; background: transparent; display: flex; flex-direction: column; align-items: center; gap: 7px; font-size: 10.5px; color: #43564f; padding: 4px 0; }
.uc-gi-ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 19px; color: #fff; font-weight: 700; }
.uc-i-profile{background:linear-gradient(135deg,#7ecfe8,#42a7d8)} .uc-i-pay{background:linear-gradient(135deg,#f3c26b,#e39b2c)} .uc-i-order{background:linear-gradient(135deg,#7bd9bb,#35b48a)} .uc-i-notice{background:linear-gradient(135deg,#b6a8f0,#7d6ad6)} .uc-i-service{background:linear-gradient(135deg,#8fd0ef,#4aa7d6)}
.uc-menu { margin: 0 12px 12px; background: var(--card); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.uc-mi { width: 100%; display: flex; align-items: center; gap: 12px; border: 0; background: transparent; padding: 15px 16px; border-bottom: 1px solid #f0f4f2; text-align: left; transition: .15s; }
.uc-mi:hover { background: #f8fbfa; }
.uc-mi:last-child { border-bottom: 0; }
.uc-mi-ico { font-size: 18px; width: 24px; text-align: center; }
.uc-mi-txt { flex: 1; font-size: 13.5px; color: #263b34; }
.uc-mi em { font-size: 11.5px; color: var(--muted); font-style: normal; }
.uc-mi i { font-size: 18px; color: #b8c7c1; font-style: normal; }
.uc-admin-entry { display: block; width: calc(100% - 24px); margin: 0 12px 10px; border: 1px dashed var(--teal); background: var(--teal-ll); color: var(--teal-d); border-radius: 12px; padding: 12px; font-size: 13px; font-weight: 700; }
.uc-logout { display: block; width: calc(100% - 24px); margin: 0 12px; border: 0; background: var(--card); color: #7a5a5a; border-radius: 12px; padding: 14px; font-size: 13.5px; box-shadow: var(--shadow); border: 1px solid #edf3f0; }
.uc-copyright { text-align: center; font-size: 11px; color: #a9bbb4; margin: 20px 0 4px; }
.uc-orders-list { max-height: 55vh; overflow: auto; }
.uc-order-card { border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 10px; background: #fbfdfc; }
.uc-order-top { display: flex; align-items: center; gap: 10px; }
.uc-order-name { flex: 1; font-size: 13px; font-weight: 700; }
.uc-order-no { font-size: 10.5px; color: var(--muted); margin-top: 4px; }
.uc-order-amt { font-size: 14px; font-weight: 800; color: var(--amber); }
.admin-tabs { display: flex; gap: 6px; overflow-x: auto; padding: 0 14px 14px; scrollbar-width: none; }
.admin-tabs::-webkit-scrollbar { display: none; }
.admin-tab { flex: none; border: 1px solid #e2ebe7; background: #fff; padding: 8px 16px; border-radius: 10px; font-size: 12.5px; color: #5b6f68; transition: .15s; box-shadow: 0 1px 3px rgba(16,60,50,.04); }
.admin-tab:hover { border-color: #cfe3dc; color: var(--teal-d); }
.admin-tab.active { background: linear-gradient(135deg, #149b86, #0d7a6a); color: #fff; border-color: transparent; font-weight: 700; box-shadow: 0 4px 12px rgba(18,138,120,.26); }
.atab-pane { padding: 0 12px 20px; }
.card { background: var(--card); border-radius: var(--r); padding: 16px; box-shadow: var(--shadow); margin-bottom: 14px; border: 1px solid #edf3f0; }
.card-title { font-size: 14px; font-weight: 700; margin-bottom: 12px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-head .card-title { margin: 0; }
.card-sub { font-size: 11px; color: var(--muted); }
.card-link { border: 0; background: transparent; color: var(--teal); font-size: 11.5px; padding: 0; }
.card-link:hover { text-decoration: underline; }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
.stat { position: relative; background: var(--card); border-radius: 14px; padding: 15px 14px; box-shadow: var(--shadow); display: flex; align-items: center; gap: 12px; border: 1px solid #edf3f0; overflow: hidden; transition: .16s; }
.stat::after { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--teal); opacity: .85; }
.stat:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.stat .ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; flex: none; }
.stat .val { font-size: 21px; font-weight: 800; line-height: 1.1; letter-spacing: -.3px; }
.stat .lbl { font-size: 11px; color: var(--muted); margin-top: 2px; }
.s-total::after { background: var(--teal); } .s-pending::after { background: var(--amber); }
.s-done::after { background: #2a9d5b; } .s-amt::after { background: var(--blue); }
.s-total .ico{background:var(--teal-l);color:var(--teal)} .s-pending .ico{background:var(--amber-l);color:var(--amber)} .s-done .ico{background:#e5f6ec;color:#2a9d5b} .s-amt .ico{background:var(--blue-l);color:var(--blue)}
.quick-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- 后台概览 ---------- */
.ov-grid { display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 760px) { .ov-grid { grid-template-columns: 1.15fr .85fr; gap: 14px; } .stats { grid-template-columns: repeat(4, 1fr); } }
.ov-card { margin-bottom: 14px; }
.trend { display: flex; align-items: flex-end; gap: 7px; height: 132px; padding-top: 8px; }
.tr-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; }
.tr-bar { width: 100%; max-width: 34px; max-height: calc(100% - 24px); border-radius: 7px 7px 4px 4px; background: linear-gradient(180deg, #2fbba3, #12836f); min-height: 4px; position: relative; transition: height .45s ease; box-shadow: 0 2px 6px rgba(18,131,111,.18); }
.tr-bar.zero { background: #e7efec; box-shadow: none; }
.tr-bar span { position: absolute; top: -17px; left: 50%; transform: translateX(-50%); font-size: 10px; color: #4a6b61; font-weight: 700; }
.tr-lbl { font-size: 9.5px; color: var(--muted); white-space: nowrap; }
.todo-list { display: flex; flex-direction: column; gap: 6px; }
.todo-row { display: flex; align-items: center; gap: 10px; width: 100%; border: 1px dashed #e3ece8; background: #fbfdfc; border-radius: 10px; padding: 9px 11px; font-size: 12.5px; color: #33473f; text-align: left; transition: .15s; }
.todo-row:hover { background: #f3faf7; border-color: #cfe3dc; }
.td-ico { width: 26px; height: 26px; flex: none; border-radius: 8px; display: grid; place-items: center; font-size: 13px; background: var(--teal-l); color: var(--teal-d); }
.td-ico.warn { background: var(--amber-l); color: var(--amber); }
.td-ico.blue { background: var(--blue-l); color: var(--blue); }
.td-txt { flex: 1; min-width: 0; }
.td-txt b { float: right; font-size: 14px; color: var(--teal-d); }
.todo-row i, .recent-row i { font-style: normal; color: #b8c7c1; font-size: 15px; }
.recent-list { display: flex; flex-direction: column; }
.recent-row { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; border-bottom: 1px dashed #eef3f1; background: transparent; padding: 10px 2px; text-align: left; font-size: 12.5px; transition: .15s; }
.recent-row:last-child { border-bottom: 0; }
.recent-row:hover { background: #fafdfc; }
.rc-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: #263b34; }
.rc-name em { font-style: normal; font-weight: 400; color: var(--muted); font-size: 10.5px; margin-left: 6px; }
.rc-amt { color: var(--amber); font-weight: 800; }
.rc-time { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.mix-bar { display: flex; height: 11px; border-radius: 7px; overflow: hidden; background: #eef3f1; margin-bottom: 12px; }
.mix-bar i { display: block; height: 100%; transition: width .5s ease; }
.mix-unused { background: linear-gradient(90deg,#f0bb63,#dc9326); }
.mix-used { background: linear-gradient(90deg,#4fc39b,#219a6e); }
.mix-disabled { background: #c3cdc9; }
.mix-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 11.5px; color: #52665f; }
.mix-legend span { display: flex; align-items: center; gap: 6px; }
.mix-legend b { color: var(--ink); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot.unused { background: #dc9326; } .dot.used { background: #219a6e; } .dot.disabled { background: #b7c2be; }
.card-mix { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.mix-chip { display: flex; align-items: center; gap: 6px; background: #f6fbf9; border: 1px solid #e6f0ec; border-radius: 9px; padding: 7px 11px; font-size: 11.5px; color: #4d635b; }
.mix-chip b { font-size: 14px; color: var(--teal-d); }

/* ---------- 批量操作条 / 勾选列 ---------- */
.batch-bar { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; background: #eefaf5; border: 1px solid #cfeade; border-radius: 11px; padding: 9px 11px; margin-bottom: 11px; animation: modalIn .18s ease; }
.bb-info { font-size: 12px; color: #3f5c53; margin-right: 2px; }
.bb-info b { color: var(--teal-d); font-size: 13px; }
.th-cb { width: 34px; padding-left: 12px !important; }
.td-cb { width: 34px; padding-left: 12px !important; }
.th-cb input, .row-cb { width: 15px; height: 15px; accent-color: var(--teal); cursor: pointer; vertical-align: middle; }
tr.row-sel { background: #f4fbf8 !important; }
.code-cell { display: flex; align-items: center; gap: 6px; font-family: monospace; font-size: 11px; }
.code-cell .copy-mini { padding: 2px 7px; font-size: 9.5px; }
.import-area { min-height: 132px; font-family: ui-monospace, monospace; font-size: 12px; }
.import-stat { font-size: 11.5px; color: var(--muted); margin-top: 8px; line-height: 1.7; }
.import-stat b { color: var(--teal-d); }

/* ---------- 按钮 ---------- */
.btn { border: 0; border-radius: 10px; padding: 10px 16px; font-size: 13.5px; font-weight: 650; transition: .15s; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-block { width: 100%; }
.btn-sm { padding: 7px 12px; font-size: 12px; }
.btn-primary { background: linear-gradient(135deg, #149b86, #0d7a6a); color: #fff; box-shadow: 0 3px 9px rgba(18,138,120,.2); }
.btn-primary:hover:not(:disabled) { filter: brightness(1.06); transform: translateY(-1px); }
.btn-ghost { background: #eef3f1; color: #40544d; }
.btn-ghost:hover:not(:disabled) { background: #e2ece8; }
.btn-danger { background: var(--red-l); color: var(--red); }
.btn-danger:hover:not(:disabled) { background: #fbdada; }

/* ---------- 工具栏 / 表格 ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.toolbar .search { width: 200px; }
.toolbar select { width: auto; }
.toolbar-hint { margin-left: auto; font-size: 11px; color: var(--muted); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 11px; }
table { width: 100%; border-collapse: collapse; font-size: 12.5px; min-width: 560px; }
thead th { background: #f5faf8; text-align: left; padding: 11px 12px; color: #6b7f78; font-weight: 700; font-size: 11.5px; letter-spacing: .2px; white-space: nowrap; border-bottom: 1px solid var(--line); }
tbody td { padding: 10px 12px; border-bottom: 1px solid #f0f5f3; vertical-align: middle; }
tbody tr:nth-child(even) { background: #fcfefd; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #f4fbf8; }
.tbl-img { width: 42px; height: 42px; border-radius: 9px; background: linear-gradient(145deg,#d8efe8,#bfe3d8); display: grid; place-items: center; overflow: hidden; font-size: 18px; }
.tbl-img img { width: 100%; height: 100%; object-fit: cover; }
.badge { display: inline-block; padding: 3px 9px; border-radius: 20px; font-size: 11px; font-weight: 650; white-space: nowrap; }
.b-pending{background:var(--amber-l);color:var(--amber)} .b-processing{background:var(--blue-l);color:var(--blue)} .b-completed{background:#e5f6ec;color:#2a9d5b} .b-cancelled{background:#eef0f0;color:#8b9994} .b-on{background:#e5f6ec;color:#2a9d5b} .b-off{background:#eef0f0;color:#8b9994}
.row-btns { display: flex; gap: 5px; flex-wrap: wrap; }
.icon-btn { border: 1px solid var(--line); background: #fff; border-radius: 7px; padding: 5px 8px; font-size: 11px; color: #5a6b65; transition: .15s; }
.icon-btn:hover { background: #f2f7f5; border-color: #cfe3dc; }
.icon-btn.del:hover { color: var(--red); border-color: #f2c9c9; background: var(--red-l); }
.empty-row td { text-align: center; color: var(--muted); padding: 34px; }
.legacy-notice { background: var(--teal-ll); border: 1px solid #d5ece4; color: #4a6b61; border-radius: 9px; padding: 10px 12px; font-size: 12px; margin-bottom: 12px; }

/* ---------- 分页 ---------- */
.pager { display: flex; align-items: center; justify-content: center; gap: 5px; margin-top: 14px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.pager button { border: 1px solid var(--line); background: #fff; border-radius: 7px; padding: 5px 10px; font-size: 12px; }
.pager button.active { background: var(--teal); color: #fff; border-color: var(--teal); }
.pager button:disabled { opacity: .45; }
.pager .pinfo { width: 100%; text-align: center; margin-top: 4px; }

/* ---------- 弹窗 ---------- */
.modal-mask { position: fixed; inset: 0; background: rgba(12,40,34,.52); backdrop-filter: blur(2px); z-index: 80; display: flex; align-items: flex-end; justify-content: center; }
@media (min-width: 700px) { .modal-mask { align-items: center; } }
.modal { background: #fff; width: 100%; max-width: 520px; border-radius: 20px 20px 0 0; padding: 22px 18px calc(22px + env(safe-area-inset-bottom)); max-height: 90vh; overflow-y: auto; animation: modalIn .22s ease; position: relative; }
@keyframes modalIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (min-width: 700px) { .modal { border-radius: 20px; } }
.modal h3 { margin: 0 0 4px; font-size: 18px; font-weight: 800; padding-right: 34px; }
.modal .modal-sub { margin: 0 0 18px; font-size: 12px; color: var(--muted); }
/* 弹窗右上角关闭按钮 */
.modal-close { position: absolute; top: 16px; right: 16px; width: 30px; height: 30px; border: 0; border-radius: 50%; background: #f0f5f2; color: #7b8a85; font-size: 13px; line-height: 1; display: grid; place-items: center; z-index: 2; transition: .15s; }
.modal-close:hover { background: var(--red-l); color: var(--red); transform: rotate(90deg); }
.modal-close:active { transform: scale(.9) rotate(90deg); }
@media (min-width: 700px) { .modal-close { top: 18px; right: 18px; } }
.modal-actions { display: flex; gap: 10px; margin-top: 12px; }
.modal-actions .btn { flex: 1; }
.qr-preview { width: 92px; height: 92px; border: 1px dashed var(--line); border-radius: 10px; display: grid; place-items: center; overflow: hidden; background: #f8fbfa; font-size: 11px; color: var(--muted); margin-top: 6px; }
.qr-preview img { width: 100%; height: 100%; object-fit: contain; }
.od-card-list { background: #f8fbfa; border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; max-height: 180px; overflow: auto; margin-bottom: 12px; }
.od-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.od-card-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px dashed #e3ece8; }
.od-card-row:last-child { border-bottom: 0; }
.od-card-row input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--teal); flex: none; cursor: pointer; }
.od-card-code { flex: 1; font-family: monospace; font-size: 12px; word-break: break-all; user-select: text; -webkit-user-select: text; cursor: text; }
.od-card-empty { font-size: 12px; color: var(--muted); padding: 6px 0; }
.pay-save-tip { background: var(--teal-ll); border: 1px solid #d5ece5; color: var(--teal-d); font-size: 12px; line-height: 1.5; border-radius: 9px; padding: 9px 11px; margin-bottom: 16px; }
.save-pay-row { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink); margin: 2px 0 16px; cursor: pointer; }
.save-pay-row input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--teal); cursor: pointer; flex: none; }
.file-input { display: none; }
/* 透明文件输入覆盖按钮：点击由 input 原生处理，绕开内嵌环境对 JS .click() 的拦截 */
.up-btn-wrap { position: relative; display: inline-flex; }
.up-btn-wrap .btn { position: relative; pointer-events: none; }
.file-cover { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; z-index: 2; }
.up-zone { position: relative; }
.up-zone .file-cover { border-radius: 14px; }
.prod-pick { display: flex; align-items: center; gap: 10px; background: var(--teal-ll); border-radius: 10px; padding: 8px; margin-bottom: 16px; }
.prod-pick .oc-thumb { width: 40px; height: 40px; }

/* ---------- 帮助中心内容 ---------- */
.help-body { max-height: 56vh; overflow: auto; margin-bottom: 6px; }
.help-cover { margin: -4px 0 14px; border-radius: 12px; overflow: hidden; background: var(--teal-ll); }
.help-cover img { width: 100%; max-height: 180px; object-fit: cover; display: block; }
/* 后台纯文本内容：固定样式自动排版，不需要在编辑框里写 HTML */
.pt-body { padding: 2px 0; }
.pt-line { position: relative; margin: 0 0 9px; padding: 9px 12px 9px 24px; background: #f7faf9; border: 1px solid #e6f0eb; border-radius: 10px; font-size: 13px; line-height: 1.8; color: #43564f; word-break: break-word; white-space: pre-wrap; }
.pt-line:last-child { margin-bottom: 0; }
.pt-line::before { content: ''; position: absolute; left: 11px; top: 18px; width: 5px; height: 5px; border-radius: 50%; background: var(--teal); }
.help-note { background: var(--teal-ll); border: 1px solid #d5ece5; color: var(--teal-d); font-size: 12.5px; line-height: 1.75; border-radius: 10px; padding: 11px 13px; margin-bottom: 12px; }
.help-item { border-bottom: 1px dashed var(--line); padding: 10px 2px; }
.help-item:last-child { border-bottom: 0; }
.help-item b { font-size: 13px; color: var(--ink); }
.help-item p { margin: 4px 0 0; font-size: 12px; color: var(--muted); line-height: 1.75; }
.help-qa { padding: 10px 0; border-bottom: 1px dashed var(--line); }
.help-qa:last-child { border-bottom: 0; }
.help-qa b { font-size: 12.5px; color: var(--teal-d); }
.help-qa p { margin: 5px 0 0; font-size: 12px; color: var(--muted); line-height: 1.75; }
.help-flow { display: flex; flex-direction: column; gap: 12px; }
.hf-step { display: flex; gap: 12px; align-items: flex-start; }
.hf-step i { width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--teal); color: #fff; display: grid; place-items: center; font-style: normal; font-size: 12px; font-weight: 800; }
.hf-step b { font-size: 13px; }
.hf-step p { margin: 3px 0 0; font-size: 12px; color: var(--muted); line-height: 1.65; }
.help-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.hg-item { background: #f8fbfa; border: 1px solid var(--line); border-radius: 11px; padding: 12px; }
.hg-item span { color: var(--teal); font-size: 15px; }
.hg-item b { display: block; font-size: 12.5px; margin: 4px 0 3px; }
.hg-item p { margin: 0; font-size: 11px; color: var(--muted); line-height: 1.6; }
.help-foot { margin-top: 14px; font-size: 10.5px; color: #a3b4ad; text-align: center; line-height: 1.6; }

/* ---------- Toast ---------- */
.toast-container { position: fixed; top: 16px; left: 50%; transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast { padding: 10px 18px; border-radius: 22px; color: #fff; font-size: 13px; font-weight: 500; box-shadow: 0 8px 24px rgba(0,0,0,.18); animation: tin .25s ease; transition: opacity .3s, transform .3s; max-width: 88vw; }
.toast.fade { opacity: 0; transform: translateY(-10px); }
.toast-info{background:#40544d} .toast-success{background:linear-gradient(135deg,#169b86,#0d7569)} .toast-error{background:var(--red)} .toast-warn{background:var(--amber)}
@keyframes tin { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }

/* ================= 图片上传 / 二维码识别 ================= */
.label .label-sub { font-weight: 400; color: var(--muted); font-size: 11.5px; }
.label em.req { color: var(--red); font-style: normal; margin-left: 2px; }
.up-zone { border: 1.5px dashed #bfe0d6; background: linear-gradient(180deg,#f7fcfa,#f1f9f6); border-radius: 14px; padding: 18px 14px; text-align: center; cursor: pointer; transition: .16s; outline: 0; }
.up-zone:hover, .up-zone:focus-visible { border-color: var(--teal); background: #effaf6; }
.up-zone.drag { border-color: var(--teal); background: #e7f7f1; box-shadow: 0 0 0 4px rgba(18,138,120,.1); }
.up-ico { width: 40px; height: 40px; margin: 0 auto 8px; border-radius: 12px; background: var(--teal-l); color: var(--teal-d); display: grid; place-items: center; font-size: 19px; font-weight: 700; }
.up-main { font-size: 13px; font-weight: 700; color: var(--teal-d); }
.up-sub { font-size: 11px; color: var(--muted); margin-top: 5px; line-height: 1.6; }
.up-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-top: 10px; }
.up-item { position: relative; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); background: #f7fbf9; aspect-ratio: 1; }
.up-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.up-item.is-fail { border-color: #f2c9c9; }
.up-rm { position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; border-radius: 50%; border: 0; background: rgba(18,34,30,.6); color: #fff; font-size: 13px; line-height: 1; display: grid; place-items: center; }
.up-rm:hover { background: var(--red); }
.up-tag { position: absolute; left: 0; right: 0; bottom: 0; font-size: 9.5px; text-align: center; padding: 2px 3px; background: rgba(10,107,92,.86); color: #fff; }
.up-tag.reading { background: rgba(217,134,24,.9); }
.up-tag.fail { background: rgba(214,75,75,.9); }
.count-bar { display: flex; align-items: center; gap: 14px; font-size: 12.5px; color: var(--muted); background: #f8fbfa; border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; margin-bottom: 14px; }
.count-bar b { color: var(--teal-d); font-size: 14px; }
.count-bar .cb-total { margin-left: auto; color: var(--ink); }
.count-bar .cb-total b { color: var(--amber); }

/* 开关 */
.sw-card { border: 1px solid var(--line); border-radius: 12px; background: #f9fcfb; overflow: hidden; }
.sw-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 11px 13px; border-bottom: 1px dashed #e3ece8; }
.sw-row:last-child { border-bottom: 0; }
.sw-txt b { display: block; font-size: 12.8px; }
.sw-txt span { display: block; font-size: 11px; color: var(--muted); line-height: 1.55; margin-top: 3px; }
.switch { position: relative; flex: none; width: 42px; height: 24px; display: inline-block; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 2; }
.switch i { position: absolute; inset: 0; background: #d6e2de; border-radius: 20px; transition: .18s; }
.switch i::after { content: ''; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; background: #fff; border-radius: 50%; box-shadow: 0 1px 3px rgba(0,0,0,.18); transition: .18s; }
.switch input:checked + i { background: var(--teal); }
.switch input:checked + i::after { transform: translateX(18px); }
.switch input:focus-visible + i { box-shadow: 0 0 0 3px rgba(18,138,120,.2); }

/* 商品列表标记 */
.ptags { display: flex; gap: 4px; margin-top: 4px; flex-wrap: wrap; }
.ptag { font-size: 9.5px; padding: 1px 6px; border-radius: 20px; background: var(--teal-l); color: var(--teal-d); font-weight: 700; }
.ptag.qr { background: #eaf0fc; color: #3358a8; }

/* 订单详情增强 */
.od-sync { font-size: 11px; font-weight: 500; color: var(--muted); margin-left: 8px; }
.od-info { font-size: 13px; line-height: 2; margin-bottom: 14px; }
.od-qr-block { margin-bottom: 14px; }
.od-empty-tip { font-size: 11.5px; color: var(--muted); }
.od-error { background: var(--red-l); color: #a63232; font-size: 12px; border-radius: 9px; padding: 9px 11px; margin-bottom: 12px; }
.od-card-loading { padding: 2px 0; }
.od-kind { flex: none; font-size: 9.5px; padding: 1px 5px; border-radius: 5px; background: var(--teal-l); color: var(--teal-d); font-weight: 700; }
.od-kind.qr { background: #eaf0fc; color: #3358a8; }
.od-img { flex: none; }

/* 图片查看器 */
.img-viewer { z-index: 120; align-items: center; }
.iv-box { background: #fff; border-radius: 16px; padding: 12px; max-width: min(92vw, 640px); max-height: 88vh; display: flex; flex-direction: column; gap: 10px; animation: modalIn .2s ease; }
.iv-box img { max-width: 100%; max-height: 70vh; object-fit: contain; border-radius: 10px; background: #f6faf8; }
.iv-bar { display: flex; gap: 10px; }
.iv-bar .btn { flex: 1; }
.prod-chan { display: inline-block; margin: 0; white-space: nowrap; font-size: 9.5px; font-weight: 700; line-height: 1.5; color: var(--teal-d); background: var(--teal-l); padding: 2px 7px; border-radius: 5px; }

/* ================= 安全 / 信誉 / 用户管理 ================= */

.uc-status-banner { margin: 10px 12px 0; padding: 10px 12px; border-radius: 11px; font-size: 12px; line-height: 1.6; background: var(--red-l); color: #a63232; border: 1px solid #f3cfcf; }
.uc-credit { border: 0; color: #fff; font: inherit; cursor: pointer; transition: .16s; }
.uc-credit:hover { background: rgba(255,255,255,.25); }

.user-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 12px; }
.user-summary .us { background: var(--card); border: 1px solid var(--line); border-radius: 13px; padding: 12px; box-shadow: var(--shadow); }
.user-summary .us b { display: block; font-size: 20px; color: var(--teal-d); }
.user-summary .us span { font-size: 11px; color: var(--muted); }
.user-summary .us.warn b { color: var(--amber); }
.user-summary .us.danger b { color: var(--red); }
@media (max-width: 640px) { .user-summary { grid-template-columns: repeat(2, 1fr); } }

.u-cell { display: flex; align-items: center; gap: 9px; min-width: 0; }
.u-avatar { width: 32px; height: 32px; flex: none; border-radius: 50%; background: var(--teal-l); color: var(--teal-d); display: grid; place-items: center; font-size: 13px; font-weight: 800; overflow: hidden; }
.u-avatar img { width: 100%; height: 100%; object-fit: cover; }
.u-name { min-width: 0; }
.u-name b { display: block; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.u-name span { display: block; font-size: 10.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rep-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 20px; background: var(--teal-l); color: var(--teal-d); }
.rep-pill.mid { background: var(--amber-l); color: #a86512; }
.rep-pill.low { background: var(--red-l); color: #a63232; }
.st-pill { font-size: 10.5px; font-weight: 700; padding: 3px 8px; border-radius: 20px; background: var(--teal-l); color: var(--teal-d); white-space: nowrap; }
.st-pill.restricted { background: var(--amber-l); color: #a86512; }
.st-pill.banned { background: var(--red-l); color: #a63232; }

.rep-hero { display: flex; align-items: center; gap: 16px; background: linear-gradient(150deg,#e9f7f2,#d9f0e8); border: 1px solid #cfe9df; border-radius: 15px; padding: 16px; }
.rep-score { font-size: 38px; line-height: 1; font-weight: 900; color: var(--teal-d); }
.rep-score small { font-size: 13px; font-weight: 600; }
.rep-meta b { font-size: 14px; }
.rep-meta p { margin: 5px 0 0; font-size: 11.5px; color: #4a7d71; line-height: 1.6; }
.rep-track { height: 7px; border-radius: 10px; background: #d7e8e1; overflow: hidden; margin: 12px 0 6px; }
.rep-track i { display: block; height: 100%; border-radius: 10px; background: linear-gradient(90deg,#2aa98f,#128a78); }
.rep-rules { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.rep-rule { border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; font-size: 11.5px; line-height: 1.6; }
.rep-rule b { display: block; font-size: 12px; }
.rep-rule.plus b { color: var(--teal); }
.rep-rule.minus b { color: var(--red); }
.rep-event { display: flex; align-items: center; gap: 10px; padding: 9px 2px; border-bottom: 1px dashed #e3ece8; font-size: 12px; }
.rep-event:last-child { border-bottom: 0; }
.rep-event .d { font-weight: 800; min-width: 34px; }
.rep-event .d.plus { color: var(--teal); }
.rep-event .d.minus { color: var(--red); }
.rep-event .r { flex: 1; color: var(--ink); }
.rep-event .t { color: var(--muted); font-size: 10.5px; }
.log-list { max-height: 340px; overflow: auto; }
.log-item { padding: 9px 2px; border-bottom: 1px dashed #e3ece8; font-size: 11.5px; line-height: 1.6; }
.log-item b { color: var(--teal-d); }
.log-item span { color: var(--muted); float: right; font-size: 10.5px; }

/* ============================================================
   后台增强 · 用户改密 / 卡密查重 / 视觉升级
   ============================================================ */
/* 管理员栏：渐变头部 + 徽标 */
.admin-bar { position: relative; background: linear-gradient(120deg,#0d7a6a,#149b86 60%,#17ac93); color: #fff; border-radius: 14px; padding: 18px 20px; margin: 12px; overflow: hidden; }
.admin-bar::after { content: '◈'; position: absolute; right: 22px; top: 6px; font-size: 92px; color: rgba(255,255,255,.09); line-height: 1; pointer-events: none; }
.admin-bar-l h2 { color: #fff; font-size: 18px; font-weight: 800; }
.admin-bar-l p { color: rgba(255,255,255,.82); font-size: 11.5px; margin-top: 3px; }
.admin-bar .btn-ghost { background: rgba(255,255,255,.18); color: #fff; }
.admin-bar .btn-ghost:hover { background: rgba(255,255,255,.28); }

/* 标签图标 */
.admin-tab { display: inline-flex; align-items: center; gap: 6px; }
.admin-tab .tab-ico { font-size: 13px; opacity: .85; }
.admin-tab.active .tab-ico { opacity: 1; }

/* 卡片标题左侧强调线 */
.card-head .card-title { padding-left: 10px; position: relative; }
.card-head .card-title::before { content: ''; position: absolute; left: 0; top: 2px; bottom: 2px; width: 3px; border-radius: 3px; background: linear-gradient(180deg,#2fbba3,#12836f); }

/* 用户管理汇总卡升级 */
.user-summary .us { position: relative; padding: 14px 14px 14px 16px; overflow: hidden; }
.user-summary .us::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--teal); }
.user-summary .us.warn::before { background: var(--amber); }
.user-summary .us.danger::before { background: var(--red); }
.user-summary .us b { font-size: 22px; letter-spacing: -.4px; }

/* 表格行操作按钮更紧凑精致 */
.row-btns .icon-btn { border-radius: 6px; padding: 4px 9px; font-size: 10.5px; }
.row-btns .upwd { color: var(--blue); border-color: #cfe0f0; }
.row-btns .upwd:hover { background: var(--blue-l); border-color: #a9cced; }

/* 改密提示 */
.pwd-tip { background: var(--amber-l); border: 1px solid #f3dfb8; color: #8a6316; border-radius: 9px; padding: 9px 11px; font-size: 11.5px; line-height: 1.6; margin-bottom: 14px; }

/* 卡密查重结果 */
.dup-list { max-height: 320px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; }
.dup-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-bottom: 1px dashed #e3ece8; font-size: 12px; }
.dup-item:last-child { border-bottom: 0; }
.dup-item b { font-family: ui-monospace, monospace; color: var(--ink); word-break: break-all; }
.dup-item span { flex: none; font-size: 11px; color: var(--red); font-weight: 700; background: var(--red-l); padding: 2px 8px; border-radius: 20px; }

/* 工具栏来源下拉稍宽 */
#legacyCardSource { min-width: 120px; }

/* 快速操作按钮悬停微动效 */
.quick-actions .btn { transition: transform .15s, box-shadow .15s; }
.quick-actions .btn:hover { transform: translateY(-2px); box-shadow: 0 5px 14px rgba(16,60,50,.1); }

/* ============================================================
   商品归属标签（卡密页）
   ============================================================ */
.prod-tag-cell { display: inline-block; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; background: linear-gradient(135deg,#eaf6f1,#dcf0e8); color: #0f6f5e; border: 1px solid #cee7dd; border-radius: 6px; padding: 2px 8px; font-size: 11px; font-weight: 600; }
.muted-dash { color: #b9c6c1; }

/* ============================================================
   移动端适配 · 后台表格转卡片 / 工具条 / 弹窗 / 头部
   ============================================================ */
/* app-shell 在 900px 以下固定 520px，故后台表格/工具条断点对齐 899px */
@media (max-width: 899px) {
  /* 管理员栏：缩小标题与水印，避免挤压 */
  .admin-bar { padding: 15px 14px; margin: 10px; }
  .admin-bar::after { font-size: 64px; right: 10px; top: 10px; }
  .admin-bar-l h2 { font-size: 16px; }
  .admin-bar-l p { font-size: 10.5px; }
  .admin-tabs { padding: 0 10px 12px; gap: 6px; }
  .admin-tab { padding: 8px 12px; font-size: 12px; }
  .atab-pane { padding: 0 10px 18px; }

  /* 工具条：搜索框占满一行，其余控件自适应 */
  .toolbar { gap: 7px; }
  .toolbar .search { flex: 1 1 100%; width: auto; }
  .toolbar select { flex: 1 1 calc(50% - 4px); min-width: 0; }
  .toolbar .btn { flex: 1 1 auto; }
  .toolbar-hint { flex-basis: 100%; margin-left: 0; text-align: right; }
  .batch-bar .btn { flex: 1 1 auto; }

  /* 表格 → 堆叠卡片：隐藏表头，每个 tr 成为独立卡片，单元格带字段标签 */
  .table-wrap { overflow: visible; border: 0; background: transparent; }
  .table-wrap table { min-width: 0; width: 100%; display: block; }
  .table-wrap thead { display: none; }
  .table-wrap tbody { display: block; }
  .table-wrap tbody tr {
    display: grid; grid-template-columns: 78px 1fr; align-items: start; column-gap: 8px; row-gap: 0;
    background: #fff; border: 1px solid var(--line); border-radius: 13px;
    padding: 12px; margin-bottom: 10px; box-shadow: var(--shadow); position: relative;
  }
  .table-wrap tbody tr.row-sel { border-color: #a9d9c9; background: #f6fcf9; }
  .table-wrap tbody td {
    border: 0; padding: 6px 0; text-align: left; min-width: 0; font-size: 12px;
    display: flex; align-items: center; gap: 6px; grid-column: 1 / -1;
  }
  .table-wrap tbody td::before {
    content: attr(data-label); flex: none; width: 72px; color: #8a9a94; font-size: 11px; font-weight: 600;
  }
  /* 勾选框列：放到卡片右上角，不带标签 */
  .table-wrap tbody td.td-cb {
    position: absolute; right: 12px; top: 12px; padding: 0;
    grid-column: auto; justify-self: end;
  }
  .table-wrap tbody td.td-cb::before { content: none; }
  .table-wrap tbody td:not(.td-cb):first-of-type { padding-top: 2px; padding-right: 26px; }
  .table-wrap tbody td.col-product::before { color: #0f6f5e; }
  .code-cell { flex-wrap: wrap; word-break: break-all; line-height: 1.5; }
  .code-cell span { word-break: break-all; }
  .table-wrap tbody td:last-child { border-top: 1px dashed #eef3f1; margin-top: 6px; padding-top: 10px; flex-wrap: wrap; }
  .table-wrap tbody td:last-child::before { align-self: center; }
  .row-btns { flex: 1; justify-content: flex-end; }
  .empty-row td { justify-content: center; padding: 30px 10px !important; }
  .empty-row td::before { content: none; }
  .sk-tr { display: grid; grid-template-columns: 1fr; gap: 8px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 10px; }
  .sk-tr td { display: block; width: 100% !important; }
}

/* 手机专属：看板压缩 / 弹窗适配 */
@media (max-width: 640px) {
  .stats { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .stat { padding: 12px 11px; gap: 9px; }
  .stat .ico { width: 36px; height: 36px; font-size: 16px; }
  .stat .val { font-size: 18px; }
  .modal { width: calc(100% - 20px) !important; max-height: 90vh; overflow-y: auto; padding: 18px 16px; }
  .modal h3 { font-size: 16px; }
  .modal-actions { flex-wrap: wrap; }
  .modal-actions .btn { flex: 1 1 auto; }
  /* 手机操作优化 */
  input[type=text], input[type=email], input[type=password], input[type=number], input[type=search], textarea, select { font-size: 16px; }
  .btn { min-height: 42px; }
  .btn-sm { min-height: 34px; }
  .modal-actions .btn { min-height: 44px; }
  .bn { padding: 8px 0; }
  .cat-item { padding: 15px 6px; }
  .field { margin-bottom: 14px; }
  .search-row { height: 46px; }
  .seg { overflow-x: auto; scrollbar-width: none; }
  .seg::-webkit-scrollbar { display: none; }
  .seg button { flex: 0 0 auto; padding: 9px 12px; font-size: 13px; }
  .prod-card:active, .order-card:active, .notice-item:active, .uc-gi:active, .uc-mi:active { transform: scale(.985); }
}

/* 窄屏手机（≤400px）：给商品卡片多留空间，价格不挤行 */
@media (max-width: 400px) {
  .cat-side { width: 80px; }
  .prod-area { padding: 12px 10px 16px; }
  .prod-grid { gap: 8px; }
  .prod-price b { font-size: 16px; }
  .pp-lbl { font-size: 10px; }
}

/* ============================================================
   平台公告页 / 未读角标 / 后台内容管理
   ============================================================ */
.bn { position: relative; }
.bn-dot { position: absolute; top: 4px; right: calc(50% - 18px); width: 8px; height: 8px; border-radius: 50%; background: var(--red, #e5484d); box-shadow: 0 0 0 2px #fff; }
.notice-body { padding: 12px; }
.notice-list { display: flex; flex-direction: column; gap: 10px; }
.notice-item { display: flex; align-items: flex-start; gap: 10px; width: 100%; text-align: left; background: #fff; border: 1px solid var(--line); border-radius: 13px; padding: 14px; box-shadow: var(--shadow); cursor: pointer; transition: transform .14s, box-shadow .14s; }
.notice-item:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(16,60,50,.1); }
.na-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: transparent; margin-top: 6px; }
.notice-item.unread .na-dot { background: var(--teal); }
.na-main { flex: 1; min-width: 0; }
.na-title { font-size: 13.5px; font-weight: 700; color: var(--ink); line-height: 1.5; }
.notice-item.unread .na-title { color: var(--teal); }
.na-pin { display: inline-block; font-size: 10px; font-weight: 700; color: #b26a00; background: #fff3d9; border: 1px solid #f3dfb8; border-radius: 5px; padding: 1px 6px; margin-right: 6px; vertical-align: 1px; }
.na-summary { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin-top: 5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.na-time { font-size: 10.5px; color: #a9b7b1; margin-top: 7px; }
.na-thumb { flex: none; width: 62px; height: 62px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.na-thumb img { width: 100%; height: 100%; object-fit: cover; }
.na-arrow { flex: none; color: #c3d0ca; font-size: 18px; align-self: center; }
.notice-empty { text-align: center; color: var(--muted); padding: 60px 0; font-size: 13px; }
.notice-modal { max-height: 88vh; overflow-y: auto; }

/* 后台内容管理卡片 */
.content-card { margin-bottom: 14px; }
.content-form { padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.content-form .field { display: flex; flex-direction: column; gap: 6px; }
.content-form .label { font-size: 12px; font-weight: 600; color: var(--muted); }
.content-form input, .content-form select, .content-form textarea { width: 100%; border: 1px solid var(--line); border-radius: 9px; padding: 9px 11px; font-size: 13px; font-family: inherit; background: #fff; color: var(--ink); }
.content-form textarea { resize: vertical; line-height: 1.7; font-family: inherit; font-size: 13px; }
.content-form .btn { align-self: flex-start; }
/* 页面内容配图控件 */
.sc-img-row { display: flex; align-items: center; gap: 14px; }
.sc-img-preview { width: 120px; height: 78px; flex: none; border: 1.5px dashed #cfe0d9; border-radius: 11px; background: #f8fbfa; display: grid; place-items: center; overflow: hidden; }
.sc-img-preview img { width: 100%; height: 100%; object-fit: cover; }
.sc-img-ph { font-size: 30px; color: #b9cdc5; }
.sc-img-ctrl { display: flex; flex-direction: column; align-items: flex-start; gap: 7px; }
.sc-img-ctrl .btn { align-self: flex-start; }
.an-opts { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; font-size: 12px; color: var(--ink); }
.an-opts label { display: inline-flex; align-items: center; gap: 6px; }

/* ============================================================
   后台格局精致化 · 控制台质感升级
   ============================================================ */
/* 管理栏：更柔和的光带与层次 */
.admin-bar { background: radial-gradient(120% 140% at 0% 0%, rgba(255,255,255,.14), transparent 55%), linear-gradient(115deg,#0d7a6a,#149b86 58%,#1ab09a); border: 1px solid rgba(255,255,255,.14); }
.admin-bar::after { content: '◈'; right: 26px; top: 2px; font-size: 100px; color: rgba(255,255,255,.1); }

/* 统计卡片：加大图标色块 + 柔和水印圆 + 更醒目数字 */
.stat { padding: 16px 15px; gap: 13px; min-height: 86px; }
.stat::before { content: ''; position: absolute; right: -16px; bottom: -22px; width: 78px; height: 78px; border-radius: 50%; background: var(--sw, var(--teal-l)); opacity: .5; pointer-events: none; }
.s-total { --sw: #d9f1e8; } .s-pending { --sw: #fbe8cb; } .s-done { --sw: #d9f0e2; } .s-amt { --sw: #dfe9fb; }
.stat > * { position: relative; z-index: 1; }
.stat .ico { width: 46px; height: 46px; font-size: 20px; border-radius: 13px; box-shadow: inset 0 1px 1px rgba(255,255,255,.6), 0 3px 9px rgba(16,60,50,.1); }
.stat .val { font-size: 24px; letter-spacing: -.5px; }
.stat .lbl { font-size: 11.5px; }

/* 趋势柱状图：渐变柱体 + 顶部高光 + 深色数值 */
.tr-bar { background: linear-gradient(180deg, #46cdb2 0%, #0f8a75 100%); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 3px 8px rgba(18,131,111,.22); }
.tr-bar.zero { background: #e7efec; box-shadow: none; }
.tr-bar span { color: #0f6f5e; font-weight: 800; }

/* 快速操作：由灰按钮改为彩色胶囊网格，分区更清晰 */
.quick-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 9px; }
.quick-actions .btn { justify-content: flex-start; padding: 13px 14px; border-radius: 11px; font-weight: 700; position: relative; overflow: hidden; box-shadow: none; }
.quick-actions .btn::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: currentColor; opacity: .55; }
.quick-actions .btn:nth-child(1) { background: #e7f6f0; color: #0d7569; }
.quick-actions .btn:nth-child(2) { background: #eaf1fc; color: #3f78c8; }
.quick-actions .btn:nth-child(3) { background: #fdf0dc; color: #b5730c; }
.quick-actions .btn:nth-child(4) { background: #f1eafc; color: #7a63cc; }
.quick-actions .btn:nth-child(5) { background: #fdeaea; color: #c45252; }
.quick-actions .btn:nth-child(n+6) { background: #eef3f1; color: #40544d; }
.quick-actions .btn:hover { filter: brightness(.97); }

/* 待办行：悬停箭头微移，强化可点击感 */
.todo-row i { transition: transform .15s, color .15s; }
.todo-row:hover i { transform: translateX(3px); color: var(--teal); }

/* 最近订单：金额做暖色胶囊，时间弱化 */
.recent-row .rc-amt { background: #fff4e3; border-radius: 6px; padding: 2px 8px; }

/* 内容管理卡片：标题带图标底色，分区更清晰 */
.content-card > .card-head .card-title { padding-left: 34px; }
.content-card > .card-head .card-title::before { width: 24px; height: 24px; top: 50%; transform: translateY(-50%); border-radius: 7px; background: var(--teal-l) url() no-repeat center; }
.content-card:nth-of-type(1) > .card-head .card-title::before { background: var(--teal-l); }
.content-card > .card-head .card-title::after { content: ''; position: absolute; left: 8px; top: 50%; transform: translateY(-50%); width: 9px; height: 9px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 3px rgba(18,138,120,.14); }

/* ============================================================
   后台美化 · 内容管理 / 表单 / 表格 / 标签栏 整体质感升级
   ============================================================ */
/* 后台卡片：顶部渐变高光条 + 更柔的阴影层次 */
.card, .content-card { position: relative; border: 1px solid #e8f0ec; box-shadow: 0 2px 8px rgba(16,60,50,.045), 0 8px 22px rgba(16,60,50,.045); }
.card::before { content: ''; position: absolute; top: 0; left: 18px; right: 18px; height: 2px; border-radius: 0 0 3px 3px; background: linear-gradient(90deg, transparent, rgba(43,183,159,.45), transparent); opacity: .55; }

/* 后台标签栏：药丸式选中态 + 图标底色 */
.admin-tabs { gap: 7px; padding-bottom: 14px; }
.admin-tab { border-radius: 20px; padding: 8px 15px; color: #6b7f78; }
.admin-tab .tab-ico { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; background: #eef4f1; font-size: 11px; }
.admin-tab.active .tab-ico { background: rgba(255,255,255,.28); color: #fff; }
.admin-tab:not(.active):hover .tab-ico { background: #dcece5; color: var(--teal-d); }

/* 表单：标签更醒目、输入框柔和底色、分组间距 */
.content-form { gap: 14px; }
.content-form .label { color: #4a5f57; font-weight: 700; font-size: 12px; padding-left: 9px; position: relative; }
.content-form .label::before { content: ''; position: absolute; left: 0; top: 2px; bottom: 2px; width: 3px; border-radius: 3px; background: linear-gradient(180deg, #2bb79f, #0d7569); }
.content-form input, .content-form select, .content-form textarea { background: #fbfdfc; border-color: #e2ece7; transition: border-color .15s, box-shadow .15s; }
.content-form input:focus, .content-form select:focus, .content-form textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(18,138,120,.1); background: #fff; outline: 0; }
.content-form textarea { line-height: 1.75; }

/* 后台表格：表头底色 + 斑马纹 + 行悬停 */
.table-wrap table thead th { background: linear-gradient(180deg, #f3faf7, #edf6f2); }
.table-wrap table tbody tr:nth-child(even) { background: #fbfdfc; }
.table-wrap table tbody tr:hover { background: #f2faf6; }

/* 内容管理卡片标题图标：按卡片顺序换色，更有辨识度 */
.content-card:nth-of-type(1) > .card-head .card-title::before { background: #e4f3ee; }
.content-card:nth-of-type(2) > .card-head .card-title::before { background: #eaf0fc; }
.content-card:nth-of-type(2) > .card-head .card-title::after { background: var(--blue); box-shadow: 0 0 0 3px rgba(74,123,214,.14); }
.content-card:nth-of-type(3) > .card-head .card-title::before { background: #fdf1de; }
.content-card:nth-of-type(3) > .card-head .card-title::after { background: var(--amber); box-shadow: 0 0 0 3px rgba(217,134,24,.14); }

/* 保存按钮：主按钮更饱满 */
.content-form .btn-primary, .content-card .btn-primary { box-shadow: 0 3px 9px rgba(18,138,120,.22); }

/* ============================================================
   后台 · 高级质感主题（最终覆盖层）
   设计目标：留白通透、克制用色、统一圆角与层次，成熟商业后台观感
   ============================================================ */
#viewAdmin { --adm-accent: #0f8a76; --adm-ink: #26362f; --adm-sub: #85938d; }

/* 管理栏：深墨绿 + 细斜纹，标题更沉稳，去掉夸张水印 */
#viewAdmin .admin-bar {
  background:
    repeating-linear-gradient(135deg, rgba(255,255,255,.035) 0 2px, transparent 2px 16px),
    linear-gradient(120deg, #0b5f53 0%, #0f7a69 55%, #12917d 100%);
  border: 0; border-radius: 16px; margin: 14px 14px 4px; padding: 20px 20px;
  box-shadow: 0 8px 22px rgba(9, 84, 71, .22);
}
#viewAdmin .admin-bar::after { content: ''; display: none; }
#viewAdmin .admin-bar-l h2 { font-size: 18px; font-weight: 800; letter-spacing: .5px; }
#viewAdmin .admin-bar-l h2::before {
  content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  background: #62e0bf; box-shadow: 0 0 0 4px rgba(98,224,191,.18);
  vertical-align: 2px; margin-right: 9px;
}
#viewAdmin .admin-bar-l p { font-size: 11px; opacity: .72; letter-spacing: .3px; }
#viewAdmin .admin-bar .btn-ghost { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.22); }

/* 标签栏：简洁药丸，选中墨绿实底，未选中浅灰底 */
#viewAdmin .admin-tabs { gap: 6px; padding: 8px 14px 16px; }
#viewAdmin .admin-tab {
  border: 1px solid transparent; border-radius: 11px; padding: 8px 13px;
  color: #60736b; font-weight: 600; background: #eef2f0; box-shadow: none;
}
#viewAdmin .admin-tab .tab-ico { background: transparent; width: auto; height: auto; font-size: 12px; opacity: .8; }
#viewAdmin .admin-tab:not(.active):hover { background: #e4ece8; color: var(--adm-accent); }
#viewAdmin .admin-tab.active {
  background: linear-gradient(135deg, #128a76, #0b6b5b); color: #fff;
  box-shadow: 0 4px 12px rgba(15,138,118,.26);
}
#viewAdmin .admin-tab.active .tab-ico { background: transparent; color: #fff; }

#viewAdmin .atab-pane { padding: 0 14px 22px; }

/* 卡片：统一圆角/细边/柔和阴影，去掉顶部彩条 */
#viewAdmin .card, #viewAdmin .content-card {
  border-radius: 15px; border: 1px solid #e9f0ec;
  box-shadow: 0 1px 2px rgba(20,60,50,.03), 0 6px 18px rgba(20,60,50,.045);
  padding: 17px 18px;
}
#viewAdmin .card::before { display: none; }
#viewAdmin .card-head { margin-bottom: 14px; }
#viewAdmin .card-head .card-title, #viewAdmin > .card-title {
  font-size: 14.5px; font-weight: 800; color: var(--adm-ink); letter-spacing: .2px;
  padding-left: 11px;
}
#viewAdmin .card-head .card-title::before {
  width: 3px; border-radius: 3px; background: linear-gradient(180deg,#3ec3a8,#0f8a76);
}
#viewAdmin .card-sub { font-size: 11px; color: var(--adm-sub); }

/* 统计卡：白底 + 精致图标砖，弱化水印，数字沉稳 */
#viewAdmin .stats { gap: 11px; margin-bottom: 14px; }
#viewAdmin .stat {
  padding: 16px; gap: 13px; min-height: 88px; border-radius: 15px;
  border: 1px solid #e9f0ec; box-shadow: 0 1px 2px rgba(20,60,50,.03), 0 6px 18px rgba(20,60,50,.045);
}
#viewAdmin .stat::after { width: 3px; opacity: .9; border-radius: 3px 0 0 3px; }
#viewAdmin .stat::before { width: 62px; height: 62px; right: -20px; bottom: -24px; opacity: .32; }
#viewAdmin .stat .ico {
  width: 44px; height: 44px; border-radius: 12px; font-size: 19px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 3px 8px rgba(16,60,50,.08);
}
#viewAdmin .stat .val { font-size: 23px; font-weight: 800; color: var(--adm-ink); }
#viewAdmin .stat .lbl { font-size: 11px; color: var(--adm-sub); }

/* 趋势柱状图：柔和渐层 */
#viewAdmin .tr-bar { background: linear-gradient(180deg, #4fc7ab 0%, #0f8a76 100%); border-radius: 6px 6px 3px 3px; }
#viewAdmin .tr-bar span { color: #0c7362; }
#viewAdmin .trend { height: 128px; }

/* 待办 / 最近订单：更轻的边界 */
#viewAdmin .todo-row { border: 1px solid #edf2ef; background: #fbfdfc; border-radius: 10px; }
#viewAdmin .todo-row:hover { border-color: #d3e6de; background: #f4faf7; }
#viewAdmin .recent-row { border-bottom-color: #f0f4f2; }

/* 快速操作：从彩色实心胶囊改为白底卡片 + 彩色图标点，克制高级 */
#viewAdmin .quick-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 9px; }
#viewAdmin .quick-actions .btn {
  justify-content: flex-start; gap: 9px; padding: 13px 13px; border-radius: 11px;
  background: #fbfdfc; color: #33473f; font-weight: 700; font-size: 12.5px;
  border: 1px solid #e8f0ec; box-shadow: none;
}
#viewAdmin .quick-actions .btn::before {
  content: ''; position: static; width: 9px; height: 9px; border-radius: 50%;
  flex: none; opacity: 1; box-shadow: 0 0 0 4px rgba(0,0,0,.03);
}
#viewAdmin .quick-actions .btn:nth-child(1)::before { background: #2bb79f; }
#viewAdmin .quick-actions .btn:nth-child(2)::before { background: #5b8fe0; }
#viewAdmin .quick-actions .btn:nth-child(3)::before { background: #eaa63c; }
#viewAdmin .quick-actions .btn:nth-child(4)::before { background: #9b83e0; }
#viewAdmin .quick-actions .btn:nth-child(5)::before { background: #e07070; }
#viewAdmin .quick-actions .btn:nth-child(n+6)::before { background: #8fa099; }
#viewAdmin .quick-actions .btn:hover {
  transform: translateY(-2px); border-color: #cfe4db;
  box-shadow: 0 6px 16px rgba(16,80,66,.1); filter: none;
}

/* 内容管理卡片标题：统一墨绿图标砖，弱化多色 */
#viewAdmin .content-card > .card-head .card-title { padding-left: 32px; }
#viewAdmin .content-card > .card-head .card-title::before {
  width: 22px; height: 22px; border-radius: 7px; background: #e6f4ee;
  top: 50%; transform: translateY(-50%);
}
#viewAdmin .content-card > .card-head .card-title::after {
  left: 7px; width: 8px; height: 8px; background: var(--adm-accent);
  box-shadow: 0 0 0 3px rgba(15,138,118,.13);
}
#viewAdmin .content-card:nth-of-type(n) > .card-head .card-title::before { background: #e6f4ee; }
#viewAdmin .content-card:nth-of-type(n) > .card-head .card-title::after { background: var(--adm-accent); box-shadow: 0 0 0 3px rgba(15,138,118,.13); }

/* 表格：清爽表头 + 柔和斑马纹 */
#viewAdmin .table-wrap table thead th { background: #f5faf7; color: #527068; font-weight: 700; }
#viewAdmin .table-wrap table tbody tr:nth-child(even) { background: #fcfefd; }
#viewAdmin .table-wrap table tbody tr:hover { background: #f4faf7; }

/* 工具栏与主按钮 */
#viewAdmin .toolbar .btn-primary { box-shadow: 0 3px 10px rgba(15,138,118,.2); }

/* 用户汇总卡：统一细条 */
#viewAdmin .user-summary .us::before { width: 3px; opacity: .9; }

@media (max-width: 899px) {
  #viewAdmin .admin-bar { margin: 10px 10px 2px; padding: 17px 15px; }
  #viewAdmin .admin-tabs { padding: 6px 10px 14px; }
  #viewAdmin .atab-pane { padding: 0 10px 20px; }
  #viewAdmin .stat { padding: 14px; }
  #viewAdmin .quick-actions { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================================
   富文本编辑器（正文排版：加粗/颜色/图片/视频）
   ============================================================ */
.rte { border: 1px solid #dfeae5; border-radius: 12px; overflow: hidden; background: #fff; }
.rte-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 3px;
  padding: 7px 8px; background: linear-gradient(180deg, #f7fbf9, #f1f7f4);
  border-bottom: 1px solid #e6efeb; position: sticky; top: 0; z-index: 3;
}
.rte-bar > button, .rte-bar > label {
  min-width: 30px; height: 30px; padding: 0 7px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; border-radius: 7px; background: transparent; color: #38544b;
  font-size: 13px; cursor: pointer; transition: .13s; position: relative; user-select: none;
}
.rte-bar > button:hover, .rte-bar > label:hover { background: #fff; border-color: #d6e7df; color: var(--teal-d); }
.rte-bar > button:active { transform: scale(.94); }
.rte-sep { width: 1px; height: 18px; background: #dce9e3; margin: 0 3px; }
.rte-fsize { width: auto; flex: none; height: 30px; border: 1px solid #dce9e3; border-radius: 7px; background: #fff; color: #38544b; font-size: 12px; padding: 0 5px; cursor: pointer; }
.rte-bar label.rte-color, .rte-bar label.rte-mark { font-weight: 800; overflow: hidden; }
.rte-bar label.rte-mark { color: #e0a020; }
.rte-bar label i { width: 0; height: 0; overflow: hidden; position: absolute; }
.rte-bar label input[type=color] { position: absolute; width: 100%; height: 100%; opacity: 0; inset: 0; cursor: pointer; }
.rte-bar label.rte-media { font-size: 14px; }
.rte-body {
  min-height: 180px; max-height: 44vh; overflow-y: auto; padding: 14px 15px;
  font-size: 14px; line-height: 1.8; color: var(--ink); outline: 0;
}
.rte-body:empty::before { content: attr(data-ph); color: #a9b8b1; }
.rte-body img { max-width: 100%; height: auto; border-radius: 8px; margin: 6px 0; }
.rte-body video { max-width: 100%; border-radius: 10px; margin: 6px 0; background: #000; }
.rte-body a { color: var(--teal); }
.rte-body ul, .rte-body ol { padding-left: 22px; }
.rte-foot { display: flex; justify-content: space-between; padding: 6px 12px; background: #fbfdfc; border-top: 1px solid #eef4f1; font-size: 10.5px; color: #9aacA4; }
.rte-foot .rte-count { color: #7d9188; font-weight: 600; }
/* 编辑器内图片：点击选中后可拖拽右下角缩放 */
.rte-body img { cursor: pointer; position: relative; }
.rte-body img.rte-img-active { outline: 2px solid var(--teal); outline-offset: 2px; border-radius: 4px; }
.rte-img-handle {
  position: fixed; z-index: 9999; width: 16px; height: 16px; display: none;
  background: var(--teal); border: 2px solid #fff; border-radius: 50%;
  box-shadow: 0 2px 8px rgba(10,90,76,.45); cursor: nwse-resize;
  touch-action: none;
}
.rte-img-handle::after { content: ''; position: absolute; right: 3px; bottom: 3px; width: 6px; height: 6px; border-right: 2px solid #fff; border-bottom: 2px solid #fff; }
.rte-img-tip {
  position: fixed; z-index: 9999; display: none; padding: 4px 9px; font-size: 11px; line-height: 1.4;
  background: rgba(16,70,58,.92); color: #fff; border-radius: 6px; pointer-events: none; white-space: nowrap;
}
/* 自定义调色板：点色块即应用，无需系统取色器二次确认 */
.rte-palette {
  position: fixed; z-index: 10000; display: none; width: 244px; padding: 10px 11px 9px;
  background: #fff; border: 1px solid #dce9e3; border-radius: 12px;
  box-shadow: 0 10px 30px rgba(10,70,58,.22);
}
.rte-palette .rp-title { font-size: 12px; font-weight: 700; color: var(--ink); margin-bottom: 8px; }
.rte-palette .rp-title span { font-weight: 400; color: #9aaba4; font-size: 10.5px; margin-left: 4px; }
.rte-palette .rp-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 5px; }
.rte-palette .rp-dot { width: 100%; aspect-ratio: 1; border: 2px solid #fff; border-radius: 7px; box-shadow: 0 0 0 1px #e2eae6; cursor: pointer; padding: 0; transition: transform .1s; }
.rte-palette .rp-dot:hover { transform: scale(1.18); box-shadow: 0 0 0 2px var(--teal); }
.rte-palette .rp-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 9px; padding-top: 8px; border-top: 1px solid #eef4f1; }
.rte-palette .rp-foot button { font-size: 11px; border: 0; background: transparent; color: var(--teal-d); cursor: pointer; padding: 3px 5px; }
.rte-palette .rp-custom-wrap { position: relative; display: inline-flex; align-items: center; gap: 4px; }
.rte-palette .rp-custom { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.rte-colorbtn.rte-mark { color: #d4a017; font-weight: 800; }

/* 前台富文本正文渲染 */
.rich-body { font-size: 13.5px; line-height: 1.85; color: #33473f; word-break: break-word; }
.rich-body > :first-child { margin-top: 0; }
.rich-body > :last-child { margin-bottom: 0; }
.rich-body p { margin: 6px 0; }
.rich-body h2, .rich-body h3, .rich-body h4 { margin: 14px 0 6px; color: var(--ink); }
.rich-body h2 { font-size: 18px; } .rich-body h3 { font-size: 16px; } .rich-body h4 { font-size: 14.5px; }
.rich-body img { max-width: 100%; height: auto; border-radius: 10px; display: block; margin: 10px auto; }
.rich-body video { max-width: 100%; border-radius: 10px; display: block; margin: 10px auto; background: #000; }
.rich-body ul, .rich-body ol { padding-left: 22px; margin: 8px 0; }
.rich-body a { color: var(--teal); text-decoration: underline; }
.rich-body blockquote { margin: 10px 0; padding: 8px 12px; border-left: 3px solid var(--teal); background: var(--teal-ll); border-radius: 0 8px 8px 0; }

/* ============================================================
   前台收尾润色 · 富文本弹窗与内容呈现
   ============================================================ */
.modal .help-cover { border-radius: 12px; box-shadow: 0 4px 14px rgba(16,70,58,.1); }
.notice-modal .help-cover { margin-top: 2px; }
.help-body .rich-body { padding: 2px 1px; }
/* 内容卡片空态更友好 */
.help-body .help-note { background: var(--teal-ll); border: 1px solid #dceee6; }
