:root{--orange:#ff6315;--orange2:#ff941e;--peach:#fff4ed;--ink:#27282b;--muted:#797d84;--line:#ebecef;--bg:#f7f7f8;--surface:#fff;font-family:-apple-system,BlinkMacSystemFont,'PingFang SC','Microsoft YaHei',system-ui,sans-serif;color:var(--ink);background:var(--bg);font-synthesis:none}
*{box-sizing:border-box}body{margin:0;font-size:15px}button,input,textarea,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.43;cursor:default}button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #fca768;outline-offset:2px}[hidden]{display:none!important}h1,h2,h3,p{margin:0}h1{font-size:24px}h2{font-size:19px}h3{font-size:16px}.muted{color:var(--muted);font-size:13px}.app-shell{max-width:1000px;min-height:100vh;margin:auto;background:var(--bg)}.topbar{height:74px;padding:12px 24px;display:flex;align-items:center;gap:12px;background:#fff;border-bottom:1px solid var(--line)}.brand-icon{width:42px;height:42px;border-radius:13px;background:linear-gradient(135deg,var(--orange2),var(--orange));display:grid;place-items:center;color:white;font-size:24px;font-weight:800}.brand{display:flex;flex-direction:column;gap:2px}.brand strong{font-size:20px;color:var(--orange)}.brand strong span{color:var(--ink)}.brand small{font-size:11px;color:var(--muted)}.app-mark{margin-left:auto;border:1px solid #ffd5bd;color:#e87030;background:#fff8f3;border-radius:99px;padding:5px 11px;font-size:12px}main{padding:20px 22px 32px}footer{text-align:center;font-size:12px;color:#aaa;padding:22px}.hero{border-radius:18px;background:linear-gradient(115deg,#e34413,#ffb044);color:#fff;padding:30px 28px;display:flex;align-items:center;min-height:210px;overflow:hidden}.hero h1{font-size:30px;line-height:1.35;margin:10px 0}.hero p{opacity:.9}.eyebrow{letter-spacing:1.2px;font-size:12px;font-weight:650}.hero-art{margin:auto;font-size:72px;opacity:.95;position:relative}.hero-art span{position:absolute;top:36px;left:45px;font-size:72px}.surface{background:#fff;border:1px solid var(--line);border-radius:18px}.login-card{max-width:510px;margin:-20px auto 18px;padding:26px;position:relative;box-shadow:0 8px 26px #be7d3a0a}.login-card h2{margin-bottom:7px}.login-card .muted{margin-bottom:20px}.login-card label,.coupon-form label{display:flex;flex-direction:column;gap:9px;font-weight:620;font-size:14px;margin-bottom:16px}.login-card input,.coupon-form input:not([type=checkbox]):not([type=file]),.coupon-form select,.coupon-form textarea{width:100%;border:1px solid #e1e2e7;background:#fafafa;border-radius:11px;padding:13px;color:var(--ink);min-height:44px}.footnote{color:var(--muted);font-size:12px;line-height:1.8;margin-top:12px}.button{border-radius:99px;min-height:40px;padding:8px 17px;display:inline-flex;align-items:center;justify-content:center;gap:7px;border:1px solid transparent;font-weight:700}.button.primary{background:linear-gradient(90deg,#ffad21,var(--orange));color:white}.button.primary:hover{filter:brightness(.97)}.button.full{width:100%;min-height:49px}.button.light{background:#fff;border-color:#e7e7e7;color:#64656b}.button.small{font-size:13px;min-height:36px}.button.white{background:#fff;color:#e55617}.button.ghost-white{background:transparent;border-color:#fff9;color:#fff}.feature-row{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}.feature-row span{background:#fff;border-radius:14px;padding:20px 8px;text-align:center;color:#664a36;font-size:13px}.shop-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:18px}.shop-heading h1{margin:4px 0 6px}.warm{color:var(--orange)}.metrics{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:18px}.metric{background:#fff;border:1px solid #f1f1f1;border-radius:16px;padding:16px}.metric span{display:block;color:var(--muted);font-size:12px}.metric strong{display:block;color:var(--orange);font-weight:800;font-size:24px;overflow-wrap:anywhere;margin-top:9px}.alert-block{background:linear-gradient(105deg,#f85213,#ff901e);padding:17px;border-radius:18px;color:#fff;margin-bottom:22px}.alert-top{display:flex;justify-content:space-between;align-items:center;gap:10px}.alert-top strong{font-size:20px}.alert-top small{display:block;margin:7px 0 0 40px;opacity:.95}.bell{font-size:26px;vertical-align:middle;margin-right:9px}.alert-refresh{background:#ffffff24;border:1px solid #ffffff88;color:#fff;flex-shrink:0;font-size:12px}.urgent-order{margin-top:13px}.urgent-order:empty{display:none}.urgent-card{background:#fff;color:var(--ink);padding:14px;border-radius:13px;display:flex;gap:12px;align-items:center}.urgent-card .urgent-main{flex:1;min-width:0}.urgent-card strong{display:block;font-size:22px}.urgent-card p{font-size:13px;color:var(--muted);margin:4px 0;overflow-wrap:anywhere}.urgent-card .button{background:var(--orange);color:white;font-size:13px;flex-shrink:0}.alert-hint{font-size:12px;margin:12px 1px 8px;line-height:1.55;color:#fff}.alarm-controls{display:flex;align-items:center;flex-wrap:wrap;gap:8px}.alarm-controls .button{min-height:35px;font-size:12px}.alarm-controls span{font-size:12px;color:#fff}.alert-block.unreachable{background:linear-gradient(105deg,#9e2630,#d44e30)}.alert-block.attention .bell{animation:wiggle 1.1s 3}@keyframes wiggle{0%,100%{transform:rotate(0)}25%{transform:rotate(14deg)}75%{transform:rotate(-14deg)}}.tabs{display:flex;gap:6px;overflow-x:auto;scrollbar-width:none;border-bottom:1px solid var(--line);padding:0 2px;position:sticky;top:0;background:var(--bg);z-index:3}.tabs::-webkit-scrollbar{display:none}.tabs button{background:none;border:0;border-bottom:3px solid transparent;white-space:nowrap;padding:14px 17px 12px;color:#5f636a;font-weight:700}.tabs button.active{color:var(--orange);border-color:var(--orange)}.section-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:20px 0 13px}.section-head h2{margin-bottom:5px}.content-stack{display:grid;grid-template-columns:1fr;gap:12px}.ticket-card,.order-card,.empty-card,.setting-card{background:white;border-radius:16px;padding:15px;border:1px solid #ededed}.ticket-card{display:grid;grid-template-columns:112px minmax(0,1fr) auto;gap:14px;align-items:center}.ticket-photo{width:112px;height:100px;border-radius:12px;object-fit:cover;background:#fff2e6}.ticket-photo-fallback{width:112px;height:100px;border-radius:12px;background:linear-gradient(145deg,#ffeddd,#ffc48b);color:#db6224;display:grid;place-items:center;font-size:34px}.ticket-name{font-weight:750;font-size:16px;line-height:1.55;overflow-wrap:anywhere}.ticket-line{margin-top:6px;display:flex;flex-wrap:wrap;align-items:baseline;gap:8px;font-size:13px}.ticket-line del{color:#9b9b9b}.ticket-price{color:var(--orange);font-size:23px;font-weight:780}.ticket-note{font-size:12px;color:var(--muted);margin-top:7px;overflow-wrap:anywhere}.tag{display:inline-flex;background:#f3f4f6;border-radius:5px;color:#69717b;padding:3px 6px;font-size:11px;font-weight:700;vertical-align:middle;margin-left:5px}.tag.live{background:#e5f7ec;color:#14834b}.tag.off{background:#f1f1f1;color:#777}.tag.single{background:#fff0e5;color:#f06821}.tag.package{background:#f4eaff;color:#7544b8}.ticket-actions{display:flex;flex-direction:column;gap:7px;align-items:stretch}.ticket-actions .button{font-size:13px;min-width:71px;min-height:34px}.button.outline-orange{background:#fff;color:var(--orange);border-color:var(--orange)}.button.solid-orange{background:var(--orange);color:white}.order-card.pending{border-color:#ffb48b;background:#fffaf7}.order-head{display:flex;justify-content:space-between;gap:10px;align-items:center}.table-number{font-size:21px;font-weight:800}.order-number{font-size:12px;color:var(--muted)}.order-items{margin:12px 0 8px;padding-left:20px}.order-items li{margin:8px 0;font-size:15px;font-weight:650}.order-items .contents{font-size:12px;color:#6a6a6a;font-weight:400;margin-top:4px}.order-foot{display:flex;justify-content:space-between;gap:8px;align-items:center;flex-wrap:wrap}.order-overdue{color:#cd3625;font-weight:700;font-size:13px;margin-top:7px}.status-pill{border-radius:99px;padding:5px 10px;font-size:12px;font-weight:750;background:#f5f5f5;color:#666}.status-pill.pending_service{background:#fff0e6;color:#de550d}.status-pill.preparing{background:#fff6d7;color:#996d00}.status-pill.ready{background:#e4f3ff;color:#2570a6}.status-pill.served{background:#e3f6ed;color:#16875c}.empty-card{text-align:center;padding:38px 18px;color:#8a8a8a}.empty-card strong{display:block;font-size:18px;color:#444;margin-bottom:7px}.pagination{display:flex;align-items:center;justify-content:center;gap:15px;margin-top:20px}.policy-note{padding:14px;color:#8a8c91;text-align:center;font-size:12px;line-height:1.6}.setting-card label{display:flex;flex-direction:column;gap:8px;margin:14px 0}.setting-card input,.setting-card select{border:1px solid #ddd;border-radius:9px;padding:10px}.setting-card p{color:var(--muted);line-height:1.6;font-size:13px}.setting-card .button{margin-top:14px}.setting-card .file-label{background:#fff3e8;padding:12px;border-radius:9px}.coupon-dialog{border:none;border-radius:20px;max-width:560px;width:calc(100% - 24px);max-height:calc(100dvh - 20px);padding:0;background:#fff;box-shadow:0 15px 60px #0003}.coupon-dialog::backdrop{background:#0007}.coupon-form{padding:22px}.dialog-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:2px 16px}.form-grid .wide{grid-column:1/-1}.coupon-form label small{color:var(--muted);font-size:11px;font-weight:400;line-height:1.55}.coupon-form .checkbox-line{flex-direction:row;align-items:center}.coupon-form .checkbox-line input{accent-color:var(--orange);width:18px;height:18px}.file-label{background:#fff4e9;color:#d35c1e;border:1px dashed #ffad73;border-radius:11px;padding:14px;cursor:pointer}.file-label input{max-width:100%;font-size:12px}.coupon-preview{grid-column:1/-1;width:150px;height:130px;object-fit:cover;border-radius:12px}#message{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);z-index:9;max-width:calc(100% - 30px);background:#333;color:white;border-radius:12px;padding:12px 17px;font-size:13px;box-shadow:0 8px 24px #0003;min-width:150px;text-align:center}#message:empty{display:none}
@media(max-width:680px){main{padding:14px 12px 24px}.topbar{padding:10px 14px;height:68px}.brand strong{font-size:18px}.app-mark{display:none}.hero{padding:22px 17px;min-height:180px}.hero h1{font-size:25px}.hero-art{font-size:48px;margin-right:25px}.hero-art span{font-size:44px;top:32px;left:20px}.feature-row{grid-template-columns:repeat(2,1fr);gap:7px}.feature-row span{padding:14px 7px}.login-card{margin-top:-15px;padding:22px}.shop-heading h1{font-size:18px}.metrics{grid-template-columns:repeat(2,1fr);gap:8px}.metric{padding:12px}.metric strong{font-size:23px}.alert-top strong{font-size:16px}.alert-refresh{font-size:11px;padding:7px}.urgent-card{align-items:flex-start}.urgent-card strong{font-size:19px}.urgent-card .button{padding:8px 12px}.tabs button{padding:13px 10px;font-size:14px}.ticket-card{grid-template-columns:82px 1fr;gap:10px;position:relative}.ticket-photo,.ticket-photo-fallback{width:82px;height:88px}.ticket-price{font-size:20px}.ticket-name{font-size:14px}.ticket-actions{grid-column:1/-1;flex-direction:row;justify-content:flex-end}.form-grid{grid-template-columns:1fr}.form-grid .wide{grid-column:auto}.coupon-form{padding:18px}.section-head h2{font-size:18px}.order-foot .button{flex:1}}
@media(prefers-reduced-motion:reduce){.alert-block.attention .bell{animation:none}}

.urgent-card .ticket-photo,.urgent-card .ticket-photo-fallback{width:72px;height:74px;flex-shrink:0;font-size:28px}
/* V3 additions: merchant-first coupon management, no receipt printer. */
.queue-filters{display:flex;gap:9px;align-items:center;flex-wrap:wrap;margin:16px 0 2px}
.queue-filter{padding:9px 13px;background:#fff;border:1px solid #e7e7ea;color:#5c626a;border-radius:9px;font-size:13px;font-weight:750}
.queue-filter.active{border-color:#ff702c;background:#fff2e9;color:#f26218}
.queue-filter span{display:inline-block;padding:1px 5px;border-radius:99px;background:#f0f0f0;font-size:11px;margin-left:4px;min-width:20px}
.queue-filter.active span{background:#ffd7c1;color:#d24c12}
.discount-tag{border:1px solid #ff9b69;color:#f06422;border-radius:5px;padding:2px 5px;font-size:12px;font-weight:650}
.cost-preview{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;padding:14px;border-radius:13px;background:#fff6ef;border:1px solid #ffe0cd;margin:4px 0 15px}
.cost-preview div{min-width:0}.cost-preview span{font-weight:500;color:#8b7469;font-size:12px;display:block;margin-bottom:8px}.cost-preview strong{font-size:19px;color:#f06020}
.cost-preview small{grid-column:1/-1;line-height:1.6;color:#8d817a!important}
.ticket-card{box-shadow:0 3px 14px rgba(20,15,10,.025)}.ticket-photo{background-color:#fff2e5}.ticket-actions .button{border-radius:99px}
.order-card{box-shadow:0 3px 14px rgba(20,15,10,.028)}.order-card.pending{border-color:#ffb98b}
.order-card .order-items{border-top:1px dashed #f2f2f2;border-bottom:1px dashed #f2f2f2;padding-top:9px;padding-bottom:9px}
.login-card{box-shadow:0 14px 40px rgba(90,50,30,.08)}.topbar{position:relative;z-index:4}
.hero{background-image:linear-gradient(110deg,rgba(108,29,9,.92),rgba(249,89,19,.78)),url('/merchant/hotpot-login.jpg');background-size:cover;background-position:center}
@media (max-width:680px){.queue-filters{gap:6px}.queue-filter{flex:1 1 calc(50% - 8px);white-space:nowrap;padding:9px 7px}.ticket-card{grid-template-columns:94px minmax(0,1fr) auto;gap:10px;align-items:start}.ticket-photo,.ticket-photo-fallback{width:94px;height:96px}.ticket-actions{grid-column:3;flex-direction:column;margin-top:2px}.ticket-actions .button{min-width:55px;padding:5px 9px;font-size:12px;min-height:30px}.ticket-price{font-size:18px}.ticket-line{gap:4px}.ticket-name{font-size:14px}.ticket-note{font-size:11px}.cost-preview strong{font-size:16px}}
@media (max-width:370px){.ticket-card{grid-template-columns:82px 1fr}.ticket-actions{grid-column:1/-1;flex-direction:row;justify-content:flex-end}.ticket-photo,.ticket-photo-fallback{width:82px;height:86px}.cost-preview{padding:9px;gap:6px}}

/* v020: merchant manually enters restaurant POS order and verifies customer code */
.redeem-form{margin:12px 0 4px;padding:12px;border-radius:12px;border:1px solid #ffca9a;background:#fff8ef;display:flex;flex-direction:column;gap:10px}
.redeem-instruction{font-size:12px;color:#935d37;line-height:1.7}.redeem-label{font-size:12px;font-weight:700;display:flex;flex-direction:column;gap:6px}
.redeem-input{border:1px solid #e5b08c;border-radius:8px;padding:12px;font-size:16px;font-family:ui-monospace,monospace;letter-spacing:1px;max-width:100%;background:white}
.redeem-confirm{display:flex;align-items:center;gap:9px;font-size:12px;line-height:1.5}.redeem-confirm input{width:18px;height:18px;flex-shrink:0;accent-color:#ed6427}
.redeem-form .button{width:100%;min-height:42px}

/* v021 scan dialog; staff may operate entirely from a phone in WeChat. */
.scan-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:18px 0 0;padding:12px;background:#fff4e9;border:1px solid #f3d9c3;border-radius:13px}
.scan-toolbar span{font-size:12px;color:#8c6043;line-height:1.5}.scan-toolbar .button{min-height:46px}
.scan-dialog{border:0;border-radius:18px;padding:0;width:min(540px,calc(100% - 18px));max-height:calc(100dvh - 16px);background:white;box-shadow:0 16px 70px #0005}
.scan-dialog::backdrop{background:#000a}.scan-inner{padding:18px;overflow:auto;max-height:calc(100dvh - 16px)}
.scan-inner h2{margin:0;color:#272727;font-size:21px}.scan-inner #scan-message{font-size:13px;line-height:1.5;color:#b14d20;background:#fff5e9;padding:10px;border-radius:9px}
#scan-video{width:100%;max-height:340px;background:#111;object-fit:cover;border-radius:12px;margin:8px 0}
#scan-result{margin:15px 0;padding:13px;border-radius:11px;background:#f9fafb;border:1px solid #ebebeb}
#scan-result:empty{display:none}#scan-result h3{font-size:25px;margin:0 0 10px;color:#d4531c}
.scan-items{padding-left:22px}.scan-items li{margin:9px 0;font-weight:700}.scan-items small{display:block;font-weight:400}
.scan-meta{font-size:13px;color:#666;overflow-wrap:anywhere}.scan-warning{color:#b33b22;font-weight:750}.scan-success{color:#18814f;font-weight:750}
.scan-confirm{display:flex;gap:8px;align-items:flex-start;margin:14px 0;line-height:1.6;font-size:14px}
.scan-confirm input{accent-color:#ec621f;margin-top:4px;width:18px;height:18px;flex-shrink:0}
.scan-submit{width:100%;min-height:47px}.scan-manual{display:flex;flex-wrap:wrap;gap:9px;margin-top:13px;padding-top:12px;border-top:1px solid #e8e8e8;align-items:flex-end}
.scan-manual label{display:flex;flex:1;flex-direction:column;gap:6px;font-size:12px;font-weight:700;min-width:160px}
.scan-manual input{padding:11px;border:1px solid #d6d6d6;border-radius:7px;width:100%;font-size:16px}
.scan-manual button{min-height:43px}

/* v022: table number is mandatory on the staff camera flow. */
.scan-table-label{display:flex;flex-direction:column;gap:8px;margin:15px 0 4px;font-weight:750;color:#26312d}
.scan-table-input{border:2px solid #ea7334;border-radius:10px;padding:14px 12px;font-size:20px;min-height:50px;width:100%;background:white;color:#202020}
.scan-table-input:focus{outline:3px solid #ffd8bb;outline-offset:1px}
.scan-table-input:disabled{background:#f3f3f3}

/* v023 商家前台自动订单同步与新订单醒目提示 */
#sync-state{display:block;margin-top:4px;font-size:12px;opacity:.95;font-weight:650}
#sync-state.sync-offline{color:#fff1ad;font-weight:800}
.new-order-toast{position:fixed;top:82px;right:max(12px,calc((100vw - 1000px)/2 + 18px));z-index:1100;
  width:min(390px,calc(100vw - 24px));background:#fffaf6;border:2px solid #fd792f;color:#9c3d13;
  box-shadow:0 15px 45px #70320d40;border-radius:17px;padding:15px;display:grid;gap:10px;
  animation:xxd-toast-in .35s ease-out}
.new-order-toast strong{font-size:17px;line-height:1.5}
.new-order-toast>div{display:flex;gap:9px;justify-content:flex-end}
.order-card.just-arrived{animation:xxd-new-order-glow 3s ease-out;outline:2px solid #f68b38;outline-offset:1px}
@keyframes xxd-toast-in{from{opacity:0;transform:translateY(-13px)}to{opacity:1;transform:translateY(0)}}
@keyframes xxd-new-order-glow{0%,40%{background:#fff1d7}100%{background:#fffaf7}}
@media(max-width:680px){.new-order-toast{top:72px;right:12px}}
@media(prefers-reduced-motion:reduce){.new-order-toast,.order-card.just-arrived{animation:none}}
/* v088 · merchant-owned cabinet management */
.merchant-cabinet-box-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin:12px 0}.merchant-cabinet-box{display:flex;flex-direction:column;gap:7px;padding:12px;border:1px solid #f1d9c5;border-radius:12px;background:#fffaf5}.merchant-cabinet-box>strong{font-size:15px;color:#8b421c}.merchant-cabinet-box>span{font-size:13px;font-weight:750;color:#55463a}.merchant-cabinet-box small{font-size:11px;color:#87776b}.merchant-cabinet-box-actions{display:flex;gap:7px;flex-wrap:wrap}.merchant-cabinet-box-actions button{margin:0;min-height:34px}.merchant-cabinet-box-grid+.muted{line-height:1.7}@media(max-width:480px){.merchant-cabinet-box-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.merchant-cabinet-box{padding:9px}.merchant-cabinet-box-actions{flex-direction:column}.merchant-cabinet-box-actions button{width:100%;font-size:11px;padding:7px 5px}}
.merchant-cabinet-history{margin-top:8px;padding:9px 12px;border:1px solid #f0dfd0;border-radius:10px;background:#fffaf5}.merchant-cabinet-history p{font-size:11px;line-height:1.6;margin:5px 0;overflow-wrap:anywhere}
