:root {
  --bg-1: #ffe3ee;
  --bg-2: #ffd1e3;
  --card-bg: rgba(255, 255, 255, 0.78);
  --card-border: rgba(255, 255, 255, 0.75);
  --text: #151515;
  --muted: #555;
  --yes-1: #ff2f7d;
  --yes-2: #ff0f6a;
  --no-bg: #eef1f4;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  --radius: 24px;
  --yes-scale: 1;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  overflow: hidden;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,0.55), transparent 28%),
    radial-gradient(circle at bottom right, rgba(255,255,255,0.35), transparent 24%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2));
}

.app {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 24px;
}

.card {
  width: min(720px, 92vw);
  min-height: 480px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 28px 24px 22px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.emoji {
  font-size: 64px;
  line-height: 1;
  margin-top: 4px;
  user-select: none;
}

.title {
  margin: 18px 0 8px;
  font-size: clamp(28px, 4vw, 54px);
  line-height: 1.06;
  letter-spacing: -0.03em;
  font-weight: 800;
  word-break: break-word;
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.stage {
  position: relative;
  height: 260px;
  margin-top: 26px;
  border-radius: 18px;
}

.stage.is-hidden {
  display: none;
}

.hint {
  position: absolute;
  left: 50%;
  bottom: 6px;
  transform: translateX(-50%);
  margin: 0;
  font-size: 12px;
  color: #666;
  user-select: none;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hint:not([hidden]) {
  opacity: 1;
}

.hint[hidden] {
  display: none !important;
}

.btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font-weight: 800;
  letter-spacing: 0.02em;
  transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.btn:hover {
  filter: brightness(1.03);
}

.btn:active {
  filter: brightness(0.98);
}

.btn.yes {
  position: absolute;
  left: 28%;
  top: 50%;
  transform: translate(-50%, -50%) scale(var(--yes-scale));
  min-width: 108px;
  min-height: 56px;
  padding: 14px 22px;
  background: linear-gradient(180deg, var(--yes-1), var(--yes-2));
  color: #fff;
  font-size: 18px;
}

.btn.no {
  position: absolute;
  left: 72%;
  top: 50%;
  transform: translate(-50%, -50%);
  min-width: 84px;
  min-height: 48px;
  padding: 12px 18px;
  background: var(--no-bg);
  color: #202020;
  font-size: 17px;
}

.btn.yes.pulse {
  animation: yesPulse 0.35s ease;
}

@keyframes yesPulse {
  0% {
    transform: translate(-50%, -50%) scale(var(--yes-scale));
  }
  50% {
    transform: translate(-50%, -50%) scale(calc(var(--yes-scale) * 1.06));
  }
  100% {
    transform: translate(-50%, -50%) scale(var(--yes-scale));
  }
}

.result[hidden] {
  display: none !important;
}

.result {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  animation: fadeIn 0.35s ease;
}

.result-title {
  font-size: clamp(30px, 4vw, 56px);
  font-weight: 900;
  letter-spacing: -0.03em;
  margin: 0;
  line-height: 1;
}

.result-gif {
  width: 260px;
  height: 260px;
  object-fit: cover;
  display: block;
  border-radius: 14px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.16);
}

.footer {
  margin-top: 18px;
  display: flex;
  justify-content: center;
}

.ghost {
  appearance: none;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.75);
  color: #222;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
}

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

@media (max-width: 640px) {
  .card {
    min-height: 520px;
    padding: 24px 18px 18px;
  }

  .title {
    font-size: clamp(26px, 8vw, 42px);
  }

  .stage {
    height: 280px;
  }

  .btn.yes {
    left: 32%;
    min-width: 110px;
    min-height: 58px;
  }

  .btn.no {
    left: 68%;
  }

  .hint {
    font-size: 11px;
    bottom: 2px;
  }

  .result {
    margin-top: 22px;
  }

  .result-gif {
    width: min(260px, 72vw);
    height: min(260px, 72vw);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
