/**
 * NewFlex AFTER redesign — shared visual system
 * Palette: #081F2D + #3B75D6 + #FFFFFF (+ #1A5D87 / #EBEBEB supporting)
 *
 * Header metrics are locked here so every page renders the same chrome.
 */
:root {
  --nf-navy: #081F2D;
  --nf-blue: #3B75D6;
  --nf-blue-2: #1A5D87;
  --nf-gray: #EBEBEB;
  --nf-white: #FFFFFF;
  --nf-text: #1F2937;
  --nf-muted: #5B6570;
  --nf-radius: 8px;
  --nf-font: "Plus Jakarta Sans", Manrope, Inter, sans-serif;
  --nf-header-h: 72px;
  --nf-header-h-m: 64px;
  --nf-logo-h: 40px;
  --nf-logo-h-m: 34px;
}

html {
  scrollbar-gutter: stable;
}

/* —— Shared header (identical on all pages) —— */
#nf-navbar {
  position: fixed !important;
  top: 0; left: 0; right: 0;
  z-index: 2147483647 !important;
  background: var(--nf-navy) !important;
  border-bottom: 1px solid rgba(255,255,255,0.12) !important;
  box-shadow: none !important;
  box-sizing: border-box !important;
  height: var(--nf-header-h) !important;
  min-height: var(--nf-header-h) !important;
  max-height: var(--nf-header-h) !important;
  overflow: visible !important;
  font-family: var(--nf-font) !important;
  font-size: 16px !important;
  line-height: 1.2 !important;
}
#nf-navbar *,
#nf-navbar *::before,
#nf-navbar *::after {
  box-sizing: border-box;
}
#nf-navbar .nf-nav-bar,
#nf-navbar .nf-nav-inner {
  max-width: 1280px !important;
  width: 100% !important;
  margin: 0 auto !important;
  padding: 0 24px !important;
  height: var(--nf-header-h) !important;
  min-height: var(--nf-header-h) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  flex-wrap: nowrap !important;
}
#nf-navbar .nf-nav-logo,
#nf-navbar a.nf-nav-logo,
#nf-navbar a[aria-label="NewFlex Group Home"],
#nf-navbar a.no-ajax[aria-label="NewFlex Group Home"] {
  display: flex !important;
  align-items: center !important;
  flex-shrink: 0 !important;
  text-decoration: none !important;
}
#nf-navbar .nf-nav-logo img,
#nf-navbar a.nf-nav-logo img,
#nf-navbar a[aria-label="NewFlex Group Home"] img,
#nf-navbar a.no-ajax[aria-label="NewFlex Group Home"] img {
  height: var(--nf-logo-h) !important;
  width: auto !important;
  max-width: none !important;
  max-height: var(--nf-logo-h) !important;
  object-fit: contain !important;
  filter: brightness(0) invert(1) !important;
  flex-shrink: 0 !important;
}
#nf-navbar .nf-nav-desktop,
#nf-navbar .nf-nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
#nf-navbar .nf-nav-desktop a,
#nf-navbar .nf-nav-links a {
  padding: 8px 14px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: rgba(255,255,255,0.92) !important;
  text-decoration: none !important;
  border-radius: 8px !important;
  background: transparent !important;
  box-shadow: none !important;
  white-space: nowrap !important;
  transition: background 0.2s ease, color 0.2s ease;
}
#nf-navbar .nf-nav-desktop a:hover,
#nf-navbar .nf-nav-links a:hover {
  background: rgba(59,117,214,0.22) !important;
  color: #fff !important;
}
#nf-navbar .nf-nav-desktop a.is-active,
#nf-navbar .nf-nav-links a.is-active,
#nf-navbar .nf-nav-desktop a[aria-current="page"],
#nf-navbar .nf-nav-links a[aria-current="page"] {
  background: var(--nf-blue) !important;
  color: #fff !important;
  box-shadow: none !important;
}
#nf-navbar .nf-nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
  margin-left: 8px;
}
#nf-navbar .nf-nav-phone {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  font-size: 13px !important;
  font-weight: 600 !important;
  color: #fff !important;
  text-decoration: none !important;
  white-space: nowrap !important;
}
#nf-navbar .nf-nav-phone svg {
  width: 18px;
  height: 18px;
  stroke: var(--nf-blue);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
#nf-navbar .nf-nav-cta {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  height: 40px !important;
  padding: 0 16px !important;
  background: var(--nf-blue) !important;
  color: #fff !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: 0.04em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  border-radius: var(--nf-radius) !important;
  box-shadow: none !important;
  white-space: nowrap !important;
  transition: background 0.2s ease, transform 0.2s ease;
}
#nf-navbar .nf-nav-cta:hover {
  background: #2f62b8 !important;
  color: #fff !important;
  transform: translateY(-1px);
}
#nf-navbar .nf-nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.06);
  color: #fff;
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
}
#nf-navbar .nf-nav-toggle svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
}
#nf-navbar .nf-nav-mobile {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--nf-navy);
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding: 10px 16px 16px;
  flex-direction: column;
  gap: 4px;
  box-shadow: 0 16px 40px rgba(8,31,45,0.45);
}
#nf-navbar .nf-nav-mobile.is-open { display: flex; }
#nf-navbar .nf-nav-mobile a {
  padding: 12px 14px;
  color: rgba(255,255,255,0.92);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
}
#nf-navbar .nf-nav-mobile a.is-active,
#nf-navbar .nf-nav-mobile a[aria-current="page"] {
  background: var(--nf-blue);
  color: #fff;
}
#nf-top-spacer {
  height: var(--nf-header-h) !important;
  min-height: var(--nf-header-h) !important;
  background: var(--nf-navy) !important;
}

/* Hero / banner backgrounds — keep photographic sharpness */
.nf-hero__bg,
.lf-hero__bg,
.av-hero__bg,
.mp-hero__bg,
.ct-banner__bg,
.ra-banner__bg {
  transform: none !important;
  animation: none !important;
  filter: none !important;
  -webkit-filter: none !important;
  image-rendering: auto;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  background-repeat: no-repeat !important;
  background-size: cover !important;
}

/* Shared primary CTA */
.nf-btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  background: var(--nf-blue);
  color: #fff !important;
  font-family: var(--nf-font);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: var(--nf-radius);
  border: none;
  box-shadow: none;
  transition: background 0.2s ease, transform 0.2s ease;
}
.nf-btn-primary:hover {
  background: #2f62b8;
  transform: translateY(-1px);
  color: #fff !important;
}
.nf-btn-primary svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.nf-phone-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff !important;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
}
.nf-phone-row__ico {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(59,117,214,0.2);
  border: 1px solid rgba(59,117,214,0.55);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nf-phone-row__ico svg {
  width: 16px;
  height: 16px;
  stroke: var(--nf-blue);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Floating appointment FAB */
#floatBtn-1,
.nf-float-appt {
  background: var(--nf-blue) !important;
  border-radius: 50% !important;
  box-shadow: 0 8px 24px rgba(59,117,214,0.4) !important;
}
#floatBtn-1 a,
#floatBtn-1 a:hover {
  background: var(--nf-blue) !important;
  background-color: var(--nf-blue) !important;
  border-radius: 50% !important;
}
@media (max-width: 900px) {
  #floatBtn-1 { bottom: 18px !important; right: 14px !important; }
}

@media (max-width: 900px) {
  #nf-navbar {
    height: var(--nf-header-h-m) !important;
    min-height: var(--nf-header-h-m) !important;
    max-height: var(--nf-header-h-m) !important;
  }
  #nf-navbar .nf-nav-bar,
  #nf-navbar .nf-nav-inner {
    height: var(--nf-header-h-m) !important;
    min-height: var(--nf-header-h-m) !important;
    padding: 0 14px !important;
    gap: 10px !important;
  }
  #nf-navbar .nf-nav-desktop,
  #nf-navbar .nf-nav-links { display: none !important; }
  #nf-navbar .nf-nav-phone { display: none !important; }
  /* AFTER mobile: keep CTA + hamburger */
  #nf-navbar .nf-nav-cta {
    display: inline-flex !important;
    height: 36px !important;
    padding: 0 12px !important;
    font-size: 10px !important;
  }
  #nf-navbar .nf-nav-toggle { display: inline-flex !important; }
  #nf-navbar .nf-nav-actions {
    gap: 8px !important;
    margin-left: auto !important;
  }
  #nf-navbar .nf-nav-logo img,
  #nf-navbar a.nf-nav-logo img,
  #nf-navbar a[aria-label="NewFlex Group Home"] img,
  #nf-navbar a.no-ajax[aria-label="NewFlex Group Home"] img {
    height: var(--nf-logo-h-m) !important;
    max-height: var(--nf-logo-h-m) !important;
  }
  #nf-top-spacer {
    height: var(--nf-header-h-m) !important;
    min-height: var(--nf-header-h-m) !important;
  }
  #nf-navbar .nf-nav-mobile { top: var(--nf-header-h-m) !important; }
}
