:root{--bg:#061522;--panel:#0a2132;--panel2:#0d2a3e;--line:#17384d;--text:#eef7ff;--muted:#8da3b8;--primary:#2368e8}*{box-sizing:border-box}body{margin:0;background:radial-gradient(circle at top,#0a263b 0,#061522 45%,#04111c 100%);color:var(--text);font-family:Inter,system-ui,sans-serif}.app-shell{min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:245px;background:#061927;border-right:1px solid var(--line);padding:18px 14px;z-index:20;display:flex;flex-direction:column}.brand{display:flex;gap:11px;align-items:center;padding:0 7px 22px}.brand>i{font-size:38px;color:#ffc107}.brand div{display:flex;flex-direction:column;line-height:1}.brand b{font-size:18px}.brand span{font-size:17px;color:#53a3ff;font-weight:800}.brand small{font-size:10px;color:var(--muted);margin-top:5px}.sidebar nav{display:flex;flex-direction:column;gap:5px}.sidebar nav a,.sidebar-bottom a{color:#cbd8e5;text-decoration:none;padding:11px 12px;border-radius:8px;display:flex;gap:11px;align-items:center}.sidebar nav a:hover,.sidebar nav a.active{background:linear-gradient(90deg,#1e5ad0,#204ca4);color:white}.sidebar-bottom{margin-top:auto;border-top:1px solid var(--line);padding-top:14px;display:flex;flex-direction:column}.sidebar-bottom small{color:var(--muted)}.topbar{position:fixed;top:0;left:245px;right:0;height:70px;background:rgba(4,17,28,.9);backdrop-filter:blur(12px);border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 24px;z-index:15}.topbar h1{font-size:18px;margin:0}.topbar small{color:var(--muted)}.top-actions{margin-left:auto;display:flex;gap:18px;align-items:center}.avatar{width:38px;height:38px;border-radius:50%;background:#e7eef6;color:#102437;display:grid;place-items:center;font-weight:800}.menu-btn{display:none;background:none;border:0;color:white;font-size:25px}.content{margin-left:245px;padding:92px 20px 40px}.page-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}.page-head h2{font-size:24px;margin:0}.page-head p{color:var(--muted);margin:4px 0 0}.date-pill{background:var(--panel);border:1px solid var(--line);padding:9px 13px;border-radius:8px}.stats-grid{display:grid;grid-template-columns:repeat(7,minmax(150px,1fr));gap:12px;margin-bottom:14px}.stat-card{background:linear-gradient(145deg,var(--panel),#071c2c);border:1px solid var(--line);border-radius:10px;padding:14px;display:flex;align-items:center;gap:12px}.stat-card small{display:block;color:#b5c4d1;font-size:11px;text-transform:uppercase}.stat-card strong{display:block;font-size:21px;margin-top:5px}.stat-icon{width:45px;height:45px;border-radius:50%;display:grid;place-items:center;font-size:21px}.blue{background:#245ad0}.green{background:#28a745}.purple{background:#6f42c1}.orange{background:#f59f00}.yellow{background:#c98600}.red{background:#d73b3e}.cyan{background:#0891b2}.dash-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-bottom:12px}.span-2{grid-column:span 2}.panel{background:linear-gradient(145deg,var(--panel),#071c2c);border:1px solid var(--line);border-radius:10px;padding:14px}.panel-title{display:flex;justify-content:space-between;align-items:center;margin-bottom:12px}.panel-title h3{font-size:16px;margin:0}.panel-title a,.panel-title span{color:#62a4ff;font-size:12px}.table-darkish{--bs-table-bg:transparent;--bs-table-color:#dce8f4;--bs-table-border-color:#17384d;margin:0}.table-darkish thead th{color:#99aec1;font-size:12px;font-weight:500}.badge.danger{background:#7c1d1d;border:1px solid #c54a4a}.ranking{padding-left:25px}.ranking li{padding:10px 0;border-bottom:1px solid var(--line);display:flex;justify-content:space-between}.expiry-list>div{display:flex;justify-content:space-between;padding:10px 0;border-bottom:1px solid var(--line)}.expiry-list span{display:flex;flex-direction:column}.expiry-list small{color:var(--muted)}.expiry-list em{font-style:normal;font-size:12px;padding:4px 7px;border-radius:5px;height:max-content}.expired,.urgent{background:#7a2020;color:#ffb0b0}.warning{background:#6c520d;color:#ffd970}.searchbar{display:flex;gap:8px;margin-bottom:12px}.form-control,.form-select{background:#071a29;border-color:#24435a;color:white}.form-control:focus,.form-select:focus{background:#071a29;color:white;border-color:#3679e6;box-shadow:none}.form-control::placeholder{color:#6f879b}.dark-modal{background:#0a2132;color:white;border:1px solid var(--line)}label{display:block;color:#b7c7d9;font-size:13px;margin:9px 0 5px}.report-card{background:linear-gradient(145deg,var(--panel),#071c2c);border:1px solid var(--line);border-radius:12px;padding:20px;color:white;text-decoration:none;display:flex;flex-direction:column;align-items:flex-start;min-height:150px}.report-card i{font-size:32px;color:#4f91ff}.report-card b{font-size:18px;margin:12px 0 5px}.report-card span{color:var(--muted)}.login-page{min-height:100vh;display:grid;place-items:center}.login-card{width:min(410px,92vw);padding:32px;background:rgba(10,33,50,.95);border:1px solid var(--line);border-radius:16px;box-shadow:0 20px 80px #0008}.login-card h2{text-align:center}.login-card p,.login-card>small{text-align:center;color:var(--muted);display:block}.login-logo{text-align:center;font-size:48px}.login-card .btn{margin-top:18px}@media(max-width:1400px){.stats-grid{grid-template-columns:repeat(4,1fr)}}@media(max-width:900px){.sidebar{transform:translateX(-100%);transition:.25s}.sidebar.open{transform:none}.topbar{left:0}.menu-btn{display:block;margin-right:12px}.content{margin-left:0}.stats-grid{grid-template-columns:repeat(2,1fr)}.dash-grid{grid-template-columns:1fr}.span-2{grid-column:span 1}}@media(max-width:560px){.content{padding:85px 10px 25px}.stats-grid{grid-template-columns:1fr}.page-head{align-items:flex-start;gap:10px;flex-direction:column}.topbar h1{font-size:15px}.date-pill{display:none}}

/* Camada responsiva avançada: desktop, tablet e celular */
.sidebar-backdrop{position:fixed;inset:0;background:rgba(0,0,0,.58);backdrop-filter:blur(2px);z-index:19;opacity:0;visibility:hidden;transition:.22s}.sidebar-backdrop.show{opacity:1;visibility:visible}body.menu-open{overflow:hidden}.mobile-table-wrap{width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}.mobile-table-wrap table{min-width:720px}.panel canvas{min-height:280px;max-height:340px}.btn,.form-control,.form-select{min-height:42px}.page-head,.panel-title,.searchbar{min-width:0}.page-head>*{min-width:0}

@media (min-width:1200px){.sidebar-backdrop{display:none}.content{max-width:none}.device-desktop .stats-grid{grid-template-columns:repeat(4,minmax(180px,1fr))}}

@media (min-width:768px) and (max-width:1199px){
  .sidebar{width:280px;transform:translateX(-105%);box-shadow:18px 0 45px #0008;transition:transform .25s ease}.sidebar.open{transform:translateX(0)}
  .topbar{left:0;height:68px;padding:0 18px}.menu-btn{display:block;margin-right:12px}.content{margin-left:0;padding:88px 16px 32px}
  .stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dash-grid{grid-template-columns:1fr 1fr}.dash-grid .span-2{grid-column:span 2}
  .page-head{gap:14px}.top-actions{gap:14px}
}

@media (max-width:767px){
  body{background:#061522}.sidebar{width:min(86vw,320px);transform:translateX(-105%);transition:transform .25s ease;box-shadow:18px 0 45px #0009;padding-bottom:max(18px,env(safe-area-inset-bottom))}.sidebar.open{transform:translateX(0)}
  .topbar{left:0;height:64px;padding:0 12px;gap:2px}.menu-btn{display:block;margin-right:8px;min-width:42px;min-height:42px;border-radius:10px}.menu-btn:active{background:#0d2a3e}.topbar h1{font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:52vw}.topbar small{display:none}.top-actions{gap:10px}.avatar{width:34px;height:34px}.content{margin-left:0;padding:78px 10px calc(24px + env(safe-area-inset-bottom))}
  .page-head{align-items:stretch;gap:10px;flex-direction:column;margin-bottom:14px}.page-head h2{font-size:21px}.page-head p{font-size:13px}.date-pill{display:none}
  .stats-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.stat-card{padding:11px;gap:9px;min-width:0}.stat-card small{font-size:9px;line-height:1.2}.stat-card strong{font-size:17px}.stat-icon{width:38px;height:38px;font-size:17px;flex:0 0 auto}
  .dash-grid{grid-template-columns:1fr;gap:10px}.span-2{grid-column:auto}.panel{padding:12px;border-radius:12px;overflow:hidden}.panel-title{gap:10px;align-items:flex-start}.panel-title h3{font-size:15px}.panel canvas{min-height:240px;max-height:280px}
  .searchbar{display:grid;grid-template-columns:1fr;gap:8px}.searchbar .btn{width:100%}.row.g-3>[class*="col-"]{width:100%}
  .modal-dialog{margin:10px}.modal-content{border-radius:14px}.modal-body{padding:14px}.modal-footer{padding:12px;gap:8px}.modal-footer .btn{flex:1}
  .report-card{min-height:130px;padding:16px}.report-card b{font-size:16px}
  .expiry-list>div,.ranking li{gap:10px}.expiry-list em{white-space:nowrap}
}

@media (max-width:420px){
  .stats-grid{grid-template-columns:1fr}.stat-card{min-height:70px}.topbar h1{max-width:45vw}.mobile-table-wrap table{min-width:660px}
}

@media (hover:none) and (pointer:coarse){
  .sidebar nav a,.sidebar-bottom a{min-height:46px}.btn,.form-control,.form-select{font-size:16px}.sidebar nav a:hover{background:transparent}.sidebar nav a.active{background:linear-gradient(90deg,#1e5ad0,#204ca4)}
}

/* Versão visual 3 */
.dashboard-hero{position:relative;overflow:hidden;display:flex;align-items:center;justify-content:space-between;gap:24px;padding:26px 30px;margin-bottom:22px;border:1px solid #244d6a;border-radius:18px;background:radial-gradient(circle at 82% 20%,rgba(32,126,255,.30),transparent 32%),linear-gradient(120deg,#0c2940,#0a1f31 55%,#102f4a);box-shadow:0 18px 50px rgba(0,0,0,.22)}
.dashboard-hero:after{content:"";position:absolute;width:240px;height:240px;border:1px solid rgba(255,255,255,.08);border-radius:50%;right:-55px;top:-85px}.dashboard-hero h2{font-size:28px;margin:5px 0 8px}.dashboard-hero p{color:#b8cad8;margin:0 0 18px}.eyebrow{font-size:11px;letter-spacing:.18em;color:#70aaff;font-weight:700}.hero-actions{display:flex;gap:9px;flex-wrap:wrap}.hero-visual{width:150px;height:120px;display:grid;place-items:center;position:relative;border-radius:26px;background:linear-gradient(145deg,rgba(43,125,255,.28),rgba(54,198,93,.12));border:1px solid rgba(255,255,255,.1);transform:rotate(2deg)}.hero-visual i{font-size:58px;color:#6ea5ff}.hero-visual span{position:absolute;right:13px;bottom:9px;font-size:11px;font-weight:800;letter-spacing:.2em;color:#a8c7ed}.brand-mark{width:46px;height:46px;border-radius:14px;display:grid;place-items:center;background:linear-gradient(145deg,#2467ea,#20b365);box-shadow:0 8px 22px rgba(35,102,234,.35)}.brand-mark i{font-size:24px}.top-icon{width:39px;height:39px;display:grid;place-items:center;border-radius:11px;color:#d8e8f6;text-decoration:none;background:#0d2a3e;border:1px solid #24445b}.top-icon:hover{color:#fff;background:#173c56}.gray{background:#475569}.pink{background:#be185d}.chart-wrap{height:310px}.panel-title small{display:block;color:var(--muted);font-size:12px;margin-top:3px}.empty-state{min-height:160px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;color:#8da3b8;text-align:center}.empty-state i{font-size:30px;color:#41627b}.empty-state b{color:#c3d2df}.empty-state span{font-size:12px}.empty-mini{min-height:170px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;color:#8098ac;text-align:center}.empty-mini i{font-size:32px}.status-pill{display:inline-flex;align-items:center;padding:5px 9px;border-radius:999px;font-size:11px;font-weight:700;white-space:nowrap}.status-danger{background:rgba(239,68,68,.15);color:#ff8585;border:1px solid rgba(239,68,68,.3)}.status-warning{background:rgba(245,158,11,.15);color:#ffd166;border:1px solid rgba(245,158,11,.3)}.status-ok{background:rgba(34,197,94,.15);color:#73e398;border:1px solid rgba(34,197,94,.3)}.status-expired{background:#581b24;color:#ff9ca7;border:1px solid #8c3340}.page-actions{display:flex;gap:8px;flex-wrap:wrap}.form-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
@media(max-width:767px){.dashboard-hero{padding:20px 17px}.dashboard-hero h2{font-size:23px}.hero-visual{display:none}.hero-actions .btn{flex:1 1 145px}.chart-wrap{height:250px}.page-actions{width:100%}.page-actions .btn{flex:1}.form-row{grid-template-columns:1fr}}
@media print{.sidebar,.topbar,.menu-btn,.hero-actions,.page-actions{display:none!important}.content{margin:0!important;padding:15px!important}.panel,.stat-card,.dashboard-hero{break-inside:avoid;box-shadow:none}}

.nav-arrow{font-size:10px;opacity:.45}.admin-chip{display:flex;align-items:center;gap:10px;padding:12px;background:#0b2538;border:1px solid var(--line);border-radius:10px}.admin-chip>i{font-size:24px;color:#ffc107}.admin-chip div{display:flex;flex-direction:column}.compact-stats{grid-template-columns:repeat(4,minmax(170px,1fr))}.report-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.info-list>div{display:flex;justify-content:space-between;gap:15px;padding:12px 0;border-bottom:1px solid var(--line)}.info-list span{color:var(--muted)}.text-end form{margin-left:5px}.footer-status{margin-left:245px;border-top:1px solid var(--line);background:#061927;padding:15px 22px;display:grid;grid-template-columns:repeat(3,1fr);gap:12px;color:#b7c7d9}.footer-status div{display:flex;align-items:center;gap:10px}.footer-status i{font-size:22px;color:#5ee887}.footer-status small{display:block;color:var(--muted)}@media(max-width:1199px){.footer-status{margin-left:0}.report-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:767px){.compact-stats{grid-template-columns:repeat(2,1fr)}.report-grid{grid-template-columns:1fr}.footer-status{grid-template-columns:1fr;padding:14px 12px}}

/* Refinamento visual e CRUD completo */
.stats-main{grid-template-columns:repeat(4,minmax(190px,1fr));gap:12px}.stat-card{min-height:104px}.stat-card span{display:block;color:var(--muted);font-size:11px;margin-top:3px}.dashboard-title{margin-bottom:16px}.dashboard-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(320px,.85fr) minmax(280px,.7fr);gap:12px;margin-bottom:12px}.dashboard-layout.lower{grid-template-columns:minmax(0,2.2fr) minmax(320px,.8fr)}.side-stack{display:grid;gap:12px}.chart-panel .chart-wrap{height:290px}.category-chart{height:260px}.quick-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.qa{min-height:78px;border-radius:10px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;color:#fff;text-decoration:none;font-size:12px;font-weight:700}.qa i{font-size:20px}.qa.green{background:linear-gradient(145deg,#239a4a,#167d38)}.qa.red{background:linear-gradient(145deg,#df4b55,#ad2b34)}.qa.blue{background:linear-gradient(145deg,#326de6,#2451b4)}.qa.purple{background:linear-gradient(145deg,#7c4dd2,#6033ab)}.qa.orange{background:linear-gradient(145deg,#e9a325,#b97811)}.qa.teal{background:linear-gradient(145deg,#20a7a2,#147d79)}.product-cell,.user-cell{display:flex;align-items:center;gap:10px}.product-cell img,.product-placeholder{width:44px;height:44px;border-radius:8px;object-fit:contain;background:#fff;border:1px solid var(--line);flex:0 0 auto}.product-placeholder{display:grid;place-items:center;background:#102c40;color:#6f8ca3}.product-cell div,.user-cell div{display:flex;flex-direction:column}.product-cell small,.user-cell small{color:var(--muted);font-size:11px}.user-avatar{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(145deg,#366fe0,#4c9af1);font-weight:800}.optional{font-weight:400;color:#71889c;font-size:11px}.image-box{padding:14px;border:1px solid var(--line);border-radius:12px;background:#071a29}.image-preview{height:190px;border:1px dashed #31516a;border-radius:10px;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#7992a6;gap:7px;overflow:hidden;background:#061522}.image-preview img{width:100%;height:100%;object-fit:contain;background:#fff}.image-preview i{font-size:35px}.image-results{display:flex;gap:10px;overflow-x:auto;padding:6px 2px}.image-choice{width:92px;height:105px;flex:0 0 auto;border:2px solid transparent;border-radius:10px;padding:4px;background:#fff}.image-choice.selected{border-color:#3b82f6}.image-choice img{width:100%;height:100%;object-fit:contain}.image-loading{padding:18px;color:var(--muted)}.form-hint{display:block;color:var(--muted);font-size:11px;margin-top:8px}.permission-note{display:flex;gap:10px;margin-top:15px;padding:12px;border:1px solid #24445b;border-radius:10px;background:#0b2538}.permission-note i{color:#57d581;font-size:22px}.permission-note div{display:flex;flex-direction:column}.permission-note span{color:var(--muted);font-size:12px}.table-darkish td{vertical-align:middle}
@media(max-width:1450px){.dashboard-layout{grid-template-columns:minmax(0,1.6fr) minmax(300px,.8fr)}.category-panel{grid-column:span 2}.category-chart{height:230px}.stats-main{grid-template-columns:repeat(4,1fr)}}
@media(max-width:1100px){.dashboard-layout,.dashboard-layout.lower{grid-template-columns:1fr}.category-panel{grid-column:auto}.stats-main{grid-template-columns:repeat(2,1fr)}}
@media(max-width:560px){.stats-main{grid-template-columns:1fr}.quick-grid{grid-template-columns:repeat(2,1fr)}.qa{min-height:70px}}

/* Pente fino: dashboard clicável, validade visual e scanner */
.stat-link{text-decoration:none;color:inherit;transition:.18s transform,.18s border-color,.18s box-shadow}.stat-link:hover{color:inherit;transform:translateY(-3px);border-color:#3b82f6;box-shadow:0 15px 32px rgba(0,0,0,.28)}
.expiry-card-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:14px}.expiry-product-card{overflow:hidden;border:1px solid var(--line);border-radius:15px;background:linear-gradient(155deg,#0b2538,#071a29);box-shadow:0 12px 30px rgba(0,0,0,.16)}.expiry-image{height:170px;background:#fff;display:grid;place-items:center}.expiry-image img{width:100%;height:100%;object-fit:contain}.expiry-image i{font-size:52px;color:#71869a}.expiry-card-body{padding:15px}.expiry-card-body h3{font-size:17px;margin:12px 0 3px}.expiry-card-body p{color:var(--muted);font-size:12px}.expiry-card-top{display:flex;justify-content:space-between;align-items:center;gap:8px}.expiry-card-top small{color:var(--muted)}.expiry-card-body dl{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin:14px 0}.expiry-card-body dl div{padding:8px;border-radius:8px;background:#061925}.expiry-card-body dt{font-size:9px;text-transform:uppercase;color:var(--muted)}.expiry-card-body dd{margin:2px 0 0;font-size:12px;font-weight:700}.filter-pills{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-bottom:15px}.filter-pills span{color:var(--muted)}.filter-pills a{padding:7px 12px;border:1px solid var(--line);border-radius:999px;color:#b8cada;text-decoration:none}.filter-pills a.active,.filter-pills a:hover{background:#2467ea;color:#fff;border-color:#2467ea}.conversion-box{min-height:38px;padding:8px 12px;border-radius:8px;background:#0b2538;border:1px solid var(--line);color:#73e398;font-weight:700}.scanner-area{position:relative;overflow:hidden;min-height:280px;border-radius:12px;background:#020b12}.scanner-area video{width:100%;height:300px;object-fit:cover}.scanner-line{position:absolute;left:8%;right:8%;top:50%;height:2px;background:#ef4444;box-shadow:0 0 12px #ef4444;animation:scanline 1.7s ease-in-out infinite}@keyframes scanline{0%,100%{transform:translateY(-85px)}50%{transform:translateY(85px)}}
@media(max-width:560px){.expiry-card-grid{grid-template-columns:1fr}.expiry-card-body dl{grid-template-columns:1fr 1fr}.scanner-area video{height:240px}}

/* Dashboard fiel à referência — desktop amplo + composição mobile própria */
.dashboard-kpis{grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}.dashboard-kpis .stat-card{min-height:100px;padding:13px 12px;position:relative;overflow:hidden}.dashboard-kpis .stat-card:before{content:"";position:absolute;inset:auto -38px -60px auto;width:105px;height:105px;border-radius:50%;background:rgba(255,255,255,.025)}.dashboard-kpis .stat-copy{min-width:0}.dashboard-kpis .stat-copy small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dashboard-kpis .stat-copy strong{font-size:22px}.stat-chevron{display:none;margin-left:auto;color:#537189}.dashboard-primary{grid-template-columns:minmax(0,1.7fr) minmax(285px,.82fr) minmax(270px,.72fr)}.dashboard-secondary{grid-template-columns:minmax(0,2.25fr) minmax(310px,.75fr)}.dashboard-primary .panel,.dashboard-secondary .panel{box-shadow:0 10px 30px rgba(0,0,0,.12)}.expiry-list>a{display:flex;justify-content:space-between;gap:12px;padding:12px 0;border-bottom:1px solid var(--line);text-decoration:none;color:inherit}.expiry-list>a:hover b{color:#72a8ff}.expiry-list>a span{display:flex;flex-direction:column;min-width:0}.expiry-list>a b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mobile-expiry-list{display:none}.dashboard-insight-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-top:12px}.dashboard-insight-strip a{display:flex;align-items:center;gap:12px;padding:14px 16px;border:1px solid var(--line);border-radius:12px;background:linear-gradient(145deg,#0a2132,#071a29);text-decoration:none;color:#dce9f5}.dashboard-insight-strip i{width:42px;height:42px;border-radius:12px;display:grid;place-items:center;background:#0f3047;color:#69a6ff;font-size:20px}.dashboard-insight-strip span{display:flex;flex-direction:column}.dashboard-insight-strip small{color:var(--muted)}
@media(min-width:1500px){.content{padding-left:16px;padding-right:16px}.dashboard-kpis .stat-card{min-height:96px}.chart-panel .chart-wrap{height:300px}}
@media(min-width:1200px) and (max-width:1499px){.dashboard-kpis{grid-template-columns:repeat(3,1fr)}.dashboard-primary{grid-template-columns:minmax(0,1.55fr) minmax(290px,.8fr)}.dashboard-primary .category-panel{grid-column:span 2}.category-chart{height:210px}}
@media(min-width:768px) and (max-width:1199px){.dashboard-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.dashboard-primary,.dashboard-secondary{grid-template-columns:1fr 1fr}.dashboard-primary .chart-panel,.dashboard-secondary .expiry-table-panel{grid-column:span 2}.dashboard-primary .category-panel{grid-column:auto}.dashboard-insight-strip{grid-template-columns:1fr 1fr 1fr}}
@media(max-width:767px){.dashboard-title{margin-bottom:10px}.dashboard-title h2{font-size:19px}.dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-bottom:10px}.dashboard-kpis .stat-card{min-height:76px;padding:9px 8px;border-radius:11px;gap:8px}.dashboard-kpis .stat-icon{width:34px;height:34px;font-size:15px}.dashboard-kpis .stat-copy small{font-size:8px;letter-spacing:0}.dashboard-kpis .stat-copy strong{font-size:16px;margin-top:2px}.dashboard-kpis .stat-copy span{font-size:9px;line-height:1.15}.dashboard-kpis .stat-chevron{display:none}.dashboard-primary,.dashboard-secondary{display:flex;flex-direction:column;gap:9px}.dashboard-primary .chart-panel{order:1}.dashboard-primary .alerts-panel{order:2}.dashboard-primary .category-panel{order:3}.chart-panel .chart-wrap{height:225px}.category-chart{height:225px}.panel{padding:11px}.panel-title{margin-bottom:8px}.panel-title h3{font-size:14px}.panel-title small{font-size:10px}.panel-title a{font-size:10px}.expiry-list>a{padding:9px 0}.expiry-list>a b{font-size:12px}.expiry-list>a small{font-size:10px}.expiry-list>a em{font-size:9px}.desktop-expiry-table{display:none}.mobile-expiry-list{display:flex;flex-direction:column;gap:7px}.mobile-expiry-card{display:grid;grid-template-columns:43px minmax(0,1fr) auto;align-items:center;gap:9px;padding:8px;border:1px solid var(--line);border-radius:10px;background:#071c2c;text-decoration:none;color:inherit}.mobile-product-thumb{width:43px;height:43px;border-radius:8px;background:#fff;display:grid;place-items:center;overflow:hidden;color:#5d7488}.mobile-product-thumb img{width:100%;height:100%;object-fit:contain}.mobile-expiry-copy{display:flex;flex-direction:column;min-width:0}.mobile-expiry-copy b,.mobile-expiry-copy small,.mobile-expiry-copy span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.mobile-expiry-copy b{font-size:12px}.mobile-expiry-copy small{font-size:9px;color:var(--muted)}.mobile-expiry-copy span{font-size:9px;color:#a9bbcb;margin-top:2px}.side-stack{gap:9px}.ranking{padding-left:20px}.ranking li{padding:8px 0;font-size:11px}.quick-grid{grid-template-columns:repeat(3,1fr);gap:6px}.qa{min-height:61px;font-size:9px;border-radius:8px}.qa i{font-size:16px}.dashboard-insight-strip{grid-template-columns:1fr;gap:7px}.dashboard-insight-strip a{padding:10px 12px}.dashboard-insight-strip i{width:36px;height:36px;font-size:17px}.dashboard-insight-strip b{font-size:12px}.dashboard-insight-strip small{font-size:9px}.footer-status{display:none}}
@media(max-width:390px){.dashboard-kpis .stat-card{min-height:72px}.dashboard-kpis .stat-icon{width:31px;height:31px}.dashboard-kpis .stat-copy strong{font-size:15px}.quick-grid{grid-template-columns:repeat(2,1fr)}}
.type-chip-grid{display:flex;flex-wrap:wrap;gap:10px}.type-chip{display:flex;align-items:center;gap:8px;padding:9px 12px;border:1px solid rgba(255,255,255,.1);border-radius:999px;background:rgba(255,255,255,.035)}.type-chip form{margin:0}.type-chip button{border:0;background:transparent;color:#ff7676;padding:0 2px}.scanner-box{position:relative;overflow:hidden;min-height:230px;border-radius:14px;background:#020a12;border:1px solid rgba(58,193,255,.25)}.scanner-box video{display:block;width:100%;height:260px;object-fit:cover}.scanner-line{position:absolute;left:10%;right:10%;top:50%;height:2px;background:#28d7ff;box-shadow:0 0 14px #28d7ff}.scan-result{padding:12px;border-radius:10px;background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.08)}.qa.cyan{background:linear-gradient(135deg,#0c8fa8,#19bad0)}
@media(max-width:767px){.scanner-box{min-height:190px}.scanner-box video{height:210px}.type-chip-grid{gap:7px}.type-chip{font-size:.82rem;padding:7px 9px}}


/* Ajuste visual neutro e integração do leitor global */
:root{--primary:#526b80;--panel:#0b1d2a;--panel2:#102634;--line:#29404f;--muted:#8fa0ae}
body{background:linear-gradient(160deg,#07131d,#0a1b27 48%,#08151f);}
.sidebar{background:#091923;border-right-color:#243946}.topbar{background:rgba(7,19,29,.94)}
.sidebar nav a:hover{background:#182f40;color:#f0f5f8}.sidebar nav a.active{background:linear-gradient(90deg,#29475d,#31566f);box-shadow:inset 0 0 0 1px rgba(255,255,255,.04)}
.brand span,.eyebrow,.panel-title a{color:#8db1c8}.brand-mark{background:linear-gradient(145deg,#3d667c,#3b776d);box-shadow:none}
.stat-card,.panel,.dashboard-insight-strip a,.report-card{background:linear-gradient(145deg,#102532,#0a1b26);border-color:#29404f;box-shadow:none!important}
.blue,.green,.purple,.orange,.yellow,.red,.cyan,.gray,.pink{background:#35566a}.stat-card:nth-child(2) .stat-icon{background:#3d655a}.stat-card:nth-child(3) .stat-icon{background:#5a526b}.stat-card:nth-child(4) .stat-icon{background:#75643b}.stat-card:nth-child(5) .stat-icon{background:#70484d}.stat-card:nth-child(6) .stat-icon{background:#386171}
.qa,.qa.cyan,.qa.green,.qa.red,.qa.blue,.qa.purple,.qa.orange,.qa.teal{background:#29485b!important;border:1px solid #38596b;color:#eef5f8}.qa:hover{background:#355a70!important}
.btn-primary,.btn-info,.btn-success,.btn-danger{background:#365c72;border-color:#466d82}.btn-primary:hover,.btn-info:hover,.btn-success:hover,.btn-danger:hover{background:#426b82;border-color:#527d94}
.btn-neutral{background:#365c72;border:1px solid #496f83;color:#f4f8fa}.btn-neutral:hover{background:#426b82;color:white}.top-icon{background:#132b3a;border-color:#294655}.form-control:focus,.form-select:focus{border-color:#56778c}
.filter-pills a.active,.filter-pills a:hover{background:#3b5d72;border-color:#52778d}.image-choice.selected{border-color:#587d92}.conversion-box{color:#adcbbf}
.scanner-page-grid{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(320px,.65fr);gap:14px}.scanner-page-box{min-height:360px}.scanner-page-box video{height:360px}.scanner-controls{display:flex;gap:8px;flex-wrap:wrap}.scanner-secure{font-size:11px;color:#9fb5c4}.scanner-corners{position:absolute;inset:17%;border:1px solid rgba(190,211,222,.4);border-radius:12px;pointer-events:none}.scanner-corners:before,.scanner-corners:after{content:"";position:absolute;width:28px;height:28px;border-color:#b7cedb}.scanner-corners:before{left:-2px;top:-2px;border-left:3px solid;border-top:3px solid}.scanner-corners:after{right:-2px;bottom:-2px;border-right:3px solid;border-bottom:3px solid}.scanner-product-card{display:flex;flex-direction:column;gap:14px}.scanner-product-image{height:190px;border-radius:13px;background:#f7f8f9;display:grid;place-items:center;overflow:hidden;color:#60717d}.scanner-product-image img{width:100%;height:100%;object-fit:contain}.scanner-product-image i{font-size:50px}.scanner-product-copy small{color:#94aab8;text-transform:uppercase;letter-spacing:.08em}.scanner-product-copy h3{margin:5px 0}.scanner-product-copy p{color:var(--muted)}.scanner-product-stats{display:grid;grid-template-columns:1fr 1fr;gap:8px}.scanner-product-stats div{padding:10px;border-radius:9px;background:#0a1923;border:1px solid var(--line);display:flex;flex-direction:column}.scanner-product-stats span{font-size:10px;color:var(--muted)}.scanner-action-grid{display:grid;gap:8px}.scanner-not-found{text-align:center;padding:30px 10px}.scanner-not-found i{font-size:46px;color:#708997}.scanner-not-found p{color:var(--muted)}
@media(max-width:900px){.scanner-page-grid{grid-template-columns:1fr}.scanner-page-box{min-height:280px}.scanner-page-box video{height:280px}}
@media(max-width:560px){.sidebar nav{gap:3px}.sidebar nav a{padding:9px 10px}.scanner-page-box{min-height:240px}.scanner-page-box video{height:240px}.scanner-product-image{height:150px}}

/* Estado inicial do dashboard sem dados */
.empty-dashboard-setup{display:flex;align-items:center;gap:18px;padding:18px 20px;margin-bottom:16px;background:linear-gradient(135deg,rgba(28,43,56,.94),rgba(19,32,44,.94));border:1px solid rgba(148,163,184,.16)}
.empty-dashboard-icon{width:52px;height:52px;border-radius:14px;display:grid;place-items:center;background:rgba(100,116,139,.16);color:#b8c4cf;font-size:24px;flex:0 0 auto}
.empty-dashboard-copy{flex:1;min-width:0}.empty-dashboard-copy h3{margin:0 0 4px;font-size:16px}.empty-dashboard-copy p{margin:0;color:#93a4b5;line-height:1.45;font-size:13px}
.empty-dashboard-actions{display:flex;gap:10px;flex-wrap:wrap}.empty-dashboard-actions .btn{white-space:nowrap}
@media(max-width:767px){.empty-dashboard-setup{align-items:flex-start;flex-wrap:wrap}.empty-dashboard-copy{flex-basis:calc(100% - 72px)}.empty-dashboard-actions{width:100%}.empty-dashboard-actions .btn{flex:1;min-width:140px}}
