/* assets/css/style.css - Romantik, Modern & Glassmorphic Tasarım */
@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@600;700&family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,600;0,700;1,400&display=swap');

:root {
  --bg-gradient: radial-gradient(circle at 20% 20%, #1f0b27 0%, #0d0414 50%, #050108 100%);
  --card-bg: rgba(28, 12, 38, 0.65);
  --card-border: rgba(255, 117, 140, 0.25);
  --card-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 35px rgba(255, 107, 137, 0.15);
  
  --primary-pink: #ff6584;
  --secondary-pink: #ff8fa3;
  --rose-gold: #f7a8b8;
  --glow-pink: rgba(255, 101, 132, 0.4);
  --gold-accent: #fcd34d;
  
  --text-primary: #ffffff;
  --text-secondary: #fbcfe8;
  --text-muted: #d8b4e2;
  
  --font-main: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-script: 'Dancing Script', cursive;
  
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-main);
  background: #09030e;
  background-image: var(--bg-gradient);
  color: var(--text-primary);
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow-x: hidden;
  position: relative;
  selection-background-color: var(--primary-pink);
  selection-color: #fff;
}

/* Background floating canvas */
#canvas-hearts {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

/* Floating ambient glowing orbs */
.ambient-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  z-index: 0;
  pointer-events: none;
  opacity: 0.45;
  animation: floatOrb 14s ease-in-out infinite alternate;
}

.glow-1 {
  width: 380px;
  height: 380px;
  top: -100px;
  right: -50px;
  background: radial-gradient(circle, #ff416c, transparent 70%);
}

.glow-2 {
  width: 420px;
  height: 420px;
  bottom: -120px;
  left: -80px;
  background: radial-gradient(circle, #8a2387, transparent 70%);
  animation-duration: 18s;
  animation-delay: -5s;
}

@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, -30px) scale(1.1); }
  100% { transform: translate(-30px, 40px) scale(0.95); }
}

/* App Main Container */
.app-container {
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
  padding: 20px;
  z-index: 2;
  position: relative;
  perspective: 1000px;
}

/* Glass Card */
.glass-card {
  background: var(--card-bg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: var(--card-shadow);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 160, 180, 0.8), transparent);
  animation: shimmerBorder 6s linear infinite;
}

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

/* Screen Transitions */
.screen {
  display: none;
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.screen.active {
  display: block;
  opacity: 1;
  transform: translateY(0) scale(1);
  animation: cardFadeIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes cardFadeIn {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Typography & Titles */
.icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 101, 132, 0.25), rgba(138, 35, 135, 0.25));
  border: 1px solid rgba(255, 120, 150, 0.4);
  box-shadow: 0 0 25px var(--glow-pink);
  margin-bottom: 18px;
  font-size: 30px;
  animation: pulseIcon 3s ease-in-out infinite;
}

@keyframes pulseIcon {
  0%, 100% { transform: scale(1); box-shadow: 0 0 20px var(--glow-pink); }
  50% { transform: scale(1.06); box-shadow: 0 0 32px rgba(255, 101, 132, 0.6); }
}

.card-title {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.card-subtitle {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Romantic Note Box (WhatsApp Request) */
.romantic-note-box {
  background: linear-gradient(135deg, rgba(255, 101, 132, 0.15), rgba(186, 66, 140, 0.15));
  border: 1px dashed rgba(255, 140, 160, 0.45);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  margin-bottom: 24px;
  text-align: left;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  box-shadow: inset 0 0 20px rgba(255, 80, 120, 0.08);
}

.romantic-note-box .note-icon {
  font-size: 24px;
  line-height: 1;
  flex-shrink: 0;
  animation: heartWiggle 2s infinite ease-in-out;
}

@keyframes heartWiggle {
  0%, 100% { transform: rotate(0deg) scale(1); }
  25% { transform: rotate(-8deg) scale(1.1); }
  75% { transform: rotate(8deg) scale(1.1); }
}

.romantic-note-box p {
  color: #fff;
  font-size: 13.5px;
  line-height: 1.55;
  font-weight: 500;
}

.romantic-note-box .note-highlight {
  color: #ffb3c1;
  font-weight: 600;
}

/* PIN Display Dots */
.pin-dots {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 28px;
}

.pin-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 130, 160, 0.4);
  background: rgba(255, 255, 255, 0.05);
  transition: var(--transition-smooth);
}

.pin-dot.filled {
  background: linear-gradient(135deg, var(--primary-pink), var(--secondary-pink));
  border-color: var(--primary-pink);
  box-shadow: 0 0 16px var(--primary-pink);
  transform: scale(1.15);
}

.pin-dot.error {
  background: #ef4444;
  border-color: #ef4444;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.8);
}

/* Shake Animation */
.shake {
  animation: shakeEffect 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes shakeEffect {
  10%, 90% { transform: translate3d(-3px, 0, 0); }
  20%, 80% { transform: translate3d(5px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-6px, 0, 0); }
  40%, 60% { transform: translate3d(6px, 0, 0); }
}

/* PIN Keypad Grid */
.pin-keypad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 290px;
  margin: 0 auto;
}

.keypad-btn {
  height: 60px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  color: #fff;
  font-size: 22px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-smooth);
  user-select: none;
  font-family: var(--font-main);
}

.keypad-btn:hover {
  background: rgba(255, 101, 132, 0.22);
  border-color: rgba(255, 101, 132, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(255, 101, 132, 0.25);
}

.keypad-btn:active {
  transform: scale(0.94);
  background: rgba(255, 101, 132, 0.4);
}

.keypad-btn.action-btn {
  font-size: 17px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
}

/* Form Styles */
.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
  letter-spacing: 0.2px;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 16px;
  font-size: 18px;
  color: var(--rose-gold);
  pointer-events: none;
}

.form-control {
  width: 100%;
  padding: 14px 18px 14px 48px;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 120, 150, 0.25);
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 15px;
  font-family: var(--font-main);
  outline: none;
  transition: var(--transition-smooth);
}

.form-control:focus {
  background: rgba(255, 255, 255, 0.09);
  border-color: var(--primary-pink);
  box-shadow: 0 0 20px var(--glow-pink);
}

.form-control::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.toggle-password {
  position: absolute;
  right: 14px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
}

/* Buttons */
.btn-primary {
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #ff416c, #ff4b2b);
  background: linear-gradient(135deg, #ff5376 0%, #ff758c 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(255, 83, 118, 0.4);
  transition: var(--transition-smooth);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  letter-spacing: 0.3px;
  font-family: var(--font-main);
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(255, 83, 118, 0.6);
  filter: brightness(1.08);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
}

/* Message Feedback */
.status-msg {
  min-height: 24px;
  margin-top: 14px;
  font-size: 13.5px;
  font-weight: 500;
  transition: var(--transition-smooth);
}

.status-msg.error {
  color: #f87171;
}

.status-msg.success {
  color: #34d399;
}

/* Q&A Game Screen */
.quiz-header {
  margin-bottom: 20px;
}

.quiz-step-badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 20px;
  background: rgba(255, 101, 132, 0.2);
  border: 1px solid rgba(255, 101, 132, 0.4);
  color: var(--secondary-pink);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.quiz-question-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: 22px 20px;
  margin-bottom: 24px;
  text-align: center;
}

.quiz-question-text {
  font-family: var(--font-serif);
  font-size: 19px;
  color: #fff;
  line-height: 1.5;
  font-style: italic;
}

.quiz-options-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.option-btn {
  width: 100%;
  padding: 15px 18px;
  text-align: left;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: #f3e8ff;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition-smooth);
  display: flex;
  align-items: center;
  gap: 14px;
  position: relative;
}

.option-btn .option-indicator {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--secondary-pink);
  flex-shrink: 0;
  transition: var(--transition-smooth);
}

.option-btn:hover {
  background: rgba(255, 101, 132, 0.18);
  border-color: rgba(255, 101, 132, 0.5);
  transform: translateX(4px);
}

.option-btn:hover .option-indicator {
  background: var(--primary-pink);
  color: #fff;
}

.option-btn.correct {
  background: rgba(16, 185, 129, 0.25) !important;
  border-color: #10b981 !important;
  color: #a7f3d0 !important;
}

.option-btn.correct .option-indicator {
  background: #10b981;
  color: #fff;
}

.option-btn.wrong {
  background: rgba(239, 68, 68, 0.25) !important;
  border-color: #ef4444 !important;
  color: #fca5a5 !important;
  animation: shakeEffect 0.4s ease;
}

.option-btn.wrong .option-indicator {
  background: #ef4444;
  color: #fff;
}

/* Final Celebration Screen */
.celebration-card {
  max-width: 640px;
}

.confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 99;
}

.birthday-badge {
  font-size: 42px;
  display: inline-block;
  margin-bottom: 10px;
  animation: bounceTada 2s infinite ease-in-out;
}

@keyframes bounceTada {
  0%, 100% { transform: scale(1) rotate(0deg); }
  20% { transform: scale(1.15) rotate(-10deg); }
  40% { transform: scale(1.15) rotate(10deg); }
  60% { transform: scale(1.1) rotate(-5deg); }
}

.celebration-title {
  font-family: var(--font-serif);
  font-size: 30px;
  background: linear-gradient(135deg, #ffffff, #fbcfe8, #ff8fa3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
}

.celebration-subtitle {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 24px;
}

/* Photo Gallery (Polaroids) */
.polaroid-gallery {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin: 24px 0;
  flex-wrap: wrap;
}

.polaroid-item {
  background: #ffffff;
  padding: 10px 10px 18px 10px;
  border-radius: 8px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  max-width: 160px;
  cursor: pointer;
}

.polaroid-item:nth-child(1) { --rot: -4deg; }
.polaroid-item:nth-child(2) { --rot: 3deg; }
.polaroid-item:nth-child(3) { --rot: -2deg; }

.polaroid-item:hover {
  transform: scale(1.1) rotate(0deg);
  z-index: 10;
  box-shadow: 0 20px 40px rgba(255, 101, 132, 0.4);
}

.polaroid-item img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 4px;
  display: block;
}

.polaroid-item .caption {
  color: #333;
  font-family: var(--font-script);
  font-size: 14px;
  margin-top: 8px;
  text-align: center;
}

/* Romantic Letter */
.love-letter-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 130, 160, 0.25);
  border-radius: var(--radius-md);
  padding: 24px;
  margin: 20px 0;
  text-align: left;
  position: relative;
}

.love-letter-box::before {
  content: '“';
  position: absolute;
  top: 6px;
  left: 14px;
  font-family: var(--font-serif);
  font-size: 60px;
  color: rgba(255, 101, 132, 0.2);
  line-height: 1;
}

.love-letter-content {
  font-family: var(--font-main);
  font-size: 15px;
  line-height: 1.8;
  color: #fff;
  white-space: pre-line;
  position: relative;
  z-index: 1;
}

/* Floating Audio Player Widget */
.floating-music-player {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(28, 12, 38, 0.85);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 101, 132, 0.35);
  padding: 8px 16px 8px 10px;
  border-radius: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(255, 101, 132, 0.2);
  transition: var(--transition-smooth);
}

.floating-music-player:hover {
  transform: translateY(-2px);
  border-color: var(--primary-pink);
}

.vinyl-disc {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff6584 15%, #111 25%, #222 65%, #ff758c 100%);
  border: 2px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 0 10px rgba(255, 101, 132, 0.4);
  cursor: pointer;
  animation: spinVinyl 5s linear infinite;
  animation-play-state: paused;
  flex-shrink: 0;
}

.vinyl-disc.playing {
  animation-play-state: running;
}

@keyframes spinVinyl {
  100% { transform: rotate(360deg); }
}

.music-info {
  display: flex;
  flex-direction: column;
}

.music-title {
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  max-width: 140px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-status {
  font-size: 10px;
  color: var(--rose-gold);
}

.music-btn {
  background: none;
  border: none;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
}

/* Floating Love Button */
.heart-burst-btn {
  background: linear-gradient(135deg, #ff416c, #ff4b2b);
  border: none;
  padding: 14px 28px;
  border-radius: 50px;
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(255, 75, 43, 0.4);
  transition: var(--transition-smooth);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 15px;
}

.heart-burst-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 15px 35px rgba(255, 75, 43, 0.6);
}

.heart-burst-btn:active {
  transform: scale(0.95);
}

/* Responsive adjustments */
@media (max-width: 480px) {
  .app-container {
    padding: 14px;
  }
  .glass-card {
    padding: 28px 20px;
    border-radius: 22px;
  }
  .keypad-btn {
    height: 54px;
    font-size: 20px;
  }
  .card-title {
    font-size: 22px;
  }
  .polaroid-item {
    max-width: 130px;
  }
  .polaroid-item img {
    height: 110px;
  }
}
