@font-face {
  font-family: "Portmanteau";
  src: 
    url("../fonts/portmanteau.woff") format("woff2"),
    url("../fonts/portmanteau.woff2") format("woff");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}
/* ===============================
   Badge Styles
================================== */
#badges-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  padding: 1rem;
}

#badges-container .badge {
  position: relative;
  background: #222;
  border-radius: 8px;
  text-align: center;
  padding: 0.5rem;
  transition: transform 0.2s ease, opacity 0.2s ease;
  cursor: pointer;
}

.badge.locked {
  opacity: 0.4;
  filter: grayscale(100%);
}

.badge.unlocked {
  opacity: 1;
  filter: none;
}

.badge:hover {
  transform: scale(1.05);
}

.badge-icon-wrapper {
  position: relative;
  display: inline-block;
}

.lock-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.6);
  border-radius: 50%;
}

.lock-icon {
  font-size: 1.8rem;
  color: #aaa;
}

.badge-info h3 {
  margin: 0.3rem 0 0.2rem;
  color: #fff;
  font-size: 0.9rem;
}

.badge-info p {
  color: #aaa;
  font-size: 0.75rem;
}

.badge-tooltip {
  visibility: hidden;
  opacity: 0;
  position: absolute;
  bottom: 110%;
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  font-size: 0.75rem;
  white-space: nowrap;
  transition: opacity 0.3s;
}

.badge:hover .badge-tooltip {
  visibility: visible;
  opacity: 1;
}

/* 
//    Unlock popup overlay 
*/
#badge-popup-overlay.hidden {
  display: none;
}

#badge-popup-overlay {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 15, 15, 0.8);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  z-index: 10000;
}

#badge-popup-overlay.visible {
  opacity: 1;
  pointer-events: all;
}

.badge-popup {
  background: #1b1b1b;
  border: 2px solid #444;
  border-radius: 10px;
  padding: 1.5rem;
  text-align: center;
  color: #fff;
  animation: pop 0.4s ease forwards;
  max-width: 280px;
}

.badge-popup img {
  width: 80px;
  height: 80px;
  margin-bottom: 0.8rem;
}

.badge-popup h2 {
  margin: 0;
  font-size: 1.1rem;
  color: #ffdf70;
}

.badge-popup p {
  font-size: 0.85rem;
  color: #ccc;
}

@keyframes pop {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
