body { font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; margin:0; background:#f8fafc; color:#0f172a; }
main.container { max-width: 1140px; margin: 16px auto 24px auto; padding-left: 0; padding-right: 0; }

.card,
.modal-content {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.08);
}

.form-control:focus,
.form-select:focus {
  box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.18);
  border-color: rgba(59, 130, 246, 0.55);
}

/* KPI chip grande no topo */
.kpi-chip { 
  display:inline-flex; align-items:center; gap:14px; 
  background:#fff; border:1px solid #e5e7eb; border-radius:16px; 
  padding:14px 18px; box-shadow:0 6px 18px rgba(2,6,23,.06);
}
.kpi-chip .kpi-title { font-size:14px; color:#64748b; font-weight:600; }
.kpi-chip .kpi-value { font-size:30px; font-weight:800; color:#0f172a; }

/* Cabeçalho */
.page-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:16px; }
.page-header h1 { margin:0; font-size:34px; font-weight:800; }
.page-header-right { display:flex; align-items:center; gap:12px; }
.mode-badge { background:#10b981; color:#fff; font-weight:700; font-size:12px; padding:6px 10px; border-radius:999px; }
.link-exit { color:#334155; text-decoration:none; font-weight:600; }
.link-exit:hover { text-decoration:underline; }

/* Layout com sidebar */
.layout {
  display:grid;
  grid-template-columns: 320px 1fr;
  gap: 20px;
}
.sidebar { min-width: 280px; }
.content { min-width: 0; border-left: 1px solid #e5e7eb; padding-left: 20px; }

/* Responsivo: mobile fica 1 coluna */
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  .content { border-left: 0; padding-left: 0; }
}

/* Card lateral e sticky */
.filters-sidebar { position: sticky; top: 1rem; background:#fff; border:1px solid #e5e7eb; border-radius:12px; }
.filters-sidebar .card-body { padding: 16px; }

/* Form vertical */
.form-group { display:flex; flex-direction:column; margin-bottom:12px; }
.form-label { font-size:13px; color:#334155; margin-bottom:6px; }
.form-input { padding:10px; border:1px solid #cbd5e1; border-radius:8px; background:#fff; }

/* Ações do form */
.form-actions { display:flex; gap:10px; margin-top:10px; }

/* Correção: restaurar comportamento dos botões usando variáveis do Bootstrap */
.btn {
  background-color: var(--bs-btn-bg) !important;
  color: var(--bs-btn-color) !important;
  border-color: var(--bs-btn-border-color) !important;
}
.btn:hover {
  background-color: var(--bs-btn-hover-bg) !important;
  color: var(--bs-btn-hover-color) !important;
  border-color: var(--bs-btn-hover-border-color) !important;
}
/* Barra de progresso fininha no topo */
.top-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 2000;
  background: transparent; pointer-events: none;
}
.top-progress-bar {
  width: 0%; height: 100%;
  background-image: linear-gradient(90deg,#6d28d9,#2563eb,#14b8a6,#f59e0b,#ef4444);
  background-size: 300% 100%; animation: galaxyShift 1.3s linear infinite;
  box-shadow: 0 0 8px rgba(37,99,235,0.5);
  transition: width 0.2s ease;
}

/* Overlay export (dark mode) */
.export-overlay.dark {
  background: rgba(2,6,23,0.68);
}
.export-overlay.dark .export-panel {
  background: #0b1220; border-color: #1f2937; color: #e5e7eb;
}
.export-overlay.dark .export-title { color: #e5e7eb; }
.export-overlay.dark .progress { background: #111827; }
.export-overlay.dark .progress-meta,
.export-overlay.dark .progress-info { color: #cbd5e1; }
.export-overlay.dark .btn.btn-outline-light { border-color: #cbd5e1; color: #e5e7eb; }

/* Overlay base existente */
.export-overlay { position: fixed; inset: 0; backdrop-filter: blur(2px); display: none; z-index: 3000; }
.export-overlay.show { display: block; }
.export-panel { position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); width: min(520px,90vw); background: #fff; border: 1px solid #e2e8f0; box-shadow: 0 12px 40px rgba(15,23,42,0.12); border-radius: 12px; padding: 18px; }
.export-title { font-weight: 600; font-size: 16px; margin-bottom: 12px; }
.progress { width: 100%; height: 12px; border-radius: 999px; overflow: hidden; }
.progress-bar { height: 100%; width: 0%; border-radius: 999px; background-image: linear-gradient(90deg,#6d28d9,#2563eb,#14b8a6,#f59e0b,#ef4444); background-size: 300% 100%; animation: galaxyShift 1.6s linear infinite; position: relative; }
.progress-bar::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(255,255,255,0.0) 0%, rgba(255,255,255,0.35) 50%, rgba(255,255,255,0.0) 100%); mix-blend-mode: overlay; animation: shimmer 1.8s ease-in-out infinite; }
@keyframes galaxyShift { 0% {background-position: 0% 50%;} 100% {background-position: 100% 50%;} }
@keyframes shimmer { 0% {opacity: .1;} 50% {opacity: .45;} 100% {opacity: .1;} }

.progress-meta { display:flex; justify-content:space-between; align-items:center; margin-top:8px; font-size:12px; }
.progress-info { display:flex; justify-content:space-between; align-items:center; margin-top:6px; font-size:12px; }
.export-actions { margin-top: 12px; display:flex; justify-content:flex-end; }

/* Indeterminado (sem Content-Length) */
.export-overlay.indeterminate .progress-bar {
  width: 100%;
  background-image: repeating-linear-gradient(90deg,#64748b 0px,#64748b 10px,#94a3b8 10px,#94a3b8 20px);
  animation: stripes 1s linear infinite;
}
@keyframes stripes { 0% {background-position: 0 0;} 100% {background-position: 40px 0;} }

/* Confetti */
.confetti-piece {
  position: fixed; top: -10px;
  width: 8px; height: 14px; opacity: 0.9; z-index: 3000;
  animation: confettiFall 2.2s ease-out forwards, confettiSpin 1.6s ease-in-out infinite;
  will-change: transform, opacity;
  border-radius: 2px;
}
@keyframes confettiFall {
  0% { transform: translateY(-20px); opacity: 0.9; }
  100% { transform: translateY(100vh); opacity: 0; }
}
@keyframes confettiSpin {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(180deg); }
  100% { transform: rotate(360deg); }
}

/* mantém os estilos anteriores da página */
/* Hover verde escuro para os botões de exportação */
.export-btn { align-self:flex-start; }
.export-btn:hover {
  background-color: #14532d !important;
  border-color: #14532d !important;
  color: #ffffff !important;
}

/* Chips KPIs */
.chips { display:flex; gap:10px; margin: 10px 0 16px; }
.chip { display: inline-flex; align-items: center; gap: 0.5rem; border-radius: 9999px; padding: 0.35rem 0.75rem; font-size: 0.875rem; font-weight: 600; line-height: 1; }
.chip-danger { background: #fdecea; color: #b23c2a; border: 1px solid #f5c2c7; }
.chip-warning { background: #fff4e5; color: #a15c00; border: 1px solid #ffd8a8; }
.chip-info { background: #e7f5ff; color: #1c7ed6; border: 1px solid #a5d8ff; }
.chip-success { background: #ecfdf5; color: #065f46; border: 1px solid #10b981; }
.chip-title { font-size:12px; color:#64748b; margin-bottom:6px; }
.chip-value { font-size:22px; font-weight:800; color:#0f172a; }

/* Ajuda abaixo do chip fica discreta */
.form-text.text-muted.small { color: #6c757d !important; font-size: 0.82rem; }

/* Tabela */
.table-wrapper { max-height: 60vh; overflow: auto; border-radius: 8px; background: #fff; border:1px solid #e5e7eb; }
table { border-collapse:collapse; width:100%; }
th, td { border-bottom:1px solid #e5e7eb; padding:10px; text-align:left; font-size:13px; vertical-align: middle; }
th { background:#f1f5f9; color:#0f172a; position: sticky; top: 0; background: #eef2f7; z-index: 1; }
/* Sem quebra de linha (nowrap) na tabela da listagem */
.table-nowrap th, .table-nowrap td { white-space: nowrap; }

/* Paginação */
.pagination { display:flex; justify-content:space-between; align-items:center; margin-top:10px; }
.page-links .btn { margin-left:8px; }

/* Splash (Home) — estilo moderno SaaS */
.splash-hero h1 {
    font-weight: 500;
    letter-spacing: 0.2px;
    color: #0f172a; /* slate-900 */
}
.splash-hero p {
    max-width: 720px;
    margin: 0 auto;
}

/* Splash: impedir links clicáveis nos chips de status */
.splash-chips a {
  pointer-events: none;
  text-decoration: none !important;
  color: inherit;
}
.splash-chips .chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    font-weight: 500;
    font-size: 0.95rem;
    border: 1px solid #cbd5e1; /* slate-300 */
    background: #fff;
    color: #0f172a;
}
.splash-chips .chip--primary {
    background: #ecfdf5;       /* green-50 */
    border-color: #10b981;     /* green-500 */
    color: #064e3b;            /* green-900 */
}
.splash-chips .chip--secondary {
    background: #eff6ff;       /* blue-50 */
    border-color: #3b82f6;     /* blue-500 */
    color: #1e3a8a;            /* blue-900 */
}

.card.splash-card {
    border: 1px solid #e2e8f0; /* slate-200 */
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card.splash-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}
.card .card-title .card-icon {
    font-size: 1.1rem;
    margin-right: 0.35rem;
    vertical-align: middle;
}

.splash-footer {
    border-top: 1px solid #e2e8f0; /* linha fina */
}

.has-splash-footer main.container {
  padding-bottom: 96px;
}
.has-splash-footer .splash-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1500;
  margin: 0 !important;
  padding: 14px 16px 12px 16px;
  background: rgba(248, 250, 252, 0.9);
  border-top: 0;
  backdrop-filter: saturate(160%) blur(10px);
  box-shadow: 0 -10px 30px rgba(2, 6, 23, 0.08);
}
.has-splash-footer .splash-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background-image: linear-gradient(90deg,#6d28d9,#2563eb,#14b8a6,#f59e0b,#ef4444);
  background-size: 300% 100%;
  animation: galaxyShift 1.3s linear infinite;
  box-shadow: 0 0 8px rgba(37,99,235,0.35);
}
.has-splash-footer .splash-footer > * {
  position: relative;
}
.has-splash-footer .splash-footer .splash-chips {
  max-width: 1140px;
  margin-left: auto;
  margin-right: auto;
  padding-top: 2px;
}

/* Página (Maps) — estilo moderno SaaS */
.page-hero h1 {
  font-weight: 500;
  letter-spacing: 0.2px;
  color: #0f172a; /* slate-900 */
}
.page-hero p {
  max-width: 780px;
  margin: 0 auto;
}

.page-chips .chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
  border: 1px solid #cbd5e1; /* slate-300 */
  background: #fff;
  color: #0f172a;
}
.page-chips .chip--primary {
  background: #ecfdf5;       /* green-50 */
  border-color: #10b981;     /* green-500 */
  color: #064e3b;            /* green-900 */
}
.page-chips .chip--secondary {
  background: #eff6ff;       /* blue-50 */
  border-color: #3b82f6;     /* blue-500 */
  color: #1e3a8a;            /* blue-900 */
}

.card.page-card {
  border: 1px solid #e2e8f0; /* slate-200 */
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card.page-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

/* Animações */
.fade-in {
    animation: fadeIn 0.4s ease both;
}
.rise-in {
    animation: riseIn 0.4s ease both;
}
.fx-fade-in {
  animation: fxFadeIn 0.4s ease both;
}
.fx-rise-in {
  animation: fxRiseIn 0.4s ease both;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes riseIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fxFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes fxRiseIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Chip input */
.chip-input { display:block; border:1px solid #cbd5e1; border-radius: .5rem; background:#fff; padding:8px; }
.chip-input-chips { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:6px; }
.chip-input-chips .chip { background:#ecfdf5; border:1px solid #10b981; color:#065f46; border-radius:999px; padding:6px 10px; font-size:12px; }
.chip-close { border:none; background:transparent; color:#064e3b; margin-left:6px; cursor:pointer; font-weight:bold; }

/* Dicas */
.tips { margin-top:14px; }
.tips h4 { margin:0 0 6px 0; font-size:14px; color:#334155; }
.tips ul { margin:0; padding-left:18px; color:#475569; font-size:13px; }

/* Overlay de carregamento global */
#loadingOverlay.overlay {
    position: fixed;
    inset: 0;
    display: none; /* controlado via JS: 'flex' para mostrar */
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(3px);
}
#loadingOverlay.overlay.overlay--light { background: rgba(255,255,255,0.82); }
#loadingOverlay.overlay.overlay--dark  { background: rgba(0,0,0,0.55); }
.overlay__content { text-align: center; animation: fadeIn 0.2s ease-out; }

/* Títulos com gradiente “chique” */
.overlay__title {
  margin-top: 6px;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.3;
  background: linear-gradient(90deg, #0d6efd, #6f42c1 60%, #0d6efd);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: luxShine 2.2s linear infinite;
}
.overlay__subtitle {
  margin-top: 6px;
  font-weight: 500;
  font-size: 14px;
  color: #475569;
}

/* Pills brancos para mensagens de overlay (mais legíveis sobre fundos) */
.overlay__pill {
  display: inline-block;
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 12px;
  background: #ffffff;
  color: #0f172a;
  font-weight: 600;
  font-size: 16px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  border: 1px solid rgba(2,6,23,0.08);
}
.overlay__pill--small {
  font-weight: 500;
  font-size: 13px;
  color: #334155;
  padding: 6px 10px;
  border-radius: 10px;
}

/* Container “lux” com leve glassmorphism */
.lux-loader {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 18px 20px;
  background: rgba(255,255,255,0.55);
  border-radius: 16px;
  border: 1px solid rgba(13,110,253,0.15);
  box-shadow: 0 10px 30px rgba(13,110,253,0.12);
}
.overlay--dark .lux-loader {
  background: rgba(0,0,0,0.35);
  border-color: rgba(255,255,255,0.18);
}

/* override: cartão realmente branco no login (tema branco) */
.overlay.overlay--white .lux-loader {
  background: #ffffff !important;
  border: 1px solid #e2e8f0;
}

/* Ícone + orbe animado */
.lux-icon {
  position: relative;
  display: grid;
  place-items: center;
  width: 110px;
  height: 110px;
}
.lux-orb {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: conic-gradient(from 0deg, #0d6efd, #6f42c1, #0d6efd);
  filter: blur(12px) saturate(120%);
  opacity: 0.35;
  animation: luxRotate 2.4s linear infinite;
}

/* Barra de progresso com brilho */
.lux-progress {
  position: relative;
  width: 220px;
  height: 6px;
  border-radius: 999px;
  background: rgba(13,110,253,0.15);
  overflow: hidden;
}
.lux-progress--light { background: rgba(13,110,253,0.10); }
.lux-progress .bar {
  display: block;
  width: 50%;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(13,110,253,0.0), #0d6efd, #6f42c1, rgba(13,110,253,0.0));
  background-size: 200% 100%;
  animation: luxSlide 1.2s ease-in-out infinite;
}

/* SVG do banco com “scanner” já existe (.db-icon .scan) */
/* Deixamos como está, apenas usamos no HTML novo */

/* Keyframes */
@keyframes luxRotate { from { transform: rotate(0); } to { transform: rotate(360deg); } }
@keyframes luxSlide { 0% { transform: translateX(-60%); } 50% { transform: translateX(10%); } 100% { transform: translateX(110%); } }
@keyframes luxShine {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

/* Spinner “ring” já existente */
.lds-ring {
    display: inline-block;
    position: relative;
    width: 64px;
    height: 64px;
}
.lds-ring div {
    box-sizing: border-box;
    display: block;
    position: absolute;
    width: 64px;
    height: 64px;
    margin: 8px;
    border: 8px solid #0d6efd;
    border-radius: 50%;
    animation: lds-ring 1s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    border-color: #0d6efd transparent transparent transparent;
}
.lds-ring div:nth-child(1) { animation-delay: -0.45s; }
.lds-ring div:nth-child(2) { animation-delay: -0.3s; }
.lds-ring div:nth-child(3) { animation-delay: -0.15s; }

/* Spinner "ring" grande */
.lds-ring-lg { width: 96px; height: 96px; }
.lds-ring-lg div {
    width: 96px;
    height: 96px;
    margin: 10px;
    border: 10px solid #0d6efd;
    border-radius: 50%;
    animation: lds-ring 1s cubic-bezier(0.5, 0, 0.5, 1) infinite;
    border-color: #0d6efd transparent transparent transparent;
}

/* Loader "database" (SVG animado) */
.db-icon { width: 84px; height: 84px; }
.db-icon .scan { transform-origin: 32px 32px; animation: dbScan 1.6s ease-in-out infinite; }
@keyframes dbScan {
  0%   { transform: translate(-6px,-5px) scale(1); opacity: .9; }
  50%  { transform: translate(6px,5px)  scale(1.06); opacity: 1; }
  100% { transform: translate(-6px,-5px) scale(1); opacity: .9; }
}

@keyframes lds-ring {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(2px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Badge chip (aprimora o visual existente) */
.badge.rounded-pill {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
}

/* Overlay global e estilos existentes */
/* Escopo só para o overlay: evita interferir na página inteira */
#loadingOverlay .pong-wrap {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
}

/* Campo do Pong */
#loadingOverlay .field {
  position: relative;
  width: 200px;
  height: 130px;
  margin: 0 auto 4px auto;
  border: 3px solid #ffffff;
  border-radius: 8px;
  background: #000000;
  box-shadow: inset 0 0 22px rgba(255,255,255,0.06);
}

/* Rede pontilhada central */
#loadingOverlay .net {
  position: absolute;
  top: 2.5%;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 95%;
  border-left: 3px dotted #ffffff;
  opacity: .85;
}

/* Raquetes */
#loadingOverlay .ping,
#loadingOverlay .pong {
  position: absolute;
  width: 4px;
  height: 16px;
  background: #ffffff;
  box-shadow: 0 0 8px rgba(255,255,255,.55);
  border-radius: 2px;
}

#loadingOverlay .ping { left: 6%; animation: ping 6s infinite linear; }
#loadingOverlay .pong { right: 6%; animation: pong 6s infinite linear; }

/* Bola */
#loadingOverlay .ball {
  position: absolute;
  width: 5px;
  height: 5px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(255,255,255,.55);
  animation: ball 6s infinite linear;
}

/* Keyframes do Pong — iguais ao exemplo */
@keyframes ball {
  0%   { top: 34%; left: 52%; }         /* centro */
  8.3% { top: 52%; left: 90%; }         /* direita */
  24.9%{ top: 85%; left: 8%;  }         /* esquerda */
  30%  { top: 98%; left: 27%; }
  41.5%{ top: 70%; left: 90%; }         /* direita */
  58.1%{ top: 55%; left: 8%;  }         /* esquerda */
  74.7%{ top: 13%; left: 90%; }         /* direita */
  79%  { top: 1%;  left: 70%; }
  91.3%{ top: 22%; left: 8%;  }         /* esquerda */
  100% { top: 34%; left: 52%; }         /* volta ao centro */
}

@keyframes ping {        /* raquete esquerda */
  0%   { top: 10%; }
  5%   { top: 10%; }
  9%   { top: 24%; }
  13%  { top: 17%; }
  24.9%{ top: 82%; }     /* contato */
  47%  { top: 37%; }
  52%  { top: 41%; }
  56%  { top: 64%; }
  58.1%{ top: 54%; }     /* contato */
  70%  { top: 74%; }
  84%  { top: 12%; }
  91.3%{ top: 18%; }     /* contato */
  100% { top: 10%; }
}

@keyframes pong {        /* raquete direita */
  0%   { top: 90%; }
  8.3% { top: 51%; }     /* contato */
  20%  { top: 60%; }
  25%  { top: 34%; }
  41.5%{ top: 68%; }     /* contato */
  46%  { top: 36%; }
  52%  { top: 18%; }
  58.1%{ top: 53%; }
  66%  { top: 14%; }
  70%  { top: 20%; }
  74.7%{ top: 10%; }
  91.3%{ top: 10%; }     /* contato */
  100% { top: 90%; }
}

/* Mantém os estilos dos títulos e barra abaixo já existentes */
.overlay__title {
  margin-top: 6px;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.3;
  background: linear-gradient(90deg, #0d6efd, #6f42c1 60%, #0d6efd);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: luxShine 2.2s linear infinite;
}
.overlay__subtitle {
  margin-top: 6px;
  font-weight: 500;
  font-size: 14px;
  color: #475569;
}

/* Placar minimalista (animado, estilo demo) */
#loadingOverlay .scoreboard {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  color: #fff;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.35));
}
#loadingOverlay .scoreboard .side { display: flex; gap: 4px; }
#loadingOverlay .scoreboard .sep { opacity: .85; font-weight: 700; }
#loadingOverlay .digit {
  width: 12px;
  height: 16px;
  overflow: hidden;
  border-radius: 2px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.25);
}
#loadingOverlay .digit span {
  display: block;
  width: 100%;
  height: 16px;
  line-height: 16px;
  text-align: center;
  font-size: 12px;
  color: #fff;
}
@keyframes scrollDigits {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-160px); } /* 10 * 16px */
}
#loadingOverlay .digit--a1 { animation: scrollDigits 8s steps(10) infinite; }
#loadingOverlay .digit--a2 { animation: scrollDigits 10s steps(10) infinite; }
#loadingOverlay .digit--b1 { animation: scrollDigits 9s steps(10) infinite reverse; }
#loadingOverlay .digit--b2 { animation: scrollDigits 11s steps(10) infinite reverse; }

/* Glow leve nas “colisões” da bola */
@keyframes ballPulse {
  0%, 6%, 12%, 20%, 28%, 36%, 44%, 52%, 60%, 68%, 76%, 84%, 92%, 100% { box-shadow: 0 0 8px rgba(255,255,255,.55); }
  8.3%, 24.9%, 41.5%, 58.1%, 74.7%, 91.3% { box-shadow: 0 0 14px rgba(255,255,255,.95); }
}
#loadingOverlay .ball { animation: ball 6s infinite linear, ballPulse 6s infinite linear; }

/* Glow breve nas raquetes */
@keyframes paddleGlow {
  0%, 100% { box-shadow: 0 0 8px rgba(255,255,255,.55); }
  8.3%, 41.5%, 74.7%, 91.3% { box-shadow: 0 0 12px rgba(255,255,255,.9); }
}
#loadingOverlay .ping,
#loadingOverlay .pong { animation-name: ping, paddleGlow; animation-duration: 6s, 6s; animation-iteration-count: infinite; animation-timing-function: linear, linear; }

/* Respeita “prefers-reduced-motion” (animações mais sutis) */
@media (prefers-reduced-motion: reduce) {
  #loadingOverlay .ping,
  #loadingOverlay .pong,
  #loadingOverlay .ball { animation-duration: 12s !important; }
  #loadingOverlay .digit--a1,
  #loadingOverlay .digit--a2,
  #loadingOverlay .digit--b1,
  #loadingOverlay .digit--b2 { animation-duration: 18s !important; }
}

/* Título e subtítulo com fundo branco quando overlay estiver em modo dark (Pong) */
#loadingOverlay.overlay.overlay--dark .overlay__title {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;                  /* texto escuro */
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
  /* desfaz o gradiente anterior */
  -webkit-background-clip: initial;
  background-clip: initial;
  animation: none;
}

#loadingOverlay.overlay.overlay--dark .overlay__subtitle {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 10px;
  background: rgba(255,255,255,0.95);
  color: #0f172a;
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
  margin-top: 6px;
}

/* Pílula branca para o texto em overlays escuros (export e busca) */
#loadingOverlay.overlay.overlay--dark .overlay__text,
.export-overlay.dark .overlay__text {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}

/* Fallback: se estiver no overlay claro, ainda fica legível */
#loadingOverlay.overlay.overlay--light .overlay__text {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
}

/* Botão verde clarinho “mint” */
.btn-mint {
  --bs-btn-color: #0f172a;
  --bs-btn-bg: #a8f0c6;
  --bs-btn-border-color: #9deabf;
  --bs-btn-hover-color: #0f172a;
  --bs-btn-hover-bg: #93e8b6;
  --bs-btn-hover-border-color: #88e3af;
  --bs-btn-focus-shadow-rgb: 16, 185, 129;
  --bs-btn-active-color: #0f172a;
  --bs-btn-active-bg: #84e0ac;
  --bs-btn-active-border-color: #7bdca6;
  --bs-btn-disabled-color: #55616d;
  --bs-btn-disabled-bg: #d9f7e9;
  --bs-btn-disabled-border-color: #c9f2df;

  background-color: var(--bs-btn-bg);
  border-color: var(--bs-btn-border-color);
  color: var(--bs-btn-color);
}
.btn-mint:hover {
  background-color: var(--bs-btn-hover-bg);
  border-color: var(--bs-btn-hover-border-color);
  color: var(--bs-btn-hover-color);
}
.btn-mint:focus {
  box-shadow: 0 0 0 .25rem rgba(16,185,129,.25);
  color: var(--bs-btn-color);
}
.btn-mint:active {
  background-color: var(--bs-btn-active-bg);
  border-color: var(--bs-btn-active-border-color);
  color: var(--bs-btn-active-color);
}
/* Mobile: ocupa toda a largura */
@media (max-width: 576px) {
  .btn-mint { width: 100%; }
}

/* Força a cor institucional dos botões dos cards (sem ser sobrescrito) */
.btn.btn-brand {
  background-color: #10b981 !important;   /* verde institucional */
  border-color: #10b981 !important;
  color: #fff !important;
}
.btn.btn-brand:hover {
  background-color: #15803d !important;   /* verde mais escuro no hover */
  border-color: #15803d !important;
  color: #fff !important;
}

/* Brilho verde e leve “lift” nos cards da home (grid de cards) */
.row.g-3 .card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform .2s ease, box-shadow .2s ease;
}
.row.g-3 .card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(16,185,129,.25), 0 4px 12px rgba(0,0,0,.08); /* brilho verde */
}
.card .card-title .card-icon {
    font-size: 1.1rem;
    margin-right: 0.35rem;
    vertical-align: middle;
}

.splash-footer {
    border-top: 1px solid #e2e8f0; /* linha fina */
}

/* Página (Maps) — estilo moderno SaaS */
.page-hero h1 {
  font-weight: 500;
  letter-spacing: 0.2px;
  color: #0f172a; /* slate-900 */
}
.page-hero p {
  max-width: 780px;
  margin: 0 auto;
}

.page-chips .chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
  border: 1px solid #cbd5e1; /* slate-300 */
  background: #fff;
  color: #0f172a;
}
.page-chips .chip--primary {
  background: #ecfdf5;       /* green-50 */
  border-color: #10b981;     /* green-500 */
  color: #064e3b;            /* green-900 */
}
.page-chips .chip--secondary {
  background: #eff6ff;       /* blue-50 */
  border-color: #3b82f6;     /* blue-500 */
  color: #1e3a8a;            /* blue-900 */
}

.card.page-card {
  border: 1px solid #e2e8f0; /* slate-200 */
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card.page-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

/* Animações */
.fade-in {
    animation: fadeIn 0.4s ease both;
}
.rise-in {
    animation: riseIn 0.4s ease both;
}
.fx-fade-in {
  animation: fxFadeIn 0.4s ease both;
}
.fx-rise-in {
  animation: fxRiseIn 0.4s ease both;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes riseIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fxFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes fxRiseIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Chip input */
.chip-input { display:block; border:1px solid #cbd5e1; border-radius: .5rem; background:#fff; padding:8px; }
.chip-input-chips { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:6px; }
.chip-input-chips .chip { background:#ecfdf5; border:1px solid #10b981; color:#065f46; border-radius:999px; padding:6px 10px; font-size:12px; }
.chip-close { border:none; background:transparent; color:#064e3b; margin-left:6px; cursor:pointer; font-weight:bold; }

/* Dicas */
.tips { margin-top:14px; }
.tips h4 { margin:0 0 6px 0; font-size:14px; color:#334155; }
.tips ul { margin:0; padding-left:18px; color:#475569; font-size:13px; }

/* Overlay de carregamento global */
#loadingOverlay.overlay {
    position: fixed;
    inset: 0;
    display: none; /* controlado via JS: 'flex' para mostrar */
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(3px);
}
#loadingOverlay.overlay.overlay--light { background: rgba(255,255,255,0.82); }
#loadingOverlay.overlay.overlay--dark  { background: rgba(0,0,0,0.55); }
.overlay__content { text-align: center; animation: fadeIn 0.2s ease-out; }

/* Títulos com gradiente “chique” */
.overlay__title {
  margin-top: 6px;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.3;
  background: linear-gradient(90deg, #0d6efd, #6f42c1 60%, #0d6efd);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: luxShine 2.2s linear infinite;
}
.overlay__subtitle {
  margin-top: 6px;
  font-weight: 500;
  font-size: 14px;
  color: #475569;
}

/* Placar minimalista (animado, estilo demo) */
#loadingOverlay .scoreboard {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  color: #fff;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.35));
}
#loadingOverlay .scoreboard .side { display: flex; gap: 4px; }
#loadingOverlay .scoreboard .sep { opacity: .85; font-weight: 700; }
#loadingOverlay .digit {
  width: 12px;
  height: 16px;
  overflow: hidden;
  border-radius: 2px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.25);
}
#loadingOverlay .digit span {
  display: block;
  width: 100%;
  height: 16px;
  line-height: 16px;
  text-align: center;
  font-size: 12px;
  color: #fff;
}
@keyframes scrollDigits {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-160px); } /* 10 * 16px */
}
#loadingOverlay .digit--a1 { animation: scrollDigits 8s steps(10) infinite; }
#loadingOverlay .digit--a2 { animation: scrollDigits 10s steps(10) infinite; }
#loadingOverlay .digit--b1 { animation: scrollDigits 9s steps(10) infinite reverse; }
#loadingOverlay .digit--b2 { animation: scrollDigits 11s steps(10) infinite reverse; }

/* Glow leve nas “colisões” da bola */
@keyframes ballPulse {
  0%, 6%, 12%, 20%, 28%, 36%, 44%, 52%, 60%, 68%, 76%, 84%, 92%, 100% { box-shadow: 0 0 8px rgba(255,255,255,.55); }
  8.3%, 24.9%, 41.5%, 58.1%, 74.7%, 91.3% { box-shadow: 0 0 14px rgba(255,255,255,.95); }
}
#loadingOverlay .ball { animation: ball 6s infinite linear, ballPulse 6s infinite linear; }

/* Glow breve nas raquetes */
@keyframes paddleGlow {
  0%, 100% { box-shadow: 0 0 8px rgba(255,255,255,.55); }
  8.3%, 41.5%, 74.7%, 91.3% { box-shadow: 0 0 12px rgba(255,255,255,.9); }
}
#loadingOverlay .ping,
#loadingOverlay .pong { animation-name: ping, paddleGlow; animation-duration: 6s, 6s; animation-iteration-count: infinite; animation-timing-function: linear, linear; }

/* Respeita “prefers-reduced-motion” (animações mais sutis) */
@media (prefers-reduced-motion: reduce) {
  #loadingOverlay .ping,
  #loadingOverlay .pong,
  #loadingOverlay .ball { animation-duration: 12s !important; }
  #loadingOverlay .digit--a1,
  #loadingOverlay .digit--a2,
  #loadingOverlay .digit--b1,
  #loadingOverlay .digit--b2 { animation-duration: 18s !important; }
}

/* Título e subtítulo com fundo branco quando overlay estiver em modo dark (Pong) */
#loadingOverlay.overlay.overlay--dark .overlay__title {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;                  /* texto escuro */
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
  /* desfaz o gradiente anterior */
  -webkit-background-clip: initial;
  background-clip: initial;
  animation: none;
}

#loadingOverlay.overlay.overlay--dark .overlay__subtitle {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 10px;
  background: rgba(255,255,255,0.95);
  color: #0f172a;
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
  margin-top: 6px;
}

/* Pílula branca para o texto em overlays escuros (export e busca) */
#loadingOverlay.overlay.overlay--dark .overlay__text,
.export-overlay.dark .overlay__text {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}

/* Fallback: se estiver no overlay claro, ainda fica legível */
#loadingOverlay.overlay.overlay--light .overlay__text {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 10px;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 3px 10px rgba(0,0,0,0.12);
}

/* Botão verde clarinho “mint” */
.btn-mint {
  --bs-btn-color: #0f172a;
  --bs-btn-bg: #a8f0c6;
  --bs-btn-border-color: #9deabf;
  --bs-btn-hover-color: #0f172a;
  --bs-btn-hover-bg: #93e8b6;
  --bs-btn-hover-border-color: #88e3af;
  --bs-btn-focus-shadow-rgb: 16, 185, 129;
  --bs-btn-active-color: #0f172a;
  --bs-btn-active-bg: #84e0ac;
  --bs-btn-active-border-color: #7bdca6;
  --bs-btn-disabled-color: #55616d;
  --bs-btn-disabled-bg: #d9f7e9;
  --bs-btn-disabled-border-color: #c9f2df;

  background-color: var(--bs-btn-bg);
  border-color: var(--bs-btn-border-color);
  color: var(--bs-btn-color);
}
.btn-mint:hover {
  background-color: var(--bs-btn-hover-bg);
  border-color: var(--bs-btn-hover-border-color);
  color: var(--bs-btn-hover-color);
}
.btn-mint:focus {
  box-shadow: 0 0 0 .25rem rgba(16,185,129,.25);
  color: var(--bs-btn-color);
}
.btn-mint:active {
  background-color: var(--bs-btn-active-bg);
  border-color: var(--bs-btn-active-border-color);
  color: var(--bs-btn-active-color);
}
/* Mobile: ocupa toda a largura */
@media (max-width: 576px) {
  .btn-mint { width: 100%; }
}

/* Glow verde e leve lift nos cards da home (radial hover) */
.row.g-3 .card {
  position: relative;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.row.g-3 .card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(16,185,129,.25), 0 4px 12px rgba(0,0,0,.08);
  border-color: rgba(16,185,129,.45);
}
/* Camada de brilho suave (radial), aparece no hover */
.row.g-3 .card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    600px circle at var(--x, 50%) var(--y, 50%),
    rgba(16,185,129,.18),
    rgba(16,185,129,0) 40%
  );
  pointer-events: none;
  opacity: 0;
  transition: opacity .15s ease;
}
.row.g-3 .card:hover::before {
  opacity: 1;
}

/* Transições do overlay global */
#loadingOverlay {
  opacity: 0;
  transition: opacity 220ms ease;
}
#loadingOverlay.overlay-fade-in { opacity: 1; }
#loadingOverlay.overlay-fade-out { opacity: 0; }

/* Glow suave no menu (lanterninha que segue o mouse apenas na navbar) */
.navbar .nav-link {
  position: relative;
  overflow: hidden; /* garante que o brilho não vaze */
}
.navbar .nav-link::before {
  content: "";
  position: absolute;
  inset: 0;
  /* radial em torno do ponteiro: usa variáveis CSS atualizadas via JS */
  background: radial-gradient(
    200px circle at var(--mx, 50%) var(--my, 50%),
    rgba(34, 197, 94, 0.22),       /* verde suave (glow) */
    rgba(34, 197, 94, 0) 42%
  );
  opacity: 0;
  transition: opacity .12s ease;
  pointer-events: none; /* não interfere no clique dos links */
}
.navbar .nav-link:hover::before,
.navbar .nav-link:focus::before {
  opacity: 1;
}

/* Overlay brand: gradiente verde + rosinha com leve glow */
.overlay.overlay--brand {
  position: fixed;
  inset: 0;
  display: none;               /* controlada via JS */
  align-items: center;
  justify-content: center;
  z-index: 2000;
  color: #fff;
  background:
    radial-gradient(1200px 600px at 50% 40%, rgba(255, 105, 180, 0.20), rgba(22, 163, 74, 0.10), rgba(59, 130, 246, 0.10)),
    linear-gradient(135deg, #0b1220 0%, #0f172a 100%);
}
.overlay.overlay--brand::before {
  content: "";
  position: absolute;
  inset: 0;
  background: conic-gradient(from 0deg, rgba(255,105,180,0.08), rgba(59,130,246,0.08), rgba(22,163,74,0.08), rgba(255,105,180,0.08));
  animation: swirl 18s linear infinite;
  filter: blur(12px);
}
@keyframes swirl { to { transform: rotate(360deg); } }

.overlay__content { position: relative; z-index: 1; text-align: center; }

/* Loader com orb girando (borda com gradiente) */
.brand-loader { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.brand-orb {
  width: 90px;
  height: 90px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 40% 35%, rgba(255,255,255,0.18) 0, rgba(255,255,255,0.02) 60%),
    conic-gradient(#10b981, #60a5fa, #ff66cc, #10b981);
  -webkit-mask: radial-gradient(#000 62px, transparent 64px);
  mask: radial-gradient(#000 62px, transparent 64px);
  animation: orbSpin 2.1s linear infinite;
  box-shadow: 0 0 18px rgba(255, 102, 204, 0.35), 0 0 26px rgba(16, 185, 129, 0.25);
}
@keyframes orbSpin { to { transform: rotate(360deg); } }

.brand-title {
  font-family: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: 0.3px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.35);
}
.brand-sub {
  font-size: 0.98rem;
  opacity: 0.92;
  color: #e6fdf5;
}

/* Mantém o layout antigo se o overlay light for usado em páginas antigas */
.overlay.overlay--light { background: rgba(2,6,23,0.6); }

/* Toast no canto: loader não bloqueante */
.overlay.overlay--toast {
  position: fixed;
  bottom: 16px;
  right: 16px;
  display: none;              /* controlado via JS */
  align-items: center;
  justify-content: center;
  pointer-events: none;       /* não bloqueia cliques na página */
  z-index: 2000;
}
.overlay.overlay--toast .overlay__content {
  background: rgba(15, 23, 42, 0.75);         /* slate-900 translúcido */
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e6fdf5;
  border-radius: 12px;
  padding: 10px 14px;
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.45);
  backdrop-filter: saturate(140%) blur(8px);
}
.toast-loader { display: flex; align-items: center; }
.toast-title { font-weight: 600; line-height: 1.1; }
.toast-sub { font-size: 0.86rem; opacity: 0.9; }

/* Modo tela cheia: usado só pelo login */
.overlay.overlay--full {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  background: rgba(2, 6, 23, 0.6);
  pointer-events: auto;       /* bloqueia durante login */
}
.overlay.overlay--full .overlay__content {
  background: transparent;    /* login injeta seu loader próprio */
  border: 0;
  padding: 0;
  box-shadow: none;
  backdrop-filter: none;
}

/* Fundo branco para o login (override do full) */
.overlay.overlay--white {
  /* antes pintava a tela inteira de branco; deixamos transparente
     para manter o escurecimento suave do overlay padrão */
  background: transparent;
  color: #0f172a;
}
.overlay.overlay--white .overlay__content { color: #0f172a; }
/* título sólido (sem gradiente/shine) no tema branco */
.overlay.overlay--white .overlay__title {
  background: none;
  -webkit-background-clip: initial;
  background-clip: initial;
  color: #0f172a;
  animation: none;
}
.overlay.overlay--white .overlay__subtitle { color: #334155; }

/* Card branco central só no login (full + white) */
.overlay.overlay--full.overlay--white {
  background: #ffffff !important;  /* fundo da tela branco no login */
  color: #0f172a;
}
.overlay.overlay--full.overlay--white .overlay__content {
  background: #ffffff;
  border: 1px solid #e2e8f0;      /* slate-200 */
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: 0 20px 40px rgba(2,6,23,0.18), 0 6px 20px rgba(2,6,23,0.12);
  min-width: 280px;
  max-width: 380px;
}

/* Spinner e barra no tema branco */
.overlay.overlay--white .lds-ring div {
  border-color: #16a34a transparent transparent transparent;
}
.overlay.overlay--white .lux-progress .bar {
  background: linear-gradient(90deg, #16a34a, #22c55e);
}
/* Footer bonito verde para status na página inicial */
.footer-status { display:flex; justify-content:center; align-items:center; flex-wrap:wrap; gap:10px; padding:12px 16px; background:#ecfdf5; border-top:2px solid #10b981; color:#065f46; margin-top:24px; }
.footer-status a { color:#10b981; text-decoration:none; font-weight:600; }
.footer-status a:hover { text-decoration:underline; }

/* Splash: ocultar ícones flutuantes adicionados no template */
.floating-social-icons-wilmar { display: none !important; }
