/* Gaffneys Bathroom Services: Get Appointment page layer (get-appointment.html, Phase 2 batch).
   Loads after site.css and service.css, and reuses the shared form field styles (.fld, .chip, .upload, .demo-flag).
   Every new rule is scoped to ap- classes or .page-appointment.
   Theme: a guided request. A short hero, a progress rail and a three-step form card. A request, never a booking. */

/* ---------- A. Hero ---------- */
.ap-hero { padding: calc(var(--nav-top) + var(--nav-h) + 48px) 0 48px; background: var(--mist); border-bottom: 1px solid var(--line); }
.ap-hero__row { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; align-items: end; }
.ap-hero h1 { margin: 18px 0 0; font-size: clamp(2.3rem, 1.3rem + 2.8vw, 3.8rem); line-height: 1.04; letter-spacing: -.012em; }
.ap-hero h1 span { display: block; color: var(--blue-ink); }
.ap-hero__side p { margin: 0; font-size: 1.0625rem; line-height: 1.6; }
.ap-hero__tel { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin-top: 12px; font-weight: 600; color: var(--blue-ink); text-decoration: underline; text-underline-offset: 4px; }

/* ---------- B. Form layout ---------- */
.ap-main { padding: 48px 0 var(--sec); }
.ap-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 48px; align-items: start; }
.ap-rail { position: sticky; top: 120px; padding-top: 12px; }
.ap-steps { margin: 0; padding: 0; list-style: none; }
.ap-steps li { position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 16px; padding: 0 0 28px; }
.ap-steps li:not(:last-child)::after { content: ""; position: absolute; left: 19.5px; top: 44px; bottom: 6px; width: 1px; background: var(--line-2); }
.ap-steps__n { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line-2); border-radius: 50%; background: #fff; font: 600 .9375rem/1 var(--ui); color: var(--grey); transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease); }
.ap-steps b { display: block; padding-top: 2px; font: 400 1.3rem/1.2 var(--display); color: var(--grey); }
.ap-steps small { display: block; margin-top: 3px; font-size: var(--t-small); color: var(--grey); }
.ap-steps li[aria-current="step"] .ap-steps__n { background: var(--blue-ink); border-color: var(--blue-ink); color: #fff; }
.ap-steps li[aria-current="step"] b { color: var(--ink); }
.ap-steps li.is-done .ap-steps__n { background: var(--ice); border-color: var(--ice-2); color: var(--blue-ink); }
.ap-steps li.is-done b { color: var(--ink); }
.ap-rail__note { margin-top: 8px; padding: 22px 24px; background: var(--ice); border-radius: var(--r) var(--arc) var(--r) var(--r); font-size: var(--t-small); }
.ap-rail__note p { margin: 0; }
.ap-rail__note p + p { margin-top: 6px; }
.ap-rail__note b { color: var(--ink); }

.ap-card { padding: 44px 52px 48px; background: #fff; border: 1px solid var(--line); border-radius: var(--arc) var(--r) var(--arc) var(--r); box-shadow: 0 40px 80px -60px rgba(16,28,42,.45); outline: none; scroll-margin-top: 24px; }
.ap-card:focus-visible { box-shadow: inset 0 0 0 2px var(--blue-ink); }
.ap-card__title { font-size: var(--t-h3); line-height: 1.1; }
.ap-card__count { margin: 6px 0 24px; font: 600 .75rem/1.4 var(--ui); letter-spacing: .14em; text-transform: uppercase; color: var(--blue-ink); }
.ap-card__count:empty { margin-bottom: 18px; }
.ap-noscript { margin: 0 0 20px; padding: 14px 16px; background: var(--ice); border-radius: var(--r); font-size: var(--t-small); }
.ap-step { margin: 0; padding: 0; border: 0; min-width: 0; }
.ap-step + .ap-step { margin-top: 36px; padding-top: 32px; border-top: 1px solid var(--line); }
.ap-form.is-stepped .ap-step + .ap-step { margin-top: 0; padding-top: 0; border-top: 0; }
.ap-step__legend { display: block; width: 100%; margin-bottom: 22px; padding: 0 0 14px; border-bottom: 1px solid var(--line); font: 400 1.5rem/1.2 var(--display); color: var(--ink); outline: none; }
.ap-step__legend:focus-visible { outline: 2px solid var(--blue-ink); outline-offset: 4px; }
.ap-form .fld--chips { margin-bottom: 22px; padding: 0; border: 0; }
.ap-opt { font-style: normal; font-weight: 400; color: var(--grey); }
.ap-hint { margin: 4px 0 0; padding: 14px 16px; background: var(--mist); border-radius: var(--r); font-size: var(--t-small); }
.ap-nav { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 28px; }
.ap-nav .btn--blue:only-child { margin-left: auto; }
.ic--back { transform: rotate(180deg); }
.btn:hover .ic--back { transform: rotate(180deg) translateX(3px); }
.ap-review { margin: 6px 0 0; padding: 20px 22px; background: var(--ice); border-radius: var(--r); }
.ap-review__h { margin: 0 0 10px; font: 600 .75rem/1.4 var(--ui); letter-spacing: .14em; text-transform: uppercase; color: var(--blue-ink); }
.ap-review dl { margin: 0; }
.ap-review dl > div { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 7fr); gap: 12px; padding: 8px 0; border-top: 1px solid var(--ice-2); font-size: var(--t-small); }
.ap-review dt { color: var(--grey); }
.ap-review dd { margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.ap-consent { margin: 16px 0 0; font-size: var(--t-xs); color: var(--grey); }
.ap-consent a, .ap-noscript a { color: var(--blue-ink); text-decoration: underline; text-underline-offset: 3px; }
[data-ap-submit].is-loading { opacity: .75; cursor: progress; }
.ap-done:focus { outline: none; }
.ap-done h3 { margin: 14px 0; font-size: clamp(1.8rem, 1.4rem + 1.2vw, 2.4rem); line-height: 1.1; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .ap-card { padding: 36px 36px 40px; }
}
@media (max-width: 1023px) {
  .ap-hero__row { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .ap-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .ap-rail { position: static; padding-top: 0; }
  .ap-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .ap-steps li { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 0; }
  .ap-steps li:not(:last-child)::after { left: 52px; right: -6px; top: 20px; bottom: auto; width: auto; height: 1px; }
  .ap-steps small { display: none; }
  .ap-rail__note { display: none; }
}
@media (max-width: 760px) {
  .ap-hero { padding: calc(var(--nav-top) + var(--nav-h) + 28px) 0 28px; }
  .ap-main { padding-top: 28px; }
  .ap-steps b { font-size: 1.05rem; }
  .ap-card { padding: 24px 18px 28px; border-radius: var(--arc) var(--r) var(--r) var(--r); }
  .ap-step__legend { font-size: 1.3rem; }
  .ap-nav { flex-direction: column-reverse; }
  .ap-nav .btn { width: 100%; }
  .ap-review dl > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .ap-steps__n { transition: none; }
}
