/* ═══════════════════════════════════════
   styles/cityPanel.css - Info Panel
   ═══════════════════════════════════════ */
#city-panel {
  position: absolute;
  top: 60px;
  right: 16px;
  width: 350px;
  max-height: calc(100vh - 100px);
  background: rgba(13, 15, 20, 0.96);
  border: 1px solid rgba(180, 160, 120, 0.2);
  border-radius: 6px;
  overflow: hidden;
  z-index: 1001;
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  display: none;
  animation: slideIn 0.3s ease;
}

#city-panel.open { display: block; }

.city-panel-header {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(180, 160, 120, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.city-panel-header .label {
  font-size: 10px;
  letter-spacing: 2px;
  color: rgba(192, 160, 48, 0.6);
  text-transform: uppercase;
}

.city-panel-header .city-name {
  font-size: 20px;
  color: var(--text-primary);
  margin-top: 2px;
}

#close-city-btn {
  width: 28px;
  height: 28px;
  background: rgba(180, 160, 120, 0.1);
  border: 1px solid var(--gold-faint);
  border-radius: 50%;
  color: var(--gold);
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  transition: background 0.2s;
}

#close-city-btn:hover { background: rgba(180, 160, 120, 0.2); }

#city-event-tabs {
  display: none;
  border-bottom: 1px solid var(--gold-ghost);
}

#city-event-tabs.visible { display: flex; }

.city-tab {
  flex: 1;
  padding: 10px 12px;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-ghost);
  cursor: pointer;
  font-size: 11px;
  font-family: var(--font-serif);
  text-align: center;
  transition: all 0.2s ease;
}

.city-tab.active {
  background: var(--gold-ghost);
  border-bottom-color: var(--gold);
  color: var(--gold-bright);
}

#city-event-content {
  padding: 20px;
  overflow-y: auto;
  max-height: 380px;
}

.event-image-container {
  width: 100%;
  height: 180px;
  background: linear-gradient(135deg, rgba(30, 35, 45, 1), rgba(20, 25, 35, 1));
  border-radius: 4px;
  margin-bottom: 16px;
  border: 1px solid var(--gold-ghost);
  position: relative;
  overflow: hidden;
}

.event-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.event-image-container img.loaded { opacity: 1; }

.event-image-container .img-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease;
}

.event-image-container .img-placeholder.hidden { opacity: 0; }

.event-image-container .img-placeholder .icon { font-size: 24px; opacity: 0.3; }
.event-image-container .img-placeholder .img-label {
  font-size: 9px;
  color: rgba(180, 160, 120, 0.3);
  letter-spacing: 1px;
  margin-top: 4px;
}

.event-image-container .img-placeholder .loading-spinner {
  width: 20px; height: 20px;
  border: 2px solid var(--gold-ghost);
  border-top-color: var(--gold-dim);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Notable people section */
.notable-people {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--gold-ghost);
}

.notable-people h4 {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-dim);
  margin-bottom: 8px;
  font-weight: 400;
}

.person-tag {
  display: inline-block;
  padding: 3px 10px;
  margin: 2px 4px 2px 0;
  background: var(--gold-ghost);
  border: 1px solid var(--gold-ghost);
  border-radius: 12px;
  font-size: 12px;
  color: var(--text-secondary);
}

/* Casualties / stats */
.event-stats {
  display: flex;
  gap: 12px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.stat-item {
  padding: 6px 10px;
  background: rgba(180, 160, 120, 0.04);
  border: 1px solid var(--gold-ghost);
  border-radius: 3px;
  font-size: 11px;
  color: var(--text-dim);
}

.stat-item .stat-value {
  color: var(--text-primary);
  font-weight: 600;
  font-size: 13px;
  display: block;
  margin-bottom: 1px;
}

#city-event-title {
  font-size: 18px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 4px;
}

#city-event-date {
  font-size: 12px;
  color: var(--gold);
  margin-bottom: 12px;
  letter-spacing: 1px;
  font-family: var(--font-mono);
}

#city-event-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.event-source {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--gold-ghost);
  font-size: 10px;
  color: rgba(180, 160, 120, 0.3);
}

/* Hint text */
#map-hint {
  position: absolute;
  bottom: 14px;
  right: 16px;
  font-size: 11px;
  color: rgba(180, 160, 120, 0.2);
  z-index: 1000;
  pointer-events: none;
}
