/* ======= Los 40 de Jona — Mobile Page ======= */
@import url('https://fonts.googleapis.com/css2?family=Bangers&family=Space+Mono:wght@400;700&family=Inter:wght@400;500;600;700&display=swap');

/* Force Bangers cursive fallback to be sans, not serif */
@font-face {
  font-family: 'BangersFallback';
  src: local('Impact'), local('Arial Black'), local('Helvetica Neue Bold');
}

:root {
  --bg: #0a0a14;
  --bg-2: #11112a;
  --neon: #39ff14;
  --neon-soft: #6dff4a;
  --magenta: #d946ef;
  --purple: #a855f7;
  --cyan: #22d3ee;
  --ink: #f5f5f7;
  --ink-dim: #a3a3b8;
  --card: rgba(15, 18, 32, 0.85);
  --border: rgba(57, 255, 20, 0.45);
}

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

html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', system-ui, sans-serif;
  overflow-x: hidden;
  min-height: 100vh;
}

body {
  background:
    radial-gradient(ellipse at top, rgba(168, 85, 247, 0.18), transparent 50%),
    radial-gradient(ellipse at bottom, rgba(57, 255, 20, 0.10), transparent 60%),
    var(--bg);
}

/* ===== App container (mobile-first) ===== */
.app {
  max-width: 480px;
  margin: 0 auto;
  position: relative;
  min-height: 100vh;
  padding-bottom: 80px;
}

/* ===== Starfield (fixed background) ===== */
.starfield {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.star {
  position: absolute;
  background: white;
  border-radius: 50%;
  animation: twinkle var(--dur, 3s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}
@keyframes twinkle {
  0%, 100% { opacity: 0.2; transform: scale(0.6); }
  50% { opacity: 1; transform: scale(1.2); }
}

.shooting-star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: white;
  border-radius: 50%;
  box-shadow: 0 0 6px 1px white, 0 0 12px 4px rgba(57, 255, 20, 0.6);
  animation: shoot var(--dur, 4s) linear infinite;
  animation-delay: var(--delay, 0s);
  opacity: 0;
}
.shooting-star::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 0;
  width: 80px;
  height: 1px;
  background: linear-gradient(to left, rgba(57, 255, 20, 0.9), transparent);
  transform: translateY(-50%);
}
@keyframes shoot {
  0% { transform: translate(0, 0) rotate(20deg); opacity: 0; }
  10% { opacity: 1; }
  60% { opacity: 1; }
  100% { transform: translate(400px, 200px) rotate(20deg); opacity: 0; }
}

/* ===== Hero ===== */
.hero {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 900 / 915;
  overflow: hidden;
  border-bottom: 2px solid var(--border);
  box-shadow: 0 8px 32px rgba(57, 255, 20, 0.25);
}

.hero-img-wrap {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  animation: heroFloat 6s ease-in-out infinite;
}
@keyframes heroFloat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-8px) scale(1.01); }
}

/* Portal glow overlay (pulsing radial behind Jona) */
.portal-glow {
  position: absolute;
  top: 42%;
  left: 50%;
  width: 70%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(57, 255, 20, 0.55) 0%, rgba(57, 255, 20, 0.15) 35%, transparent 60%);
  mix-blend-mode: screen;
  animation: portalPulse 2.4s ease-in-out infinite;
  pointer-events: none;
  filter: blur(6px);
}
@keyframes portalPulse {
  0%, 100% { transform: translate(-50%, -50%) scale(0.95); opacity: 0.5; }
  50% { transform: translate(-50%, -50%) scale(1.15); opacity: 0.95; }
}

/* Floating particles around hero */
.hero-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--neon);
  border-radius: 50%;
  box-shadow: 0 0 8px 2px var(--neon);
  animation: floatParticle var(--dur, 6s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  pointer-events: none;
}
@keyframes floatParticle {
  0%, 100% { transform: translate(0, 0); opacity: 0.4; }
  50% { transform: translate(var(--dx, 20px), var(--dy, -30px)); opacity: 1; }
}

/* Title glow ring (subtle vignette pulse on top) */
.hero-glow-ring {
  position: absolute;
  inset: -2px;
  pointer-events: none;
  box-shadow:
    inset 0 0 60px rgba(57, 255, 20, 0.15),
    inset 0 0 120px rgba(168, 85, 247, 0.18);
  animation: ringPulse 3s ease-in-out infinite;
}
@keyframes ringPulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

/* Easter egg invisible button on Jona's head */
.jona-head {
  position: absolute;
  top: 28%;
  left: 50%;
  transform: translateX(-50%);
  width: 35%;
  height: 22%;
  cursor: pointer;
  z-index: 5;
  background: transparent;
  border: none;
  outline: none;
}

/* Section header */
.section-title {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-style: normal;
  font-size: 28px;
  letter-spacing: 2px;
  color: var(--neon);
  text-align: center;
  margin: 32px 16px 20px;
  text-shadow:
    0 0 10px rgba(57, 255, 20, 0.6),
    0 0 24px rgba(57, 255, 20, 0.4);
  position: relative;
  z-index: 2;
}

/* ===== Cards grid ===== */
.cards {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 0 16px;
}

.card {
  perspective: 1200px;
  height: 110px;
  cursor: pointer;
}
.card-tall { height: 130px; }

.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.7s cubic-bezier(0.5, 0, 0.2, 1);
  transform-style: preserve-3d;
}
.card.flipped .card-inner { transform: rotateY(180deg); }

.card-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  border-radius: 14px;
  background: var(--card);
  border: 1.5px solid var(--border);
  box-shadow:
    0 0 0 1px rgba(57, 255, 20, 0.1),
    0 0 18px rgba(57, 255, 20, 0.15),
    inset 0 0 24px rgba(0, 0, 0, 0.4);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  overflow: hidden;
}
.card-front {
  transform: translateZ(1px);
}
.card-back {
  transform: rotateY(180deg) translateZ(1px);
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 8px;
}

/* Icon bubble */
.card-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(57, 255, 20, 0.15));
  border: 1px solid rgba(168, 85, 247, 0.4);
  font-size: 26px;
}
.card-icon.calendar { background: linear-gradient(135deg, #ef4444, #b91c1c); border-color: #fca5a5; }
.card-icon.clock { background: white; border-color: var(--ink); }
.card-icon.pin { background: linear-gradient(135deg, #ef4444, #991b1b); border-color: #fca5a5; }
.card-icon.shirt { background: linear-gradient(135deg, #6b21a8, #1e1b4b); border-color: #c084fc; }
.card-icon.gift { background: linear-gradient(135deg, #ec4899, #831843); border-color: #f9a8d4; }

.card-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.card-label {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 18px;
  letter-spacing: 1.5px;
  color: var(--neon);
  text-shadow: 0 0 8px rgba(57, 255, 20, 0.5);
  line-height: 1;
}
.card-value {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 22px;
  letter-spacing: 1px;
  color: white;
  margin-top: 4px;
  line-height: 1.1;
}
.card-sub {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-dim);
  margin-top: 2px;
  word-break: break-all;
}

.card-hint {
  position: absolute;
  bottom: 6px;
  right: 10px;
  font-family: 'Space Mono', monospace;
  font-size: 9px;
  color: rgba(57, 255, 20, 0.5);
  letter-spacing: 1px;
}

/* Card back actions */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--neon), var(--neon-soft));
  color: #0a0a14;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 13px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 0 16px rgba(57, 255, 20, 0.4);
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:active { transform: scale(0.97); }
.btn-secondary {
  background: transparent;
  color: var(--neon);
  border: 1.5px solid var(--neon);
  box-shadow: none;
}
.btn-purple {
  background: linear-gradient(135deg, var(--purple), var(--magenta));
  color: white;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.4);
}

.back-title {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 16px;
  letter-spacing: 1px;
  color: var(--neon);
  text-align: center;
  margin-bottom: 4px;
}

/* Countdown */
.countdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  text-align: center;
}
.countdown-unit {
  background: rgba(57, 255, 20, 0.08);
  border: 1px solid rgba(57, 255, 20, 0.3);
  border-radius: 8px;
  padding: 6px 2px;
}
.countdown-num {
  font-family: 'Space Mono', monospace;
  font-weight: 700;
  font-size: 18px;
  color: var(--neon);
  text-shadow: 0 0 8px rgba(57, 255, 20, 0.5);
  line-height: 1;
}
.countdown-lbl {
  font-family: 'Inter', sans-serif;
  font-size: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--ink-dim);
  margin-top: 3px;
}

/* Map preview */
.mini-map {
  width: 100%;
  height: 60px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(57, 255, 20, 0.3);
  background: #1a1a2e;
  position: relative;
}

/* RSVP card */
.rsvp-card {
  margin: 24px 16px 0;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(57, 255, 20, 0.08));
  border: 2px solid var(--neon);
  border-radius: 18px;
  padding: 20px 18px;
  position: relative;
  z-index: 2;
  box-shadow:
    0 0 0 4px rgba(57, 255, 20, 0.1),
    0 0 30px rgba(57, 255, 20, 0.3);
  animation: rsvpGlow 2.5s ease-in-out infinite;
}
@keyframes rsvpGlow {
  0%, 100% { box-shadow: 0 0 0 4px rgba(57, 255, 20, 0.1), 0 0 20px rgba(57, 255, 20, 0.25); }
  50% { box-shadow: 0 0 0 4px rgba(57, 255, 20, 0.18), 0 0 40px rgba(57, 255, 20, 0.5); }
}

.rsvp-title {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 26px;
  text-align: center;
  letter-spacing: 2px;
  color: white;
  text-shadow: 0 0 10px rgba(57, 255, 20, 0.7);
  margin-bottom: 14px;
}

.input {
  width: 100%;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.4);
  border: 1.5px solid rgba(57, 255, 20, 0.4);
  border-radius: 10px;
  color: white;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.input:focus {
  border-color: var(--neon);
  box-shadow: 0 0 0 3px rgba(57, 255, 20, 0.2);
}
.input::placeholder { color: rgba(255, 255, 255, 0.4); }

.rsvp-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
}
.rsvp-opt {
  padding: 12px 6px;
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  color: white;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.rsvp-opt:active { transform: scale(0.96); }
.rsvp-opt.active.yes {
  background: rgba(57, 255, 20, 0.2);
  border-color: var(--neon);
  color: var(--neon);
  box-shadow: 0 0 16px rgba(57, 255, 20, 0.4);
}
.rsvp-opt.active.maybe {
  background: rgba(251, 191, 36, 0.2);
  border-color: #fbbf24;
  color: #fbbf24;
  box-shadow: 0 0 16px rgba(251, 191, 36, 0.4);
}
.rsvp-opt.active.no {
  background: rgba(239, 68, 68, 0.2);
  border-color: #ef4444;
  color: #ef4444;
}
.rsvp-emoji { font-size: 18px; }

.rsvp-submit {
  margin-top: 14px;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--neon), var(--neon-soft));
  color: #0a0a14;
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 20px;
  letter-spacing: 2px;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  box-shadow: 0 0 24px rgba(57, 255, 20, 0.5);
  transition: transform 0.15s;
}
.rsvp-submit:active { transform: scale(0.98); }
.rsvp-submit:disabled { opacity: 0.4; cursor: not-allowed; }

/* Confirmed state */
.rsvp-confirmed {
  text-align: center;
  padding: 12px 0;
}
.rsvp-confirmed-emoji { font-size: 56px; margin-bottom: 10px; animation: bounce 1s ease-in-out infinite; }
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}
.rsvp-confirmed-title {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 24px;
  letter-spacing: 2px;
  color: var(--neon);
  text-shadow: 0 0 10px rgba(57, 255, 20, 0.6);
}
.rsvp-confirmed-msg {
  font-size: 13px;
  color: var(--ink-dim);
  margin-top: 6px;
  line-height: 1.5;
}

/* Floating music toggle */
.music-toggle {
  position: fixed;
  bottom: 16px;
  right: 16px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(15, 18, 32, 0.9);
  border: 1.5px solid var(--neon);
  color: var(--neon);
  font-size: 20px;
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(57, 255, 20, 0.4);
  backdrop-filter: blur(8px);
  transition: transform 0.2s;
}
.music-toggle:active { transform: scale(0.92); }
.music-toggle.playing {
  animation: musicPulse 1.2s ease-in-out infinite;
}
@keyframes musicPulse {
  0%, 100% { box-shadow: 0 0 16px rgba(57, 255, 20, 0.4); }
  50% { box-shadow: 0 0 28px rgba(57, 255, 20, 0.8); }
}

/* Footer */
.footer {
  text-align: center;
  margin-top: 32px;
  padding: 0 16px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 1px;
  position: relative;
  z-index: 2;
}

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

/* Easter egg modal */
.easter-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: fadeIn 0.3s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.easter-content {
  background: linear-gradient(135deg, #1a0033, #003318);
  border: 2px solid var(--neon);
  border-radius: 18px;
  padding: 28px 24px;
  text-align: center;
  max-width: 320px;
  box-shadow: 0 0 40px rgba(57, 255, 20, 0.5);
  animation: zoomIn 0.4s cubic-bezier(0.18, 1.25, 0.4, 1.1);
}
@keyframes zoomIn { from { transform: scale(0.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.easter-emoji { font-size: 64px; animation: spin 2s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.easter-title {
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 24px;
  letter-spacing: 2px;
  color: var(--neon);
  margin: 12px 0 8px;
  text-shadow: 0 0 10px rgba(57, 255, 20, 0.6);
}
.easter-msg { font-size: 13px; color: var(--ink-dim); line-height: 1.5; }
.easter-close {
  margin-top: 16px;
  padding: 10px 24px;
  background: var(--neon);
  color: #0a0a14;
  font-family: 'Bangers', 'BangersFallback', Impact, sans-serif;
  font-size: 16px;
  letter-spacing: 1px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 18, 32, 0.95);
  border: 1.5px solid var(--neon);
  color: var(--neon);
  padding: 12px 20px;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  z-index: 150;
  box-shadow: 0 0 20px rgba(57, 255, 20, 0.4);
  animation: toastIn 0.3s ease;
  white-space: nowrap;
}
@keyframes toastIn {
  from { opacity: 0; transform: translate(-50%, 10px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* Variants — pink */
body.variant-pink {
  --neon: #f0abfc;
  --neon-soft: #f5d0fe;
  --border: rgba(240, 171, 252, 0.45);
}
body.variant-cyan {
  --neon: #22d3ee;
  --neon-soft: #67e8f9;
  --border: rgba(34, 211, 238, 0.45);
}
