.contributors-map-container {
  position: relative;
  width: 100%;
  min-height: 600px;
  background: #1a1a2e;
  border-radius: 8px;
  overflow: hidden; }

.map-controls {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 10px; }

.map-view-toggle {
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 8px;
  padding: 12px 15px;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
  color: #1a1a2e;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  position: relative;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center; }
  .map-view-toggle i {
    font-size: 18px; }
  .map-view-toggle::after {
    content: attr(title);
    position: absolute;
    top: 50%;
    right: calc(100% + 12px);
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    pointer-events: none;
    font-weight: normal;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.2s ease; }
  .map-view-toggle:hover {
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2); }
    .map-view-toggle:hover::after {
      opacity: 1; }
  .map-view-toggle.active {
    background: #589632;
    color: white; }
    .map-view-toggle.active:hover {
      background: #6aaa3d; }

#globe-view {
  width: 100%;
  height: 700px;
  background: #1a1a2e; }

#flat-map-view {
  width: 100%;
  height: 700px;
  display: none;
  background: #f8f9fa; }

.contributor-tooltip {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 320px;
  width: 90%;
  z-index: 2000;
  display: none; }
  .contributor-tooltip.active {
    display: block;
    animation: popupFadeIn 0.3s ease; }
  .contributor-tooltip .contributor-card {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3); }
    .contributor-tooltip .contributor-card:hover {
      transform: none;
      box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3); }

.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1999;
  display: none; }
  .popup-overlay.active {
    display: block; }

.tooltip-close {
  position: absolute;
  top: -12px;
  right: -12px;
  background: #ffffff;
  border: 2px solid #1a1a2e;
  color: #1a1a2e;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 24px;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  line-height: 1;
  padding: 0;
  transform-origin: center center; }
  .tooltip-close:hover {
    background: #1a1a2e;
    color: #ffffff;
    transform: rotate(90deg); }

.map-legend {
  background: rgba(255, 255, 255, 0.95);
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  margin-top: 20px;
  max-width: 100%; }
  .map-legend h4 {
    margin: 0 0 16px 0;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a2e; }
  .map-legend .legend-items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 16px;
    align-items: end; }
  .map-legend .legend-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    font-size: 13px;
    text-align: center; }
    .map-legend .legend-item .legend-circle {
      flex-shrink: 0;
      border-radius: 50%;
      border: 2px solid #589632;
      background: rgba(88, 150, 50, 0.1); }

.loading-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 18px;
  z-index: 100; }

@keyframes popupFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, -45%); }
  to {
    opacity: 1;
    transform: translate(-50%, -50%); } }

@media (max-width: 768px) {
  .map-controls {
    top: 10px;
    right: 10px; }
  .map-view-toggle {
    width: 40px;
    height: 40px;
    padding: 8px; }
    .map-view-toggle i {
      font-size: 16px; }
    .map-view-toggle:hover::after {
      display: none; }
  .contributor-popup {
    max-width: 95%; }
  .popup-header {
    padding: 16px; }
  .popup-avatar {
    width: 48px;
    height: 48px; }
  .popup-body {
    padding: 16px; }
  .thematics-list {
    grid-template-columns: 1fr; }
  .map-legend {
    margin-top: 15px;
    padding: 15px; }
    .map-legend h4 {
      font-size: 14px;
      margin-bottom: 12px; }
    .map-legend .legend-items-grid {
      grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
      gap: 12px; }
    .map-legend .legend-item {
      font-size: 12px;
      margin-bottom: 10px; } }

img[crossorigin="anonymous"] {
  border-radius: 50%; }
