/* ============================================================
   ACAI Diagnostic — main stylesheet
   Brand: professional medical imaging, Cayman Islands
   Palette anchored on deep purple; accents used sparingly.
   ============================================================ */

/* -- Design tokens ------------------------------------------------ */
:root {
  --purple: #5b3a8c;          /* primary brand */
  --purple-deep: #452c6b;     /* hover / press */
  --purple-tint: #f3eef9;     /* very pale purple wash */
  --plum: #883072;            /* secondary accent */
  --mint: #b0f5d0;            /* success/wellness micro-accent */
  --pink: #f7b5e5;            /* soft accent, rare */
  --ink: #1a1a1a;             /* body text */
  --ink-2: #4a4a52;           /* muted text */
  --ink-3: #7a7a82;           /* subtle labels */
  --line: #e6e6ea;            /* hairline borders */
  --grey-bg: #e9f0f1;         /* section wash */
  --paper: #fafafa;           /* off-white */
  --white: #ffffff;
  --shadow-sm: 0 1px 2px rgba(20,10,40,.06);
  --shadow-md: 0 6px 20px rgba(20,10,40,.08);
  --shadow-lg: 0 18px 48px rgba(20,10,40,.12);
  --radius: 14px;
  --radius-sm: 8px;
  --radius-lg: 22px;
  --wrap: 1160px;
  --gutter: clamp(20px, 4vw, 40px);
  --font-display: 'Poppins', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Poppins', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

/* -- Reset -------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--purple); text-decoration: none; }
a:hover { color: var(--purple-deep); text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 .4em;
}
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 700; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); font-weight: 700; }
h3 { font-size: clamp(1.2rem, 2vw, 1.35rem); font-weight: 600; }
p { margin: 0 0 1em; }
p.lead { font-size: 1.15rem; color: var(--ink-2); }

/* -- Utility ------------------------------------------------------ */
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section--tight { padding: clamp(40px, 6vw, 64px) 0; }
.section--wash { background: var(--grey-bg); }
.section--purple { background: var(--purple-tint); }
.eyebrow {
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--purple);
  margin: 0 0 .8rem;
  display: inline-block;
}
.divider { height: 1px; background: var(--line); border: 0; margin: 40px 0; }

/* -- Buttons ------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .98rem;
  border: 1.5px solid transparent;
  transition: all .18s ease;
  text-decoration: none;
  line-height: 1;
  cursor: pointer;
}
.btn--primary { background: var(--purple); color: var(--white); }
.btn--primary:hover { background: var(--purple-deep); color: var(--white); text-decoration: none; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn--ghost { background: transparent; color: var(--purple); border-color: var(--purple); }
.btn--ghost:hover { background: var(--purple); color: var(--white); text-decoration: none; }
.btn--white { background: var(--white); color: var(--purple); }
.btn--white:hover { background: var(--paper); color: var(--purple-deep); text-decoration: none; }
.btn--sm { padding: 10px 18px; font-size: .88rem; }
.btn--lg { padding: 16px 32px; font-size: 1.05rem; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

/* -- Header ------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  font-size: 1.05rem;
}
.logo:hover { text-decoration: none; color: var(--purple); }
.logo img { height: 44px; width: auto; }
.site-header .logo img { height: 60px; width: auto; }
@media (max-width: 500px) { .site-header .logo img { height: 48px; } }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-text small { font-family: var(--font-body); font-size: .68rem; font-weight: 500; color: var(--ink-3); letter-spacing: .05em; text-transform: uppercase; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a:not(.btn) { color: var(--ink-2); font-size: .94rem; font-weight: 500; }
.nav a:not(.btn):hover { color: var(--purple); text-decoration: none; }
.nav a.is-active { color: var(--purple); }
.nav a.btn { color: var(--white); font-weight: 700; letter-spacing: .02em; box-shadow: 0 2px 6px rgba(91,58,140,.28); }
.nav a.btn:hover { color: var(--white); box-shadow: 0 6px 16px rgba(91,58,140,.35); }
.nav-cta { margin-left: 8px; }
.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
  color: var(--ink);
}
.nav-toggle svg { width: 26px; height: 26px; }

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--white);
    padding: 20px var(--gutter);
    gap: 4px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .nav-cta { margin: 12px 0 0; align-self: flex-start; }
}

/* -- Hero -------------------------------------------------------- */
/* Two states: hero--empty (fallback gradient, dark text) and
   hero--image (slideshow with dark overlay, white text).
   Starts in --empty; JS upgrades to --image once at least one
   hero-N image loads successfully. */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  padding: clamp(80px, 12vw, 140px) 0 clamp(64px, 10vw, 120px);
}
.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1200px 500px at 90% 0%, rgba(136,48,114,.10), transparent 60%),
    radial-gradient(900px 500px at -10% 100%, rgba(91,58,140,.12), transparent 55%),
    var(--white);
  will-change: transform;
}
.hero__slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.6s ease-in-out;
}
.hero--image .hero__slide.is-active {
  opacity: 1;
  animation: heroKen 14s ease-in-out infinite alternate;
}
@keyframes heroKen {
  0%   { transform: scale(1.02) translate(0, 0); }
  100% { transform: scale(1.10) translate(-1%, -1%); }
}
.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  transition: opacity .8s ease;
}
.hero--image .hero__overlay { opacity: 1; }

.hero__content {
  max-width: 720px;
  color: var(--ink);
  transition: color .6s ease;
}
.hero--image .hero__content { color: var(--white); }
.hero--image .hero__content .eyebrow { color: rgba(255,255,255,.9); }
.hero--image .hero__content h1 { color: var(--white); text-shadow: 0 2px 24px rgba(0,0,0,.35); }
.hero--image .hero__content p.lead { color: rgba(255,255,255,.94); text-shadow: 0 1px 8px rgba(0,0,0,.35); }

/* Two-column hero layout: content + info stack.
   Info stack is only shown in the empty state (no photos yet) —
   it fills the right side of the hero so the page doesn't feel bare. */
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, .8fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
@media (max-width: 900px) {
  .hero__grid { grid-template-columns: 1fr; }
}
.hero--image .hero__stack { display: none; }

.hero__stack {
  display: grid;
  gap: 20px;
  padding: 28px 32px;
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  border: 1px solid rgba(91,58,140,0.1);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 50px rgba(91,58,140,0.15);
}
.hero__stack-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: center;
}
.hero__stack-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.6rem;
  line-height: 1;
  color: var(--purple);
  letter-spacing: -0.03em;
  min-width: 68px;
  text-align: center;
  position: relative;
}
.hero__stack-plus {
  font-size: 1.4rem;
  vertical-align: super;
  color: var(--plum);
}
.hero__stack-label {
  color: var(--ink-2);
  font-size: .92rem;
  line-height: 1.4;
  font-weight: 500;
}

/* EIM slot references — hidden markup, no visual effect */
.eim-slots { display: none !important; }
.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: .35em;
  font-weight: 700;
}
.hero h1 em {
  color: var(--purple);
  font-style: italic;
  font-weight: 500;
  transition: color .6s ease;
}
.hero--image h1 em { color: #ffd9a8; }
.hero__content p.lead {
  max-width: 56ch;
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero--image .btn--ghost {
  color: var(--white);
  border-color: rgba(255,255,255,.7);
  background: rgba(255,255,255,.06);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.hero--image .btn--ghost:hover {
  background: rgba(255,255,255,.94);
  color: var(--purple);
  border-color: transparent;
}

/* Dots (only visible when 2+ slides available) */
.hero__dots {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: none;
  gap: 8px;
  z-index: 2;
}
.hero--slideshow .hero__dots { display: flex; }
.hero__dot {
  width: 8px; height: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.5);
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: all .3s ease;
}
.hero__dot.is-active { background: var(--white); width: 24px; }
.hero__dot:hover { background: rgba(255,255,255,.85); }

/* Reduced motion — no Ken Burns, no parallax */
@media (prefers-reduced-motion: reduce) {
  .hero--image .hero__slide.is-active { animation: none; }
  .hero__bg { transform: none !important; }
}

/* -- Service cards ----------------------------------------------- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 40px;
}
@media (max-width: 900px) { .svc-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .svc-grid { grid-template-columns: 1fr; } }

.svc-card {
  background: var(--white);
  border: 0;
  border-radius: var(--radius);
  padding: 0 0 24px;
  transition: transform .25s ease, box-shadow .25s ease;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 1px 3px rgba(20,10,40,.04);
}
.svc-card > *:not(.svc-card__img-slot) { margin-left: 24px; margin-right: 24px; }
.svc-card > .svc-card__icon { margin-top: 20px; }
.svc-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(91,58,140,.15);
}
.svc-card__more { color: var(--purple); font-weight: 600; font-size: .82rem; }
.svc-card__more:hover { text-decoration: none; color: var(--purple-deep); }

/* Image slot: always present, shows a gradient + watermark icon by default.
   When an image loads, the img tag covers the placeholder entirely. */
.svc-card__img-slot {
  width: 100%;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, var(--purple) 0%, var(--plum) 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.svc-card__img-slot::after {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,.12), transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(0,0,0,.15), transparent 55%);
  pointer-events: none;
}
.svc-card__img-icon {
  width: 68px; height: 68px;
  color: rgba(255,255,255,.9);
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,.15));
}
.svc-card__img-icon svg { width: 100%; height: 100%; }
.svc-card__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 2;  /* covers the placeholder gradient + icon when loaded */
}
.svc-card__icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: var(--purple-tint);
  color: var(--purple);
  display: grid;
  place-items: center;
}
.svc-card__icon svg { width: 26px; height: 26px; }
.svc-card h3 { margin: 0; font-size: 1.15rem; }
.svc-card p { color: var(--ink-2); font-size: .93rem; margin: 0; }
.svc-card__meta { display: flex; justify-content: space-between; align-items: center; font-size: .82rem; color: var(--ink-3); margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--line); }
.svc-card__meta strong { color: var(--purple); font-weight: 600; }

/* -- Location cards ---------------------------------------------- */
.loc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
  margin-top: 40px;
}
.loc-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.loc-card__pin {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--plum);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.loc-card h3 { margin: 0; font-size: 1.6rem; }
.loc-card__row {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 14px;
  color: var(--ink-2);
  font-size: .95rem;
  align-items: start;
}
.loc-card__row svg {
  width: 18px; height: 18px;
  color: var(--purple);
  margin-top: 3px;
}
.loc-card__ctas { display: flex; gap: 10px; margin-top: 8px; flex-wrap: wrap; }

/* -- About / Team ------------------------------------------------ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}
@media (max-width: 820px) { .about-grid { grid-template-columns: 1fr; } }
.about-mission {
  background: var(--purple-tint);
  border-radius: var(--radius);
  padding: 32px;
  position: sticky;
  top: 90px;
}
.about-mission h3 { color: var(--purple); }
.commit-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.commit-list li {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 12px;
  color: var(--ink-2);
  font-size: .95rem;
}
.commit-list li::before {
  content: '';
  width: 8px; height: 8px;
  background: var(--purple);
  border-radius: 999px;
  margin-top: 8px;
}

.team-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 24px;
  align-items: start;
}
@media (max-width: 600px) { .team-card { grid-template-columns: 1fr; } }
.team-card__portrait {
  width: 120px; height: 120px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--purple), var(--plum));
  color: var(--white);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-weight: 500;
  overflow: hidden;
}
.team-card__portrait img { width: 100%; height: 100%; object-fit: cover; }
.team-card h3 { margin: 0 0 4px; }
.team-card__role { color: var(--purple); font-weight: 600; font-size: .95rem; margin: 0 0 14px; }

/* -- Contact / Forms --------------------------------------------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}
@media (max-width: 820px) { .form-grid { grid-template-columns: 1fr; } }
.form { display: grid; gap: 16px; }
.form label { font-weight: 500; font-size: .9rem; color: var(--ink-2); display: block; margin-bottom: 6px; }
.form input, .form select, .form textarea {
  width: 100%;
  padding: 13px 14px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--white);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none;
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(91,58,140,.12);
}
.form textarea { min-height: 120px; resize: vertical; }
.form .field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 500px) { .form .field-row { grid-template-columns: 1fr; } }
.form-note { font-size: .82rem; color: var(--ink-3); }
.form-msg { padding: 14px 16px; border-radius: var(--radius-sm); font-size: .94rem; display: none; }
.form-msg.is-shown { display: block; }
.form-msg--ok { background: var(--mint); color: #0f4f2b; }
.form-msg--err { background: #fde5e5; color: #8a1e1e; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* -- Contact info block ------------------------------------------ */
.contact-info { display: grid; gap: 22px; }
.contact-info__row {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 14px;
  align-items: start;
}
.contact-info__row svg {
  width: 22px; height: 22px;
  color: var(--purple);
  margin-top: 6px;
}
.contact-info__row strong { display: block; margin-bottom: 4px; font-size: 1rem; }
.contact-info__row span, .contact-info__row a { color: var(--ink-2); font-size: .94rem; }

/* -- CTA band ---------------------------------------------------- */
.cta-band {
  background: linear-gradient(135deg, var(--purple), var(--purple-deep));
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: clamp(40px, 6vw, 72px);
  text-align: center;
  margin: clamp(56px, 8vw, 96px) 0;
}
.cta-band h2 { color: var(--white); margin-bottom: .3em; }
.cta-band p { color: rgba(255,255,255,.9); font-size: 1.1rem; max-width: 52ch; margin: 0 auto 28px; }
.cta-band__actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* -- Footer ------------------------------------------------------ */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,.75);
  padding: clamp(48px, 6vw, 72px) 0 24px;
}
.site-footer a { color: rgba(255,255,255,.85); }
.site-footer a:hover { color: var(--white); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid h4 {
  color: var(--white);
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin: 0 0 16px;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-size: .92rem; }
.footer-brand p { font-size: .92rem; line-height: 1.7; }
.footer-brand .logo { color: var(--white); margin-bottom: 16px; }
.footer-brand .logo:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: .82rem;
  color: rgba(255,255,255,.55);
}
.footer-medical { font-size: .8rem; color: rgba(255,255,255,.5); font-style: italic; margin-top: 32px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.08); }

/* -- Page banner (non-home pages) -------------------------------- */
.page-banner {
  background: var(--purple-tint);
  padding: clamp(56px, 8vw, 96px) 0 clamp(40px, 6vw, 64px);
  border-bottom: 1px solid var(--line);
}
.page-banner h1 { margin-bottom: .3em; }
.page-banner p { color: var(--ink-2); max-width: 60ch; font-size: 1.1rem; margin: 0; }

/* -- Legal / long-form content ----------------------------------- */
.prose { max-width: 68ch; }
.prose h2 { margin-top: 2em; }
.prose h3 { margin-top: 1.5em; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; color: var(--ink-2); }

/* -- Accessibility ----------------------------------------------- */
:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; border-radius: 4px; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}

/* -- v3: dynamic service cards with images ----------------------- */

/* Overrides the v1/v2 svc-card layout — v3 cards lead with an image */
.svc-card {
  padding: 0;
  overflow: hidden;
  background: var(--white);
}
.svc-card__media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--purple-tint);
}
.svc-card__img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .3s ease;
}
.svc-card:hover .svc-card__img { transform: scale(1.03); }
.svc-ph {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--purple), var(--plum));
  color: rgba(255,255,255,.85);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.1rem;
  letter-spacing: .04em;
}
.svc-card__body {
  padding: 22px 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.svc-card__cat {
  font-size: .72rem;
  color: var(--plum);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.svc-card h3 { margin: 0; font-size: 1.15rem; }
.svc-card h3 a { color: var(--ink); text-decoration: none; }
.svc-card h3 a:hover { color: var(--purple); }
.svc-card__meta { color: var(--ink-3); font-size: .85rem; margin: 0; }
.svc-card__desc { color: var(--ink-2); font-size: .93rem; margin: 4px 0 0; }
.svc-card__foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.svc-card__price { color: var(--purple); font-weight: 600; }
.svc-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--ink-3);
  background: var(--paper);
  border-radius: var(--radius);
}

.svc-group { margin-bottom: 56px; }
.svc-group:last-child { margin-bottom: 0; }
.svc-group__heading {
  font-size: 1.5rem;
  margin: 0 0 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--purple);
  display: inline-block;
}

/* -- v3: service detail page (service.html) ---------------------- */
.crumbs {
  font-size: .88rem;
  color: var(--ink-3);
  margin-bottom: 24px;
}
.crumbs a { color: var(--ink-2); text-decoration: none; }
.crumbs a:hover { color: var(--purple); }
.crumbs span { margin: 0 6px; color: var(--line); }

.sp-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  margin-bottom: 48px;
}
@media (max-width: 800px) { .sp-hero { grid-template-columns: 1fr; } }
.sp-hero__media {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--purple-tint);
}
.sp-hero__img { width: 100%; height: 100%; object-fit: cover; }
.sp-hero__body h1 { margin: 8px 0 12px; }
.sp-meta { color: var(--ink-3); font-size: 1rem; margin: 0 0 16px; }
.sp-priceline { margin-bottom: 24px; }
.sp-price {
  font-family: var(--font-display);
  color: var(--purple);
  font-size: 1.8rem;
  font-weight: 500;
}
.sp-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.sp-sec {
  margin: 40px 0;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line);
}
.sp-sec:last-of-type { border-bottom: 0; }
.sp-sec h2 { font-size: 1.4rem; margin: 0 0 16px; }
.sp-steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  display: grid;
  gap: 14px;
  margin: 0;
}
.sp-steps li {
  counter-increment: step;
  padding-left: 44px;
  position: relative;
  color: var(--ink-2);
  line-height: 1.6;
}
.sp-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: -2px;
  width: 30px; height: 30px;
  border-radius: 999px;
  background: var(--purple);
  color: var(--white);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: .9rem;
  font-family: var(--font-body);
}

.sp-details ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.sp-details li {
  padding: 16px 20px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}
.sp-details li:last-child { border-right: 0; }
.sp-details li span {
  display: block;
  font-size: .78rem;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 4px;
}
.sp-details li b { color: var(--ink); font-weight: 600; font-size: .98rem; }

.sp-related {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}
.sp-rel {
  display: block;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  transition: all .15s ease;
}
.sp-rel:hover {
  border-color: var(--purple);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
}
.sp-rel__img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}
.sp-rel .svc-ph { aspect-ratio: 16 / 10; }
.sp-rel span {
  display: block;
  padding: 14px 16px;
}
.sp-rel b { color: var(--ink); display: block; font-size: .98rem; margin-bottom: 4px; }
.sp-rel em { color: var(--ink-3); font-style: normal; font-size: .82rem; }

.sp-book {
  text-align: center;
  margin-top: 40px;
  padding: 32px;
  background: var(--purple-tint);
  border-radius: var(--radius);
}

/* -- v3: hero image on home ------------------------------------- */
.hero-image {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

/* ============================================================
   v3 — Service detail page (service.html?id=X)
   Hero image, badges, spec table, related grid.
   ============================================================ */
.crumbs {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 24px var(--gutter) 0;
  font-size: .88rem;
  color: var(--ink-3);
}
.crumbs a { color: var(--ink-3); }
.crumbs a:hover { color: var(--purple); }
.sp-hero {
  max-width: var(--wrap);
  margin: 24px auto 40px;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
@media (max-width: 820px) {
  .sp-hero { grid-template-columns: 1fr; }
  .sp-hero .sp-photo { order: -1; }
}
.sp-photo {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: linear-gradient(135deg, var(--purple-tint), var(--grey-bg));
  aspect-ratio: 4 / 3;
}
.sp-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sp-head h1 { margin: 12px 0 8px; }
.sp-badges { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.sp-badge {
  display: inline-block;
  padding: 4px 12px;
  background: var(--purple-tint);
  color: var(--purple);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  border-radius: 999px;
}
.sp-meta { color: var(--ink-3); font-size: .95rem; }
.sp-priceline { margin: 12px 0; }
.sp-price { font-family: var(--font-display); font-size: 1.6rem; color: var(--purple); font-weight: 500; }
.sp-cta { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.sp-sec {
  max-width: 780px;
  margin: 0 auto 40px;
  padding: 0 var(--gutter);
}
.sp-sec h2 {
  font-size: 1.4rem;
  margin-bottom: .5em;
}
.sp-sec p { color: var(--ink-2); font-size: 1.02rem; }
.sp-list { padding-left: 0; list-style: none; }
.sp-list li {
  position: relative;
  padding: 8px 0 8px 32px;
  color: var(--ink-2);
  border-bottom: 1px solid var(--line);
}
.sp-list li::before {
  content: '';
  position: absolute;
  left: 4px; top: 14px;
  width: 16px; height: 16px;
  border-radius: 999px;
  background: var(--purple);
}
.sp-list.yes li::before { background: #0f8a53; }
.sp-list.no li::before { background: #b23b3b; }
.sp-steps { padding-left: 20px; }
.sp-steps li { color: var(--ink-2); padding: 6px 0; }
.sp-steps li b { color: var(--ink); }
.sp-details ul { list-style: none; padding: 0; margin: 0 0 16px; border-top: 1px solid var(--line); }
.sp-details ul li {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: .95rem;
}
.sp-details ul li span { color: var(--ink-3); font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; padding-top: 2px; }
.sp-details ul li b { color: var(--ink); font-weight: 500; }
.sp-scope { color: var(--ink-3); font-size: .88rem; font-style: italic; }
.sp-related {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.sp-rel {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
  transition: all .15s ease;
}
.sp-rel:hover { border-color: var(--purple); transform: translateY(-2px); box-shadow: var(--shadow-sm); text-decoration: none; color: var(--ink); }
.sp-rel img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--purple-tint); }
.sp-rel span { padding: 14px; display: block; }
.sp-rel span b { display: block; font-size: 1rem; margin-bottom: 4px; }
.sp-rel span em { color: var(--purple); font-style: normal; font-weight: 600; font-size: .85rem; }
.sp-book {
  max-width: 780px;
  margin: 0 auto 56px;
  padding: 32px var(--gutter);
  text-align: center;
  border-top: 1px solid var(--line);
}

/* Services hub page — grouped sections */
.svc-group { margin-bottom: 56px; }
.svc-group__head { margin-bottom: 8px; }
.svc-group__head h2 { margin-bottom: 4px; }

/* Hero image support on home — background image gracefully absent */
.hero--with-image {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* ============================================================
   v4 — Scroll-reveal animations (fail-safe)
   Elements are only hidden once JS has confirmed IntersectionObserver
   support and added .js-anim-ready to <html>. If JS fails, breaks, or
   is disabled, content stays visible.
   ============================================================ */
.js-anim-ready .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .8s ease-out, transform .8s ease-out;
}
.js-anim-ready .reveal.revealed { opacity: 1; transform: none; }
.js-anim-ready .reveal-stagger > * {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .6s ease-out, transform .6s ease-out;
}
.js-anim-ready .revealed .reveal-stagger > *,
.js-anim-ready .reveal-stagger.revealed > * { opacity: 1; transform: none; }
.js-anim-ready .reveal-stagger > *:nth-child(1) { transition-delay: 0ms; }
.js-anim-ready .reveal-stagger > *:nth-child(2) { transition-delay: 80ms; }
.js-anim-ready .reveal-stagger > *:nth-child(3) { transition-delay: 160ms; }
.js-anim-ready .reveal-stagger > *:nth-child(4) { transition-delay: 240ms; }
.js-anim-ready .reveal-stagger > *:nth-child(5) { transition-delay: 320ms; }
.js-anim-ready .reveal-stagger > *:nth-child(6) { transition-delay: 400ms; }

@media (prefers-reduced-motion: reduce) {
  .js-anim-ready .reveal, .js-anim-ready .reveal-stagger > * {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ============================================================
   v4 — Pre-footer locations band
   Two location cards displayed prominently above the footer.
   Uses the deep purple as background — high visibility handoff.
   ============================================================ */
.pre-footer {
  background: linear-gradient(135deg, var(--purple), var(--purple-deep));
  color: var(--white);
  padding: clamp(48px, 6vw, 72px) 0;
}
.pre-footer .eyebrow { color: rgba(255,255,255,.75); }
.pre-footer h2 { color: var(--white); font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 32px; }
.pre-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
}
.pre-footer__loc h3 {
  font-family: var(--font-display);
  color: var(--white);
  font-size: 1.4rem;
  font-weight: 500;
  margin: 0 0 8px;
}
.pre-footer__loc .pin {
  display: inline-block;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.7);
  margin-bottom: 8px;
}
.pre-footer__loc p { margin: 0 0 6px; color: rgba(255,255,255,.9); font-size: .95rem; }
.pre-footer__loc a { color: var(--white); font-weight: 600; }
.pre-footer__loc a:hover { color: #ffd9a8; text-decoration: none; }
.pre-footer__ctas { margin-top: 14px; display: flex; gap: 8px; flex-wrap: wrap; }
