:root {
  --bg-1: #fff5f8;
  --bg-2: #eef6ff;
  --bg-3: #fffbe6;
  --pink: #ffb3c7;
  --pink-deep: #ff7aa2;
  --blue: #b8dcff;
  --yellow: #fff0a8;
  --green: #cdeccd;
  --ink: #3a2a3a;
  --ink-soft: #6b5c6b;
  --card: #ffffff;
  --card-shadow: 0 12px 40px rgba(255, 122, 162, 0.15),
    0 2px 6px rgba(58, 42, 58, 0.06);
  --radius: 22px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Quicksand", system-ui, -apple-system, sans-serif;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.55;
  background:
    radial-gradient(at 20% 0%, var(--bg-1) 0%, transparent 50%),
    radial-gradient(at 80% 30%, var(--bg-2) 0%, transparent 55%),
    radial-gradient(at 50% 100%, var(--bg-3) 0%, transparent 55%),
    #fffafd;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 640px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

/* HERO */
.hero {
  text-align: center;
  padding: 24px 8px 8px;
}

.hero-art {
  width: 180px;
  height: 180px;
  margin: 0 auto 8px;
  border-radius: 50%;
  overflow: hidden;
  filter: drop-shadow(0 8px 20px rgba(255, 122, 162, 0.25));
  animation: float 6s ease-in-out infinite;
}

.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  color: var(--ink-soft);
  margin: 8px 0 4px;
}

.hero h1 {
  font-family: "Pacifico", cursive;
  font-weight: 400;
  font-size: clamp(2.4rem, 8vw, 3.4rem);
  margin: 0 0 8px;
  color: var(--pink-deep);
  line-height: 1.1;
}

.subtitle {
  font-size: 1.05rem;
  color: var(--ink-soft);
  margin: 0 auto;
  max-width: 28ch;
}

/* CARDS */
.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--card-shadow);
  margin-top: 28px;
}

.card h2 {
  font-family: "Pacifico", cursive;
  font-weight: 400;
  color: var(--pink-deep);
  font-size: 1.7rem;
  margin: 0 0 16px;
  text-align: center;
}

/* DETAILS */
.detail-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
}

.detail-list li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: linear-gradient(135deg, #fff5f8, #fffafd);
  border-radius: var(--radius-sm);
}

.detail-icon {
  font-size: 1.5rem;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  background: #fff;
  border-radius: 50%;
  flex-shrink: 0;
}

.detail-list strong {
  display: block;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  font-weight: 600;
}

.detail-list span:not(.detail-icon) {
  font-size: 1.05rem;
}

.detail-list a {
  color: var(--pink-deep);
  text-decoration: none;
  font-weight: 600;
}

.detail-list a:hover {
  text-decoration: underline;
}

.note {
  margin: 18px 0 16px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.calendar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  background: var(--bg-2);
  color: var(--ink);
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.15s ease, background 0.2s ease;
}

.calendar-btn:hover {
  background: #d6e9ff;
  transform: translateY(-1px);
}

.calendar-btn span {
  font-size: 1.2rem;
  color: var(--pink-deep);
}

/* FORM */
.rsvp-deadline {
  text-align: center;
  color: var(--ink-soft);
  margin: -8px 0 20px;
  font-size: 0.95rem;
}

#rsvp-form {
  display: grid;
  gap: 16px;
}

.field {
  display: grid;
  gap: 6px;
}

.field > span,
.field legend {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
  padding: 0;
}

.field em {
  color: var(--pink-deep);
  font-style: normal;
}

.field input[type="text"],
.field input[type="number"],
.field textarea {
  font: inherit;
  width: 100%;
  padding: 12px 14px;
  border: 2px solid #f0e3ec;
  border-radius: var(--radius-sm);
  background: #fffafd;
  color: var(--ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease,
    background 0.2s ease;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--pink);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 179, 199, 0.25);
}

.field textarea {
  resize: vertical;
  min-height: 60px;
}

.attending {
  border: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

.attending legend {
  margin-bottom: 6px;
}

.radio {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 2px solid #f0e3ec;
  border-radius: var(--radius-sm);
  background: #fffafd;
  cursor: pointer;
  transition: all 0.15s ease;
}

.radio:hover {
  border-color: var(--pink);
}

.radio input {
  accent-color: var(--pink-deep);
  width: 18px;
  height: 18px;
  margin: 0;
}

.radio:has(input:checked) {
  border-color: var(--pink-deep);
  background: #fff5f8;
}

/* honeypot — hidden from humans, visible to bots */
.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

button[type="submit"] {
  margin-top: 8px;
  padding: 14px 20px;
  font: inherit;
  font-weight: 700;
  font-size: 1.05rem;
  color: #fff;
  background: linear-gradient(135deg, var(--pink-deep), #ff9ec1);
  border: none;
  border-radius: 999px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 8px 20px rgba(255, 122, 162, 0.35);
  transition: transform 0.15s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

button[type="submit"]:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(255, 122, 162, 0.45);
}

button[type="submit"]:active:not(:disabled) {
  transform: translateY(0);
}

button[type="submit"]:disabled {
  opacity: 0.7;
  cursor: progress;
}

.btn-spinner {
  display: none;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

button[type="submit"].loading .btn-spinner {
  display: inline-block;
}

button[type="submit"].loading .btn-label {
  opacity: 0.85;
}

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

.form-status {
  margin: 4px 0 0;
  text-align: center;
  font-weight: 600;
  min-height: 1.2em;
}

.form-status.success {
  color: #2f8a4a;
}

.form-status.error {
  color: #c0334d;
}

/* SUCCESS STATE */
.thank-you {
  text-align: center;
  padding: 8px 4px;
}

.thank-you h2 {
  margin-bottom: 8px;
}

.thank-you p {
  color: var(--ink-soft);
  margin: 0;
}

.thank-you .emoji {
  font-size: 3rem;
  display: block;
  margin-bottom: 8px;
}

/* FOOTER */
.footer {
  text-align: center;
  margin-top: 32px;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

@media (max-width: 480px) {
  .page {
    padding: 20px 14px 40px;
  }

  .card {
    padding: 22px 18px;
  }

  .hero-art {
    width: 140px;
    height: 140px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-art {
    animation: none;
  }
  .btn-spinner {
    animation-duration: 1.5s;
  }
}
