/* ===== MAP LOGOS ===== */
#map-logos-wrap {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 500;
  width: 42px;
  height: 42px;
}

#map-logo-main {
  position: absolute;
  top: 0;
  left: 0;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.3s ease;
}

#map-logo-main.logos-open {
  opacity: 0;
  pointer-events: none;
}

#map-logo-main-img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: block;
  position: relative;
  z-index: 1;
  transition: transform 0.2s ease;
}

#map-logo-main:hover #map-logo-main-img {
  transform: scale(1.08);
}

#map-logo-main-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 3.5px dashed #C5532B;
  animation: mapLogoSpin 6s linear infinite;
  opacity: 0.85;
  transition: border-color 0.4s ease;
}

#map-logo-main.state-home #map-logo-main-ring {
  border-color: #00c853;
  animation-duration: 5s;
}

#map-logo-main.state-worldcup #map-logo-main-ring {
  border-color: #3B82C4;
  animation-direction: reverse;
  animation-duration: 5s;
}

#map-logo-main:hover #map-logo-main-ring {
  border-color: #FFD700;
  opacity: 1;
}

/* ── Superscript hint badge ── */
#map-logo-main-hint {
  position: absolute;
  top: -5px;
  right: -8px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #C5532B;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
  z-index: 2;
  font-size: 0.55rem;
  opacity: 0;
  transition: opacity 0.3s ease, background 0.4s ease;
}

#map-logo-main.state-home #map-logo-main-hint {
  opacity: 1;
  background: #00c853;
}

#map-logo-main.state-worldcup #map-logo-main-hint {
  opacity: 1;
  background: #3B82C4;
}

/* ── Expanded pair ── */
#map-logo-expanded {
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-8px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

#map-logo-expanded.logos-visible {
  opacity: 1;
  pointer-events: all;
  transform: translateX(0);
}

#map-logo-link,
#map-worldcup-link {
  position: relative;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
  flex-shrink: 0;
}

#map-logo-img,
#map-worldcup-img {
  width: 26px;
  height: 26px;
  object-fit: contain;
  display: block;
  position: relative;
  z-index: 1;
  transition: transform 0.2s ease;
}

#map-logo-link:hover #map-logo-img,
#map-worldcup-link:hover #map-worldcup-img {
  transform: scale(1.1);
}

/* Home ring — green */
#map-logo-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2.5px dashed #00c853;
  animation: mapLogoSpin 5s linear infinite;
  opacity: 0.9;
}

#map-logo-link:hover #map-logo-ring {
  border-color: #FFD700;
  opacity: 1;
}

/* World Cup ring — blue */
#map-worldcup-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2.5px dashed #3B82C4;
  animation: mapLogoSpin 5s linear infinite reverse;
  opacity: 0.9;
}

#map-worldcup-link:hover #map-worldcup-ring {
  border-color: #FFD700;
  opacity: 1;
}

/* ── Expanded badges ── */
#map-logo-home-badge {
  position: absolute;
  top: -5px;
  right: -7px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #00c853;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
  z-index: 2;
}

#map-worldcup-badge {
  position: absolute;
  top: -5px;
  right: -7px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #3B82C4;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.4);
  z-index: 2;
  font-size: 0.5rem;
}

@keyframes mapLogoSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* ── Mobile ── */
@media (max-width: 480px) {
  #map-logos-wrap {
    top: 10px;
    left: 10px;
    width: 34px;
    height: 34px;
  }

  #map-logo-main {
    width: 34px;
    height: 34px;
  }

  #map-logo-main-img {
    width: 34px;
    height: 34px;
  }

  #map-logo-link,
  #map-worldcup-link {
    width: 21px;
    height: 21px;
  }

  #map-logo-img,
  #map-worldcup-img {
    width: 21px;
    height: 21px;
  }
}