@import url("https://fonts.googleapis.com/css2?family=Fredoka:wght@500;600;700&family=Pacifico&display=swap");

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

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  overflow: hidden;
  font-family: "Fredoka", system-ui, sans-serif;
  color: #6a1b6a;
  background: linear-gradient(
    130deg,
    #ff9ff3,
    #feca57,
    #ff6b9d,
    #48dbfb,
    #1dd1a1,
    #f368e0
  );
  background-size: 400% 400%;
  animation: rainbow 14s ease infinite;
}

@keyframes rainbow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ---- floating flowers & butterflies ---- */
.sky {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.float {
  position: absolute;
  font-size: 2.4rem;
  animation: drift linear infinite;
  opacity: 0.9;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.15));
}

@keyframes drift {
  0% { transform: translateY(110vh) rotate(0deg) scale(1); }
  50% { transform: translateY(50vh) rotate(180deg) scale(1.2); }
  100% { transform: translateY(-20vh) rotate(360deg) scale(1); }
}

.f1  { left: 5%;  animation-duration: 13s; animation-delay: 0s; }
.f2  { left: 18%; animation-duration: 17s; animation-delay: 2s; }
.f3  { left: 30%; animation-duration: 11s; animation-delay: 4s; }
.f4  { left: 44%; animation-duration: 19s; animation-delay: 1s; font-size: 3rem; }
.f5  { left: 57%; animation-duration: 15s; animation-delay: 6s; }
.f6  { left: 68%; animation-duration: 12s; animation-delay: 3s; }
.f7  { left: 78%; animation-duration: 18s; animation-delay: 5s; font-size: 3.2rem; }
.f8  { left: 88%; animation-duration: 16s; animation-delay: 2.5s; }
.f9  { left: 95%; animation-duration: 14s; animation-delay: 7s; }
.f10 { left: 12%; animation-duration: 20s; animation-delay: 8s; }

/* ---- the card ---- */
.card {
  position: relative;
  z-index: 1;
  width: min(620px, 100%);
  background: rgba(255, 255, 255, 0.92);
  border: 6px dashed #ff6b9d;
  border-radius: 32px;
  padding: 3.5rem 2.5rem 4.5rem;
  text-align: center;
  box-shadow: 0 20px 50px rgba(214, 51, 132, 0.4);
  animation: bob 4s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(-0.5deg); }
  50% { transform: translateY(-12px) rotate(0.5deg); }
}

.corner {
  position: absolute;
  font-size: 2.2rem;
  animation: spin 6s linear infinite;
}
.tl { top: -18px; left: -18px; }
.tr { top: -18px; right: -18px; }
.bl { bottom: -18px; left: -18px; }
.br { bottom: -18px; right: -18px; }

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.label {
  font-family: "Pacifico", cursive;
  font-size: 1.4rem;
  color: #ee5253;
  margin-bottom: 1.75rem;
  text-shadow: 2px 2px 0 #feca57;
}

.advice {
  font-size: clamp(1.5rem, 4vw, 2.3rem);
  font-weight: 700;
  line-height: 1.4;
  min-height: 3em;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #8e44ad;
  transition: opacity 0.2s ease;
  text-shadow: 1px 1px 0 rgba(255, 107, 157, 0.25);
}

.advice.loading {
  opacity: 0.4;
}

.btn {
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  border: 4px solid #fff;
  cursor: pointer;
  font-family: "Fredoka", sans-serif;
  background: linear-gradient(135deg, #ff6b9d, #feca57);
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  padding: 1rem 2.2rem;
  border-radius: 999px;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.25);
  box-shadow: 0 8px 20px rgba(214, 51, 132, 0.45);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateX(-50%) scale(1.08) rotate(-2deg);
  box-shadow: 0 12px 28px rgba(214, 51, 132, 0.6);
}

.btn:active {
  transform: translateX(-50%) scale(0.95);
}

.btn:disabled {
  opacity: 0.7;
  cursor: wait;
}
