/* ASN ERP V4.8.7 – UI DE VERDADE, reconstruída a partir da referência visual aprovada.
   Somente na Visão Geral. Preserva o ERP multiempresa e todas as funções antigas. */
html.asn-brand-v482[data-theme="dark"] .main-content.dashboard-v34-shell{
 background:radial-gradient(ellipse 440px 210px at 73% 6%,rgba(133,6,27,.19),transparent 80%),#0c1119!important;
}
html.asn-brand-v482 .dashboard-v34{max-width:1700px!important}
html.asn-brand-v482 .dashboard-v34 .asn-v486-utility{height:68px;min-height:68px;margin-bottom:18px;background:rgba(12,18,27,.86);}
html.asn-brand-v482 .asn-v486-global-search{width:min(420px,60%);min-height:43px}
.asn-v487-header-icons{display:flex;align-items:center;gap:18px}
.asn-v487-header-icon{font-size:17px;color:#becbd9!important;text-decoration:none;display:grid;place-items:center;min-width:22px;min-height:27px}
.asn-v487-header-icon:hover{color:#fff!important}
.dashboard-v34 header.v34-topbar{min-height:63px;margin-bottom:16px!important;align-items:center!important}
.dashboard-v34 .v34-topbar h1{font-size:35px!important;margin:0!important;line-height:1.15;letter-spacing:-.045em}
.dashboard-v34 .v34-eyebrow{display:none!important}
.dashboard-v34 .asn-v486-headline-sub{font-size:13px;margin-top:4px;color:#b9c5d4}
.dashboard-v34 .v34-header-actions{align-items:center;gap:11px}
.asn-v487-date-card{height:61px;display:flex;align-items:center;gap:12px;background:#151a25;border:1px solid #303749;border-radius:11px;padding:10px 14px;min-width:275px}
.asn-v487-cal{font-size:22px;color:#c5d2e1}
.asn-v487-date-card strong{display:block;font-size:11px;color:#f2f5fa;font-weight:700;max-width:270px}
.asn-v487-date-card small{display:block;font-size:10px;color:#acb9ca;margin-top:3px}
.asn-v487-actions{position:relative;z-index:15;flex:0 0 auto}
.asn-v487-actions summary{cursor:pointer;list-style:none;color:#c3cfdd;background:#141c29;border:1px solid #324055;border-radius:9px;padding:11px 12px;font-size:11px;font-weight:700}
.asn-v487-actions summary::-webkit-details-marker{display:none}
.asn-v487-action-list{position:absolute;right:0;top:calc(100% + 7px);min-width:225px;display:flex;flex-direction:column;gap:9px;padding:13px;background:#111a27;border:1px solid #354256;border-radius:12px;box-shadow:0 15px 45px rgba(0,0,0,.4);}
.asn-v487-action-list>*{width:100%;justify-content:center!important}
/* Filter layout: four aligned groups + action, while original IDs and events are unchanged */
.dashboard-v34 .v34-filterbar{padding:16px 16px 11px!important;margin-bottom:13px!important;border-radius:14px!important;}
.dashboard-v34 .v34-filter-main{display:grid!important;grid-template-columns:minmax(200px,1.25fr) minmax(160px,.85fr) minmax(170px,.95fr) minmax(340px,2.15fr)!important;align-items:end!important;column-gap:12px!important;row-gap:8px!important;}
.dashboard-v34 .v34-filter-main .filter-group{min-width:0}
.dashboard-v34 .v34-filter-main .filter-group>label,.dashboard-v34 .asn-dashboard-tools-title{display:block!important;margin:0 0 7px!important;color:#aebbd0!important;font-weight:800!important;font-size:10px!important;text-transform:uppercase;letter-spacing:.055em;}
.dashboard-v34 .v34-filter-main .filter-input{height:42px;min-height:42px}
.dashboard-v34 .v34-platform-pills{display:flex;align-items:center;min-height:42px;gap:5px;flex-wrap:wrap}
.dashboard-v34 .v34-platform-pills label{padding:6px 8px!important;margin:0!important;border-radius:8px!important}
.dashboard-v34 .asn-dashboard-tools-v458{display:flex!important;flex-wrap:wrap!important;align-items:center!important;justify-content:flex-start!important;column-gap:6px!important;row-gap:5px!important;margin:0!important;padding:0!important;border:0!important;min-width:0}
.dashboard-v34 .asn-dashboard-tools-v458>.asn-dashboard-tools-title{width:100%;flex:0 0 100%;margin:0!important;height:auto}
.dashboard-v34 .asn-dashboard-tools-v458 button:not(#asn-dash-refresh-v458){white-space:nowrap;font-size:10.5px!important;padding:0 11px!important;min-height:42px!important;}
html.asn-brand-v482 .dashboard-v34 #asn-dash-refresh-v458{height:42px!important;min-height:42px!important;font-size:11.5px!important;white-space:nowrap;margin-left:auto!important;padding:0 15px!important;box-shadow:0 2px 13px rgba(218,24,54,.24)!important}
.asn-v487-advanced{margin-top:8px;font-size:11px;color:#a9bacb}
.asn-v487-advanced>summary{cursor:pointer;color:#9fb0c3;font-size:10px}
.asn-v487-advanced .asn-month-filter-v460{display:flex;gap:10px;align-items:end;max-width:350px;padding:10px 0}
.asn-v487-advanced .asn-month-filter-v460>label{font-size:10px;color:#b7c4d0}
.asn-v487-advanced .asn-month-controls-v460{display:flex;align-items:center;gap:7px}
.asn-v487-status-row{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:21px;margin-top:6px;font-size:10px;color:#98aabf;}
.asn-v487-status-row small{font-size:10px!important;line-height:1.4;}
/* six metric cards with understated decorative strokes and no imaginary growth rates */
.dashboard-v34 .v34-kpi-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important;gap:11px!important;margin-bottom:13px!important;}
.dashboard-v34 .v34-kpi{height:128px!important;min-height:128px!important;padding:14px 14px 11px!important;border-radius:13px!important;display:flex;flex-direction:column;overflow:hidden;}
.dashboard-v34 .v34-kpi::after{display:none!important}
.dashboard-v34 .v34-kpi-icon{height:33px;width:33px;flex:0 0 33px;border-radius:8px;color:#fff!important;background:linear-gradient(135deg,#841329,#ce203a)!important;margin:0!important;position:absolute;top:13px;left:13px;font-size:15px!important;}
.dashboard-v34 .v34-kpi-label{font-size:9px!important;color:#b6c1d2!important;text-transform:uppercase;letter-spacing:.025em;margin:4px 0 0 43px!important;min-height:12px}
.dashboard-v34 .v34-kpi-value{font-size:20px!important;font-weight:840!important;color:#f8f9fb!important;margin:7px 0 0 43px!important;line-height:1.18;letter-spacing:-.04em}
.dashboard-v34 .asn-v487-metric-foot{margin-top:auto;min-width:0;display:flex;align-items:end;justify-content:space-between;gap:5px}
.dashboard-v34 .asn-v487-metric-foot .v34-kpi-note{font-size:9px!important;color:#a8b7ca!important;line-height:1.4;white-space:normal;max-height:2.8em;overflow:hidden;flex:1}
.dashboard-v34 .asn-v487-metric-foot svg{color:#db304e;width:54px;height:24px;flex:0 0 54px;opacity:.88}
/* Charts 1.62:1 side-by-side like reference; status chart replaces cost chart. */
.dashboard-v34 .asn-v487-charts{grid-template-columns:minmax(0,1.62fr) minmax(0,1fr)!important;gap:13px;margin-bottom:13px;}
.dashboard-v34 .asn-v487-charts .asn-v486-chart-card{height:254px!important;min-height:254px!important;padding:15px 15px 9px!important;border-radius:14px!important;}
.dashboard-v34 .asn-v487-charts .asn-v486-chart-header{margin-bottom:9px;min-height:38px;}
.dashboard-v34 .asn-v487-charts .asn-v486-graph-icon{width:38px;height:38px;flex:0 0 38px;border-radius:9px;background:linear-gradient(135deg,#a1112b,#db2140);}
.dashboard-v34 .asn-v487-charts .asn-v486-chart-header h2{font-size:14px!important}
.dashboard-v34 .asn-v487-charts .asn-v486-chart-header p{font-size:10px;color:#a8baca;}
.asn-v487-plot-range{margin-left:auto;border:1px solid #334054;background:#121a27;color:#d1dce7;padding:8px 9px;border-radius:8px;white-space:nowrap;font-size:10px}
.asn-v487-canvas{height:174px!important;min-height:174px;position:relative;flex:1}
.asn-v487-canvas canvas{width:100%!important;height:100%!important}
.asn-v487-chart-status{font-size:9px!important;line-height:1.25;color:#a9b7c7;margin:2px 0 0;min-height:12px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}
.asn-v487-status-content{display:grid;grid-template-columns:minmax(120px,.95fr) minmax(175px,1.05fr);gap:9px;align-items:center;height:176px;min-height:176px}
.asn-v487-donut-area{height:166px;min-width:0;position:relative}
.asn-v487-donut-area canvas{height:100%!important;width:100%!important}
.asn-v487-donut-center{position:absolute;inset:0;display:flex;justify-content:center;align-items:center;flex-direction:column;pointer-events:none}
.asn-v487-donut-center strong{font-size:22px;color:#f5f7fb;font-weight:850}
.asn-v487-donut-center span{font-size:10px;color:#c2cbd8}
.asn-v487-status-legend{min-width:0;display:flex;flex-direction:column;gap:9px}
.asn-v487-status-row-item{display:grid;grid-template-columns:8px minmax(0,1fr) auto;gap:7px;align-items:center;font-size:10px;color:#cbd4e0}
.asn-v487-status-row-item .dot{width:8px;height:8px;border-radius:50%}
.asn-v487-status-row-item .name{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}
.asn-v487-status-row-item strong{font-size:10px;color:#f2f5fb}
.asn-v487-unavailable{font-size:10px;color:#9baec2}
/* Bottom cost cards and real product ranking */
.dashboard-v34 .v34-main-grid{grid-template-columns:minmax(0,1.38fr) minmax(0,1fr)!important;gap:13px;margin-bottom:14px}
.dashboard-v34 .v34-main-grid>.v34-panel{padding:14px 15px!important;border-radius:13px!important;}
.dashboard-v34 .v34-panel-head{align-items:center;margin-bottom:10px}
.dashboard-v34 .v34-panel-head>div:first-child:has(.asn-v487-card-icon){position:relative;padding-left:50px;min-height:42px;display:flex;flex-direction:column;justify-content:center}
.dashboard-v34 .asn-v487-card-icon{display:grid;place-items:center;position:absolute;left:0;top:0;height:40px;width:40px;background:linear-gradient(135deg,#a81734,#d72a45);border-radius:9px;color:#fff;font-size:20px;font-weight:900}
.dashboard-v34 .v34-main-grid .v34-panel-kicker:empty{display:none!important}
.dashboard-v34 .v34-main-grid .v34-panel h2{font-size:14px!important}
.dashboard-v34 .asn-v486-panel-hint{font-size:10px!important;color:#a8b9cb;margin-top:3px}
.dashboard-v34 .v34-total-cost{display:flex;align-items:center;gap:16px;min-width:0;text-align:left;}
.dashboard-v34 .v34-total-cost>span{display:none}
.dashboard-v34 .v34-total-cost>strong{font-size:14px!important;white-space:nowrap}
.dashboard-v34 .v34-total-cost::before{content:'CUSTOS TOTAIS';position:absolute;margin-top:-29px;color:#a9b5c8;font-size:9px}
.asn-v487-fin-profit{padding-left:16px;border-left:1px solid #344154}
.asn-v487-fin-profit span{display:block;font-size:9px!important;text-transform:uppercase;color:#a9b5c8!important;white-space:nowrap}
.dashboard-v34 .asn-v487-fin-profit strong{display:block;font-size:14px!important;color:#f7fafc!important;margin-top:4px;white-space:nowrap}
.dashboard-v34 .v34-breakdown-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}
.dashboard-v34 .v34-breakdown-item{position:relative;min-height:58px;padding:10px 8px 9px 47px!important;background:#1a2633!important;border:1px solid #273747!important;border-radius:10px}
.dashboard-v34 .v34-breakdown-item>span:not(.asn-v487-tile-icon):not(.asn-v487-cost-percent){display:block!important;min-height:16px;line-height:1.3;color:#acbacb;font-size:9px!important}
.dashboard-v34 .v34-breakdown-item strong{display:block!important;font-size:12px!important;margin-top:4px;color:#f3f6fc!important;white-space:nowrap}
.asn-v487-tile-icon{position:absolute;left:9px;top:12px;width:30px;height:30px;display:grid;place-items:center;background:#273546;color:#b2c2d2;font-size:16px;border-radius:9px}
.asn-v487-cost-percent{position:absolute;bottom:8px;right:6px;font-size:9px;color:#90a7bc}
.dashboard-v34 .v34-top-panel .v34-panel-head{justify-content:space-between}
.dashboard-v34 .v34-top-panel .v34-badge{display:none}
.asn-v487-view-products{color:#bbcddd!important;text-decoration:none;border:1px solid #334356;border-radius:7px;font-size:10px;padding:7px 9px;white-space:nowrap}
.dashboard-v34 .v34-top-panel .v34-compact-table th{font-size:9px!important;letter-spacing:.025em;background:#1b2836!important;color:#b7c6d6}
.dashboard-v34 .v34-top-panel .v34-compact-table td{font-size:10px!important;padding:8px 7px!important;line-height:1.34;vertical-align:middle}
.dashboard-v34 .v34-top-panel .v34-compact-table tbody tr{border-bottom:1px solid #263443}
.dashboard-v34 .v34-top-panel .v34-compact-table tbody td:nth-child(2){font-weight:650;max-width:180px}
.dashboard-v34 .v34-top-panel .v34-compact-table tbody td:nth-child(2)>strong{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.dashboard-v34 .v34-top-panel .v34-compact-table :is(td,th):nth-child(2){width:32%}
.dashboard-v34 .v34-top-panel .v34-compact-table :is(td,th):nth-child(3){width:18%}
.dashboard-v34 .v34-top-panel .v34-compact-table :is(td,th):nth-child(4){width:10%}
.dashboard-v34 .v34-top-panel .v34-compact-table :is(td,th):nth-child(5){width:18%}
.dashboard-v34 .v34-top-panel .v34-compact-table :is(td,th):nth-child(6){width:14%}
/* Light theme remains legible and fully working */
html.asn-brand-v482[data-theme="light"] .asn-v487-date-card,html.asn-brand-v482[data-theme="light"] .asn-v487-actions summary{background:#fff;border-color:#ced8e4}
html.asn-brand-v482[data-theme="light"] .asn-v487-date-card strong,html.asn-brand-v482[data-theme="light"] .asn-v487-actions summary{color:#29364a}
html.asn-brand-v482[data-theme="light"] .asn-v487-date-card small{color:#57667c}
html.asn-brand-v482[data-theme="light"] .asn-v487-action-list{background:#fff;border-color:#cad5e0}
html.asn-brand-v482[data-theme="light"] .asn-v487-header-icon{color:#516275!important}
html.asn-brand-v482[data-theme="light"] .dashboard-v34 .v34-kpi-label,html.asn-brand-v482[data-theme="light"] .dashboard-v34 .v34-filter-main .filter-group>label{color:#4d5b6a!important}
html.asn-brand-v482[data-theme="light"] .dashboard-v34 .v34-kpi-value,html.asn-brand-v482[data-theme="light"] .dashboard-v34 .asn-v487-donut-center strong{color:#172336!important}
html.asn-brand-v482[data-theme="light"] .dashboard-v34 .v34-breakdown-item{background:#f1f5fa!important;border-color:#d9e0e8!important}
html.asn-brand-v482[data-theme="light"] .dashboard-v34 .v34-breakdown-item strong{color:#172236!important}
html.asn-brand-v482[data-theme="light"] .asn-v487-status-row-item strong{color:#172236}
html.asn-brand-v482[data-theme="light"] .asn-v487-fin-profit strong{color:#172236!important}
html.asn-brand-v482[data-theme="light"] .asn-v487-plot-range{background:#fff;color:#4e6073;border-color:#d5dce5}
html.asn-brand-v482[data-theme="light"] .asn-v487-actions summary{color:#354659}
@media(max-width:1560px){
 .dashboard-v34 .v34-filter-main{grid-template-columns:minmax(170px,1fr) minmax(170px,.85fr) minmax(170px,.95fr)!important}
 .dashboard-v34 .asn-dashboard-tools-v458{grid-column:1/-1;justify-content:flex-start!important}
 .dashboard-v34 .asn-dashboard-tools-v458>.asn-dashboard-tools-title{flex:0 0 auto;width:auto!important;margin:0 10px 0 0!important}
}
@media(max-width:1280px){
 .dashboard-v34 .v34-kpi-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
 .dashboard-v34 .v34-kpi{height:130px!important}
 .dashboard-v34 .v34-main-grid{grid-template-columns:1fr!important}
}
@media(max-width:1000px){
 .dashboard-v34 .v34-filter-main{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .dashboard-v34 .asn-v487-charts{grid-template-columns:1fr!important}
 .dashboard-v34 .v34-filter-main .asn-dashboard-tools-v458{grid-column:1/-1}
}
@media(max-width:700px){
 .asn-v487-header-icons{display:none}
 .dashboard-v34 header.v34-topbar{align-items:start!important}
 .dashboard-v34 .v34-header-actions{width:100%;justify-content:space-between!important}
 .asn-v487-date-card{min-width:0;flex:1;height:auto}
 .dashboard-v34 .v34-filter-main{grid-template-columns:1fr!important}
 .dashboard-v34 .v34-filter-main .asn-dashboard-tools-v458{display:flex!important;flex-wrap:wrap!important}
 .dashboard-v34 .v34-filter-main .asn-dashboard-tools-v458>.asn-dashboard-tools-title{width:100%!important;flex-basis:100%!important}
 html.asn-brand-v482 .dashboard-v34 #asn-dash-refresh-v458{margin-left:0!important}
 .dashboard-v34 .v34-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .dashboard-v34 .v34-kpi{height:148px!important;min-height:148px!important}
 .dashboard-v34 .v34-kpi-value{font-size:17px!important;margin-left:0!important;margin-top:21px!important}
 .dashboard-v34 .v34-kpi-label{font-size:9px!important}
 .dashboard-v34 .v34-breakdown-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .dashboard-v34 .v34-total-cost{gap:8px}
 .dashboard-v34 .v34-total-cost>strong,.dashboard-v34 .asn-v487-fin-profit strong{font-size:12px!important}
 .dashboard-v34 .v34-financial-panel .v34-panel-head{flex-direction:column;align-items:flex-start}
 .dashboard-v34 .v34-total-cost::before{display:none}
 .dashboard-v34 .v34-main-grid{grid-template-columns:1fr!important}
 .dashboard-v34 .asn-v487-charts .asn-v486-chart-card{height:283px!important;min-height:283px!important}
 .asn-v487-canvas{height:198px!important;min-height:198px}
 .asn-v487-status-content{min-height:204px;height:204px}
}
@media(max-width:410px){
 .dashboard-v34 .v34-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 .dashboard-v34 .asn-v487-status-content{grid-template-columns:48% 52%;gap:3px}
 .asn-v487-status-row-item{font-size:9px}
}
/* Navegação real – logo fornecida pelo usuário, sem substituir permissões. */
html.asn-brand-v482 .asn-sidebar .asn-nav-mark{
 background:#9f0a1d url('asn-logo-icon-v483.png') center/cover no-repeat!important;
 color:transparent!important;-webkit-text-fill-color:transparent!important;
 border:1px solid #d62f46!important;box-shadow:0 4px 18px rgba(208,12,44,.23)!important;
 border-radius:10px!important;
}
html.asn-brand-v482 .asn-nav-brand-text strong{font-size:18px!important}
html.asn-brand-v482 .asn-sidebar .asn-nav-link.active{background:linear-gradient(100deg,#8f0e23,#c91c36)!important;box-shadow:0 5px 22px rgba(210,18,43,.18),inset 0 0 0 1px rgba(254,150,166,.4)!important}
