/* ==========================================================================
   RAKHI SURPRISE FOR KHUSHI - STYLESHEET
   Design System: Festive Royal Blue & Gold Theme
   ========================================================================== */

:root {
  /* Color Palette - Festive Royal Blueish Theme */
  --bg-gradient: linear-gradient(135deg, #020b18 0%, #081c38 35%, #003566 70%, #001229 100%);
  --card-bg: rgba(240, 248, 255, 0.94);
  --card-border: rgba(255, 215, 0, 0.55);
  
  --primary-blue: #00509d;
  --primary-cyan: #0096c7;
  --dark-navy: #03045e;
  --secondary-gold: #ffb703;
  --accent-amber: #fb8500;
  
  --text-dark: #020b18;
  --text-muted: #1d3557;
  --text-light: #f0f8ff;

  --gold-gradient: linear-gradient(135deg, #ffe259 0%, #ffa751 100%);
  --blue-gradient: linear-gradient(135deg, #0077b6 0%, #0096c7 50%, #03045e 100%);
  --gold-shine: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.85), transparent);

  /* Shadows & Glows */
  --card-shadow: 0 20px 45px rgba(0, 0, 0, 0.45), 0 0 35px rgba(0, 150, 199, 0.25);
  --btn-glow: 0 8px 25px rgba(0, 119, 182, 0.55), 0 0 18px rgba(255, 215, 0, 0.45);
  --gold-glow: 0 0 25px rgba(255, 215, 0, 0.6);

  /* Typography */
  --font-heading: 'Fredoka', 'Rozha One', cursive, sans-serif;
  --font-body: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 0.5s cubic-bezier(0.68, -0.6, 0.32, 1.6);
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  font-family: var(--font-body);
  background: var(--bg-gradient);
  color: var(--text-dark);
  touch-action: manipulation;
}

/* Particle Canvas Overlay */
#fxCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
}

/* Sound Control Button */
.sound-toggle-btn {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 215, 0, 0.5);
  padding: 8px 14px;
  border-radius: 30px;
  color: var(--text-light);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease, background 0.2s ease;
}

.sound-toggle-btn:active {
  transform: scale(0.92);
}

/* Desktop Floating Side Photo Columns (Left and Right empty space) */
.desktop-side-photos {
  display: block;
}

.side-photo-column {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 20px;
  z-index: 20;
}

.side-column-left {
  left: 2.2%;
}

.side-column-right {
  right: 2.2%;
}

.side-photo-card {
  width: 215px;
  background: #ffffff;
  padding: 8px 8px 12px;
  border-radius: 18px;
  border: 3px solid #ffd700;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), var(--gold-glow);
  transition: transform 0.4s var(--transition-bounce), box-shadow 0.3s ease;
  animation: popScale 0.6s var(--transition-bounce) forwards;
}

.side-column-left .card-top {
  transform: rotate(-6deg);
}

.side-column-left .card-bottom {
  transform: rotate(5deg);
}

.side-column-right .card-top {
  transform: rotate(6deg);
}

.side-column-right .card-bottom {
  transform: rotate(-5deg);
}

.side-photo-card:hover {
  z-index: 30;
  box-shadow: 0 16px 40px rgba(0, 119, 182, 0.55), 0 0 30px rgba(255, 215, 0, 0.85);
  transform: rotate(0deg) scale(1.08) !important;
}

.polaroid-frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.polaroid-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  object-position: center top;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.polaroid-caption {
  font-family: var(--font-heading);
  font-size: 0.88rem;
  color: var(--primary-blue);
  margin-top: 8px;
  font-weight: 700;
}

/* Main Container Layout */
.app-container {
  position: relative;
  z-index: 2;
  width: 100%;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 16px;
}

/* Floating Decorative Elements */
.decorative-rakhi {
  position: fixed;
  font-size: 2.2rem;
  opacity: 0.3;
  pointer-events: none;
  z-index: 1;
  animation: floatRakhi 6s ease-in-out infinite alternate;
}

.left-rakhi {
  top: 10%;
  left: 5%;
}

.right-rakhi {
  bottom: 12%;
  right: 5%;
  animation-delay: -3s;
}

@keyframes floatRakhi {
  0% { transform: translateY(0) rotate(0deg); }
  100% { transform: translateY(-20px) rotate(15deg); }
}

/* Screen Transitions & Cards */
.screen {
  display: none;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  opacity: 0;
  transform: scale(0.94) translateY(15px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.screen.active {
  display: block;
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* Glassmorphism Card Base */
.glass-card {
  background: var(--card-bg);
  border: 2px solid var(--card-border);
  border-radius: 28px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--card-shadow);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  position: relative;
  overflow: hidden;
}

/* Utility Helper Classes */
.hidden {
  display: none !important;
}

.gradient-text {
  background: var(--blue-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.gradient-text-gold {
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Floating Badge */
.floating-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #e0f2fe;
  border: 1px solid var(--primary-cyan);
  color: var(--primary-blue);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Headings & Text */
.main-heading {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 12px;
}

.sub-heading {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 24px;
  font-weight: 500;
}

/* Gift Box Preview Animation */
.gift-box-preview {
  position: relative;
  margin: 20px auto 30px;
  width: 100px;
  height: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.gift-box-icon {
  font-size: 4.5rem;
  filter: drop-shadow(0 8px 15px rgba(0, 119, 182, 0.45));
}

.sparkles-ring {
  position: absolute;
  top: -10px;
  font-size: 1.2rem;
  animation: pulseSparkles 2s ease-in-out infinite alternate;
}

@keyframes pulseSparkles {
  0% { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(1.15); opacity: 1; }
}

.animate-bounce-slow {
  animation: bounceSlow 2.5s infinite;
}

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

/* Buttons */
.primary-btn {
  position: relative;
  width: 100%;
  min-height: 56px;
  padding: 16px 24px;
  background: var(--blue-gradient);
  color: white;
  border: 2px solid #ffd700;
  border-radius: 50px;
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--btn-glow);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease;
}

.primary-btn:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 30px rgba(0, 150, 199, 0.65), 0 0 22px rgba(255, 215, 0, 0.65);
}

.primary-btn:active {
  transform: translateY(1px) scale(0.97);
}

.primary-btn.secondary-style {
  background: linear-gradient(135deg, #03045e 0%, #002855 100%);
  border-color: rgba(255, 215, 0, 0.7);
}

.btn-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: var(--gold-shine);
  transform: skewX(-25deg);
  animation: shine 3s infinite;
}

@keyframes shine {
  0% { left: -100%; }
  20%, 100% { left: 200%; }
}

.pulse-glow {
  animation: pulseGlowBtn 2s infinite alternate;
}

@keyframes pulseGlowBtn {
  0% { box-shadow: var(--btn-glow); }
  100% { box-shadow: 0 10px 30px rgba(0, 150, 199, 0.85), 0 0 25px rgba(255, 215, 0, 0.8); }
}

/* Footer Note & Hyperlink */
.footer-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 24px;
  font-weight: 500;
}

.footer-note.margin-top-card {
  margin-top: 20px;
}

.author-link {
  color: var(--primary-blue);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px dashed var(--primary-cyan);
  padding-bottom: 1px;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.author-link:hover {
  color: var(--dark-navy);
  border-bottom-style: solid;
  border-color: var(--secondary-gold);
}

/* ================= SCREEN 2: PRANK STYLING ================= */
.prank-card {
  min-height: 380px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
}

/* Screen Shake Animation on Slap */
.shake-screen {
  animation: screenShake 0.45s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes screenShake {
  10%, 90% { transform: translate3d(-6px, 2px, 0) rotate(-1deg); }
  20%, 80% { transform: translate3d(8px, -4px, 0) rotate(2deg); }
  30%, 50%, 70% { transform: translate3d(-10px, 5px, 0) rotate(-2deg); }
  40%, 60% { transform: translate3d(10px, -3px, 0) rotate(1deg); }
}

.prank-message-container {
  width: 100%;
  margin-bottom: 24px;
}

.message-box {
  background: rgba(255, 255, 255, 0.95);
  padding: 16px 20px;
  border-radius: 18px;
  font-family: var(--font-heading);
  font-size: 1.3rem;
  color: var(--primary-blue);
  margin-bottom: 14px;
  border: 1px solid #ffd700;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  opacity: 0;
  transform: translateY(10px);
  animation: fadeInUp 0.5s ease forwards;
}

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

.shame-banner {
  margin-top: 15px;
  animation: popScale 0.4s var(--transition-bounce) forwards;
}

.shame-heading {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  color: #d90429;
  text-shadow: 0 4px 10px rgba(217, 4, 41, 0.3);
}

@keyframes popScale {
  0% { transform: scale(0.3); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* Cartoon Slap VFX Layer */
.slap-vfx-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
  display: flex;
  justify-content: center;
  align-items: center;
}

.slap-hand {
  position: absolute;
  font-size: 6.5rem;
  opacity: 0;
  transform: scale(0.2) translate(150px, -150px) rotate(45deg);
}

.slap-hand.animate-slap {
  animation: slapFlyIn 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes slapFlyIn {
  0% { opacity: 0; transform: scale(0.2) translate(200px, -200px) rotate(60deg); }
  60% { opacity: 1; transform: scale(1.3) translate(0, 0) rotate(-15deg); }
  100% { opacity: 0; transform: scale(1) translate(-50px, 30px) rotate(-30deg); }
}

.bonk-badge {
  position: absolute;
  background: #ff0055;
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 2.5rem;
  padding: 8px 24px;
  border-radius: 20px;
  border: 4px solid #fff;
  box-shadow: 0 8px 25px rgba(255, 0, 85, 0.5), 0 0 0 6px #ffd700;
  opacity: 0;
  transform: scale(0.1) rotate(-15deg);
}

.bonk-badge.animate-bonk {
  animation: bonkPop 0.8s var(--transition-bounce) forwards;
}

@keyframes bonkPop {
  0% { opacity: 0; transform: scale(0.1) rotate(-25deg); }
  50% { opacity: 1; transform: scale(1.25) rotate(-10deg); }
  80% { opacity: 1; transform: scale(1) rotate(-12deg); }
  100% { opacity: 0; transform: scale(0.8) rotate(-12deg); }
}

.slap-stars {
  position: absolute;
  font-size: 1.8rem;
  opacity: 0;
}

.slap-stars.animate-stars {
  animation: starsExplosion 0.8s ease-out forwards;
}

@keyframes starsExplosion {
  0% { opacity: 0; transform: scale(0.3); }
  50% { opacity: 1; transform: scale(1.4); }
  100% { opacity: 0; transform: scale(1.8); }
}

/* ================= SCREEN 3: SUSPENSE STYLING ================= */
.suspense-card {
  text-align: center;
}

.teaser-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
}

.teaser-header h2 {
  font-family: var(--font-heading);
  color: var(--primary-blue);
  font-size: 1.4rem;
}

.emoji-tag {
  font-size: 1.8rem;
}

.question-intro {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 24px;
}

.quiz-container {
  margin-bottom: 24px;
}

.quiz-question-btn {
  width: 100%;
  padding: 18px 20px;
  background: #e0f2fe;
  border: 2px dashed var(--primary-cyan);
  border-radius: 20px;
  color: var(--primary-blue);
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.quiz-question-btn:hover {
  background: #bae6fd;
  transform: scale(1.02);
}

.quiz-question-btn:active {
  transform: scale(0.97);
}

/* Reveal Box & Sunglasses Drop */
.reveal-box {
  margin-top: 20px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 24px;
  border: 2px solid #ffd700;
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.3);
  animation: popScale 0.5s var(--transition-bounce) forwards;
}

.brother-avatar-wrapper {
  position: relative;
  width: 90px;
  height: 90px;
  margin: 0 auto 12px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.avatar-face {
  font-size: 4.5rem;
}

.sunglasses {
  position: absolute;
  top: -30px;
  font-size: 2.4rem;
  opacity: 0;
}

.sunglasses.animate-drop {
  animation: dropSunglasses 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards 0.2s;
}

@keyframes dropSunglasses {
  0% { top: -40px; opacity: 0; transform: rotate(-20deg) scale(1.5); }
  70% { top: 22px; opacity: 1; transform: rotate(0deg) scale(1.1); }
  100% { top: 20px; opacity: 1; transform: rotate(0deg) scale(1); }
}

.reveal-punchline {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.teasing-caption {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ================= SCREEN 4: FINAL REVEAL ================= */
.final-reveal-card {
  padding: 36px 20px;
  position: relative;
}

.pre-reveal-text {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  color: var(--primary-blue);
  margin-bottom: 20px;
}

.suspense-loader {
  margin: 20px 0 10px;
}

.gift-box-suspense {
  font-size: 4rem;
  animation: shakeGift 0.5s infinite alternate;
}

@keyframes shakeGift {
  0% { transform: rotate(-10deg) scale(1); }
  100% { transform: rotate(10deg) scale(1.1); }
}

.progress-bar-wrap {
  width: 80%;
  height: 12px;
  background: #bae6fd;
  border-radius: 10px;
  margin: 20px auto 10px;
  overflow: hidden;
  border: 1px solid var(--primary-cyan);
}

.progress-bar-fill {
  width: 0%;
  height: 100%;
  background: var(--blue-gradient);
  border-radius: 10px;
  transition: width 0.1s linear;
}

.suspense-status {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Grand Reveal Display */
.grand-reveal-content {
  position: relative;
  z-index: 2;
}

.gift-tag-badge {
  display: inline-block;
  background: #ffb703;
  color: #020b18;
  font-weight: 800;
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: 12px;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.reveal-sub {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.glowing-brother-card {
  background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 100%);
  border: 3px solid #ffd700;
  border-radius: 24px;
  padding: 24px 16px;
  margin-bottom: 20px;
  box-shadow: var(--gold-glow), 0 10px 25px rgba(0, 0, 0, 0.12);
  position: relative;
  transform: scale(0.95);
  animation: popScale 0.6s var(--transition-bounce) forwards;
}

.crown-icon {
  font-size: 2.8rem;
  margin-bottom: -10px;
}

.brother-name {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  color: var(--primary-blue);
  margin-bottom: 6px;
}

.brother-title {
  font-size: 1.1rem;
  color: #0077b6;
  font-weight: 700;
  margin-bottom: 14px;
}

.guarantee-badge {
  display: inline-block;
  background: rgba(255, 183, 3, 0.25);
  border: 1px dashed #fb8500;
  padding: 8px 12px;
  border-radius: 14px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #03045e;
}

/* Mobile Sibling Photos Grid */
.mobile-sibling-photos {
  display: none;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 18px 0;
  width: 100%;
}

.photo-card {
  background: #ffffff;
  padding: 6px 6px 10px;
  border-radius: 14px;
  border: 2px solid #ffd700;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.photo-card .polaroid-img {
  height: 120px;
}

.photo-card .polaroid-caption {
  font-size: 0.75rem;
  margin-top: 6px;
}

.heartfelt-message {
  margin-bottom: 24px;
}

.final-wish {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--primary-blue);
  margin-bottom: 4px;
}

.love-always {
  font-size: 1.15rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Action Buttons Group */
.action-buttons-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.action-btn {
  width: 100%;
  padding: 14px 18px;
  border-radius: 18px;
  border: 2px solid transparent;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.action-btn:hover {
  transform: translateY(-2px);
}

.action-btn:active {
  transform: scale(0.96);
}

.hug-btn {
  background: #0096c7;
  color: white;
  box-shadow: 0 4px 15px rgba(0, 150, 199, 0.45);
}

.revenge-btn {
  background: #ffb703;
  color: #020b18;
  box-shadow: 0 4px 15px rgba(255, 183, 3, 0.45);
}

.replay-btn {
  background: #fff;
  color: var(--primary-blue);
  border-color: var(--primary-cyan);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

/* Responsive Breakpoints for Desktop Side Photos */
@media (max-width: 980px) {
  .desktop-side-photos {
    display: none !important;
  }

  .mobile-sibling-photos {
    display: grid;
  }
}

@media (max-width: 380px) {
  .glass-card {
    padding: 24px 16px;
  }

  .main-heading {
    font-size: 1.8rem;
  }

  .brother-name {
    font-size: 1.6rem;
  }

  .primary-btn {
    font-size: 1.05rem;
    padding: 14px 18px;
  }
}
