:root {
  --bg: #0b1120; --lat: #0e1526; --card: #151d2e; --card2: #1b2537; --campo: #212c40;
  --borda: #26324a; --txt: #e7ecf5; --sub: #8e9ab0; --fraco: #5d6a82;
  --borda-card: #18213a; --trilho: #26324a; --borda-forte: #3a4a6a; --rolagem: #33405c; --linha: #222c44; --txt2: #d5dbe8; --linha-tab: #1f2840; --dica: #0b1120f2;
  --verde: #34d399; --verde2: #10b981; --azul: #38bdf8; --azul2: #0ea5e9; --amarelo: #fbbf24;
  --vermelho: #f87171; --roxo: #a78bfa; --rosa: #e0457b;
  --marca: #006990; /* azul Uniconnect */
  --raio: 14px; --fonte: "Segoe UI", "Noto Sans", Inter, system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "JetBrains Mono", Consolas, monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--txt); font: 14px/1.45 var(--fonte); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.hidden { display: none !important; }
.mono { font-family: var(--mono); font-size: 13px; }
.sub { color: var(--sub); }
.fraco { color: var(--fraco); }
.ok { color: var(--verde); } .alerta { color: var(--amarelo); } .ruim { color: var(--vermelho); } .info { color: var(--azul); }

/* ---------- layout ---------- */
#app { display: grid; grid-template-columns: 64px 1fr; grid-template-rows: 56px 1fr; height: 100vh; }
.lateral { grid-row: 1 / 3; background: var(--lat); display: flex; flex-direction: column; align-items: center; padding: 8px 0; gap: 6px; border-right: 1px solid var(--borda-card); }
.logo { width: 42px; height: 42px; border-radius: 11px; background: var(--marca); display: grid; place-items: center; margin-bottom: 18px; box-shadow: 0 0 0 1px #ffffff14; }
.logo img { width: 30px; height: 30px; object-fit: contain; }
.logo-login { display: block; width: 230px; max-width: 100%; margin: 0 0 26px; }
.logo.grande { width: 64px; height: 64px; font-size: 18px; border-radius: 16px; margin: 0 auto 14px; }
#menu { display: flex; flex-direction: column; gap: 6px; }
#menu a, .sair { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; color: var(--sub); position: relative; }
#menu a:hover, .sair:hover { background: var(--card); color: var(--txt); }
#menu a.ativo { background: var(--card2); color: var(--txt); }
#menu a.ativo::before { content: ""; position: absolute; left: -10px; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--azul); }
#menu a .bolinha { position: absolute; top: 6px; right: 6px; min-width: 16px; height: 16px; border-radius: 8px; background: var(--amarelo); color: #111; font-size: 10px; font-weight: 700; display: grid; place-items: center; padding: 0 4px; }
#menu a[data-dica]:hover::after { content: attr(data-dica); position: absolute; left: 54px; white-space: nowrap; background: #000c; padding: 4px 10px; border-radius: 6px; font-size: 12px; color: #fff; z-index: 50; }
.sair { margin-top: auto; }
.topo { display: flex; align-items: center; gap: 16px; padding: 0 20px; background: var(--bg); }
.trilha { flex: 1; font-size: 13px; color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trilha b { color: var(--txt); font-weight: 600; }
.busca { flex: 0 1 480px; display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border-radius: 18px; border: 1px solid var(--borda); background: #0f1728; color: var(--sub); }
.busca input { flex: 1; background: none; border: 0; outline: 0; }
kbd { font-size: 11px; border: 1px solid var(--borda); border-radius: 5px; padding: 1px 6px; color: var(--sub); font-family: var(--fonte); }
.topo-dir { flex: 1; display: flex; justify-content: flex-end; align-items: center; gap: 10px; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--verde2); color: #062; font-weight: 700; display: grid; place-items: center; text-transform: uppercase; }
.chip { font-size: 12px; padding: 5px 12px; border-radius: 16px; border: 1px solid var(--borda); background: var(--card); display: inline-flex; align-items: center; gap: 6px; cursor: pointer; white-space: nowrap; }
main { overflow: auto; padding: 4px 20px 30px; background: #0d1424; border-top-left-radius: 18px; }

/* ---------- cards ---------- */
.grade { display: grid; gap: 14px; margin-top: 14px; }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { background: var(--card); border-radius: var(--raio); padding: 18px 20px; min-width: 0; border: 1px solid var(--borda-card); }
.card h3 { margin: 0 0 14px; font-size: 16px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.card h3 .acao-dir { margin-left: auto; }
.card.destaque { background: linear-gradient(140deg, #1d1b45 0%, #261a4a 55%, #2b1440 100%); border-color: #4b3a8a; }
.titulo-pag { display: flex; align-items: flex-end; gap: 12px; margin: 14px 0 4px; }
.titulo-pag h1 { margin: 0; font-size: 22px; font-weight: 700; }
.titulo-pag p { margin: 2px 0 0; color: var(--sub); }
.titulo-pag .dir { margin-left: auto; display: flex; gap: 8px; }
.numero { font-size: 44px; font-weight: 700; letter-spacing: -1px; line-height: 1; }
.numero small { font-size: 18px; font-weight: 600; margin-left: 2px; }
.legenda { color: var(--sub); font-size: 13px; margin-top: 6px; }
.par-num { display: flex; justify-content: space-around; text-align: center; margin: 6px 0 18px; }
.ponto { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--fraco); margin-right: 6px; vertical-align: middle; }
.ponto.on { background: var(--verde); box-shadow: 0 0 0 3px #34d39922; }
.barra { height: 10px; border-radius: 6px; background: var(--trilho); overflow: hidden; }
.barra > i { display: block; height: 100%; border-radius: 6px; background: var(--verde); }
.barra.azul > i { background: var(--azul2); }
.colunas { display: flex; align-items: flex-end; gap: 5px; height: 72px; }
.colunas > i { flex: 1; border-radius: 4px; background: var(--verde); min-height: 3px; position: relative; }
.colunas > i.vazio { background: var(--trilho); }
.colunas > i:hover::after { content: attr(data-t); position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); background: #000c; padding: 2px 8px; border-radius: 4px; font-size: 11px; white-space: nowrap; margin-bottom: 4px; z-index: 5; }
.eixo { display: flex; gap: 5px; font-size: 11px; color: var(--fraco); margin-top: 6px; }
.eixo > span { flex: 1; text-align: center; }
.aviso { display: flex; gap: 10px; align-items: center; border: 1px solid var(--amarelo); border-radius: 12px; padding: 10px 14px; font-weight: 600; font-size: 13px; cursor: pointer; }
.aviso.verde { border-color: transparent; background: var(--card2); font-weight: 500; cursor: default; }
.caixa-cinza { background: var(--card2); border-radius: 12px; padding: 16px; }
.hbar { display: grid; grid-template-columns: 1fr; gap: 8px; }
.hbar > div { position: relative; height: 26px; border-radius: 13px; background: var(--card2); overflow: hidden; cursor: pointer; }
.hbar > div > i { position: absolute; inset: 0 auto 0 0; border-radius: 13px; }
.hbar > div > span { position: relative; padding: 0 12px; line-height: 26px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.cores-0 { background: #2f9e6e; } .cores-1 { background: #2a8f5a; } .cores-2 { background: #b02e5a; } .cores-3 { background: #3c8f3c; } .cores-4 { background: #b4a234; } .cores-5 { background: #1b7bb0; }
.lista-ev { display: flex; flex-direction: column; gap: 8px; }
.lista-ev > div { display: flex; gap: 10px; align-items: center; font-size: 13px; padding: 8px 10px; background: var(--card2); border-radius: 10px; }
.lista-ev .quando { margin-left: auto; color: var(--fraco); white-space: nowrap; font-size: 12px; }
.ia-texto { font-size: 14px; line-height: 1.75; }

/* ---------- tabelas ---------- */
.tabela-card { background: var(--card); border-radius: var(--raio); margin-top: 14px; padding: 14px 14px 6px; border: 1px solid var(--borda-card); }
.barra-ferr { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.grupo-busca { display: flex; height: 36px; border-radius: 8px; background: var(--card2); overflow: hidden; }
.grupo-busca select { background: var(--campo); border: 0; padding: 0 12px; outline: 0; }
.grupo-busca input { background: none; border: 0; outline: 0; padding: 0 12px; width: 260px; }
.filtros { display: flex; gap: 6px; flex-wrap: wrap; }
.filtros button { border: 1px solid var(--borda); background: transparent; border-radius: 16px; padding: 5px 12px; font-size: 12.5px; cursor: pointer; color: var(--sub); }
.filtros button.ativo { background: var(--card2); color: var(--txt); border-color: var(--borda-forte); }
.rolagem { overflow: auto; max-height: calc(100vh - 250px); }
table { width: 100%; border-collapse: collapse; }
th { position: sticky; top: 0; background: var(--card); text-align: left; font-weight: 600; padding: 10px 10px; border-bottom: 1px solid var(--borda); white-space: nowrap; z-index: 1; }
td { padding: 9px 10px; border-bottom: 1px solid #1d2740; white-space: nowrap; }
tbody tr { cursor: pointer; }
tbody tr:hover { background: #1a2338; }
td.mono { font-size: 12.5px; }
.paginacao { display: flex; justify-content: space-between; align-items: center; padding: 10px 6px; color: var(--sub); font-size: 13px; }
.paginacao button { margin-left: 6px; }
.etq { display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 10px; background: var(--card2); margin-right: 4px; border: 1px solid var(--borda); }
.etq.amarela { border-color: #fbbf2466; color: var(--amarelo); }
.etq.verde { border-color: #34d39966; color: var(--verde); }
.etq.vermelha { border-color: #f8717166; color: var(--vermelho); }
.etq.azul { border-color: #38bdf866; color: var(--azul); }

/* ---------- botões / formulários ---------- */
.btn { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--borda); background: var(--card2); cursor: pointer; font-weight: 600; font-size: 13px; white-space: nowrap; }
.btn:hover { border-color: #3c4d70; }
.btn svg { width: 16px; height: 16px; }
.btn.primario { background: var(--azul); border-color: var(--azul); color: #04263b; }
.btn.contorno { background: transparent; border-color: var(--azul); color: var(--azul); }
.btn.perigo { background: transparent; border-color: #f8717188; color: var(--vermelho); }
.btn.peq { height: 28px; padding: 0 10px; font-size: 12px; }
.btn.redondo { width: 36px; padding: 0; justify-content: center; }
.btn[disabled] { opacity: .5; cursor: progress; }
label { display: block; font-size: 12.5px; color: var(--sub); margin-bottom: 12px; }
label input, label select, label textarea { display: block; width: 100%; margin-top: 5px; height: 36px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--borda); background: var(--campo); color: var(--txt); outline: 0; }
label textarea { height: auto; padding: 10px 12px; font-family: var(--mono); font-size: 12.5px; }
label input:focus, label select:focus, label textarea:focus { border-color: var(--azul); }
.linha-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.check { display: flex; align-items: center; gap: 8px; color: var(--txt); }
.check input { width: auto; height: auto; margin: 0; }
.dica { font-size: 12.5px; color: var(--sub); background: var(--card2); border-left: 3px solid var(--azul); padding: 10px 12px; border-radius: 6px; margin: 4px 0 14px; }
.dica.amarela { border-color: var(--amarelo); }

/* ---------- dispositivo ---------- */
.cab-disp { background: var(--card); border-radius: var(--raio); padding: 16px 20px 0; margin-top: 12px; border: 1px solid var(--borda-card); }
.cab-disp .linha1 { display: flex; gap: 14px; align-items: center; }
.icone-disp { width: 48px; height: 48px; border-radius: 12px; border: 2px solid var(--verde); display: grid; place-items: center; color: var(--txt); }
.icone-disp.off { border-color: var(--fraco); }
.icone-disp svg { width: 26px; height: 26px; }
.cab-disp h2 { margin: 0; font-size: 17px; display: flex; align-items: center; gap: 6px; }
.metas { display: flex; gap: 16px; flex-wrap: wrap; color: var(--sub); font-size: 12.5px; margin-top: 3px; }
.metas span { display: inline-flex; align-items: center; gap: 4px; }
.metas svg { width: 14px; height: 14px; }
.cab-disp .dir { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.estado { text-align: right; font-size: 12.5px; font-weight: 600; }
.abas { display: flex; gap: 6px; margin-top: 12px; }
.abas a { padding: 10px 14px; font-size: 15px; font-weight: 600; color: var(--sub); border-bottom: 2px solid transparent; }
.abas a.ativa { color: var(--azul); border-color: var(--azul); }
.abas a:hover { color: var(--txt); }
.info-lista { display: flex; flex-direction: column; gap: 8px; }
.info-lista > div { display: flex; gap: 12px; align-items: center; background: var(--card2); border-radius: 10px; padding: 10px 12px; }
.info-lista b { display: block; font-size: 14px; }
.info-lista small { color: var(--sub); font-size: 12px; }
.info-lista svg { color: var(--sub); flex: none; }
.optico { display: flex; align-items: center; justify-content: space-around; gap: 10px; }
.optico .valor { font-size: 30px; font-weight: 700; }
.optico .valor small { font-size: 15px; }
.medidor { width: 120px; height: 8px; border-radius: 4px; background: linear-gradient(90deg, var(--vermelho) 0 25%, var(--amarelo) 25% 45%, var(--verde) 45% 100%); position: relative; margin-top: 8px; }
.medidor i { position: absolute; top: -4px; width: 4px; height: 16px; background: #fff; border-radius: 2px; }
.secao { border-bottom: 1px solid var(--borda); padding: 14px 0; display: flex; gap: 20px; align-items: flex-start; }
.secao:last-child { border-bottom: 0; }
.secao .esq { flex: 1; }
.secao h4 { margin: 0 0 6px; font-size: 14px; }
.lado { display: grid; grid-template-columns: 220px 1fr; gap: 14px; margin-top: 14px; }
.submenu { background: var(--card); border-radius: var(--raio); padding: 10px; display: flex; flex-direction: column; gap: 4px; align-self: start; border: 1px solid var(--borda-card); }
.submenu a { padding: 11px 12px; border-radius: 10px; display: flex; gap: 10px; align-items: center; font-weight: 500; color: var(--sub); }
.submenu a.ativo, .submenu a:hover { background: var(--card2); color: var(--txt); }
.vazio-msg { text-align: center; color: var(--sub); padding: 40px 10px; }
.carregando { display: inline-block; width: 18px; height: 18px; border: 2px solid var(--borda); border-top-color: var(--azul); border-radius: 50%; animation: gira .8s linear infinite; vertical-align: middle; }
@keyframes gira { to { transform: rotate(360deg); } }
.json { white-space: pre-wrap; overflow-wrap: anywhere; font-family: var(--mono); font-size: 12px; color: var(--sub); }

/* ---------- modal / toast / login ---------- */
.modal { position: fixed; inset: 0; background: #020617b3; display: grid; place-items: center; z-index: 100; padding: 20px; }
.modal-caixa { background: var(--card); border: 1px solid var(--borda); border-radius: 16px; padding: 22px 24px; width: min(620px, 100%); max-height: 90vh; overflow: auto; }
.modal-caixa h3 { margin: 0 0 6px; font-size: 18px; }
.modal-caixa .rodape { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }
#toasts { position: fixed; right: 20px; bottom: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 200; }
.toast { background: var(--card2); border: 1px solid var(--borda); border-left: 4px solid var(--verde); padding: 10px 16px; border-radius: 10px; min-width: 260px; max-width: 420px; box-shadow: 0 10px 30px #0008; }
.toast.erro { border-left-color: var(--vermelho); }
.erro { color: var(--vermelho); font-size: 13px; min-height: 18px; margin-bottom: 8px; }
.param-linha { display: grid; grid-template-columns: 1fr 160px 130px 34px; gap: 6px; margin-bottom: 6px; }
.param-linha input, .param-linha select { height: 32px; border-radius: 6px; border: 1px solid var(--borda); background: var(--campo); padding: 0 8px; font-size: 12.5px; outline: 0; min-width: 0; }
@media (max-width: 1200px) { .g3, .g4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 800px) { .g3, .g2, .g4, .lado { grid-template-columns: 1fr; } .busca { display: none; } }

/* ---------- senha com olho ---------- */
.com-olho { position: relative; display: block; margin-top: 5px; }
.com-olho input { margin-top: 0 !important; padding-right: 40px !important; }
.olho { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); background: none; border: 0; color: var(--sub); cursor: pointer; padding: 4px; display: grid; place-items: center; }
.olho.on { color: var(--azul); }
.olho.mini { position: static; transform: none; display: inline-grid; vertical-align: middle; padding: 0 2px; }
.olho.mini svg { width: 16px; height: 16px; }
.senha-oculta { font-family: var(--mono); letter-spacing: 1px; }

/* ---------- sinal Wi-Fi ---------- */
.barras-sinal { display: inline-flex; align-items: flex-end; gap: 2px; vertical-align: middle; margin-right: 4px; }
.barras-sinal i { width: 4px; border-radius: 1px; background: #33415a; }
.barras-sinal.ok i.on { background: var(--verde); }
.barras-sinal.alerta i.on { background: var(--amarelo); }
.barras-sinal.ruim i.on { background: var(--vermelho); }

/* ---------- interfaces WAN (estilo lista expansível) ---------- */
.wan { background: var(--card2); border-radius: 12px; margin-bottom: 10px; overflow: hidden; border: 1px solid transparent; }
.wan.aberta { border-color: #2c3a55; }
.wan-cab { display: flex; align-items: center; gap: 16px; padding: 14px 18px; cursor: pointer; }
.wan-cab:hover { background: #212c42; }
.wan-cab .sub { display: flex; align-items: center; gap: 6px; font-size: 13px; margin-top: 2px; }
.wan-cab .sub svg { width: 14px; height: 14px; }
.chave { width: 40px; height: 22px; border-radius: 11px; background: #3a4660; position: relative; flex: none; }
.chave::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; }
.chave.on { background: var(--azul); }
.chave.on::after { left: 21px; }
.status-wan { margin-left: auto; font-size: 13px; font-weight: 600; padding: 4px 12px; border-radius: 14px; border: 1px solid; white-space: nowrap; }
.status-wan.on { color: var(--verde); border-color: #34d39988; }
.status-wan.off { color: #fb923c; border-color: #fb923c88; }
.seta { color: var(--sub); font-size: 18px; transition: transform .15s; }
.wan.aberta .seta { transform: rotate(180deg); }
.wan-corpo { display: none; padding: 0 18px 6px; border-top: 1px solid var(--borda); }
.wan.aberta .wan-corpo { display: block; }
.wan-corpo .secao { padding: 12px 0; font-size: 13.5px; line-height: 1.7; }

/* ---------- diagnósticos ---------- */
.roxo { color: #a78bfa; }
.opcoes { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin: 14px 0; }
.opcoes.cats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; justify-content: stretch; }
.opcao { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-width: 220px; min-height: 120px; padding: 18px; border-radius: 14px; background: var(--card2); border: 2px solid transparent; cursor: pointer; color: var(--txt); margin: 0; text-align: center; }
.opcoes.cats .opcao { min-width: 0; min-height: 0; align-items: flex-start; text-align: left; padding: 12px 14px; }
.opcao b { font-size: 18px; }
.opcoes.cats .opcao b { font-size: 14px; }
.opcao .opcao-ic svg { width: 30px; height: 30px; }
.opcao.on { border-color: var(--azul); }
.opcao.on.cor-roxo { border-color: #a78bfa; }
.opcao.on.cor-verde { border-color: var(--verde); }
.opcao-check { position: absolute; top: 10px; right: 10px; width: 20px; height: 20px; border-radius: 50%; border: 2px dashed #4a5878; }
.opcao.on .opcao-check { border: 0; background: var(--azul); }
.opcao.on.cor-roxo .opcao-check { background: #a78bfa; }
.opcao.on.cor-verde .opcao-check { background: var(--verde); }
.opcao.on .opcao-check::after { content: "✓"; color: #04263b; font-size: 12px; font-weight: 800; display: grid; place-items: center; height: 100%; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px; border: 1px solid var(--azul); border-radius: 10px; background: var(--campo); min-height: 44px; }
.chips input { flex: 1; min-width: 180px; background: none; border: 0; outline: 0; height: 30px; padding: 0 6px; }
.chip-v { display: inline-flex; align-items: center; gap: 6px; background: #2b3954; border-radius: 6px; padding: 4px 8px; font-family: var(--mono); font-size: 13px; color: #bfe6ff; }
.chip-v button { background: none; border: 0; color: var(--sub); cursor: pointer; font-size: 15px; padding: 0; }
.viz-grade { display: grid; grid-template-columns: 300px 1fr; gap: 12px; }
.legenda-redes { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; font-size: 12px; }
.legenda-redes i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: middle; }
details summary::-webkit-details-marker { color: var(--sub); }
@media (max-width: 1100px) { .viz-grade { grid-template-columns: 1fr; } .opcoes.cats { grid-template-columns: 1fr 1fr; } }
.opcao input { display: none !important; }

/* ---------- portas físicas ---------- */
.portas { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.porta { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 50px; padding: 6px 0; border-radius: 8px; border: 1.5px solid var(--borda-forte); color: var(--sub); font-size: 10.5px; }
.porta svg { width: 26px; height: 26px; }
.porta.on { border-color: var(--verde); color: var(--verde); background: #10b98118; }
.porta.pon { border-color: #6b5bb5; color: #a78bfa; }
.porta.pon.on { background: #a78bfa22; }

/* ---- Sistema → Atualizações ---- */
.lista-versoes { display: flex; flex-direction: column; gap: 10px; }
.versao { border: 1px solid var(--borda, #24304a); border-radius: 12px; background: rgba(255,255,255,.02); }
.versao.ativa { border-color: rgba(52, 211, 153, .35); }
.versao-cab { display: flex; align-items: center; gap: 14px; padding: 14px 16px; cursor: pointer; }
.versao-ico { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 10px; color: var(--fraco, #64748b); background: rgba(255,255,255,.04); }
.versao-ico.on { color: #34d399; background: rgba(52, 211, 153, .12); }
.versao-ico svg { width: 22px; height: 22px; }
.versao-num { font-size: 17px; margin-right: 8px; }
.versao-corpo { padding: 0 16px 14px 70px; }
.versao-corpo ul { margin: 6px 0 0; padding-left: 18px; line-height: 1.6; font-size: 13px; }
.etq.azul { background: rgba(56, 189, 248, .14); color: #7dd3fc; }
.etq.verde { background: rgba(52, 211, 153, .14); color: #6ee7b7; }

/* ---- Resumo do dispositivo (layout compacto) ---- */
.grade-resumo { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 14px; margin: 14px 0 16px; }
@media (max-width: 1100px) { .grade-resumo { grid-template-columns: 1fr; } }
.cab-recolher { cursor: pointer; user-select: none; }
.cab-recolher .chevron svg { width: 20px; height: 20px; fill: none; stroke: var(--sub); stroke-width: 2; transition: transform .2s; }
.card-info.fechado .chevron svg { transform: rotate(-90deg); }
.card-info.fechado .info-corpo { display: none; }
.card-info.fechado h3 { margin-bottom: 0; }
.info-corpo { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
@media (max-width: 760px) { .info-corpo { grid-template-columns: 1fr; } }
.info-col { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ib { display: flex; align-items: center; gap: 12px; background: var(--card2); border-radius: 10px; padding: 10px 12px; min-width: 0; }
.ib-ico svg { width: 20px; height: 20px; fill: none; stroke: var(--txt); stroke-width: 1.8; display: block; }
.ib-txt { flex: 1; min-width: 0; }
.ib-txt b { display: block; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ib-txt small { color: var(--sub); font-size: 12px; display: inline-flex; align-items: center; gap: 4px; }
.ib-dica svg { width: 13px; height: 13px; fill: none; stroke: var(--sub); stroke-width: 2; cursor: help; vertical-align: -2px; }
.ib-copiar { background: none; border: 0; padding: 4px; cursor: pointer; border-radius: 6px; opacity: .55; }
.ib-copiar:hover { opacity: 1; background: var(--campo); }
.ib-copiar svg { width: 16px; height: 16px; fill: none; stroke: var(--txt); stroke-width: 1.8; display: block; }
.sub-caixa { background: var(--card2); border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.sub-caixa.grow { flex: 1; }
.sub-titulo { text-align: center; font-size: 13px; font-weight: 600; color: var(--txt); }
.portas-mini { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.pm { width: 48px; height: 42px; border-radius: 7px; display: inline-flex; align-items: center; justify-content: center; border: 1.5px solid #2f7d77; color: #2f7d77; }
.pm svg { width: 30px; height: 30px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.pm.lan.on, .pm.wan.on { border-color: #5eead4; color: #5eead4; background: rgba(94, 234, 212, .12); }
.pm.pon { background: #a78bfa; border-color: #a78bfa; color: #1b1340; }
.pm.pon:not(.on) { background: transparent; color: #a78bfa; }
.sinal-area { display: flex; align-items: stretch; gap: 12px; min-height: 120px; }
.graf-sinal { flex: 1; min-width: 0; height: 120px; display: block; }
.sinal-valores { display: flex; flex-direction: column; justify-content: space-around; min-width: 82px; }
.sinal-valores > div { display: flex; flex-direction: column; align-items: center; }
.sinal-valores b { font-size: 22px; font-weight: 700; }
.sinal-valores b small { font-size: 13px; margin-left: 2px; }
.sinal-valores span { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--sub); }
.sinal-valores span svg { width: 15px; height: 15px; fill: none; stroke-width: 1.8; }
.sinal-valores .tx svg { stroke: #5eead4; }
.sinal-valores .rx svg { stroke: #a78bfa; }
.grade-blocos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 1100px) { .grade-blocos { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---- lista de dispositivos: densidade e escolha de colunas ---- */
table.dens-alta td { padding: 4px 10px; font-size: 13px; }
table.dens-alta th { padding: 7px 10px; }
table.dens-baixa td { padding: 14px 10px; }
.btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.pop-colunas { position: fixed; z-index: 50; width: 300px; max-height: 70vh; overflow: auto; background: var(--card); border: 1px solid var(--borda); border-radius: 12px; padding: 14px; box-shadow: 0 16px 40px #000a; }
.pc-tit { font-weight: 600; font-size: 13px; margin: 2px 0 8px; }
.pc-dens { display: flex; gap: 8px; margin-bottom: 14px; }
.pc-dens button { width: 38px; height: 34px; border-radius: 8px; border: 1px solid var(--borda); background: var(--card2); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.pc-dens button.on { border-color: var(--azul); background: rgba(56, 189, 248, .14); }
.pc-dens svg { width: 20px; height: 20px; fill: none; stroke: var(--txt); stroke-width: 2; }
.pc-lista { display: flex; flex-direction: column; gap: 2px; }
.pc-item { display: flex; align-items: center; gap: 8px; padding: 6px 6px; border-radius: 6px; cursor: grab; font-size: 13.5px; user-select: none; }
.pc-item:hover { background: var(--card2); }
.pc-item span { flex: 1; }
.pc-item input { width: 16px; height: 16px; accent-color: var(--azul); }
.pc-alca { color: var(--fraco); font-style: normal; letter-spacing: -2px; }
.pc-item.arrastando { opacity: .4; }

/* ---- estatísticas ---- */
.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
@media (max-width: 1300px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.kpi { background: var(--card); border: 1px solid var(--borda-card); border-radius: var(--raio); padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.kpi-l { display: flex; align-items: center; gap: 10px; }
.kpi-l > svg { width: 30px; height: 30px; fill: none; stroke: var(--txt); stroke-width: 1.6; flex: none; }
.kpi-l b { display: block; font-size: 15px; }
.kpi-l small { color: var(--sub); font-size: 12px; }
.kpi-v { margin-left: auto; font-size: 22px; font-weight: 700; }
.kpi-barra { height: 4px; border-radius: 2px; background: var(--card2); overflow: hidden; }
.kpi-barra i { display: block; height: 100%; border-radius: 2px; }
.kpi-rede { margin-left: auto; display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.kpi-rede span { font-size: 12.5px; font-weight: 600; background: rgba(167, 139, 250, .14); color: #c4b5fd; padding: 2px 8px; border-radius: 6px; }
.graf-informs { width: 100%; height: 200px; display: block; }

/* ---- arquivos ---- */
.barra-prog { position: relative; height: 22px; border-radius: 11px; background: var(--card2); overflow: hidden; margin: 8px 0; }
.barra-prog i { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--azul2); transition: width .2s; }
.barra-prog span { position: relative; display: block; text-align: center; font-size: 12px; line-height: 22px; font-weight: 600; }
.arq-linha { display: flex; align-items: center; gap: 12px; background: var(--card2); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; }
.arq-ico svg { width: 26px; height: 26px; fill: none; stroke: var(--sub); stroke-width: 1.5; display: block; }
.arq-tags { display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; max-width: 40%; }
.etq.vermelha { color: var(--vermelho); border-color: #f8717166; }
textarea { width: 100%; background: var(--campo); color: var(--txt); border: 1px solid var(--borda); border-radius: 8px; padding: 8px 10px; font: inherit; resize: vertical; }
.avatar { cursor: pointer; }
body.so-leitura .btn.perigo, body.so-leitura #btnRemoverSel { display: none !important; }
.pc-item input[type=checkbox] { display: inline-block; width: 16px; height: 16px; margin: 0; padding: 0; flex: none; }
.pc-item { margin: 0 !important; padding: 5px 6px; }

/* layout não estoura para a direita quando a tabela é larga */
#app { grid-template-columns: 64px minmax(0, 1fr); }
main, .topo { min-width: 0; }
.lateral { padding-top: 10px; }
.logo { flex: none; margin: 0 auto 18px; }
/* "Últimos eventos" do painel inicial: ocupa só a altura da linha e rola por dentro */
.card-eventos { contain: size; display: flex; flex-direction: column; min-height: 240px; }
.card-eventos .lista-ev { flex: 1; min-height: 0; overflow: auto; padding-right: 4px; }
.card-eventos .lista-ev .mono { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }

/* menu lateral maior (como no ACS antigo) */
#app { grid-template-columns: 78px minmax(0, 1fr); }
.lateral { gap: 8px; }
.logo { width: 48px; height: 48px; border-radius: 12px; margin-bottom: 20px; }
.logo img { width: 34px; height: 34px; }
#menu { gap: 10px; }
#menu a, .sair { width: 54px; height: 54px; border-radius: 14px; }
#menu a svg, .sair svg { width: 28px; height: 28px; stroke-width: 1.6; }
#menu a .bolinha { top: 4px; right: 4px; }
#menu a[data-dica]:hover::after { left: 64px; font-size: 13px; }
#menu a.ativo::before { left: -12px; top: 12px; bottom: 12px; }
#menu { overflow-y: auto; overflow-x: visible; }
@media (max-height: 760px) { #menu { gap: 4px; } #menu a, .sair { width: 48px; height: 48px; } #menu a svg { width: 24px; height: 24px; } }
/* telas médias (2 colunas): o 3º quadro de cada linha ocupa a largura toda, sem buraco ao lado */
@media (max-width: 1200px) and (min-width: 801px) { .g3 > .linha-cheia-media { grid-column: 1 / -1; } }

/* lista de dispositivos compacta (como no ACS antigo): tudo cabe na tela */
table.dens-alta { font-size: 13px; }
table.dens-alta td { padding: 6px 9px; font-size: 13px; }
table.dens-alta th { padding: 8px 9px; font-size: 13px; }
table.dens-alta .mono { font-size: 12px; }
table.dens-alta .etq { font-size: 11px; padding: 1px 7px; }
#tabDisp td.corta { max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#tabDisp td.mono.corta { max-width: 230px; }
#tabDisp th:first-child, #tabDisp td:first-child { padding-left: 12px; padding-right: 2px; width: 22px; }

/* ---- etiquetas coloridas ---- */
.etq.cor { font-weight: 600; text-transform: none; max-width: 150px; overflow: hidden; text-overflow: ellipsis; display: inline-block; vertical-align: middle; white-space: nowrap; }
.etq-mais { width: 22px; height: 22px; border-radius: 50%; border: 0; background: #2a3550; color: var(--txt); font-size: 15px; line-height: 20px; cursor: pointer; vertical-align: middle; margin-left: 2px; padding: 0; }
.etq-mais:hover { background: var(--azul2); color: #fff; }
td.col-etq { white-space: nowrap; }
td.col-etq .etq { margin-right: 4px; }
.pop-etq { width: 330px; }
.pop-etq .pc-item { cursor: pointer; }
.pe-ed { margin-left: auto; background: none; border: 0; color: var(--sub); cursor: pointer; font-size: 16px; padding: 0 6px; }
.pe-ed:hover { color: var(--txt); }
.pop-etq input#peBusca { background: var(--campo); color: var(--txt); border: 1px solid var(--borda); border-radius: 8px; padding: 8px 10px; font: inherit; outline: none; }
.pop-etq input#peBusca:focus { border-color: var(--azul); }
td.col-etq .etq.cor { max-width: 118px; }
td.col-etq .etq { padding-top: 1px; padding-bottom: 1px; }

/* ---- barras de rolagem discretas (em todo o painel) ---- */
* { scrollbar-width: thin; scrollbar-color: var(--rolagem) transparent; }
::-webkit-scrollbar { width: 8px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--rolagem); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #46557a; }
::-webkit-scrollbar-corner { background: transparent; }

/* ---- lista de dispositivos: quadro até o fim da tela, rodapé fixo embaixo ---- */
.tabela-card.cheia { display: flex; flex-direction: column; height: calc(100vh - 56px - 96px); min-height: 320px; padding-bottom: 0; }
.tabela-card.cheia .rolagem { flex: 1; min-height: 0; max-height: none; }
.tabela-card.cheia .paginacao { border-top: 1px solid var(--linha); padding: 10px 8px; }
.pg-bts { display: inline-flex; gap: 6px; }
.pg-bt { width: 30px; height: 28px; border-radius: 7px; border: 0; background: var(--linha); color: var(--txt); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.pg-bt svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }
.pg-bt:disabled { opacity: .35; cursor: default; }
.pg-bt:not(:disabled):hover { background: #2e3a59; }
/* cores mais suaves na tabela */
#tabDisp td { color: var(--txt2); border-bottom-color: var(--linha-tab); }
#tabDisp th { color: var(--txt); border-bottom: 1px solid var(--borda); }
#tabDisp tbody tr:hover td { background: #212b43; }
#tabDisp .ponto.on { background: #22c55e; box-shadow: none; }
.etq.cor { border-radius: 999px; padding: 2px 9px; font-size: 12px; }

/* ---------- tela de login (igual ao sistema antigo, com a marca UNI) ---------- */
.login { position: fixed; inset: 0; display: grid; grid-template-columns: 1fr 440px; background: #050b1a; z-index: 50; }
.login-hero { position: relative; overflow: hidden; display: grid; place-items: center;
  background: radial-gradient(circle at 50% 50%, #0b2a55 0%, #071733 45%, #040a18 100%); }
.login-hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(#ffffff10 1px, transparent 1px); background-size: 22px 22px; }
.bolha { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .75; }
.bolha.b1 { width: 520px; height: 520px; background: #0ea5e9; left: 8%; top: 18%; animation: flutua1 14s ease-in-out infinite alternate; }
.bolha.b2 { width: 460px; height: 460px; background: #22d3ee; right: 6%; top: 4%; animation: flutua2 17s ease-in-out infinite alternate; }
.bolha.b3 { width: 380px; height: 380px; background: #1d4ed8; left: 35%; bottom: -8%; animation: flutua3 19s ease-in-out infinite alternate; }
@keyframes flutua1 { to { transform: translate(180px, 120px) scale(1.15); } }
@keyframes flutua2 { to { transform: translate(-220px, 200px) scale(.9); } }
@keyframes flutua3 { to { transform: translate(160px, -220px) scale(1.2); } }
.hero-centro { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 46px; }
.marca-uni { display: flex; align-items: center; gap: 22px; }
.caixa-uni { width: 110px; height: 110px; background: #dbe3ec; color: #13355e; display: grid; place-items: center;
  font: 900 38px/1 "Segoe UI", Arial, sans-serif; letter-spacing: -1.5px; }
.txt-acs { color: #e7f2ff; font: 300 34px/1 "Segoe UI", Arial, sans-serif; letter-spacing: 9px; }
.txt-acs span { border-bottom: 3px solid #e7f2ff; padding-bottom: 5px; }
.marca-uni.mini { gap: 8px; }
.marca-uni.mini .caixa-uni { width: 40px; height: 40px; font-size: 13px; letter-spacing: -.5px; }
.marca-uni.mini .txt-acs { font-size: 13px; letter-spacing: 3px; }
.marca-uni.mini .txt-acs span { border-bottom-width: 1px; padding-bottom: 2px; }
.frase { color: #fff; font-size: 30px; font-weight: 700; min-height: 40px; display: flex; align-items: center; }
.cursor { display: inline-block; width: 3px; height: 34px; background: #cfe8ff; margin-left: 6px; animation: pisca 1s steps(1) infinite; }
@keyframes pisca { 50% { opacity: 0; } }
.login-lado { background: #121a2b; display: flex; flex-direction: column; padding: 24px 52px; overflow-y: auto; }
.login-topo { height: 60px; }
.login-form { margin: auto 0; display: flex; flex-direction: column; }
.login-form h1 { font-size: 26px; margin: 0 0 10px; display: flex; align-items: center; gap: 8px; }
.login-form h1 svg { width: 22px; height: 22px; }
.login-sub { color: #c6cfdd; font-size: 13.5px; margin: 0 0 38px; }
.login-form label { font-weight: 600; font-size: 13px; color: #e7ecf5; margin-bottom: 18px; }
.login-form input { height: 44px; background: #1c2537; border: 1px solid transparent; border-radius: 10px; }
.login-form input:focus { border-color: var(--azul); }
.campo-senha { position: relative; display: block; }
.campo-senha input { width: 100%; padding-right: 44px; }
.olho { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: 0; color: var(--azul); cursor: pointer; padding: 4px; display: grid; }
.btn-entrar { height: 42px; border-radius: 10px; border: 1px solid var(--azul); background: transparent; color: var(--azul);
  font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer; margin-top: 8px; transition: background .15s, color .15s; }
.btn-entrar:hover { background: var(--azul); color: #06263a; }
.btn-entrar svg { width: 16px; height: 16px; }
.seu-ip { text-align: right; font-size: 10.5px; color: var(--fraco); font-style: italic; margin-top: 6px; min-height: 14px; }
.esqueceu { text-align: center; color: var(--azul); font-size: 13px; margin-top: 34px; }
@media (max-width: 900px) { .login { grid-template-columns: 1fr; } .login-hero { display: none; } .login-lado { padding: 24px; } }
/* logo da barra lateral: caixa UNI */
.logo.logo-uni { background: #dbe3ec; color: #13355e; border-radius: 6px; font: 900 15px/1 "Segoe UI", Arial, sans-serif; letter-spacing: -.5px; }
/* gráfico de TX/RX: dica ao passar o mouse */
.sinal-graf-box { position: relative; flex: 1; min-width: 0; }
.sinal-graf-box .graf-sinal { width: 100%; }
.sinal-dica { position: absolute; pointer-events: none; background: var(--dica); border: 1px solid var(--borda); border-radius: 8px;
  padding: 6px 9px; font-size: 11.5px; white-space: nowrap; z-index: 5; box-shadow: 0 6px 18px #0008; transform: translate(-50%, -110%); }
.sinal-dica .d { color: var(--sub); margin-bottom: 3px; }
.sinal-dica b { font-family: var(--mono); font-weight: 600; }
.sinal-dica i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.sinal-ponto { position: absolute; width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--card); transform: translate(-50%, -50%); pointer-events: none; }
.sinal-linha-v { position: absolute; top: 0; bottom: 0; width: 1px; background: #ffffff22; pointer-events: none; }

/* ---------- menu da conta (clique no avatar) ---------- */
.menu-conta { position: fixed; top: 52px; right: 14px; z-index: 60; display: flex; background: var(--card); border: 1px solid var(--borda);
  border-radius: 14px; box-shadow: 0 16px 40px #0007; padding: 18px; gap: 18px; }
.mc-esq { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 0 18px 0 6px; border-right: 1px solid var(--borda); min-width: 190px; text-align: center; }
.mc-esq small { color: var(--sub); }
.mc-avatar { width: 84px; height: 84px; border-radius: 50%; background: #7cc7bf; color: #fff; display: grid; place-items: center; font-size: 40px; font-weight: 300; margin-bottom: 8px; }
.mc-avatar.grande { width: 104px; height: 104px; font-size: 50px; margin: 0; flex: none; }
.mc-dir { display: flex; flex-direction: column; min-width: 230px; }
.mc-linha { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 9px 4px; border-radius: 8px; }
.mc-link:hover { background: var(--card2); }
.mc-dir hr { border: 0; border-top: 1px solid var(--borda); width: 100%; margin: 8px 0; }
.mc-temas { display: flex; background: var(--card2); border-radius: 20px; padding: 3px; gap: 2px; }
.mc-temas button { width: 32px; height: 28px; border-radius: 16px; border: 0; background: transparent; color: var(--sub); cursor: pointer; display: grid; place-items: center; }
.mc-temas button svg { width: 17px; height: 17px; }
.mc-temas button.on { background: var(--campo); color: var(--txt); box-shadow: 0 0 0 1px var(--borda-forte); }
/* ---------- página Meu perfil ---------- */
.perfil-topo { display: flex; align-items: center; gap: 22px; margin-top: 12px; }
.perfil-topo h2 { margin: 0 0 4px; font-size: 22px; display: flex; align-items: center; gap: 10px; }
.perfil-conta { margin-top: 14px; }
.pc-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 10px; border-top: 1px solid var(--borda); }
.pc-item b { display: block; font-size: 13.5px; }
.pc-item span { color: var(--sub); font-size: 13px; }
/* ---------- histórico de sinal dos hosts ---------- */
.spark-sinal { display: inline-flex; align-items: center; gap: 8px; }
.spark-sinal svg { width: 120px; height: 30px; }
/* ================= TEMA CLARO ================= */
html[data-tema="claro"] {
  --bg: #e9eef4; --lat: #f6f8fb; --card: #f8fafc; --card2: #eef2f7; --campo: #e4eaf1;
  --borda: #d5dde8; --txt: #1d2939; --sub: #5b6b82; --fraco: #8a97aa;
  --borda-card: #dde4ee; --trilho: #dfe6ef; --borda-forte: #b7c3d4; --rolagem: #c3cddb; --linha: #e3e9f1; --txt2: #2b3a4f; --linha-tab: #e6ebf2; --dica: #ffffffef;
  --verde: #059669; --azul: #0284c7; --amarelo: #b45309; --vermelho: #dc2626; --roxo: #7c3aed;
}
html[data-tema="claro"] body { background: var(--bg); }
html[data-tema="claro"] .btn.primario { color: #fff; }
html[data-tema="claro"] .menu-conta { box-shadow: 0 16px 40px #0002; }
html[data-tema="claro"] .sinal-dica, html[data-tema="claro"] .toast { box-shadow: 0 6px 18px #0002; }
html[data-tema="claro"] .logo.logo-uni { background: #13355e; color: #fff; }
html[data-tema="claro"] main { background: #f1f4f8; }
html[data-tema="claro"] tbody tr:hover, html[data-tema="claro"] #tabDisp tbody tr:hover td, html[data-tema="claro"] .wan-cab:hover { background: #e6edf5; }
html[data-tema="claro"] .barras-sinal i { background: #cfd8e3; }
html[data-tema="claro"] .chave { background: #c3cddb; }
html[data-tema="claro"] .chip-v { background: #e2e8f0; }
html[data-tema="claro"] .etq-mais, html[data-tema="claro"] .pg-bt:not(:disabled):hover { background: #dbe3ed; }
html[data-tema="claro"] .busca { background: #ffffff; }
html[data-tema="claro"] td { border-bottom-color: var(--linha-tab); }
html[data-tema="claro"] .etq.azul { background: #e0f2fe; color: #0369a1; border-color: #7dd3fc; }
html[data-tema="claro"] .etq.verde { background: #d1fae5; color: #047857; }
html[data-tema="claro"] .card.destaque { background: linear-gradient(140deg, #eef0ff 0%, #f1ebff 55%, #f7ecfb 100%); border-color: #c9bdf3; }
.pm-box { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 52px; }
.pm-nome { font-size: 10.5px; color: var(--sub); margin-top: 2px; }
.pm-rot { font-size: 11px; line-height: 1.1; white-space: nowrap; text-align: center; }
.pm-rot b { font-family: var(--mono); font-weight: 600; }
.pm-rot small { color: var(--sub); margin-left: 2px; }

/* técnico: botões só do administrador ficam escondidos (o servidor também bloqueia) */
body.nivel-tecnico #bReset, body.nivel-tecnico #btnRemoverSel { display: none !important; }
/* wiki */
.glossario { display: grid; grid-template-columns: 220px 1fr; gap: 10px 18px; margin: 6px 0 0; }
.glossario dt { font-weight: 700; color: var(--azul); }
.glossario dd { margin: 0; color: var(--sub); }
/* ================= TEMA ÂMBAR (grafite quente com detalhes laranja) ================= */
html[data-tema="ambar"] {
  --bg: #0f0c0a; --lat: #14100d; --card: #1b1612; --card2: #231c16; --campo: #2a221b;
  --borda: #3a2e24; --txt: #f5ece4; --sub: #b3a395; --fraco: #7d6d60;
  --borda-card: #2a211a; --trilho: #33281f; --borda-forte: #5a4534; --rolagem: #4a3a2c; --linha: #2d241c; --txt2: #e6d8cb; --linha-tab: #2a2119; --dica: #1b1410f2;
  --azul: #fb923c; --roxo: #f472b6;
}
html[data-tema="ambar"] body { background: radial-gradient(1200px 500px at 85% -10%, #fb923c1f, transparent 60%), radial-gradient(900px 400px at -10% 110%, #f9731614, transparent 60%), var(--bg); background-attachment: fixed; }
html[data-tema="ambar"] main { background: transparent; }
html[data-tema="ambar"] .logo.logo-uni { background: linear-gradient(135deg, #fb923c, #f97316 55%, #ea580c); color: #1b0f05; box-shadow: 0 0 22px #fb923c55; }
html[data-tema="ambar"] #menu a.ativo, html[data-tema="ambar"] #menu a:hover { color: #fb923c; }
html[data-tema="ambar"] .btn.primario { background: linear-gradient(135deg, #fb923c, #f97316); color: #1b0f05; border-color: #f97316; }
html[data-tema="ambar"] .card { box-shadow: 0 1px 0 #ffffff06 inset, 0 10px 30px #00000040; }
html[data-tema="ambar"] .card.destaque { background: linear-gradient(140deg, #2a1608 0%, #3a1d0a 55%, #45200b 100%); border-color: #7c3a12; }
html[data-tema="ambar"] .etq.azul { background: #fb923c22; color: #fdba74; border-color: #fb923c66; }
html[data-tema="ambar"] tbody tr:hover, html[data-tema="ambar"] #tabDisp tbody tr:hover td { background: #2a2018; }
html[data-tema="ambar"] td { border-bottom-color: var(--linha-tab); }
html[data-tema="ambar"] .busca { background: #1b1612; }
html[data-tema="ambar"] #avatar { background: #f97316; color: #1b0f05; }
html[data-tema="ambar"] ::selection { background: #fb923c55; }
.campo-busca { width: 340px; max-width: 100%; height: 36px; padding: 0 12px; margin-bottom: 10px; background: var(--campo); border: 1px solid var(--borda); border-radius: 8px; color: var(--txt); }
/* "Informações do dispositivo" recolhido: o card encolhe e avisa como abrir (antes ficava um quadro vazio) */
.card-info.fechado { align-self: start; }
.info-dica-fechado { display: none; font-size: 12px; font-weight: 400; color: var(--sub); margin-left: 10px; }
.card-info.fechado .info-dica-fechado { display: inline; }
/* "TR-069" ao lado de ACS */
.txt-acs .txt-tr { font-style: normal; font: inherit; letter-spacing: inherit; color: inherit; margin-left: 18px; }
.marca-uni.mini .txt-acs .txt-tr { margin-left: 6px; }
.creditos { text-align: center; font-size: 11.5px; color: var(--fraco); padding: 14px 0 4px; letter-spacing: .3px; }
#cabTabela th.ordenavel { cursor: pointer; user-select: none; white-space: nowrap; }
#cabTabela th.ordenavel:hover { color: var(--azul); }
#cabTabela .seta-ord { font-size: 10px; margin-left: 5px; opacity: .3; }
#cabTabela th.ordenavel:hover .seta-ord { opacity: .7; }
#cabTabela th.on { color: var(--azul); }
#cabTabela th.on .seta-ord { opacity: 1; }
.grupos-dest { margin-top: 8px; font-size: 12.5px; color: var(--sub); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.btn.mini { height: 26px; padding: 0 10px; font-size: 12px; }
/* qualidade do Wi-Fi no Resumo */
.qualidade-wifi { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0 4px 12px; }
.qw-bloco { background: var(--card2); border-radius: 12px; padding: 12px 16px; }
.qw-tit { font-weight: 600; font-size: 13px; text-align: center; margin-bottom: 6px; }
.qw-linha { display: flex; align-items: center; gap: 14px; }
.qw-linha .mini-graf { flex: 1; }
.qw-num { min-width: 86px; text-align: center; }
.qw-num b { font-size: 34px; font-weight: 700; }
.qw-num small { color: var(--sub); margin-left: 2px; }
.qw-barra { position: relative; height: 6px; border-radius: 4px; margin-top: 4px; background: linear-gradient(90deg, #f87171, #fbbf24, #34d399); }
.qw-barra i { position: absolute; top: -4px; width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; border-top: 6px solid var(--txt); transform: translateX(-5px); }
.qw-pe { text-align: center; font-size: 11.5px; color: var(--sub); margin-top: 6px; font-style: italic; }
.mini-graf { position: relative; height: 56px; }
.mini-graf svg { width: 100%; height: 100%; display: block; }
.mini-graf.vazio { display: grid; place-items: center; font-size: 11.5px; color: var(--fraco); text-align: center; }
.nota-host { display: inline-flex; flex-direction: column; align-items: center; min-width: 46px; }
.nota-host b { font-size: 13px; }
.nota-host i { display: block; height: 3px; border-radius: 2px; background: var(--c); margin-top: 2px; align-self: flex-start; }
@media (max-width: 900px) { .qualidade-wifi { grid-template-columns: 1fr; } }
