* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  background: pink;
  font-family: monospace;
  height: 100vh;
  overflow: hidden; /* keep this */
  padding: 16px;
}

/* ================= MAIN CONTAINER ================= */

#container {
  position: relative;
  z-index: 2;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

  animation: popIn 0.6s ease;
}

/* ================= TEXT ================= */

#text {
  font-size: clamp(22px, 6vw, 36px);
  margin-bottom: 20px;
  text-align: center;
  padding: 0 12px;
  transition: opacity 0.5s, transform 0.5s;
}

/* ================= BUTTONS ================= */

#buttons {
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: opacity 0.5s, transform 0.5s;
  position: relative; /* fine for normal buttons */
}

.fade-out {
  opacity: 0;
  transform: translateY(-10px);
}

button {
  width: min(90vw, 280px);
  min-height: 44px;
  padding: 12px 22px;
  margin: 8px;
  font-size: 16px;
  border: none;
  background: white;
  cursor: pointer;
  border-radius: 8px;
}

button.smooth {
  transition: all 0.3s ease;
}

/* ================= RUNAWAY BUTTONS (FIXED) ================= */

/*
  IMPORTANT:
  - MUST be position: fixed
  - NOT absolute
  - otherwise it gets clipped by #buttons / body
*/
.runaway {
  position: fixed;          /* 🔥 THE REAL FIX */
  z-index: 1;
  pointer-events: auto;

  transition: left 0.15s ease-out, top 0.15s ease-out;
}

/* normal buttons always stay above */
#buttons button:not(.runaway) {
  position: relative;
  z-index: 2;
}

/* ================= VIDEO ================= */

video {
  display: none;
  max-width: 95vw;
  max-height: 60vh;
  border-radius: 12px;
  background: black;
  opacity: 0;
  transition: opacity 0.6s;
}

video.show {
  display: block;
  opacity: 1;
}

/* ================= KISS IMAGE ================= */

#kissImg {
  display: none;
  width: min(80vw, 320px);
}

/* ================= FALLING HEARTS ================= */

.heart {
  position: fixed; /* also escape clipping */
  color: hotpink;
  font-size: 18px;
  animation: fall linear forwards;
  pointer-events: none;
}

@keyframes fall {
  to {
    transform: translateY(100vh);
    opacity: 0;
  }
}

/* ================= ENTRANCE ANIMATION ================= */

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ===== TEXT FADE ===== */
#text {
  opacity: 1;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.text-hide {
  opacity: 0;
  transform: translateY(-6px);
}

/* ===== BUTTON POP ===== */
button.pop {
  animation: pop 0.25s ease;
}

@keyframes pop {
  0% {
    transform: scale(0.92);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

#topAction {
  margin-bottom: 18px;
}

/* ===== TEXT ANIMATION ===== */
#text {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

#text.show {
  opacity: 1;
  transform: translateY(0);
}

/* ===== CORNER BUTTONS ===== */
#topLeft {
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 10;
}

#bottomRight {
  position: fixed;
  bottom: 16px;
  right: 16px;
  z-index: 10;
}

/* ===== BIG YAY ===== */
.bigText {
  font-size: clamp(32px, 8vw, 56px);
  font-weight: bold;
}


