/* ===== CSS Variables ===== */
:root {
  --bg-primary: #0a0a0f;
  --bg-card: rgba(20, 20, 35, 0.7);
  --border-color: rgba(168, 85, 247, 0.3);
  --purple: #a855f7;
  --pink: #ec4899;
  --amber: #f59e0b;
  --blue: #3b82f6;
  --green: #10b981;
  --orange: #f97316;
  --indigo: #6366f1;
  --text-primary: #f8f9fc;
  --text-secondary: #a0a0b0;
  --radius: 1rem;
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

/* ===== Reset & Base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  height: 100%;
  overflow: hidden;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  position: fixed;
  width: 100%;
  height: 100%;
}

/* ===== Background Effects ===== */
.bg-gradient {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.15) 0%, transparent 50%, rgba(236, 72, 153, 0.1) 100%);
  pointer-events: none;
  z-index: 0;
}

.bg-gradient-2 {
  position: fixed;
  inset: 0;
  background: linear-gradient(225deg, rgba(245, 158, 11, 0.08) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}

/* ===== Falling Elements ===== */
#falling-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}

.falling-item {
  position: absolute;
  font-size: 20px;
  animation: fall linear forwards;
  opacity: 0.8;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

@keyframes fall {
  0% {
    transform: translateY(-50px) rotate(0deg);
    opacity: 0;
  }

  10% {
    opacity: 0.8;
  }

  90% {
    opacity: 0.8;
  }

  100% {
    transform: translateY(110vh) rotate(720deg);
    opacity: 0;
  }
}

/* ===== Page Structure ===== */
.page {
  display: none;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.4s ease;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

.page.active {
  display: block;
  opacity: 1;
}

.container {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  padding: 2rem 1rem;
  min-height: 100%;
}

/* ===== Header ===== */
.header {
  text-align: center;
  margin-bottom: 2rem;
}

.logo-container {
  display: inline-block;
  margin-bottom: 1rem;
}

.logo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  box-shadow: 0 0 30px rgba(168, 85, 247, 0.4);
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {

  0%,
  100% {
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
  }

  50% {
    box-shadow: 0 0 40px rgba(168, 85, 247, 0.6), 0 0 60px rgba(236, 72, 153, 0.3);
  }
}

.title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.gradient-text {
  background: linear-gradient(135deg, var(--purple) 0%, var(--pink) 50%, var(--amber) 100%);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 3s ease infinite;
}

@keyframes gradient-shift {

  0%,
  100% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }
}

.subtitle {
  font-family: 'Dancing Script', cursive;
  font-size: 2rem;
  color: var(--amber);
  margin-bottom: 0.5rem;
}

.description {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.pulse {
  display: inline-block;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.3);
  }
}

/* ===== Card ===== */
.card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: 1.5rem;
  padding: 1.5rem;
  box-shadow: var(--shadow), 0 0 20px rgba(168, 85, 247, 0.1);
}

/* ===== Form Elements ===== */
.input-group {
  margin-bottom: 1.25rem;
}

.input-group label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.icon {
  width: 16px;
  height: 16px;
  color: var(--purple);
  flex-shrink: 0;
}

.input-group:nth-child(2) .icon {
  color: var(--pink);
}

.input-group:nth-child(3) .icon {
  color: var(--amber);
}

input,
textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  background: rgba(30, 30, 46, 0.8);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
}

input::placeholder,
textarea::placeholder {
  color: #6b6b7b;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--purple);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.2);
}

textarea {
  resize: none;
  min-height: 80px;
}

.phone-input {
  display: flex;
  gap: 0.5rem;
}

.phone-prefix {
  padding: 0.875rem 0.75rem;
  background: rgba(30, 30, 46, 0.8);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  white-space: nowrap;
  display: flex;
  align-items: center;
}

.phone-input input {
  flex: 1;
  min-width: 0;
}

/* ===== Buttons ===== */
.btn-primary {
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  background-size: 200% 200%;
  border: none;
  border-radius: 0.75rem;
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: translateX(-100%);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(168, 85, 247, 0.4);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
}

.btn-primary:disabled {
  background: #3a3a4a;
  cursor: not-allowed;
}

.btn-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ===== Link Modal ===== */
.link-modal {
  margin-top: 1.5rem;
}

.link-modal.hidden {
  display: none;
}

.link-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 2px solid rgba(168, 85, 247, 0.4);
  border-radius: 1.5rem;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  text-align: center;
}

.link-card::before,
.link-card::after {
  content: '';
  position: absolute;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.2;
}

.link-card::before {
  background: var(--purple);
  top: -50px;
  right: -50px;
}

.link-card::after {
  background: var(--pink);
  bottom: -50px;
  left: -50px;
}

.success-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  color: white;
  animation: bounce-in 0.5s ease;
}

@keyframes bounce-in {
  0% {
    transform: scale(0);
  }

  50% {
    transform: scale(1.1);
  }

  100% {
    transform: scale(1);
  }
}

.link-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.25rem;
  position: relative;
  z-index: 1;
}

.link-subtitle {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.link-display {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background: linear-gradient(90deg, rgba(168, 85, 247, 0.15), rgba(236, 72, 153, 0.15));
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: 1rem;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
  word-break: break-all;
}

.link-icon {
  width: 20px;
  height: 20px;
  color: var(--purple);
  flex-shrink: 0;
}

.link-text {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-family: monospace;
  text-align: left;
}

.link-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  position: relative;
  z-index: 1;
}

.btn-copy,
.btn-share {
  padding: 0.75rem;
  border: none;
  border-radius: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-copy {
  background: linear-gradient(135deg, var(--purple), var(--pink));
  color: white;
}

.btn-share {
  background: linear-gradient(135deg, var(--amber), var(--orange));
  color: white;
}

.btn-copy:hover,
.btn-share:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.btn-copy:active,
.btn-share:active {
  transform: translateY(0);
}

.btn-copy svg,
.btn-share svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.btn-preview {
  width: 100%;
  padding: 0.75rem;
  background: transparent;
  border: 1px solid #4a4a5a;
  border-radius: 0.75rem;
  color: var(--text-secondary);
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  position: relative;
  z-index: 1;
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-preview:hover {
  border-color: var(--purple);
  color: var(--text-primary);
}

.btn-preview svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.copy-message {
  margin-top: 1rem;
  color: #10b981;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  animation: fade-in 0.3s ease;
}

.copy-message.hidden {
  display: none;
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Loading Page ===== */
.loading-container {
  text-align: center;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 0;
}

.gift-wrapper {
  position: relative;
  width: 200px;
  height: 200px;
  margin: 0 auto 2rem;
  flex-shrink: 0;
}

.ring {
  position: absolute;
  border-radius: 50%;
  border-style: dashed;
}

.ring-1 {
  inset: -20px;
  border: 2px solid rgba(168, 85, 247, 0.3);
  animation: spin 8s linear infinite;
}

.ring-2 {
  inset: -40px;
  border: 1px dotted rgba(236, 72, 153, 0.2);
  animation: spin-reverse 12s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes spin-reverse {
  from {
    transform: rotate(360deg);
  }

  to {
    transform: rotate(0deg);
  }
}

.floating-hearts {
  position: absolute;
  inset: 0;
}

.heart {
  position: absolute;
  font-size: 1.25rem;
  animation: float-heart 2s ease-in-out infinite;
  opacity: 0.5;
}

.heart:nth-child(1) {
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  animation-delay: 0s;
}

.heart:nth-child(2) {
  top: 25%;
  right: 0;
  animation-delay: 0.3s;
}

.heart:nth-child(3) {
  bottom: 25%;
  right: 0;
  animation-delay: 0.6s;
}

.heart:nth-child(4) {
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  animation-delay: 0.9s;
}

.heart:nth-child(5) {
  bottom: 25%;
  left: 0;
  animation-delay: 1.2s;
}

.heart:nth-child(6) {
  top: 25%;
  left: 0;
  animation-delay: 1.5s;
}

@keyframes float-heart {

  0%,
  100% {
    transform: translateY(0) scale(1);
    opacity: 0.5;
  }

  50% {
    transform: translateY(-10px) scale(1.2);
    opacity: 0.8;
  }
}

.gift-box {
  position: absolute;
  inset: 20px;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  border-radius: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: gift-bounce 2s ease-in-out infinite;
  box-shadow: 0 0 40px rgba(168, 85, 247, 0.4);
}

@keyframes gift-bounce {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-15px);
  }
}

.gift-icon {
  width: 80px;
  height: 80px;
  color: white;
  animation: gift-wiggle 1.5s ease-in-out infinite;
}

@keyframes gift-wiggle {

  0%,
  100% {
    transform: rotate(0deg);
  }

  25% {
    transform: rotate(5deg);
  }

  75% {
    transform: rotate(-5deg);
  }
}

.sparkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.sparkle {
  position: absolute;
  font-size: 1.5rem;
  animation: sparkle 2s ease-in-out infinite;
}

.sparkle:nth-child(1) {
  top: -10px;
  right: 0;
  animation-delay: 0s;
}

.sparkle:nth-child(2) {
  bottom: 0;
  left: -10px;
  animation-delay: 0.7s;
}

.sparkle:nth-child(3) {
  top: 50%;
  right: -15px;
  animation-delay: 1.4s;
}

@keyframes sparkle {

  0%,
  100% {
    opacity: 0;
    transform: scale(0.5);
  }

  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

.loading-title {
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
  flex-shrink: 0;
}

.dots {
  animation: dots 1.5s infinite;
}

@keyframes dots {

  0%,
  20% {
    opacity: 0;
  }

  40% {
    opacity: 1;
  }

  60% {
    opacity: 1;
  }

  80%,
  100% {
    opacity: 0;
  }
}

.loading-subtitle {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  flex-shrink: 0;
}

.progress-bar {
  width: 250px;
  height: 6px;
  background: #2a2a3a;
  border-radius: 3px;
  margin: 0 auto 1rem;
  overflow: hidden;
  flex-shrink: 0;
}

.progress-fill {
  height: 100%;
  width: 50%;
  background: linear-gradient(90deg, var(--purple), var(--pink), var(--amber));
  border-radius: 3px;
  animation: progress 1.5s linear infinite;
}

@keyframes progress {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(200%);
  }
}

.loading-text {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-family: monospace;
  animation: loading-pulse 1s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes loading-pulse {

  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 1;
  }
}

/* ===== Greeting Page ===== */
.greeting-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.header-badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.badge {
  font-size: 1.25rem;
  animation: badge-bounce 2s ease-in-out infinite;
}

.badge:nth-child(3) {
  animation-delay: 0.5s;
}

@keyframes badge-bounce {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.2);
  }
}

.badge-text {
  font-size: 0.75rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.greeting-name {
  font-family: 'Dancing Script', cursive;
  font-size: 3.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
  animation: name-appear 0.6s ease;
}

@keyframes name-appear {
  from {
    opacity: 0;
    transform: scale(0.8);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

.greeting-text {
  color: #c0c0d0;
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

.greeting-hint {
  color: var(--text-secondary);
  font-size: 0.8rem;
}

.message-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
}

.message-card::before {
  content: '';
  position: absolute;
  top: -20px;
  right: -20px;
  width: 60px;
  height: 60px;
  background: rgba(236, 72, 153, 0.15);
  border-radius: 50%;
  filter: blur(20px);
}

.message-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.message-icon {
  width: 14px;
  height: 14px;
  color: var(--amber);
  flex-shrink: 0;
}

.message-content {
  color: var(--text-primary);
  font-size: 1.1rem;
  font-weight: 500;
  text-align: center;
  position: relative;
  z-index: 1;
}

/* ===== Wheel Section ===== */
.wheel-section {
  margin-bottom: 1.5rem;
}

.wheel-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0.5rem 1.25rem;
  background: linear-gradient(90deg, rgba(168, 85, 247, 0.15), rgba(236, 72, 153, 0.15));
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: 2rem;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.wheel-icon {
  width: 18px;
  height: 18px;
  color: var(--purple);
  flex-shrink: 0;
}

.wheel-title span {
  font-family: 'Dancing Script', cursive;
  font-size: 1.25rem;
  color: var(--amber);
}

.wheel-container {
  position: relative;
  width: 300px;
  height: 300px;
  margin: 0 auto 1.5rem;
}

.wheel-outer-ring {
  position: absolute;
  inset: -10px;
  border: 2px dashed rgba(168, 85, 247, 0.3);
  border-radius: 50%;
  animation: spin 20s linear infinite;
}

.wheel-inner-ring {
  position: absolute;
  inset: -25px;
  border: 1px dotted rgba(236, 72, 153, 0.2);
  border-radius: 50%;
  animation: spin-reverse 15s linear infinite;
}

.wheel-pointer {
  position: absolute;
  top: -15px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  animation: pointer-bounce 1s ease-in-out infinite;
}

@keyframes pointer-bounce {

  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }

  50% {
    transform: translateX(-50%) translateY(-5px);
  }
}

.pointer-triangle {
  width: 0;
  height: 0;
  border-left: 15px solid transparent;
  border-right: 15px solid transparent;
  border-top: 25px solid var(--amber);
  filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.5));
}

.wheel {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 4px solid rgba(168, 85, 247, 0.4);
  box-shadow: 0 0 40px rgba(168, 85, 247, 0.3);
  overflow: hidden;
  transition: transform 4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.wheel-segment {
  position: absolute;
  width: 100%;
  height: 100%;
  clip-path: polygon(50% 50%, 50% 0%, 85% 15%);
}

.wheel-content {
  position: absolute;
  left: 50%;
  top: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform-origin: center;
}

.wheel-emoji {
  font-size: 1.75rem;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.wheel-text {
  font-size: 0.65rem;
  font-weight: 700;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
  margin-top: 2px;
}

.wheel-divider {
  position: absolute;
  left: 50%;
  top: 0;
  width: 2px;
  height: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform-origin: bottom;
}

.wheel-center {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.wheel-center::before {
  content: '';
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  border-radius: 50%;
  box-shadow: 0 0 30px rgba(168, 85, 247, 0.5);
  animation: center-pulse 2s ease-in-out infinite;
}

@keyframes center-pulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.1);
  }
}

.wheel-center svg {
  position: absolute;
  width: 35px;
  height: 35px;
  color: white;
}

.btn-spin {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2.5rem;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  border: none;
  border-radius: 2rem;
  color: white;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  margin: 0 auto;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-spin:hover:not(:disabled) {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(245, 158, 11, 0.5);
}

.btn-spin:active:not(:disabled) {
  transform: translateY(-1px);
}

.btn-spin:disabled {
  background: #3a3a4a;
  cursor: not-allowed;
  box-shadow: none;
}

.spin-icon {
  font-size: 1.25rem;
  animation: spin-icon 2s linear infinite;
}

@keyframes spin-icon {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* ===== Result Section ===== */
.result-section {
  animation: slide-up 0.5s ease;
}

.result-section.hidden {
  display: none;
}

@keyframes slide-up {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.result-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 2px solid rgba(168, 85, 247, 0.5);
  border-radius: 1.5rem;
  padding: 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  margin-bottom: 1rem;
}

.result-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(168, 85, 247, 0.2), transparent 70%);
  opacity: 0.5;
}

.result-emoji {
  font-size: 4rem;
  margin-bottom: 0.5rem;
  position: relative;
  z-index: 1;
  animation: result-bounce 0.6s ease;
}

@keyframes result-bounce {
  0% {
    transform: scale(0) rotate(-180deg);
  }

  60% {
    transform: scale(1.2) rotate(10deg);
  }

  100% {
    transform: scale(1) rotate(0deg);
  }
}

.result-title {
  font-family: 'Dancing Script', cursive;
  font-size: 2rem;
  color: var(--purple);
  text-shadow: 0 0 20px rgba(168, 85, 247, 0.5);
  margin-bottom: 0.25rem;
  position: relative;
  z-index: 1;
}

.result-text {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.result-stars {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  position: relative;
  z-index: 1;
}

.result-stars span {
  font-size: 1.25rem;
  animation: star-bounce 1s ease-in-out infinite;
}

.result-stars span:nth-child(1) {
  animation-delay: 0s;
}

.result-stars span:nth-child(2) {
  animation-delay: 0.1s;
}

.result-stars span:nth-child(3) {
  animation-delay: 0.2s;
}

.result-stars span:nth-child(4) {
  animation-delay: 0.3s;
}

.result-stars span:nth-child(5) {
  animation-delay: 0.4s;
}

@keyframes star-bounce {

  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-8px) scale(1.2);
  }
}

/* ===== Wish Section ===== */
.wish-section {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.wish-section.hidden {
  display: none;
}

.wish-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.85rem;
  color: #c0c0d0;
}

.wish-icon {
  width: 18px;
  height: 18px;
  color: var(--purple);
  flex-shrink: 0;
}

.wish-input {
  width: 100%;
  padding: 1rem;
  background: rgba(30, 30, 46, 0.8);
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  text-align: center;
  margin-bottom: 0.75rem;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
}

.wish-input:focus {
  outline: none;
  border-color: var(--purple);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.2);
}

.wish-input::placeholder {
  color: #6b6b7b;
}

.btn-send-wish {
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, var(--purple), var(--pink), var(--amber));
  border: none;
  border-radius: 0.75rem;
  color: white;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-send-wish:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(168, 85, 247, 0.4);
}

.btn-send-wish:active:not(:disabled) {
  transform: translateY(0);
}

.btn-send-wish:disabled {
  background: #3a3a4a;
  cursor: not-allowed;
}

.btn-send-wish svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ===== Wish Sent ===== */
.wish-sent {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  margin-bottom: 1rem;
  animation: sent-appear 0.5s ease;
}

.wish-sent.hidden {
  display: none;
}

@keyframes sent-appear {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

.sent-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  animation: sent-bounce 0.8s ease;
}

@keyframes sent-bounce {
  0% {
    transform: scale(0);
  }

  50% {
    transform: scale(1.3);
  }

  100% {
    transform: scale(1);
  }
}

.sent-text {
  color: #10b981;
  font-size: 1.25rem;
  font-weight: 600;
}

.sent-subtitle {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ===== Reset Button ===== */
.btn-reset {
  width: 100%;
  padding: 1rem;
  background: transparent;
  border: 1px solid #4a4a5a;
  border-radius: 0.75rem;
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  touch-action: manipulation;
}

.btn-reset:hover {
  border-color: var(--purple);
  color: var(--text-primary);
}

.btn-reset:active {
  transform: scale(0.98);
}

.btn-reset svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ===== Footer ===== */
.footer {
  text-align: center;
  color: #5a5a6a;
  font-size: 0.75rem;
  margin-top: 2rem;
  padding-bottom: 2rem;
}

/* ===== Confetti Canvas ===== */
#confetti-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
}

/* ===== Responsive ===== */
@media (max-width: 480px) {
  .container {
    padding: 1.5rem 1rem;
  }

  .greeting-name {
    font-size: 2.5rem;
  }

  .wheel-container {
    width: 260px;
    height: 260px;
  }

  .gift-wrapper {
    width: 160px;
    height: 160px;
  }

  .gift-box {
    inset: 15px;
  }

  .gift-icon {
    width: 60px;
    height: 60px;
  }
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ===== iOS Safe Area Support ===== */
@supports (padding-top: env(safe-area-inset-top)) {
  .container {
    padding-top: max(2rem, env(safe-area-inset-top));
    padding-bottom: max(2rem, env(safe-area-inset-bottom));
  }
}

/* Bildiriş animasiyaları */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes slideUp {
  from {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }

  to {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }
}