/* style.css — Estilos adicionales para Panel Central */

/* ─── Animaciones ─────────────────────────────────────────────────────────── */
@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.animate-pulse-dot {
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.2s ease-out forwards;
}

/* ─── Tabs ────────────────────────────────────────────────────────────────── */
.tab-btn {
  transition: color 0.15s, border-color 0.15s;
  cursor: pointer;
  background: none;
  border: none;
  border-bottom-width: 2px;
}

.tab-btn.active {
  color: #60a5fa;
  border-bottom-color: #3b82f6;
}

/* ─── Gauge / Barra de progreso ───────────────────────────────────────────── */
.gauge-bar {
  height: 6px;
  border-radius: 9999px;
  background: #1f2937;
  overflow: hidden;
  position: relative;
}

.gauge-fill {
  height: 100%;
  border-radius: 9999px;
  transition: width 0.6s ease;
}

.gauge-fill.ok     { background: linear-gradient(90deg, #10b981, #34d399); }
.gauge-fill.warn   { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.gauge-fill.danger { background: linear-gradient(90deg, #ef4444, #f87171); }

/* ─── Status dots ─────────────────────────────────────────────────────────── */
.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-dot.online  { background: #22c55e; box-shadow: 0 0 6px #22c55e88; }
.status-dot.offline { background: #ef4444; }
.status-dot.unknown { background: #6b7280; }

/* ─── Node card ────────────────────────────────────────────────────────────── */
.node-card {
  cursor: pointer;
  transition: border-color 0.15s, transform 0.1s;
}

.node-card:hover {
  border-color: #4b5563;
  transform: translateY(-1px);
}

.node-card.online-card  { border-left: 3px solid #22c55e; }
.node-card.offline-card { border-left: 3px solid #ef4444; }

/* ─── Service pill ─────────────────────────────────────────────────────────── */
.svc-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 9999px;
  font-weight: 500;
}

.svc-pill.ok  { background: #14532d; color: #86efac; }
.svc-pill.err { background: #450a0a; color: #fca5a5; }
.svc-pill.unk { background: #1f2937; color: #9ca3af; }

/* ─── Scrollbar personalizado ─────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #111827; }
::-webkit-scrollbar-thumb { background: #374151; border-radius: 3px; }

/* ─── Acciones Rápidas & Botones ─────────────────────────────────────────── */
.quick-action-btn {
  cursor: pointer;
  user-select: none;
  transition: all 0.15s ease;
}
.quick-action-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.15);
}
.quick-action-btn:active {
  transform: translateY(0);
}

/* ─── Badges de Puertos ─────────────────────────────────────────────────── */
.port-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}
.port-web  { background: rgba(16, 185, 129, 0.15); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.3); }
.port-db   { background: rgba(245, 158, 11, 0.15); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.3); }
.port-ssh  { background: rgba(168, 85, 247, 0.15); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.3); }
.port-mesh { background: rgba(59, 130, 246, 0.15); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.3); }
.port-gen  { background: rgba(107, 114, 128, 0.15); color: #9ca3af; border: 1px solid rgba(107, 114, 128, 0.3); }

::-webkit-scrollbar-thumb:hover { background: #4b5563; }
