/* ============================================================
   VIBRA RADAR — Urban Live Radar
   Sistema nervioso digital de la ciudad
   ============================================================ */

#vibra-radar-panel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: #000;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Inter', 'SF Pro Display', sans-serif;
}

/* ── Header ── */
.vr-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 10px;
  background: #050510;
  border-bottom: 1px solid rgba(0,255,150,0.15);
  flex-shrink: 0;
}

.vr-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.vr-title-icon {
  width: 32px;
  height: 32px;
  background: radial-gradient(circle, rgba(0,255,150,0.3), transparent);
  border: 1px solid rgba(0,255,150,0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  animation: vrIconPulse 2s ease-in-out infinite;
}

@keyframes vrIconPulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(0,255,150,0.3); }
  50% { box-shadow: 0 0 0 8px rgba(0,255,150,0); }
}

.vr-title h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: #00ff96;
  letter-spacing: 0.5px;
}

.vr-title span {
  font-size: 10px;
  color: rgba(0,255,150,0.6);
  letter-spacing: 2px;
  text-transform: uppercase;
  display: block;
}

.vr-close {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.vr-close:hover { background: rgba(255,255,255,0.18); }

/* ── City Stats Bar ── */
.vr-stats-bar {
  display: flex;
  gap: 0;
  padding: 10px 18px;
  background: #050510;
  border-bottom: 1px solid rgba(0,255,150,0.08);
  flex-shrink: 0;
  overflow-x: auto;
}

.vr-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 16px;
  border-right: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.vr-stat:last-child { border-right: none; }

.vr-stat-value {
  font-size: 20px;
  font-weight: 800;
  color: #00ff96;
  line-height: 1;
}

.vr-stat-label {
  font-size: 9px;
  color: rgba(255,255,255,0.45);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 3px;
}

/* ── Main Layout ── */
.vr-body {
  display: flex;
  flex: 1;
  overflow: hidden;
  gap: 0;
}

/* ── Radar Canvas ── */
.vr-radar-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  position: relative;
  background: radial-gradient(ellipse at center, #010815 0%, #000 100%);
}

#vr-radar-canvas {
  border-radius: 50%;
  cursor: crosshair;
}

/* ── Zone Filters ── */
.vr-filters {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(10px);
  padding: 8px 12px;
  border-radius: 30px;
  border: 1px solid rgba(255,255,255,0.1);
}

.vr-filter-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.6);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 11px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
  font-family: inherit;
}

.vr-filter-btn.active {
  background: rgba(0,255,150,0.15);
  border-color: rgba(0,255,150,0.5);
  color: #00ff96;
}

/* ── Tooltip ── */
.vr-tooltip {
  position: absolute;
  background: rgba(5,5,20,0.95);
  border: 1px solid rgba(0,255,150,0.4);
  border-radius: 10px;
  padding: 10px 14px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 10;
  min-width: 140px;
}

.vr-tooltip.visible { opacity: 1; }

.vr-tooltip-name {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 3px;
}

.vr-tooltip-type {
  font-size: 10px;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.vr-tooltip-energy {
  font-size: 12px;
  color: #00ff96;
  font-weight: 600;
}

/* ── Right Panel: Feed ── */
.vr-feed-panel {
  width: 220px;
  background: #050510;
  border-left: 1px solid rgba(0,255,150,0.12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex-shrink: 0;
}

.vr-feed-header {
  padding: 12px 14px 8px;
  font-size: 10px;
  color: rgba(0,255,150,0.7);
  text-transform: uppercase;
  letter-spacing: 2px;
  border-bottom: 1px solid rgba(0,255,150,0.08);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.vr-feed-dot {
  width: 6px;
  height: 6px;
  background: #00ff96;
  border-radius: 50%;
  animation: vrBlink 1s ease-in-out infinite;
}

@keyframes vrBlink {
  0%,100% { opacity: 1; }
  50% { opacity: 0.2; }
}

.vr-feed-list {
  flex: 1;
  overflow-y: auto;
  padding: 6px 0;
}

.vr-feed-list::-webkit-scrollbar { width: 3px; }
.vr-feed-list::-webkit-scrollbar-track { background: transparent; }
.vr-feed-list::-webkit-scrollbar-thumb { background: rgba(0,255,150,0.2); border-radius: 2px; }

.vr-feed-item {
  display: flex;
  gap: 10px;
  padding: 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  animation: vrFeedIn 0.4s ease-out;
  cursor: pointer;
  transition: background 0.2s;
}

.vr-feed-item:hover { background: rgba(0,255,150,0.04); }

@keyframes vrFeedIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.vr-feed-emoji {
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}

.vr-feed-content { flex: 1; min-width: 0; }

.vr-feed-zone {
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vr-feed-desc {
  font-size: 10px;
  color: rgba(255,255,255,0.45);
  margin-top: 2px;
  line-height: 1.3;
}

.vr-feed-time {
  font-size: 9px;
  color: rgba(0,255,150,0.5);
  margin-top: 3px;
}

/* ── NERHIA Urban Intelligence ── */
.vr-nerhia-box {
  padding: 10px 14px;
  background: rgba(0,255,150,0.04);
  border-top: 1px solid rgba(0,255,150,0.12);
  flex-shrink: 0;
}

.vr-nerhia-label {
  font-size: 9px;
  color: rgba(0,255,150,0.6);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 6px;
  font-weight: 600;
}

.vr-nerhia-msg {
  font-size: 11px;
  color: rgba(255,255,255,0.75);
  line-height: 1.5;
  font-style: italic;
}

/* ── Energy Meter (bottom of radar wrap) ── */
.vr-energy-bar {
  position: absolute;
  top: 16px;
  right: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.vr-energy-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 10px;
  color: rgba(255,255,255,0.6);
}

.vr-energy-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.vr-energy-track {
  width: 60px;
  height: 3px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  overflow: hidden;
}

.vr-energy-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 1s ease;
}

/* ── City Mode Selector ── */
.vr-city-select {
  position: absolute;
  top: 16px;
  left: 16px;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 6px 8px;
}

.vr-city-select select {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.8);
  font-size: 11px;
  font-family: inherit;
  cursor: pointer;
  outline: none;
}

.vr-city-select select option { background: #050510; color: #fff; }

/* ── Responsive ── */
@media (max-width: 500px) {
  .vr-feed-panel { width: 160px; }
  .vr-filter-btn { padding: 5px 8px; font-size: 10px; }
}
