:root {
  --bg-top: #ffd6e7;
  --bg-bottom: #fff0f6;
  --card: rgba(255, 255, 255, 0.85);
  --text-main: #6e2142;
  --text-soft: #8e4a67;
  --pink: #ff4d8d;
  --pink-dark: #e23979;
  --cream: #fff8f0;
  --mint: #d9ffe9;
  --shadow: 0 20px 45px rgba(173, 55, 106, 0.2);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: "Fredoka", sans-serif;
  color: var(--text-main);
  background: radial-gradient(circle at 15% 20%, #ffe7ef, transparent 35%),
    radial-gradient(circle at 85% 15%, #ffd9e8, transparent 35%),
    linear-gradient(160deg, var(--bg-top), var(--bg-bottom));
  display: grid;
  place-items: center;
  padding: 16px;
  overflow-x: hidden;
}

.bg-hearts {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.bg-hearts span {
  position: absolute;
  opacity: 0.18;
  animation: floatUp 10s linear infinite;
  font-size: clamp(20px, 3vw, 34px);
}

.bg-hearts span:nth-child(1) {
  left: 8%;
  bottom: -8%;
  animation-delay: 0s;
}

.bg-hearts span:nth-child(2) {
  left: 23%;
  bottom: -10%;
  animation-delay: 2s;
}

.bg-hearts span:nth-child(3) {
  left: 39%;
  bottom: -7%;
  animation-delay: 4s;
}

.bg-hearts span:nth-child(4) {
  left: 57%;
  bottom: -9%;
  animation-delay: 1s;
}

.bg-hearts span:nth-child(5) {
  left: 74%;
  bottom: -8%;
  animation-delay: 3s;
}

.bg-hearts span:nth-child(6) {
  left: 88%;
  bottom: -10%;
  animation-delay: 5s;
}

.app {
  width: min(760px, 100%);
  z-index: 1;
}

.card {
  display: none;
  position: relative;
  background: var(--card);
  border: 2px solid #ffd5e4;
  border-radius: 26px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(4px);
  padding: clamp(20px, 4vw, 38px);
  text-align: center;
}

.card.is-active {
  display: block;
  animation: popIn 0.45s ease both;
}

.eyebrow {
  margin: 0 0 8px;
  font-family: "Pacifico", cursive;
  font-size: clamp(1.05rem, 3vw, 1.4rem);
  color: #d23474;
}

h1,
h2 {
  margin: 6px 0 12px;
  line-height: 1.18;
}

h1 {
  font-size: clamp(1.5rem, 5vw, 2.55rem);
}

h2 {
  font-size: clamp(1.45rem, 4.5vw, 2.1rem);
}

.subtitle {
  margin: 0 auto 24px;
  max-width: 35ch;
  color: var(--text-soft);
  font-size: clamp(1rem, 3vw, 1.2rem);
}

.button-zone {
  position: relative;
  min-height: 190px;
  width: min(500px, 100%);
  margin: 0 auto 14px;
}

.btn {
  border: 0;
  border-radius: 999px;
  font-family: inherit;
  font-size: clamp(1rem, 3vw, 1.15rem);
  font-weight: 600;
  padding: 14px 20px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-yes {
  position: absolute;
  left: 50%;
  top: 32%;
  transform: translateX(-50%);
  background: linear-gradient(180deg, #ff70a8, var(--pink));
  color: #fff;
  box-shadow: 0 10px 24px rgba(234, 58, 123, 0.35);
}

.btn-yes:hover {
  transform: translateX(-50%) scale(1.04);
}

.btn-no {
  position: absolute;
  left: 50%;
  top: 70%;
  transform: translateX(-50%);
  background: #fff;
  color: #b54973;
  box-shadow: 0 10px 24px rgba(182, 71, 112, 0.15);
}

.btn-no.fleeing {
  transition: left 0.17s ease, top 0.17s ease;
}

.hint {
  margin: 10px 0 0;
  min-height: 24px;
  color: #b3577c;
  font-size: 0.98rem;
}

.day-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.day-btn {
  border: 2px solid #ffc6da;
  border-radius: 18px;
  background: #fff;
  color: var(--text-main);
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  padding: 14px 10px;
  min-height: 95px;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.day-btn small {
  display: block;
  margin-top: 6px;
  font-weight: 500;
  color: #9a5771;
}

.day-btn:hover {
  transform: translateY(-2px);
  border-color: #ff8cb8;
  box-shadow: 0 10px 20px rgba(186, 82, 122, 0.2);
}

.day-btn.selected {
  background: linear-gradient(180deg, #fff6fa, #ffe7f1);
  border-color: #ff6ea6;
}

.result {
  min-height: 56px;
  margin: 20px auto 0;
  max-width: 44ch;
  font-size: 1.1rem;
  color: #8f2f57;
}

@keyframes floatUp {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 0;
  }
  15% {
    opacity: 0.2;
  }
  85% {
    opacity: 0.2;
  }
  100% {
    transform: translateY(-115vh) rotate(15deg);
    opacity: 0;
  }
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: translateY(6px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 600px) {
  .button-zone {
    min-height: 220px;
  }

  .btn {
    width: min(240px, 90%);
  }

  .btn-yes {
    top: 25%;
  }

  .day-options {
    grid-template-columns: 1fr;
  }
}
