/* ================================================
   LUCKY BOX (CS:GO STYLE) SPINNER
   Horizontal scrolling reel from right to left
   ================================================ */

.lucky-container {
  position: relative;
  width: 100%;
  max-width: 900px;
  height: 250px;
  margin: 0 auto;
  background: linear-gradient(180deg, #e9ecef 0%, #dee2e6 100%);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  border: 3px solid #adb5bd;
}

.navbar-nav .nav-link:hover, 
.navbar-nav .nav-link.active {
  color: var(--primary-color);
}

.btn-theme-color {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

body.dark-mode .lucky-container,
body[data-theme="dark"] .lucky-container {
  background: linear-gradient(180deg, #2c3e50 0%, #34495e 100%);
  border-color: #495057;
}

body[data-theme="crypto"] .lucky-container {
  background: linear-gradient(180deg, #1a1f3a 0%, #2a2f4a 100%);
  border-color: #f7931a;
}

body[data-theme="food"] .lucky-container {
  background: linear-gradient(180deg, #fff5e6 0%, #ffe4c4 100%);
  border-color: #ff6b35;
}

body[data-theme="creative"] .lucky-container {
  background: linear-gradient(180deg, #f3e7ff 0%, #e7d7ff 100%);
  border-color: #667eea;
}

body[data-theme="gaming"] .lucky-container {
  background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%);
  border-color: #58a6ff;
}

/* Wheel Title Styling */
#wheelTitle {
  color: var(--primary-color);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

body[class*="theme-"] #wheelTitle {
  color: var(--primary-color);
}

/* Preset Dropdown Styling */
#presetDropdown {
  cursor: pointer;
  transition: border-color 0.2s ease;
}

#presetDropdown:hover {
  border-color: var(--primary-color);
}

body[class*="theme-"] #presetDropdown:hover {
  border-color: var(--primary-color);
}

#presetDropdown:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(40, 167, 69, 0.25);
}

body[class*="theme-"] #presetDropdown:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(var(--primary-color-rgb), 0.25);
}

.lucky-pointer {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, transparent 0%, #dc3545 20%, #dc3545 80%, transparent 100%);
  transform: translateX(-50%);
  z-index: 10;
  box-shadow: 0 0 20px rgba(220, 53, 69, 0.8);
}

body[data-theme="crypto"] .lucky-pointer {
  background: linear-gradient(180deg, transparent 0%, #f7931a 20%, #f7931a 80%, transparent 100%);
  box-shadow: 0 0 20px rgba(247, 147, 26, 0.8);
}

body[data-theme="food"] .lucky-pointer {
  background: linear-gradient(180deg, transparent 0%, #ff6b35 20%, #ff6b35 80%, transparent 100%);
  box-shadow: 0 0 20px rgba(255, 107, 53, 0.8);
}

.lucky-pointer::before,
.lucky-pointer::after {
  content: '';
  position: absolute;
  left: 50%;
  width: 0;
  height: 0;
  transform: translateX(-50%);
}

.lucky-pointer::before {
  top: -10px;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 15px solid #dc3545;
}

.lucky-pointer::after {
  bottom: -10px;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 15px solid #dc3545;
}

body[data-theme="crypto"] .lucky-pointer::before {
  border-top-color: #f7931a;
}

body[data-theme="crypto"] .lucky-pointer::after {
  border-bottom-color: #f7931a;
}

.lucky-reel-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;
}

.lucky-reel {
  display: flex;
  align-items: center;
  height: 100%;
  position: absolute;
  transition: transform cubic-bezier(0.22, 0.61, 0.36, 1);
}

.lucky-reel.spinning {
  filter: blur(2px);
}

/* Item dimensions must match LuckyEngine constants */
.lucky-item {
  flex-shrink: 0;
  width: 180px;
  height: 180px;
  margin: 0 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #f8f9fa;
  border: 2px solid #6c757d;
  border-radius: 12px;
  position: relative;
  transition: all 0.2s;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

body.dark-mode .lucky-item,
body[data-theme="dark"] .lucky-item {
  background: #34495e;
  border-color: #7f8c8d;
}

body[data-theme="crypto"] .lucky-item {
  background: rgba(42, 47, 74, 0.9);
  border-color: #ffa726;
}

body[data-theme="food"] .lucky-item {
  background: #fff9f0;
  border-color: #ff8c42;
}

body[data-theme="creative"] .lucky-item {
  background: #faf5ff;
  border-color: #9f7aea;
}

body[data-theme="gaming"] .lucky-item {
  background: #1e2a47;
  border-color: #79b8ff;
}

.lucky-item-image {
  font-size: 4rem;
  margin-bottom: 0.5rem;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.lucky-item-name {
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  color: #212529;
}

body.dark-mode .lucky-item-name,
body[data-theme="dark"] .lucky-item-name {
  color: #f8f9fa;
}

body[data-theme="crypto"] .lucky-item-name {
  color: #ffa726;
}

body[data-theme="food"] .lucky-item-name {
  color: #8b4513;
}

body[data-theme="creative"] .lucky-item-name {
  color: #667eea;
}

body[data-theme="gaming"] .lucky-item-name {
  color: #79b8ff;
}

.lucky-item.winner {
  animation: luckyWinnerReveal 0.8s ease-out forwards;
}

@keyframes luckyWinnerReveal {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1.15);
    border-color: #ffc107;
    border-width: 3px;
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    box-shadow: 0 0 40px rgba(40, 167, 69, 0.8), 0 0 80px rgba(40, 167, 69, 0.4);
  }
}

.lucky-item.winner .lucky-item-name {
  color: #ffffff !important;
  font-size: 1.2rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  font-weight: 900;
}

.lucky-item.winner .lucky-item-image {
  filter: drop-shadow(0 4px 8px rgba(255, 255, 255, 0.5));
  transform: scale(1.1);
}

.lucky-glow-overlay {
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 12px;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.3) 50%, transparent 70%);
  background-size: 200% 200%;
}

.lucky-item.winner .lucky-glow-overlay {
  animation: luckyShine 1.5s ease-in-out infinite;
  opacity: 1;
}

@keyframes luckyShine {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Responsive */
@media (max-width: 768px) {
  .lucky-container {
    max-width: 100%;
    height: 180px;
  }
  
  .lucky-item {
    width: 120px;
    height: 120px;
    margin: 0 10px;
  }
  
  .lucky-item-image {
    font-size: 2.5rem;
  }
  
  .lucky-item-name {
    font-size: 0.85rem;
  }
}