:root {
  color-scheme: dark;
  --card: rgba(99, 91, 152, 0.42);
  --card-edge: rgba(221, 214, 255, 0.26);
  --text: #fff7ff;
  --muted: #e9e0ff;
  --pink: #ff42bd;
  --pink-hot: #ff2aa9;
  --green: #9df5bf;
  --yellow: #ffe275;
  --shadow: rgba(21, 11, 37, 0.7);
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: "Trebuchet MS", "Arial Rounded MT Bold", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 72, 177, 0.28), transparent 28%),
    radial-gradient(circle at 82% 10%, rgba(157, 245, 191, 0.16), transparent 24%),
    radial-gradient(circle at 50% 88%, rgba(255, 226, 117, 0.14), transparent 28%),
    linear-gradient(145deg, #211933 0%, #302247 42%, #151321 100%);
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(circle at center, black, transparent 78%);
}

button {
  font: inherit;
}

.page-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(18px, 5vw, 48px);
}

.invite-card {
  position: relative;
  width: min(100%, 430px);
  min-height: min(680px, calc(100vh - 36px));
  padding: clamp(22px, 6vw, 34px);
  display: grid;
  align-content: center;
  overflow: hidden;
  border: 1px solid var(--card-edge);
  border-radius: 22px;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.08), transparent 30%),
    var(--card);
  box-shadow:
    0 22px 68px var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -1px 22px rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.invite-card::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(circle at 32% 16%, rgba(255, 66, 189, 0.26), transparent 24%),
    radial-gradient(circle at 88% 88%, rgba(141, 248, 255, 0.14), transparent 28%);
}

.progress {
  position: absolute;
  top: 22px;
  left: 50%;
  z-index: 2;
  width: min(58%, 260px);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  transform: translateX(-50%);
}

.progress span {
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
}

.progress .progress-fill {
  background: linear-gradient(90deg, var(--pink), var(--yellow), var(--green));
  box-shadow: 0 0 18px rgba(255, 66, 189, 0.52);
}

.screen {
  position: relative;
  z-index: 1;
  display: none;
  text-align: center;
}

.screen-active {
  display: block;
  animation: floatIn 360ms ease both;
}

.snack-badge {
  width: clamp(92px, 28vw, 132px);
  height: auto;
  margin: 20px auto 10px;
  display: block;
  filter: drop-shadow(0 14px 30px rgba(255, 66, 189, 0.32));
  animation: gentleBob 3.6s ease-in-out infinite;
}

h1,
h2 {
  margin: 0 auto;
  max-width: 10.5em;
  font-family: "Arial Rounded MT Bold", "Trebuchet MS", "Arial Black", sans-serif;
  font-size: clamp(1.85rem, 8.1vw, 3.05rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  text-wrap: balance;
  text-shadow: 0 2px 8px rgba(15, 10, 24, 0.5);
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

h1 span {
  display: block;
  font-size: 0.72em;
}

em {
  color: var(--pink);
  font-style: normal;
  text-shadow: 0 0 9px rgba(255, 66, 189, 0.55);
}

p {
  margin: 14px auto 0;
  max-width: 30rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.button-row {
  position: relative;
  margin-top: 28px;
  min-height: 64px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.yes-button,
.reset-button {
  min-height: 54px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(90deg, #ff73ce, var(--pink-hot), #ff56bd);
  box-shadow:
    0 0 28px rgba(255, 42, 169, 0.75),
    0 12px 28px rgba(123, 8, 82, 0.42);
  transition: transform 160ms ease, filter 160ms ease;
}

.yes-button {
  min-width: min(64vw, 250px);
  padding: 0 24px;
  font-weight: 900;
}

.yes-button:hover,
.yes-button:focus-visible,
.reset-button:hover,
.reset-button:focus-visible {
  transform: translateY(-2px) scale(1.02);
  filter: brightness(1.08);
  outline: none;
}

.no-button {
  min-width: 42px;
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.84);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.06);
  transition:
    transform 220ms ease,
    opacity 220ms ease,
    left 260ms ease,
    top 260ms ease;
  transform-origin: center;
}

.no-button.is-running {
  position: fixed;
  z-index: 20;
  box-shadow: 0 0 18px rgba(255, 255, 255, 0.18);
}

.tiny-note {
  min-height: 1.3em;
  margin-top: 2px;
  font-size: 0.76rem;
  color: rgba(255, 247, 255, 0.68);
}

.emoji-burst,
.confetti-line {
  margin-bottom: 14px;
  color: var(--yellow);
  font-weight: 900;
  font-size: 1.35rem;
  text-shadow: 0 0 10px rgba(255, 226, 117, 0.48);
}

.choice-grid {
  margin-top: 26px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.choice-card {
  min-height: 132px;
  padding: 18px 12px;
  display: grid;
  place-items: center;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  color: var(--text);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 170ms ease, border-color 170ms ease, background 170ms ease;
}

.choice-card span {
  font-size: 1.8rem;
}

.choice-card strong {
  font-size: 1.02rem;
}

.choice-card:hover,
.choice-card:focus-visible {
  border-color: var(--yellow);
  background: rgba(255, 226, 117, 0.1);
  transform: translateY(-2px);
  outline: none;
}

.plan-copy {
  font-size: 1rem;
}

.plan-copy strong {
  color: var(--green);
}

.receipt {
  margin: 24px auto 0;
  padding: 16px;
  max-width: 330px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px;
  text-align: left;
  background: rgba(255, 255, 255, 0.07);
}

.receipt p {
  margin: 0;
  font-size: 0.86rem;
}

.receipt p + p {
  margin-top: 8px;
}

.reset-button {
  margin-top: 24px;
  padding: 0 22px;
  font-size: 0.9rem;
  font-weight: 800;
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes gentleBob {
  0%,
  100% {
    transform: translateY(0) rotate(-1deg);
  }

  50% {
    transform: translateY(-6px) rotate(1deg);
  }
}

@media (max-width: 420px) {
  .invite-card {
    min-height: calc(100vh - 28px);
    border-radius: 18px;
  }

  .button-row {
    gap: 8px;
  }

  .yes-button {
    min-width: 68vw;
    padding: 0 16px;
  }

  .choice-grid {
    grid-template-columns: 1fr;
  }

  .choice-card {
    min-height: 92px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
