:root{
  --m-pink:#ff3f75;
  --m-pink-soft:#fff0f5;
  --m-orange:#ffae42;
  --m-blue:#43b5ff;
  --m-purple:#8a62ff;
  --m-bg:#f6f7fb;
  --m-card:#fff;
  --m-text:#181a22;
  --m-muted:#8b91a2;
  --m-line:#eef0f5;
  --m-shadow:0 18px 48px rgba(31,37,61,.08);
  --m-pink-shadow:0 20px 52px rgba(255,63,117,.22);
}
*{box-sizing:border-box}
html,body{margin:0;padding:0;min-height:100%;background:var(--m-bg);color:var(--m-text);font-family:system-ui,-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif}
body.merchant-mobile-page{overflow-x:hidden;-webkit-tap-highlight-color:transparent}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer}
img{max-width:100%;display:block}
.hidden{display:none!important}
.merchant-app{min-height:100vh}
.merchant-shell{min-height:100vh;padding-bottom:118px}
.merchant-boot-screen{position:fixed;inset:0;z-index:1000;display:none;place-items:center;background:#fff}
.merchant-boot-screen img{width:50px;height:50px;border-radius:14px;object-fit:cover;animation:merchantBootPulse 1s ease-in-out infinite alternate}
.merchant-boot-screen i{position:absolute;width:68px;height:68px;border:2px solid #f0f1f4;border-top-color:#ff4b79;border-radius:50%;animation:merchantBootSpin .8s linear infinite}
body.merchant-booting .merchant-boot-screen{display:grid}
body.merchant-booting #merchantAuth,body.merchant-booting #merchantShell{visibility:hidden}
@keyframes merchantBootPulse{from{opacity:.72;transform:scale(.96)}to{opacity:1;transform:scale(1)}}
@keyframes merchantBootSpin{to{transform:rotate(360deg)}}

.merchant-auth-screen{min-height:100vh;min-height:100svh;display:grid;place-items:center;padding:calc(32px + env(safe-area-inset-top)) 0 calc(32px + env(safe-area-inset-bottom));background:linear-gradient(145deg,#ff2f66 0%,#ff7098 36%,#fff0f5 68%,#f3f5fa 100%)}
.merchant-auth-shell{width:min(100%,430px);padding:22px}
.merchant-auth-brand{display:flex;align-items:flex-end;justify-content:space-between;color:#fff;margin-bottom:20px;padding:0 5px}
.merchant-auth-logo{font-size:34px;line-height:1;font-weight:900;letter-spacing:0}
.merchant-auth-subtitle{font-size:15px;font-weight:900;opacity:.96}
.merchant-auth-card{padding:20px;background:rgba(255,255,255,.98);border:1px solid rgba(255,255,255,.72);border-radius:28px;box-shadow:0 24px 70px rgba(121,27,61,.18)}
.merchant-auth-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-bottom:16px}
.merchant-auth-tab{height:44px;border:0;border-radius:999px;background:#f2f3f8;color:#717789;font-weight:800}
.merchant-auth-tab.active{background:linear-gradient(90deg,#ff2f66,#ff6d98);color:#fff}
.merchant-auth-form{display:grid;gap:13px}
.merchant-register-auth,.merchant-register-fields,.merchant-register-auth-panel{display:grid;gap:13px}
.merchant-register-auth-tabs{display:grid;grid-template-columns:1fr 1fr;gap:5px;padding:4px;border-radius:16px;background:#f1f3f7}
.merchant-register-auth-tabs button{height:40px;border:0;border-radius:12px;background:transparent;color:#717789;font-size:13px;font-weight:900}
.merchant-register-auth-tabs button.active{background:#fff;color:#20232a;box-shadow:0 5px 16px rgba(26,31,43,.08)}
.merchant-register-wechat-copy{display:grid;gap:5px;padding:3px 2px;text-align:center}
.merchant-register-wechat-copy strong{font-size:15px;font-weight:900;color:#252932}
.merchant-register-wechat-copy small{font-size:11px;line-height:1.55;color:var(--m-muted)}
.merchant-wechat-auth-btn{height:50px;border:0;border-radius:17px;background:#20b66f;color:#fff;font-size:14px;font-weight:900;box-shadow:0 10px 22px rgba(32,182,111,.2)}
.merchant-register-verified{padding:11px 13px;border:1px solid #d7f2e5;border-radius:15px;background:#f1fbf6;color:#168356;font-size:12px;font-weight:900;line-height:1.5}
.merchant-register-verified:empty{display:none}
.merchant-auth-form label{display:grid;gap:8px;color:#5a6170;font-size:13px;font-weight:700}
.merchant-auth-form input{height:50px;border:1px solid #e8ebf2;border-radius:17px;padding:0 14px;background:#fff;outline:none}
.merchant-auth-form input:focus{border-color:#ff9ab6;box-shadow:0 0 0 3px rgba(255,63,117,.12)}
.merchant-auth-form input[readonly]{background:#f5f6fa;color:#73798a;cursor:not-allowed}
.merchant-captcha-field{display:grid;grid-template-columns:minmax(0,1fr) 132px;gap:9px}
.merchant-captcha-field input{min-width:0}
.captcha-code{height:50px;border:1px solid #ffc7d9;border-radius:17px;background:#fff0f5;color:#ff2f66;font-weight:900}
.captcha-code img{display:block;width:100%;height:100%;border-radius:inherit;object-fit:contain;pointer-events:none}
.merchant-forgot-reset{display:grid;gap:11px;padding-top:12px;border-top:1px solid #eceef3}
.merchant-code-field{display:grid;grid-template-columns:minmax(0,1fr) 108px;gap:9px;min-width:0}
.merchant-code-field input{min-width:0}
.merchant-code-btn{height:50px;border:1px solid #20242b;border-radius:17px;background:#20242b;color:#fff;font-size:12px;font-weight:900;white-space:nowrap}
.merchant-code-btn:disabled{cursor:wait;opacity:.58}

.merchant-home{width:min(100%,480px);margin:0 auto}
.merchant-home-hero{height:150px;margin:0 14px;padding:26px 22px 50px;border-radius:0 0 30px 30px;background:linear-gradient(145deg,#ff2f66,#ff7599);box-shadow:var(--m-pink-shadow);display:flex;align-items:center}
.merchant-topbar{display:flex;align-items:center;width:100%;color:#fff}
.merchant-mark{font-size:34px;line-height:1;font-weight:900;letter-spacing:0}
.merchant-top-title{min-width:0}
.merchant-top-title strong{display:block;font-size:26px;font-weight:900;white-space:nowrap}
.merchant-top-title span{display:block;margin-top:7px;font-size:13px;opacity:.9;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.merchant-round-btn,.merchant-wide-btn{height:58px;border:1px solid rgba(255,255,255,.38);background:rgba(255,255,255,.24);color:#fff;display:grid;place-items:center;box-shadow:inset 0 2px 16px rgba(255,255,255,.12)}
.merchant-round-btn{width:58px;border-radius:50%}
.merchant-wide-btn{width:100%;border-radius:999px}
.merchant-round-btn svg,.merchant-wide-btn svg{width:24px;height:24px;fill:currentColor}

.merchant-home-main{display:grid;gap:14px;margin-top:-28px;padding:0 14px}
.merchant-card,.merchant-shop-card,.merchant-function-grid{background:var(--m-card);border-radius:28px;box-shadow:var(--m-shadow)}
.merchant-shop-card{padding:18px}
.merchant-shop-row{display:flex;align-items:center;gap:14px;min-width:0}
.merchant-shop-avatar{width:72px;height:72px;border-radius:22px;background:#111;color:#fff;display:grid;place-items:center;font-size:30px;font-weight:900;flex:0 0 auto}
.merchant-shop-avatar img{display:block;width:100%;height:100%;border-radius:inherit;object-fit:cover}
.merchant-shop-info{min-width:0;flex:1}
.merchant-shop-info h1{margin:0;font-size:24px;line-height:1.18;font-weight:900;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.merchant-shop-info p{margin:7px 0 0;color:var(--m-muted);font-size:14px}
.merchant-home-logout{flex:0 0 auto;display:flex;align-items:center;justify-content:center;gap:6px;width:98px;height:44px;padding:0 11px;border:1px solid #e8ebf2;border-radius:16px;background:#f8f9fc;color:#5f6675;font-size:12px;font-weight:800;white-space:nowrap;cursor:pointer}
.merchant-home-logout img{width:18px;height:18px;object-fit:contain}
.merchant-home-logout:active{background:#fff0f4;color:#ff405f}
.merchant-store-actions{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px;margin-top:13px}
.merchant-promote-btn,.merchant-store-link-btn{height:46px;border-radius:999px;padding:0 18px;font-weight:900;white-space:nowrap}
.merchant-promote-btn{border:0;background:linear-gradient(90deg,#ff2f66,#ff628e);color:#fff;box-shadow:0 10px 22px rgba(255,47,102,.2)}
.merchant-store-link-btn{border:1px solid #ffd0df;background:#fff1f6;color:#ff2f66}
.merchant-stats-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-top:18px;padding-top:16px;border-top:1px dashed #e7eaf2}
.merchant-stats-grid div{text-align:center;min-width:0}
.merchant-stats-grid strong{display:block;font-size:22px;line-height:1.08;font-weight:900;white-space:nowrap}
.merchant-stats-grid span{display:block;margin-top:7px;font-size:12px;color:var(--m-muted);white-space:nowrap}

.merchant-function-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:16px}
.merchant-announcement-btn{width:100%;min-height:58px;border:0;border-radius:22px;background:#fff;box-shadow:var(--m-shadow);display:flex;align-items:center;gap:11px;padding:12px 16px;text-align:left;color:#222;cursor:pointer}
.merchant-announcement-btn img{width:30px;height:30px;object-fit:contain;flex:0 0 auto}
.merchant-announcement-btn span{font-size:15px;font-weight:900}
.merchant-announcement-btn small{margin-left:auto;color:var(--m-muted);font-size:11px}
.merchant-announcement-sheet-card{padding-bottom:calc(22px + env(safe-area-inset-bottom))}
.merchant-announcement-content{font-size:14px;line-height:1.85;color:#343947;word-break:break-word}
.merchant-form-help{display:block;color:var(--m-muted);font-size:12px;line-height:1.6;margin-top:-5px}
.merchant-function-tile{position:relative;min-height:112px;border:0;border-radius:24px;background:#fff;box-shadow:0 10px 28px rgba(18,29,57,.06);display:grid;place-items:center;gap:9px;color:#2a2d35}
.merchant-function-tile i{width:62px;height:62px;border-radius:20px;display:grid;place-items:center;font-style:normal;font-size:24px;font-weight:900;color:#fff;background:linear-gradient(180deg,#ff5d85,#ff88a1)}
.merchant-function-tile:nth-child(2) i{background:linear-gradient(180deg,#43a8ff,#5fd2ff)}
.merchant-function-tile:nth-child(3) i{background:linear-gradient(180deg,#ffa93d,#ffd064)}
.merchant-function-tile:nth-child(4) i{background:linear-gradient(180deg,#ff477a,#ff7a98)}
.merchant-function-tile:nth-child(5) i{background:linear-gradient(180deg,#ffa43a,#ffbd6d)}
.merchant-function-tile:nth-child(6) i{background:linear-gradient(180deg,#7b5cff,#b37dff)}
.merchant-function-tile span{font-size:15px;font-weight:900;white-space:nowrap}
.merchant-function-tile em,.merchant-bottom-item em{position:absolute;min-width:18px;height:18px;border-radius:999px;background:#ff2f44;color:#fff;font-style:normal;font-size:11px;line-height:18px;text-align:center;font-weight:900}
.merchant-function-tile em{top:10px;right:14px}

.merchant-home-list{padding:16px}
.merchant-card-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.merchant-card-head strong{font-size:18px;font-weight:900}
.merchant-text-btn{border:0;background:transparent;color:#ff2f66;font-size:13px;font-weight:800;padding:6px}
.merchant-sales-tabs{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;margin-bottom:12px;padding:4px;border-radius:15px;background:#f2f4f8}
.merchant-sales-tabs button{height:34px;border:0;border-radius:11px;background:transparent;color:#777e8e;font-size:11px;font-weight:800}
.merchant-sales-tabs button.active{background:#111;color:#fff;box-shadow:0 4px 12px rgba(17,17,17,.12)}
.merchant-mini-list{display:grid;gap:10px}
.merchant-mini-item,.merchant-mini-row{width:100%;border:0;border-radius:18px;background:#f8f9fd;padding:10px;display:flex;align-items:center;gap:10px;text-align:left}
.merchant-mini-item img,.merchant-mini-item i{width:46px;height:46px;border-radius:14px;object-fit:cover;flex:0 0 auto}
.merchant-mini-item i{display:grid;place-items:center;background:#111;color:#fff;font-style:normal;font-weight:900}
.merchant-mini-item span,.merchant-mini-row span{min-width:0;flex:1}
.merchant-mini-item b,.merchant-mini-row b{display:block;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.merchant-mini-item small,.merchant-mini-row small{display:block;margin-top:4px;color:var(--m-muted);font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.merchant-mini-row{justify-content:space-between}
.merchant-mini-row>strong{font-size:14px;white-space:nowrap}
.merchant-mini-row>strong.positive{color:#16a36a}
.merchant-mini-row>strong.negative{color:#ff3f50}
.merchant-sales-rank-item{position:relative;padding-left:8px}
.merchant-sales-rank-item>strong{flex:0 0 auto;color:#ff2f66;font-size:12px;white-space:nowrap}
.merchant-rank-number{width:22px;height:22px;display:grid;place-items:center;flex:0 0 22px;border-radius:8px;background:#e9ecf2;color:#697080;font-size:11px;font-style:normal;font-weight:900}
.merchant-rank-number.rank-1{background:#fff0c9;color:#d89000}
.merchant-rank-number.rank-2{background:#edf1f7;color:#758094}
.merchant-rank-number.rank-3{background:#fff0e9;color:#d56e3d}

.merchant-page{width:min(100%,480px);margin:0 auto;padding:16px 14px 0}
.merchant-page-topbar{height:84px;display:grid;grid-template-columns:64px minmax(0,1fr) 64px;align-items:center}
.merchant-page-topbar strong{justify-self:center;font-size:22px;font-weight:900;letter-spacing:0}
.merchant-page-back{width:60px;height:60px;border:0;border-radius:50%;background:#fff;box-shadow:0 10px 28px rgba(16,24,40,.08);display:grid;place-items:center}
.merchant-page-back svg{width:25px;height:25px;fill:#16181f}
.merchant-page-back img{width:23px;height:23px;object-fit:contain}
.merchant-page-topbar{position:sticky;top:calc(8px + env(safe-area-inset-top));z-index:20;isolation:isolate}
.merchant-page-back.is-refreshing img{animation:merchantRefreshSpin .8s linear infinite}
.merchant-page-back.is-refreshing{cursor:wait;opacity:.72}
@keyframes merchantRefreshSpin{to{transform:rotate(360deg)}}
.merchant-page-body{display:grid;gap:12px;padding-bottom:4px}
.merchant-subpage{display:grid;gap:12px}
.merchant-card{padding:15px}
.merchant-store-share{display:grid;grid-template-columns:auto minmax(0,1fr);gap:8px;margin-top:14px;min-width:0}
.merchant-store-share .merchant-promote-btn{height:42px;padding:0 16px;border:0;border-radius:999px;background:linear-gradient(90deg,#ff2f66,#ff628e);color:#fff;font-weight:900;white-space:nowrap}
.merchant-store-link{min-width:0;height:42px;padding:0 14px;border:1px solid #ffd0df;border-radius:999px;background:#fff7fa;color:#ff2f66;text-align:left;cursor:pointer}
.merchant-store-link span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}

.merchant-filter-row{display:grid;grid-template-columns:minmax(0,1fr) 48px;gap:9px;margin-bottom:10px}
.merchant-filter-row.two{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
.merchant-input,.merchant-select,.merchant-textarea{width:100%;border:1px solid #e8ebf2;background:#f9fafd;border-radius:16px;outline:none}
.merchant-input,.merchant-select{height:48px;padding:0 13px}
.merchant-textarea{min-height:92px;resize:vertical;padding:13px;line-height:1.5}
.merchant-textarea.tall{min-height:210px}
.merchant-delivery-textarea{min-height:132px}
.merchant-input:focus,.merchant-select:focus,.merchant-textarea:focus{border-color:#ff9ab6;box-shadow:0 0 0 3px rgba(255,63,117,.1)}
.merchant-icon-action{height:48px;border:0;border-radius:16px;background:#111;color:#fff;display:grid;place-items:center}
.merchant-icon-action svg{width:21px;height:21px;fill:currentColor}
.merchant-icon-action img{width:22px;height:22px;object-fit:contain}
.merchant-search-action{background:#fff;color:#20242b;border:1px solid #e3e6ec;box-shadow:0 6px 16px rgba(27,32,43,.06)}
.merchant-search-action img{width:21px;height:21px}
.merchant-action-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.merchant-primary-btn,.merchant-plain-btn,.merchant-danger-btn{border:0;border-radius:18px;font-weight:900}
.merchant-primary-btn{height:50px;background:linear-gradient(90deg,#ff2f66,#ff6e98);color:#fff;box-shadow:0 10px 22px rgba(255,47,102,.18)}
.merchant-primary-btn.compact,.merchant-plain-btn.compact,.merchant-danger-btn.compact{height:46px}
.merchant-plain-btn{background:#f0f2f7;color:#2b303b}
.merchant-danger-btn{height:50px;background:#ff4056;color:#fff}
.merchant-order-tabs{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.merchant-order-tabs button{height:40px;border:0;border-radius:999px;background:#f2f3f8;color:#6f7688;font-size:13px;font-weight:900}
.merchant-order-tabs button.active{background:#111;color:#fff}

.merchant-card-list{display:grid;gap:12px}
.merchant-list-card{position:relative;background:#fff;border-radius:24px;box-shadow:var(--m-shadow);padding:14px}
.product-card{display:grid;grid-template-columns:86px minmax(0,1fr);gap:12px}
.merchant-product-media{width:86px;display:grid;align-content:start;gap:7px}
.merchant-product-cover{width:86px;height:86px;border-radius:20px;background:#f2f4f9;overflow:hidden;display:grid;place-items:center}
.merchant-product-cover{position:relative;padding:0;border:0;cursor:zoom-in}
.merchant-product-cover img{width:100%;height:100%;object-fit:cover}
.merchant-product-cover span{font-size:28px;font-weight:900;color:#a2a8b8}
.merchant-product-cover em{position:absolute;right:5px;bottom:5px;padding:3px 6px;border-radius:999px;background:rgba(17,17,17,.72);color:#fff;font-size:10px;font-style:normal;line-height:1}
.merchant-product-check{width:100%;height:29px;display:flex;align-items:center;justify-content:center;gap:5px;border-radius:10px;background:#f7f8fb;color:#737a8b;font-size:10px;font-weight:800;cursor:pointer}
.merchant-product-check input{position:absolute;opacity:0;pointer-events:none}
.merchant-product-check span{width:15px;height:15px;border:1.5px solid #cbd1dc;border-radius:5px;background:#fff;display:grid;place-items:center}
.merchant-product-check input:checked+span{border-color:var(--m-pink);background:var(--m-pink)}
.merchant-product-check input:checked+span::after{content:"";width:6px;height:3px;border-left:2px solid #fff;border-bottom:2px solid #fff;transform:translateY(-1px) rotate(-45deg)}
.merchant-product-check b{font-size:10px;font-weight:800}
.merchant-product-main{min-width:0}
.merchant-card-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.merchant-card-title-row h3{margin:0;font-size:16px;line-height:1.35;font-weight:900;min-width:0;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.merchant-product-main p,.order-card p{margin:6px 0 0;color:var(--m-muted);font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.merchant-product-meta,.merchant-order-meta{display:flex;align-items:center;gap:10px;margin-top:8px;flex-wrap:wrap}
.merchant-product-meta strong,.merchant-order-meta strong{color:#ff2f66;font-size:16px}
.merchant-product-meta del{color:#a1a7b3;font-size:11px}
.merchant-product-meta span,.merchant-order-meta span{color:#7d8496;font-size:12px}
.merchant-card-actions{display:flex;align-items:center;gap:8px;margin-top:10px;overflow-x:auto;padding-bottom:1px}
.merchant-card-actions button{flex:0 0 auto;height:34px;border:0;border-radius:999px;background:#f3f5fa;color:#272b35;padding:0 13px;font-size:12px;font-weight:900}
.merchant-card-actions button.danger{background:#fff0f2;color:#ff4056}
.merchant-card-actions button.stock{background:#ecfbf4;color:#119c62}
.merchant-delivery-mode-text{color:#1686d8!important}
.merchant-badge{display:inline-grid;place-items:center;flex:0 0 auto;min-width:52px;height:26px;border-radius:999px;padding:0 9px;font-style:normal;font-size:12px;font-weight:900;white-space:nowrap}
.merchant-badge.green{background:#eaf9f2;color:#11a263}
.merchant-badge.red{background:#fff0f2;color:#ff4056}
.merchant-badge.orange{background:#fff5e7;color:#ee8a00}
.merchant-badge.blue{background:#edf7ff;color:#1686d8}

.merchant-stock-batch-toolbar,.merchant-product-batch-toolbar{display:grid;grid-template-columns:minmax(68px,.8fr) repeat(3,minmax(0,1fr));gap:6px;align-items:center}
.merchant-stock-batch-toolbar button,.merchant-product-batch-toolbar button{height:36px;min-width:0;border:0;border-radius:13px;background:#f1f3f7;color:#363b47;padding:0 6px;font-size:11px;font-weight:800;white-space:nowrap}
.merchant-stock-batch-toolbar button.danger,.merchant-product-batch-toolbar button.danger{background:#fff0f2;color:#f04457}
.merchant-product-batch-toolbar button.publish{background:#eaf9f2;color:#0b9b5b}
.merchant-stock-batch-toolbar button:disabled,.merchant-product-batch-toolbar button:disabled{opacity:.42;cursor:not-allowed}
.merchant-product-batch-toolbar{grid-template-columns:minmax(68px,.8fr) repeat(4,minmax(64px,1fr));overflow-x:auto}
.merchant-product-pager{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:6px;margin:2px 0 4px}
.merchant-pager-btn{min-width:34px;height:34px;padding:0 10px;border:1px solid #e8ebf2;border-radius:11px;background:#fff;color:#61697a;font-size:11px;font-weight:900}
.merchant-pager-btn.active{border-color:var(--m-pink);background:var(--m-pink);color:#fff}
.merchant-pager-btn:disabled{cursor:default;opacity:.42}
.merchant-pager-size{display:flex;align-items:center;gap:5px;color:#8a91a0;font-size:11px;font-weight:800}
.merchant-pager-size select{height:34px;border:1px solid #e8ebf2;border-radius:11px;background:#fff;color:#454c5b;padding:0 7px;font-size:11px;font-weight:800}
.merchant-stock-select-all,.merchant-product-select-all{height:36px;display:flex;align-items:center;justify-content:center;gap:5px;border-radius:13px;background:#fff;border:1px solid #e8ebf2;color:#555d6d;font-size:11px;font-weight:800;white-space:nowrap;cursor:pointer}
.merchant-stock-select-all input,.merchant-product-select-all input{width:15px;height:15px;margin:0;accent-color:var(--m-pink)}
.merchant-stock-select-all em,.merchant-product-select-all em{min-width:17px;height:17px;border-radius:999px;background:#f0f2f6;color:#606777;font-size:9px;font-style:normal;line-height:17px;text-align:center}
.stock-card{display:grid;grid-template-columns:22px minmax(0,1fr) auto;gap:9px;align-items:start}
.merchant-stock-check{width:22px;height:24px;display:grid;place-items:center;cursor:pointer}
.merchant-stock-check input{position:absolute;opacity:0;pointer-events:none}
.merchant-stock-check span{width:17px;height:17px;border:1.5px solid #cfd4de;border-radius:6px;background:#fff;display:grid;place-items:center}
.merchant-stock-check input:checked+span{border-color:var(--m-pink);background:var(--m-pink)}
.merchant-stock-check input:checked+span::after{content:"";width:7px;height:4px;border-left:2px solid #fff;border-bottom:2px solid #fff;transform:translateY(-1px) rotate(-45deg)}
.merchant-stock-code{min-width:0}
.merchant-stock-code strong{display:block;font-size:15px;word-break:break-all}
.merchant-stock-code small,.merchant-list-time{display:block;margin-top:7px;color:var(--m-muted);font-size:12px}
.merchant-stock-side{display:grid;justify-items:end;align-content:start;gap:8px}
.merchant-stock-item-actions{display:flex;align-items:center;justify-content:flex-end;gap:5px}
.merchant-stock-side button{height:30px;border:0;border-radius:999px;background:#111;color:#fff;padding:0 10px;font-size:11px;font-weight:900}
.merchant-stock-side button.danger{background:#fff0f2;color:#f04457}
.merchant-stock-code .merchant-list-time{margin:5px 0 0;line-height:1.45}

.order-card{display:grid;gap:6px}
.merchant-order-meta{margin-top:0;justify-content:space-between}
.merchant-profit-line{font-size:12px;color:#545b6b;background:#f8f9fd;border-radius:12px;padding:8px 10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

.merchant-wallet-summary{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.merchant-wallet-summary div{min-height:94px;border-radius:24px;background:linear-gradient(135deg,#111,#323645);color:#fff;padding:16px;box-shadow:var(--m-shadow)}
.merchant-wallet-summary div:nth-child(2){background:linear-gradient(135deg,#ff4c78,#ff8aa5)}
.merchant-wallet-summary span{display:block;font-size:12px;opacity:.78}
.merchant-wallet-summary strong{display:block;margin-top:10px;font-size:23px;font-weight:900;white-space:nowrap}
.merchant-wallet-history{padding:12px}
.merchant-wallet-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;padding:4px;border-radius:18px;background:#f2f4f8}
.merchant-wallet-tabs button{height:40px;border:0;border-radius:14px;background:transparent;color:#71788a;font-size:13px;font-weight:900;transition:background .18s ease,color .18s ease,box-shadow .18s ease}
.merchant-wallet-tabs button.active{background:#fff;color:#171920;box-shadow:0 4px 14px rgba(20,28,45,.08)}
.merchant-wallet-panel{margin-top:12px}
.merchant-wallet-panel .merchant-mini-row{align-items:flex-start;padding:12px}
.merchant-wallet-panel .merchant-mini-row time{display:block;margin-top:5px;color:#a0a6b5;font-size:11px;font-style:normal;line-height:1.25;white-space:nowrap}
.merchant-wallet-panel .merchant-mini-row>strong,.merchant-wallet-panel .merchant-mini-row>.merchant-badge{margin-top:1px}

.merchant-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.merchant-single-column-form{grid-template-columns:minmax(0,1fr)}
.merchant-bulk-form{grid-template-columns:minmax(0,1fr);gap:0}
.merchant-bulk-section{display:grid;gap:10px;padding:15px 0 4px;border-top:1px solid #e7eaf0}
.merchant-bulk-section:first-of-type{padding-top:3px;border-top:0}
.merchant-bulk-section h3{margin:0 0 2px;color:#272b35;font-size:14px;font-weight:900}
.merchant-bulk-section small{display:block;margin-top:-2px;color:var(--m-muted);font-size:11px;line-height:1.5}
.merchant-bulk-detail{display:grid;gap:10px;margin:0 0 4px;padding:11px;border:1px solid #f0dfe6;border-radius:15px;background:#fff9fb}
.merchant-bulk-detail>label{min-width:0}
.merchant-bulk-schedule-fields{display:grid;gap:10px;padding-top:1px}
.merchant-bulk-schedule-range,.merchant-bulk-schedule-daily{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.merchant-bulk-schedule-range.hidden,.merchant-bulk-schedule-daily.hidden,.merchant-bulk-detail.hidden,.merchant-bulk-schedule-fields.hidden{display:none!important}
.merchant-description-preset-sheet-card{animation:merchantDescriptionPresetRise .24s cubic-bezier(.22,.7,.25,1)}
.merchant-description-preset-form{gap:12px}
.merchant-description-preset-form .merchant-page-note{padding:0 2px}
@keyframes merchantDescriptionPresetRise{from{opacity:0;transform:translateY(32px)}to{opacity:1;transform:translateY(0)}}
.merchant-form-grid label{display:grid;gap:8px;font-size:13px;font-weight:800;color:#565d6d}
.merchant-form-grid label.wide,.merchant-form-grid button.wide{grid-column:1/-1}
.merchant-form-field{display:grid;gap:8px;color:#565d6d;font-size:13px;font-weight:800}
.merchant-product-description-field{display:grid;gap:8px;min-width:0}
.merchant-product-description-head{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0;color:#565d6d;font-size:13px;font-weight:800}
.merchant-product-description-actions{display:flex;align-items:center;gap:6px;flex:0 0 auto}
.merchant-description-action{height:30px;padding:0 10px;border:1px solid #e3e6ec;border-radius:999px;background:#fff;color:#697180;font-size:10px;font-weight:850;white-space:nowrap;cursor:pointer}
.merchant-description-action.primary{border-color:#ffd0df;background:#fff4f7;color:#e83d68}
.merchant-description-action:active{transform:translateY(1px)}
.merchant-product-import{display:grid;gap:10px;padding:13px;border:1px solid #f0e4e8;border-radius:18px;background:#fff9fb}
.merchant-product-import-head{display:flex;align-items:center;justify-content:space-between;gap:10px;color:#343945;font-size:13px;font-weight:900}
.merchant-product-import-head small{color:#9a7180;font-size:10px;font-weight:700}
.merchant-product-import-action{display:grid;grid-template-columns:minmax(0,1fr) 64px;gap:8px}
.merchant-product-import-btn,.merchant-product-import-apply{border:0;border-radius:14px;background:#20232a;color:#fff;font-size:12px;font-weight:900}
.merchant-product-import-btn:disabled,.merchant-product-import-apply:disabled{cursor:wait;opacity:.58}
.merchant-product-import-result{display:grid;gap:10px;padding-top:10px;border-top:1px solid #f1dce3}
.merchant-product-import-message{margin:0;color:#777e8c;font-size:11px;line-height:1.6}
.merchant-product-import-message.error{color:#e84861}
.merchant-product-import-summary{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0}
.merchant-product-import-summary>div{display:grid;gap:4px;min-width:0}
.merchant-product-import-summary strong{overflow:hidden;color:#2e333d;font-size:12px;text-overflow:ellipsis;white-space:nowrap}
.merchant-product-import-summary span{color:#9298a5;font-size:10px;font-weight:700}
.merchant-product-import-summary em{flex:0 0 auto;padding:4px 8px;border-radius:999px;background:#fce7ed;color:#e04469;font-size:9px;font-style:normal;font-weight:900}
.merchant-product-import-images{display:flex;gap:8px;overflow-x:auto;padding:1px 0 5px;scrollbar-width:thin;overscroll-behavior-x:contain}
.merchant-product-import-images label{position:relative;flex:0 0 64px;width:64px;height:64px;cursor:pointer}
.merchant-product-import-images input{position:absolute;z-index:2;top:4px;left:4px;width:15px;height:15px;margin:0;accent-color:#ff3f75}
.merchant-product-import-images span{position:relative;display:block;width:100%;height:100%;overflow:hidden;border:2px solid transparent;border-radius:13px;background:#f0f2f6}
.merchant-product-import-images input:checked+span{border-color:#ff7098}
.merchant-product-import-images img{width:100%;height:100%;object-fit:cover}
.merchant-product-import-images i{position:absolute;right:3px;bottom:3px;padding:2px 5px;border-radius:999px;background:rgba(18,20,25,.72);color:#fff;font-size:8px;font-style:normal;font-weight:800}
.merchant-product-import-apply{height:40px;padding:0 13px;background:linear-gradient(90deg,#ff2f66,#ff6e98)}
.merchant-stock-product-field{grid-column:1/-1;min-width:0}
.merchant-stock-product-picker{display:grid;gap:7px;min-width:0}
.merchant-stock-filter-picker{position:relative;z-index:4}
.merchant-stock-filter-picker .merchant-stock-product-options{position:absolute;z-index:12;top:calc(100% + 6px);left:0;right:0;box-shadow:0 14px 30px rgba(26,34,50,.12)}
.merchant-stock-product-picker.open .merchant-input{border-color:#ff9ab6;box-shadow:0 0 0 3px rgba(255,63,117,.1)}
.merchant-stock-product-options{display:grid;gap:4px;max-height:190px;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain;touch-action:pan-y;-webkit-overflow-scrolling:touch;padding:5px;border:1px solid #e7eaf1;border-radius:14px;background:#f8f9fc;scrollbar-width:thin}
.merchant-stock-product-option{width:100%;min-width:0;height:38px;border:0;border-radius:10px;background:#fff;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:0 11px;text-align:left;color:#262b35;font-size:12px}
.merchant-stock-product-option span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.merchant-stock-product-option b{flex:0 0 auto;color:#8b92a3;font-size:11px}
.merchant-stock-product-option.selected{background:#fff0f5;color:#ff2f66}
.merchant-stock-product-option.selected b{color:#ff2f66}
.merchant-stock-product-empty{margin:0;padding:16px 10px;color:#9198a8;font-size:11px;font-weight:700;text-align:center}
.merchant-image-picker{display:flex;flex-wrap:wrap;gap:10px;min-height:92px;padding:2px 0}
.merchant-image-upload-status{flex:0 0 100%;display:block;color:#8b93a1;font-size:11px;line-height:1.5}
.merchant-image-add,.merchant-image-item{position:relative;display:grid;place-items:center;width:92px;height:92px;border-radius:18px;overflow:hidden}
.merchant-image-add{border:1px dashed #ff9ab6;background:#fff6f9;color:#ff2f66;cursor:pointer;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center}
.merchant-image-add input{display:none}
.merchant-image-add b{display:block;margin:0;font-size:34px;font-weight:500;line-height:1}
.merchant-image-add span{display:block;margin-top:4px;font-size:11px;font-weight:900;line-height:1}
.merchant-image-item{border:2px solid #f0f2f6;background:#f7f8fb;cursor:grab;touch-action:none}
.merchant-image-item.dragging{opacity:.55;border-color:#ff3f75;transform:scale(.96)}
.merchant-image-item img{width:100%;height:100%;object-fit:cover}
.merchant-avatar-preview{cursor:default;touch-action:auto}
.merchant-image-item>span{position:absolute;left:5px;bottom:5px;padding:3px 6px;border-radius:999px;background:rgba(17,17,17,.72);color:#fff;font-size:10px;font-weight:800}
.merchant-image-item>button{position:absolute;right:4px;top:4px;display:grid;place-items:center;width:23px;height:23px;border:0;border-radius:50%;background:rgba(17,17,17,.72);color:#fff;font-size:17px;line-height:1}
.merchant-tag-editor{display:grid;gap:8px;min-width:0}
.merchant-tag-selected{display:flex;flex-wrap:wrap;gap:7px;min-height:30px;align-items:center}
.merchant-tag-chip{display:inline-flex;align-items:center;justify-content:center;gap:5px;height:30px;padding:0 9px 0 11px;border:0;border-radius:999px;background:#fff0f5;color:#ff2f66;font-size:12px;font-weight:900;line-height:1;white-space:nowrap}
.merchant-tag-chip span{line-height:1}
.merchant-tag-chip b{display:grid;place-items:center;width:16px;height:16px;margin:0;border-radius:50%;font-size:13px;font-weight:900;line-height:1}
.merchant-tag-picker{display:grid;gap:8px;padding:10px;border:1px solid #f0dbe3;border-radius:16px;background:#fffafd}
.merchant-tag-search{height:40px!important;border-radius:13px!important;font-size:12px}
.merchant-tag-options{display:flex;flex-wrap:nowrap;gap:7px;min-height:25px;align-items:center;overflow-x:auto;overscroll-behavior-x:contain;padding-bottom:2px;scrollbar-width:none;-webkit-overflow-scrolling:touch}
.merchant-tag-options::-webkit-scrollbar{display:none}
.merchant-tag-option{flex:0 0 auto;height:29px;padding:0 10px;border:1px solid #ffd0df;border-radius:999px;background:#fff;color:#ff2f66;font-size:11px;font-weight:800;line-height:1}
.merchant-tag-empty{color:var(--m-muted);font-size:12px}
.merchant-switch-row{display:flex!important;align-items:center;gap:9px;border:1px solid #e8ebf2;background:#f9fafd;border-radius:16px;padding:12px}
.merchant-switch-row input{width:18px;height:18px;accent-color:#ff2f66}
.merchant-switch-row span{line-height:1.45}
.merchant-discount-field small{margin-top:-2px;color:var(--m-muted);font-size:11px;font-weight:600;line-height:1.4}
.merchant-customer-fields-section{display:grid;gap:8px}
.merchant-delivery-fields-list{display:grid;gap:8px}
.merchant-delivery-field-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 58px;gap:8px;align-items:center}
.merchant-delivery-field-row .merchant-input{min-width:0}
.merchant-delete-field-btn{height:48px;border:0;border-radius:16px;background:#fff0f2;color:#ff4056;font-size:12px;font-weight:900;white-space:nowrap}
.merchant-add-field-btn{justify-self:start;height:38px;padding:0 14px;border:1px solid #ffd0df;border-radius:999px;background:#fff6f9;color:#ff2f66;font-size:12px;font-weight:900}
.merchant-add-field-btn:disabled{cursor:not-allowed;opacity:.55}
.merchant-delivery-fields-empty{padding:11px 13px;border:1px dashed #e2e6ef;border-radius:14px;color:var(--m-muted);font-size:12px}
.merchant-file-line{display:flex!important;align-items:center;justify-content:center;height:44px;border:1px dashed #ff9ab6;border-radius:16px;color:#ff2f66;background:#fff6f9;font-weight:900}
.merchant-file-line input{display:none}
.merchant-store-profile{display:flex;gap:13px;align-items:center}
.merchant-store-profile h2{margin:0;font-size:22px;font-weight:900}
.merchant-store-profile p{margin:7px 0 0;color:var(--m-muted);font-size:13px;line-height:1.5}
.merchant-store-metrics{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:16px 0}
.merchant-store-metrics div{background:#f8f9fd;border-radius:18px;padding:13px}
.merchant-store-metrics strong{display:block;font-size:18px;font-weight:900;white-space:nowrap}
.merchant-store-metrics span{display:block;margin-top:6px;color:var(--m-muted);font-size:12px}

.merchant-bottom-capsule{position:fixed;z-index:50;left:50%;bottom:calc(14px + env(safe-area-inset-bottom));transform:translateX(-50%);width:min(92vw,430px);display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;padding:12px;border-radius:999px;background:rgba(255,255,255,.92);backdrop-filter:blur(16px);box-shadow:0 18px 48px rgba(20,26,40,.16)}
.merchant-bottom-item{position:relative;border:0;background:transparent;display:grid;justify-items:center;gap:5px;padding:8px 3px;border-radius:999px;color:#252933}
.merchant-bottom-item span{width:32px;height:32px;border-radius:11px;background:#111;color:#fff;display:grid;place-items:center;font-size:14px;font-weight:900}
.merchant-bottom-item b{font-size:12px;font-weight:900;white-space:nowrap}
.merchant-bottom-item.active{background:#fff0f5;color:#ff2f66}
.merchant-bottom-item.active span{background:#ff2f66}
.merchant-bottom-item em{top:7px;right:18px}

.merchant-sheet{position:fixed;z-index:100;inset:0;background:rgba(15,18,28,.45);display:grid;align-items:end}
.merchant-sheet-card{width:min(100%,480px);max-height:88vh;margin:0 auto;background:#fff;border-radius:28px 28px 0 0;padding:16px 16px calc(18px + env(safe-area-inset-bottom));overflow:auto;box-shadow:0 -18px 56px rgba(0,0,0,.16)}
.merchant-sheet-head{position:sticky;top:0;z-index:2;margin:-16px -16px 14px;padding:16px;background:#fff;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #f0f2f6}
.merchant-sheet-head strong{font-size:18px;font-weight:900}
.merchant-sheet-head button{border:0;background:#f3f5fa;border-radius:999px;height:34px;padding:0 13px;font-size:12px;font-weight:900;color:#555d70}
.sheet-form{padding-bottom:4px}
.merchant-sheet-open{overflow:hidden;scrollbar-width:none;-ms-overflow-style:none}
.merchant-sheet-open::-webkit-scrollbar{display:none;width:0;height:0}
.merchant-sheet-card{scrollbar-width:none;-ms-overflow-style:none}
.merchant-sheet-card::-webkit-scrollbar{display:none;width:0;height:0}
.merchant-confirm-sheet-card{width:min(100%,420px);max-height:none;padding-bottom:calc(20px + env(safe-area-inset-bottom))}
.merchant-confirm-body{display:grid;grid-template-columns:38px minmax(0,1fr);align-items:start;gap:12px;padding:7px 2px 20px}
.merchant-confirm-body p{margin:0;color:#4f5662;font-size:13px;line-height:1.65}
.merchant-confirm-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:13px;background:#fff1f2;color:#e5485d;font-size:22px;font-weight:900;line-height:1}
.merchant-confirm-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.merchant-confirm-actions button{width:100%;margin:0}
.merchant-confirm-actions .merchant-plain-btn{height:50px;border:1px solid #e7e9ee;border-radius:18px;background:#f8f9fb;color:#666e7a;font-weight:900}
.merchant-confirm-actions .merchant-danger-btn{height:50px;border-radius:18px}

.merchant-detail-block{display:grid;gap:10px}
.merchant-detail-title{display:flex;align-items:center;justify-content:space-between;gap:10px}
.merchant-detail-title h3{margin:0;font-size:18px;font-weight:900;min-width:0}
.merchant-detail-row{display:grid;grid-template-columns:84px minmax(0,1fr);gap:10px;background:#f8f9fd;border-radius:15px;padding:11px}
.merchant-detail-row span{color:var(--m-muted);font-size:13px}
.merchant-detail-row strong{font-size:13px;word-break:break-all}
.merchant-detail-content{background:#f8f9fd;border-radius:15px;padding:12px}
.merchant-detail-content strong{display:block;margin-bottom:8px;font-size:13px}
.merchant-detail-content pre{margin:0;white-space:pre-wrap;word-break:break-word;font-size:13px;line-height:1.55}
.merchant-detail-delivery{display:grid;gap:9px;border:1px solid #edf0f4;background:#f8f9fc}
.merchant-detail-delivery strong{margin:0;color:#343b47}
.merchant-detail-delivery pre{padding:10px 11px;border:1px solid #edf0f4;border-radius:10px;background:#fff;color:#303640}
.merchant-detail-copy{justify-self:start;min-height:32px;padding:0 13px;border:1px solid #dfe4eb;border-radius:999px;background:#fff;color:#4d5665;font-size:11px;font-weight:850;line-height:1;cursor:pointer}
.merchant-detail-copy:hover{border-color:#c6ced9;background:#f8fafc}
.merchant-detail-copy:active{transform:translateY(1px)}
.merchant-image-lightbox{z-index:420!important;display:block!important;inset:0;background:rgba(13,16,22,.95);touch-action:none}
.merchant-image-lightbox.hidden{display:none!important}
.merchant-image-lightbox-viewer{position:relative;display:block;width:100%;height:100dvh;box-sizing:border-box;padding:14px 12px calc(76px + env(safe-area-inset-bottom))}
.merchant-image-lightbox-frame{display:flex;align-items:center;justify-content:center;width:100%;height:100%;min-width:0;min-height:0}
.merchant-image-lightbox-stage{display:flex;align-items:center;justify-content:center;width:100%;height:100%;min-width:0;min-height:0;overflow:hidden;touch-action:none}
.merchant-image-lightbox-stage img{display:block;width:auto;height:auto;max-width:100%;max-height:100%;object-fit:contain;object-position:center;border-radius:8px;box-shadow:0 18px 46px rgba(0,0,0,.28);transform-origin:center;touch-action:none;user-select:none;-webkit-user-drag:none;will-change:transform}
.merchant-image-lightbox-close{position:absolute;left:50%;bottom:16px;z-index:3;min-width:104px;height:36px;padding:0 18px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:rgba(255,255,255,.14);backdrop-filter:blur(12px);color:#fff;font-size:12px;font-weight:800;transform:translateX(-50%);cursor:pointer}
.merchant-image-lightbox-close:active{background:rgba(255,255,255,.25)}

.merchant-empty{border-radius:20px;background:#f8f9fd;color:#8b91a2;text-align:center;padding:28px 12px;font-size:14px;font-weight:800}
.toast{position:fixed;z-index:200;left:50%;top:24px;transform:translateX(-50%);max-width:86vw;padding:11px 15px;border-radius:999px;background:#111;color:#fff;font-size:13px;font-weight:900;box-shadow:0 12px 34px rgba(0,0,0,.2)}
.toast[data-type="success"]{background:#12a66a}
.toast[data-type="error"]{background:#ff4056}

/* B2/Qmsg-style global notices for every merchant-backend view. */
.merchant-mobile-page .toast {
  box-sizing:border-box;
  top:max(20px,calc(env(safe-area-inset-top) + 18px));
  z-index:999999;
  max-width:none;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
  box-shadow:none;
  color:#333;
  pointer-events:none;
  animation:merchantB2ToastIn .24s cubic-bezier(.2,.8,.2,1) both;
}
.merchant-mobile-page .toast-content {
  display:inline-flex;
  align-items:center;
  width:max-content;
  max-width:calc(100vw - 32px);
  min-height:40px;
  padding:9px 14px;
  border-radius:4px;
  background:#fff;
  box-shadow:0 4px 12px rgba(0,0,0,.15);
  color:#333;
  line-height:1.35;
  pointer-events:auto;
}
.merchant-mobile-page .toast-icon {
  display:inline-grid;
  place-items:center;
  width:16px;
  height:16px;
  margin-right:8px;
  flex:0 0 16px;
  color:#1890ff;
}
.merchant-mobile-page .toast-icon svg { display:block; width:16px; height:16px; fill:currentColor; }
.merchant-mobile-page .toast-text { min-width:0; overflow-wrap:anywhere; }
.merchant-mobile-page .toast[data-type="success"] .toast-icon { color:#52c41a; }
.merchant-mobile-page .toast[data-type="error"] .toast-icon { color:#ff4d4f; }
.merchant-mobile-page .toast[data-type="warning"] .toast-icon { color:#faad14; }
@keyframes merchantB2ToastIn {
  from { opacity:0; transform:translate(-50%,-10px) scale(.96); }
  to { opacity:1; transform:translate(-50%,0) scale(1); }
}

@media (max-width:380px){
  .merchant-home-hero{margin:0 10px;padding-left:14px;padding-right:14px}
  .merchant-home-main,.merchant-page{padding-left:10px;padding-right:10px}
  .merchant-round-btn{width:50px}
  .merchant-round-btn,.merchant-wide-btn{height:50px}
  .merchant-mark{font-size:29px}
  .merchant-top-title strong{font-size:17px}
  .merchant-stats-grid strong{font-size:18px}
  .merchant-function-tile{min-height:104px}
  .merchant-function-tile i{width:56px;height:56px}
  .product-card{grid-template-columns:76px minmax(0,1fr)}
  .merchant-product-cover{width:76px;height:76px}
  .merchant-form-grid{grid-template-columns:1fr}
}

@media (min-width:721px){
  .merchant-shell{padding-top:18px}
  .merchant-home-hero{border-radius:30px}
}

/* 85% merchant interface density */
@media (max-width:720px){
  .merchant-shell{padding-bottom:100px}
  .merchant-auth-screen{place-items:start center;padding-top:calc(54px + env(safe-area-inset-top))}.merchant-auth-shell{width:min(100%,366px);padding:18px}.merchant-auth-brand{margin-bottom:18px}.merchant-auth-logo{font-size:29px}.merchant-auth-subtitle{font-size:13px}.merchant-auth-card{padding:16px;border-radius:24px}.merchant-auth-tabs{gap:7px;margin-bottom:13px}.merchant-auth-tab{height:40px}.merchant-auth-form{gap:11px}.merchant-auth-form label{gap:7px;font-size:11px}.merchant-auth-form input,.captcha-code{height:43px;border-radius:14px}.merchant-captcha-field{grid-template-columns:minmax(0,1fr) 120px;gap:7px}
  .merchant-home{width:min(100%,408px)}.merchant-home-hero{height:132px;margin:0 12px;padding:20px 17px 43px;border-radius:0 0 26px 26px}.merchant-top-title strong{font-size:20px}.merchant-top-title span{margin-top:5px;font-size:10px}
  .merchant-home-main{gap:12px;margin-top:-24px;padding:0 12px}.merchant-card,.merchant-shop-card,.merchant-function-grid{border-radius:24px}.merchant-shop-card{padding:15px}.merchant-shop-row{gap:12px}.merchant-shop-avatar{width:61px;height:61px;border-radius:19px;font-size:26px}.merchant-shop-info h1{font-size:20px}.merchant-shop-info p{margin-top:6px;font-size:12px}.merchant-store-actions{gap:8px;margin-top:11px}.merchant-promote-btn,.merchant-store-link-btn{height:40px;padding:0 14px;font-size:11px}.merchant-stats-grid{gap:7px;margin-top:15px;padding-top:14px}.merchant-stats-grid strong{font-size:18px}.merchant-stats-grid span{margin-top:6px;font-size:10px}
  .merchant-home-logout{width:82px;height:40px;gap:5px;padding-inline:8px;border-radius:14px;font-size:10px}.merchant-home-logout img{width:16px;height:16px}
  .merchant-function-grid{gap:10px;padding:14px}.merchant-function-tile{min-height:95px;border-radius:20px;gap:8px}.merchant-function-tile i{width:53px;height:53px;border-radius:17px;font-size:20px}.merchant-function-tile span{font-size:13px}.merchant-function-tile em{top:8px;right:12px}
  .merchant-home-list{padding:14px}.merchant-card-head{gap:10px;margin-bottom:10px}.merchant-card-head strong{font-size:15px}.merchant-text-btn{font-size:11px}.merchant-sales-tabs{gap:4px;margin-bottom:10px;padding:3px;border-radius:13px}.merchant-sales-tabs button{height:31px;border-radius:10px;font-size:10px}.merchant-mini-list{gap:8px}.merchant-mini-item,.merchant-mini-row{border-radius:15px;padding:8px;gap:8px}.merchant-mini-item img,.merchant-mini-item i{width:40px;height:40px;border-radius:12px}.merchant-mini-item b,.merchant-mini-row b{font-size:12px}.merchant-mini-item small,.merchant-mini-row small{font-size:10px}.merchant-sales-rank-item>strong{font-size:10px}.merchant-rank-number{width:20px;height:20px;flex-basis:20px;border-radius:7px;font-size:10px}
  .merchant-page{width:min(100%,408px);padding:13px 12px 0}.merchant-page-topbar{height:71px;grid-template-columns:54px minmax(0,1fr) 54px}.merchant-page-topbar strong{font-size:19px}.merchant-page-back{width:50px;height:50px}.merchant-page-back svg{width:22px;height:22px}.merchant-page-body,.merchant-subpage{gap:10px}.merchant-card{padding:13px}
  .merchant-filter-row{grid-template-columns:minmax(0,1fr) 42px;gap:7px;margin-bottom:8px}.merchant-input,.merchant-select{height:42px;padding:0 11px;border-radius:14px;font-size:12px}.merchant-textarea{min-height:78px;padding:11px;border-radius:14px;font-size:12px}.merchant-textarea.tall{min-height:178px}.merchant-icon-action{height:42px;border-radius:14px}.merchant-icon-action svg{width:18px;height:18px}.merchant-action-row{gap:8px}.merchant-primary-btn,.merchant-plain-btn,.merchant-danger-btn{height:43px;border-radius:15px;font-size:12px}.merchant-primary-btn.compact,.merchant-plain-btn.compact,.merchant-danger-btn.compact{height:42px}.merchant-order-tabs{gap:6px}.merchant-order-tabs button{height:36px;font-size:11px}.merchant-store-share{gap:6px;margin-top:11px}.merchant-store-share .merchant-promote-btn,.merchant-store-link{height:38px;padding-inline:11px;font-size:10px}.merchant-store-link span{font-size:10px}.merchant-form-field{gap:7px;font-size:11px}.merchant-image-picker{gap:7px}.merchant-image-add,.merchant-image-item{width:76px;height:76px;border-radius:15px}.merchant-image-add b{font-size:28px}.merchant-image-add span{font-size:10px}.merchant-image-item>span{font-size:9px}.merchant-image-item>button{width:20px;height:20px;font-size:15px}.merchant-tag-chip{height:28px;font-size:11px}.merchant-image-viewer{gap:8px}.merchant-image-viewer img{border-radius:13px}
  .merchant-delivery-textarea{min-height:104px}.merchant-delivery-field-row{grid-template-columns:minmax(0,1fr) minmax(0,1fr) 44px;gap:6px}.merchant-delete-field-btn{height:42px;border-radius:14px;padding:0 6px;font-size:11px}.merchant-add-field-btn{height:34px;font-size:11px}
  .merchant-card-list{gap:10px}.merchant-list-card{border-radius:20px;padding:12px}.product-card{grid-template-columns:73px minmax(0,1fr);gap:10px}.merchant-product-media{width:73px;gap:6px}.merchant-product-cover{width:73px;height:73px;border-radius:17px}.merchant-product-cover span{font-size:24px}.merchant-product-check{height:27px;border-radius:9px}.merchant-card-title-row h3{font-size:14px}.merchant-product-main p,.order-card p{margin-top:5px;font-size:10px}.merchant-product-meta,.merchant-order-meta{gap:8px;margin-top:7px}.merchant-product-meta strong,.merchant-order-meta strong{font-size:14px}.merchant-product-meta span,.merchant-order-meta span{font-size:10px}.merchant-card-actions{gap:7px;margin-top:8px}.merchant-card-actions button{height:32px;padding:0 11px;font-size:10px}.merchant-badge{min-width:45px;height:23px;padding:0 8px;font-size:10px}
  .merchant-stock-code strong{font-size:13px}.merchant-stock-code small,.merchant-list-time{margin-top:6px;font-size:10px}.merchant-stock-side button{height:30px;font-size:10px}.merchant-profit-line{font-size:10px;padding:7px 8px;border-radius:10px}
  .merchant-wallet-summary{gap:8px}.merchant-wallet-summary div{min-height:80px;border-radius:20px;padding:14px}.merchant-wallet-summary span{font-size:10px}.merchant-wallet-summary strong{margin-top:8px;font-size:20px}.merchant-form-grid{gap:10px}.merchant-form-grid label{gap:7px;font-size:11px}.merchant-switch-row{gap:8px;border-radius:14px;padding:10px}.merchant-file-line{height:42px;border-radius:14px}
  .merchant-store-profile{gap:11px}.merchant-store-profile h2{font-size:19px}.merchant-store-profile p{margin-top:6px;font-size:11px}.merchant-store-metrics{gap:8px;margin:14px 0}.merchant-store-metrics div{border-radius:15px;padding:11px}.merchant-store-metrics strong{font-size:15px}.merchant-store-metrics span{font-size:10px}
  .merchant-bottom-capsule{bottom:calc(12px + env(safe-area-inset-bottom));width:min(86vw,366px);gap:5px;padding:9px}.merchant-bottom-item{gap:4px;padding:6px 3px}.merchant-bottom-item span{width:28px;height:28px;border-radius:9px;font-size:12px}.merchant-bottom-item b{font-size:10px}.merchant-bottom-item em{top:4px;right:15px}
  .merchant-sheet-card{width:min(100%,408px);padding:14px 14px calc(16px + env(safe-area-inset-bottom));border-radius:24px 24px 0 0}.merchant-sheet-head{margin:-14px -14px 12px;padding:14px}.merchant-sheet-head strong{font-size:15px}.merchant-sheet-head button{height:32px;font-size:10px}.merchant-detail-block{gap:8px}.merchant-detail-title h3{font-size:15px}.merchant-detail-row{grid-template-columns:72px minmax(0,1fr);gap:8px;border-radius:13px;padding:9px}.merchant-detail-row span,.merchant-detail-row strong,.merchant-detail-content strong,.merchant-detail-content pre{font-size:11px}.merchant-detail-content{border-radius:13px;padding:10px}
  .merchant-home,.merchant-home-main,.merchant-shop-card,.merchant-function-grid,.merchant-home-list{min-width:0;max-width:100%}.merchant-home{overflow-x:hidden}.merchant-home-main>.merchant-shop-card,.merchant-home-main>.merchant-function-grid,.merchant-home-main>.merchant-card{width:100%}.merchant-mini-item,.merchant-mini-row{min-width:0;max-width:100%;overflow:hidden}.merchant-mini-item>span,.merchant-mini-row>span{min-width:0;max-width:100%}
}

/* Authentication stays deliberately denser than the store workspace. */
.merchant-auth-shell{width:min(100%,366px);padding:19px}
.merchant-auth-brand{margin-bottom:17px;padding:0 4px}
.merchant-auth-logo{font-size:29px}
.merchant-auth-subtitle{font-size:13px}
.merchant-auth-home{display:inline-flex;align-items:center;justify-content:center;min-width:48px;height:30px;border:1px solid rgba(255,255,255,.48);border-radius:999px;color:#fff;font-size:11px;font-weight:800;text-decoration:none}
.merchant-auth-card{padding:17px;border-radius:24px}
.merchant-auth-tabs{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin-bottom:13px}
.merchant-auth-tab{height:40px;padding:0 4px;font-size:12px}
.merchant-auth-form{gap:11px}
.merchant-auth-form label{gap:7px;font-size:11px}
.merchant-auth-form input,.merchant-auth-form textarea,.captcha-code{border:1px solid #e8ebf2;border-radius:14px;background:#fff;outline:none}
.merchant-auth-form input{height:43px;padding:0 12px}
.merchant-auth-form textarea{min-height:72px;padding:11px 12px;resize:vertical;line-height:1.45}
.merchant-auth-form input:focus,.merchant-auth-form textarea:focus{border-color:#ff9ab6;box-shadow:0 0 0 3px rgba(255,63,117,.12)}
  .merchant-auth-form .merchant-primary-btn{height:43px;border-radius:15px;font-size:12px}
  .merchant-captcha-field{grid-template-columns:minmax(0,1fr) 120px;gap:7px}
  .captcha-code{height:43px;color:#ff2f66;background:#fff0f5;font-size:13px;font-weight:900;cursor:pointer}
  .merchant-code-field{grid-template-columns:minmax(0,1fr) 94px;gap:7px}
  .merchant-code-btn{height:43px;border-radius:14px;font-size:11px}
.merchant-auth-note{margin:0;color:#8b91a2;font-size:10px;line-height:1.55;text-align:center}
.merchant-app-downloads{display:flex;align-items:center;justify-content:center;gap:14px;margin-top:14px}
.merchant-app-download-btn{display:grid;place-items:center;width:46px;height:46px;border:1px solid #e6e9ef;border-radius:50%;background:#fff;box-shadow:0 8px 20px rgba(31,37,61,.08);text-decoration:none;transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease}
.merchant-app-download-btn.android{border-color:#d8ebce;background:#f8fcf6}
.merchant-app-download-btn.ios{border-color:#e1e2e8;background:#fafafd}
.merchant-app-download-btn img{width:25px;height:25px;object-fit:contain}
.merchant-app-download-btn:active{transform:scale(.94);box-shadow:0 4px 12px rgba(31,37,61,.07)}
@media (max-width:380px){.merchant-auth-shell{padding:16px}.merchant-auth-tab{font-size:11px}.merchant-auth-card{padding:15px}.merchant-captcha-field{grid-template-columns:minmax(0,1fr) 112px}}

/* Merchant workspace frame: independent capsules with a shared content width. */
.merchant-app {
  --merchant-frame-width: min(calc(100vw - 16px), 424px);
  min-height: 100vh;
  min-height: 100dvh;
  padding: 0 0 calc(16px + env(safe-area-inset-bottom));
  background: #fff;
}

.merchant-app .merchant-home,
.merchant-app .merchant-page {
  width: var(--merchant-frame-width);
  max-width: var(--merchant-frame-width);
  margin: 0 auto;
}

.merchant-app .merchant-home {
  padding-bottom: calc(108px + env(safe-area-inset-bottom));
}

.merchant-app .merchant-home-hero {
  width: 100%;
  height: 58px;
  margin: 14px 0 0;
  padding: 0 18px;
  border: 1px solid #e7e9ee;
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(27, 32, 43, .07);
}

.merchant-app .merchant-topbar {
  color: #20242b;
  justify-content: space-between;
}

.merchant-app .merchant-top-title {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 9px;
}

.merchant-app .merchant-brand-icon {
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
  border-radius: 10px;
  object-fit: cover;
}

.merchant-app .merchant-top-title strong {
  color: #20242b;
  font-size: 18px;
}

.merchant-app .merchant-frontend-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  gap: 5px;
  height: 32px;
  padding: 0 11px;
  border: 1px solid #e8eaf0;
  border-radius: 999px;
  background: #f7f8fa;
  color: #3c424d;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.merchant-app .merchant-frontend-btn img {
  width: 15px;
  height: 15px;
  object-fit: contain;
}

.merchant-app .merchant-shop-info h1 {
  font-size: 18px;
}

.merchant-app .merchant-stats-grid span {
  font-size: 9px;
}

.merchant-app .merchant-stats-grid strong {
  font-size: 18px;
}

.merchant-app .merchant-home-main {
  gap: 14px;
  margin-top: 14px;
  padding: 0;
}

.merchant-app .merchant-home-main > .merchant-shop-card,
.merchant-app .merchant-home-main > .merchant-function-grid,
.merchant-app .merchant-home-main > .merchant-card {
  width: 100%;
  border: 1px solid #eceef2;
  box-shadow: 0 10px 28px rgba(27, 32, 43, .055);
}

.merchant-app .merchant-shop-card,
.merchant-app .merchant-function-grid,
.merchant-app .merchant-card {
  border-radius: 22px;
}

.merchant-app .merchant-function-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  border: 0 !important;
  background: transparent;
  box-shadow: none !important;
}

.merchant-app .merchant-function-tile {
  min-height: 88px;
  align-content: center;
  gap: 5px;
  border: 0 !important;
  border-radius: 16px;
  background: #fff;
  box-shadow: none;
}

.merchant-app .merchant-function-tile .merchant-function-icon {
  width: 43px;
  height: 43px;
  border: 0;
  border-radius: 14px;
  background: #f6f7f9 !important;
  color: #707070;
}

.merchant-app .merchant-function-tile .merchant-function-icon img {
  width: 23px;
  height: 23px;
  object-fit: contain;
}

.merchant-app .merchant-function-tile span:not(.merchant-function-icon) {
  color: #363b45;
  font-size: 12px;
  font-weight: 800;
}

.merchant-app .merchant-page {
  padding: 14px 0 0;
}

.merchant-app .merchant-page-topbar {
  width: 100%;
  height: 58px;
  grid-template-columns: 44px minmax(0, 1fr) 44px;
  padding: 0 7px;
  border: 1px solid #e7e9ee;
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(27, 32, 43, .07);
}

.merchant-app .merchant-page-topbar strong {
  color: #20242b;
  font-size: 18px;
}

.merchant-app .merchant-page-back {
  width: 42px;
  height: 42px;
  border: 1px solid #eceef2;
  border-radius: 50%;
  background: #f7f8fa;
  box-shadow: none;
}

.merchant-app .merchant-page-back svg {
  width: 20px;
  height: 20px;
  fill: #4c535e;
}

.merchant-app .merchant-page-body {
  gap: 12px;
  padding: 14px 0 calc(112px + env(safe-area-inset-bottom));
}

.merchant-app .merchant-subpage > .merchant-card,
.merchant-app .merchant-subpage > form.merchant-card,
.merchant-app .merchant-subpage > section.merchant-card {
  border: 1px solid #eceef2;
  box-shadow: 0 10px 28px rgba(27, 32, 43, .055);
}

.merchant-app .merchant-bottom-capsule {
  width: var(--merchant-frame-width);
  max-width: var(--merchant-frame-width);
  bottom: calc(12px + env(safe-area-inset-bottom));
  gap: 4px;
  padding: 6px;
  border: 1px solid #e5e7ec;
  border-radius: 25px;
  background: rgba(255, 255, 255, .97);
  box-shadow: 0 14px 32px rgba(27, 32, 43, .13);
  backdrop-filter: blur(18px);
}

.merchant-app .merchant-bottom-item {
  min-width: 0;
  gap: 3px;
  padding: 5px 3px;
  border-radius: 19px;
  color: #6d7480;
}

.merchant-app .merchant-bottom-item .merchant-bottom-icon {
  width: 31px;
  height: 31px;
  border: 1px solid #eceef2;
  border-radius: 11px;
  background: #f6f7f9;
  display: grid;
  place-items: center;
}

.merchant-app .merchant-bottom-item .merchant-bottom-icon img {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.merchant-app .merchant-bottom-item b {
  color: inherit;
  font-size: 10px;
  font-weight: 800;
}

.merchant-app .merchant-bottom-item.active {
  background: transparent;
  color: #20242b;
}

.merchant-app .merchant-bottom-item.active .merchant-bottom-icon {
  border-color: #20242b;
  background: #fff;
}

.merchant-app .merchant-button-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  object-fit: contain;
}

body.merchant-mobile-page .merchant-sheet-card {
  width: min(calc(100vw - 24px), 408px);
  max-width: min(calc(100vw - 24px), 408px);
}

.merchant-app .merchant-promote-btn,
.merchant-app .merchant-store-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.merchant-app .merchant-store-actions {
  grid-template-columns: 3fr 7fr;
  gap: 0;
  padding: 3px;
  border: 1px solid #ffd7e3;
  border-radius: 999px;
  background: #fff7fa;
  overflow: hidden;
}

.merchant-app .merchant-store-actions .merchant-promote-btn,
.merchant-app .merchant-store-actions .merchant-store-link-btn {
  min-width: 0;
  width: 100%;
  height: 34px;
  border: 0;
  border-radius: 999px;
}

.merchant-app .merchant-store-actions .merchant-store-link-btn {
  justify-content: flex-start;
  overflow: hidden;
  background: transparent;
  color: #ff2f66;
}

.merchant-app .merchant-store-actions #merchantStoreLink {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.merchant-app .merchant-promote-btn .merchant-button-icon {
  filter: brightness(0) invert(1);
}

@media (max-width: 380px) {
  .merchant-app {
    --merchant-frame-width: calc(100vw - 14px);
  }

  .merchant-app .merchant-home-hero {
    height: 54px;
    margin-top: 10px;
    padding-inline: 14px;
    border-radius: 22px;
  }

  .merchant-app .merchant-top-title strong {
    font-size: 18px;
  }

  .merchant-app .merchant-top-title span {
    font-size: 10px;
  }

  .merchant-app .merchant-page {
    padding-top: 10px;
  }

  .merchant-app .merchant-page-topbar {
    height: 54px;
    grid-template-columns: 40px minmax(0, 1fr) 40px;
    border-radius: 22px;
  }

  .merchant-app .merchant-page-back {
    width: 38px;
    height: 38px;
  }

  body.merchant-mobile-page .merchant-sheet-card {
    width: calc(100vw - 20px);
    max-width: calc(100vw - 20px);
  }
}

/* Keep the merchant workspace locked to a vertical mobile canvas. */
html:has(body.merchant-mobile-page),
body.merchant-mobile-page {
  overflow-x: hidden;
  overscroll-behavior-x: none;
}

body.merchant-mobile-page {
  width: 100%;
  max-width: 100%;
  touch-action: pan-y;
}

body.merchant-mobile-page .merchant-app {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: clip;
}

body.merchant-mobile-page .merchant-app > *,
body.merchant-mobile-page .merchant-app .merchant-home,
body.merchant-mobile-page .merchant-app .merchant-page,
body.merchant-mobile-page .merchant-app .merchant-page-body {
  min-width: 0;
  max-width: 100%;
}

body.merchant-mobile-page .merchant-sheet-card {
  width: min(calc(100vw - 16px), 424px);
  max-width: min(calc(100vw - 16px), 424px);
}

/* Desktop merchant workspace: keep every visible surface on one centered frame. */
@media (min-width: 721px) {
  body.merchant-mobile-page {
    overflow-x: hidden;
    overflow-y: auto;
  }

  body.merchant-mobile-page .merchant-app {
    --merchant-frame-width: min(960px, calc(100vw - 64px));
    width: 100%;
    max-width: none;
    min-width: 0;
    padding: 0 0 calc(108px + env(safe-area-inset-bottom));
  }

  body.merchant-mobile-page .merchant-app .merchant-home,
  body.merchant-mobile-page .merchant-app .merchant-page,
  body.merchant-mobile-page .merchant-app .merchant-bottom-capsule {
    width: var(--merchant-frame-width);
    max-width: var(--merchant-frame-width);
  }

  body.merchant-mobile-page .merchant-app .merchant-home {
    padding-bottom: calc(112px + env(safe-area-inset-bottom));
  }

  body.merchant-mobile-page .merchant-app .merchant-home-hero {
    height: 64px;
    margin-top: 18px;
    padding-inline: 22px;
    border-radius: 32px;
  }

  body.merchant-mobile-page .merchant-app .merchant-top-title {
    gap: 11px;
  }

  body.merchant-mobile-page .merchant-app .merchant-brand-icon {
    width: 31px;
    height: 31px;
    flex-basis: 31px;
  }

  body.merchant-mobile-page .merchant-app .merchant-top-title strong {
    font-size: 20px;
  }

  body.merchant-mobile-page .merchant-app .merchant-frontend-btn {
    height: 36px;
    padding-inline: 14px;
    font-size: 13px;
  }

  body.merchant-mobile-page .merchant-app .merchant-home-main {
    gap: 16px;
    margin-top: 16px;
  }

  body.merchant-mobile-page .merchant-app .merchant-shop-card {
    padding: 23px;
    border-radius: 24px;
  }

  body.merchant-mobile-page .merchant-app .merchant-shop-row {
    gap: 17px;
  }

  body.merchant-mobile-page .merchant-app .merchant-shop-avatar {
    width: 82px;
    height: 82px;
    border-radius: 24px;
  }

  body.merchant-mobile-page .merchant-app .merchant-shop-info h1 {
    font-size: 22px;
  }

  body.merchant-mobile-page .merchant-app .merchant-shop-info p {
    margin-top: 8px;
    font-size: 14px;
  }

  body.merchant-mobile-page .merchant-app .merchant-home-logout {
    width: 112px;
    height: 44px;
    border-radius: 15px;
    font-size: 13px;
  }

  body.merchant-mobile-page .merchant-app .merchant-store-actions {
    margin-top: 17px;
  }

  body.merchant-mobile-page .merchant-app .merchant-store-actions .merchant-promote-btn,
  body.merchant-mobile-page .merchant-app .merchant-store-actions .merchant-store-link-btn {
    height: 38px;
    font-size: 12px;
  }

  body.merchant-mobile-page .merchant-app .merchant-stats-grid {
    margin-top: 20px;
    padding-top: 18px;
  }

  body.merchant-mobile-page .merchant-app .merchant-stats-grid strong {
    font-size: 20px;
  }

  body.merchant-mobile-page .merchant-app .merchant-stats-grid span {
    margin-top: 8px;
    font-size: 11px;
  }

  body.merchant-mobile-page .merchant-app .merchant-function-grid {
    gap: 10px;
  }

  body.merchant-mobile-page .merchant-app .merchant-function-tile {
    min-height: 104px;
    border-radius: 18px;
  }

  body.merchant-mobile-page .merchant-app .merchant-function-tile .merchant-function-icon {
    width: 48px;
    height: 48px;
    border-radius: 15px;
  }

  body.merchant-mobile-page .merchant-app .merchant-function-tile .merchant-function-icon img {
    width: 25px;
    height: 25px;
  }

  body.merchant-mobile-page .merchant-app .merchant-function-tile span:not(.merchant-function-icon) {
    font-size: 13px;
  }

  body.merchant-mobile-page .merchant-app .merchant-home-list {
    padding: 20px;
    border-radius: 24px;
  }

  body.merchant-mobile-page .merchant-app .merchant-card-head strong {
    font-size: 20px;
  }

  body.merchant-mobile-page .merchant-app .merchant-mini-item,
  body.merchant-mobile-page .merchant-app .merchant-mini-row {
    padding: 12px;
    border-radius: 16px;
  }

  body.merchant-mobile-page .merchant-app .merchant-mini-item b,
  body.merchant-mobile-page .merchant-app .merchant-mini-row b {
    font-size: 14px;
  }

  body.merchant-mobile-page .merchant-app .merchant-page {
    padding-top: 18px;
  }

  body.merchant-mobile-page .merchant-app .merchant-page-topbar {
    height: 64px;
    grid-template-columns: 48px minmax(0, 1fr) 48px;
    padding-inline: 8px;
    border-radius: 32px;
  }

  body.merchant-mobile-page .merchant-app .merchant-page-topbar strong {
    font-size: 20px;
  }

  body.merchant-mobile-page .merchant-app .merchant-page-back {
    width: 46px;
    height: 46px;
  }

  body.merchant-mobile-page .merchant-app .merchant-page-body {
    gap: 16px;
    padding-top: 16px;
    padding-bottom: calc(112px + env(safe-area-inset-bottom));
  }

  body.merchant-mobile-page .merchant-app .merchant-bottom-capsule {
    bottom: calc(18px + env(safe-area-inset-bottom));
    gap: 6px;
    padding: 7px;
    border-radius: 28px;
  }

  body.merchant-mobile-page .merchant-app .merchant-bottom-item {
    padding-block: 6px;
  }

  body.merchant-mobile-page .merchant-app .merchant-bottom-item b {
    font-size: 11px;
  }

  body.merchant-mobile-page > .merchant-sheet:not(.merchant-image-lightbox) .merchant-sheet-card {
    width: min(680px, calc(100vw - 64px));
    max-width: min(680px, calc(100vw - 64px));
  }
}

@media (max-width: 380px) {
  body.merchant-mobile-page .merchant-sheet-card {
    width: calc(100vw - 14px);
    max-width: calc(100vw - 14px);
  }
}

/* Product editor: single-column fields with three focused sections. */
.merchant-app .merchant-product-form-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  width: 100%;
  margin-bottom: 10px;
  padding: 4px;
  border: 1px solid #e8eaf0;
  border-radius: 18px;
  background: #f7f8fa;
}

.merchant-app .merchant-product-form-tabs button {
  min-width: 0;
  height: 38px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: #7b8290;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.merchant-app .merchant-product-form-tabs button.active {
  background: #fff;
  color: #20242b;
  box-shadow: 0 4px 12px rgba(27, 32, 43, .08);
}

.merchant-app #merchantProductForm {
  grid-template-columns: 1fr;
  gap: 12px;
}

.merchant-app #merchantProductForm .merchant-product-form-panel {
  display: none;
  grid-column: 1 / -1;
  gap: 12px;
  min-width: 0;
}

.merchant-app #merchantProductForm .merchant-product-form-panel.active {
  display: grid;
}

.merchant-app #merchantProductForm .merchant-product-form-panel > label,
.merchant-app #merchantProductForm > .merchant-primary-btn {
  grid-column: 1 / -1;
}

/* Order detail sheet: keep the title fixed and scroll only the detail body. */
body.merchant-mobile-page #merchantOrderSheet .merchant-order-sheet-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

body.merchant-mobile-page #merchantOrderSheet .merchant-sheet-head {
  position: relative;
  top: auto;
  flex: 0 0 auto;
  margin: 0 0 14px;
  padding: 0 0 12px;
  background: #fff;
  border-bottom: 1px solid #f0f2f6;
}

/* Stock import uses a fixed header and a separately scrollable form. */
body.merchant-mobile-page #merchantStockSheet .merchant-sheet-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

body.merchant-mobile-page #merchantStockSheet .merchant-sheet-head {
  position: relative;
  top: auto;
  flex: 0 0 auto;
  margin: 0 0 12px;
  padding: 0 0 12px;
  background: #fff;
  border-bottom: 1px solid #f0f2f6;
}

body.merchant-mobile-page #merchantStockSheet .sheet-form {
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 2px 1px 4px;
}

/* Reject order is a compact, self-contained action sheet. */
body.merchant-mobile-page #merchantRejectSheet .merchant-reject-sheet-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(76vh, 540px);
  overflow: hidden;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-sheet-head {
  position: relative;
  top: auto;
  flex: 0 0 auto;
  margin: 0;
  padding: 0 0 13px;
  background: #fff;
  border-bottom: 1px solid #f0f2f6;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-reject-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 13px;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 14px 1px 2px;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-reject-reason {
  display: grid;
  gap: 8px;
  min-width: 0;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-reject-reason span {
  color: #545c6d;
  font-size: 12px;
  font-weight: 800;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-reject-reason textarea {
  min-height: 126px;
  resize: vertical;
  line-height: 1.55;
}

body.merchant-mobile-page #merchantRejectSheet .merchant-danger-btn {
  width: 100%;
  margin-top: 1px;
}

body.merchant-mobile-page #merchantOrderSheet .merchant-order-detail-scroll {
  min-height: 0;
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 0 1px calc(24px + env(safe-area-inset-bottom));
  overscroll-behavior: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

body.merchant-mobile-page #merchantOrderSheet .merchant-order-detail-scroll::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

/* Agent pricing, bindings and after-sales use the same compact merchant workspace. */
.merchant-app .merchant-switch-row {
  position: relative;
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr);
  min-height: 46px;
  gap: 10px;
  padding: 8px 11px;
  cursor: pointer;
}

.merchant-app .merchant-switch-row input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.merchant-app .merchant-switch-row i {
  position: relative;
  display: block;
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: #d8dce3;
  box-shadow: inset 0 0 0 1px rgba(39, 45, 55, .05);
  transition: background .2s ease;
}

.merchant-app .merchant-switch-row i::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(28, 34, 45, .2);
  transition: transform .2s ease;
  content: "";
}

.merchant-app .merchant-switch-row input:checked + i { background: #24272d; }
.merchant-app .merchant-switch-row input:checked + i::after { transform: translateX(18px); }
.merchant-app .merchant-switch-row input:focus-visible + i { outline: 3px solid rgba(255, 63, 117, .18); }
.merchant-app .merchant-agent-price-field small { margin-top: -2px; color: var(--m-muted); font-size: 11px; line-height: 1.45; }
.merchant-app .merchant-group-config{display:grid;gap:10px;min-width:0;padding:10px;border:1px solid #eceef2;border-radius:10px;background:#fafbfc}
.merchant-app .merchant-group-tier-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;min-width:0}
.merchant-app .merchant-group-tier{display:grid;gap:8px;min-width:0;padding:9px;border:1px solid #e7eaee;border-radius:10px;background:#fff}
.merchant-app .merchant-group-tier .merchant-switch-row{min-height:34px;padding:4px 0;border:0;background:transparent}
.merchant-app .merchant-group-tier label:last-child{display:grid;gap:5px;min-width:0;color:#6b7280;font-size:10px;font-weight:750}
.merchant-app .merchant-group-tier .merchant-input{min-width:0;padding-inline:8px;font-size:11px}
@media (max-width:520px){.merchant-app .merchant-group-tier-grid{grid-template-columns:1fr}.merchant-app .merchant-group-tier{grid-template-columns:minmax(0,1fr) minmax(110px,1fr);align-items:center}}
.merchant-app .merchant-offer-schedule { display: grid; gap: 9px; min-width: 0; padding: 10px; border: 1px solid #eceef2; border-radius: 10px; background: #fafbfc; }
.merchant-app .merchant-offer-schedule > .merchant-switch-row { min-height: 42px; padding: 6px 8px; border: 0; background: transparent; }
.merchant-app .merchant-offer-schedule-body { display: grid; gap: 9px; min-width: 0; padding-top: 9px; border-top: 1px solid #eceef2; }
.merchant-app .merchant-offer-schedule-body > label,.merchant-app .merchant-offer-time-grid > label { display: grid; gap: 6px; min-width: 0; }
.merchant-app .merchant-offer-schedule-body label > span { color: #6b7280; font-size: 10px; font-weight: 750; }
.merchant-app .merchant-offer-time-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; min-width: 0; }
.merchant-app .merchant-offer-time-grid .merchant-input { min-width: 0; padding-inline: 9px; font-size: 11px; }
.merchant-app .merchant-agent-price { color: #5369d8 !important; font-weight: 850; }
.merchant-app .merchant-product-flag { display: inline-grid; place-items: center; height: 22px; padding: 0 8px; border-radius: 999px; font-weight: 850; }
.merchant-app .merchant-product-flag.free { background: #e9f9f1; color: #15965f; }
.merchant-app .merchant-product-flag.activity { background: #fff1f4; color: #e84969; }
.merchant-app .merchant-product-flag.blind-box { background: #fff0e4; color: #b95f24; }
.merchant-app .merchant-product-flag.related { background: #eef4ff; color: #3768b8; }
.merchant-app .merchant-product-flag.gift { background: #fff4df; color: #b87413; }
.merchant-app .merchant-product-time { flex: 1 1 100%; color: #8a5360; font-size: 9px; font-weight: 700; line-height: 1.4; white-space: normal; }

@media (max-width: 360px) {
  .merchant-app .merchant-offer-time-grid { grid-template-columns: 1fr; }
}

.merchant-app .merchant-gift-field { position: relative; display: grid; gap: 8px; min-width: 0; }
.merchant-app .merchant-gift-field > span { color: var(--m-text); font-size: 12px; font-weight: 850; }
.merchant-app .merchant-gift-field > small { color: var(--m-muted); font-size: 10px; line-height: 1.5; }
.merchant-app .merchant-gift-selected { display: grid; gap: 7px; min-width: 0; }
.merchant-app .merchant-gift-selected-item { display: grid; grid-template-columns: 48px minmax(0, 1fr) 30px; align-items: center; gap: 9px; min-width: 0; padding: 7px; border: 1px solid #eceef2; border-radius: 8px; background: #fff; }
.merchant-app .merchant-gift-selected-item > img { width: 48px; height: 48px; border-radius: 7px; object-fit: cover; background: #f3f4f6; }
.merchant-app .merchant-gift-selected-item > div { display: grid; gap: 3px; min-width: 0; }
.merchant-app .merchant-gift-selected-item strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.merchant-app .merchant-gift-selected-item span,.merchant-app .merchant-gift-selected-item small { overflow: hidden; color: var(--m-muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.merchant-app .merchant-gift-selected-item > button { display: grid; place-items: center; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 50%; background: #fff0f3; color: #df4967; font-size: 18px; line-height: 1; }
.merchant-app .merchant-gift-picker { position: relative; min-width: 0; }
.merchant-app .merchant-gift-options { position: absolute; inset: calc(100% + 5px) 0 auto; z-index: 80; display: grid; gap: 4px; max-height: 230px; overflow-y: auto; padding: 6px; border: 1px solid #e5e8ed; border-radius: 8px; background: #fff; box-shadow: 0 12px 28px rgba(24,29,37,.14); overscroll-behavior: contain; }
.merchant-app .merchant-gift-option { display: grid; grid-template-columns: 42px minmax(0, 1fr); align-items: center; gap: 8px; width: 100%; min-width: 0; padding: 6px; border: 0; border-radius: 7px; background: #fff; color: var(--m-text); text-align: left; }
.merchant-app .merchant-gift-option:hover,.merchant-app .merchant-gift-option:focus-visible { background: #f5f6f8; }
.merchant-app .merchant-gift-option img { width: 42px; height: 42px; border-radius: 6px; object-fit: cover; background: #f3f4f6; }
.merchant-app .merchant-gift-option span { display: grid; gap: 4px; min-width: 0; }
.merchant-app .merchant-gift-option strong,.merchant-app .merchant-gift-option small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.merchant-app .merchant-gift-option strong { font-size: 11px; }
.merchant-app .merchant-gift-option small,.merchant-app .merchant-gift-empty { color: var(--m-muted); font-size: 10px; }
.merchant-app .merchant-gift-empty { padding: 8px 3px; }

.merchant-agent-bind { display: grid; grid-template-columns: minmax(0, 1fr) 92px; gap: 8px; }
.merchant-agent-bind .merchant-primary-btn { height: 42px; border-radius: 14px; }
.merchant-agent-candidate { margin-top: 2px; }
.merchant-agent-candidate.hidden { display: none; }
.merchant-agent-list-search { margin-top: 3px; }
.merchant-agent-search-card { border-color: #dfe9ff; background: #fbfdff; }
.merchant-agent-search-card .merchant-card-actions { justify-content: flex-end; }
.merchant-badge.blue { background: #eef4ff; color: #3978d5; }
.merchant-page-note { margin: 0; padding: 0 2px; color: #8a909c; font-size: 11px; line-height: 1.55; }
.merchant-agent-card { display: grid; grid-template-columns: 50px minmax(0, 1fr); gap: 10px; }
.merchant-agent-card > img { width: 50px; height: 50px; border: 1px solid #eceef2; border-radius: 15px; object-fit: cover; background: #f4f5f7; }
.merchant-agent-copy { min-width: 0; }
.merchant-agent-copy p { margin: 3px 0; color: #8a909b; font-size: 11px; }
.merchant-agent-copy code { display: block; overflow: hidden; color: #545b67; font: 700 11px/1.35 ui-monospace, SFMono-Regular, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.merchant-agent-card .merchant-card-actions { grid-column: 1 / -1; justify-content: flex-end; margin-top: 0; }
.merchant-card-actions button.primary { background: #eef4ff; color: #3978d5; }
.merchant-agent-action-bar{grid-column:1 / -1;display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0;margin-top:1px}
.merchant-agent-stats{min-width:0;overflow:hidden;color:#6f7684;font-size:11px;line-height:1.4;white-space:nowrap;text-overflow:ellipsis}
.merchant-agent-action-bar .merchant-card-actions{flex:0 0 auto}

.merchant-after-sale-card { display: grid; gap: 8px; }
.merchant-after-sale-card > p { margin: 0; }
.merchant-after-sale-card .merchant-card-title-row h3 { overflow-wrap: anywhere; }
.merchant-after-sale-unread { display: inline-grid; place-items: center; width: 17px; height: 17px; margin-left: 6px; border-radius: 50%; background: #ff4056; color: #fff; font-size: 11px; font-style: normal; font-weight: 900; line-height: 1; vertical-align: 2px; box-shadow: 0 3px 9px rgba(255,64,86,.24); }
.merchant-after-sale-question,
.merchant-after-sale-info { display: grid; gap: 4px; padding: 10px 11px; border-radius: 12px; background: #f7f8fa; }
.merchant-after-sale-question span,
.merchant-after-sale-info span { color: #979ca6; font-size: 10px; font-weight: 800; }
.merchant-after-sale-question p,
.merchant-after-sale-info p { margin: 0; color: #41464f; font-size: 12px; line-height: 1.55; white-space: pre-line; overflow-wrap: anywhere; }
.merchant-after-sale-summary { display: grid; gap: 4px; margin-bottom: 13px; padding: 11px 12px; border-radius: 13px; background: #f7f8fa; }
.merchant-after-sale-summary strong { font-size: 14px; }
.merchant-after-sale-summary span { color: #9298a3; font-size: 10px; }
.merchant-after-sale-summary p { margin: 4px 0 0; color: #555c67; font-size: 12px; line-height: 1.55; white-space: pre-line; }
.merchant-after-sale-conversation { display: grid; gap: 9px; min-width: 0; }
.merchant-after-sale-message { display: grid; gap: 5px; width: 92%; padding: 10px 11px; border-radius: 13px; background: #f5f6f8; }
.merchant-after-sale-message.is-merchant { justify-self: end; background: #eef4ff; }
.merchant-after-sale-message > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.merchant-after-sale-message strong { color: #656c77; font-size: 10px; }
.merchant-after-sale-message time { color: #9ba0aa; font-size: 9px; }
.merchant-after-sale-message p { margin: 0; color: #343943; font-size: 12px; line-height: 1.55; white-space: pre-line; overflow-wrap: anywhere; }
.merchant-after-sale-empty { padding: 18px 10px; color: #969ca7; font-size: 11px; text-align: center; }
.merchant-detail-after-sale { gap: 9px; }
body.merchant-mobile-page #merchantAfterSaleSheet .merchant-after-sale-sheet-card { display: flex; flex-direction: column; gap: 12px; max-height: min(86dvh, 700px); overflow: hidden; }
body.merchant-mobile-page #merchantAfterSaleSheet .merchant-sheet-head { position: relative; flex: 0 0 auto; margin: 0; padding: 0 0 12px; }
body.merchant-mobile-page #merchantAfterSaleSheet > .merchant-after-sale-sheet-card > .merchant-after-sale-conversation { flex: 1 1 auto; min-height: 110px; overflow-y: auto; overscroll-behavior: contain; scroll-behavior: smooth; }
body.merchant-mobile-page #merchantAfterSaleSheet .merchant-after-sale-summary,
body.merchant-mobile-page #merchantAfterSaleSheet .sheet-form { flex: 0 0 auto; margin-bottom: 0; }

.merchant-app .merchant-function-tile:nth-child(7) i { background: linear-gradient(180deg, #6574df, #8994ef); }
.merchant-app .merchant-function-tile:nth-child(8) i { background: linear-gradient(180deg, #26ad82, #5ac9a5); }

@media (max-width: 380px) {
  .merchant-agent-bind { grid-template-columns: minmax(0, 1fr) 82px; }
  .merchant-agent-bind .merchant-primary-btn { padding: 0 8px; font-size: 11px; }
  .merchant-agent-action-bar{gap:6px}
  .merchant-agent-stats{font-size:10px}
}

/* Store cover uploader */
.merchant-background-picker{display:block;min-height:0;padding:0}
.merchant-background-picker .merchant-background-add,
.merchant-background-picker .merchant-background-preview{width:100%;height:124px;border-radius:10px}
.merchant-background-picker .merchant-background-add{display:grid;place-content:center;justify-items:center}
.merchant-background-picker .merchant-background-preview{position:relative;overflow:hidden;background:#f3f4f6}
.merchant-background-replace{position:absolute;inset:0;display:block;overflow:hidden;cursor:pointer}
.merchant-background-replace input{display:none}
.merchant-background-replace img{display:block;width:100%;height:100%;object-fit:cover}
.merchant-background-replace span{position:absolute;left:10px;bottom:9px;padding:4px 9px;border-radius:999px;background:rgba(18,20,24,.7);color:#fff;font-size:10px;font-weight:800;line-height:1.2;backdrop-filter:blur(5px)}
.merchant-background-preview>button{position:absolute;top:8px;right:8px;z-index:2;display:grid;place-items:center;width:25px;height:25px;padding:0;border:0;border-radius:50%;background:rgba(18,20,24,.72);color:#fff;font-size:17px;line-height:1;cursor:pointer}
@media (max-width:420px){.merchant-background-picker .merchant-background-add,.merchant-background-picker .merchant-background-preview{height:116px}}

/* Batch editing keeps the title bar above one dedicated scrolling content area. */
body.merchant-mobile-page #merchantProductBulkSheet {
  z-index: 180;
  isolation: isolate;
}

body.merchant-mobile-page #merchantProductBulkSheet .merchant-bulk-sheet-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(90dvh, 760px);
  overflow: hidden;
}

body.merchant-mobile-page #merchantProductBulkSheet .merchant-sheet-head {
  position: relative;
  top: auto;
  z-index: 3;
  flex: 0 0 auto;
  margin: 0 0 12px;
  padding: 0 0 12px;
  background: #fff;
  border-bottom: 1px solid #f0f2f6;
}

body.merchant-mobile-page #merchantProductBulkSheet .merchant-bulk-form {
  flex: 1 1 auto;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 1px 2px 8px;
}

body.merchant-mobile-page #merchantProductBulkSheet .merchant-bulk-form::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

body.merchant-mobile-page #merchantProductBulkSheet .merchant-bulk-form > .merchant-primary-btn {
  position: sticky;
  bottom: 0;
  z-index: 2;
  margin-top: 6px;
  background: linear-gradient(90deg, #ff2f66, #ff6e98);
  box-shadow: 0 -8px 14px rgba(255, 249, 251, .92), 0 10px 22px rgba(255, 47, 102, .18);
}

@media (max-width: 420px) {
  .merchant-bulk-schedule-range,
  .merchant-bulk-schedule-daily { grid-template-columns: minmax(0, 1fr); }
}

.merchant-wechat-bind-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 13px;border:1px solid #e8ebf2;border-radius:16px;background:#f9fafd}
.merchant-wechat-bind-row>div{display:grid;gap:4px;min-width:0}
.merchant-wechat-bind-row strong{color:#343943;font-size:13px;font-weight:900}
.merchant-wechat-bind-row small{color:var(--m-muted);font-size:11px;line-height:1.35;overflow-wrap:anywhere}
.merchant-wechat-bind-row small.is-bound{color:#23a477}
.merchant-wechat-bind-row .merchant-plain-btn{flex:0 0 auto;height:38px;padding:0 13px;border:0;border-radius:999px;background:#20232a;color:#fff;font-size:11px;font-weight:900}
.merchant-bark-form{margin-top:12px}
.merchant-bark-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-bottom:12px;border-bottom:1px solid #edf0f5}
.merchant-bark-heading>div{display:grid;gap:4px;min-width:0}
.merchant-bark-heading strong{color:#343943;font-size:15px;font-weight:900}
.merchant-bark-heading small{color:var(--m-muted);font-size:11px;line-height:1.5}
.merchant-bark-heading em{flex:0 0 auto;padding:5px 9px;border-radius:999px;background:#f0f2f6;color:#8b919f;font-size:10px;font-style:normal;font-weight:900}
.merchant-bark-heading em.is-bound{background:#e9f8f2;color:#1f9a70}
.merchant-bark-events{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.merchant-bark-events .merchant-switch-row{min-width:0;padding:10px}
.merchant-bark-events .merchant-switch-row span{font-size:11px;white-space:nowrap}
.merchant-bark-actions{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr) minmax(0,1fr);gap:8px}
.merchant-bark-actions button{min-width:0;padding-inline:8px;font-size:11px}
.merchant-bark-actions .merchant-plain-btn.danger{background:#fff0f2;color:#e94b62}
.merchant-bark-actions button:disabled{opacity:.45;cursor:not-allowed}
@media (max-width:380px){.merchant-bark-events{grid-template-columns:1fr}.merchant-bark-actions{grid-template-columns:1fr 1fr}.merchant-bark-actions .merchant-primary-btn{grid-column:1/-1}}
.merchant-wechat-qr-sheet-card{display:grid;gap:14px}
.merchant-wechat-qr-content{display:grid;justify-items:center;gap:10px;text-align:center}
.merchant-wechat-qr-content p{margin:0;color:#5c6372;font-size:12px;font-weight:800}
.merchant-wechat-qr-code{display:grid;place-items:center;width:216px;height:216px;padding:10px;border-radius:18px;background:#fff;box-shadow:0 10px 28px rgba(29,35,49,.08)}
.merchant-wechat-qr-code canvas,.merchant-wechat-qr-code img{display:block;width:196px;height:196px}
.merchant-wechat-qr-content strong{color:#343943;font-size:13px;font-weight:900}
.merchant-wechat-qr-content small{color:var(--m-muted);font-size:11px;line-height:1.5}
.merchant-wechat-qr-actions{display:flex;justify-content:center}
.merchant-wechat-qr-actions .merchant-plain-btn{min-width:130px;height:40px;border:0;border-radius:999px;background:#20232a;color:#fff;font-size:12px;font-weight:900}
/* Product recycle/details and stock paging controls. */
.merchant-product-page-actions{display:flex;align-items:center;gap:8px;margin-bottom:10px}
.merchant-product-page-actions .merchant-primary-btn{margin:0;flex:1}
.merchant-recycle-entry{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;padding:0 14px;border:1px solid #e8ebf1;border-radius:999px;background:#fff;color:#303642;font-size:13px;font-weight:900;cursor:pointer;box-shadow:0 8px 20px rgba(25,32,46,.05)}
.merchant-recycle-entry img{width:18px;height:18px;object-fit:contain}
.merchant-product-statuses{display:flex;align-items:center;justify-content:flex-end;gap:6px;flex:0 0 auto}
.merchant-product-statuses .merchant-badge{margin:0}
.merchant-product-detail-sheet-card,.merchant-recycle-sheet-card{max-height:88dvh}
.merchant-product-detail{display:grid;gap:14px}
.merchant-detail-product-head{display:grid;grid-template-columns:74px minmax(0,1fr);align-items:center;gap:12px}
.merchant-detail-product-head h3{margin:0;font-size:18px;line-height:1.35;font-weight:900;color:#222832;word-break:break-word}
.merchant-detail-product-head p{margin:5px 0 0;color:#8a91a0;font-size:12px;line-height:1.5}
.merchant-product-detail-cover{width:74px;height:74px;padding:0;overflow:hidden;border:0;border-radius:16px;background:#f2f4f8;cursor:pointer}
.merchant-product-detail-cover img{display:block;width:100%;height:100%;object-fit:cover}
.merchant-product-detail-cover span{font-size:28px;font-weight:900;color:#8790a0}
.merchant-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.merchant-detail-grid>div{display:grid;gap:4px;padding:10px 11px;border:1px solid #edf0f4;border-radius:13px;background:#fafbfc;min-width:0}
.merchant-detail-grid span,.merchant-detail-tags>span,.merchant-purchase-link-block>span{color:#8a91a0;font-size:11px;font-weight:700}
.merchant-detail-grid strong{min-width:0;color:#242a34;font-size:13px;font-weight:900;overflow-wrap:anywhere}
.merchant-detail-grid .merchant-badge{width:max-content}
.merchant-detail-tags{display:grid;gap:8px}
.merchant-detail-tags>div{display:flex;flex-wrap:wrap;gap:6px}
.merchant-detail-tags em{padding:5px 9px;border-radius:999px;background:#f1f3f7;color:#596273;font-size:11px;font-style:normal;font-weight:800}
.merchant-purchase-link-block{display:grid;gap:8px}
.merchant-purchase-link-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:6px;align-items:center}
.merchant-purchase-link-row input{min-width:0;font-size:11px;color:#596273}
.merchant-purchase-link-row button,.merchant-purchase-link-row a{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:0 12px;border:0;border-radius:999px;background:#202329;color:#fff;font-size:11px;font-weight:900;text-decoration:none;white-space:nowrap}
.merchant-purchase-link-row a{background:#eef4ff;color:#3978d5}
.merchant-recycle-note{margin:0 0 10px}
.merchant-recycle-list{display:grid;gap:10px}
.merchant-recycle-item{display:grid;grid-template-columns:54px minmax(0,1fr);gap:10px;padding:11px;border:1px solid #edf0f4;border-radius:16px;background:#fff}
.merchant-recycle-cover{width:54px;height:54px;overflow:hidden;border-radius:13px;background:#f2f4f8;display:grid;place-items:center}
.merchant-recycle-cover img{width:100%;height:100%;object-fit:cover}
.merchant-recycle-cover span{font-size:20px;font-weight:900;color:#8790a0}
.merchant-recycle-main{min-width:0;display:grid;align-content:center;gap:3px}
.merchant-recycle-main strong{font-size:14px;color:#242a34;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.merchant-recycle-main small{font-size:11px;line-height:1.4;color:#8a91a0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.merchant-recycle-actions{grid-column:1 / -1;display:flex;justify-content:flex-end;gap:7px}
.merchant-recycle-actions button{min-height:32px;padding:0 12px;border:0;border-radius:999px;background:#eefaf4;color:#119c62;font-size:11px;font-weight:900;cursor:pointer}
.merchant-recycle-actions button.danger{background:#fff0f2;color:#ff4056}
.merchant-stock-pager{margin-top:10px}
@media (max-width:520px){
  .merchant-product-page-actions{gap:6px}
  .merchant-recycle-entry{padding:0 11px;font-size:11px}
  .merchant-detail-product-head h3{font-size:16px}
  .merchant-purchase-link-row{grid-template-columns:minmax(0,1fr) auto}
  .merchant-purchase-link-row a{grid-column:1 / -1}
}
