/* ===== 商家体系（入驻 / 商家列表 / 店铺 / 商家后台，由 make_merchant_pages.py 生成） ===== */
.m-hero{padding:38px 0 40px;}
.m-hero .hero-ic img{width:44px;height:44px;border-radius:10px;object-fit:cover;}
.m-hero h1{font-size:28px;}
.mainnav a.on{color:var(--primary);font-weight:600;}

/* 面板 / 表单 */
.m-panel{background:#fff;border:1px solid var(--border);border-radius:var(--radius);padding:22px 20px;margin-bottom:18px;}
.m-panel-t{font-size:16px;color:var(--primary);margin-bottom:8px;}
.m-tip{font-size:13px;color:var(--muted);margin-bottom:14px;}
.m-form{max-width:820px;}
.f-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.f-row{display:flex;flex-direction:column;gap:6px;}
.f-row.f-full{grid-column:1 / -1;}
.f-row label{font-size:13px;color:#374151;font-weight:600;}
.f-row label i{color:#e11d48;font-style:normal;margin-left:2px;}
.f-row input,.f-row select,.f-row textarea{border:1px solid var(--border);border-radius:8px;padding:9px 11px;font-size:14px;font-family:inherit;background:#fff;color:var(--text);}
.f-row input:focus,.f-row textarea:focus,.f-row select:focus{outline:none;border-color:var(--primary);box-shadow:0 0 0 3px rgba(11,61,145,.08);}
.f-inline{display:flex;gap:8px;align-items:center;}
.f-inline input[type=text],.f-inline input:not([type]){flex:1;}
.f-file{font-size:12px;max-width:210px;}
.f-hint{font-size:12px;color:var(--muted);}
.f-check{display:flex;gap:8px;align-items:flex-start;font-size:13px;color:var(--muted);margin:14px 0;line-height:1.7;}
.f-check input{margin-top:4px;}
.btn-mini{padding:7px 14px;font-size:13px;border-radius:7px;background:var(--primary);color:#fff;border:none;cursor:pointer;}
.btn-mini:hover{background:var(--primary-dark);}
.auth-tabs{display:flex;gap:6px;background:#f0f3f8;padding:4px;border-radius:8px;margin-bottom:16px;max-width:420px;}
.auth-tabs button{flex:1;border:none;background:none;padding:8px;border-radius:6px;font-size:14px;color:var(--muted);cursor:pointer;}
.auth-tabs button.active{background:#fff;color:var(--primary);font-weight:600;box-shadow:0 1px 3px rgba(0,0,0,.1);}
.auth-msg{font-size:13px;margin:10px 0 0;min-height:18px;}
.auth-msg.err{color:#e11d48;} .auth-msg.ok{color:#059669;}

/* 状态徽标 */
.m-badge{display:inline-block;font-size:12px;padding:3px 10px;border-radius:20px;font-weight:600;}
.s-pending{background:#fff7ed;color:#c2410c;}
.s-ok{background:#ecfdf5;color:#047857;}
.s-bad{background:#fef2f2;color:#b91c1c;}
.m-status{display:flex;align-items:center;gap:14px;padding:14px;background:#f8fafc;border:1px solid var(--border);border-radius:8px;margin-bottom:12px;}
.m-status-m b{display:block;font-size:16px;color:var(--text);}
.m-status-m span{font-size:12.5px;color:var(--muted);}
.m-done-btns{display:flex;gap:10px;flex-wrap:wrap;margin-top:14px;}

/* 商家列表 */
.m-shops{display:flex;flex-direction:column;gap:14px;}
.m-shop{display:flex;gap:16px;align-items:center;background:#fff;border:1px solid var(--border);border-radius:var(--radius);padding:16px 18px;transition:.2s;}
.m-shop:hover{box-shadow:0 10px 26px rgba(11,61,145,.1);border-color:#c7d6f0;transform:translateY(-2px);}
.m-shop-l{width:62px;height:62px;border-radius:12px;background:#eef2f8;display:flex;align-items:center;justify-content:center;font-size:30px;flex-shrink:0;overflow:hidden;}
.m-shop-l img{width:100%;height:100%;object-fit:cover;}
.m-shop-m{flex:1;min-width:0;}
.m-shop-m h3{font-size:16px;color:var(--primary);margin-bottom:3px;}
.m-shop-loc{font-size:12.5px;color:var(--muted);margin-bottom:5px;}
.m-shop-intro{font-size:13px;color:var(--muted);line-height:1.7;margin-bottom:7px;}
.m-shop-cats em{font-style:normal;font-size:11.5px;background:#eef2f8;color:#334155;border-radius:4px;padding:2px 8px;margin-right:6px;}
.m-shop-r{text-align:center;flex-shrink:0;min-width:88px;}
.m-shop-r b{display:block;font-size:20px;color:var(--accent);}
.m-shop-r span{font-size:12px;color:var(--muted);}
.m-shop-r i{display:block;font-style:normal;font-size:12.5px;color:var(--primary);margin-top:6px;}

/* 商品网格（店铺页） */
.m-prods{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:16px;}
.m-prod{background:#fff;border:1px solid var(--border);border-radius:var(--radius);padding:14px;text-align:center;transition:.2s;}
.m-prod:hover{box-shadow:0 10px 26px rgba(11,61,145,.1);transform:translateY(-2px);}
.m-prod img{width:100%;height:120px;object-fit:contain;margin-bottom:8px;}
.m-pimg{display:flex;align-items:center;justify-content:center;height:120px;font-size:44px;background:#f8fafc;border-radius:8px;margin-bottom:8px;}
.m-prod h3{font-size:14px;color:var(--text);margin-bottom:5px;line-height:1.5;min-height:42px;}
.m-prod-sum{font-size:12px;color:var(--muted);min-height:34px;margin-bottom:6px;}
.m-prod-price b{color:#e11d48;font-size:16px;}
.m-prod-price s{color:var(--muted);font-size:12px;margin-left:6px;}

/* 协议确认区（入驻表单内） */
.m-agree{border:1px solid var(--border);border-radius:var(--radius);padding:14px 16px;margin:18px 0 6px;background:#fbfcfe;}
.m-agree.ok{border-color:#c7d6f0;background:#fff;}
.m-agree-head{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:10px;}
.m-agree-head b{font-size:15px;color:var(--primary);}
.m-agree-more{font-size:13px;color:var(--primary);text-decoration:none;}
.m-agree-more:hover{text-decoration:underline;}
.m-agree-box{max-height:230px;overflow-y:auto;border:1px solid var(--border);border-radius:8px;background:#fff;padding:12px 14px;}
.m-agree-box:focus{outline:2px solid rgba(11,61,145,.25);}
.m-agree-t{font-size:13px;font-weight:600;color:var(--text);margin-bottom:8px;}
.m-agree-ol{margin:0 0 10px;padding-left:22px;}
.m-agree-ol li{font-size:13px;color:#374151;line-height:1.85;margin-bottom:5px;}
.m-agree-ol li b{color:var(--text);}
.m-agree-end{font-size:12.5px;color:var(--muted);margin:0;}
.m-agree-end a{color:var(--primary);}
.m-agree-hint{font-size:12.5px;color:#c2410c;margin:8px 0 2px;}
.m-agree-hint.ok{color:#047857;}
.m-agree .f-check input:disabled{cursor:not-allowed;}
.m-agree .f-check a{color:var(--primary);}
.m-faq-more{font-size:13px;color:var(--muted);line-height:1.85;margin-top:14px;}
.m-faq-more a{color:var(--primary);}

/* 法律文本页（入驻服务协议） */
.m-hero-law .hero-ic{font-size:34px;}
.m-legal{max-width:900px;margin:0 auto;}
.m-legal-meta{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:16px;}
.m-legal-meta div{background:#f8fafc;border:1px solid var(--border);border-radius:8px;padding:8px 14px;}
.m-legal-meta span{display:block;font-size:11.5px;color:var(--muted);}
.m-legal-meta b{font-size:13.5px;color:var(--text);}
.m-law-note{background:#fffbeb;border:1px solid #fde68a;border-radius:8px;padding:12px 14px;font-size:13px;color:#78350f;line-height:1.85;margin-bottom:18px;}
.m-toc{background:#f8fafc;border:1px solid var(--border);border-radius:8px;padding:14px 16px;margin-bottom:24px;}
.m-toc > b{font-size:14px;color:var(--primary);}
.m-toc-links{display:flex;flex-wrap:wrap;gap:8px 14px;margin-top:10px;}
.m-toc-links a{font-size:13px;color:#334155;text-decoration:none;border-bottom:1px dashed #cbd5e1;}
.m-toc-links a:hover{color:var(--primary);border-color:var(--primary);}
.m-law-sec{margin-bottom:26px;scroll-margin-top:20px;}
.m-law-h{font-size:17px;color:var(--primary);margin-bottom:10px;padding-bottom:8px;border-bottom:1px solid var(--border);}
.m-law-body p{font-size:14.5px;color:#374151;line-height:1.95;margin-bottom:10px;text-align:justify;}
.m-law-sign{background:#f8fafc;border:1px solid var(--border);border-radius:8px;padding:16px 18px;}
.m-law-sign-line{font-size:13px;color:var(--muted);margin:12px 0 0;}
.m-table-wrap{overflow-x:auto;}
.m-table{width:100%;border-collapse:collapse;font-size:13.5px;min-width:560px;}
.m-table th,.m-table td{border:1px solid var(--border);padding:9px 12px;text-align:left;vertical-align:top;line-height:1.75;}
.m-table thead th{background:#eef2f8;color:var(--primary);font-weight:600;}
.m-table tbody tr:nth-child(even){background:#fcfdff;}
.m-table td:first-child{font-weight:600;color:var(--text);white-space:nowrap;}
.m-faq details.faq{border:1px solid var(--border);border-radius:8px;margin-bottom:10px;background:#fff;}
.m-faq summary{padding:12px 16px;font-size:14px;font-weight:600;color:var(--text);cursor:pointer;}
.m-faq details.faq p{padding:0 16px 14px;font-size:13.5px;color:var(--muted);line-height:1.9;}
@media print{
  .topbar,.site,.m-toc,.hero-btns,.m-faq,.copyright{display:none !important;}
  .m-law-h{color:#000;border-color:#999;}
}
@media (max-width:720px){
  .m-law-h{font-size:16px;}
  .m-law-body p{font-size:14px;}
}

.m-empty{text-align:center;padding:40px 16px;color:var(--muted);font-size:14px;}
.m-empty .btn{margin-top:14px;}
.m-miss{padding:70px 0;text-align:center;}
.m-miss h1{font-size:24px;color:var(--primary);margin-bottom:12px;}
.m-miss p{color:var(--muted);font-size:14px;margin-bottom:8px;}
.m-miss .btn{margin-top:12px;}

.m-toast{position:fixed;left:50%;bottom:40px;transform:translateX(-50%) translateY(20px);background:#0b3d91;color:#fff;
  padding:11px 22px;border-radius:8px;font-size:14px;opacity:0;pointer-events:none;transition:.25s;z-index:999;}
.m-toast.show{opacity:1;transform:translateX(-50%) translateY(0);}

@media (max-width:720px){
  .f-grid{grid-template-columns:1fr;}
  .m-shop{flex-wrap:wrap;}
  .m-shop-r{min-width:auto;}
}
/* ===== 商家体系样式结束（make_merchant_pages.py） ===== */

/* ===== 商家后台（mcenter） ===== */
.mc-top{background:#0d1b2e;color:#fff;}
.mc-top-in{display:flex;justify-content:space-between;align-items:center;height:56px;}
.mc-brand{display:flex;align-items:center;gap:10px;}
.mc-brand .mark{width:32px;height:32px;border-radius:8px;background:linear-gradient(135deg,var(--primary),#1560c8);display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;}
.mc-brand b{font-size:16px;}
.mc-brand small{font-size:10px;color:#8a9bb0;letter-spacing:1px;margin-left:4px;}
.mc-who{font-size:13px;color:#cfe0ff;}
.mc-who a{color:#ffd9a8;}

.mc-login,.mc-gate{min-height:70vh;display:flex;align-items:center;justify-content:center;padding:30px 16px;background:var(--bg);}
.mc-box{background:#fff;border:1px solid var(--border);border-radius:12px;padding:28px 26px;max-width:520px;width:100%;box-shadow:0 12px 30px rgba(11,61,145,.08);}
.mc-box h2{font-size:20px;color:var(--primary);margin-bottom:10px;}
.mc-gate-ic{font-size:44px;text-align:center;margin-bottom:10px;}
.mc-gate .m-status{margin-top:10px;}

.mc-shell{padding:22px 0 50px;background:var(--bg);min-height:70vh;}
.mc-layout{display:grid;grid-template-columns:210px 1fr;gap:20px;align-items:start;}
.mc-side{background:#fff;border:1px solid var(--border);border-radius:10px;padding:16px 12px;position:sticky;top:16px;}
.mc-side-h{display:flex;align-items:center;gap:10px;padding:6px 8px 14px;border-bottom:1px solid var(--border);margin-bottom:10px;}
.mc-side-h span{font-size:24px;}
.mc-side-h img{width:34px;height:34px;border-radius:8px;object-fit:cover;}
.mc-side-h b{font-size:14px;color:var(--text);line-height:1.3;}
.mc-side nav{display:flex;flex-direction:column;gap:2px;}
.mc-side nav a{padding:9px 12px;border-radius:7px;font-size:14px;color:#374151;cursor:pointer;}
.mc-side nav a:hover{background:#f0f3f8;}
.mc-side nav a.on{background:var(--primary);color:#fff;font-weight:600;}
.mc-side-f{margin-top:14px;padding-top:12px;border-top:1px solid var(--border);display:flex;flex-direction:column;gap:6px;}
.mc-side-f a{font-size:12.5px;color:var(--muted);}
.mc-side-f a:hover{color:var(--primary);}

.mc-main{background:#fff;border:1px solid var(--border);border-radius:10px;padding:22px 20px;min-height:520px;}
.mc-pane{display:none;}
.mc-pane.on{display:block;}
.mc-h{font-size:18px;color:var(--primary);margin-bottom:14px;padding-bottom:10px;border-bottom:1px solid var(--border);}
.mc-h2{font-size:15px;color:var(--text);margin:22px 0 10px;}
.mc-h-row{display:flex;justify-content:space-between;align-items:center;}
.mc-h-row .mc-h{border:none;padding:0;margin-bottom:14px;}

.mc-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:12px;margin-bottom:8px;}
.mc-stat{background:#f8fafc;border:1px solid var(--border);border-radius:9px;padding:14px 10px;text-align:center;}
.mc-stat b{display:block;font-size:24px;color:var(--primary);line-height:1.2;}
.mc-stat span{font-size:12.5px;color:var(--muted);}

.mc-tbl{width:100%;border-collapse:collapse;font-size:13.5px;}
.mc-tbl th{background:#f8fafc;text-align:left;padding:9px 10px;color:#374151;font-weight:600;border-bottom:1px solid var(--border);white-space:nowrap;}
.mc-tbl td{padding:10px;border-bottom:1px solid #f1f4f8;vertical-align:top;}
.mc-tbl tr:hover td{background:#fafbfd;}
.mc-td-n{max-width:280px;color:var(--text);}
.mc-td-m{max-width:320px;color:var(--muted);font-size:13px;}
.mc-td-op{white-space:nowrap;}
.mc-td-op .btn-mini{margin-right:2px;}
.btn-danger{background:#b91c1c;}
.btn-danger:hover{background:#991b1b;}
.mc-note{font-size:12px;color:#b91c1c;margin-top:4px;}

.mc-form-box{background:#f8fafc;border:1px solid var(--border);border-radius:9px;padding:18px 16px;margin-bottom:18px;}
.mc-form-box h3{font-size:15px;color:var(--primary);margin-bottom:12px;}
.mc-form-btns{display:flex;gap:10px;margin-top:14px;}
.mc-form-btns .btn-ghost{background:#fff;color:#374151;border:1px solid var(--border);}

@media (max-width:860px){
  .mc-layout{grid-template-columns:1fr;}
  .mc-side{position:static;}
  .mc-side nav{flex-direction:row;flex-wrap:wrap;}
  .mc-tbl{font-size:12.5px;}
  .mc-td-n,.mc-td-m{max-width:150px;}
}
