/* ============================================
   EASTER EGGS STYLES ⚡
   Sparkles, hearts, popups, and secret magic
   ============================================ */

/* ===== Dashie Points Counter ===== */
.dashie-points-counter {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  border: 4px solid white;
  border-radius: 2rem;
  padding: 8px 16px;
  font-family: 'Fredoka One', cursive;
  font-size: 1.2rem;
  color: #1388D3;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.5s ease, transform 0.3s ease;
  box-shadow: 0 8px 0 rgba(19, 136, 211, 0.2);
  pointer-events: none;
}

.dashie-points-counter:hover {
  transform: scale(1.1);
}

/* ===== Sparkle Poof Effect ===== */
@keyframes sparkle-poof {
  0% {
    transform: scale(0) rotate(0deg);
    opacity: 1;
  }
  50% {
    transform: scale(1.5) rotate(180deg);
    opacity: 0.8;
  }
  100% {
    transform: scale(0) rotate(360deg);
    opacity: 0;
  }
}

.sparkle-particle {
  position: fixed;
  pointer-events: none;
  z-index: 10000;
  font-size: 1.5rem;
  animation: sparkle-poof 0.8s ease-out forwards;
}

/* ===== Cloud Click Effect ===== */
.cloud-click-effect {
  animation: cloud-poof 0.6s ease-out;
}

@keyframes cloud-poof {
  0% { transform: scale(1); }
  30% { transform: scale(1.3); filter: brightness(1.3); }
  60% { transform: scale(0.9); }
  100% { transform: scale(1); filter: brightness(1); }
}

/* ===== Secret Heart Styles ===== */
.secret-heart {
  position: absolute;
  cursor: pointer;
  opacity: 0.15;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), filter 0.3s ease;
  z-index: 90; /* Keep it below overlays but high enough to be clicked */
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.secret-heart svg {
  width: 100%;
  height: 100%;
  transition: fill 0.3s ease, filter 0.3s ease;
}

.secret-heart:hover {
  opacity: 0.7;
  transform: scale(1.3);
  filter: drop-shadow(0 4px 8px rgba(169, 10, 95, 0.4));
}

.secret-heart.discovered {
  opacity: 0.8;
  filter: drop-shadow(0 4px 10px rgba(255, 94, 151, 0.5));
  animation: heart-pulse 2s ease-in-out infinite;
}

@keyframes heart-pulse {
  0%, 100% {
    transform: scale(1);
    filter: drop-shadow(0 4px 10px rgba(255, 94, 151, 0.5));
  }
  50% {
    transform: scale(1.15);
    filter: drop-shadow(0 6px 16px rgba(255, 94, 151, 0.8));
  }
}

/* ===== Love Note Popup ===== */
.love-note-popup {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.7);
  opacity: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 4px solid rgba(255, 255, 255, 0.6);
  border-radius: 2.5rem;
  padding: 2.5rem;
  width: 90%;
  max-width: 420px;
  text-align: center;
  z-index: 10001;
  box-shadow: 
    0 24px 60px rgba(169, 10, 95, 0.25),
    inset 0 0 0 2px rgba(255, 255, 255, 0.3);
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.4s ease;
  pointer-events: none;
}

.love-note-popup.show {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.love-note-popup .close-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 36px;
  height: 36px;
  background: rgba(169, 10, 95, 0.1);
  color: #A90A5F;
  border: none;
  border-radius: 50%;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, transform 0.2s, color 0.2s;
}

.love-note-popup .close-btn:hover {
  background: #A90A5F;
  color: white;
  transform: scale(1.1) rotate(90deg);
}

.love-note-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 90, 140, 0.3); /* Soft blue tinted overlay matching Dashie */
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.love-note-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.popup-heart-container {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 94, 151, 0.15), rgba(169, 10, 95, 0.15));
  margin-bottom: 1.25rem;
  animation: float-heart 3s ease-in-out infinite;
}

.popup-heart-svg {
  width: 40px;
  height: 40px;
  fill: #A90A5F;
  filter: drop-shadow(0 2px 4px rgba(169, 10, 95, 0.3));
}

.popup-title {
  font-family: 'Fredoka One', cursive;
  font-size: 1.6rem;
  color: #1388D3;
  margin-bottom: 0.75rem;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.5);
}

.popup-message {
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: #A90A5F;
  line-height: 1.5;
  margin: 0;
}

@keyframes float-heart {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* ===== Lightning Bolt Cursor Trail ===== */
.lightning-trail {
  position: fixed;
  pointer-events: none;
  z-index: 9998;
  font-size: 1.5rem;
  animation: trail-fade 1s ease-out forwards;
}

@keyframes trail-fade {
  0% {
    opacity: 1;
    transform: scale(1) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: scale(0.3) rotate(45deg) translateY(-30px);
  }
}

/* ===== Master Dashie Fan Badge ===== */
.master-badge {
  display: inline-block;
  background: linear-gradient(135deg, #FCEF50, #ED2B2A, #F37934, #54B345, #1388D3, #642D91);
  background-size: 300% 300%;
  animation: rainbow-shift 3s ease infinite;
  color: white;
  font-family: 'Fredoka One', cursive;
  font-size: 0.9rem;
  padding: 6px 14px;
  border-radius: 1rem;
  border: 3px solid white;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.2);
  margin-top: 8px;
  opacity: 0;
  transform: scale(0);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.master-badge.show {
  opacity: 1;
  transform: scale(1);
}

@keyframes rainbow-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ===== Rainbow Mode Toggle Button ===== */
.rainbow-toggle {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 12px;
  background: linear-gradient(90deg, #ED2B2A, #F37934, #FCEF50, #54B345, #1388D3, #642D91);
  background-size: 200% 100%;
  z-index: 9999;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.5s ease, height 0.3s ease;
}

@keyframes rainbow-bar-pulse {
  0%, 100% { box-shadow: 0 -2px 10px rgba(253, 239, 80, 0); }
  50% { box-shadow: 0 -8px 25px rgba(253, 239, 80, 0.7); }
}

@keyframes rainbow-bar-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.rainbow-toggle.unlocked {
  opacity: 0.85;
  animation: rainbow-bar-pulse 3s infinite, rainbow-bar-shift 5s linear infinite;
}

.rainbow-toggle.unlocked:hover {
  opacity: 1;
  height: 24px;
}

.rainbow-toggle-label {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: 4px solid #A90A5F;
  border-radius: 1rem;
  padding: 6px 16px;
  font-family: 'Fredoka One', cursive;
  font-size: 0.9rem;
  color: #A90A5F;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.rainbow-toggle.unlocked:hover + .rainbow-toggle-label {
  opacity: 1;
}

/* ===== Lightning Zap Flash Effect ===== */
@keyframes lightning-flash {
  0% { opacity: 0; }
  10% { opacity: 0.8; }
  20% { opacity: 0; }
  30% { opacity: 0.6; }
  40% { opacity: 0; }
  50% { opacity: 0.4; }
  100% { opacity: 0; }
}

.lightning-flash-overlay {
  position: fixed;
  inset: 0;
  background: white;
  z-index: 9997;
  pointer-events: none;
  animation: lightning-flash 0.5s ease-out forwards;
}

/* ===== Points Notification Toast ===== */
.points-toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: #FCEF50;
  color: #1388D3;
  font-family: 'Fredoka One', cursive;
  font-size: 1.3rem;
  padding: 12px 24px;
  border-radius: 1.5rem;
  border: 4px solid #1388D3;
  box-shadow: 0 8px 0 rgba(19, 136, 211, 0.3);
  z-index: 10002;
  transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: none;
}

.points-toast.show {
  transform: translateX(-50%) translateY(0);
}

/* ===== Banner Wiggle ===== */
.banner-wiggle {
  animation: wiggle-anim 1s ease-in-out infinite;
  animation-play-state: paused;
}

.group:hover .banner-wiggle {
  animation-play-state: running;
}

@keyframes wiggle-anim {
  0%, 100% { transform: rotate(2deg); }
  50% { transform: rotate(-2deg); }
}
