/* ═══════════════════════════════════════════════════════════════════════
   account.css — /account/, the parent's personal area. Loaded after
   bloom.css, pages.css, forms.css and playdate.css (for .pd-card).

   One idea carries the page: an upcoming visit is a TICKET — a date stub on
   the reading side, the details beside it — because what a parent opens this
   page for is "when are we going, and what do I pay at the door". Everything
   else (saved children, past visits) is quieter and flatter than the tickets.
   ═══════════════════════════════════════════════════════════════════════ */

.acc-head { padding-block-end: 36px; }

.acc-body { padding-block: 40px 96px; background: var(--cream); }

.acc-loading {
  text-align: center; font-family: 'Heebo', sans-serif; color: rgba(43, 43, 43, 0.7);
  padding-block: 40px;
}

/* ── Sign-in ────────────────────────────────────────────────────────── */
.acc-signin { text-align: start; }
.acc-signin h2, .acc-sent h2 { text-align: center; }
.acc-signin > p { text-align: center; }
.acc-signin form { margin-block-start: 22px; }

/* Sign-in / sign-up: a segmented switch, the way trusted sites do it
   (6.10.2026). The track is the neutral ground; the chosen tab is a raised
   ivory pill, so "where am I" is shape and shade, not colour alone. */
.acc-tabs {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px;
  max-width: 360px; margin: 0 auto 26px;
  padding: 5px; border-radius: var(--radius-pill);
  background: var(--neutral);
  box-shadow: inset 0 1px 3px rgba(110, 72, 40, 0.12);
}
.acc-tab {
  appearance: none; border: 0; cursor: pointer;
  padding: 11px 18px; border-radius: var(--radius-pill);
  background: transparent; color: rgba(43, 43, 43, 0.72);
  font-family: 'Heebo', sans-serif; font-size: 15px; font-weight: 700;
  transition: background-color .25s, color .25s, box-shadow .25s, transform .2s;
}
.acc-tab:hover { color: var(--ink); background: rgba(251, 247, 241, 0.55); }
.acc-tab:active { transform: scale(.98); }
.acc-tab:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.acc-tab[aria-selected="true"] {
  background: var(--ivory); color: var(--ink);
  box-shadow: 0 6px 14px -8px rgba(110, 72, 40, 0.45), 0 1px 2px rgba(110, 72, 40, 0.12);
}
.acc-panel h2 { margin-block-end: 6px; }
.acc-panel-lead {
  text-align: center; font-family: 'Heebo', sans-serif; font-size: 15px; line-height: 1.65;
  color: rgba(43, 43, 43, 0.75); max-width: 46ch; margin-inline: auto;
}
.acc-panel:not([hidden]) { animation: accPanelIn .35s cubic-bezier(.2, .7, .3, 1) both; }
@keyframes accPanelIn { from { opacity: 0; transform: translateY(6px); } }
.acc-signin .checkbox-row { margin-block-start: 6px; }
.acc-switch {
  text-align: center; margin-block-start: 18px;
  font-family: 'Heebo', sans-serif; font-size: 14px; color: rgba(43, 43, 43, 0.72);
}
.acc-switch .link-btn { font-weight: 700; }
#accHello { color: var(--ink); }
@media (prefers-reduced-motion: reduce) {
  .acc-tab { transition: none; }
  .acc-panel:not([hidden]) { animation: none; }
}
.acc-signin .form-actions { justify-content: center; }

.acc-alert {
  font-family: 'Heebo', sans-serif; font-size: 14px; line-height: 1.6;
  color: var(--error); background: var(--error-soft);
  border: 1px solid rgba(168, 69, 47, 0.24); border-radius: var(--radius-field);
  padding: 10px 14px; margin-block: 14px 4px; text-align: start;
}
.pd-card .acc-alert { color: var(--error); }

.acc-devlink { font-size: 13px; }
.acc-devlink a { color: var(--mocha); text-decoration: underline; }

/* ── Who is signed in ───────────────────────────────────────────────── */
.acc-who {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  flex-wrap: wrap;
  font-family: 'Heebo', sans-serif; font-size: 14px; color: rgba(43, 43, 43, 0.72);
  margin-block-end: 28px;
}
.acc-who bdi { color: var(--ink); font-weight: 600; overflow-wrap: anywhere; }

/* ── Sections ───────────────────────────────────────────────────────── */
.acc-section { margin-block-end: 48px; }
.acc-section-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px 16px;
  flex-wrap: wrap; margin-block-end: 16px;
}
.acc-section-head h2 {
  font-family: 'Heebo', sans-serif; font-weight: 800; color: var(--ink);
  font-size: clamp(22px, 2.6vw, 28px); letter-spacing: -0.02em; margin: 0;
}
.acc-cta { padding-block: 10px; }

.acc-note, .acc-empty {
  font-family: 'Heebo', sans-serif; font-size: 14px; line-height: 1.7;
  color: rgba(43, 43, 43, 0.7); margin-block: 10px 0;
}
.acc-empty {
  padding: 22px; text-align: center;
  border: 1px dashed rgba(140, 90, 54, 0.28); border-radius: var(--radius-field);
}
.acc-note a, .acc-empty a {
  color: var(--mocha); border-bottom: 1px solid rgba(140, 90, 54, 0.4);
  transition: color .2s, border-color .2s;
}
.acc-note a:hover, .acc-note a:active { color: var(--mocha-deep); border-bottom-color: var(--mocha-deep); }
.acc-note a:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

/* ── Upcoming visits: the tickets ───────────────────────────────────── */
.acc-visits { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }

.acc-visit {
  display: grid; grid-template-columns: minmax(150px, 190px) 1fr;
  background: var(--ivory);
  border: 1px solid rgba(140, 90, 54, 0.14);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
/* The stub: the date, on the side read first (right, in RTL), separated by a
   perforation rather than a rule. */
.acc-visit-when {
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  padding: 20px 22px;
  background: rgba(232, 180, 184, 0.28);
  border-inline-end: 2px dashed rgba(140, 90, 54, 0.22);
}
.acc-visit-day {
  font-family: 'Heebo', sans-serif; font-weight: 800; font-size: 17px; line-height: 1.3;
  color: var(--ink); letter-spacing: -0.01em;
}
.acc-visit-slot { font-family: 'Heebo', sans-serif; font-size: 14px; color: var(--mocha-deep); }

.acc-visit-body { padding: 18px 22px; display: grid; gap: 8px; align-content: center; }
.acc-visit-kids {
  font-family: 'Heebo', sans-serif; font-weight: 600; font-size: 15.5px; color: var(--ink);
  margin: 0; overflow-wrap: anywhere;
}
.acc-visit-facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 0; }
.acc-visit-facts div { display: flex; gap: 6px; align-items: baseline; }
.acc-visit-facts dt { font-family: 'Heebo', sans-serif; font-size: 12.5px; color: rgba(43, 43, 43, 0.62); }
.acc-visit-facts dd { font-family: 'Heebo', sans-serif; font-size: 14px; font-weight: 700; color: var(--ink); margin: 0; }

.acc-badge {
  justify-self: start;
  font-family: 'Heebo', sans-serif; font-size: 11.5px; font-weight: 700;
  color: var(--sage-text); background: rgba(152, 160, 122, 0.18);
  border-radius: var(--radius-pill); padding: 3px 10px;
}

@media (max-width: 560px) {
  .acc-visit { grid-template-columns: 1fr; }
  .acc-visit-when {
    border-inline-end: 0; border-block-end: 2px dashed rgba(140, 90, 54, 0.22);
    flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px;
    padding: 14px 18px;
  }
  .acc-visit-body { padding: 14px 18px 16px; }
}

/* ── My children ────────────────────────────────────────────────────── */
.acc-kids { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.acc-kid {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--ivory); border: 1px solid var(--neutral);
  border-radius: var(--radius-field); padding: 12px 16px;
  font-family: 'Heebo', sans-serif; font-size: 15px; color: rgba(43, 43, 43, 0.8);
}
.acc-kid strong { color: var(--ink); font-weight: 700; }
.acc-kid-remove { color: var(--error); font-size: 13px; }

.acc-kid-form {
  margin-block-start: 18px; padding: 18px 18px 6px;
  border: 1px solid var(--neutral); border-radius: var(--radius-field);
  background: rgba(241, 234, 223, 0.5);
}
.acc-kid-form .field { align-content: start; }
.acc-kid-form .btn { margin-block-end: 12px; }

/* ── Past visits: flat, quiet ───────────────────────────────────────── */
.acc-history { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--neutral); }
.acc-past {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 16px;
  padding: 12px 2px; border-bottom: 1px solid var(--neutral);
  font-family: 'Heebo', sans-serif; font-size: 14px;
}
.acc-past-when { color: var(--ink); font-weight: 600; }
.acc-past-kids { color: rgba(43, 43, 43, 0.66); overflow-wrap: anywhere; }
.acc-past.is-cancelled .acc-past-when { color: rgba(43, 43, 43, 0.5); font-weight: 400; }
