/* ==========================================================================
   Discover Your Health - Design System
   Palette: dusty pink / sage / light sage / warm cream / charcoal
   Type: Playfair Display (display) · Lato (body) · Mrs Saint Delafield
   (accent, free placeholder for the licensed "Southfield Signature" script)
   ========================================================================== */

:root {
  --pink: #DDA4AE;
  --pink-soft: #EFD3D9;
  --sage: #6A7F62;
  --sage-deep: #4F6049;
  --sage-light: #DDE6D2;
  --cream: #F7F4EE;
  --white: #FFFFFF;
  --charcoal: #333B36;
  --charcoal-70: #454D47; /* solid, not 70%-alpha: kept the name for the ~7 existing references, but this is now a fixed dark tone so contrast holds on sage-light and cream backgrounds too */
  --charcoal-40: rgba(51, 59, 54, 0.4);
  --charcoal-12: rgba(51, 59, 54, 0.12);

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Lato', -apple-system, sans-serif;
  --font-accent: 'Mrs Saint Delafield', cursive; /* free match for the licensed 'Southfield' script, swap here once purchased */

  --container: 1180px;
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 10px;
  --shadow-soft: 0 20px 60px -25px rgba(51, 59, 54, 0.25);
  --shadow-card: 0 12px 32px -18px rgba(51, 59, 54, 0.28);

  --space-3xs: 0.4rem;
  --space-2xs: 0.8rem;
  --space-xs: 1.2rem;
  --space-sm: 1.8rem;
  --space-md: 2.8rem;
  --space-lg: 4.5rem;
  --space-xl: 4.5rem;
  --space-2xl: 6rem;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
body {
  font-family: var(--font-body);
  color: var(--charcoal);
  background: var(--cream);
  line-height: 1.7;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font: inherit; color: inherit; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; line-height: 1.15; letter-spacing: -0.01em; color: var(--charcoal); margin-bottom: var(--space-sm); }
h1 { font-size: clamp(2.6rem, 5vw, 4.6rem); font-weight: 700; }
h2 { font-size: clamp(2.1rem, 3.4vw, 3rem); }
h3 { font-size: clamp(1.4rem, 2vw, 1.7rem); margin-bottom: var(--space-xs); }
h4 { margin-bottom: var(--space-2xs); }
p { max-width: 62ch; margin-bottom: var(--space-xs); }
p:last-child { margin-bottom: 0; }
.lede { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--charcoal-70); font-weight: 300; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sage-deep);
  margin-bottom: var(--space-xs);
}
.eyebrow::before { content: ''; width: 28px; height: 1px; background: var(--pink); display: inline-block; }

.accent-script {
  font-family: var(--font-accent);
  font-weight: 400;
  color: var(--sage-deep);
  line-height: 1;
}

.section-head { max-width: 700px; margin-bottom: var(--space-lg); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--space-md); }
@media (max-width: 640px) { .container { padding: 0 var(--space-sm); } }

.section { padding: var(--space-2xl) 0; position: relative; }
.section--tight { padding: var(--space-xl) 0; }
.section--sage-light { background: var(--sage-light); }
.section--cream { background: var(--cream); }
.section--charcoal { background: var(--charcoal); color: var(--cream); }
.section--charcoal h2, .section--charcoal h3 { color: var(--cream); }
.section--charcoal .eyebrow { color: var(--pink); }
.section--charcoal p { color: rgba(247, 244, 238, 0.75); }
.section--sage-deep { background: var(--sage-deep); color: var(--cream); }
.section--sage-deep h2, .section--sage-deep h3 { color: var(--cream); }
.section--sage-deep .eyebrow { color: var(--pink); }
.section--sage-deep p { color: rgba(247, 244, 238, 0.8); }

@media (max-width: 900px) {
  .section { padding: var(--space-xl) 0; }
  .section--tight { padding: var(--space-lg) 0; }
}

.grid { display: grid; gap: var(--space-md); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

/* ---------- Reveal on scroll ----------
   Content is visible by default (no JS dependency). main.js "arms" elements
   with .js-armed on load, which is what actually applies the hidden
   pre-animation state, so if the script fails to load, nothing stays hidden. */
.reveal { opacity: 1; transform: none; }
.reveal.js-armed { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.js-armed.is-visible { opacity: 1; transform: translateY(0); }
.reveal-stagger.is-visible > * { transition-delay: calc(var(--i, 0) * 110ms); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 1em 2.1em;
  border-radius: 100px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), background 0.3s var(--ease), color 0.3s var(--ease);
  white-space: nowrap;
}
.btn-primary { background: var(--sage); color: var(--cream); box-shadow: 0 10px 26px -12px rgba(106, 127, 98, 0.65); }
.btn-primary:hover { background: var(--sage-deep); transform: translateY(-2px); box-shadow: 0 16px 32px -14px rgba(106, 127, 98, 0.75); }
.btn-outline { background: transparent; color: var(--charcoal); box-shadow: inset 0 0 0 1.5px var(--charcoal-40); }
.btn-outline:hover { box-shadow: inset 0 0 0 1.5px var(--charcoal); transform: translateY(-2px); }
.btn-light { background: var(--cream); color: var(--sage-deep); }
.btn-light:hover { background: var(--white); transform: translateY(-2px); }
.btn-arrow { display: inline-flex; align-items: center; gap: 0.5em; font-weight: 700; color: var(--sage-deep); border-bottom: 1.5px solid var(--pink); padding-bottom: 0.15em; transition: gap 0.3s var(--ease), color 0.3s var(--ease); }
.btn-arrow:hover { gap: 0.9em; color: var(--sage); }
.btn:focus-visible, a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--sage-deep);
  outline-offset: 3px;
}

/* ---------- Nav ---------- */
.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1.6rem 0;
  background: var(--cream);
  transition: padding 0.4s var(--ease), background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.site-nav.is-scrolled {
  padding: 1rem 0;
  background: rgba(247, 244, 238, 0.92);
  backdrop-filter: blur(14px);
  box-shadow: 0 8px 30px -18px rgba(51, 59, 54, 0.35);
}
.site-nav .container { display: flex; align-items: center; justify-content: space-between; gap: 4rem; }
.brand { display: flex; align-items: center; gap: 0.7rem; font-family: var(--font-display); font-weight: 700; letter-spacing: 0.01em; }
.brand-logo { width: 40px; height: 40px; border-radius: 50%; object-fit: contain; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-name { font-size: 1.25rem; white-space: nowrap; }
.brand-tagline { font-family: var(--font-body); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--pink); margin-top: 0.1rem; white-space: nowrap; }
.footer-logo-plate { width: 60px; height: 60px; border-radius: 50%; background: var(--cream); display: flex; align-items: center; justify-content: center; margin-bottom: var(--space-sm); }
.footer-logo-plate img { width: 46px; height: 46px; object-fit: contain; }
.footer-tagline { font-family: var(--font-body); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pink); }
.nav-links { display: flex; align-items: center; gap: var(--space-lg); }
.nav-links a { font-size: 0.95rem; font-weight: 700; position: relative; padding: 0.3em 0; white-space: nowrap; }
.nav-links a::after { content: ''; position: absolute; left: 0; right: 100%; bottom: 0; height: 1.5px; background: var(--sage-deep); transition: right 0.35s var(--ease); }
.nav-links a:hover::after, .nav-links a.is-active::after { right: 0; }
.nav-links a.is-active { color: var(--sage-deep); }
.nav-cta { display: flex; align-items: center; gap: var(--space-md); }
.nav-toggle { display: none; flex-direction: column; gap: 5px; padding: 0.5rem; }
.nav-toggle span { width: 24px; height: 2px; background: var(--charcoal); transition: transform 0.3s var(--ease), opacity 0.3s var(--ease); }

@media (max-width: 900px) {
  .nav-links { position: fixed; top: 0; right: 0; height: 100vh; width: min(78vw, 340px); background: var(--cream); flex-direction: column; justify-content: center; align-items: flex-start; gap: var(--space-md); padding: var(--space-lg); transform: translateX(100%); transition: transform 0.45s var(--ease); box-shadow: -20px 0 50px -20px rgba(0,0,0,0.2); }
  .nav-links.is-open { transform: translateX(0); }
  .nav-links a { font-size: 1.1rem; }
  .nav-cta .btn-primary { display: none; }
  .nav-toggle { display: flex; z-index: 110; }
  body.nav-open { overflow: hidden; }
  .nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.is-open span:nth-child(2) { opacity: 0; }
  .nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ---------- Hero ---------- */
.hero { padding: 11rem 0 var(--space-2xl); overflow: hidden; background: var(--sage-light); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--space-xl); align-items: center; }
.hero h1 { margin: var(--space-xs) 0 var(--space-sm); }
.hero h1 em { font-style: italic; color: var(--sage-deep); }
.hero-actions { display: flex; align-items: center; gap: var(--space-md); margin-top: var(--space-md); flex-wrap: wrap; }
@media (max-width: 900px) { .hero { padding: 8rem 0 var(--space-xl); } .hero-grid { grid-template-columns: 1fr; gap: var(--space-lg); } }

/* ---------- Image placeholders ---------- */
.img-frame {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.img-frame.ratio-square { aspect-ratio: 1 / 1; }
.img-frame.ratio-portrait { aspect-ratio: 4 / 5; }
.img-frame.ratio-wide { aspect-ratio: 16 / 10; }
.img-frame.ratio-tall { aspect-ratio: 3 / 4; }
.img-frame-fill {
  position: absolute;
  inset: 0;
  background: linear-gradient(155deg, var(--sage-light) 0%, var(--pink-soft) 100%);
}
.img-frame-fill::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(circle at 30% 20%, rgba(255,255,255,0.5), transparent 55%);
}
.img-frame-label {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 1;
  margin: var(--space-sm);
  padding: 0.5em 1em;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage-deep);
  background: rgba(255,255,255,0.72);
  border-radius: 100px;
}

/* ---------- Real photos ---------- */
.photo-frame { position: relative; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-soft); }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-frame.ratio-square { aspect-ratio: 1 / 1; }
.photo-frame.ratio-portrait { aspect-ratio: 4 / 5; }
.photo-frame.ratio-wide { aspect-ratio: 16 / 10; }
.room-card .photo-frame { border-radius: 0; box-shadow: none; }

/* ---------- Cards ---------- */
.card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  box-shadow: var(--shadow-card);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: 0 24px 46px -20px rgba(51, 59, 54, 0.32); }

.practitioner-card { display: flex; flex-direction: column; }
.practitioner-card h3 { margin-bottom: 0; }
.practitioner-card .img-frame { margin-bottom: var(--space-sm); flex-shrink: 0; }
.practitioner-card .photo-frame { margin-bottom: var(--space-sm); flex-shrink: 0; }
.practitioner-card .role { color: var(--sage-deep); font-weight: 700; font-size: 0.9rem; margin: 0.3rem 0 var(--space-xs); }
.tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.practitioner-card .tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: var(--space-xs) 0; }
.tag { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; background: var(--sage-light); color: var(--sage-deep); padding: 0.4em 0.9em; border-radius: 100px; white-space: nowrap; display: inline-block; }
.practitioner-card .bio { color: var(--charcoal-70); font-size: 0.96rem; flex-grow: 1; }
.practitioner-card .btn-arrow { margin-top: var(--space-sm); }

.program-card { background: var(--cream); }
.program-card .eyebrow { margin-bottom: var(--space-2xs); }

.room-card { padding: 0; overflow: hidden; }
.room-card .img-frame { border-radius: 0; }
.room-card .room-body { padding: var(--space-md); }
.room-card .feature-list { margin: var(--space-sm) 0; display: grid; gap: 0.6rem; }
.room-card .feature-list li { display: flex; gap: 0.7rem; font-size: 0.93rem; color: var(--charcoal-70); }
.room-card .feature-list li::before { content: '•'; color: var(--pink); flex-shrink: 0; }
.room-card .room-meta { display: flex; justify-content: space-between; align-items: center; margin-top: var(--space-sm); padding-top: var(--space-sm); border-top: 1px solid var(--charcoal-12); }

/* ---------- Testimonials ---------- */
.testimonial-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: var(--space-md);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.testimonial-card .quote-mark { font-family: var(--font-display); font-size: 3rem; color: var(--pink); line-height: 1; margin-bottom: var(--space-2xs); }
.testimonial-card p { font-size: 0.98rem; color: var(--charcoal-70); flex-grow: 1; }
.testimonial-card .attribution { margin-top: var(--space-sm); font-family: var(--font-accent); font-size: 2.6rem; font-weight: 400; color: var(--pink); }

/* ---------- Framework diagram (signature element) ---------- */
.framework { display: grid; grid-template-columns: 0.95fr 1.05fr; gap: var(--space-xl); align-items: center; }
@media (max-width: 1000px) { .framework { grid-template-columns: 1fr; } }
.framework-diagram { width: 100%; max-width: 560px; margin: 0 auto; }
.framework-diagram img { width: 100%; display: block; border-radius: var(--radius-lg); box-shadow: var(--shadow-soft); }

.framework-legend { display: grid; gap: var(--space-sm); margin-top: var(--space-md); }
.framework-legend-item { display: grid; grid-template-columns: 20px 1fr; gap: var(--space-xs); align-items: baseline; }
.framework-legend-item .dot { width: 11px; height: 11px; border-radius: 50%; margin-top: 6px; }
.framework-legend-item h4 { font-size: 1.05rem; margin-bottom: 0.2rem; }
.framework-legend-item p { font-size: 0.92rem; color: var(--charcoal-70); }

/* ---------- Forms ---------- */
.form-field { margin-bottom: var(--space-sm); }
.form-field label { display: block; font-size: 0.82rem; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase; color: var(--sage-deep); margin-bottom: 0.6rem; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  padding: 0.95em 1.1em;
  background: var(--white);
  border: 1px solid var(--charcoal-12);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus { border-color: var(--sage); box-shadow: 0 0 0 4px rgba(106,127,98,0.14); outline: none; }
.form-field textarea { min-height: 140px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-sm); }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }

/* ---------- Generic checklist ---------- */
.check-list { display: grid; gap: 0.9rem; }
.check-list.two-col { grid-template-columns: 1fr 1fr; gap: 0.9rem 2rem; }
@media (max-width: 700px) { .check-list.two-col { grid-template-columns: 1fr; } }
.check-list li { display: flex; gap: 0.8rem; align-items: flex-start; font-size: 0.98rem; color: var(--charcoal-70); }
.check-list li::before { content: ''; flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; background: var(--pink); margin-top: 8px; }
.check-list li > div { display: flex; flex-direction: column; gap: 0.15rem; }
.check-list .program-name { font-weight: 700; color: var(--charcoal); }
.check-list .program-desc { font-size: 0.85rem; color: var(--charcoal-70); }

/* ---------- Divider / stat strip ---------- */
.divider-ring { width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--pink); margin: 0 auto var(--space-md); }

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-md); }
@media (max-width: 800px) { .pillars { grid-template-columns: 1fr; } }
.pillar { text-align: center; padding: var(--space-md) var(--space-sm); }
.pillar .glyph { width: 76px; height: 76px; margin: 0 auto var(--space-sm); border-radius: 50%; background: var(--sage-light); display: flex; align-items: center; justify-content: center; }

/* ---------- Footer ---------- */
.site-footer { background: var(--charcoal); color: rgba(247,244,238,0.8); padding: var(--space-xl) 0 var(--space-md); border-top: 1px solid rgba(247, 244, 238, 0.14); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: var(--space-lg); padding-bottom: var(--space-lg); border-bottom: 1px solid rgba(247,244,238,0.14); }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-grid h4 { color: var(--cream); font-family: var(--font-body); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: var(--space-sm); }
.footer-grid a { display: block; margin-bottom: 0.7rem; font-size: 0.94rem; transition: color 0.3s var(--ease); }
.footer-grid a:hover { color: var(--pink); }
.footer-brand .accent-script { color: var(--pink); font-size: 1.6rem; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: var(--space-md); font-size: 0.85rem; color: rgba(247,244,238,0.55); flex-wrap: wrap; gap: var(--space-sm); }

/* ---------- Back to top ---------- */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 90;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--sage);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 26px -12px rgba(106, 127, 98, 0.65);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease), visibility 0.35s, background 0.3s var(--ease), box-shadow 0.3s var(--ease);
  pointer-events: none;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { background: var(--sage-deep); box-shadow: 0 16px 32px -14px rgba(106, 127, 98, 0.75); transform: translateY(-3px); }
body.nav-open .back-to-top { opacity: 0; visibility: hidden; pointer-events: none; }
@media (max-width: 640px) { .back-to-top { bottom: 1.25rem; right: 1.25rem; width: 44px; height: 44px; } }

/* ---------- Page header (non-home pages) ---------- */
.page-header { padding: 11rem 0 var(--space-lg); text-align: center; background: var(--sage-light); }
.page-header .lede { margin: 0 auto; }

/* ---------- Misc ---------- */
.center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.mt-lg { margin-top: var(--space-lg); }
.mt-sm { margin-top: var(--space-sm); }
.note-box { background: var(--sage-light); border-radius: var(--radius-md); padding: var(--space-md); }
.note-box p { color: var(--charcoal); }
