/* Feet First – scroll-driven foot
   Colour tokens from Brand Kit v1.1 (core, surfaces, service lines).
   Coral CTA + status colours intentionally not used on the public site. */
:root {
  --brand-primary: #482683;
  --brand-deep: #330072;
  --brand-light: #5F36A6;
  --brand-soft: #7B4FC7;
  --brand-muted: #A17EDB;
  --brand-pale: #D4C4F0;
  --brand-ghost: #F0EBFA;

  --bg-card: #FFFFFF;
  --bg-main: #FAF8FC;
  --bg-soft: #EDEAF2;
  --border-default: #E8E5EE;
  --text-heading: #1A1A2E;
  --text-body: #333333;
  --text-secondary: #666666;
  --field-border: #CFC8DC;
  --error-text: #B3261E;

  --svc-routine: #482683;
  --svc-biomech: #3F6FD1;
  --svc-nailsurg: #1E9E93;
  --svc-diabetic: #D6478E;
  --svc-skin: #3FA35F;
  --svc-homevisit: #2FA3C7;

  --font-display: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 0.75rem;
  --shadow: 0 8px 28px rgba(72, 38, 131, 0.08);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --vh: 100svh;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body); color: var(--text-body); line-height: 1.6;
  background: var(--bg-main); overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--brand-primary); }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--text-heading); line-height: 1.2; }
:focus-visible { outline: 3px solid var(--brand-muted); outline-offset: 3px; border-radius: 6px; }

/* ── Buttons ─────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 44px; padding: .65rem 1.4rem; border-radius: 999px;
  font: 600 1rem/1 var(--font-body); text-decoration: none; cursor: pointer;
  border: 2px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand-primary); color: #fff; }
.btn-primary:hover { background: var(--brand-deep); }
.btn-ghost { background: var(--brand-ghost); color: var(--brand-primary); border-color: var(--border-default); }
.btn-ghost:hover { background: var(--bg-soft); }

/* ── Loader ──────────────────────────────── */
.loader { display: none; }
.js .loader {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  background: linear-gradient(145deg, var(--brand-primary), var(--brand-deep));
  transition: opacity .5s ease, visibility .5s ease;
}
.js .loader.done { opacity: 0; visibility: hidden; }
.loader-inner { width: min(340px, 78vw); text-align: center; }
.loader-logo { width: 100%; height: auto; margin-bottom: 2rem; }
.loader-track { height: 8px; border-radius: 999px; background: rgba(255,255,255,.18); overflow: hidden; }
.loader-fill { height: 100%; width: 100%; border-radius: inherit; background: #fff; transform: scaleX(0); transform-origin: left center; will-change: transform; }
.loader-text { margin-top: .9rem; color: rgba(255,255,255,.88); font-size: .95rem; display: flex; justify-content: space-between; }
#loader-pct { font-variant-numeric: tabular-nums; font-weight: 600; }
body.loading { overflow: hidden; }

/* ── Logo tile: the primary (purple) logo on a white tile, fixed top-left ── */
.brand-tile {
  position: fixed; top: 12px; left: clamp(12px, 2.5vw, 28px); z-index: 95;
  display: grid; place-items: center; width: 100px; height: 64px; border-radius: 16px;
  background: #fff; border: 1px solid var(--border-default);
  box-shadow: 0 8px 24px rgba(51, 0, 114, .16);
  transition: opacity .3s ease, visibility .3s, transform .3s ease;
}
.brand-tile:hover { transform: translateY(-1px); }
.brand-tile img { width: 78px; height: auto; }
.brand-tile.hidden { opacity: 0; visibility: hidden; transform: translateY(-10px); }
@media (max-width: 820px) and (max-aspect-ratio: 78/100) { .brand-tile { width: 80px; height: 52px; border-radius: 13px; top: 10px; } .brand-tile img { width: 62px; } }

/* ── Top contact pill (the only "header") ── */
.top-actions {
  position: fixed; top: 14px; right: clamp(12px, 2.5vw, 28px); z-index: 60;
  display: flex; gap: .4rem; padding: 5px; border-radius: 999px;
  background: rgba(255,255,255,.94); border: 1px solid var(--border-default); box-shadow: var(--shadow);
}
.pill {
  display: inline-flex; align-items: center; gap: .45rem; min-height: 40px; padding: 0 1rem;
  border-radius: 999px; text-decoration: none; font-weight: 600; font-size: .95rem;
  transition: background-color .15s ease, color .15s ease;
}
.pill svg { width: 17px; height: 17px; fill: currentColor; }
.pill-phone { color: var(--brand-primary); }
.pill-phone:hover { background: var(--brand-ghost); }
.pill-contact { background: var(--brand-primary); color: #fff; }
.pill-contact:hover { background: var(--brand-deep); }
@media (max-width: 480px) { .pill-phone span { display: none; } .pill-phone { padding: 0 .8rem; } }

/* ── Story: pinned stage ─────────────────── */
.story { position: relative; }
.story { --step: .5; } /* viewport-heights of scrolling per service: shorter on desktop */
@media (max-width: 820px) and (max-aspect-ratio: 78/100) { .story { --step: .7; } }
.js .story { height: calc(var(--vh) * (1 + 7 * var(--step))); }
.stage {
  position: relative; min-height: var(--vh); overflow: hidden;
  background: radial-gradient(110% 90% at 40% 45%, #fff 0%, var(--brand-ghost) 65%, #E9E1F7 100%);
  --foot-x: 40%;
}
.js .stage { position: sticky; top: 0; height: var(--vh); }

/* The foot is the hero: as tall as the screen allows */
.foot-wrap {
  position: absolute; top: 50%; left: var(--foot-x);
  height: min(calc(var(--vh) - 32px), 1100px); aspect-ratio: 300 / 585;
  transform: translate(-50%, -50%);
}
.foot {
  display: block; width: 100%; height: 100%; overflow: visible;
  transform-origin: 42.7% 86.7%; /* the heel (238,547) in the 110 40 300 585 viewBox */
  will-change: transform; shape-rendering: geometricPrecision;
}
.sole { fill: var(--brand-primary); transition: fill .3s ease; }
.toe-halo { display: none; }
.heel-glow { fill: #fff; opacity: 0; transition: opacity .3s ease; pointer-events: none; }
.toe { cursor: pointer; outline: none; }
.toe-shape { fill: var(--brand-primary); transition: fill .3s ease, transform .4s var(--ease); transform-box: fill-box; transform-origin: 50% 80%; }
.toe-ring { fill: none; stroke: var(--brand-primary); stroke-width: 0; opacity: 0; transition: opacity .3s ease, stroke-width .3s ease, transform .4s var(--ease); transform-box: fill-box; transform-origin: 50% 80%; }
.toe:hover .toe-shape { fill: var(--brand-light); }
.toe:focus-visible .toe-ring { opacity: 1; stroke-width: 5; }

/* When a service is in view: other toes fade back, the active one lifts */
.foot .toe.is-active .toe-shape { fill: var(--brand-pale); transform: translateY(-6px) scale(1.12); }
.foot .toe.is-active .toe-ring { opacity: 1; stroke-width: 5; transform: translateY(-6px) scale(1.12); }
.foot.on-heel .heel-glow { opacity: .14; animation: heel-pulse 2.2s ease-in-out infinite; }
.foot.opening .heel-glow { animation: none; opacity: 0; }
.foot.opening .toe .toe-shape { fill: var(--brand-primary); }
@keyframes heel-pulse { 50% { opacity: .26; } }

/* intro: toes pop in after the loader */
.js .toe { opacity: 0; }
.ready .toe { opacity: 1; transition: opacity .45s ease; transition-delay: calc(var(--i) * 90ms + 150ms); }

/* panels: cards that grow out of the highlighted toe (JS positions + animates them) */
.panels { position: relative; display: grid; gap: 1rem; padding: 24px 16px; }
.js .panels { position: absolute; inset: 0; padding: 0; display: block; pointer-events: none; }
.panel {
  background: rgba(255, 255, 255, .97); border: 1px solid var(--border-default); border-radius: var(--radius);
  box-shadow: 0 18px 48px rgba(72, 38, 131, .14); padding: clamp(18px, 2.2vw, 28px);
}
.js .panel {
  position: absolute; left: 0; top: 0; width: 420px; pointer-events: auto;
  opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s;
}
.js .panel.is-active { opacity: 1; visibility: visible; }
.panel-eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-primary); }
.panel h1 { font-size: clamp(1.9rem, 3.4vw, 3rem); color: var(--brand-primary); margin: .45rem 0 .7rem; }
.panel h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); margin: .35rem 0 .6rem; }
.panel-body { font-size: clamp(.98rem, 1.3vw, 1.08rem); color: var(--text-body); }
.ticks { list-style: none; margin-top: .9rem; display: grid; gap: .4rem; }
.ticks li { position: relative; padding-left: 1.8rem; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .28em; width: 1.15rem; height: 1.15rem; border-radius: 50%;
  background: var(--brand-ghost) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%23482683' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/80% no-repeat;
}
.panel-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.25rem; }
.scroll-cue { display: flex; align-items: center; gap: .7rem; margin: 0 0 0 .4rem; color: var(--text-secondary); font-weight: 600; font-size: .9rem; }
.scroll-cue span { width: 22px; height: 34px; border: 2px solid var(--brand-muted); border-radius: 12px; position: relative; }
.scroll-cue span::after { content: ""; position: absolute; left: 50%; top: 6px; width: 4px; height: 7px; margin-left: -2px; border-radius: 2px; background: var(--brand-primary); animation: cue 1.6s ease-in-out infinite; }
@keyframes cue { 60% { transform: translateY(10px); opacity: 0; } 61% { transform: none; opacity: 0; } 100% { opacity: 1; } }


/* the foot opens up from the heel into the contact form */
.stage-cover { position: absolute; inset: 0; background: var(--brand-primary); opacity: 0; pointer-events: none; }

@media (max-width: 1400px) { .stage { --foot-x: 34%; } }
/* tall tablets (portrait iPads wider than 820px): keep the foot narrow enough to leave room for the card */
@media (min-width: 821px) and (max-aspect-ratio: 78/100) {
  .stage { --foot-x: 31%; }
  .foot-wrap { height: min(calc(var(--vh) - 32px), 88vw); }
}
/* unfolded foldables & other near-square screens: foot centred on the left screen,
   card centred on the right screen (JS places the card) */
@media (min-width: 600px) and (max-width: 1180px) and (min-aspect-ratio: 78/100) and (max-aspect-ratio: 150/100) {
  .stage { --foot-x: 25%; }
  .foot-wrap { top: calc(50% + 34px); height: min(calc(var(--vh) - 150px), 80vw); }
}
@media (max-width: 820px) and (max-aspect-ratio: 78/100) {
  .stage { --foot-x: 50%; }
  /* phones: zoom in on the toes inside a soft circle; the camera pans down to the heel at the end */
  .foot-wrap { top: 58px; height: auto; width: 108vw; transform: translate(-50%, var(--pan, 0px)); }
  .toe-halo { display: inline; fill: #fff; opacity: .75; stroke: var(--brand-pale); stroke-width: 2; transition: opacity .4s ease; }
  .foot.on-heel .toe-halo, .foot.opening .toe-halo { opacity: 0; }
  .js .panel { width: auto; }
  .panel h1 { font-size: clamp(1.6rem, 7vw, 2.1rem); }
  .panel h2 { font-size: clamp(1.3rem, 5.6vw, 1.7rem); }
  .panel-body { font-size: .95rem; }
  .js .panel { display: flex; flex-direction: column; }
  .ticks { display: grid; margin-top: .7rem; gap: .35rem; font-size: .95rem; }
  .panel-actions { margin-top: 1.1rem; display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
  .panel-actions .btn { width: 100%; min-height: 50px; }
  .panel-actions .btn { min-height: 42px; padding: .5rem 1.1rem; font-size: .95rem; }
}

/* ── Scroll map (left edge, like a scrollbar) ── */
.foot-map { position: fixed; left: clamp(14px, 2vw, 28px); top: 50%; transform: translateY(-50%); z-index: 40; display: none; gap: .7rem; transition: opacity .3s ease, visibility .3s; }
.foot-map.tucked { opacity: 0; visibility: hidden; }
@media (min-width: 1200px) { .js .foot-map { display: flex; } }
.foot-map-track { position: relative; width: 4px; border-radius: 2px; background: var(--brand-pale); }
/* the marker is the LEFT foot, mirroring the big right foot on the stage */
.foot-map-dot {
  position: absolute; left: 50%; top: 0; width: 20px; height: 39px; margin-left: -10px;
  fill: var(--brand-primary); transform: translateY(-50%); transition: top .45s var(--ease); overflow: visible;
}
.foot-map ol { list-style: none; display: flex; flex-direction: column; gap: 1.4rem; padding: 6px 0; }
.foot-map a { display: block; text-decoration: none; padding: .1rem .4rem; border-radius: 6px; font: 600 .82rem/1.2 var(--font-display); color: var(--text-secondary); transition: color .15s ease; }
.foot-map ol { gap: 1.05rem; }
.foot-map .map-group a { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-muted); }
.foot-map .map-group { margin-bottom: -.45rem; }
.foot-map li.sub a { padding-left: 1rem; font-weight: 500; position: relative; }
.foot-map li.sub a::before { content: ""; position: absolute; left: .4rem; top: 50%; width: 4px; height: 4px; margin-top: -2px; border-radius: 50%; background: var(--brand-pale); }
.foot-map li.sub a.is-current::before { background: var(--brand-primary); }
.foot-map a:hover, .foot-map a.is-current { color: var(--brand-primary); }
.foot-map.on-dark .foot-map-dot { fill: #fff; }
.foot-map.on-dark .foot-map-track { background: rgba(255,255,255,.35); }
.foot-map.on-dark a { color: rgba(255,255,255,.75); }
.foot-map.on-dark a.is-current, .foot-map.on-dark a:hover { color: #fff; }

/* "Contact us" jump: fade to purple, cut to the form, fade back */
.jump-cover { position: fixed; inset: 0; z-index: 90; background: linear-gradient(180deg, var(--brand-primary), var(--brand-deep)); opacity: 0; pointer-events: none; transition: opacity .35s ease; }
.jump-cover.show { opacity: 1; pointer-events: auto; }
.jump-cover.instant { transition: none; }
.top-actions { transition: opacity .3s ease, visibility .3s, transform .3s ease; }
.top-actions.away { opacity: 0; visibility: hidden; transform: translateY(-12px); }

/* ── Contact ─────────────────────────────── */
.contact { background: #fff; }
.contact-band {
  background: linear-gradient(180deg, var(--brand-primary), var(--brand-deep));
  color: #fff; text-align: center; padding: clamp(28px, 5vh, 48px) 16px clamp(96px, 14vh, 130px);
}
.contact-band h2 { color: #fff; font-size: clamp(1.8rem, 4vw, 2.6rem); }
@media (max-width: 820px) and (max-aspect-ratio: 78/100) { .contact-band { padding-top: 28px; } }
.contact-wrap {
  max-width: 1180px; margin: calc(-1 * clamp(64px, 10vh, 100px)) auto 0; padding: 0 16px clamp(40px, 6vw, 72px);
  display: grid; gap: 1.25rem; position: relative;
}
/* row 1: clinic info + map, equal height */
.contact-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 1.25rem; align-items: stretch; }
@media (max-width: 599px) { .contact-row { grid-template-columns: 1fr; } }
.card { background: var(--bg-card); color: var(--text-body); border-radius: var(--radius); padding: clamp(18px, 2.6vw, 28px); border: 1px solid var(--border-default); box-shadow: var(--shadow); }
.card h3 { font-size: 1.15rem; }
.info-card { display: flex; flex-direction: column; }
.info-head { display: flex; align-items: center; justify-content: space-between; gap: .5rem; flex-wrap: wrap; }
.open-badge { display: inline-flex; align-items: center; gap: .4rem; font-size: .8rem; font-weight: 700; padding: .25rem .65rem; border-radius: 999px; background: var(--brand-ghost); color: var(--brand-primary); }
.open-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.open-badge.closed { background: var(--bg-soft); color: var(--text-secondary); }
.info-list { display: grid; grid-template-columns: auto 1fr; gap: .45rem .9rem; margin: .9rem 0 1rem; font-size: .95rem; }
.info-list dt { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--text-secondary); padding-top: .2rem; }
.info-list dd { color: var(--text-heading); overflow-wrap: anywhere; }
.hours { border-top: 1px solid var(--border-default); padding-top: .9rem; }
.hours h4 { font-size: .95rem; margin-bottom: .4rem; }
.hours ul { list-style: none; display: grid; gap: .1rem; font-size: .9rem; }
.hours li { display: flex; justify-content: space-between; gap: 1rem; padding: .15rem .5rem; margin: 0 -.5rem; border-radius: 6px; }
.hours li .t { font-variant-numeric: tabular-nums; color: var(--text-heading); }
.hours li.today { background: var(--brand-ghost); font-weight: 600; }
.hours li.muted, .muted { color: var(--text-secondary); }
.hours-source { font-size: .75rem; color: var(--text-secondary); margin-top: .5rem; }
.hours-source:empty { display: none; }
.info-actions { margin-top: auto; padding-top: 1.1rem; display: grid; }
.info-actions .btn { width: 100%; min-height: 50px; }
.directions { font-weight: 600; text-decoration: none; }
.directions:hover { text-decoration: underline; }
.map-card { padding: 0; overflow: hidden; display: flex; min-height: 280px; }
.map-card iframe { display: block; width: 100%; flex: 1; min-height: 280px; border: 0; }

/* row 2: the form, laid out wide so it fits on one screen */
.form-card { scroll-margin-top: 16px; }
.js .contact-row > *, .js .form-card { opacity: 0; transform: translateY(24px); }
.js .contact.in .contact-row > *, .js .contact.in .form-card { opacity: 1; transform: none; transition: opacity .45s ease, transform .55s var(--ease); }
.js .contact.in .contact-row > :nth-child(2) { transition-delay: .08s; }
.js .contact.in .form-card { transition-delay: .16s; }

/* ── Enquiry form ────────────────────────── */
.enquiry, .form-done { display: grid; gap: 1rem; }
/* The form lays itself out by the width of its own card (container query), so it scales
   cleanly on any screen shape: phones, unfolded foldables, tablets, laptops, ultrawides. */
.form-card { container: enquiry / inline-size; }
.enquiry { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "fields" "msg" "foot"; }
.form-head { grid-area: head; }
.form-fields { grid-area: fields; display: grid; gap: .85rem; align-content: start; }
.field.field-message { grid-area: msg; display: flex; flex-direction: column; gap: .3rem; }
.field-message textarea { flex: 1; min-height: 112px; }
.form-foot { grid-area: foot; display: grid; justify-items: stretch; gap: 0; }
.form-foot .cf-turnstile { min-height: 0; }
.form-foot .submit { justify-self: stretch; width: 100%; min-height: 56px; font-size: 1.1rem; border-radius: 999px; box-shadow: 0 10px 24px rgba(72, 38, 131, .25); }
.form-footnote { font-size: .78rem; color: var(--text-secondary); text-align: center; margin-top: 1rem; }
.form-status:not(:empty) { margin-top: .8rem; }
.form-foot .cf-turnstile:has(iframe[style*="display: block"]) { margin-bottom: 1rem; }
.form-status { text-align: center; }
.service-chip { display: inline-flex; align-items: center; gap: .4rem; justify-self: start; background: var(--brand-ghost); color: var(--brand-primary); border-radius: 999px; padding: .3rem .4rem .3rem .9rem; font-size: .88rem; }
.service-chip[hidden] { display: none; }
.service-chip button { border: 0; background: #fff; color: var(--brand-primary); width: 26px; height: 26px; border-radius: 50%; cursor: pointer; font-size: 1rem; line-height: 1; }
/* medium cards (unfolded foldables, tablets): fields in two columns, message full width */
@container enquiry (min-width: 520px) {
  .form-fields { grid-template-columns: 1fr 1fr; }
  .form-fields .field:first-child { grid-column: 1 / -1; }
}
/* wide cards (laptops and up): fields left, message right, send centred across the bottom */
@container enquiry (min-width: 820px) {
  .enquiry { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); grid-template-areas: "head head" "fields msg" "foot foot"; column-gap: 1.75rem; }
  .form-fields { grid-template-columns: 1fr; }
}
.enquiry[hidden], .form-done[hidden] { display: none; }
.enquiry h3, .form-done h3 { font-size: 1.4rem; }
.form-intro { color: var(--text-secondary); font-size: .92rem; margin-top: .25rem; }
.field { display: grid; gap: .3rem; align-content: start; }
.field label, .field .label { font-weight: 600; font-size: .92rem; color: var(--text-heading); }
.opt { font-weight: 400; color: var(--text-secondary); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 46px; padding: .6rem .8rem; border-radius: 8px;
  border: 1px solid var(--field-border); background: #fff; color: var(--text-heading);
  font: 1rem/1.4 var(--font-body); transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { resize: vertical; min-height: 112px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand-primary); box-shadow: 0 0 0 3px var(--brand-ghost); }
.field [aria-invalid] { border-color: var(--error-text); }
.field-error { color: var(--error-text); font-size: .85rem; }
.field-error:empty { display: none; }
.field-hint { color: var(--text-secondary); font-size: .8rem; text-align: right; margin-top: -.15rem; }
.segmented { display: flex; gap: .4rem; }
.segmented label { flex: 1; position: relative; }
.segmented input { position: absolute; inset: 0; opacity: 0; pointer-events: none; }
.segmented span {
  display: grid; place-items: center; min-height: 46px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--field-border); font-weight: 600; color: var(--text-secondary);
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.segmented input:checked + span { background: var(--brand-ghost); border-color: var(--brand-primary); color: var(--brand-primary); }
.segmented input:focus-visible + span { outline: 3px solid var(--brand-muted); outline-offset: 2px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.consent { display: flex; gap: .65rem; align-items: flex-start; font-size: .92rem; cursor: pointer; }
.consent input { width: 20px; height: 20px; margin-top: .15rem; accent-color: var(--brand-primary); flex: none; }
.submit { justify-self: start; min-width: 180px; }
.spinner { display: none; width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: spin .7s linear infinite; }
.sending .spinner { display: inline-block; }
.sending .submit { opacity: .85; cursor: progress; }
@keyframes spin { to { transform: rotate(360deg); } }
.form-status { font-size: .92rem; color: var(--error-text); }
.form-status:empty { display: none; }
.form-done { justify-items: start; padding: 1rem 0; outline: none; }
.done-tick { width: 56px; height: 56px; border-radius: 50%; background: var(--brand-ghost) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%23482683' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/60% no-repeat; }

/* ── Footer ──────────────────────────────── */
.site-footer { background: var(--brand-deep); color: rgba(255,255,255,.82); font-size: .92rem; }
.footer-inner {
  max-width: 1180px; margin: 0 auto; padding: clamp(36px, 6vw, 56px) 16px 28px;
  display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 32px;
}
.footer-brand img { width: 150px; height: auto; margin-bottom: .8rem; }
.site-footer h3 { color: #fff; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: .8rem; }
.site-footer address { font-style: normal; margin-bottom: .6rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer ul { list-style: none; display: grid; gap: .45rem; }
.footer-base { border-top: 1px solid rgba(255,255,255,.14); max-width: 1180px; margin: 0 auto; padding: 16px 16px 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .4rem 1.5rem; font-size: .8rem; color: rgba(255,255,255,.65); }
.todo { color: #fff; opacity: .7; }
@media (max-width: 760px) {
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 24px; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-brand img { width: 120px; }
}
@media (max-width: 420px) { .footer-inner { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
}

/* ── 16:9 and wider: use the width – bigger cards, larger text, easier navigation ── */
.stage.is-wide .panel { padding: clamp(28px, 2.2vw, 40px); }
.stage.is-wide .panel h1 { font-size: clamp(2.6rem, 3.6vw, 4rem); }
.stage.is-wide .panel h2 { font-size: clamp(2.1rem, 2.6vw, 3.2rem); }
.stage.is-wide .panel-body { font-size: clamp(1.1rem, 1.05vw, 1.35rem); }
.stage.is-wide .ticks { font-size: clamp(1rem, .95vw, 1.2rem); gap: .6rem; margin-top: 1.2rem; }
.stage.is-wide .panel-eyebrow { font-size: .85rem; }
.stage.is-wide .panel-actions .btn { min-height: 52px; padding: .8rem 1.8rem; font-size: 1.05rem; }
@media (min-width: 1280px) and (min-aspect-ratio: 155/100) {
  .foot-map a { font-size: .95rem; padding: .25rem .5rem; }
  .foot-map ol { gap: 1.25rem; }
  .foot-map .map-group a { font-size: .78rem; }
  .foot-map-dot { width: 24px; height: 47px; margin-left: -12px; }
  .contact-wrap { max-width: min(1560px, 92vw); }
}


/* ── Phones: centre the clinic information and the footer, line by line ── */
@media (max-width: 599px) {
  .info-card { text-align: center; align-items: center; }
  .info-head { justify-content: center; flex-direction: column; gap: .5rem; }
  .info-list { grid-template-columns: 1fr; gap: .15rem; justify-items: center; }
  .info-list dt { padding-top: .6rem; }
  .info-card { padding: 28px 24px; }
  .hours { width: 100%; max-width: 270px; }
  .info-actions { justify-content: center; width: 100%; }
  .info-actions .btn { width: 100%; max-width: 320px; min-height: 50px; }
  .footer-inner { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 28px; }
  .footer-brand { display: grid; justify-items: center; }
  .footer-brand img { margin: 0 0 .8rem; }
  .site-footer ul { justify-items: center; }
  .footer-base { flex-direction: column; align-items: center; text-align: center; }
}

/* ── Phones (and portrait iPads, which share the phone flow): intro card tidy ── */
@media (max-width: 820px) and (max-aspect-ratio: 78/100) {
  .panel-eyebrow .eb-sep { display: none; }
  .panel-eyebrow span { display: block; }
  .scroll-cue { display: none; }
}

/* ── Portrait iPads (600px+): a smaller, centred foot instead of the zoomed phone view ── */
@media (min-width: 600px) and (max-width: 820px) and (max-aspect-ratio: 78/100) {
  .foot-wrap { width: min(78vw, 640px); top: 72px; }
  .js .panel { min-height: 0; }
  .panel-actions { margin-top: 1.4rem; }
  .panel h1 { font-size: 2.4rem; }
  .panel h2 { font-size: 2rem; }
  .panel-body, .ticks { font-size: 1.05rem; }
}

/* ── Tablet-width footers (iPads, foldables): the normal three-column bar, with roomier edges ── */
@media (min-width: 600px) and (max-width: 1180px) {
  .footer-inner { grid-template-columns: 1.2fr 1fr 1fr; padding-inline: 40px; gap: 32px; }
  .footer-brand { grid-column: auto; }
  .footer-base { padding-inline: 40px; }
  .contact-wrap { padding-inline: 32px; }
}

/* intro card: Contact us · Call · Scroll to explore on one line on desktop */
.panel[data-step="0"] .panel-actions { flex-wrap: nowrap; align-items: center; gap: .5rem; }
.panel[data-step="0"] .panel-actions .btn,
.stage.is-wide .panel[data-step="0"] .panel-actions .btn { padding: .65rem 1.1rem; font-size: .98rem; min-height: 46px; white-space: nowrap; }
.panel[data-step="0"] .scroll-cue { white-space: nowrap; margin-left: .3rem; font-size: .85rem; }
@media (max-width: 820px) and (max-aspect-ratio: 78/100) {
  .panel[data-step="0"] .panel-actions { display: grid; }
}

/* unfolded foldables & near-square screens: no "Scroll to explore" on the intro card */
@media (min-width: 600px) and (max-width: 1180px) and (min-aspect-ratio: 78/100) and (max-aspect-ratio: 150/100) {
  .scroll-cue { display: none; }
}
