/* ============================================================
   Services page + queue wizard + track status
   ============================================================ */
.svc-grid--page { margin-bottom: 36px; }
.svc-card--sel { cursor: pointer; }
.svc-card--sel.is-active { border-color: var(--brand-400); box-shadow: 0 0 0 3px var(--brand-50); }

.svc-flow { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl); box-shadow: var(--shadow-md); overflow: hidden; scroll-margin-top: 140px; }
.svc-flow__tabs { display: flex; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.svc-tab { display: inline-flex; align-items: center; gap: 9px; padding: 17px 26px; border: none; background: transparent; font-family: var(--font-head); font-weight: 600; font-size: 1.02rem; color: var(--ink-500); border-bottom: 3px solid transparent; }
.svc-tab:hover { color: var(--brand-700); }
.svc-tab.is-active { color: var(--brand-700); border-bottom-color: var(--brand-600); background: #fff; }

/* ---- Stepper ---- */
.wizard { padding: clamp(22px, 3vw, 38px); }
.stepper { display: flex; align-items: center; gap: 6px; margin-bottom: 30px; overflow-x: auto; padding-bottom: 4px; }
.stepper__item { display: flex; align-items: center; gap: 10px; flex: 1; min-width: max-content; }
.stepper__item:not(:last-child)::after { content: ""; flex: 1; height: 2px; background: var(--line-strong); margin: 0 4px; min-width: 18px; }
.stepper__item.is-done:not(:last-child)::after { background: var(--brand-500); }
.stepper__dot { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border-radius: 50%; font-family: var(--font-head); font-weight: 700; font-size: .98rem; background: var(--surface-2); color: var(--ink-500); border: 2px solid var(--line-strong); }
.stepper__item.is-cur .stepper__dot { background: var(--brand-700); color: #fff; border-color: var(--brand-700); box-shadow: 0 0 0 4px var(--brand-50); }
.stepper__item.is-done .stepper__dot { background: var(--brand-500); color: #fff; border-color: var(--brand-500); }
.stepper__label { font-family: var(--font-head); font-weight: 600; font-size: .92rem; color: var(--ink-500); white-space: nowrap; }
.stepper__item.is-cur .stepper__label, .stepper__item.is-done .stepper__label { color: var(--ink-900); }

.wizard__panel { min-height: 280px; }
.wstep__title { font-size: 1.3rem; margin-bottom: 6px; }
.wstep__hint { margin-bottom: 18px; }
.wstep__label-sm { font-family: var(--font-head); font-weight: 600; font-size: .95rem; color: var(--ink-700); margin: 22px 0 12px; }
.wstep__label-sm:first-of-type { margin-top: 16px; }

/* ---- Choice cards ---- */
.choice-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 18px; }
.choice { display: flex; align-items: center; gap: 15px; padding: 18px; border: 2px solid var(--line); border-radius: var(--r-lg); background: #fff; text-align: right; transition: all .15s ease; position: relative; }
.choice:hover { border-color: var(--brand-300); background: var(--brand-50); }
.choice.is-sel { border-color: var(--brand-600); background: var(--brand-50); }
.choice__ic { width: 52px; height: 52px; flex: none; display: grid; place-items: center; border-radius: var(--r-md); background: var(--brand-100); color: var(--brand-700); }
.choice.is-sel .choice__ic { background: var(--brand-700); color: #fff; }
.choice__txt { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.choice__label { font-family: var(--font-head); font-weight: 700; font-size: 1.06rem; color: var(--ink-900); }
.choice__desc { font-size: .9rem; color: var(--ink-500); }
.choice__check { width: 26px; height: 26px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--brand-600); color: #fff; opacity: 0; transform: scale(.6); transition: all .15s ease; }
.choice.is-sel .choice__check, .place.is-sel .choice__check { opacity: 1; transform: scale(1); }

/* ---- Place list ---- */
.place-list { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; max-height: 380px; overflow-y: auto; padding: 2px; }
.place { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 2px solid var(--line); border-radius: var(--r-md); background: #fff; text-align: right; transition: all .15s ease; }
.place:hover { border-color: var(--brand-300); background: var(--brand-50); }
.place.is-sel { border-color: var(--brand-600); background: var(--brand-50); }
.place__ic { width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: var(--r-md); background: var(--brand-100); color: var(--brand-700); }
.place__info { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.place__name { font-family: var(--font-head); font-weight: 600; font-size: 1.02rem; color: var(--ink-900); }
.place__meta { font-size: .88rem; color: var(--ink-500); }

/* ---- Date + slot ---- */
.date-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 10px; }
.date-cell { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 4px; border: 2px solid var(--line); border-radius: var(--r-md); background: #fff; transition: all .15s ease; }
.date-cell:hover:not(:disabled) { border-color: var(--brand-400); }
.date-cell.is-sel { border-color: var(--brand-600); background: var(--brand-700); color: #fff; }
.date-cell.is-off { opacity: .4; cursor: not-allowed; background: var(--surface-2); }
.date-cell__dow { font-size: .8rem; font-family: var(--font-head); color: inherit; opacity: .8; }
.date-cell__day { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; }
.slot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.slot { position: relative; padding: 13px 8px; border: 2px solid var(--line); border-radius: var(--r-md); background: #fff; font-family: var(--font-head); font-weight: 600; font-size: 1rem; color: var(--ink-800); transition: all .15s ease; }
.slot:hover:not(:disabled) { border-color: var(--brand-400); }
.slot.is-sel { border-color: var(--brand-600); background: var(--brand-700); color: #fff; }
.slot.is-taken { opacity: .5; cursor: not-allowed; background: var(--surface-2); color: var(--ink-400); }
.slot__full { display: block; font-size: .7rem; font-weight: 500; color: var(--emergency); }

/* ---- Form ---- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 18px; }
.consent { display: flex; align-items: center; gap: 10px; margin-top: 20px; padding: 14px 18px; background: var(--brand-50); border-radius: var(--r-md); font-size: .92rem; color: var(--brand-700); }
.consent .icon { flex: none; }

/* ---- Done ---- */
.wstep--done { text-align: center; display: flex; flex-direction: column; align-items: center; padding-top: 8px; }
.done-ic { color: var(--ok-600); margin-bottom: 8px; }
.done-title { font-size: 1.7rem; }
.done-sub { margin-top: 8px; max-width: 46ch; }
.ref-box { display: inline-flex; flex-direction: column; align-items: center; gap: 4px; margin: 22px 0; padding: 16px 44px; background: var(--brand-50); border: 2px dashed var(--brand-300); border-radius: var(--r-lg); }
.ref-box__label { font-size: .85rem; color: var(--ink-500); font-family: var(--font-head); }
.ref-box__num { font-family: var(--font-head); font-weight: 800; font-size: 1.8rem; letter-spacing: .04em; color: var(--brand-700); }
.summary-card { width: 100%; max-width: 460px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 8px 20px; }
.sum-row { display: flex; align-items: center; gap: 12px; padding: 13px 0; text-align: right; }
.sum-row:not(:last-child) { border-bottom: 1px solid var(--line); }
.sum-row__ic { color: var(--brand-600); flex: none; }
.sum-row__label { color: var(--ink-500); font-size: .92rem; width: 96px; flex: none; text-align: right; }
.sum-row__value { flex: 1; font-family: var(--font-head); font-weight: 600; color: var(--ink-900); text-align: left; }
.done-actions { display: flex; gap: 12px; margin-top: 26px; flex-wrap: wrap; justify-content: center; }

/* ---- Wizard nav ---- */
.wizard__nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); }
.wizard__nav .btn:disabled { opacity: .45; cursor: not-allowed; }
.wizard__nav .btn:disabled:hover { transform: none; box-shadow: none; background: var(--brand-700); }
.btn--ghost:disabled:hover { background: transparent; }

/* ---- Track status ---- */
.track { padding: clamp(22px, 3vw, 38px); }
.track__form { display: flex; gap: 14px; align-items: flex-end; max-width: 640px; }
.track__btn { flex: none; }
.track__error { display: flex; align-items: center; gap: 10px; margin-top: 18px; padding: 14px 18px; background: #fbe6e4; color: var(--emergency-dark); border-radius: var(--r-md); }
.track__result { margin-top: 24px; padding: 24px; max-width: 640px; }
.track__result-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 18px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.track__ref { font-family: var(--font-head); font-weight: 800; font-size: 1.4rem; color: var(--brand-700); }
.timeline { padding: 14px 6px 0; }
.timeline__item { display: flex; gap: 16px; padding-bottom: 26px; position: relative; }
.timeline__item:not(:last-child)::before { content: ""; position: absolute; right: 15px; top: 32px; bottom: -2px; width: 2px; background: var(--line-strong); }
.timeline__item.is-done:not(:last-child)::before { background: var(--brand-500); }
.timeline__dot { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--surface-2); color: var(--ink-400); border: 2px solid var(--line-strong); z-index: 1; }
.timeline__item.is-done .timeline__dot { background: var(--brand-500); color: #fff; border-color: var(--brand-500); }
.timeline__item.is-pending .timeline__dot { background: var(--warn-100); color: var(--warn-600); border-color: var(--warn-600); }
.timeline__body { display: flex; flex-direction: column; gap: 3px; padding-top: 4px; }
.timeline__label { font-family: var(--font-head); font-weight: 600; font-size: 1.04rem; color: var(--ink-900); }
.timeline__date { font-size: .9rem; }

@media (max-width: 760px) {
  .choice-grid, .form-grid { grid-template-columns: 1fr; }
  .stepper__label { display: none; }
  .stepper__item.is-cur .stepper__label { display: inline; }
  .track__form { flex-direction: column; align-items: stretch; }
  .svc-tab { padding: 15px 16px; font-size: .95rem; flex: 1; justify-content: center; }
}
