/* ═══════════════════════════════════════════════════════════════
   VIBRA ATLAS — Globo 3D interactivo · presencia global VibraWorld
   ═══════════════════════════════════════════════════════════════ */

/* ── Panel container ── */
#panel-atlas {
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at 50% 30%, #0a0520 0%, #020008 70%);
  display: none;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  z-index: 10;
}
#panel-atlas.active { display: flex; }

/* ── HUD top ── */
.va-hud {
  position: absolute;
  top: 56px;
  left: 0; right: 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 10px 16px 0;
  pointer-events: none;
  z-index: 20;
}

.va-hud-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.va-hud-title {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 1.1rem;
  font-weight: 900;
  color: #fff;
  letter-spacing: -.02em;
  text-shadow: 0 0 20px rgba(160,100,255,.8);
}

.va-hud-sub {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .65rem;
  color: rgba(180,140,255,.7);
  letter-spacing: .08em;
}

.va-hud-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  pointer-events: auto;
}

/* ── Stat pills ── */
.va-stats-row {
  position: absolute;
  top: 110px;
  left: 0; right: 0;
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 12px;
  z-index: 20;
  pointer-events: none;
  flex-wrap: wrap;
}

.va-stat-pill {
  background: rgba(120,60,220,.18);
  border: 1px solid rgba(160,100,255,.3);
  border-radius: 20px;
  padding: 4px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 58px;
}

.va-stat-val {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .75rem;
  font-weight: 700;
  color: #d4a8ff;
  line-height: 1.1;
}

.va-stat-label {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .5rem;
  color: rgba(200,170,255,.5);
  letter-spacing: .06em;
  text-transform: uppercase;
}

/* ── Canvas wrapper ── */
.va-canvas-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

#atlas-canvas {
  display: block;
  cursor: grab;
  touch-action: none;
}
#atlas-canvas:active { cursor: grabbing; }

/* ── City tooltip ── */
.va-tooltip {
  position: absolute;
  background: rgba(12, 4, 28, .92);
  border: 1px solid rgba(160,100,255,.5);
  border-radius: 10px;
  padding: 8px 12px;
  pointer-events: none;
  z-index: 50;
  min-width: 130px;
  backdrop-filter: blur(8px);
  transform: translate(-50%, calc(-100% - 14px));
  transition: opacity .15s;
}

.va-tooltip-name {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: .75rem;
  font-weight: 800;
  color: #e8d0ff;
  margin-bottom: 2px;
}

.va-tooltip-metrics {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.va-tooltip-metric {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .6rem;
  color: rgba(200,170,255,.75);
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.va-tooltip-metric span:last-child {
  color: #b088ff;
  font-weight: 700;
}

/* ── City detail panel ── */
.va-city-panel {
  position: absolute;
  bottom: 80px;
  left: 12px; right: 12px;
  background: rgba(10,3,24,.92);
  border: 1px solid rgba(160,100,255,.4);
  border-radius: 16px;
  padding: 14px 16px 16px;
  z-index: 30;
  backdrop-filter: blur(12px);
  transform: translateY(120%);
  transition: transform .35s cubic-bezier(.25,1,.4,1);
  max-height: 200px;
  overflow: hidden;
}

.va-city-panel.open {
  transform: translateY(0);
}

.va-city-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.va-city-panel-name {
  font-family: var(--sans, 'Syne', sans-serif);
  font-size: 1rem;
  font-weight: 900;
  color: #e8d0ff;
}

.va-city-panel-close {
  background: rgba(120,60,220,.2);
  border: 1px solid rgba(160,100,255,.3);
  border-radius: 50%;
  width: 26px; height: 26px;
  color: rgba(200,160,255,.8);
  font-size: .8rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}

.va-city-panel-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.va-city-panel-metric {
  background: rgba(120,60,220,.12);
  border: 1px solid rgba(160,100,255,.2);
  border-radius: 8px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.va-city-panel-metric-val {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .8rem;
  font-weight: 700;
  color: #c49aff;
}

.va-city-panel-metric-label {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .5rem;
  color: rgba(180,140,255,.5);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-top: 1px;
}

/* ── Filter tabs ── */
.va-filters {
  position: absolute;
  top: 160px;
  right: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 20;
}

.va-filter-btn {
  background: rgba(12,4,28,.7);
  border: 1px solid rgba(160,100,255,.25);
  border-radius: 20px;
  padding: 5px 10px;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .58rem;
  color: rgba(200,160,255,.6);
  cursor: pointer;
  transition: all .2s;
  text-align: center;
  white-space: nowrap;
}

.va-filter-btn.active,
.va-filter-btn:hover {
  background: rgba(120,60,220,.4);
  border-color: rgba(180,120,255,.7);
  color: #e0c8ff;
}

/* ── Rotation toggle ── */
.va-rotate-btn {
  position: absolute;
  top: 160px;
  left: 12px;
  background: rgba(12,4,28,.7);
  border: 1px solid rgba(160,100,255,.25);
  border-radius: 20px;
  padding: 5px 10px;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .58rem;
  color: rgba(200,160,255,.6);
  cursor: pointer;
  transition: all .2s;
  z-index: 20;
}

.va-rotate-btn.paused {
  border-color: rgba(255,100,100,.4);
  color: rgba(255,160,160,.7);
}

/* ── VBC flow ticker ── */
.va-ticker {
  position: absolute;
  bottom: 82px;
  left: 0; right: 0;
  height: 24px;
  overflow: hidden;
  background: rgba(0,0,0,.4);
  border-top: 1px solid rgba(120,60,220,.2);
  display: flex;
  align-items: center;
  z-index: 20;
}

.va-ticker-inner {
  display: flex;
  gap: 40px;
  animation: va-ticker-scroll 30s linear infinite;
  white-space: nowrap;
  padding-left: 100%;
}

.va-ticker-item {
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .6rem;
  color: rgba(180,140,255,.6);
  display: flex;
  align-items: center;
  gap: 6px;
}

.va-ticker-item .vt-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: #b088ff;
  flex-shrink: 0;
}

@keyframes va-ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ── Glow ring around globe ── */
.va-glow-ring {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 5;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  animation: va-ring-pulse 3s ease-in-out infinite;
}

@keyframes va-ring-pulse {
  0%, 100% { opacity: .3; transform: translate(-50%, -50%) scale(1); }
  50%       { opacity: .6; transform: translate(-50%, -50%) scale(1.03); }
}

/* ── Live arc counter ── */
.va-arc-counter {
  position: absolute;
  top: 56px;
  right: 16px;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .6rem;
  color: rgba(160,120,220,.6);
  pointer-events: none;
  z-index: 20;
  text-align: right;
}

.va-arc-counter strong {
  color: #b088ff;
  font-size: .75rem;
}

/* ── Legend ── */
.va-legend {
  position: absolute;
  bottom: 108px;
  left: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 20;
  pointer-events: none;
}

.va-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono, 'DM Mono', monospace);
  font-size: .58rem;
  color: rgba(180,140,255,.55);
}

.va-legend-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
