:root {
  --purple: #7c3aed;
  --purple-dark: #5b21b6;
  --purple-deep: #4c1d95;
  --pink: #ec4899;
  --pink-hot: #db2777;
  --gold: #f59e0b;
  --gold-light: #fbbf24;
  --text: #1a1028;
  --text-muted: #7c7c9a;
  --bg: #f8f7ff;
  --white: #ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
}

.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--purple), var(--pink), var(--gold), var(--pink), var(--purple));
  background-size: 200% 100%;
  animation: shimmerBar 4s linear infinite;
  z-index: 200;
}

@keyframes shimmerBar {
  0% { background-position: 0% 0; }
  100% { background-position: 200% 0; }
}

.bg-dots {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(70% 45% at 10% 0%, rgba(124, 58, 237, 0.12) 0%, transparent 55%),
    radial-gradient(55% 40% at 90% 100%, rgba(236, 72, 153, 0.09) 0%, transparent 50%),
    url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='1' cy='1' r='1' fill='rgba(124,58,237,0.06)'/%3E%3C/svg%3E");
  background-size: auto, auto, 40px 40px;
  pointer-events: none;
  z-index: 0;
}

#confetti {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 95;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.floaters {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.floater {
  position: absolute;
  font-size: 2rem;
  opacity: 0.18;
  animation: float 6s ease-in-out infinite;
}

.f1 { top: 12%; left: 8%; animation-delay: 0s; font-size: 2.4rem; }
.f2 { top: 20%; right: 10%; animation-delay: 1s; font-size: 1.8rem; }
.f3 { bottom: 30%; left: 5%; animation-delay: 2s; }
.f4 { top: 45%; right: 6%; animation-delay: 0.5s; font-size: 1.5rem; }
.f5 { bottom: 15%; right: 15%; animation-delay: 1.5s; font-size: 2.2rem; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-18px) rotate(8deg); }
}

.header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 24px 0;
  max-width: 800px;
  margin: 0 auto;
}

.logo {
  font-size: 1.75rem;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.logo-pop { color: var(--purple); }
.logo-vai { color: var(--pink); }

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sound-toggle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(124, 58, 237, 0.15);
  background: var(--white);
  font-size: 1.05rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.1);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.sound-toggle:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.18);
}

.sound-toggle:active {
  transform: scale(0.95);
}

.badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  font-weight: 800;
  color: var(--white);
  background: linear-gradient(135deg, var(--purple), var(--pink));
  padding: 9px 16px;
  border-radius: 999px;
  box-shadow: 0 4px 20px rgba(124, 58, 237, 0.45);
  letter-spacing: 0.03em;
}

.badge-icon { font-size: 0.85rem; }

.main {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
  padding: 16px 24px 60px;
  text-align: center;
}

.tagline {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 10px;
  letter-spacing: 0.02em;
}

h1 {
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 10px;
  letter-spacing: -0.03em;
}

.highlight {
  background: linear-gradient(90deg, var(--purple), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 24px;
  line-height: 1.5;
}

.stats {
  display: inline-flex;
  align-items: center;
  gap: 20px;
  background: var(--white);
  border-radius: 16px;
  padding: 14px 28px;
  margin-bottom: 36px;
  box-shadow: 0 4px 24px rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.08);
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.stat strong {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--purple);
}

.stat span {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.stat-divider {
  width: 1px;
  height: 32px;
  background: rgba(124, 58, 237, 0.15);
}

.wheel-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 48px;
}

.wheel-outer-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -58%);
  width: min(95vw, 520px);
  height: min(95vw, 520px);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.25) 0%, rgba(236, 72, 153, 0.1) 40%, transparent 70%);
  animation: pulseGlow 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes pulseGlow {
  0%, 100% { transform: translate(-50%, -58%) scale(1); opacity: 0.8; }
  50% { transform: translate(-50%, -58%) scale(1.06); opacity: 1; }
}

.wheel-wrap {
  position: relative;
  width: min(90vw, 480px);
  height: min(90vw, 480px);
  margin-bottom: 32px;
}

.wheel-rim {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--gold-light), var(--gold), #d97706, var(--gold-light));
  box-shadow:
    0 0 0 3px var(--white),
    0 0 0 6px var(--purple),
    0 8px 40px rgba(124, 58, 237, 0.35),
    inset 0 2px 8px rgba(255, 255, 255, 0.5);
  z-index: 1;
  pointer-events: none;
}

.rim-lights {
  position: absolute;
  inset: 6px;
  border-radius: 50%;
}

.rim-light {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 0 6px 2px rgba(255, 255, 255, 0.8);
  transform: translate(-50%, -50%);
  transition: background 0.15s, box-shadow 0.15s;
}

.rim-light.on {
  background: var(--gold-light);
  box-shadow: 0 0 10px 4px rgba(251, 191, 36, 0.9);
}

.pointer-wrap {
  position: absolute;
  top: -4px;
  left: 50%;
  transform: translateX(-50%);
  transform-origin: 50% 10%;
  transition: transform 0.09s ease-out;
  z-index: 20;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.pointer {
  width: 0;
  height: 0;
  border-left: 22px solid transparent;
  border-right: 22px solid transparent;
  border-top: 48px solid var(--gold);
  position: relative;
}

.pointer::after {
  content: "";
  position: absolute;
  top: -46px;
  left: -14px;
  width: 0;
  height: 0;
  border-left: 14px solid transparent;
  border-right: 14px solid transparent;
  border-top: 30px solid var(--gold-light);
}

.pointer-base {
  width: 20px;
  height: 20px;
  background: linear-gradient(145deg, var(--gold-light), #d97706);
  border-radius: 50%;
  margin: -6px auto 0;
  border: 3px solid var(--white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

#wheel {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: block;
}

.wheel-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow:
    inset 0 0 34px rgba(0, 0, 0, 0.28),
    inset 0 0 10px rgba(255, 255, 255, 0.4);
  pointer-events: none;
  z-index: 3;
}

.hub {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--purple), var(--pink-hot));
  border: 5px solid var(--white);
  box-shadow:
    0 4px 24px rgba(124, 58, 237, 0.5),
    inset 0 2px 6px rgba(255, 255, 255, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.hub:hover:not(:disabled) {
  transform: translate(-50%, -50%) scale(1.06);
  box-shadow: 0 6px 32px rgba(236, 72, 153, 0.55);
}

.hub:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.hub-ring {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 255, 255, 0.4);
  animation: spinRing 8s linear infinite;
}

@keyframes spinRing {
  to { transform: rotate(360deg); }
}

.hub-text {
  font-size: 0.85rem;
  font-weight: 900;
  color: var(--white);
  letter-spacing: 0.08em;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.spin-btn {
  position: relative;
  overflow: hidden;
  padding: 18px 64px;
  font-size: 1.15rem;
  font-weight: 900;
  font-family: inherit;
  letter-spacing: 0.06em;
  color: var(--white);
  background: linear-gradient(135deg, var(--purple), var(--pink));
  border: none;
  border-radius: 999px;
  cursor: pointer;
  box-shadow:
    0 8px 32px rgba(124, 58, 237, 0.45),
    0 0 0 4px rgba(124, 58, 237, 0.15);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  animation: btnPulse 2.5s ease-in-out infinite;
}

@keyframes btnPulse {
  0%, 100% { box-shadow: 0 8px 32px rgba(124, 58, 237, 0.45), 0 0 0 4px rgba(124, 58, 237, 0.15); }
  50% { box-shadow: 0 8px 40px rgba(236, 72, 153, 0.55), 0 0 0 8px rgba(236, 72, 153, 0.12); }
}

.spin-btn-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent);
  animation: btnShine 3s ease-in-out infinite;
}

@keyframes btnShine {
  0% { left: -100%; }
  50%, 100% { left: 150%; }
}

.spin-btn-text {
  position: relative;
  z-index: 1;
}

.spin-btn:hover:not(:disabled) {
  transform: translateY(-3px) scale(1.04);
}

.spin-btn:active:not(:disabled) {
  transform: translateY(0) scale(0.98);
}

.spin-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  animation: none;
}

.prizes-section {
  text-align: left;
}

.prizes-section h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--text);
  justify-content: center;
}

.prizes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
}

.prize-card {
  background: var(--white);
  border-radius: 16px;
  padding: 18px 14px;
  text-align: center;
  border: 1px solid rgba(124, 58, 237, 0.1);
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.prize-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 28px rgba(124, 58, 237, 0.15);
}

.prize-card .icon {
  font-size: 2rem;
  margin-bottom: 8px;
  display: block;
}

.prize-card .name {
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
}

.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(26, 16, 40, 0.75);
  backdrop-filter: blur(8px);
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
}

.modal.show {
  display: flex;
}

.modal-rays {
  position: absolute;
  width: 600px;
  height: 600px;
  background: conic-gradient(
    from 0deg,
    transparent 0deg,
    rgba(124, 58, 237, 0.08) 20deg,
    transparent 40deg,
    rgba(236, 72, 153, 0.08) 60deg,
    transparent 80deg,
    rgba(245, 158, 11, 0.08) 100deg,
    transparent 120deg
  );
  border-radius: 50%;
  animation: rotateRays 10s linear infinite;
  pointer-events: none;
}

@keyframes rotateRays {
  to { transform: rotate(360deg); }
}

.modal-box {
  position: relative;
  background: var(--white);
  border-radius: 28px;
  padding: 40px 36px;
  max-width: 400px;
  width: 100%;
  text-align: center;
  box-shadow:
    0 0 0 4px rgba(124, 58, 237, 0.2),
    0 32px 80px rgba(124, 58, 237, 0.3);
  animation: modalPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalPop {
  from { transform: scale(0.7) rotate(-4deg); opacity: 0; }
  to { transform: scale(1) rotate(0deg); opacity: 1; }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(124, 58, 237, 0.08);
  color: var(--text-muted);
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.modal-close:hover {
  background: rgba(124, 58, 237, 0.15);
  color: var(--purple);
  transform: rotate(90deg);
}

.modal-sparkles {
  font-size: 1.2rem;
  margin-bottom: 4px;
  animation: sparkle 1s ease-in-out infinite alternate;
}

@keyframes sparkle {
  from { opacity: 0.6; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1.05); }
}

.prize-card .prize-thumb {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 12px;
  margin-bottom: 10px;
  background: #f3f0ff;
  border: 1px solid rgba(124, 58, 237, 0.1);
}

.prize-card .icon {
  display: none;
}

.modal-prize-img {
  width: 120px;
  height: 120px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 12px;
  border: 3px solid rgba(124, 58, 237, 0.15);
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.15);
  animation: bounceIcon 0.6s ease infinite alternate;
}

.modal-icon {
  display: none;
}

@keyframes bounceIcon {
  from { transform: translateY(0); }
  to { transform: translateY(-8px); }
}

.modal-box h2 {
  font-size: 2rem;
  font-weight: 900;
  background: linear-gradient(90deg, var(--purple), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.modal-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.modal-prize {
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.4;
  color: var(--text);
  margin-bottom: 28px;
}

.modal-btn {
  padding: 14px 36px;
  font-size: 1rem;
  font-weight: 800;
  font-family: inherit;
  color: var(--white);
  background: linear-gradient(135deg, var(--purple), var(--pink));
  border: none;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(124, 58, 237, 0.4);
  transition: transform 0.15s ease;
}

.modal-btn:hover {
  transform: scale(1.05);
}

@media (max-width: 480px) {
  .header {
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
  }

  .header-actions {
    width: 100%;
    justify-content: space-between;
  }

  .stats {
    gap: 12px;
    padding: 12px 18px;
  }

  .prizes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
