html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: #000;
  color: white;
}

/* Pantallas */
.screen {
  position: absolute;
  top: 0;
  left: 0;
  display: none;
  height: 100vh;
  width: 100vw;
  z-index: 0;
}

.screen.active {
  display: flex;
  z-index: 1;
}

/* INTRO */
.intro {
  position: relative;
  width: 100%;
  height: 100vh;
  justify-content: center;
  align-items: center;
  text-align: center;
}


.intro-bg {
  position: absolute;
  inset: 0;
  background-image: url("assets/preview.jpg");
  background-size: cover;
  background-position: center;
  filter: brightness(0.65);
}

.intro-content {
  position: relative;
  z-index: 1;
  padding: 24px;
}

.intro h1 {
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
}

.subtitle {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

button {
  background: rgba(255, 255, 255, 0.9);
  color: #000;
  border: none;
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: 999px;
  cursor: pointer;
}

button:active {
  transform: scale(0.97);
}

.game {
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 12vh;
  background: #111;
}

.game::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("assets/preview.jpg");
  background-size: cover;
  background-position: center;
  opacity: 0.08; /* MUY IMPORTANTE: sutileza */
  z-index: 0;
}

.game > * {
  position: relative;
  z-index: 1;
}

.info {
  width: 100%;
  max-width: 360px;
  text-align: center;
  font-size: 1.4rem;
  line-height: 1.6;
  white-space: pre-line;
  margin-bottom: 2rem;
}

.info.visible {
  opacity: 1;
}

#balloon {
  font-size: 75px;
  position: absolute;
  bottom: -50px;
  left: 50%;
  transform: translateX(-50%);
  animation: floatUp 9s ease-in infinite;
  animation-play-state: paused; 
  cursor: pointer;
  animation-duration: 12s;
}

@keyframes floatUp {
  from {
    bottom: -50px;
    transform: translateX(-50%) translateX(0);
  }
  to {
    bottom: 110%;
    transform: translateX(-50%) translateX(40px);
  }
}

#hint {
  position: absolute;
  bottom: 20%;
  width: 100%;
  text-align: center;
  font-size: 1.2rem;
  opacity: 0.8;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { opacity: 0.4; }
  50% { opacity: 1; }
  100% { opacity: 0.4; }
}

#app {
  position: relative;
  min-height: 100vh;
  width: 100vw;
  overflow: hidden; 
}

.hidden {
  display: none !important;
}

.preview-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  max-width: 360px;
  margin: 0 auto 1.5rem;
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(16px);
}

.preview-thumbnail {
  width: 88px;
  height: 88px;
  border-radius: 16px;
  object-fit: cover;
  flex-shrink: 0;
}

.preview-content {
  text-align: left;
}

.preview-title {
  margin: 0 0 0.35rem;
  font-weight: 700;
  font-size: 1rem;
}

.preview-desc {
  margin: 0 0 0.35rem;
  font-size: 0.92rem;
  line-height: 1.35;
  opacity: 0.88;
}

.preview-url {
  margin: 0;
  font-size: 0.78rem;
  opacity: 0.65;
}

#confetti-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.confetti {
  position: absolute;
  width: 8px;
  height: 14px;
  opacity: 0.9;
  animation: confetti-fall 2.2s ease-out forwards;
}

@keyframes confetti-fall {
  from {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  to {
    transform: translateY(120vh) rotate(720deg);
    opacity: 0;
  }
}

/* =========================
   RESUMEN FINAL ESTÃTICO
   ========================= */

#final {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-width: 360px;
  text-align: center;
}

#final h2 {
  font-size: 2.1rem;
  font-weight: 600;
  margin-bottom: 1.4rem;
}

#final .final-item {
  font-size: 1.3rem;
  line-height: 1.4;
  margin-bottom: 0.6rem;
}

#final .final-item span {
  margin-right: 0.4rem;
}

.final-message {
  font-size: 1.8rem;
  font-weight: 600;
  margin-top: 1.5rem;
  text-align: center;
  opacity: 0.9;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin-top: 1.5rem;
  width: 100%;
  max-width: 320px;
}

.action-btn {
  display: block;
  text-align: center;
  padding: 12px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  text-decoration: none;
  font-size: 1rem;
  backdrop-filter: blur(4px);
}

.action-btn.primary {
  background: white;
  color: black;
  font-weight: 600;
}

/* VISIBILIDAD CONTROLADA PARA FINAL */

.final-message,
.actions {
  visibility: hidden;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.4s ease, max-height 0.4s ease;
}

.final-message.show,
.actions.show {
  visibility: visible;
  opacity: 1;
  max-height: 500px;
}

.rsvp-note {
  font-size: 0.85rem;
  opacity: 0.7;
  text-align: center;
}

#app.scroll-enabled {
  overflow-y: auto;
}

/* Feedback claro de elementos clicables */
.action-btn {
  cursor: pointer;
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.action-btn:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.25);
}

.action-btn.primary:hover {
  background: white;
  color: black;
}











