/* ════════════════════════════════════════════════════════════════════
   Gracewood Acres — "Reserve my spot" summer booking flow
   Scoped to the Summer page. Matches the site's ink / bone / clay system.
   ════════════════════════════════════════════════════════════════════ */

/* ─── launch button row on the page ─── */
.rsv-launch {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-top: 28px;
}
.rsv-launch .rsv-launch-note {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ─── overlay + modal shell ─── */
.rsv-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(14, 13, 11, 0.72);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(12px, 4vw, 56px) clamp(10px, 3vw, 40px);
  overflow-y: auto;
  opacity: 0;
  transition: opacity .2s ease;
}
.rsv-overlay.is-open { opacity: 1; }
.rsv-overlay[hidden] { display: none; }

.rsv-modal {
  position: relative;
  width: min(760px, 100%);
  background: var(--bone);
  border: 1px solid var(--ink);
  box-shadow: 0 30px 80px rgba(14, 13, 11, 0.5);
  display: flex;
  flex-direction: column;
  transform: translateY(12px);
  transition: transform .22s ease;
  margin: auto;
}
.rsv-overlay.is-open .rsv-modal { transform: translateY(0); }

.rsv-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--rule);
  background: var(--bone);
  color: var(--ink);
  font-size: 15px;
  cursor: pointer;
  border-radius: 2px;
  transition: background .12s ease, color .12s ease;
  z-index: 3;
}
.rsv-close:hover { background: var(--ink); color: var(--bone); }

/* ─── header + stepper ─── */
.rsv-head {
  padding: 30px clamp(22px, 4vw, 40px) 22px;
  border-bottom: 1px solid var(--rule);
}
.rsv-title {
  font-family: var(--f-display);
  font-weight: 900;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 0.92;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  margin: 10px 0 0;
}
.rsv-steps {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 22px 0 0;
  padding: 0;
  counter-reset: rsvstep;
}
.rsv-steps li {
  counter-increment: rsvstep;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.rsv-steps li::before {
  content: counter(rsvstep);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 1px solid var(--rule-strong);
  border-radius: 50%;
  font-size: 11px;
  color: var(--muted);
}
.rsv-steps li[data-state="active"] { color: var(--ink); }
.rsv-steps li[data-state="active"]::before {
  background: var(--signal);
  border-color: var(--signal);
  color: var(--paper);
}
.rsv-steps li[data-state="done"]::before {
  content: '✓';
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bone);
}

/* ─── body / panels ─── */
.rsv-body {
  padding: clamp(22px, 4vw, 36px) clamp(22px, 4vw, 40px);
}
.rsv-panel[hidden] { display: none; }
.rsv-panel-h {
  font-family: var(--f-edit);
  font-size: clamp(18px, 1.6vw, 22px);
  line-height: 1.3;
  margin: 0 0 4px;
  color: var(--ink);
}
.rsv-panel-sub {
  font-family: var(--f-body);
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0 0 22px;
  max-width: 56ch;
  text-wrap: pretty;
}

/* ─── choice cards (pass + family) ─── */
.rsv-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.rsv-choice {
  text-align: left;
  background: var(--paper);
  border: 1.5px solid var(--rule);
  padding: 22px 22px 24px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color .12s ease, background .12s ease, transform .12s ease;
  font: inherit;
  color: inherit;
  position: relative;
}
.rsv-choice:hover { border-color: var(--rule-strong); transform: translateY(-1px); }
.rsv-choice[aria-pressed="true"] {
  border-color: var(--signal);
  background: var(--bone);
  box-shadow: inset 0 0 0 1px var(--signal);
}
.rsv-choice[aria-pressed="true"]::after {
  content: '✓';
  position: absolute;
  top: 16px;
  right: 18px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--signal);
  color: var(--paper);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rsv-choice-name {
  font-family: var(--f-display);
  font-weight: 900;
  font-size: 30px;
  line-height: 0.95;
  text-transform: uppercase;
  letter-spacing: -0.005em;
}
.rsv-choice-price {
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--signal);
}
.rsv-choice-desc { font-size: 13px; line-height: 1.5; color: var(--muted); margin: 0; }

/* ─── calendar ─── */
.rsv-cal-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.rsv-cal-month {
  font-family: var(--f-display);
  font-weight: 800;
  font-size: 22px;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}
.rsv-cal-nav { display: flex; gap: 8px; }
.rsv-cal-nav button {
  width: 36px;
  height: 36px;
  border: 1px solid var(--rule-strong);
  background: var(--paper);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  color: var(--ink);
  border-radius: 2px;
  transition: background .12s ease, color .12s ease, border-color .12s ease;
}
.rsv-cal-nav button:hover:not(:disabled) { background: var(--ink); color: var(--bone); }
.rsv-cal-nav button:disabled { opacity: 0.3; cursor: not-allowed; }

.rsv-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.rsv-cal-dow {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  padding: 6px 0;
}
.rsv-cal-cell {
  aspect-ratio: 1 / 1;
  border: 1px solid transparent;
  background: transparent;
  font-family: var(--f-body);
  font-size: 15px;
  color: var(--ink);
  cursor: default;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  position: relative;
}
.rsv-cal-cell.is-empty { visibility: hidden; }
.rsv-cal-cell.is-off { color: var(--rule-strong); }
.rsv-cal-cell.is-open {
  cursor: pointer;
  background: var(--paper);
  border-color: var(--rule-strong);
  font-weight: 500;
}
.rsv-cal-cell.is-open:hover { border-color: var(--signal); }
.rsv-cal-cell.is-open::after {
  content: '';
  position: absolute;
  bottom: 5px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--signal);
}
.rsv-cal-cell.is-selected {
  background: var(--signal);
  border-color: var(--signal);
  color: var(--paper);
  font-weight: 700;
}
.rsv-cal-cell.is-selected::after { background: var(--paper); }

.rsv-cal-legend {
  display: flex;
  gap: 18px;
  margin-top: 14px;
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.rsv-cal-legend span { display: inline-flex; align-items: center; gap: 7px; }
.rsv-cal-legend i { width: 12px; height: 12px; border-radius: 2px; display: inline-block; }
.rsv-cal-legend .sw-open { background: var(--paper); border: 1px solid var(--rule-strong); }
.rsv-cal-legend .sw-sel { background: var(--signal); }

.rsv-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; min-height: 4px; }
.rsv-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--f-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  padding: 7px 10px;
  background: var(--ink);
  color: var(--bone);
  border-radius: 2px;
}
.rsv-chip button {
  border: 0;
  background: transparent;
  color: var(--bone);
  cursor: pointer;
  font-size: 13px;
  line-height: 1;
  padding: 0;
  opacity: 0.7;
}
.rsv-chip button:hover { opacity: 1; color: var(--signal); }

.rsv-cal-hint {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--signal);
  margin-top: 14px;
  min-height: 14px;
}

/* ─── details form ─── */
.rsv-form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.rsv-field { display: flex; flex-direction: column; gap: 6px; }
.rsv-field.wide { grid-column: 1 / -1; }
.rsv-field label {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.rsv-field label .req { color: var(--signal); }
.rsv-field input,
.rsv-field select,
.rsv-field textarea {
  appearance: none;
  border: 0;
  border-bottom: 1.5px solid var(--ink);
  background: transparent;
  padding: 9px 0;
  font-family: var(--f-body);
  font-size: 15px;
  color: var(--ink);
  border-radius: 0;
  outline: none;
  transition: border-color .12s ease;
}
.rsv-field textarea { min-height: 64px; resize: vertical; }
.rsv-field input:focus,
.rsv-field select:focus,
.rsv-field textarea:focus { border-bottom-color: var(--signal); }
.rsv-field.has-error input,
.rsv-field.has-error select { border-bottom-color: var(--signal-2); }

.rsv-newonly { display: contents; }
.rsv-newonly[hidden] { display: none; }

.rsv-waiver {
  grid-column: 1 / -1;
  margin-top: 6px;
  padding: 18px;
  background: var(--paper);
  border: 1px solid var(--rule);
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.rsv-waiver input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--signal); flex: 0 0 auto; }
.rsv-waiver label { font-family: var(--f-body); font-size: 13px; line-height: 1.55; color: var(--ink); }
.rsv-waiver a { color: var(--signal); text-decoration: underline; text-underline-offset: 2px; }

/* ─── review / pay ─── */
.rsv-review {
  border: 1px solid var(--rule);
  background: var(--paper);
}
.rsv-review-row {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 18px;
  padding: 15px 20px;
  border-bottom: 1px solid var(--rule);
  align-items: baseline;
}
.rsv-review-row:last-child { border-bottom: 0; }
.rsv-review-row dt {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.rsv-review-row dd { margin: 0; font-size: 15px; line-height: 1.45; color: var(--ink); }
.rsv-review-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 20px;
  background: var(--ink);
  color: var(--bone);
}
.rsv-review-total .lbl {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(241, 236, 221, 0.7);
}
.rsv-review-total .amt {
  font-family: var(--f-display);
  font-weight: 900;
  font-size: 40px;
  line-height: 1;
  color: var(--signal);
}
.rsv-pay-note {
  font-family: var(--f-body);
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
  margin: 18px 0 0;
  text-wrap: pretty;
}
.rsv-pay-note strong { color: var(--ink); font-weight: 600; }

/* ─── success ─── */
.rsv-done { text-align: center; padding: 12px 0 8px; }
.rsv-done-mark {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--signal);
  color: var(--paper);
  font-size: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
}
.rsv-done h3 {
  font-family: var(--f-display);
  font-weight: 900;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 0.95;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.rsv-done p { font-size: 15px; line-height: 1.6; color: var(--muted); max-width: 44ch; margin: 0 auto 8px; }

/* ─── footer nav ─── */
.rsv-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(22px, 4vw, 40px);
  border-top: 1px solid var(--rule);
  background: var(--bone);
}
.rsv-back {
  font-family: var(--f-body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: transparent;
  border: 0;
  color: var(--muted);
  cursor: pointer;
  padding: 8px 0;
}
.rsv-back:hover { color: var(--ink); }
.rsv-back[hidden] { visibility: hidden; }
.rsv-foot-right { display: flex; align-items: center; gap: 18px; }
.rsv-total {
  font-family: var(--f-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--ink);
}
.rsv-total b { font-family: var(--f-display); font-size: 18px; font-weight: 900; }
.rsv-next:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }

@media (max-width: 620px) {
  .rsv-choices, .rsv-form { grid-template-columns: 1fr; }
  .rsv-steps li span { display: none; }
  .rsv-review-row { grid-template-columns: 1fr; gap: 4px; }

  /* full-screen sheet: fixed header + action bar, scrollable middle */
  .rsv-overlay { padding: 0; align-items: stretch; }
  .rsv-modal {
    width: 100%;
    max-width: 100%;
    min-height: 100%;
    max-height: 100%;
    margin: 0;
    border: 0;
    display: flex;
    flex-direction: column;
  }
  .rsv-head { flex: 0 0 auto; }
  .rsv-body { flex: 1 1 auto; overflow-y: auto; -webkit-overflow-scrolling: touch; }
  .rsv-foot { flex: 0 0 auto; flex-wrap: wrap; }
}
