*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Paytone One", system-ui, sans-serif;
  background: #507EA6;
  background: linear-gradient(135deg, #3B5D7B, #507EA6, #2B4459);
  color: #fff;
  overflow: hidden;
}

#app {
  text-align: center;
  padding: 2rem;
  z-index: 10;
  position: relative;
}

.title {
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 2rem;
  line-height: 1.2;
}

.title span {
  color: #f9a825;
  display: block;
}

.screen { display: none; }
.screen.visible { display: block; animation: fadeIn 0.6s ease; }
.hidden { display: none; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.answer {
  font-size: clamp(3rem, 15vw, 8rem);
  font-weight: 900;
  line-height: 1;
  margin-bottom: 1rem;
}

.answer.no  { color: #FF5350; }
.answer.yes {
  color: #75C25D;
  animation: pulse 1s ease-in-out infinite alternate;
}

@keyframes pulse {
  from { transform: scale(1); text-shadow: 0 0 20px #5B9749; }
  to   { transform: scale(1.05); text-shadow: 0 0 40px #6FB959; }
}

.subtitle {
  font-size: clamp(1rem, 3vw, 1.4rem);
  opacity: 0.8;
  margin-bottom: 2rem;
}

/* Countdown */
.countdown {
  display: flex;
  gap: clamp(0.5rem, 2vw, 1.5rem);
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.unit {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: clamp(0.6rem, 2vw, 1rem) clamp(0.8rem, 2.5vw, 1.4rem);
  min-width: 70px;
  backdrop-filter: blur(6px);
}

.unit span {
  display: block;
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #f9a825;
}

.unit label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.6;
}

/* Yes screen emojis */
.emojis {
  font-size: clamp(2rem, 8vw, 4rem);
  margin: 1rem 0;
  display: flex;
  justify-content: center;
  gap: 0.3em;
  flex-wrap: wrap;
}

.emojis span {
  display: inline-block;
  opacity: 0;
  animation: pop-in 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, float 3s ease-in-out infinite;
  animation-delay: calc(var(--i) * 0.12s), calc(var(--i) * 0.12s + 0.6s);
}

.emojis span:nth-child(1) { --i: 0; }
.emojis span:nth-child(2) { --i: 1; }
.emojis span:nth-child(3) { --i: 2; }
.emojis span:nth-child(4) { --i: 3; }
.emojis span:nth-child(5) { --i: 4; }
.emojis span:nth-child(6) { --i: 5; }
.emojis span:nth-child(7) { --i: 6; }

@keyframes pop-in {
  0%   { transform: scale(0) rotate(-15deg); opacity: 0; }
  100% { transform: scale(1) rotate(0deg);   opacity: 1; }
}

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

/* Credit link */
.credit {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.75rem;
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  letter-spacing: 0.5px;
  z-index: 20;
  transition: color 0.2s;
}

.credit:hover { color: rgba(255,255,255,0.7); }
#confetti-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 5;
}
