:root{
  --bg:#0b1220;
  --panel:#0f1a2e;
  --panel2:#0b1426;
  --card:#ffffff;
  --muted:#64748b;
  --text:#0b1220;
  --line:#e5e7eb;

  --blue:#2563eb;
  --blue2:#1d4ed8;
  --danger:#ef4444;

  --shadow: 0 20px 50px rgba(2,6,23,.25);
  --shadow2: 0 10px 30px rgba(2,6,23,.18);
  --radius: 18px;
  --radius2: 14px;
  --radius3: 12px;

  --sidebarW: 280px;
  --topbarH: 84px;
  --gap: 22px;

  /* ✅ Fonte moderna e consistente (Inter) */
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:var(--font);
  background: #0b1220;
  color: #0b1220;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ---- APP LAYOUT ---- */
.app{
  min-height:100vh;
  display:grid;
  grid-template-columns: var(--sidebarW) 1fr;
  background:
    radial-gradient(1200px 700px at 15% 15%, rgba(37,99,235,.18), transparent 60%),
    radial-gradient(900px 600px at 90% 20%, rgba(29,78,216,.14), transparent 60%),
    linear-gradient(180deg, #0b1220, #070b14 70%);
}

.sidebar{
  position:sticky;
  top:0;
  height:100vh;
  padding:26px 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,0) 35%),
    linear-gradient(180deg, #0f1a2e, #0b1426 70%, #08101f);
  border-right: 1px solid rgba(148,163,184,.12);
}

.sidebar__brand{
  display:flex;
  align-items:center;
  gap:12px;
  padding:8px 10px 18px;
}
.sidebar__logo{
  width:44px;height:44px;
  border-radius:14px;
  background: rgba(37,99,235,.18);
  border: 1px solid rgba(37,99,235,.35);
  display:grid;
  place-items:center;
  box-shadow: 0 10px 25px rgba(37,99,235,.18);
}
.sidebar__logo img{width:26px;height:26px; display:block; opacity:.95}
.sidebar__title{
  display:flex;
  flex-direction:column;
  line-height:1.1;
}
.sidebar__title strong{
  color:#eaf1ff;
  font-size:16px;
  letter-spacing:.1px;
  font-weight: 700;
}
.sidebar__title span{
  color: rgba(234,241,255,.65);
  font-size:12px;
  margin-top:3px;
}

.sidebar__nav{
  margin-top:10px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

.navBtn{
  cursor:pointer;
  width:100%;
  border:1px solid rgba(148,163,184,.12);
  background:
    linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.02));
  color:#eaf1ff;
  padding:14px 14px;
  border-radius:16px;
  font-weight:600;
  text-align:left;
  box-shadow: 0 10px 30px rgba(2,6,23,.22);
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
  position:relative;
}
.navBtn:hover{
  transform: translateY(-1px);
  border-color: rgba(37,99,235,.35);
}
.navBtn.is-active{
  background:
    radial-gradient(500px 120px at 30% 0%, rgba(37,99,235,.35), transparent 60%),
    linear-gradient(180deg, rgba(37,99,235,.20), rgba(255,255,255,.02));
  border-color: rgba(37,99,235,.50);
}

.sidebar__footer{
  position:absolute;
  left:18px;
  right:18px;
  bottom:18px;
}

/* ✅ Status profissional */
.pillStatus{
  display:flex;
  gap:10px;
  align-items:center;
  padding:10px 12px;
  border-radius:16px;
  border:1px solid rgba(148,163,184,.12);
  background: rgba(255,255,255,.06);
  color:#eaf1ff;
}
.pillStatus__txt{min-width:0}
.pillStatus small{
  display:block;
  color: rgba(234,241,255,.65);
  margin-top:2px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  max-width: 220px;
}

.pillDot{
  width:10px;height:10px;border-radius:50%;
  background:#f59e0b;
  box-shadow: 0 0 0 4px rgba(245,158,11,.18);
}

.pillDot--ok{
  background:#22c55e;
  box-shadow: 0 0 0 4px rgba(34,197,94,.18);
}
.pillDot--bad{
  background:#f59e0b;
  box-shadow: 0 0 0 4px rgba(245,158,11,.18);
}

.pillStatus.is-ok{
  border-color: rgba(34,197,94,.25);
  background: rgba(34,197,94,.10);
}
.pillStatus.is-bad{
  border-color: rgba(245,158,11,.22);
  background: rgba(255,255,255,.06);
}

/* ---- CONTENT ---- */
.main{
  min-height:100vh;
  padding: 0;
}
.topbar{
  height: var(--topbarH);
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 0 var(--gap);
  position:sticky;
  top:0;
  z-index:5;
  background: rgba(245,246,248,.82);
  backdrop-filter: blur(10px);
  border-bottom:1px solid rgba(148,163,184,.22);
}
.topbar__left{
  display:flex;
  flex-direction:column;
  gap:4px;
}
.kicker{
  font-size:12px;
  color: #64748b;
  letter-spacing:.2px;
  text-transform: none;
  font-weight: 600;
}
#pageTitle{
  margin:0;
  font-size:28px;
  letter-spacing:-.4px;
  font-weight: 800;
}
.topbar__actions{
  display:flex;
  align-items:center;
  gap:10px;
}

.content{
  padding: var(--gap);
  background: #f5f6f8;
  min-height: calc(100vh - var(--topbarH));
}

/* ---- BUTTONS ---- */
.btn{
  cursor:pointer;
  border:1px solid rgba(2,6,23,.12);
  background: white;
  color: #0b1220;
  padding: 11px 14px;
  border-radius: 14px;
  font-weight:600;
  box-shadow: 0 12px 25px rgba(2,6,23,.12);
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease, background .12s ease;
}
.btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 18px 30px rgba(2,6,23,.16);
  border-color: rgba(37,99,235,.25);
}
.btn--primary{
  border-color: rgba(37,99,235,.35);
  background: linear-gradient(180deg, rgba(37,99,235,.95), rgba(29,78,216,.95));
  color: white;
  box-shadow: 0 18px 40px rgba(37,99,235,.24);
  font-weight: 700;
}
.btn--primary:hover{
  box-shadow: 0 26px 50px rgba(37,99,235,.28);
}
.btn--danger{
  border-color: rgba(239,68,68,.35);
  background: linear-gradient(180deg, rgba(239,68,68,.95), rgba(220,38,38,.95));
  color:#fff;
  font-weight: 700;
}
.iconBtn{
  cursor:pointer;
  width:40px;height:40px;
  border-radius: 14px;
  border:1px solid rgba(2,6,23,.10);
  background:#fff;
  box-shadow: 0 10px 25px rgba(2,6,23,.12);
}

/* ---- TABLES ---- */
.tableWrap{
  margin-top:14px;
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 20px;
  overflow:hidden;
  box-shadow: var(--shadow2);
}
.tableTop{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:14px 14px;
  border-bottom:1px solid rgba(148,163,184,.20);
  background: linear-gradient(180deg, rgba(2,6,23,.02), transparent);
}
.tableTop h3{
  margin:0;
  font-size:16px;
  font-weight: 700;
}
.tableTop .actions{
  display:flex;
  gap:10px;
  align-items:center;
}

.table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
}
.table th, .table td{
  padding: 12px 14px;
  border-bottom: 1px solid rgba(148,163,184,.18);
  text-align:left;
  font-size: 13px;
}
.table th{
  color:#475569;
  font-size:12px;
  letter-spacing:.2px;
  text-transform:none;
  background: rgba(2,6,23,.02);
  font-weight: 700;
}
.table tr:hover td{
  background: rgba(37,99,235,.03);
}

/* ✅ Cabeçalho clicável (ordenar) */
.thSortable{
  cursor:pointer;
  user-select:none;
}
.thSortable:hover{
  background: rgba(37,99,235,.06);
}
.thSort{
  margin-left:8px;
  font-weight:800;
  color:#94a3b8;
}
.thSort.is-on{
  color:#1d4ed8;
}

/* ---- AUTH GATE (LOGIN) ---- */
.authGate{
  position:fixed;
  inset:0;
  display:none;
  align-items:center;
  justify-content:center;
  background: rgba(2,6,23,.55);
  backdrop-filter: blur(10px);
  z-index:50;
}
.authGate.is-visible{display:flex}
.authCard{
  width:min(460px, calc(100vw - 26px));
  background: linear-gradient(180deg, rgba(15,26,46,.98), rgba(11,20,38,.98));
  border:1px solid rgba(148,163,184,.20);
  border-radius: 22px;
  padding: 22px;
  box-shadow: var(--shadow);
  color:#eaf1ff;
}
.authCard h3{margin:0 0 6px; font-size:22px; font-weight: 800}
.authCard p{margin:0 0 14px; color: rgba(234,241,255,.70); font-size:13px}
.authCard label{display:block; margin-top:10px; font-size:12px; color: rgba(234,241,255,.72); font-weight: 600}
.authCard input{
  width:100%;
  margin-top:6px;
  padding:12px 12px;
  border-radius: 14px;
  border:1px solid rgba(148,163,184,.22);
  background: rgba(255,255,255,.06);
  color:#fff;
  outline:none;
}
.authCard input:focus{
  border-color: rgba(37,99,235,.65);
  box-shadow: 0 0 0 4px rgba(37,99,235,.18);
}
.authActions{
  display:flex;
  gap:10px;
  margin-top:14px;
}
.authActions .btn{flex:1}
.muted{color:var(--muted)}
.authCard .muted{color: rgba(234,241,255,.60); margin-top:10px; display:block}

/* ---- MODAL ---- */
.modal{
  position:fixed;
  inset:0;
  display:none;
  z-index:60;
}
.modal.is-open{display:block}

.modal__backdrop{
  position:absolute;
  inset:0;
  background: rgba(2,6,23,.55);
  backdrop-filter: blur(10px);
}

.modal__panel{
  position:absolute;
  left:50%;
  top:70px;
  transform: translateX(-50%);
  width:min(720px, calc(100vw - 26px));
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 22px;
  box-shadow: var(--shadow);
  overflow:hidden;
  max-height: calc(100vh - 140px);
  display:flex;
  flex-direction:column;
}
.modal__panel--xl{
  width:min(980px, calc(100vw - 26px));
}

.modal__header{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:16px 18px;
  border-bottom:1px solid rgba(148,163,184,.20);
  background: radial-gradient(900px 160px at 10% 0%, rgba(37,99,235,.12), transparent 60%);
}
.modal__kicker{font-size:12px; color:#64748b; margin-bottom:4px; font-weight: 600}
.modal__title{margin:0; font-size:18px; font-weight: 800}

.formGrid{
  padding:18px;
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
}

.field label{display:block; font-size:12px; color:#64748b; margin-bottom:6px; font-weight:700}
.field input{
  width:100%;
  padding:12px 12px;
  border-radius: 14px;
  border:1px solid rgba(148,163,184,.30);
  outline:none;
}
.field input:focus{
  border-color: rgba(37,99,235,.55);
  box-shadow: 0 0 0 4px rgba(37,99,235,.12);
}
.field--full{grid-column:1 / -1}

.segmented{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.segmented__item{
  flex:1;
  min-width: 160px;
  border:1px solid rgba(148,163,184,.30);
  border-radius: 14px;
  padding:10px 10px;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:700;
  color:#0b1220;
  background: rgba(2,6,23,.02);
}
.segmented__item input{display:none}
.segmented__item:has(input:checked){
  border-color: rgba(37,99,235,.55);
  background: rgba(37,99,235,.08);
}

.modal__footer{
  grid-column:1 / -1;
  display:flex;
  align-items:center;
  gap:10px;
  padding-top:6px;
}
.spacer{flex:1}

/* ---- PAGES VISIBILITY (router) ---- */
.page{display:none}
.page.is-visible{display:block}

/* ---- RESPONSIVE ---- */
@media (max-width: 980px){
  :root{ --sidebarW: 240px; }
}
@media (max-width: 760px){
  .app{grid-template-columns: 1fr}
  .sidebar{ position:relative; height:auto; }
  .sidebar__footer{ position:relative; left:auto; right:auto; bottom:auto; margin-top:12px}
  .topbar{ position:relative }
  .formGrid{ grid-template-columns: 1fr }
  .modal__panel{ top:18px; max-height: calc(100vh - 36px); }
}

/* ---- SEARCH ---- */
.tableTop .searchWrap{
  display:flex;
  gap:10px;
  align-items:center;
}
.searchInput{
  width:min(360px, 52vw);
  padding:10px 12px;
  border-radius:14px;
  border:1px solid rgba(148,163,184,.30);
  outline:none;
  background:#fff;
  font-weight: 500;
}
.searchInput:focus{
  border-color: rgba(37,99,235,.55);
  box-shadow: 0 0 0 4px rgba(37,99,235,.12);
}

/* remove setinhas nativas estranhas */
input::-webkit-calendar-picker-indicator{
  opacity: 0;
  display: none;
}
input::-webkit-inner-spin-button,
input::-webkit-outer-spin-button{
  -webkit-appearance: none;
  margin: 0;
}

/* ---- AUTOCOMPLETE (UPN) - CUSTOM ---- */
.ac{ position: relative; }

.ac__input{
  width: 100%;
  padding: 12px 44px 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(148,163,184,.30);
  outline: none;
  background: #fff;
  box-shadow: 0 10px 22px rgba(2,6,23,.08);
  transition: border-color .12s ease, box-shadow .12s ease;
  font-weight: 500;
}
.ac__input:focus{
  border-color: rgba(37,99,235,.55);
  box-shadow: 0 0 0 4px rgba(37,99,235,.12), 0 14px 24px rgba(2,6,23,.12);
}

.ac__btn{
  position:absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 10px;
  display:grid;
  place-items:center;
  font-weight: 800;
  color:#1d4ed8;
  background: rgba(37,99,235,.10);
  border: 1px solid rgba(37,99,235,.20);
  cursor:pointer;
}
.ac__btn:hover{
  background: rgba(37,99,235,.14);
}

.ac__panel{
  position:absolute;
  left:0;
  right:0;
  top: calc(100% + 8px);
  z-index: 9999;
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 16px;
  box-shadow: 0 22px 55px rgba(2,6,23,.25);
  overflow:hidden;
  display:none;
}
.ac.is-open .ac__panel{ display:block; }

.ac__head{
  padding: 10px 12px;
  border-bottom:1px solid rgba(148,163,184,.18);
  background: linear-gradient(180deg, rgba(2,6,23,.02), transparent);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.ac__head small{
  color:#64748b;
  font-weight:700;
}

.ac__list{
  max-height: 260px;
  overflow:auto;
}
.ac__item{
  padding: 10px 12px;
  display:flex;
  flex-direction:column;
  gap:2px;
  cursor:pointer;
}
.ac__item strong{
  font-size: 13px;
  color:#0b1220;
  font-weight: 700;
}
.ac__item span{
  font-size: 12px;
  color:#64748b;
}
.ac__item:hover{
  background: rgba(37,99,235,.06);
}
.ac__empty{
  padding: 12px;
  color:#64748b;
  font-size: 13px;
}

#modalPerif .modal__panel { overflow: visible; }
#modalPerif .formGrid { position: relative; }
#acUpnPerif .ac__input { caret-color: #1d4ed8; }

.autofillTrap{
  position: fixed !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

input:-webkit-autofill{
  -webkit-box-shadow: 0 0 0px 1000px #fff inset;
  -webkit-text-fill-color: #0b1220;
  transition: background-color 999999s ease-in-out 0s;
}

input, button, textarea, select{
  outline: none;
}
input:focus-visible, button:focus-visible, textarea:focus-visible, select:focus-visible{
  outline: none;
}

/* ✅ MODAL COMPUTADOR (DETALHES) */
.deviceBody{
  padding:18px;
  overflow:auto;
}

.deviceGrid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
}
@media (max-width: 760px){
  .deviceGrid{ grid-template-columns: 1fr; }
}

.deviceCard{
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 18px;
  box-shadow: var(--shadow2);
  overflow:hidden;
}
.deviceCard__head{
  padding:12px 14px;
  border-bottom:1px solid rgba(148,163,184,.18);
  background: linear-gradient(180deg, rgba(2,6,23,.02), transparent);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.deviceCard__head strong{
  font-size:12px;
  letter-spacing:.2px;
  color:#475569;
  font-weight: 700;
}
.deviceCard__body{
  padding: 12px 14px;
}

.kv{
  display:grid;
  grid-template-columns: 160px 1fr;
  gap:10px;
  padding:8px 0;
  border-bottom:1px solid rgba(148,163,184,.14);
}
.kv:last-child{border-bottom:0}
.kv .k{
  font-size:12px;
  color:#64748b;
  font-weight:700;
}
.kv .v{
  font-size:13px;
  color:#0b1220;
  word-break: break-word;
}

.badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid rgba(148,163,184,.25);
  background: rgba(2,6,23,.02);
  font-size:12px;
  font-weight:700;
  color:#0b1220;
}
.badge--ok{
  border-color: rgba(34,197,94,.28);
  background: rgba(34,197,94,.10);
}
.badge--warn{
  border-color: rgba(245,158,11,.28);
  background: rgba(245,158,11,.12);
}
.badge--bad{
  border-color: rgba(239,68,68,.28);
  background: rgba(239,68,68,.10);
}

.miniBtn{
  cursor:pointer;
  border:1px solid rgba(2,6,23,.12);
  background:#fff;
  color:#0b1220;
  padding:6px 10px;
  border-radius: 12px;
  font-weight:700;
  font-size:12px;
  box-shadow: 0 10px 20px rgba(2,6,23,.10);
}
.miniBtn:hover{
  border-color: rgba(37,99,235,.30);
  transform: translateY(-1px);
}
.codeBox{
  width:100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size:12px;
  padding:12px;
  border-radius: 16px;
  border:1px solid rgba(148,163,184,.25);
  background: rgba(2,6,23,.02);
  white-space: pre;
  overflow:auto;
}

/* ✅ DASHBOARD NOVO */
.dashGrid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:14px;
}
@media (max-width: 980px){
  .dashGrid{ grid-template-columns: 1fr; }
}
.dashCard{
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 20px;
  box-shadow: var(--shadow2);
  padding:16px;
  overflow:hidden;
  position:relative;
}
.dashCard::before{
  content:"";
  position:absolute;
  inset:-1px;
  background: radial-gradient(900px 240px at 10% 0%, rgba(37,99,235,.14), transparent 60%);
  pointer-events:none;
}
.dashCard--wide{
  grid-column: 1 / -1;
}
.dashCard__head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  position:relative;
  z-index:1;
}
.dashKicker{
  font-size:12px;
  color:#64748b;
  font-weight:700;
}
.dashTitle{
  margin:4px 0 0;
  font-size:18px;
  letter-spacing:-.2px;
  font-weight: 800;
}
.dashBig{
  font-size:34px;
  font-weight:800;
  letter-spacing:-.6px;
}
.dashSplit{
  display:grid;
  grid-template-columns: repeat(3, minmax(140px, 1fr));
  gap:10px;
  margin-top:12px;
  position:relative;
  z-index:1;
}
@media (max-width: 760px){
  .dashSplit{ grid-template-columns: 1fr; }
}
.dashChip{
  border:1px solid rgba(148,163,184,.22);
  border-radius: 16px;
  padding:10px 12px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  background: rgba(2,6,23,.02);
}
.dashChip span{ color:#475569; font-weight:700; font-size:12px; }
.dashChip b{ font-size:16px; font-weight: 800; }
.dashChip--ok{
  border-color: rgba(34,197,94,.25);
  background: rgba(34,197,94,.08);
}
.dashChip--warn{
  border-color: rgba(245,158,11,.22);
  background: rgba(245,158,11,.08);
}

.dashNote{
  margin-top:10px;
  color:#64748b;
  font-size:12px;
  position:relative;
  z-index:1;
}

.dashRight{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.dashMini{
  border:1px solid rgba(148,163,184,.22);
  border-radius: 14px;
  padding:8px 10px;
  background: rgba(2,6,23,.02);
  min-width: 140px;
}
.dashMini__k{
  font-size:11px;
  color:#64748b;
  font-weight:700;
}
.dashMini__v{
  font-size:16px;
  font-weight:800;
  margin-top:4px;
}

.dashGrowth{
  margin-top:12px;
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:12px;
  position:relative;
  z-index:1;
}
@media (max-width: 980px){
  .dashGrowth{ grid-template-columns: 1fr; }
}
.dashGrowthCol{
  border:1px solid rgba(148,163,184,.22);
  border-radius: 18px;
  padding:12px;
  background: #fff;
}
.dashGrowthTitle{
  font-size:12px;
  font-weight:800;
  color:#475569;
  margin-bottom:8px;
}

.miniBars{
  display:flex;
  flex-direction:column;
  gap:10px;
}
.miniBarRow{
  display:grid;
  grid-template-columns: 110px 1fr 44px;
  gap:10px;
  align-items:center;
}
.miniBarLabel{
  font-size:12px;
  color:#475569;
  font-weight:700;
}
.miniBar{
  height:10px;
  border-radius:999px;
  background: rgba(2,6,23,.06);
  overflow:hidden;
  border:1px solid rgba(148,163,184,.18);
}
.miniBar i{
  display:block;
  height:100%;
  background: linear-gradient(90deg, rgba(37,99,235,.85), rgba(29,78,216,.85));
  border-radius:999px;
}
.miniBarVal{
  text-align:right;
  font-size:12px;
  color:#0b1220;
  font-weight:800;
}

/* ✅ Dashboard chart (mês a mês) */
.dashChartControls{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  align-items:flex-end;
}
.dashCtl{
  border:1px solid rgba(148,163,184,.22);
  border-radius: 14px;
  padding:8px 10px;
  background: rgba(2,6,23,.02);
}
.dashCtl.is-disabled{
  opacity:.55;
}
.dashCtl label{
  display:block;
  font-size:11px;
  color:#64748b;
  font-weight:700;
  margin-bottom:6px;
}
.dashCtl select{
  border:1px solid rgba(148,163,184,.30);
  border-radius: 12px;
  padding:8px 10px;
  background:#fff;
  font-weight:600;
  color:#0b1220;
  min-width: 180px;
}
.dashCtl--range{
  min-width: 220px;
}
.dashRangePills{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.rangePill{
  border:1px solid rgba(148,163,184,.22);
  background:#fff;
  border-radius: 999px;
  padding:6px 10px;
  font-size:12px;
  color:#0b1220;
  font-weight:600;
}
.dashCtl--metric{
  min-width: 160px;
}
.dashMetric{
  font-size:18px;
  font-weight:800;
  color:#0b1220;
}

.dashChartArea{
  margin-top:12px;
  position:relative;
  z-index:1;
}
.dashChartHint{
  font-size:12px;
  color:#64748b;
  margin-bottom:10px;
}

.dashBars{
  display:grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap:8px;
  align-items:end;
}
@media (max-width: 980px){
  .dashBars{ grid-template-columns: repeat(6, minmax(0, 1fr)); }
}
@media (max-width: 560px){
  .dashBars{ grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.dashBar{
  border:1px solid rgba(148,163,184,.22);
  background: rgba(2,6,23,.02);
  border-radius: 14px;
  padding:10px 8px;
  cursor:pointer;
  display:flex;
  flex-direction:column;
  justify-content:flex-end;
  gap:8px;
  height: 170px;
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}
.dashBar:hover{
  transform: translateY(-1px);
  border-color: rgba(37,99,235,.35);
}
.dashBar i{
  display:block;
  width:100%;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(37,99,235,.85), rgba(29,78,216,.85));
  min-height: 2px;
}
.dashBar span{
  font-size:11px;
  color:#475569;
  font-weight:700;
  text-align:center;
  white-space:nowrap;
}
.dashBar.is-selected{
  border-color: rgba(37,99,235,.45);
  background: rgba(37,99,235,.06);
}
.dashBar.is-edge{
  border-color: rgba(37,99,235,.65);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}

/* ✅ Usuários (cards + filtros) */
.usersMeta{
  display:flex;
  gap:10px;
  padding:12px 14px;
  border-bottom:1px solid rgba(148,163,184,.18);
  flex-wrap:wrap;
}
.pillCount{
  border:1px solid rgba(148,163,184,.22);
  background: rgba(2,6,23,.02);
  border-radius:999px;
  padding:8px 12px;
  font-size:12px;
  color:#0b1220;
  font-weight:700;
}
.pillCount--ok{
  border-color: rgba(34,197,94,.25);
  background: rgba(34,197,94,.08);
}
.pillCount--warn{
  border-color: rgba(245,158,11,.22);
  background: rgba(245,158,11,.08);
}

.chk{
  display:flex;
  align-items:center;
  gap:8px;
  border:1px solid rgba(148,163,184,.22);
  background:#fff;
  border-radius: 14px;
  padding:10px 12px;
  font-weight:600;
  color:#0b1220;
}
.chk input{ transform: translateY(1px); }

.userCard{
  border:1px solid rgba(148,163,184,.20);
  border-radius:18px;
  padding:14px;
  margin-bottom:12px;
  background:#fff;
}
.userCard__top{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
}
.userName{
  font-weight:800;
  font-size:16px;
}
.userCard__grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:10px;
}
@media (max-width: 760px){
  .userCard__grid{ grid-template-columns:1fr; }
}
.userCard__k{
  font-weight:800;
  font-size:12px;
  color:#475569;
  margin-bottom:6px;
}

/* =========================
   ✅ GEO (Lista + Mapa)
   ========================= */
.geoLayout{
  display:grid;
  grid-template-columns: 420px 1fr;
  gap:14px;
  height: calc(100vh - var(--topbarH) - (var(--gap) * 2));
  min-height: 520px;
}

@media (max-width: 1100px){
  .geoLayout{ grid-template-columns: 1fr; height:auto; }
}

.geoPanel{
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 20px;
  box-shadow: var(--shadow2);
  overflow:hidden;
  display:flex;
  flex-direction:column;
}

.geoPanel__head{
  padding:14px 14px;
  border-bottom:1px solid rgba(148,163,184,.20);
  background: linear-gradient(180deg, rgba(2,6,23,.02), transparent);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}

.geoPanel__head h3{
  margin:0;
  font-size:16px;
}

.geoPanel__tools{
  padding:12px 14px;
  border-bottom:1px solid rgba(148,163,184,.18);
  display:flex;
  gap:10px;
  align-items:center;
}

.geoPanel__tools .searchInput{
  width:100%;
}

.geoList{
  padding: 10px 10px 12px;
  overflow:auto;
  flex:1;
}

.geoItem{
  border:1px solid rgba(148,163,184,.18);
  border-radius: 16px;
  padding:12px 12px;
  margin-bottom:10px;
  cursor:pointer;
  background:#fff;
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
}

.geoItem:hover{
  transform: translateY(-1px);
  border-color: rgba(37,99,235,.25);
  background: rgba(37,99,235,.03);
}

.geoItem.is-active{
  border-color: rgba(37,99,235,.45);
  background: rgba(37,99,235,.06);
  box-shadow: 0 0 0 3px rgba(37,99,235,.10);
}

.geoItem__top{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
}

.geoName{
  font-weight:950;
  font-size:14px;
  color:#0b1220;
}

.geoMeta{
  margin-top:6px;
  font-size:12px;
  color:#64748b;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.geoBadge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid rgba(148,163,184,.22);
  background: rgba(2,6,23,.02);
  font-size:12px;
  font-weight:900;
  color:#0b1220;
}

.geoBadge--ok{
  border-color: rgba(34,197,94,.25);
  background: rgba(34,197,94,.08);
}

.geoBadge--warn{
  border-color: rgba(245,158,11,.22);
  background: rgba(245,158,11,.08);
}

.geoMapWrap{
  background:#fff;
  border:1px solid rgba(148,163,184,.25);
  border-radius: 20px;
  box-shadow: var(--shadow2);
  overflow:hidden;
  display:flex;
  flex-direction:column;
}

.geoMapHead{
  padding:14px 14px;
  border-bottom:1px solid rgba(148,163,184,.20);
  background: radial-gradient(900px 160px at 10% 0%, rgba(37,99,235,.10), transparent 60%);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}

.geoMapHead .muted{ font-size:12px; }

#geoMap{
  width:100%;
  height:100%;
  min-height: 520px;
}

@media (max-width: 1100px){
  #geoMap{ min-height: 420px; }
}

.leaflet-container{
  font-family: var(--font);
}

.geoItem.is-selected {
  outline: 2px solid rgba(255,255,255,.18);
}


/* GEO MAP (Leaflet) */
.geoMap {
  height: 420px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.10);
  background: #111;
}
.geoMapWrap{
  margin: 12px 0 16px;
}
.geoMapMeta{
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  margin: 10px 0 6px;
}
.geoMapMeta .muted{ font-size: 12px; }

.geoTop{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  margin-bottom:12px;
}

.geoTop__actions{
  display:flex;
  align-items:center;
  gap:12px;
}

.geoSplit{
  display:grid;
  grid-template-columns: 380px 1fr;
  gap:14px;
  align-items:stretch;
}

.geoLeft, .geoRight{
  background:#fff;
  border-radius:14px;
  box-shadow: 0 10px 24px rgba(0,0,0,.08);
  overflow:hidden;
  border:1px solid rgba(0,0,0,.06);
}

.geoLeft__head, .geoRight__head{
  padding:12px 14px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-bottom:1px solid rgba(0,0,0,.06);
}

.geoLeft__list{
  max-height: 620px;
  overflow:auto;
}

.geoItem{
  padding:12px 14px;
  border-bottom:1px solid rgba(0,0,0,.06);
  cursor:pointer;
}
.geoItem:hover{ background: rgba(0,0,0,.03); }

.geoItem__title{
  font-weight:800;
}
.geoItem__meta{
  margin-top:6px;
  font-size:12px;
  color:#666;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.geoMap{
  height: 680px;
  width: 100%;
}
