/* ===== Geopolitical Risk Map Styles - Redesigned for Zeeland Global ===== */

:root {
  --primary-deep: #000c1a;
  --gold: #C6A961;
  --gold-light: #d4bc7a;
  --risk-high: #8B2C2D;
  --risk-medium: #C6A961;
  --risk-low: #2D5A4A;
}

.map-container {
  position: relative;
  background: var(--primary-deep);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
  cursor: crosshair;
}

/* Leaflet Overrides */
#leaflet-map {
  background: var(--primary-deep) !important;
  outline: none;
}

.leaflet-container {
  background: var(--primary-deep) !important;
}

.leaflet-vignette {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 400;
  background: radial-gradient(circle, transparent 50%, rgba(0, 12, 26, 0.4) 100%);
}

/* Region Styles */
.map-region {
  outline: none;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.map-region:hover {
  filter: brightness(1.2) saturate(1.2);
  stroke-width: 1.5px !important;
}

/* Tooltip */
.map-tooltip {
  position: absolute;
  background: rgba(0, 12, 26, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(198, 169, 97, 0.3);
  padding: 20px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1000;
  width: 300px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

.map-tooltip.visible {
  opacity: 1;
  visibility: visible;
}

.map-tooltip-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}

.map-tooltip-risk {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 2px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.risk-badge-high {
  background: rgba(139, 44, 45, 0.2);
  color: #ff6b6b;
  border: 1px solid rgba(139, 44, 45, 0.4);
}

.risk-badge-medium {
  background: rgba(198, 169, 97, 0.15);
  color: var(--gold);
  border: 1px solid rgba(198, 169, 97, 0.3);
}

.risk-badge-low {
  background: rgba(45, 90, 74, 0.2);
  color: #5fb89a;
  border: 1px solid rgba(45, 90, 74, 0.4);
}

.map-tooltip-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
  margin-bottom: 16px;
  font-weight: 300;
}

.map-tooltip-link {
  font-size: 0.75rem;
  color: var(--gold);
  text-decoration: none;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: all 0.3s ease;
}

.map-tooltip-link:hover {
  color: var(--gold-light);
  transform: translateX(4px);
}

/* Legend */
.map-legend {
  position: absolute;
  bottom: 30px;
  left: 30px;
  background: rgba(0, 12, 26, 0.8);
  backdrop-filter: blur(8px);
  border-left: 3px solid var(--gold);
  padding: 20px;
  z-index: 500;
  min-width: 180px;
}

.map-legend-title {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 16px;
}

.map-legend-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 500;
}

.legend-color {
  width: 12px;
  height: 12px;
  border-radius: 1px;
}

/* Title Overlay */
.map-title-overlay {
  position: absolute;
  top: 30px;
  left: 30px;
  z-index: 500;
}

.map-title-overlay h3 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}

.map-title-overlay p {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 500;
}

/* Animations */
@keyframes map-pulse {
  0% { fill-opacity: 0.6; }
  50% { fill-opacity: 0.8; }
  100% { fill-opacity: 0.6; }
}

.risk-high-pulse {
  animation: map-pulse 3s infinite ease-in-out;
}

/* Hide Leaflet Controls for cleaner look */
.leaflet-control-attribution,
.leaflet-control-zoom {
  display: none !important;
}

@media (max-width: 768px) {
  .map-container {
    height: 500px;
  }
  #leaflet-map {
    height: 500px;
  }
  .map-legend, .map-title-overlay {
    left: 20px;
    bottom: 20px;
  }
  .map-tooltip {
    width: 260px;
    padding: 15px;
  }
}
