:root {
  --azul-neon: #00d9ff;
  --azul-neon-fraco: rgba(0, 217, 255, 0.35);
  --fundo: #050810;
  --fundo-card: #0b0f1a;
  --fundo-card-vidro: rgba(14, 18, 28, 0.62);
  --fundo-sidebar: #080c14;
  --fundo-sidebar-vidro: rgba(8, 12, 20, 0.55);
  --texto: #e6f7ff;
  --texto-fraco: #7fa7b8;
  --desfoque-sidebar: 20px;
  --desfoque-card: 22px;
}

* { box-sizing: border-box; }

/* ---------- Scrollbar customizado (mais discreto que o padrão do navegador) ---------- */

* {
  scrollbar-width: thin;
  scrollbar-color: rgba(160, 180, 195, 0.35) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  background-color: rgba(160, 180, 195, 0.35);
  border-radius: 10px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

*::-webkit-scrollbar-thumb:hover {
  background-color: rgba(0, 217, 255, 0.45);
  background-clip: padding-box;
}

body {
  background: var(--fundo);
  color: var(--texto);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Arial, sans-serif;
  margin: 0;
  min-height: 100vh;
}

/* ---------- Layout com barra lateral ---------- */

.app-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 240px;
  flex-shrink: 0;
  background: var(--fundo-sidebar-vidro);
  backdrop-filter: blur(var(--desfoque-sidebar)) saturate(160%);
  -webkit-backdrop-filter: blur(var(--desfoque-sidebar)) saturate(160%);
  border-right: 1px solid var(--azul-neon-fraco);
  display: flex;
  flex-direction: column;
  padding: 24px 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1), padding 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.recolhida {
  width: 0;
  padding: 24px 0;
  overflow: hidden;
  border-right: none;
}

.sidebar.recolhida .logo-topo,
.sidebar.recolhida .sidebar-links,
.sidebar.recolhida .sidebar-rodape {
  opacity: 0;
  transition: opacity 0.15s;
  pointer-events: none;
}

.sidebar:not(.recolhida) .logo-topo,
.sidebar:not(.recolhida) .sidebar-links,
.sidebar:not(.recolhida) .sidebar-rodape {
  opacity: 1;
  transition: opacity 0.25s ease 0.1s;
}

.botao-menu {
  position: fixed;
  top: 16px;
  left: 12px;
  z-index: 50;
  background: var(--fundo-sidebar);
  border: 1px solid var(--azul-neon-fraco);
  color: var(--azul-neon);
  border-radius: 10px;
  width: 34px;
  height: 34px;
  font-size: 16px;
  cursor: pointer;
}

.botao-menu:hover {
  background: rgba(0, 217, 255, 0.1);
}

.botao-tema {
  position: fixed;
  top: 16px;
  left: 54px;
  z-index: 50;
  background: var(--fundo-sidebar);
  border: 1px solid var(--azul-neon-fraco);
  color: var(--azul-neon);
  border-radius: 10px;
  width: 34px;
  height: 34px;
  font-size: 15px;
  cursor: pointer;
}

.botao-tema:hover {
  background: rgba(0, 217, 255, 0.1);
}

/* ---------- Tema claro ---------- */

body.tema-claro {
  --azul-neon: #0077b6;
  --azul-neon-fraco: rgba(0, 119, 182, 0.3);
  --fundo: #f2f6fa;
  --fundo-card: #ffffff;
  --fundo-card-vidro: rgba(255, 255, 255, 0.65);
  --fundo-sidebar: #ffffff;
  --fundo-sidebar-vidro: rgba(255, 255, 255, 0.7);
  --texto: #10151c;
  --texto-fraco: #55636f;
}

body.tema-claro .card,
body.tema-claro .sidebar,
body.tema-claro .botao-menu,
body.tema-claro .botao-tema {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

body.tema-claro input,
body.tema-claro select {
  background: #f5f8fb;
  color: var(--texto);
}

body.tema-claro .botao:hover {
  color: #ffffff;
}

/* ---------- Tema preto absoluto ---------- */

body.tema-preto {
  --azul-neon: #00d9ff;
  --azul-neon-fraco: rgba(0, 217, 255, 0.25);
  --fundo: #000000;
  --fundo-card: #000000;
  --fundo-card-vidro: rgba(0, 0, 0, 0.75);
  --fundo-sidebar: #000000;
  --fundo-sidebar-vidro: rgba(0, 0, 0, 0.85);
  --texto: #f5f5f5;
  --texto-fraco: #8a8a8a;
}

/* ---------- Tema branco puro ---------- */

body.tema-branco {
  --azul-neon: #0077b6;
  --azul-neon-fraco: rgba(0, 119, 182, 0.2);
  --fundo: #ffffff;
  --fundo-card: #ffffff;
  --fundo-card-vidro: rgba(255, 255, 255, 0.92);
  --fundo-sidebar: #ffffff;
  --fundo-sidebar-vidro: rgba(255, 255, 255, 0.96);
  --texto: #0a0a0a;
  --texto-fraco: #6b7280;
}

body.tema-branco .card,
body.tema-branco .sidebar,
body.tema-branco .botao-menu,
body.tema-branco .botao-tema {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

body.tema-branco input,
body.tema-branco select {
  background: #f5f8fb;
  color: var(--texto);
}

/* ---------- Tema vidro transparente (bom em cima de papel de parede) ---------- */

body.tema-vidro {
  --azul-neon: #00d9ff;
  --azul-neon-fraco: rgba(0, 217, 255, 0.3);
  --fundo-card-vidro: rgba(14, 18, 28, 0.25);
  --fundo-sidebar-vidro: rgba(8, 12, 20, 0.25);
  --texto: #eaf6fb;
  --texto-fraco: #a9c5d1;
  --desfoque-sidebar: 30px;
  --desfoque-card: 34px;
}

/* ---------- Tema verde tecnológico ---------- */

body.tema-verde {
  --azul-neon: #39ff88;
  --azul-neon-fraco: rgba(57, 255, 136, 0.3);
  --texto: #e8fff0;
  --texto-fraco: #7fb897;
}

/* ---------- Tema estilo Apple (minimalista, cinza claro + acentos discretos) ---------- */

body.tema-apple {
  --azul-neon: #0071e3;
  --azul-neon-fraco: rgba(0, 113, 227, 0.18);
  --fundo: #f5f5f7;
  --fundo-card: #ffffff;
  --fundo-card-vidro: rgba(255, 255, 255, 0.4);
  --fundo-sidebar: #ffffff;
  --fundo-sidebar-vidro: rgba(255, 255, 255, 0.45);
  --texto: #1d1d1f;
  --texto-fraco: #6e6e73;
  --desfoque-sidebar: 28px;
  --desfoque-card: 26px;
}

body.tema-apple .card,
body.tema-apple .sidebar,
body.tema-apple .botao-menu,
body.tema-apple .botao-tema {
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

body.tema-apple .card {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0.05) 45%),
    var(--fundo-card-vidro);
}

body.tema-apple .card h2,
body.tema-apple .card h3 {
  color: var(--texto);
  text-shadow: none;
  font-weight: 600;
  letter-spacing: -0.01em;
}

body.tema-apple input,
body.tema-apple select {
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  color: var(--texto);
}

body.tema-apple input:focus,
body.tema-apple select:focus {
  box-shadow: 0 0 0 4px var(--azul-neon-fraco);
}

body.tema-apple .botao {
  background: rgba(0, 113, 227, 0.82);
  backdrop-filter: blur(14px) saturate(180%);
  -webkit-backdrop-filter: blur(14px) saturate(180%);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 980px;
  font-weight: 500;
  letter-spacing: normal;
  box-shadow: 0 4px 16px rgba(0, 113, 227, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

body.tema-apple .botao:hover {
  background: rgba(0, 119, 237, 0.92);
  box-shadow: 0 4px 20px rgba(0, 113, 227, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

body.tema-apple .botao-secundario {
  background: rgba(255, 255, 255, 0.3);
  color: var(--texto);
  border-color: rgba(255, 255, 255, 0.5);
}

body.tema-apple .botao-secundario:hover {
  background: rgba(255, 255, 255, 0.45);
  color: var(--texto);
}

.logo-topo {
  background: #000000;
  margin: -24px 0 0;
  padding: 70px 0 28px;
  display: flex;
  justify-content: center;
}

.logo-sidebar {
  display: block;
  width: 150px;
  margin: 0;
}

.sidebar-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0 14px;
  flex: 1;
}

.link-sidebar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  margin: 3px 0;
  color: var(--texto-fraco);
  text-decoration: none;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: 0.15s;
}

.icone-link {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.link-sidebar:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.10);
  color: var(--texto);
}

.link-sidebar.ativo {
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.10), rgba(255, 255, 255, 0.02) 60%),
    rgba(0, 217, 255, 0.14);
  border-color: rgba(0, 217, 255, 0.35);
  color: var(--azul-neon);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 0 16px rgba(0, 217, 255, 0.08);
}

.sidebar-rodape {
  padding: 16px 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
  text-align: center;
}

.cartao-usuario-sidebar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 12px;
  margin-bottom: 12px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.01) 60%), rgba(5, 8, 16, 0.5);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.10);
}

.nome-usuario {
  font-size: 17px;
  font-weight: 700;
  color: var(--texto);
  letter-spacing: 0.3px;
}

.sair {
  display: inline-block;
  color: var(--texto-fraco);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 20px;
  border: 1px solid transparent;
  border-radius: 20px;
  transition: 0.2s;
}

.sair:hover {
  color: var(--azul-neon);
  border-color: var(--azul-neon-fraco);
  background: rgba(0, 217, 255, 0.06);
}

.conteudo-principal {
  flex: 1;
  padding: 36px 40px;
  max-width: 1000px;
  margin: 0 auto;
}

/* ---------- Login (sem sidebar) ---------- */

.container {
  max-width: 960px;
  margin: 40px auto;
  padding: 0 20px;
}

.cena-fundo {
  position: fixed;
  inset: 0;
  z-index: -2;
  background-image: url("/static/cena/bg-desktop.jpg?v=3");
  background-size: cover;
  background-position: center;
}

@media (max-width: 760px) {
  .cena-fundo {
    background-image: url("/static/cena/bg-mobile.jpg?v=3");
  }
}

.cena-fundo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(3,6,12,0.55), rgba(3,6,12,0.4) 40%, rgba(3,6,12,0.65));
}

.cena-fazenda {
  position: fixed;
  left: 24px;
  bottom: 24px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.marcador {
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 300px;
  padding: 12px;
  background: rgba(5, 8, 16, 0.55);
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  pointer-events: auto;
  cursor: default;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.marcador:hover,
.marcador:focus-visible {
  transform: translateY(-2px) scale(1.03);
  border-color: var(--azul-neon);
  box-shadow: 0 0 26px rgba(0, 217, 255, 0.25);
  outline: none;
}

.marcador-foto {
  width: 86px;
  height: 86px;
  flex-shrink: 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--azul-neon-fraco);
}

.marcador-foto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.marcador-texto {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.marcador-nome {
  font-size: 12px;
  font-weight: 600;
  color: var(--texto);
  letter-spacing: 0.3px;
}

.marcador-status {
  font-size: 11px;
  color: var(--texto-fraco);
  display: flex;
  align-items: center;
  gap: 6px;
}

.marcador-status .valor-grande {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--azul-neon);
}

.marcador-status .status-ligado { display: none; color: #4dffa0; }
.marcador-status .status-desligado { display: inline; }
.marcador:hover .status-ligado,
.marcador:focus-visible .status-ligado { display: inline; }
.marcador:hover .status-desligado,
.marcador:focus-visible .status-desligado { display: none; }

.led {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #ff3b3b;
  box-shadow: 0 0 6px #ff3b3b;
}

.marcador:hover .led,
.marcador:focus-visible .led {
  background: #2bff6a;
  box-shadow: 0 0 8px #2bff6a;
}

.barra-caixa {
  position: relative;
  width: 100%;
  height: 7px;
  margin-top: 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.barra-caixa-preenchimento {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 50%;
  border-radius: 4px;
  background: linear-gradient(90deg, #0077ff, #4dd8ff, #0077ff);
  background-size: 200% 100%;
  transition: height 4.5s ease-in-out;
  animation: brilho-agua 3s linear infinite;
}

@keyframes brilho-agua {
  0% { background-position: 0% 0%; }
  100% { background-position: 200% 0%; }
}

.marcador-painel {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.25s ease, opacity 0.25s ease;
}

.marcador:hover .marcador-painel,
.marcador:focus-visible .marcador-painel {
  max-height: 90px;
  opacity: 1;
  margin-top: 4px;
}

.painel-linha {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 11px;
  color: var(--texto-fraco);
}

.painel-linha b {
  color: var(--azul-neon);
  font-variant-numeric: tabular-nums;
}

@media (max-width: 760px) {
  .cena-fazenda {
    position: static;
    margin: 18px auto 0;
    width: fit-content;
    max-width: 100%;
  }
  .marcador { max-width: 310px; padding: 10px; gap: 10px; }
  .marcador-foto { width: 64px; height: 64px; }

  .card-login { padding: 26px 22px; }
  .logo-login { max-width: 210px; margin-bottom: 4px; }
  .subtitulo-login { margin: 2px 0 18px; }
  .form-login input { margin-bottom: 14px; }
  .form-login .campo-senha { margin-bottom: 14px; }
}

.legenda-3d {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  margin-top: 22px;
  color: var(--texto-fraco);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  background: rgba(5, 8, 16, 0.5);
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 999px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  pointer-events: none;
  opacity: 0;
  animation: legenda3dEntrar 1.2s ease 0.5s forwards;
}

.ponto-vivo {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--azul-neon);
  box-shadow: 0 0 8px var(--azul-neon);
  animation: piscarPonto 2s ease-in-out infinite;
}

@keyframes piscarPonto {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

@keyframes legenda3dEntrar {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 640px) {
  .legenda-3d { font-size: 10px; padding: 7px 14px; margin-top: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .ponto-vivo { animation: none; }
}

.wrapper-login {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.card-login {
  width: 100%;
  max-width: 380px;
  background: #000;
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 22px;
  padding: 40px 34px;
  box-shadow: 0 0 40px rgba(0, 217, 255, 0.10);
  text-align: center;
}

.subtitulo-login {
  font-family: "Orbitron", "Segoe UI", sans-serif;
  font-weight: 600;
  color: var(--azul-neon);
  font-size: 18px;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-shadow: 0 0 12px var(--azul-neon-fraco), 0 0 2px var(--azul-neon);
  margin: 6px 0 30px;
}

.form-login {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  text-align: left;
}

.form-login label {
  font-size: 12px;
  color: var(--texto-fraco);
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.form-login input {
  margin-bottom: 20px;
}

.form-login .campo-senha {
  margin-bottom: 20px;
}

.form-login .campo-senha input {
  margin-bottom: 0;
  width: 100%;
}

.botao-ios {
  margin-top: 14px;
  padding: 14px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(180deg, #00e5ff, #00a0d6);
  color: #001018;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.3px;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 217, 255, 0.35);
  transition: transform 0.15s, box-shadow 0.15s;
}

.botao-ios:hover {
  box-shadow: 0 8px 26px rgba(0, 217, 255, 0.5);
}

.botao-ios:active {
  transform: scale(0.97);
}

.logo-login {
  display: block;
  margin: 0 auto 8px;
  max-width: 100%;
  height: auto;
}

/* ---------- Selos (ADM / Cliente) ---------- */

.selo {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
}

.selo-pequeno {
  padding: 2px 8px;
  font-size: 9px;
  letter-spacing: 0.5px;
  opacity: 0.85;
}

.selo-admin {
  background: rgba(255, 193, 7, 0.15);
  color: #ffc107;
  border: 1px solid rgba(255, 193, 7, 0.5);
}

.selo-cliente {
  background: rgba(0, 217, 255, 0.15);
  color: var(--azul-neon);
  border: 1px solid var(--azul-neon-fraco);
}

.selo-online {
  background: rgba(76, 217, 100, 0.15);
  color: #4cd964;
  border: 1px solid rgba(76, 217, 100, 0.5);
}

.selo-offline {
  background: rgba(255, 107, 107, 0.15);
  color: #ff6b6b;
  border: 1px solid rgba(255, 107, 107, 0.5);
}

.badge-contagem {
  margin-left: auto;
  background: #ff6b6b;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ---------- Cards e formulários ---------- */

.card {
  position: relative;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.015) 45%),
    var(--fundo-card-vidro);
  backdrop-filter: blur(var(--desfoque-card)) saturate(170%);
  -webkit-backdrop-filter: blur(var(--desfoque-card)) saturate(170%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 28px;
  padding: 28px;
  margin-bottom: 24px;
  box-shadow: 0 10px 34px rgba(0, 0, 0, 0.28), 0 0 24px rgba(0, 217, 255, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  overflow: hidden;
}

/* ---------- Modal de histórico (popup ao clicar num valor da página inicial) ---------- */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
}

.modal-overlay.aberto {
  display: flex;
  animation: modal-abrir-fundo 0.15s ease;
}

.modal-overlay.aberto .modal-painel {
  animation: modal-abrir-painel 0.18s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes modal-abrir-fundo {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modal-abrir-painel {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

.modal-painel {
  max-width: 640px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  margin-bottom: 0;
}

.modal-painel-cabecalho {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 4px;
}

.modal-painel-cabecalho h4 {
  margin: 0;
}

.modal-fechar {
  background: none;
  border: none;
  color: var(--texto-fraco);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.valor-destaque[role="button"] {
  cursor: pointer;
  transition: transform 0.15s;
}

.valor-destaque[role="button"]:hover {
  transform: translateY(-2px);
}

.card h2, .card h3 {
  color: var(--azul-neon);
  margin-top: 0;
  text-shadow: 0 0 6px var(--azul-neon-fraco);
  text-align: center;
}

.card-interno {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 18px;
  padding: 16px 18px;
}

label {
  display: block;
  margin: 12px 0 4px;
  color: var(--texto-fraco);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

input, select {
  width: 100%;
  padding: 11px 14px;
  background: #0f1622;
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 12px;
  color: var(--texto);
  font-size: 14px;
}

input:focus, select:focus {
  outline: none;
  border-color: var(--azul-neon);
  box-shadow: 0 0 10px var(--azul-neon-fraco);
}

input:disabled {
  opacity: 0.55;
}

/* ---------- Botões ---------- */

.botao {
  display: inline-block;
  padding: 11px 22px;
  background: transparent;
  border: 1px solid var(--azul-neon);
  color: var(--azul-neon);
  border-radius: 14px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 1px;
  cursor: pointer;
  text-decoration: none;
  transition: 0.2s;
}

.botao:hover {
  background: var(--azul-neon);
  color: #001018;
  box-shadow: 0 0 16px var(--azul-neon);
}

.botao-secundario {
  border-color: var(--texto-fraco);
  color: var(--texto-fraco);
}

.botao-perigo {
  border-color: #ff6b6b;
  color: #ff6b6b;
}

.botao-perigo:hover {
  background: #ff6b6b;
  color: #1a0505;
  box-shadow: 0 0 12px #ff6b6b;
}

.linha-botoes {
  display: flex;
  gap: 12px;
  margin-top: 18px;
}

.linha-botoes .botao {
  flex: 0 0 auto;
  min-width: 110px;
  text-align: center;
}

/* ---------- Senha com olhinho ---------- */

.campo-senha {
  position: relative;
}

.campo-senha input {
  padding-right: 36px;
}

/* esconde o olhinho nativo do Edge/IE pra nao sobrepor o nosso .olho-senha */
.campo-senha input::-ms-reveal,
.campo-senha input::-ms-clear {
  display: none;
}

.olho-senha {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  opacity: 0.7;
  user-select: none;
}

.olho-senha:hover { opacity: 1; }

/* ---------- Cartões de usuário / hidrômetro ---------- */

.cartao-usuario {
  border-top: 1px solid rgba(0, 217, 255, 0.15);
  padding-top: 18px;
  margin-top: 10px;
}

.cartao-usuario:first-of-type {
  border-top: none;
  margin-top: 0;
  padding-top: 0;
}

.linha-editavel {
  border-top: 1px solid rgba(0, 217, 255, 0.1);
  padding-top: 14px;
  margin-top: 4px;
  padding-bottom: 8px;
}

.linha-checkboxes {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.opcao-checkbox {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--texto-fraco);
  font-size: 13px;
  text-transform: none;
  letter-spacing: normal;
  cursor: pointer;
}

.opcao-checkbox input {
  width: auto;
  accent-color: var(--azul-neon);
}

.linha-form {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.linha-form > div { flex: 1; min-width: 160px; }

.hidrometros-do-usuario {
  margin-top: 14px;
  padding: 14px;
  background: rgba(0, 217, 255, 0.04);
  border-radius: 8px;
}

.lista-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0, 217, 255, 0.1);
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 20px;
  padding: 4px 6px 4px 12px;
  font-size: 13px;
}

.tag-remover {
  background: none;
  border: none;
  color: var(--texto-fraco);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  padding: 2px 6px;
  border-radius: 50%;
}

.tag-remover:hover {
  color: #ff6b6b;
  background: rgba(255, 107, 107, 0.15);
}

.texto-fraco {
  color: var(--texto-fraco);
  font-size: 13px;
}

.cartao-hidrometro {
  text-align: center;
}

.nome-hidrometro {
  color: var(--texto);
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 4px;
}

.nome-destaque {
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto 14px;
  padding: 10px 26px;
  border: 1px solid #ff6b6b;
  border-radius: 999px;
  color: var(--azul-neon);
  font-size: 22px;
  font-weight: 700;
  text-align: center;
  text-shadow: 0 0 10px var(--azul-neon-fraco);
  box-shadow: 0 0 14px rgba(255, 107, 107, 0.25);
}

.rodape-cartao {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}

.painel-valores {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 14px;
}

.botao-recarregar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
  padding: 10px 22px;
  background: rgba(0, 217, 255, 0.08);
  border: 1px solid var(--azul-neon);
  color: var(--azul-neon);
  border-radius: 14px;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: 0.2s;
}

.botao-recarregar:hover {
  background: var(--azul-neon);
  color: #001018;
  box-shadow: 0 0 16px var(--azul-neon);
}

.botao-recarregar-flutuante {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--fundo-sidebar);
  border: 1px solid var(--azul-neon-fraco);
  color: var(--azul-neon);
  border-radius: 12px;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  transition: 0.2s;
}

.botao-recarregar-flutuante:hover {
  background: var(--azul-neon);
  color: #001018;
  box-shadow: 0 0 16px var(--azul-neon);
}

.botao-recarregar-flutuante .icone-link {
  width: 15px;
  height: 15px;
}

.valor-destaque {
  background: rgba(0, 217, 255, 0.06);
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 16px;
  padding: 12px 20px;
  min-width: 130px;
  text-align: center;
}

.valor-numero {
  display: block;
  font-size: 24px;
  font-weight: 700;
  color: var(--azul-neon);
  text-shadow: 0 0 8px var(--azul-neon-fraco);
}

.valor-rotulo {
  display: block;
  font-size: 11px;
  color: var(--texto-fraco);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

/* ---------- Tabela de relatório ---------- */

table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  margin-top: 20px;
}

th, td {
  padding: 10px 12px;
  text-align: center;
  border-bottom: 1px solid rgba(0, 217, 255, 0.15);
  font-size: 14px;
}

th {
  color: var(--azul-neon);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 1px;
}

tr.total td {
  font-weight: 700;
  color: var(--azul-neon);
  border-top: 1px solid var(--azul-neon);
}

.erro {
  color: #ff6b6b;
  margin: 10px 0;
}

/* ---------- Dropdown de exportar (PDF / Excel) ---------- */
.dropdown-exportar {
  position: relative;
  display: inline-block;
}

.menu-exportar {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 160px;
  background: var(--fundo-card);
  border: 1px solid var(--azul-neon-fraco);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  z-index: 50;
}

.menu-exportar.aberto {
  display: block;
}

.menu-exportar button {
  display: block;
  width: 100%;
  padding: 10px 16px;
  background: transparent;
  border: none;
  color: var(--texto);
  font-size: 14px;
  text-align: left;
  cursor: pointer;
  transition: 0.15s;
}

.menu-exportar button:hover {
  background: var(--azul-neon-fraco);
  color: var(--azul-neon);
}

/* Botões flutuantes de contato (WhatsApp/Instagram), mesmo estilo do site marceloautomacoesgo.com.br */
.float-btn {
  position: fixed;
  right: 30px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: transform 0.3s;
  text-decoration: none;
}

.float-btn:hover {
  transform: scale(1.1);
}

.float-btn svg {
  width: 32px;
  height: 32px;
  fill: #fff;
}

.whatsapp-btn {
  bottom: 30px;
  background: #25d366;
  box-shadow: 0 4px 30px rgba(37, 211, 102, 0.714);
}

.instagram-btn {
  bottom: 100px;
  background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285aeb 90%);
  box-shadow: 0 4px 20px rgba(214, 36, 159, 0.5);
}

.float-tooltip {
  position: fixed;
  right: 100px;
  color: #fff;
  padding: 8px 15px;
  border-radius: 20px;
  font-size: 13.6px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s;
  z-index: 9998;
  pointer-events: none;
}

.whatsapp-tooltip {
  bottom: 42px;
  background: #25d366;
}

.instagram-tooltip {
  bottom: 112px;
  background: #d6249f;
}

.whatsapp-btn:hover + .whatsapp-tooltip,
.instagram-btn:hover + .instagram-tooltip {
  opacity: 1;
}

@media (max-width: 480px) {
  .float-btn {
    width: 52px;
    height: 52px;
    right: 16px;
  }
  .whatsapp-btn { bottom: 16px; }
  .instagram-btn { bottom: 78px; }
  .float-tooltip { display: none; }
}
