/* 僅供首頁回覆示範；沿用心頁色票與共用動效曲線。 */
.rsvp-live[hidden],
.rsvp-live [hidden] { display: none; }
.rsvp-live .nb { display: inline-block; }

.rsvp-stage {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: var(--space-8);
}
.rsvp-form,
.rsvp-list {
  min-width: 0;
  padding: var(--space-4);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.rsvp-cap {
  margin-bottom: var(--space-2);
  color: var(--muted);
  font-size: var(--text-xs);
  letter-spacing: .08em;
}
.rsvp-form h3 {
  margin-bottom: var(--space-3);
  font-family: var(--font-title);
}
.rsvp-field {
  display: grid;
  min-width: 0;
  gap: var(--space-1);
  margin-bottom: var(--space-3);
  font-size: var(--text-sm);
}
.rsvp-field input {
  width: 100%;
  min-width: 0;
  height: 48px;
  padding-inline: var(--space-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: max(16px, 1rem);
}
.rsvp-field input::placeholder { color: var(--muted); }
.rsvp-field input:focus { border-color: var(--rose); }
.rsvp-live input:focus-visible,
.rsvp-live button:focus-visible {
  outline: 2px solid var(--rose);
  outline-offset: 5px;
}
.rsvp-hint {
  margin-top: calc(-1 * var(--space-2));
  margin-bottom: var(--space-3);
  color: var(--rose);
  font-size: var(--text-sm);
}
.rsvp-step,
.rsvp-diet { display: flex; align-items: center; gap: var(--space-1); }
.rsvp-live button {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  transition: transform 150ms var(--fx-out, cubic-bezier(.23, 1, .32, 1));
}
.rsvp-step button,
.rsvp-diet button {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  background: var(--surface);
}
.rsvp-diet button { width: 72px; }
.rsvp-diet button[aria-pressed="true"] {
  border-color: var(--rose);
  color: var(--surface);
  background: var(--rose);
}
.rsvp-step output {
  min-width: 48px;
  text-align: center;
  font-size: 1.5rem;
  font-variant-numeric: tabular-nums;
}
.rsvp-live button:disabled { opacity: .45; cursor: default; }
.rsvp-live .button {
  width: 100%;
  border-color: var(--rose);
  background: var(--rose);
  color: var(--surface);
  transform: none;
}
.rsvp-live button:active:not(:disabled) { transform: scale(.98); }
.rsvp-total {
  margin-bottom: var(--space-3);
  font-size: 1.125rem;
  font-variant-numeric: tabular-nums;
}
.rsvp-total b { color: var(--rose); }
.rsvp-rows { margin: 0; padding: 0; list-style: none; }
.rsvp-row {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 3.5em 2em 2.5em;
  align-items: center;
  gap: var(--space-1);
  min-width: 0;
  padding-block: var(--space-2);
  font-size: var(--text-sm);
}
.rsvp-row + .rsvp-row { border-top: 1px solid var(--line); }
.rsvp-row > span { min-width: 0; white-space: nowrap; }
.rsvp-name { overflow: hidden; text-overflow: ellipsis; }
.rsvp-amount { text-align: right; font-variant-numeric: tabular-nums; }
.rsvp-meal { justify-self: end; }
.rsvp-meal.is-veg {
  padding-inline: calc(var(--space-1) / 2);
  border-radius: var(--radius);
  background: var(--sand2);
  color: var(--rose);
  font-size: var(--text-xs);
}
.rsvp-time { text-align: right; color: var(--muted); font-size: var(--text-xs); }
.rsvp-row.is-new {
  animation: rsvp-arrive 250ms var(--fx-out, cubic-bezier(.23, 1, .32, 1)) both;
}
.rsvp-row.is-new::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--rose);
  opacity: 0;
  pointer-events: none;
  animation: rsvp-tint 1200ms var(--fx-out, cubic-bezier(.23, 1, .32, 1)) both;
}
.rsvp-reset {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  margin-top: var(--space-2);
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: var(--text-sm);
  text-decoration: underline;
  text-underline-offset: 6px;
}
@keyframes rsvp-arrive {
  from { opacity: 0; translate: 0 8px; }
  to { opacity: 1; translate: 0 0; }
}
@keyframes rsvp-tint {
  from { opacity: .08; }
  to { opacity: 0; }
}
@media (hover: hover) and (pointer: fine) {
  .rsvp-step button:hover:not(:disabled),
  .rsvp-diet button:hover:not(:disabled) { border-color: var(--rose); }
  .rsvp-live .button:hover:not(:disabled) {
    background: var(--rose-deep);
    border-color: var(--rose-deep);
  }
  .rsvp-reset:hover { color: var(--rose); }
}
@media (max-width: 1023px) {
  .rsvp-stage { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 767px) {
  .rsvp-form,
  .rsvp-list { padding: var(--space-3); }
}
@media (prefers-reduced-motion: reduce) {
  .rsvp-row.is-new { animation: none; opacity: 1; translate: none; }
  .rsvp-row.is-new::before { animation: none; opacity: 0; }
  .rsvp-live button,
  .rsvp-live button:active:not(:disabled) { transition: none; transform: none; }
}

/* ── 場合切換、封面、出席點點（後來加的） ── */
.rsvp-occasions { display: flex; flex-wrap: wrap; gap: var(--space-1); margin-bottom: var(--space-4); }
.rsvp-occasions button { min-height: 44px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-soft); font: inherit; font-size: var(--text-sm); cursor: pointer; }
.rsvp-occasions button[aria-pressed="true"] { background: var(--rose); border-color: var(--rose); color: #fff; }
.rsvp-cover { position: relative; aspect-ratio: 16 / 9; margin: 0 0 var(--space-3); overflow: hidden; border-radius: var(--radius); background: var(--blush); }
.rsvp-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 320ms var(--fx-out, cubic-bezier(.23, 1, .32, 1)); }
.rsvp-cover img.is-on { opacity: 1; }
.rsvp-form h3 { margin-bottom: var(--space-1); }
.rsvp-when { margin: 0 0 var(--space-3); color: var(--muted); font-size: var(--text-sm); }
.rsvp-dots { display: flex; flex-wrap: wrap; gap: 6px; min-height: 40px; margin: var(--space-2) 0 var(--space-3); padding: var(--space-2); border-radius: var(--radius); background: var(--sand); }
.rsvp-dots i { width: 14px; height: 14px; border-radius: 50%; background: var(--rose); }
.rsvp-dots i.is-veg { background: transparent; border: 2px solid var(--clay); }
.rsvp-dots i.is-new { animation: rsvp-dot 320ms var(--fx-out, cubic-bezier(.23, 1, .32, 1)) both; }
@keyframes rsvp-dot { from { opacity: 0; scale: .6; } to { opacity: 1; scale: 1; } }
@media (hover: hover) and (pointer: fine) {
  .rsvp-occasions button:not([aria-pressed="true"]):hover { border-color: var(--rose); color: var(--rose); }
}
@media (prefers-reduced-motion: reduce) {
  .rsvp-cover img { transition: none; }
  .rsvp-dots i.is-new { animation: none; }
}
