:root{--bg:#07151d;--panel:#0d2530;--panel2:#091b23;--line:#173944;--text:#f6f8fa;--muted:#91a7b0;--teal:#16c8b7;--yellow:#ffbe22;--green:#39d99a;--blue:#22a9f0;--purple:#b67ee9;--red:#ec6c7c;--orange:#ff9f43}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font-family:Inter,Segoe UI,Arial,sans-serif}.page{width:min(1500px,calc(100% - 24px));margin:auto;padding:18px 0 40px}
.header{display:grid;grid-template-columns:180px 1fr 100px;align-items:center;gap:18px}.brand-logo{width:165px;max-height:90px;object-fit:contain}.header-center{text-align:center}.eyebrow{color:var(--teal);font-size:11px;font-weight:900;letter-spacing:.12em}h1{margin:4px 0;font-size:34px}.sub,footer{color:var(--muted);font-size:12px}.flag-wrap{width:80px;height:80px;border-radius:50%;padding:4px;background:linear-gradient(135deg,var(--teal),var(--yellow))}.flag-wrap img{width:100%;height:100%;object-fit:cover;border-radius:50%}
.panel{background:linear-gradient(180deg,#0d2833,#0b202a);border:1px solid var(--line);border-radius:10px;overflow:hidden}.section-space{margin-top:12px}.filters{display:grid;grid-template-columns:repeat(5,1fr) auto;gap:10px;padding:12px;margin:14px 0}.filters label{display:grid;gap:5px;color:var(--muted);font-size:10px;font-weight:800}.filters select,.filters button,.chart-select,.triple-toolbar select,.map-toolbar select{background:var(--panel2);color:var(--text);border:1px solid var(--line);border-radius:8px;padding:9px 11px}.filters button{background:var(--teal);color:#06201d;font-weight:900;cursor:pointer}.error{padding:12px;border:1px solid var(--red);border-radius:8px;color:#ffd8de;background:rgba(236,108,124,.1)}
.kpi-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.kpi{padding:15px;background:var(--panel);border:1px solid var(--line);border-radius:10px}.kpi-label{color:var(--muted);font-size:10px;text-transform:uppercase;font-weight:900}.kpi-value{font-size:28px;font-weight:900;margin-top:8px}.kpi-note{color:var(--muted);font-size:10px;margin-top:5px}
.section-title{display:flex;justify-content:space-between;align-items:center;padding:13px 15px;border-bottom:1px solid rgba(255,255,255,.05)}.section-title h2{margin:0;font-size:13px;text-transform:uppercase}.section-title span{color:var(--muted);font-size:10px}.team-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;padding:14px}.seller-card{padding:14px;background:var(--panel2);border:1px solid var(--line);border-radius:10px}.seller-head{display:flex;align-items:center;gap:10px}.seller-head img{width:64px;height:64px;border-radius:50%;object-fit:cover;border:3px solid var(--teal)}.seller-name{font-weight:900}.seller-metric{margin-top:10px}.seller-row{display:flex;justify-content:space-between;font-size:10px;margin-bottom:4px}.bar{height:8px;background:#1d3741;border-radius:999px;overflow:hidden}.fill{height:100%;background:var(--teal)}.stack{display:flex;height:11px;border-radius:999px;overflow:hidden;background:#1d3741}.stack i{display:block;height:100%}.low{background:var(--blue)}.mid{background:var(--yellow)}.high{background:var(--red)}.stack-legend{display:grid;gap:3px;margin-top:5px;color:var(--muted);font-size:9px}
.charts-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-top:12px}.chart-card{min-height:390px}.chart-select{float:right;margin:10px 14px 0}.chart-wrap{height:320px;padding:12px 14px 16px;clear:both}.chart-wrap.tall{height:420px}.chart-wrap canvas{width:100%!important;height:100%!important}
.map-toolbar,.triple-toolbar{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;padding:12px 14px}.map-toolbar{grid-template-columns:240px}.map-layout{display:grid;grid-template-columns:1fr 280px;gap:12px;padding:0 14px 14px}.map-box{position:relative;height:520px;border:1px solid var(--line);border-radius:10px;background:#06131a}.map-box svg{width:100%;height:100%}#mapLoading{position:absolute;inset:0;display:grid;place-items:center;color:var(--muted)}.map-detail{padding:14px;border:1px solid var(--line);border-radius:10px;background:var(--panel2)}.map-shape{stroke:#fff;stroke-width:1;cursor:pointer}.map-label{pointer-events:none;fill:#fff;font-size:10px;font-weight:900;text-anchor:middle;paint-order:stroke;stroke:#06131a;stroke-width:4px}
.table-wrap{overflow:auto;padding:0 14px 14px}table{width:100%;border-collapse:collapse;min-width:900px}table.wide{min-width:1250px}th,td{padding:9px 10px;border-bottom:1px solid rgba(255,255,255,.07);font-size:10px;text-align:left}th{color:var(--muted);text-transform:uppercase;font-size:9px}.summary-strip{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;padding:12px 14px}.summary-strip article{padding:11px;border:1px solid var(--line);border-radius:8px;background:var(--panel2)}.summary-strip span{display:block;color:var(--muted);font-size:9px;text-transform:uppercase}.summary-strip strong{display:block;margin-top:5px}.date-list{display:grid;gap:4px}.date-chip{width:max-content;padding:4px 7px;border-radius:999px;background:rgba(34,169,240,.12);color:#9edcff;font-size:9px}.finish-chip{background:rgba(255,159,67,.12);color:#ffc084}.toggle{padding:6px 9px;border:1px solid var(--line);border-radius:7px;background:#122c36;color:#fff;font-size:10px;cursor:pointer}.detail-row{display:none}.detail-row.open{display:table-row}.sale-box{margin:8px 0;padding:10px;border:1px solid var(--line);border-radius:8px;background:#081820}.sale-title{display:flex;justify-content:space-between;font-weight:900;margin-bottom:8px}.sale-table{min-width:700px}
footer{text-align:right;margin-top:12px}
@media(max-width:1100px){.filters{grid-template-columns:repeat(3,1fr)}.kpi-grid{grid-template-columns:repeat(2,1fr)}.team-grid{grid-template-columns:repeat(2,1fr)}.charts-grid{grid-template-columns:1fr}.map-layout{grid-template-columns:1fr}.map-detail{order:-1}}
@media(max-width:700px){.header{grid-template-columns:1fr;text-align:center}.brand-logo,.flag-wrap{justify-self:center}.filters,.kpi-grid,.team-grid,.triple-toolbar,.summary-strip{grid-template-columns:1fr}h1{font-size:27px}}

.map-zoom-controls{
  position:absolute;
  top:12px;
  right:12px;
  z-index:20;
  display:grid;
  gap:6px;
}
.map-zoom-controls button{
  width:38px;
  height:38px;
  border:1px solid rgba(255,255,255,.28);
  border-radius:8px;
  background:#0a1d26;
  color:#fff;
  font-size:21px;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 5px 16px rgba(0,0,0,.28);
}
.map-zoom-controls button:hover{background:#17343f}
.department-sellers{
  display:grid;
  gap:8px;
  margin-top:12px;
}
.department-sellers h4{
  margin:0 0 2px;
  color:var(--muted);
  font-size:10px;
  text-transform:uppercase;
}
.department-seller-row{
  padding:8px 9px;
  border:1px solid rgba(255,255,255,.07);
  border-radius:8px;
  background:#091a22;
}
.department-seller-row span{
  display:block;
  color:#fff;
  font-size:10px;
  font-weight:800;
}
.department-seller-row strong{
  display:block;
  margin-top:3px;
  color:var(--teal);
  font-size:9px;
}
.open-product-button{
  padding:6px 9px;
  border:1px solid var(--line);
  border-radius:7px;
  background:#122c36;
  color:#fff;
  font-size:10px;
  font-weight:800;
  cursor:pointer;
}
.open-product-detail{display:none}
.open-product-detail.open{display:table-row}
.open-product-cell{
  padding:0 12px 12px!important;
  background:rgba(255,255,255,.015);
}
.open-product-table{
  width:100%;
  min-width:720px;
  border-collapse:collapse;
  background:#091a22;
  border-radius:8px;
}
.open-product-table th,
.open-product-table td{
  padding:8px 10px;
  border-bottom:1px solid rgba(255,255,255,.06);
  font-size:10px;
}

.map-label-group{pointer-events:none}
.map-department-name{
  font-size:8px;
  font-weight:900;
}
.map-department-value{
  font-size:9px;
  font-weight:900;
  fill:#fff;
}
.cost-source{
  margin-top:2px;
  color:var(--muted);
  font-size:8px;
  font-weight:600;
}

#pendingTable td:nth-child(2){
  color:var(--teal);
  font-weight:800;
  line-height:1.5;
}
