/**
 * Lucky Guide Character Styles
 * 
 * Reusable styles for Lucky guide character across pages
 */

/* Lucky Guide Character */
.lucky-guide-character {
  position: fixed;
  top: 50px;
  right: 20px;
  z-index: 10000; /* High z-index to stay above all content */
  cursor: pointer;
  transition: transform 0.3s ease;
  animation: luckyFloat 3s ease-in-out infinite;
  pointer-events: auto; /* Ensure it's clickable */
}

@keyframes luckyFloat {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Dancing animation - combines floating with side-to-side motion */
.lucky-guide-character.dancing {
  animation: luckyDance 3s ease-in-out infinite; /* Slowed down from 1.5s to 3s */
}

.lucky-guide-character img {
  width: 100px;
  height: auto;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4));
  transition: transform 0.3s ease;
  object-fit: contain;
}

.lucky-guide-character:hover {
  transform: scale(1.1);
}

@keyframes luckyDance {
  0%, 100% {
    transform: translateY(0px) translateX(0px);
  }
  25% {
    transform: translateY(-5px) translateX(-2.4px); /* Reduced by 70%: 8px * 0.3 = 2.4px */
  }
  50% {
    transform: translateY(-10px) translateX(0px);
  }
  75% {
    transform: translateY(-5px) translateX(2.4px); /* Reduced by 70%: 8px * 0.3 = 2.4px */
  }
}

@media (max-width: 768px) {
  .lucky-guide-character {
    top: 40px;
    right: 10px;
  }
  
  .lucky-guide-character img {
    width: 80px;
  }
  
  /* Slightly less side-to-side motion on mobile */
  .lucky-guide-character.dancing {
    animation: luckyDanceMobile 3s ease-in-out infinite; /* Slowed down from 1.5s to 3s */
  }
}

@keyframes luckyDanceMobile {
  0%, 100% {
    transform: translateY(0px) translateX(0px);
  }
  25% {
    transform: translateY(-5px) translateX(-1.5px); /* Reduced by 70%: 5px * 0.3 = 1.5px */
  }
  50% {
    transform: translateY(-10px) translateX(0px);
  }
  75% {
    transform: translateY(-5px) translateX(1.5px); /* Reduced by 70%: 5px * 0.3 = 1.5px */
  }
}

/* Lucky Modal */
.lucky-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  z-index: 100000;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.3s ease;
}

.lucky-modal.show {
  display: flex;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.lucky-modal-content {
  background: white;
  border-radius: 20px;
  padding: 40px;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.lucky-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  font-size: 2rem;
  color: #999;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.lucky-modal-close:hover {
  background: #f0f0f0;
  color: #333;
}

.lucky-modal-image {
  width: 120px;
  height: auto;
  display: block;
  margin: 0 auto 20px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.lucky-modal-title {
  font-size: 2rem;
  margin: 0 0 15px 0;
  text-align: center;
  color: #333;
  font-family: 'AnimeAce', Arial, sans-serif;
}

.lucky-modal-description {
  font-size: 1.1rem;
  color: #666;
  text-align: center;
  margin: 0 0 30px 0;
  line-height: 1.6;
}

.lucky-modal-options {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.lucky-modal-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'AnimeAce', Arial, sans-serif;
  text-align: center;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.lucky-modal-option:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.lucky-modal-option:active {
  transform: translateY(0);
}

.lucky-option-emoji {
  font-size: 2.5rem;
  margin-bottom: 10px;
  display: block;
}

.lucky-option-text {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 5px;
  display: block;
}

.lucky-option-subtitle {
  font-size: 0.9rem;
  opacity: 0.9;
  font-weight: normal;
  display: block;
}

@media (max-width: 768px) {
  .lucky-modal-content {
    padding: 30px 20px;
    max-width: 95%;
  }
  
  .lucky-modal-title {
    font-size: 1.5rem;
  }
  
  .lucky-modal-description {
    font-size: 1rem;
  }
  
  .lucky-modal-option {
    padding: 15px;
  }
  
  .lucky-option-emoji {
    font-size: 2rem;
  }
  
  .lucky-option-text {
    font-size: 1rem;
  }
  
  .lucky-option-subtitle {
    font-size: 0.85rem;
  }
}

