.barcode-camera{position:relative;overflow:hidden;aspect-ratio:4/3;border-radius:18px;background:#102b24}.barcode-camera video{width:100%;height:100%;object-fit:cover}.barcode-guide{position:absolute;inset:23%;border:3px solid var(--acid);border-radius:12px;box-shadow:0 0 0 999px #102b2466}.wizard-actions,.manual-barcode,.stock-update{display:flex;gap:12px;align-items:end;margin-top:14px}.manual-barcode{display:grid;grid-template-columns:1fr auto}.recognized-product{display:grid;grid-template-columns:48px 1fr;gap:14px;align-items:center;padding:18px;border-radius:16px;background:#eff5d7}.recognized-product>span{display:grid;place-items:center;width:48px;height:48px;border-radius:50%;background:var(--ink);color:var(--acid);font-size:1.4rem}.recognized-product h3{margin:3px 0;font-family:var(--display);font-size:1.5rem}.recognized-product p,.recognized-product small{margin:0;color:var(--muted)}.stock-update>label{flex:1;color:var(--muted);font-size:.75rem;font-weight:700}.source-result,.match-warning{display:grid;gap:4px;padding:14px;margin-bottom:12px;border-radius:13px;background:var(--paper)}.source-result span,.match-warning small{color:var(--muted);font-size:.72rem}.barcode-match-list{margin-bottom:16px}.barcode-match{width:100%;display:flex;justify-content:space-between;gap:12px;align-items:center;text-align:left;padding:13px;border:1px solid var(--line);border-radius:12px;background:white;color:var(--ink);margin-top:7px}.barcode-match strong,.barcode-match small{display:block}.barcode-match small{margin-top:4px;color:var(--muted);font-size:.66rem}.barcode-match b{color:var(--orange);font-size:.7rem}.muted-copy.error{color:var(--danger);font-weight:700}
@media(max-width:820px){html,body,.app-shell{min-height:100%;min-height:100dvh}.app-shell{padding-bottom:calc(72px + env(safe-area-inset-bottom))}.menu-toggle{display:none!important}.topbar{height:62px;padding-inline:16px}.topbar .brand span{width:36px;height:36px}.topbar-actions{display:none}.content{padding:22px 14px calc(94px + env(safe-area-inset-bottom));max-width:none}.page-head h1{font-size:2.45rem}.page-head>div>p:last-child{font-size:1rem}.view-dashboard>.summary-grid,.view-dashboard>.dashboard-grid,.view-dashboard>.recent-panel{display:none}.sidebar{display:block;position:fixed;inset:auto 0 0 0;transform:none!important;width:auto;height:calc(68px + env(safe-area-inset-bottom));z-index:40;padding:7px 6px env(safe-area-inset-bottom);border:0;border-top:1px solid var(--line);background:#fffdf8f2;backdrop-filter:blur(18px);box-shadow:0 -8px 30px #173f3514}.sidebar nav{height:100%;display:grid;grid-template-columns:repeat(5,1fr);gap:2px}.sidebar-foot,.sidebar .nav-item[data-view="stats"],.sidebar .nav-item[data-view="diabetes"],.sidebar .nav-item[data-view="diabetes-settings"],.sidebar .nav-item[data-view="settings"]{display:none}.sidebar .nav-item{display:flex;min-width:0;min-height:54px;flex-direction:column;justify-content:center;gap:2px;padding:4px 2px;text-align:center;border-radius:12px;font-size:.64rem;line-height:1.05}.sidebar .nav-item span{font-size:1.25rem}.sidebar .nav-item b{position:absolute;transform:translate(14px,-14px);padding:2px 5px;background:var(--orange);color:white}.sidebar .nav-item.active{background:var(--ink)}.mobile-core-action{order:3}.sidebar .nav-item[data-view="dashboard"]{order:1}.sidebar .nav-item[data-view="products"]{order:2}.sidebar .nav-item[data-view="advice"]{order:4}.sidebar .nav-item[data-view="receipts"]{order:5}.mobile-command{min-height:calc(100dvh - 190px);align-content:start}.mobile-tile{font-size:1rem}.mobile-tile strong{font-size:1.25rem}.mobile-tile small{font-size:.76rem}.toast{top:auto;left:12px;right:12px;bottom:calc(80px + env(safe-area-inset-bottom));padding:17px 18px;border-radius:14px;font-size:.92rem;line-height:1.35}.dialog{width:100%;max-width:none;margin:auto 0 0;border-radius:24px 24px 0 0;max-height:94dvh}.dialog form{padding:20px 16px calc(20px + env(safe-area-inset-bottom));overflow:auto;max-height:94dvh}.dialog h2{font-size:1.8rem}.barcode-wizard .form-grid{grid-template-columns:1fr 1fr}.barcode-camera{aspect-ratio:1.2}.wizard-actions{display:grid;grid-template-columns:1fr 1fr}.wizard-actions .button{width:100%}.stock-update{display:grid;grid-template-columns:1fr 1fr}.pwa-install-banner{bottom:calc(80px + env(safe-area-inset-bottom))}}
@media(max-width:390px){.barcode-wizard .form-grid,.wizard-actions,.stock-update{grid-template-columns:1fr}.sidebar .nav-item{font-size:.58rem}.page-head h1{font-size:2.2rem}}
