/* ============================================================
   Michael Ankenmann for Huntsville & Chaffey
   Muskoka-inspired theme: calming blue/turquoise, water & topo motifs
   ============================================================ */

:root {
  /* Water — calming blue with a slight turquoise tint */
  --water: #2b8ca6;
  --water-deep: #14586b;
  --water-dark: #0d3f4d;
  --water-light: #e3f0f3;
  --water-mist: #f3f9fa;

  /* Muskoka accents */
  --pine: #2f5d4f;        /* forest green */
  --granite: #6b7178;     /* rock grey */
  --sand: #d8cbb4;        /* warm shoreline */
  --sun: #e2a54c;         /* subtle warm highlight */

  /* Ink & surfaces */
  --ink: #16262c;
  --ink-soft: #45575d;
  --muted: #6a7a80;
  --line: #dde7e9;
  --bg: #ffffff;
  --bg-alt: #f3f9fa;

  --radius: 14px;
  --radius-lg: 22px;
  --max: 1120px;
  --peek: clamp(90px, 15vh, 170px); /* how much of the video peeks above the fold */
  --wave-h: clamp(48px, 6vw, 88px);  /* wave divider height = section overlap amount */
  --shadow: 0 10px 30px -12px rgba(13, 63, 77, 0.28);
  --shadow-sm: 0 4px 14px -8px rgba(13, 63, 77, 0.30);
  --font: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Georgia", "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.4rem;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
  color: var(--water-dark);
}
h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); }
h2 { font-size: clamp(1.55rem, 3.2vw, 2.4rem); }
h3 { font-size: clamp(1.15rem, 2vw, 1.4rem); }

p { margin: 0 0 1rem; }
a { color: var(--water-deep); }

.eyebrow {
  display: inline-block;
  font-family: var(--font);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--water);
  margin-bottom: 0.6rem;
}

.lead { font-size: 1.18rem; color: var(--ink-soft); }

.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;
}

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--water-dark); color: #fff;
  padding: 0.6rem 1rem; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--water); color: #fff;
  padding: 0.8rem 1.5rem; border-radius: 999px;
  text-decoration: none; font-weight: 600; font-family: var(--font);
  border: 2px solid var(--water); cursor: pointer;
  transition: transform 0.06s ease, background 0.15s ease, box-shadow 0.15s ease;
  box-shadow: var(--shadow-sm);
}
.btn:hover { background: var(--water-deep); border-color: var(--water-deep); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 0.5rem 1.1rem; font-size: 0.9rem; box-shadow: none; }
.btn-lg { padding: 0.95rem 1.9rem; font-size: 1.05rem; }
.btn-outline { background: transparent; color: var(--water-deep); box-shadow: none; }
.btn-outline:hover { background: var(--water); color: #fff; }
.btn-ghost { background: rgba(255,255,255,0.12); color: #fff; border-color: rgba(255,255,255,0.5); box-shadow: none; }
.btn-ghost:hover { background: #fff; color: var(--water-deep); border-color: #fff; }
.btn-sun { background: var(--sun); border-color: var(--sun); color: var(--ink); }
.btn-sun:hover { background: #d0942f; border-color: #d0942f; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}
/* Semitransparent over the hero image at the top of the page */
.site-header:not(.scrolled) {
  background: linear-gradient(to bottom, rgba(13,63,77,0.42), rgba(13,63,77,0.10));
  backdrop-filter: saturate(1.2) blur(3px);
}
.site-header:not(.scrolled) .brand,
.site-header:not(.scrolled) .brand-text strong { color: #fff; }
.site-header:not(.scrolled) .nav-links a { color: rgba(255,255,255,0.92); }
.site-header:not(.scrolled) .nav-links a:hover,
.site-header:not(.scrolled) .nav-links a[aria-current="page"] { color: #fff; }
.site-header:not(.scrolled) .nav-links a[aria-current="page"]::after { background: #fff; }
.site-header:not(.scrolled) .nav-toggle span { background: #fff; }
.site-header:not(.scrolled) .brand-mark { box-shadow: inset 0 0 0 2px rgba(255,255,255,0.8); }

/* Solid once the user scrolls, or while the mobile menu is open */
.site-header.scrolled,
.site-header:has(.nav-links.open) {
  background: rgba(255,255,255,0.96);
  backdrop-filter: saturate(1.4) blur(8px);
  box-shadow: var(--shadow-sm);
}
/* When the menu is open over a transparent (unscrolled) header, use dark marks */
.site-header:not(.scrolled):has(.nav-links.open) .brand,
.site-header:not(.scrolled):has(.nav-links.open) .brand-text strong { color: var(--ink); }
.site-header:not(.scrolled):has(.nav-links.open) .nav-toggle span { background: var(--ink); }
.site-header:not(.scrolled):has(.nav-links.open) .brand-mark { box-shadow: inset 0 0 0 2px rgba(255,255,255,0.55); }
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  background:
    radial-gradient(circle at 50% 120%, var(--water-light) 0 30%, transparent 31%),
    linear-gradient(160deg, var(--water) 0%, var(--water-deep) 100%);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,0.55);
}
.brand-text { font-family: var(--font-display); font-size: 1.15rem; letter-spacing: -0.01em; }
.brand-text strong { color: var(--water-deep); }

.nav-links { display: flex; align-items: center; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav-links a {
  color: var(--ink-soft); text-decoration: none; font-weight: 500;
  padding: 0.3rem 0; position: relative;
}
.nav-links a:hover { color: var(--water-deep); }
.nav-links a[aria-current="page"] { color: var(--water-deep); }
.nav-links a[aria-current="page"]::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 2px; background: var(--water); border-radius: 2px;
}

.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: 0; cursor: pointer; padding: 8px;
}
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); border-radius: 2px; transition: 0.2s; }

/* ---------- Map texture (real OSM shorelines: Lake Vernon, Fairy Lake, etc.) --- */
.topo-bg { position: relative; }
.topo-bg::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url("/assets/img/map-huntsville.svg") center / cover no-repeat;
  opacity: 0.2;
  mix-blend-mode: multiply;
}
.topo-bg > * { position: relative; z-index: 1; }

/* ---------- Hero ---------- */
/* Solid water-tint gradient; the OSM lake/map texture (below, via ::before) is
   the only imagery. To use a real Muskoka photo later, layer it in here. */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: linear-gradient(165deg, var(--water) 0%, var(--water-deep) 55%, var(--water-dark) 100%);
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url("/assets/img/map-huntsville-light.svg") center / cover no-repeat;
  opacity: 0.22;
}
.hero-inner {
  position: relative; z-index: 1; max-width: 760px;
  padding-top: clamp(2.5rem, 6vw, 4.5rem);
  padding-bottom: clamp(3.5rem, 7vw, 5.5rem);
}
.hero h1 { color: #fff; }
.hero .lead { color: rgba(255,255,255,0.94); }
.hero-office {
  display: inline-block; max-width: 100%;
  background: rgba(255,255,255,0.14); border: 1px solid rgba(255,255,255,0.3);
  padding: 0.4rem 0.9rem; border-radius: 999px; font-size: 0.9rem; margin-bottom: 1.1rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 1.6rem; }

/* Fullscreen home hero. The copy area fills (100dvh − peek) so the video,
   which lives in the SAME section, peeks above the fold — with the hero's
   tint + map background continuous behind everything (no seam, no color band). */
.hero-full { display: flex; flex-direction: column; }
.hero-copy-area {
  min-height: calc(100dvh - var(--peek));
  display: grid; grid-template-columns: minmax(0, 1fr); align-content: center;
}
.hero-full .hero-inner { padding-top: clamp(5rem, 12vh, 8rem); }
.hero-video-wrap {
  position: relative; z-index: 1;
  padding-bottom: clamp(2.5rem, 6vw, 4rem);
  scroll-margin-top: 84px; /* clear the fixed header when "Learn More" scrolls here */
}
/* Keep the announcement video from feeling oversized on wide screens. */
.hero-video-wrap .video { max-width: 820px; margin-inline: auto; }

/* Compact interior page header — bigger type + accent rule */
.page-hero { min-height: 38vh; display: grid; grid-template-columns: minmax(0, 1fr); align-content: center; }
.page-hero .page-hero-inner {
  padding-top: clamp(7.5rem, 16vh, 11rem);
  padding-bottom: clamp(1.5rem, 3.5vw, 2.3rem);
  position: relative; z-index: 1;
}
.page-hero h1 { color: #fff; max-width: 20ch; font-size: clamp(2.4rem, 5.5vw, 3.6rem); }
.page-hero .lead { color: rgba(255,255,255,0.94); max-width: 60ch; }
.page-hero-cta { margin-top: 1.4rem; margin-bottom: 0; }
.page-hero-rule {
  display: block; width: 64px; height: 4px; margin-top: 1.4rem;
  background: var(--sun); border-radius: 4px;
}

/* Video facade */
.video { position: relative; }
.video-facade {
  display: flex; flex-direction: column; justify-content: flex-end;
  width: 100%; aspect-ratio: 16 / 9; border: 0; cursor: pointer;
  border-radius: var(--radius-lg); overflow: hidden;
  background-size: cover; background-position: center;
  box-shadow: var(--shadow); color: #fff; text-align: left;
  padding: 1rem 1.2rem;
}
.video-placeholder { cursor: default; }
.video-facade::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(13,63,77,0.55), rgba(13,63,77,0.05) 55%);
}
.video-play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 74px; height: 74px; border-radius: 50%;
  background: rgba(255,255,255,0.92); box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}
.video-play::after {
  content: ""; position: absolute; top: 50%; left: 54%; transform: translate(-50%, -50%);
  border-style: solid; border-width: 13px 0 13px 21px;
  border-color: transparent transparent transparent var(--water-deep);
}
.video-facade:hover .video-play { transform: translate(-50%, -50%) scale(1.06); }
.video-label { position: relative; font-weight: 600; }
.video iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: var(--radius-lg); display: block; }

/* ---------- Water dividers ---------- */
/* The section overlaps the one above by a wave-height; its own top edge is cut
   into a wave with a mask, so the section's real background + map texture fill
   the peaks while the gaps reveal the textured section above (seamless). The
   mask is a sum-of-sines wave that is exactly periodic, so it tiles + loops with
   no seam/hitch; it drifts sideways so the shoreline moves. */
.section.has-wave {
  position: relative;
  margin-top: calc(-1 * var(--wave-h));
  padding-top: calc(clamp(3rem, 6vw, 5rem) + var(--wave-h));
  background: var(--bg);
  --wave-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath fill='black' d='M0.0,60.0 L15.0,59.7 L30.0,59.4 L45.0,59.1 L60.0,58.8 L75.0,58.5 L90.0,58.3 L105.0,58.0 L120.0,57.8 L135.0,57.6 L150.0,57.4 L165.0,57.3 L180.0,57.2 L195.0,57.1 L210.0,57.0 L225.0,57.0 L240.0,57.0 L255.0,57.1 L270.0,57.2 L285.0,57.4 L300.0,57.6 L315.0,57.8 L330.0,58.1 L345.0,58.5 L360.0,58.8 L375.0,59.2 L390.0,59.6 L405.0,60.0 L420.0,60.5 L435.0,60.9 L450.0,61.3 L465.0,61.7 L480.0,62.0 L495.0,62.3 L510.0,62.6 L525.0,62.9 L540.0,63.2 L555.0,63.4 L570.0,63.6 L585.0,63.7 L600.0,63.9 L615.0,64.1 L630.0,64.2 L645.0,64.4 L660.0,64.6 L675.0,64.9 L690.0,65.2 L705.0,65.6 L720.0,66.0 L735.0,66.5 L750.0,67.1 L765.0,67.7 L780.0,68.5 L795.0,69.2 L810.0,70.1 L825.0,71.0 L840.0,71.9 L855.0,72.8 L870.0,73.8 L885.0,74.7 L900.0,75.6 L915.0,76.5 L930.0,77.3 L945.0,78.0 L960.0,78.6 L975.0,79.2 L990.0,79.6 L1005.0,79.8 L1020.0,80.0 L1035.0,80.0 L1050.0,79.8 L1065.0,79.5 L1080.0,79.1 L1095.0,78.6 L1110.0,77.9 L1125.0,77.2 L1140.0,76.3 L1155.0,75.4 L1170.0,74.4 L1185.0,73.3 L1200.0,72.3 L1215.0,71.2 L1230.0,70.1 L1245.0,69.1 L1260.0,68.1 L1275.0,67.1 L1290.0,66.2 L1305.0,65.3 L1320.0,64.5 L1335.0,63.7 L1350.0,63.0 L1365.0,62.4 L1380.0,61.8 L1395.0,61.3 L1410.0,60.8 L1425.0,60.4 L1440.0,60.0 L1440.0,100 L0,100 Z'/%3E%3C/svg%3E");
  -webkit-mask: var(--wave-mask) 0 0 / 1440px var(--wave-h) repeat-x, linear-gradient(#000 0 0) 0 100% / 100% calc(100% - var(--wave-h) + 1px) no-repeat;
          mask: var(--wave-mask) 0 0 / 1440px var(--wave-h) repeat-x, linear-gradient(#000 0 0) 0 100% / 100% calc(100% - var(--wave-h) + 1px) no-repeat;
  animation: wave-clip 26s linear infinite;
}
@keyframes wave-clip {
  from { -webkit-mask-position: 0 0, 0 100%; mask-position: 0 0, 0 100%; }
  to   { -webkit-mask-position: 1440px 0, 0 100%; mask-position: 1440px 0, 0 100%; }
}
.section-alt.has-wave { background: var(--bg-alt); }
.cta.has-wave { background: var(--pine); }

/* Preceding section: relative (for the accent wave) + room for the overlap. */
.hero:has(+ .section.has-wave),
.section:has(+ .section.has-wave),
.endorse-band:has(+ .section.has-wave) { position: relative; }
.hero:has(+ .section.has-wave) { padding-bottom: calc(var(--wave-h) + 0.5rem); }
.section:has(+ .section.has-wave) { padding-bottom: calc(clamp(3rem, 6vw, 5rem) + var(--wave-h)); }
.endorse-band:has(+ .section.has-wave) { padding-bottom: calc(clamp(2rem, 4vw, 3rem) + var(--wave-h)); }

/* One accent wave behind the shoreline, drawn in the section ABOVE (so the front
   mask doesn't clip it), drifting the opposite way via a cheap GPU transform. It
   is a solid --accent colour behind a wave-shaped mask, so the tint is easy to
   change per transition.
   HOW TO USE / IMPORTANT: --accent must be a colour that works for BOTH sides —
   it has to be visible against the section it SITS in (the one above) and still
   read sensibly against the section below. Semi-transparent white reads as foam
   on the dark hero, but over a LIGHT section (e.g. the light section just before
   the pine "Let's talk about your priorities" CTA) white is invisible, so those
   are tinted instead. Set --accent per preceding section below.
   It is over-sized (left/right: -1500px) so the transform loop never runs past
   the element edge and glitches — it always covers the viewport. */
.hero:has(+ .section.has-wave)::after,
.section:has(+ .section.has-wave)::after,
.endorse-band:has(+ .section.has-wave)::after {
  content: ""; position: absolute; left: -1500px; right: -1500px;
  bottom: calc(-0.15 * var(--wave-h)); /* tuck it down, more under the main wave */
  height: calc(var(--wave-h) * 1.9); pointer-events: none; will-change: transform;
  --accent: rgba(255, 255, 255, 0.22); /* default: sits over the dark hero */
  background: var(--accent);
  --accent-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 100' preserveAspectRatio='none'%3E%3Cpath fill='black' d='M0.0,61.5 L15.0,61.5 L30.0,61.5 L45.0,61.6 L60.0,61.8 L75.0,62.0 L90.0,62.3 L105.0,62.6 L120.0,63.0 L135.0,63.5 L150.0,64.0 L165.0,64.6 L180.0,65.2 L195.0,65.9 L210.0,66.7 L225.0,67.5 L240.0,68.3 L255.0,69.1 L270.0,70.0 L285.0,70.9 L300.0,71.8 L315.0,72.7 L330.0,73.6 L345.0,74.5 L360.0,75.3 L375.0,76.1 L390.0,76.9 L405.0,77.6 L420.0,78.3 L435.0,78.9 L450.0,79.5 L465.0,79.9 L480.0,80.4 L495.0,80.7 L510.0,80.9 L525.0,81.1 L540.0,81.2 L555.0,81.2 L570.0,81.1 L585.0,81.0 L600.0,80.8 L615.0,80.5 L630.0,80.1 L645.0,79.7 L660.0,79.3 L675.0,78.7 L690.0,78.2 L705.0,77.6 L720.0,77.0 L735.0,76.4 L750.0,75.7 L765.0,75.1 L780.0,74.4 L795.0,73.8 L810.0,73.1 L825.0,72.5 L840.0,71.9 L855.0,71.3 L870.0,70.8 L885.0,70.3 L900.0,69.8 L915.0,69.3 L930.0,68.9 L945.0,68.5 L960.0,68.2 L975.0,67.9 L990.0,67.6 L1005.0,67.3 L1020.0,67.0 L1035.0,66.8 L1050.0,66.6 L1065.0,66.4 L1080.0,66.2 L1095.0,66.0 L1110.0,65.9 L1125.0,65.7 L1140.0,65.5 L1155.0,65.3 L1170.0,65.1 L1185.0,64.9 L1200.0,64.7 L1215.0,64.5 L1230.0,64.3 L1245.0,64.0 L1260.0,63.8 L1275.0,63.5 L1290.0,63.3 L1305.0,63.0 L1320.0,62.8 L1335.0,62.5 L1350.0,62.3 L1365.0,62.1 L1380.0,61.9 L1395.0,61.7 L1410.0,61.6 L1425.0,61.5 L1440.0,61.5 L1440.0,100 L0,100 Z'/%3E%3C/svg%3E");
  -webkit-mask: var(--accent-mask) 0 bottom / 1440px 100% repeat-x;
          mask: var(--accent-mask) 0 bottom / 1440px 100% repeat-x;
  animation: drift-accent 34s linear infinite;
}
/* A light section above -> tint the wave so it is actually visible. */
.section:has(+ .section.has-wave)::after,
.endorse-band:has(+ .section.has-wave)::after { --accent: rgba(43, 140, 166, 0.34); }
/* ...but when the section BELOW is the green CTA, tint the wave green so it
   makes sense leading into it (must stay visible on the light section above). */
.section:has(+ .cta.has-wave)::after { --accent: rgba(47, 93, 79, 0.5); }
@keyframes drift-accent { from { transform: translateX(0); } to { transform: translateX(-1440px); } }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 6vw, 5rem) 0; }
.section-alt { background: var(--bg-alt); }
.section-tight { padding: clamp(2rem, 4vw, 3rem) 0; }
.section-head { max-width: 62ch; margin-bottom: 2rem; }
.section p { color: var(--ink-soft); }
.narrow { max-width: 720px; margin-inline: auto; }

/* ---------- Endorsement marquee ---------- */
.endorse-band { background: var(--water-mist); overflow: hidden; }
.marquee { display: flex; flex-direction: column; gap: 4rem; overflow: hidden; }
.marquee-row {
  display: flex; gap: 4.5rem; width: max-content;
  animation: marquee 90s linear infinite;
  /* Own GPU layer so the drifting accent wave overlapping the band can't force
     the row to repaint each frame (that was jittering the second row). */
  will-change: transform;
  backface-visibility: hidden;
}
/* Use a forward animation with reversed keyframes rather than
   animation-direction: reverse — the latter drops the row off the compositor
   in Chromium and jitters. */
.marquee-row.reverse { animation-name: marquee-reverse; }
@keyframes marquee-reverse {
  from { transform: translateX(-50%); }
  to   { transform: translateX(0); }
}
.marquee:hover .marquee-row { animation-play-state: paused; }
@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.bubble {
  flex: none; max-width: 320px; margin: 0; /* reset <figure> default 1em 40px */
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 0.9rem 1.1rem; box-shadow: var(--shadow-sm);
}
/* Endorse page: masonry columns so bubbles pack naturally (no stretch/squish) */
.endorse-list { columns: 270px 4; column-gap: 1rem; }
.endorse-list .bubble { width: 100%; max-width: none; margin: 0 0 1rem; break-inside: avoid; }
.endorse-note { text-align: center; color: var(--muted); font-size: 0.9rem; margin-top: 1.5rem; }

.bubble p { margin: 0 0 0.5rem; font-size: 0.98rem; color: var(--ink); }
.bubble .who { display: flex; align-items: center; gap: 0.6rem; font-size: 0.85rem; color: var(--muted); }
.bubble .avatar {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  background: linear-gradient(150deg, var(--water) 0%, var(--pine) 100%);
  color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 0.8rem;
}

/* ---------- Cards / feature grid ---------- */
.grid { display: grid; gap: 1.4rem; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.6rem; box-shadow: var(--shadow-sm);
}
.card h3 { color: var(--water-deep); }
.card p { margin: 0; }
.card-icon {
  width: 44px; height: 44px; border-radius: 12px; margin-bottom: 0.9rem;
  background: var(--water-light); display: grid; place-items: center; color: var(--water-deep);
}

/* ---------- About / split ---------- */
.split { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 2.5rem; align-items: center; }
.portrait {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow);
  aspect-ratio: 4 / 5; background: var(--water-light);
}
.portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- CTA band ---------- */
.cta {
  position: relative; overflow: hidden; color: #fff; text-align: center;
  background: var(--pine);
}
.cta::before {
  content: ""; position: absolute; inset: 0;
  background: url("/assets/img/map-huntsville-light.svg") center / cover no-repeat; opacity: 0.18;
}
.cta .container { position: relative; z-index: 1; }
.cta h2 { color: #fff; }
.cta p { color: rgba(255,255,255,0.9); }

/* ---------- Forms / embeds ---------- */
.form-embed {
  position: relative;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm); overflow: hidden;
}
/* GoHighLevel's form_embed.js sets the iframe's inline height once the form
   renders. We give it an explicit starting height + a height transition, so it
   smoothly grows/shrinks to the loaded size instead of snapping. */
.form-embed .ghl-form { width: 100%; height: 480px; border: 0; display: block; }

/* Graceful load: main.js adds .is-loading (JS present) which shows the spinner
   and hides the iframe; on iframe load it's removed and the form fades in.
   Without JS the class is never added, so the form just shows normally. */
.form-embed .ghl-form { transition: opacity 0.45s ease, height 0.55s ease; }
.form-embed.is-loading .ghl-form { opacity: 0; }
.form-loading {
  position: absolute; inset: 0; z-index: 1; background: #fff;
  display: grid; place-items: center;
  opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease;
}
.form-embed.is-loading .form-loading { opacity: 1; visibility: visible; }
.spinner {
  width: 34px; height: 34px; border-radius: 50%;
  border: 3px solid var(--line); border-top-color: var(--water);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.form-placeholder {
  border: 2px dashed var(--water); border-radius: var(--radius-lg);
  background: var(--water-mist); padding: 2.5rem 1.5rem; text-align: center; color: var(--ink-soft);
}
.form-placeholder code { background: #fff; padding: 0.15rem 0.4rem; border-radius: 6px; border: 1px solid var(--line); }

/* ---------- Floating "Get updates" button + modal ---------- */
.fab {
  position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 45;
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--sun); color: var(--ink); border: 0; border-radius: 999px;
  padding: 0.8rem 1.3rem; font-family: var(--font); font-weight: 700; font-size: 0.98rem;
  cursor: pointer; box-shadow: var(--shadow);
  transition: transform 0.12s ease, background 0.15s ease;
}
.fab:hover { background: #d0942f; transform: translateY(-2px); }
.fab svg { flex: none; }

.modal {
  width: min(460px, 92vw); max-height: 90vh; overflow: auto;
  padding: 0; border: 0; border-radius: var(--radius-lg); color: var(--ink);
  background: #fff; box-shadow: 0 30px 80px -20px rgba(13, 63, 77, 0.55);
}
.modal::backdrop { background: rgba(13, 63, 77, 0.5); backdrop-filter: blur(2px); }
.modal[open] { animation: modal-in 0.2s ease; }
@keyframes modal-in { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.2rem 1.3rem 0.2rem; }
.modal-head h2 { margin: 0; font-size: 1.3rem; }
.modal-close {
  background: none; border: 0; font-size: 1.9rem; line-height: 1; color: var(--muted);
  cursor: pointer; padding: 0 0.2rem; margin: -0.2rem -0.2rem 0 0;
}
.modal-close:hover { color: var(--ink); }
.modal-sub { padding: 0 1.3rem; margin: 0 0 0.9rem; color: var(--muted); font-size: 0.92rem; }
.modal .form-embed { margin: 0 1.1rem 1.1rem; border-radius: var(--radius); }
/* Start compact so the modal opens small, then animates up to the loaded size. */
.modal .form-embed .ghl-form { height: 240px; }

@media (max-width: 520px) {
  .fab { right: 0.9rem; bottom: 0.9rem; padding: 0.72rem 1.05rem; font-size: 0.92rem; }
}

/* ---------- Footer ---------- */
.site-footer { position: relative; background: var(--water-dark); color: #cfe0e4; padding-top: 2.6rem; }
.footer-topo { position: absolute; inset: 0; background: url("/assets/img/map-huntsville-light.svg") center / cover no-repeat; opacity: 0.14; pointer-events: none; }
.footer-inner { position: relative; display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; padding-bottom: 1.8rem; }
.footer-name { font-family: var(--font-display); font-size: 1.3rem; color: #fff; margin: 0 0 0.2rem; }
.footer-role { margin: 0 0 1rem; color: #a9c6cd; font-size: 0.92rem; }
.footer-heading { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.75rem; color: #8fb2ba; margin: 0 0 0.6rem; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; columns: 2; }
.footer-nav a { color: #cfe0e4; text-decoration: none; display: inline-block; padding: 0.25rem 0; }
.footer-nav a:hover { color: #fff; }
.footer-legal { position: relative; border-top: 1px solid rgba(255,255,255,0.12); padding-top: 1rem; padding-bottom: 1.6rem; }
.footer-legal p { margin: 0; font-size: 0.82rem; color: #9fbdc4; }
.footer-legal .fine-print { opacity: 0.8; margin-top: 0.25rem; }

/* ---------- Button rows ---------- */
.button-row { display: flex; flex-wrap: wrap; gap: 0.9rem; justify-content: center; }

/* ---------- Split button (Instagram / Facebook) ---------- */
.split-btn {
  display: inline-flex; border: 1px solid rgba(255,255,255,0.4);
  border-radius: 999px; overflow: hidden;
}
.split-btn-half {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.55rem 1.15rem; color: #fff; text-decoration: none;
  font-weight: 600; font-size: 0.9rem; background: rgba(255,255,255,0.08);
  transition: background 0.15s ease, color 0.15s ease;
}
.split-btn-half + .split-btn-half { border-left: 1px solid rgba(255,255,255,0.4); }
.split-btn-half:hover { background: #fff; color: var(--water-deep); }
.split-btn-half svg { flex: none; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .split .portrait { max-width: 340px; }
}
@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 0.5rem 1.4rem 1rem; display: none; box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; padding: 0.55rem 0; }
  /* Menu panel is white even when the header is transparent — keep links dark */
  .site-header:not(.scrolled) .nav-links.open a { color: var(--ink-soft); }
  .site-header:not(.scrolled) .nav-links.open a[aria-current="page"] { color: var(--water-deep); }
  .footer-inner { grid-template-columns: 1fr; }
}

/* ---------- Overflow / mobile margins ---------- */
html, body { overflow-x: hidden; }
@media (max-width: 520px) {
  .container { padding-left: 1.15rem; padding-right: 1.15rem; }
  .split { gap: 1.6rem; }
}

/* ---------- Motion safety ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-row,
  .section.has-wave,
  .hero:has(+ .section.has-wave)::after,
  .section:has(+ .section.has-wave)::after,
  .endorse-band:has(+ .section.has-wave)::after { animation: none !important; }
  * { transition-duration: 0.01ms !important; }
}
