:root{font-family:'DM Sans','Kantumruy Pro',system-ui,sans-serif;color:#20242c;background:#f7f8fa;font-synthesis:none;text-rendering:optimizeLegibility;--orange:#f97316;--orange-dark:#ea580c;--orange-soft:#fff2e8;--ink:#20242c;--muted:#858b98;--line:#eceef1;--surface:#fff;--green:#16845d;--shadow:0 8px 30px rgba(28,32,39,.045)}*{box-sizing:border-box}body{margin:0;min-height:100dvh;background:#f7f8fa;-webkit-tap-highlight-color:transparent;overscroll-behavior-y:none}button,input,textarea{font:inherit}button{cursor:pointer}button:focus-visible,input:focus-visible,textarea:focus-visible{outline:3px solid #fdba74;outline-offset:2px}.app-shell{min-height:100dvh}.topbar{height:74px;background:white;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 30px;gap:24px;position:sticky;top:0;z-index:20}.brand-lockup{display:flex;align-items:center;gap:11px;min-width:225px}.brand-mark{width:39px;height:39px;background:linear-gradient(145deg,#fb923c,#f97316);border-radius:12px;display:grid;place-items:center;box-shadow:0 5px 14px #f9731638}.brand-mark svg{width:23px;height:23px;fill:none;stroke:white;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}.brand-name{font-weight:800;font-size:17px;letter-spacing:-.55px;line-height:1.1}.brand-caption{font-size:9px;letter-spacing:1.2px;color:#9ba0aa;font-weight:700;margin-top:4px}.header-context{font-size:12px;color:#717782;display:flex;align-items:center;gap:8px;border-left:1px solid var(--line);padding-left:20px;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.context-dot,.foot-indicator{width:7px;height:7px;border-radius:50%;background:#31b584;box-shadow:0 0 0 3px #dff6ed;flex:none}.top-actions{margin-left:auto;display:flex;gap:9px;align-items:center}.btn{height:39px;padding:0 14px;border-radius:9px;border:1px solid transparent;font-size:12px;font-weight:700;display:inline-flex;align-items:center;justify-content:center;gap:8px;transition:transform .14s,background .14s,border-color .14s;white-space:nowrap}.btn:active{transform:scale(.97)}.btn-primary{background:var(--orange);color:white;box-shadow:0 3px 8px #f973162a}.btn-primary:hover{background:var(--orange-dark)}.btn-quiet{background:white;color:#555c68;border-color:#e8e9ec}.btn-quiet:hover,.btn-outline:hover{background:#fff8f2;border-color:#fed7aa}.btn-outline{background:white;color:#555c68;border-color:#e7e9ed}.icon{font-size:16px;font-weight:500}.sync-pill{display:inline-flex;align-items:center;gap:7px;font-size:10px;font-weight:600;color:#858b98;padding:7px 10px;border-radius:20px;background:#f7f8fa}.sync-pill i{width:7px;height:7px;border-radius:50%;background:#f59e0b}.sync-pill.online i{background:#20a273}.sync-pill.offline i{background:#e8a127}.workspace{display:grid;grid-template-columns:286px minmax(0,1fr);min-height:calc(100dvh - 74px)}.sidebar{background:white;border-right:1px solid var(--line);display:flex;flex-direction:column;min-height:calc(100dvh - 74px);height:calc(100dvh - 74px);position:sticky;top:74px}.sidebar-head{padding:25px 21px 17px;display:flex;justify-content:space-between;align-items:center}.eyebrow,.section-kicker{font-size:9px;font-weight:800;letter-spacing:1.25px;color:#a0a5af;margin:0 0 7px}.sidebar-head h1,.dashboard-head h2{font-size:20px;letter-spacing:-.7px;margin:0;font-weight:800}.search-wrap{height:40px;display:flex;align-items:center;gap:8px;background:#f7f8fa;border:1px solid #eff0f2;border-radius:9px;margin:0 16px 15px;padding:0 11px}.search-icon{font-size:21px;color:#9da2ab;line-height:1}.search-wrap input{border:0;background:transparent;outline:none;width:100%;font-size:11px;color:var(--ink)}.search-wrap input::placeholder{color:#a7abb3}.filter-row{display:flex;gap:5px;padding:0 15px 12px;border-bottom:1px solid #f0f0f1}.filter{border:0;border-radius:7px;background:transparent;color:#838994;padding:7px 9px;font-size:10px;font-weight:700;white-space:nowrap}.filter span{margin-left:3px;color:#a2a7af}.filter.active{background:var(--orange-soft);color:var(--orange-dark)}.filter.active span{color:#ed7b32}.list-summary{display:flex;justify-content:space-between;align-items:center;padding:14px 19px 7px;color:#a0a4ac;font-size:10px;font-weight:600}.text-btn{border:0;background:none;color:var(--orange-dark);font-size:10px;font-weight:700;padding:5px}.text-btn:hover{text-decoration:underline}.product-list{overflow:auto;flex:1;padding:0 9px 10px}.empty-list{padding:48px 18px 25px;display:flex;align-items:center;flex-direction:column;text-align:center;gap:8px;color:#969ba5;font-size:11px}.empty-list strong{font-size:12px;color:#575e69;margin-top:5px}.empty-icon{width:48px;height:48px;border-radius:15px;background:#fff3e9;color:var(--orange);display:grid;place-items:center;font-size:25px}.empty-list .btn{margin-top:8px}.product-row{width:100%;border:1px solid transparent;background:white;border-radius:10px;text-align:left;display:grid;grid-template-columns:34px 1fr auto;align-items:center;gap:10px;padding:11px 9px;margin:2px 0;transition:background .15s,border-color .15s}.product-row:hover{background:#fafafa}.product-row.selected{background:#fff7f1;border-color:#ffe2ca}.row-avatar{width:33px;height:33px;border-radius:9px;background:#f5f6f8;color:#888e99;display:grid;place-items:center;font-size:16px}.product-row.selected .row-avatar{background:#ffe8d6;color:var(--orange-dark)}.row-name{font-weight:700;color:#373c45;font-size:11px;line-height:1.35;display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.row-code{display:block;font-size:9px;color:#9ba0a9;font-family:ui-monospace,SFMono-Regular,monospace;margin-top:4px}.row-right{text-align:right}.row-count{font-size:11px;font-weight:800;color:#444b55;display:block}.row-diff{font-size:9px;color:#a1a6ae;margin-top:4px;display:block}.row-status{height:6px;width:6px;border-radius:50%;display:inline-block;background:#d5d8de;margin-left:4px}.row-status.counted{background:#2caa7c}.row-status.draft{background:#f2a442}.sidebar-foot{border-top:1px solid #f0f0f1;padding:15px 20px;display:flex;align-items:center;gap:9px;font-size:10px;color:#969ba5}.sidebar-foot .foot-indicator{width:6px;height:6px}.main-panel{padding:28px 30px 25px;min-width:0;max-width:1500px;width:100%;margin:0 auto}.dashboard-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:21px}.dashboard-head h2{font-size:24px}.subhead{margin:5px 0 0;color:#8b909a;font-size:11px}.dashboard-head .eyebrow{margin-bottom:6px}.metrics-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:18px}.metric-card{background:white;border:1px solid #eff0f2;border-radius:12px;padding:15px 16px 12px;box-shadow:0 3px 10px #1e293b04}.metric-label{font-size:8px;letter-spacing:.85px;font-weight:800;color:#a0a4ad}.metric-card>div{display:flex;align-items:center;justify-content:space-between;margin:8px 0 6px}.metric-card>div>strong{font-size:24px;letter-spacing:-1px;line-height:1}.metric-symbol{height:28px;width:28px;border-radius:9px;display:grid;place-items:center;font-size:14px;font-weight:700}.metric-symbol.orange{background:#fff0e4;color:#f07828}.metric-symbol.green{background:#eaf8f2;color:#24966c}.metric-symbol.amber{background:#fff6df;color:#d89b21}.metric-symbol.purple{background:#f2efff;color:#8266d8}.metric-foot{font-size:9px;color:#9ca1ab}.metric-foot span{font-weight:700;color:#5c626d}.content-grid{display:grid;grid-template-columns:minmax(340px,1.06fr) minmax(315px,.94fr);gap:14px;align-items:stretch}.count-card,.scanner-card{background:white;border:1px solid #eceef1;border-radius:14px;box-shadow:var(--shadow);min-width:0}.count-card{padding:18px 19px 16px}.card-topline{display:flex;justify-content:space-between;align-items:center}.card-topline>div{display:flex;align-items:center;gap:9px}.card-topline .section-kicker{margin:0}.status-badge{padding:5px 8px;font-size:8px;font-weight:800;letter-spacing:.35px;border-radius:20px}.status-badge.pending{background:#fff6e7;color:#bd8114}.status-badge.draft{background:#eff4ff;color:#5276c9}.status-badge.confirmed{background:#e8f8f1;color:#218359}.active-product{display:flex;align-items:center;gap:12px;padding:18px 0 14px}.product-avatar{width:52px;height:52px;border:1px solid #f0f1f2;border-radius:12px;background:linear-gradient(145deg,#fafafa,#f3f4f5);display:grid;place-items:center;color:#9da1a8;font-size:24px;flex:none}.active-product-copy{min-width:0}.active-name{font-size:15px;line-height:1.3;font-weight:800;letter-spacing:-.3px;color:#282d35;overflow-wrap:anywhere}.active-code{display:flex;align-items:center;gap:8px;margin-top:6px;font-size:10px;color:#989da7;font-family:ui-monospace,SFMono-Regular,monospace;min-height:13px}.active-code span:first-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.active-code span:last-child{font-family:inherit;border-left:1px solid #e4e5e8;padding-left:8px}.product-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));background:#f8f9fa;border:1px solid #f0f1f2;border-radius:10px;padding:11px 9px}.product-facts>div{display:flex;flex-direction:column;gap:5px;padding:0 9px;border-right:1px solid #e9eaec;min-width:0}.product-facts>div:last-child{border:0}.product-facts span{font-size:9px;color:#9a9faa;white-space:nowrap}.product-facts strong{font-size:12px;color:#4c535e;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.count-divider{height:1px;background:#f0f1f2;margin:17px 0 14px}.count-label-row{display:flex;align-items:center;justify-content:space-between}.count-label-row .section-kicker{margin:0 0 4px}.count-hint{font-size:9px;color:#a2a6ae;display:block}.variance-chip{font-size:9px;background:#f7f8f9;color:#9297a1;padding:6px 8px;border-radius:7px;white-space:nowrap}.variance-chip b{color:#454b54;margin-left:3px;font-family:ui-monospace,monospace}.variance-chip.positive{background:#fff0e8;color:#d65f25}.variance-chip.negative{background:#fff0f0;color:#d34d4d}.variance-chip.zero{background:#eaf8f2;color:#25835d}.quantity-control{height:78px;display:flex;align-items:center;justify-content:center;gap:22px}.step-btn{border:1px solid #f2e5da;background:white;width:40px;height:40px;border-radius:12px;color:var(--orange-dark);font-size:24px;line-height:1;display:grid;place-items:center;transition:.12s}.step-btn:active{background:var(--orange);color:white;transform:scale(.93)}.step-btn.plus{background:var(--orange);color:white;border-color:var(--orange);box-shadow:0 4px 9px #f9731630}.quantity-input-wrap{display:flex;align-items:baseline;gap:7px}.quantity-input-wrap input{border:0;outline:0;width:120px;text-align:center;font-size:34px;letter-spacing:-1.7px;font-weight:800;color:#252a32;background:transparent;font-variant-numeric:tabular-nums}.quantity-input-wrap input::-webkit-inner-spin-button,.quantity-input-wrap input::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.quantity-input-wrap input{appearance:textfield}.quantity-input-wrap span{font-size:10px;color:#a2a6ae}.quick-steps{display:flex;align-items:center;justify-content:center;gap:7px;margin-bottom:17px}.quick-steps>span{font-size:8px;letter-spacing:.8px;font-weight:800;color:#a4a8b0;margin-right:3px}.quick-steps button{padding:6px 9px;border-radius:7px;background:#fff7f0;border:1px solid #ffeadb;color:#d66822;font-weight:700;font-size:9px}.quick-steps button:last-child{background:white;color:#858b95;border-color:#e9eaec}.remarks-label{display:flex;justify-content:space-between;color:#959aa4;font-size:8px;font-weight:800;letter-spacing:.75px;margin-bottom:6px}.remarks-label span{font-weight:500;letter-spacing:0;color:#b0b4bb}.remarks-input{height:36px;width:100%;border:1px solid #eceef1;border-radius:8px;padding:0 10px;font-size:10px;color:#434954;outline:none}.remarks-input:focus,.manual-input-row:focus-within{border-color:#fdba74;box-shadow:0 0 0 3px #fff1e6}.remarks-input::placeholder{color:#b0b4bb}.card-actions{display:flex;gap:8px;margin-top:13px}.card-actions .btn{height:40px;flex:1;font-size:11px}.confirm-btn span{font-size:17px;margin-left:4px}.scanner-card{padding:18px 17px 13px;display:flex;flex-direction:column}.scanner-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:12px}.scanner-heading .section-kicker{margin-bottom:5px}.scanner-heading h3{font-size:15px;letter-spacing:-.35px;margin:0;font-weight:800}.format-pill{font-size:8px;letter-spacing:.4px;font-weight:800;color:#b35c18;background:#fff2e8;border:1px solid #ffe1cb;border-radius:6px;padding:6px 7px;white-space:nowrap}.format-pill span{display:inline-block;height:6px;width:6px;border-radius:50%;background:#f48033;margin-right:4px;vertical-align:1px}.camera-stage{position:relative;min-height:235px;flex:1;border-radius:11px;background:#202329;overflow:hidden;display:grid;place-items:center;color:white}.camera-stage video{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:none}.camera-stage.is-live video{display:block}.camera-stage.is-live{background:#17191d}.camera-idle{position:relative;z-index:1;display:flex;flex-direction:column;align-items:center;text-align:center;padding:18px}.camera-icon{width:44px;height:44px;border-radius:13px;background:#ffffff14;border:1px solid #ffffff1c;display:grid;place-items:center;color:#ffb17d;font-size:22px;margin-bottom:9px}.camera-idle strong{font-size:12px;font-weight:700}.camera-idle>span{font-size:9px;color:#c2c4ca;line-height:1.6;margin:5px 0 12px}.camera-idle .btn{height:34px;font-size:10px}.camera-stage.is-live .camera-idle{display:none}.scan-frame{position:absolute;inset:50% auto auto 50%;transform:translate(-50%,-50%);height:92px;width:min(78%,300px);z-index:2;pointer-events:none;opacity:0;transition:opacity .2s}.camera-stage.is-live .scan-frame{opacity:1}.scan-frame i{position:absolute;width:17px;height:17px;border-color:#fff;border-style:solid}.scan-frame i:nth-child(1){top:0;left:0;border-width:3px 0 0 3px;border-radius:5px 0 0}.scan-frame i:nth-child(2){top:0;right:0;border-width:3px 3px 0 0;border-radius:0 5px 0 0}.scan-frame i:nth-child(3){bottom:0;left:0;border-width:0 0 3px 3px;border-radius:0 0 0 5px}.scan-frame i:nth-child(4){bottom:0;right:0;border-width:0 3px 3px 0;border-radius:0 0 5px 0}.scan-frame span{position:absolute;left:5px;right:5px;height:2px;background:#fb754d;box-shadow:0 0 12px #ff433a;animation:laser 1.8s ease-in-out infinite alternate}@keyframes laser{from{top:12px;opacity:.55}to{top:calc(100% - 12px);opacity:1}}.camera-live-label{display:none;position:absolute;top:10px;left:11px;z-index:3;font-size:8px;font-weight:800;letter-spacing:.7px;color:white;background:#121418aa;padding:6px 8px;border-radius:20px}.camera-live-label span{width:6px;height:6px;display:inline-block;border-radius:50%;background:#44db99;margin-right:4px;animation:pulse 1.2s infinite}@keyframes pulse{50%{opacity:.3}}.camera-stage.is-live .camera-live-label{display:block}.scan-feedback{display:flex;align-items:flex-start;gap:8px;font-size:9px;color:#8f949e;line-height:1.45;padding:11px 1px 9px;min-height:39px}.feedback-dot{width:6px;height:6px;border-radius:50%;background:#37a97b;flex:none;margin-top:3px}.scan-feedback.error{color:#c75042}.scan-feedback.error .feedback-dot{background:#d85446}.scan-feedback.success{color:#398363}.manual-scan{padding:10px 0 6px;border-top:1px solid #f0f1f2}.manual-scan>label{display:block;font-size:8px;font-weight:800;letter-spacing:.75px;color:#9196a0;margin-bottom:7px}.manual-input-row{height:37px;border:1px solid #e9ebee;border-radius:8px;display:flex;align-items:center;padding:0 5px 0 10px;gap:7px;color:#a1a6af}.manual-input-row>span{font-size:14px}.manual-input-row input{flex:1;min-width:0;border:0;outline:0;background:transparent;font-size:10px;color:#333944}.manual-input-row input::placeholder{color:#b1b5bc}.manual-input-row button{border:0;width:27px;height:27px;border-radius:6px;background:#fff0e4;color:#e76b1d;font-size:17px}.manual-scan small{font-size:8px;color:#a3a7ae;display:block;margin-top:6px}.scanner-footer{display:flex;align-items:center;justify-content:space-between;padding-top:5px}.scanner-footer .text-btn{color:#787e89}.scanner-footer .text-btn:disabled{opacity:.45;cursor:not-allowed}.scanner-footer>span{font-size:8px;color:#b1b4bb}.bottom-note{display:flex;align-items:center;gap:7px;margin-top:13px;color:#a1a5ad;font-size:9px}.bottom-note span{font-size:9px;color:#36a87a}.modal-backdrop{position:fixed;inset:0;z-index:50;background:#161a21a8;backdrop-filter:blur(3px);display:none;place-items:center;padding:18px}.modal-backdrop.open{display:grid}.modal{width:min(590px,100%);max-height:min(92dvh,760px);background:white;border-radius:16px;box-shadow:0 25px 80px #0003;display:flex;flex-direction:column;overflow:hidden}.modal-header{padding:20px 21px 16px;display:flex;align-items:center;gap:12px;border-bottom:1px solid #f0f1f2}.modal-mark{width:37px;height:37px;display:grid;place-items:center;background:#fff1e5;color:#ee741f;border-radius:11px;font-size:21px}.modal-header h2{font-size:15px;margin:0;font-weight:800}.modal-header p{font-size:10px;color:#979ca5;margin:4px 0 0}.icon-btn{border:0;background:transparent;color:#8a9099;font-size:23px;line-height:1;margin-left:auto;padding:4px}.modal-body{padding:17px 21px;overflow:auto}.format-help{background:#f8f9fa;border:1px solid #eff0f2;border-radius:9px;padding:10px 11px;margin-bottom:14px}.format-help strong{display:block;font-size:9px;color:#777e89;margin-bottom:6px}.format-help code{font-size:9px;line-height:1.7;color:#8b9098;white-space:normal}.file-drop{min-height:100px;border:1px dashed #f6ba8e;border-radius:10px;display:flex;align-items:center;justify-content:center;flex-direction:column;position:relative;cursor:pointer;background:#fffaf6}.file-drop:hover{background:#fff5ec}.file-drop .upload-icon{font-size:18px;color:#ed7927}.file-drop strong{font-size:10px;color:#464c56;margin:4px 0}.file-drop>span:last-of-type{font-size:9px;color:#a3a7af}.file-drop input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.paste-label{display:block;font-size:9px;font-weight:700;color:#777d87;margin:13px 0 6px}.modal-body textarea{width:100%;resize:vertical;border:1px solid #e8eaed;border-radius:8px;padding:10px;font-size:10px;outline:none;color:#414650}.modal-body textarea:focus{border-color:#fdba74}.replace-row{display:flex;align-items:center;gap:7px;margin-top:12px;font-size:9px;color:#777d87}.replace-row input{accent-color:var(--orange)}.replace-row .text-btn{margin-left:auto}.modal-footer{border-top:1px solid #f0f1f2;padding:13px 20px;display:flex;align-items:center;justify-content:flex-end;gap:8px}.modal-footer>span{margin-right:auto;max-width:220px;font-size:8px;line-height:1.5;color:#a0a4ac}.modal-footer .btn{height:35px;font-size:10px}.toast{position:fixed;left:50%;bottom:24px;transform:translate(-50%,20px);opacity:0;pointer-events:none;background:#272b33;color:white;border-radius:10px;padding:11px 15px;display:flex;align-items:center;gap:8px;font-size:11px;font-weight:600;box-shadow:0 8px 24px #0003;z-index:80;transition:.22s;max-width:calc(100vw - 28px)}.toast.show{opacity:1;transform:translate(-50%,0)}.toast #toast-icon{color:#60d2a2;font-size:14px}.mobile-only,.mobile-list-trigger{display:none}button[disabled]{opacity:.48;cursor:not-allowed}
@media(min-width:1440px){.main-panel{padding-left:42px;padding-right:42px}.content-grid{grid-template-columns:minmax(440px,1.05fr) minmax(360px,.95fr);gap:18px}.camera-stage{min-height:280px}}
@media(max-width:1100px){.workspace{grid-template-columns:260px minmax(0,1fr)}.main-panel{padding:24px 20px}.metrics-grid{gap:8px}.metric-card{padding:13px}.metric-card>div>strong{font-size:21px}.content-grid{grid-template-columns:1fr}.scanner-card{min-height:380px}.camera-stage{min-height:240px}.dashboard-head h2{font-size:22px}}
@media(max-width:760px){.topbar{height:61px;padding:0 14px;gap:10px}.brand-lockup{min-width:0;gap:8px}.brand-mark{width:34px;height:34px;border-radius:10px}.brand-name{font-size:15px}.brand-caption{font-size:8px}.header-context{display:none}.top-actions{gap:6px}.top-actions .btn{height:35px;padding:0 10px;font-size:10px}.sync-pill{font-size:0;padding:7px}.sync-pill i{width:7px;height:7px}.workspace{display:block;min-height:calc(100dvh - 61px)}.sidebar{position:fixed;inset:61px 0 0 0;z-index:30;width:min(340px,88vw);height:auto;min-height:0;transform:translateX(-105%);transition:transform .22s ease;box-shadow:15px 0 35px #20242c18}.sidebar.mobile-open{transform:translateX(0)}.mobile-only{display:block}.main-panel{padding:19px 13px 22px}.mobile-list-trigger{display:flex;align-items:center;gap:11px;margin-bottom:17px;min-width:0}.mobile-list-trigger .btn{height:32px;padding:0 10px;font-size:10px}.mobile-list-trigger .btn b{font-size:9px;color:#ee7424;background:#fff0e5;border-radius:12px;padding:3px 5px}.mobile-list-trigger>span{font-size:10px;color:#8e939c;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dashboard-head{margin-bottom:14px}.dashboard-head h2{font-size:21px}.subhead{font-size:10px;max-width:275px;line-height:1.5}.metrics-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-bottom:12px}.metric-card{padding:11px 12px}.metric-label{font-size:7px}.metric-card>div{margin:7px 0 5px}.metric-card>div>strong{font-size:21px}.metric-symbol{height:25px;width:25px}.metric-foot{font-size:8px}.content-grid{gap:10px}.count-card,.scanner-card{border-radius:12px}.count-card{padding:15px 13px}.active-product{padding:15px 0 12px}.active-name{font-size:14px}.product-facts{padding:10px 4px}.product-facts>div{padding:0 6px}.product-facts span{font-size:8px}.product-facts strong{font-size:11px}.count-divider{margin:14px 0 12px}.quantity-control{height:70px;gap:16px}.quantity-input-wrap input{font-size:31px;width:105px}.quick-steps{gap:5px}.quick-steps>span{font-size:7px}.quick-steps button{padding:6px 8px}.card-actions .btn{height:39px;font-size:10px}.scanner-card{padding:15px 13px 12px;min-height:390px}.camera-stage{min-height:220px}.bottom-note{font-size:8px}.desktop-only{display:none}.modal-backdrop{padding:10px;align-items:end}.modal{border-radius:16px 16px 10px 10px;max-height:93dvh}.modal-header{padding:16px}.modal-body{padding:13px 16px}.modal-footer{padding:11px 14px}.modal-footer>span{display:none}.toast{bottom:max(17px,env(safe-area-inset-bottom));font-size:10px}.hide-mobile{display:none}}
@media(max-width:390px){.topbar{padding:0 10px}.top-actions .btn{padding:0 8px}.metrics-grid{gap:6px}.metric-card{padding:10px}.product-facts>div{padding:0 4px}.product-facts span{font-size:7px}.quantity-input-wrap input{width:94px}.quick-steps{gap:4px}.quick-steps button{padding:6px}.format-pill{font-size:7px}.count-label-row{gap:5px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}

/* Scan-first stocktake flow */
@media(min-width:1101px){.content-grid{grid-template-columns:minmax(340px,.96fr) minmax(370px,1.04fr);grid-template-areas:"scanner count"}.scanner-card{grid-area:scanner}.count-card{grid-area:count}.camera-stage{min-height:320px}}
@media(max-width:1100px){.content-grid{grid-template-areas:"scanner" "count"}.scanner-card{grid-area:scanner}.count-card{grid-area:count}}
.camera-requirement{font-size:9px;color:#c7c8ce;margin-top:11px}.camera-stage.is-awaiting{box-shadow:inset 0 0 0 2px #fb923c}.camera-stage.is-awaiting .camera-live-label{background:#b84e11}.camera-stage.is-awaiting .scan-frame{opacity:.22}.import-message{color:#8b9099;font-size:11px;line-height:1.5;margin:12px 0 0}.file-drop input{max-width:100%}
@media(max-width:760px){.main-panel{display:grid;grid-template-columns:minmax(0,1fr);grid-template-areas:"mobile-list" "dashboard" "content" "metrics" "note";gap:0;padding:14px 14px calc(22px + env(safe-area-inset-bottom))}.mobile-list-trigger{grid-area:mobile-list}.dashboard-head{grid-area:dashboard;margin:13px 0 14px;align-items:flex-start}.dashboard-head h2{font-size:22px}.dashboard-head .subhead{max-width:330px;line-height:1.45}.content-grid{grid-area:content;display:flex;flex-direction:column;gap:12px}.scanner-card{order:0;padding:15px 14px 10px;min-height:0}.count-card{order:1;padding:16px 14px 14px}.camera-stage{min-height:300px;flex:none}.camera-stage.is-live{min-height:300px}.scanner-heading{margin-bottom:10px}.scan-feedback{font-size:11px;min-height:43px;padding:11px 2px}.manual-scan{padding-top:10px}.manual-scan>label{font-size:9px}.manual-input-row{height:42px}.manual-input-row input{font-size:14px}.manual-scan small{font-size:9px}.scanner-footer>span{font-size:9px}.count-hint{font-size:10px}.quantity-control{height:86px}.quantity-input-wrap input{font-size:40px;width:140px}.card-actions{position:sticky;bottom:0;background:#fff;padding:8px 0 max(2px,env(safe-area-inset-bottom));z-index:4}.card-actions .btn{height:48px;font-size:13px}.card-actions .confirm-btn{flex:1.5}.metrics-grid{grid-area:metrics;grid-template-columns:repeat(2,minmax(0,1fr));margin:14px 0 0;gap:8px}.metric-card{padding:12px}.metric-card>div>strong{font-size:20px}.metric-label{font-size:8px}.metric-foot{font-size:9px}.bottom-note{grid-area:note;margin-top:14px;line-height:1.5}.top-actions{gap:5px}.top-actions .btn{padding:0 9px;font-size:10px}.top-actions .btn-primary{min-width:98px}.sync-pill{padding:6px 7px}.sync-pill span{max-width:52px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.brand-lockup{min-width:0}.header-context{display:none}}
@media(max-width:390px){.main-panel{padding-left:10px;padding-right:10px}.top-actions .btn{padding:0 7px}.top-actions .btn-quiet{font-size:9px}.brand-mark{width:34px;height:34px}.brand-caption{font-size:8px}.camera-stage,.camera-stage.is-live{min-height:270px}.count-card{padding-left:12px;padding-right:12px}.quantity-control{gap:14px}}

@media(max-width:760px){.top-actions #import-btn span:last-child{display:none}.top-actions #import-btn{width:38px;padding:0}.top-actions #import-btn .icon{font-size:20px}.top-actions .btn-primary{min-width:96px}}
@media(max-width:390px){.sync-pill span{display:none}.top-actions .btn-primary{min-width:88px;font-size:9px}.brand-lockup{gap:7px}}

/* Warehouse context and mobile refresh */
.warehouse-picker{display:flex;align-items:center;gap:7px;padding:5px 8px;border:1px solid var(--line);border-radius:9px;background:#fff;color:#969ba5}
.warehouse-picker>span{font-size:8px;font-weight:800;letter-spacing:.6px;white-space:nowrap}
.warehouse-picker select{max-width:155px;border:0;background:transparent;color:#454b55;font-size:10px;font-weight:700;outline:none}
.refresh-btn{width:38px;padding:0;font-size:18px}
.refresh-indicator{height:0;overflow:hidden;display:flex;align-items:center;justify-content:center;color:#8d929c;font-size:10px;font-weight:700;transition:height .18s,opacity .18s;opacity:0}
.refresh-indicator.pull-ready{height:30px;opacity:1;color:var(--orange-dark)}
.refresh-indicator.refreshing{height:32px;opacity:1;color:var(--orange-dark)}
.refresh-indicator.refreshing:before{content:"";width:11px;height:11px;border:2px solid #ffd4b5;border-top-color:var(--orange);border-radius:50%;margin-right:8px;animation:refresh-spin .7s linear infinite}
.refresh-indicator.refreshing{font-size:0}.refresh-indicator.refreshing:after{content:"Refreshing · saved counts stay safe";font-size:10px}
@keyframes refresh-spin{to{transform:rotate(360deg)}}
@media(max-width:760px){.top-actions{gap:4px}.warehouse-picker{padding:4px 5px;gap:3px}.warehouse-picker>span{display:none}.warehouse-picker select{max-width:86px;font-size:9px}.refresh-btn{width:33px;height:35px!important;padding:0!important}.refresh-indicator{grid-row:1}}
@media(max-width:760px){.topbar{padding-left:8px;padding-right:8px;gap:7px}.top-actions{gap:3px}.warehouse-picker select{max-width:62px}.top-actions #export-btn{width:34px;padding:0}.top-actions #export-btn span:last-child{display:none}.top-actions #import-btn{width:34px}}
