:root{font-family:Arial,"PingFang SC",sans-serif;color:#162840;background:#f1f4f8;font-synthesis:none}*{box-sizing:border-box}body{margin:0;padding:20px 16px}button,input{font:inherit}button,.file-button{cursor:pointer;min-height:48px;border:1px solid #9baac0;border-radius:8px;padding:12px 18px;background:white;color:#163e77;font-weight:600}button:disabled{opacity:.55;cursor:wait}button:focus-visible,input:focus-visible,.file-button:focus-within{outline:3px solid #2465b7;outline-offset:3px}.environment{margin:0 auto 12px;text-align:center;color:#526174;font-size:13px}.device{max-width:560px;margin:auto;background:#fff;border:1px solid #d2dbea;border-radius:12px;overflow:hidden}header{display:flex;align-items:center;justify-content:space-between;padding:24px;background:#173f7b;color:white}header img{width:150px}header span{font-size:13px;max-width:160px;text-align:right}#screen{padding:30px 24px 20px;text-align:center;min-height:390px}h1{font-size:30px;letter-spacing:-.02em;margin:0 0 12px;text-wrap:balance}p{line-height:1.6}.muted{color:#526174}.four{position:relative;max-width:360px;margin:24px auto}.four input{position:absolute;inset:0;width:100%;opacity:0;z-index:1}.boxes{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.boxes span{border:1px solid #8294ae;border-radius:8px;min-height:65px;font-size:32px;display:grid;place-items:center}.four:focus-within .boxes span.current{outline:3px solid #1c4d8e;outline-offset:2px}.pad{max-width:360px;margin:auto;display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.pad button{font-size:24px;min-height:58px}.pad button[data-key="清空"],.pad button[data-key="退格"]{font-size:16px}#message{min-height:26px;margin:12px auto;color:#344f73}.actions{display:grid;gap:12px;margin-top:24px}.primary{background:#173f7b;color:white;border-color:#173f7b}.slot{font-size:64px;font-weight:700;margin:22px 0 4px}.order-no{font-size:18px}#scan-tools{text-align:center;padding:0 24px 24px}#scan-tools p{font-size:14px;color:#526174}#scan-tools button,.file-button{font-size:14px;display:inline-flex;align-items:center;margin:4px;position:relative}.file-button input{position:absolute;inset:0;opacity:0;width:100%;cursor:pointer}video{width:100%;max-height:230px;background:#15263d;border-radius:8px;margin-top:16px}footer{border-top:1px solid #d2dbea;padding:16px 24px;font-size:13px;color:#526174}.sim{max-width:800px;margin:auto}.sim img{max-width:320px;width:100%}.sim .controls{display:flex;flex-wrap:wrap;gap:10px}.sim button{margin:4px}.sim a{color:#173f7b}@media(max-width:420px){body{padding:12px}header{padding:20px}header img{width:120px}#screen{padding:24px 18px 16px}h1{font-size:27px}#scan-tools{padding:0 16px 20px}}
.cup-row{border-top:1px solid #d2dbea;padding:20px 0}.cup-row h2{font-size:18px;margin:0}.cup-row .slot{font-size:48px;margin:8px 0}.cup-row button{margin:4px}.v2 #screen>button{margin:6px}
/* English pickup copy: keep long recovery actions readable on narrow screens. */
.v2 #screen p{max-width:48ch;margin-left:auto;margin-right:auto;text-wrap:pretty}
.v2 button,.v2 .file-button{max-width:100%;white-space:normal;overflow-wrap:break-word}
.v2 #screen>button,.v2 .cup-row button{line-height:1.4}
.v2 header{gap:16px}.v2 header span{overflow-wrap:break-word}

/* Simultaneous English / Chinese; keep both languages in normal document flow. */
.v2 .copy-line{display:block;overflow-wrap:anywhere;text-wrap:pretty}
.v2 .copy-line+ .copy-line{margin-top:4px}
.v2 h1 .copy-line{font-size:26px;line-height:1.3}
.v2 h1 .copy-line[lang="zh-CN"]{font-size:24px}
.v2 #screen{min-height:280px}
.v2 #screen p{font-size:16px;line-height:1.5}
.v2 #scan-tools button,.v2 .file-button{display:inline-block;vertical-align:top;font-size:16px}
.v2 #scan-tools p,.v2 footer,.v2 header span{font-size:14px}
.v2 #scan-status{white-space:pre-line}
.v2 .slot{overflow-wrap:anywhere}
.v2 header img{flex-shrink:0}
@media(max-width:420px){.v2 h1 .copy-line{font-size:24px}.v2 h1 .copy-line[lang="zh-CN"]{font-size:22px}.v2 #screen{padding-top:22px}.v2 header{padding:18px;gap:12px}}

.v2 #screen .slot{font-size:48px;line-height:1.15;margin:8px 0;font-weight:700}
.v2.session-active #scan-tools>p:first-child:not(#scan-status),.v2.session-active #camera,.v2.session-active .file-button{display:none}
.v2.session-active #scan-tools{padding-bottom:12px}
.v2.session-active #scan-status:empty{display:none}
.v2.session-active .cup-row{padding:14px 0}
.v2.session-active #screen{padding-top:22px;padding-bottom:12px}

.v2 #screen .slot.long-slot{font-size:24px;line-height:1.4;max-width:26ch;margin:12px auto}
