/* ============================================
   Eastern County Care - Main Stylesheet
   Colour Palette: Navy + Sage Green + Gold Accents
   ============================================ */

/* --- CSS Variables --- */
:root {
  --color-black: #121212;
  --color-navy: #263347;
  --color-navy-dark: #1c2738;
  --color-navy-light: #344a63;
  --color-navy-lighter: #3d5570;
  --color-sage: #96AC8B;
  --color-sage-dark: #7a9170;
  --color-sage-light: #a8bda0;
  --color-sage-bg: #849c79;
  --color-gold: #B39F68;
  --color-gold-dark: #9a8856;
  --color-gold-light: #c4b37f;
  --color-white: #FFFFFF;
  --color-offwhite: #F5F5F5;
  --color-light-gray: #E0E0E0;
  --color-text-muted: #c0c8d0;
  --color-text-muted-sage: #d4ddd0;
  --font-heading: 'arboria', 'Georgia', serif;
  --font-body: 'avenir-next', 'Segoe UI', Arial, sans-serif;
  --transition-smooth: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --max-width: 1200px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-navy);
  color: var(--color-white);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--color-gold);
  text-decoration: none;
  transition: var(--transition-smooth);
}

a:hover {
  color: var(--color-gold-light);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 40px;
}

/* --- Logo Opener  --- */
.logo-opener {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--color-navy-dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  transition: opacity 2.5s cubic-bezier(0.4, 0, 0.2, 1), visibility 2.5s ease, transform 2.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.logo-opener.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: scale(1.04);
}

.opener-logo-container {
  position: relative;
  width: 300px;
  height: 300px;
  margin-bottom: 40px;
}

.opener-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transform: scale(1.6);
  filter: blur(8px) drop-shadow(0 0 0px rgba(179, 159, 104, 0));
  animation: logoReveal 2.5s ease-out 0.5s forwards;
}

.opener-text {
  text-align: center;
  overflow: hidden;
}

.opener-company-name {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--color-white);
  opacity: 0;
  transform: translateY(20px);
  animation: textReveal 1s ease-out 2s forwards;
}

.opener-company-name .gold {
  color: var(--color-gold);
}

.opener-tagline {
  font-family: var(--font-body);
  font-size: 1rem;
	font-style: italic; 
  color: var(--color-sage-light);
  letter-spacing: 4px;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(15px);
  animation: textReveal 1s ease-out 2.5s forwards;
  margin-top: 12px;
}

.opener-skip {
  position: absolute;
  bottom: 40px;
  right: 40px;
  background: none;
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--color-text-muted);
  padding: 8px 20px;
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition-smooth);
  opacity: 0;
  animation: textReveal 0.5s ease-out 1s forwards;
}

.opener-skip:hover {
  border-color: var(--color-gold);
  color: var(--color-gold);
}

@keyframes logoReveal {
  0% {
    opacity: 0;
    transform: scale(1.6);
    filter: blur(8px) drop-shadow(0 0 0px rgba(179, 159, 104, 0));
  }
  40% {
    opacity: 0.7;
    transform: scale(1.08);
    filter: blur(1px) drop-shadow(0 0 40px rgba(179, 159, 104, 0.5));
  }
  70% {
    opacity: 1;
    transform: scale(1);
    filter: blur(0) drop-shadow(0 0 60px rgba(179, 159, 104, 0.4));
  }
  85% {
    filter: blur(0) drop-shadow(0 0 80px rgba(179, 159, 104, 0.3));
  }
  100% {
    opacity: 1;
    transform: scale(1);
    filter: blur(0) drop-shadow(0 0 40px rgba(179, 159, 104, 0.2));
  }
}

@keyframes textReveal {
  0% { opacity: 0; transform: translateY(20px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* --- Navigation --- */
.main-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9000;
  background: rgba(38, 51, 71, 0.0);
  backdrop-filter: blur(0px);
  transition: background 0.4s ease, backdrop-filter 0.4s ease, box-shadow 0.4s ease;
  padding: 0;
}

.main-nav.scrolled {
  background: rgba(38, 51, 71, 0.97);
  backdrop-filter: blur(20px);
  box-shadow: 0 2px 30px rgba(0,0,0,0.2);
}

.nav-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 40px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Home page: nav logo hidden until hero scrolls away */
.home-page .nav-logo {
  opacity: 0;
  transform: translateX(-10px);
  pointer-events: none;
  transition: opacity 0.22s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

.home-page .nav-logo.nav-logo-visible {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.nav-logo img {
  height: 65px;
  width: auto;
}

.nav-logo-text {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 1px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  color: var(--color-white);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  position: relative;
  padding: 4px 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-gold);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links a:hover {
  color: var(--color-gold);
}

.nav-cta {
  background: var(--color-gold) !important;
  color: var(--color-navy) !important;
  padding: 10px 24px !important;
  border-radius: 4px;
  font-weight: 600 !important;
  letter-spacing: 1px;
}

.nav-cta::after {
  display: none !important;
}

.nav-cta:hover {
  background: var(--color-sage) !important;
  color: var(--color-white) !important;
}

/* Mobile Nav Toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 5px;
}

.nav-toggle span {
  width: 25px;
  height: 2px;
  background: var(--color-white);
  transition: var(--transition-smooth);
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Hero Section --- */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
  filter: brightness(0.4);
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;   
  /* background: linear-gradient(180deg, rgba(38,51,71,0.1) 0%, rgba(38,51,71,0.5) 60%, var(--color-navy) 100%); */
  
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  padding: 0 40px;
  padding-top: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-logo {
  width: 340px;
  margin: 0 auto 10px;
  display: block;
  opacity: 0;
  /* Logo appears first, after opener fades out (~4.5s) */
  animation: heroFadeIn 1.4s cubic-bezier(0.22, 1, 0.36, 1) 4.8s both;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 20px;
  opacity: 0;
  /* Heading appears slowly after logo */
  animation: heroSlideUp 1.4s cubic-bezier(0.22, 1, 0.36, 1) 5.4s both;
}

.hero h1 .gold {
  color: var(--color-gold);
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--color-text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
  opacity: 0;
  /* Subtitle appears after heading */
  animation: heroSlideUp 1.4s cubic-bezier(0.22, 1, 0.36, 1) 6.0s both;
  line-height: 1.8;
}

.hero-cta {
  display: inline-block;
  background: var(--color-gold);
  color: var(--color-navy);
  padding: 16px 40px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  border-radius: 4px;
  opacity: 0;
  /* Button appears last */
  animation: heroSlideUp 1.4s cubic-bezier(0.22, 1, 0.36, 1) 6.6s both;
  transition: background 0.4s ease, color 0.4s ease, transform 0.4s ease, box-shadow 0.4s ease;
}

.hero-cta:hover {
  background: var(--color-sage);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(179, 159, 104, 0.3);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  opacity: 0;
  animation: heroSlideUp 1.4s cubic-bezier(0.22, 1, 0.36, 1) 7.2s both;
}

.scroll-arrow {
  width: 24px;
  height: 24px;
  border-right: 2px solid var(--color-gold);
  border-bottom: 2px solid var(--color-gold);
  transform: rotate(45deg);
  animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
  0%, 100% { transform: rotate(45deg) translateY(0); opacity: 1; }
  50% { transform: rotate(45deg) translateY(10px); opacity: 0.5; }
}

@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(30px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* When skip is used — instantly show all hero elements with no animation */
.hero-skip-done .hero-logo,
.hero-skip-done .hero h1,
.hero-skip-done .hero-subtitle,
.hero-skip-done .hero-cta,
.hero-skip-done .hero-scroll-indicator {
  animation: none !important;
  opacity: 1 !important;
  transform: none !important;
}

/* Hero-specific animations — triggered after opener closes */
@keyframes heroFadeIn {
  0%   { opacity: 0; transform: scale(0.32); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes heroSlideUp {
  0%   { opacity: 0; transform: translateY(40px); }
  60%  { opacity: 1; }
  100% { opacity: 1; transform: translateY(0); }
}

/* --- Scroll Animation Classes --- */
.reveal {
  opacity: 0;
  transform: translateY(200px);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-150px);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(150px);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.85s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.85s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* Stagger delays — 9 levels */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }
.delay-6 { transition-delay: 0.6s; }
.delay-7 { transition-delay: 0.7s; }
.delay-8 { transition-delay: 0.8s; }
.delay-9 { transition-delay: 0.9s; }

/* --- Section Styles --- */
.section {
  padding: 120px 0;
  position: relative;
}

.section-navy {
  background-color: var(--color-navy);
  position: relative;
  overflow: hidden;
}

/* bg1 texture on navy sections — 20% opacity, fades in from top */
.section-navy::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('../images/backgrounds/bg1.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.20;
  /* Gradient mask: transparent at top, full opacity at bottom */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.4) 25%, rgba(0,0,0,1.0) 60%, black 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.4) 25%, rgba(0,0,0,1.0) 60%, black 100%);
  pointer-events: none;
  z-index: -1;
}

.section-navy > * {
  position: relative;
  z-index: 1;
}

.section-navy-dark {
  background: var(--color-navy-dark);
}

.section-sage {
  background-color: var(--color-sage-bg);
  color: var(--color-white);
  position: relative;
  overflow: hidden;
}

/* Sage texture pseudo-element — 10% opacity, fades in from top */
.section-sage::before {
  content: '';
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.10;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.4) 25%, rgba(0,0,0,0.8) 60%, black 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.4) 25%, rgba(0,0,0,0.8) 60%, black 100%);
  pointer-events: none;
  z-index: 0;
}

.section-sage > * {
  position: relative;
  z-index: 1;
}

/* Sage section background texture variants */
.section-sage.bg-tex-2::before {
  background-image: url('../images/backgrounds/bg2.png');
  opacity: 0.10; /* bg2 — 10% */
}

.section-sage.bg-tex-3::before {
  background-image: url('../images/backgrounds/bg3.png');
  opacity: 0.10; /* bg3 — 10% */
}

.section-sage.bg-tex-4::before {
  background-image: url('../images/backgrounds/bg4.png');
  opacity: 0.20; /* bg4 — 20% */
}

.section-sage .section-subtitle,
.section-sage .feature-card p,
.section-sage .specialist-item p,
.section-sage .intro-text p,
.section-sage .benefit-item p {
  color: var(--color-text-muted-sage);
}

.section-gradient {
  background: linear-gradient(180deg, var(--color-navy) 0%, var(--color-navy-dark) 100%);
}

.section-gradient-sage {
  background: linear-gradient(180deg, var(--color-sage-bg) 0%, var(--color-sage-dark) 100%);
}

.section-gradient-sage .section-subtitle,
.section-gradient-sage .specialist-item p,
.section-gradient-sage .benefit-item p {
  color: var(--color-text-muted-sage);
}

/* --- Gold Shimmer Divider --- */
.gold-divider {
  width: 100%;
  height: 3px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(179, 159, 104, 0.3) 15%,
    rgba(179, 159, 104, 0.7) 30%,
    #b39f68 42%,
    #e8d9a8 48%,
    #ffffff 50%,
    #e8d9a8 52%,
    #b39f68 58%,
    rgba(179, 159, 104, 0.7) 70%,
    rgba(179, 159, 104, 0.3) 85%,
    transparent 100%
  );
}

/* Animated shimmer sweep across the divider */
.gold-divider::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.0) 30%,
    rgba(255, 255, 255, 0.8) 50%,
    rgba(255, 255, 255, 0.0) 70%,
    transparent 100%
  );
  animation: shimmerSweep 3s ease-in-out infinite;
}

@keyframes shimmerSweep {
  0%   { left: -60%; }
  100% { left: 160%; }
}

.section-header {
  text-align: center;
  margin-bottom: 70px;
}

.section-label {
  display: inline-block;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 4px;
  text-transform: uppercase;
  margin-bottom: 16px;
  /* Shimmer  — slow elegant gold sweep -------------------------------------------------------------------------------------------------------- */
  background: linear-gradient(
    90deg,
    #b39f68 0%,
    #b39f68 30%,
    #f5e6a3 45%,
    #fffbe8 50%,
    #f5e6a3 55%,
    #b39f68 70%,
    #b39f68 100%
  );
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: sectionLabelShimmer 22s linear infinite;
}

.section-label-navy {
  display: inline-block;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 4px;
  text-transform: uppercase;
  margin-bottom: 16px;
  /* Shimmer  — slow elegant gold sweep with Navy Blue Font------------------------------------------------------------------------------------------ */
  background: linear-gradient(
    90deg,
    #263347 0%,
    #263347 30%,
    #f5e6a3 45%,
    #fffbe8 50%,
    #f5e6a3 55%,
    #263347 70%,
    #263347 100%
  );
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: sectionLabelShimmer 22s linear infinite;
}

@keyframes sectionLabelShimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}

/* Restore gold shimmer on mobile for all section-labels (navy sections) */
@media (max-width: 950px) {
  .section-label {
    background: linear-gradient(
      90deg,
      #b39f68 0%,
      #b39f68 30%,
      #f5e6a3 45%,
      #fffbe8 50%,
      #f5e6a3 55%,
      #b39f68 70%,
      #b39f68 100%
    );
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: sectionLabelShimmer 22s linear infinite;
  }
}


.section-title {
  font-size: 2.8rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--color-white);
}


/* --- Changed gold word to navy blue on the sage gree sections ------------------------------------------------------------------------------ */
.section-title .gold {
  color: var(--color-gold);
}

.section-title .navy {
  color: var(--color-navy);
}

/* ------------------------------------------------------------------------------------------------------------------------------------------- */


.section-subtitle {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 650px;
  margin: 0 auto;
  line-height: 1.8;
}

/* --- Full Bleed Image --- */
.full-bleed {
  position: relative;
  width: 100%;
  height: 70vh;
  min-height: 400px;
  overflow: hidden;
}

.full-bleed img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 6s ease;
}

.full-bleed:hover img {
  transform: scale(1.03);
}

.full-bleed-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(38,51,71,0.2) 0%, rgba(38,51,71,0.6) 100%);
}

.full-bleed-content {
  position: absolute;
  bottom: 60px;
  left: 60px;
  z-index: 2;
  max-width: 500px;
}

.full-bleed-content h3 {
  font-size: 2rem;
  margin-bottom: 12px;
}

.full-bleed-content p {
  color: var(--color-light-gray);
  font-size: 1rem;
}

/* --- Feature Cards --- */
.feature-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.feature-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.2);
  border-radius: 12px;
  padding: 40px 30px;
  text-align: center;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--color-sage), var(--color-gold));
  transform: scaleX(0);
  transition: transform 0.4s ease;
}

.feature-card:hover::before {
  transform: scaleX(1);
}

.feature-card:hover {
  background: var(--color-navy);
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  border-color: rgba(179, 159, 104, 0.5);
}

.feature-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, var(--color-sage), var(--color-gold));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon svg {
  width: 32px;
  height: 32px;
  fill: var(--color-white);
}

.feature-card h3 {
  font-size: 1.3rem;
  margin-bottom: 14px;
  color: var(--color-white);
  font-family: var(--font-heading);
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* --- About / Intro Section --- */
.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.intro-text h2 {
  font-size: 2.4rem;
  margin-bottom: 24px;
}

.intro-text p {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  margin-bottom: 20px;
  line-height: 1.8;
}

.intro-image {
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}

.intro-image img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.intro-image:hover img {
  transform: scale(1.05);
}

/* --- Philosophy Section --- */
.philosophy-section {
  position: relative;
  padding: 140px 0;
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
}

.philosophy-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(38, 51, 71, 0.88);
}

/* Gold shimmer on bg1.png shapes only — very subtle, smooth continuous left-to-right sweep */
.section-navy::after {
  content: '';
  position: absolute;
  inset: 0;
  /* Wide gradient: mostly transparent with a narrow bright band that sweeps through */
  background: linear-gradient(
    90deg,
    rgba(179, 159, 104, 0.01) 0%,
    rgba(179, 159, 104, 0.01) 43%,
    rgba(179, 159, 104, 0.15) 47%,
    rgba(210, 190, 130, 0.27) 50%,
    rgba(179, 159, 104, 0.15) 53%,
    rgba(179, 159, 104, 0.01) 57%,
    rgba(179, 159, 104, 0.01) 100%
  );
  background-size: 400% 100%;
  -webkit-mask-image: url('../images/backgrounds/bg1.png');
  -webkit-mask-size: cover;
  -webkit-mask-position: center;
  -webkit-mask-repeat: no-repeat;
  mask-image: url('../images/backgrounds/bg1.png');
  mask-size: cover;
  mask-position: center;
  mask-repeat: no-repeat;
  animation: navyShimmer 20s linear infinite;
  animation-delay: 0s;
  pointer-events: none;
  z-index: 0;
}

/* Stagger shimmer so the 3 navy sections never sweep at the same time */
#specialist::after {
  animation-delay: -6.67s;
}

#testimonials::after {
  animation-delay: -13.33s;
}

@keyframes navyShimmer {
  0%   { background-position: 150% 0; }
  100% { background-position: -150% 0; }
}

.philosophy-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.philosophy-content blockquote {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-style: italic;
  color: var(--color-white);
  line-height: 1.6;
  border-left: 4px solid var(--color-gold);
  padding-left: 30px;
  margin: 30px 0;
  text-align: left;
}

/* --- Location Cards --- */
.location-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.location-card {
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.2);
  transition: var(--transition-smooth);
}

.location-card:hover {
  background: var(--color-navy);
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  border-color: rgba(179, 159, 104, 0.5);
}

.location-card-image {
  height: 280px;
  overflow: hidden;
}

.location-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.location-card:hover .location-card-image img {
  transform: scale(1.08);
}

.location-card-content {
  padding: 30px;
}

.location-card-content h3 {
  font-size: 1.4rem;
  margin-bottom: 10px;
  color: var(--color-white);
}

.location-card-content p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  margin-bottom: 16px;
  line-height: 1.7;
}

.btn-outline {
  display: inline-block;
  border: 1px solid var(--color-gold);
  color: var(--color-gold);
  padding: 10px 24px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-radius: 4px;
  transition: var(--transition-smooth);
}

.btn-outline:hover {
  background: var(--color-gold);
  color: var(--color-navy);
}

.btn-primary {
  display: inline-block;
  background: var(--color-gold);
  color: var(--color-navy);
  padding: 14px 36px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.btn-primary:hover {
  background: var(--color-sage);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(179, 159, 104, 0.3);
}

/* --- Testimonials --- */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.testimonial-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.2);
  border-radius: 12px;
  padding: 40px;
  position: relative;
  transition: var(--transition-smooth);
}

.testimonial-card:hover {
  background: var(--color-navy);
  transform: translateY(-5px);
  box-shadow: 0 16px 50px rgba(0,0,0,0.25);
  border-color: rgba(179, 159, 104, 0.5);
}

.testimonial-card::before {
  content: '\201C';
  font-family: var(--font-heading);
  font-size: 5rem;
  color: var(--color-gold);
  opacity: 0.3;
  position: absolute;
  top: 10px;
  left: 20px;
  line-height: 1;
}

.testimonial-card p {
  font-size: 1rem;
  color: var(--color-light-gray);
  line-height: 1.8;
  font-style: italic;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

.testimonial-author {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-gold);
}

.testimonial-role {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* --- CTA Section --- */
.cta-section {
  text-align: center;
  padding: 120px 0;
  background: linear-gradient(135deg, var(--color-sage-bg) 0%, var(--color-sage-dark) 100%);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at center, rgba(179, 159, 104, 0.08) 0%, transparent 50%);
}

.cta-section h2 {
  font-size: 2.8rem;
  margin-bottom: 20px;
}

.cta-section p {
  font-size: 1.1rem;
  color: var(--color-text-muted-sage);
  max-width: 600px;
  margin: 0 auto 40px;
}

.cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.cta-section .btn-outline {
  border-color: var(--color-white);
  color: var(--color-white);
}

.cta-section .btn-outline:hover {
  background: var(--color-white);
  color: var(--color-navy);
}

.cta-section .btn-primary {
  background: var(--color-gold);
  color: var(--color-navy);
}

.cta-section .btn-primary:hover {
  background: var(--color-white);
  color: var(--color-navy);
}

/* --- Footer --- */
.main-footer {
  background: var(--color-navy-dark);
  padding: 80px 0 30px;
  border-top: 1px solid rgba(150, 172, 139, 0.15);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 50px;
  margin-bottom: 60px;
}

.footer-brand img {
  height: 60px;
  margin-bottom: 20px;
}

.footer-brand p {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: 20px;
}

.footer-heading {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--color-white);
  margin-bottom: 20px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  transition: var(--transition-smooth);
}

.footer-links a:hover {
  color: var(--color-gold);
  padding-left: 5px;
}

.footer-contact p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.footer-contact a {
  color: var(--color-gold);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 30px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.footer-legal-links {
  margin-top: 10px;
  font-size: 0.8rem;
}

.footer-legal-links a {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color 0.25s ease;
}

.footer-legal-links a:hover {
  color: var(--color-gold);
}

.footer-legal-sep {
  margin: 0 10px;
  opacity: 0.4;
}

/* --- Page Header (for sub-pages) --- */
.page-header {
  padding: 160px 0 80px;
  text-align: center;
  background: linear-gradient(180deg, var(--color-sage-bg) 0%, var(--color-navy) 100%);
  position: relative;
}

.page-header h1 {
  font-size: 3rem;
  margin-bottom: 16px;
}

.page-header p {
  font-size: 1.1rem;
  color: var(--color-text-muted-sage);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Location Detail --- */
.location-detail {
  padding: 80px 0;
}

.location-detail-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-bottom: 60px;
}

.location-detail-header h2 {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.location-detail-header p {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  line-height: 1.8;
}

.location-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.location-gallery img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  transition: var(--transition-smooth);
  cursor: pointer;
}

.location-gallery img:hover {
  transform: scale(1.03);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* --- Specialist Support --- */
.specialist-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.specialist-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 30px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  border: 1px solid rgba(150, 172, 139, 0.15);
  transition: var(--transition-smooth);
}

.specialist-item:hover {
  background: var(--color-navy);
  border-color: rgba(179, 159, 104, 0.5);
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.2);
}

.specialist-icon {
  flex-shrink: 0;
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--color-sage), var(--color-gold));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.specialist-icon svg {
  width: 24px;
  height: 24px;
  fill: var(--color-white);
}

.specialist-item h4 {
  font-size: 1.1rem;
  margin-bottom: 6px;
  color: var(--color-white);
  font-family: var(--font-heading);
}

.specialist-item p {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* --- Forms --- */
.form-group {
  margin-bottom: 24px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-sage-light);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.25);
  border-radius: 8px;
  color: var(--color-white);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: var(--transition-smooth);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(179, 159, 104, 0.15);
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

.form-group select option {
  background: var(--color-navy);
  color: var(--color-white);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.referral-form-container {
  max-width: 800px;
  margin: 0 auto;
  background: var(--color-navy);
  border: 1px solid rgba(179, 159, 104, 0.3);
  border-radius: 16px;
  padding: 50px;
}

/* --- Blog Cards --- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.blog-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.2);
  border-radius: 12px;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.blog-card:hover {
  background: var(--color-navy);
  transform: translateY(-8px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  border-color: rgba(179, 159, 104, 0.5);
}

.blog-card-image {
  height: 220px;
  overflow: hidden;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.08);
}

.blog-card-content {
  padding: 28px;
}

.blog-card-date {
  font-size: 0.8rem;
  color: var(--color-sage-light);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.blog-card-content h3 {
  font-size: 1.2rem;
  margin-bottom: 12px;
  color: var(--color-white);
  font-family: var(--font-heading);
}

.blog-card-content p {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  line-height: 1.7;
}

/* --- Work With Us --- */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.benefit-item {
  text-align: center;
  padding: 40px 30px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  border: 1px solid rgba(150, 172, 139, 0.15);
  transition: var(--transition-smooth);
}

.benefit-item:hover {
  background: var(--color-navy);
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.2);
  border-color: rgba(179, 159, 104, 0.5);
}

.benefit-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, var(--color-sage), var(--color-gold));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.benefit-icon svg {
  width: 28px;
  height: 28px;
  fill: var(--color-white);
}

.benefit-item h4 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  color: var(--color-white);
  font-family: var(--font-heading);
}

.benefit-item p {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* --- Case Studies Filter --- */
.filter-tabs {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}

.filter-tab {
  padding: 10px 24px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(150, 172, 139, 0.25);
  border-radius: 30px;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.filter-tab:hover,
.filter-tab.active {
  background: var(--color-gold);
  color: var(--color-navy);
  border-color: var(--color-gold);
}

/* --- Divider --- */
.section-divider {
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-sage), var(--color-gold));
  margin: 0 auto 30px;
  border-radius: 2px;
}

/* --- Lightbox --- */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(28, 39, 56, 0.95);
  z-index: 10001;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 90%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
}

.lightbox-close {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 40px;
  height: 40px;
  background: none;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.lightbox-close:hover {
  border-color: var(--color-gold);
  color: var(--color-gold);
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  background: rgba(38, 51, 71, 0.6);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 50%;
  color: white;
  font-size: 1.4rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
  z-index: 10002;
  -webkit-user-select: none;
  user-select: none;
}

.lightbox-prev {
  left: 24px;
}

.lightbox-next {
  right: 24px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(38, 51, 71, 0.9);
  border-color: var(--color-gold);
  color: var(--color-gold);
}

.lightbox-counter {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  letter-spacing: 2px;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
  .feature-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .intro-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .location-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .location-detail-header {
    grid-template-columns: 1fr;
  }

  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 950px) {
  html {
    font-size: 15px;
  }

  .container {
    padding: 0 24px;
  }

  .section {
    padding: 80px 0;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(38, 51, 71, 0.98);
    flex-direction: column;
    padding: 20px 40px 30px;
    gap: 16px;
    border-top: 1px solid rgba(255,255,255,0.05);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .hero h1 {
    font-size: 2.4rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .feature-cards {
    grid-template-columns: 1fr;
  }

  .location-cards {
    grid-template-columns: 1fr;
  }

  .location-gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .testimonials-grid {
    grid-template-columns: 1fr;
  }

  .blog-grid {
    grid-template-columns: 1fr;
  }

  .benefits-grid {
    grid-template-columns: 1fr;
  }

  .specialist-grid {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .full-bleed {
    height: 50vh;
  }

  .full-bleed-content {
    left: 24px;
    bottom: 30px;
  }

  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }

  .opener-logo-container {
    width: 220px;
    height: 220px;
  }

  .opener-company-name {
    font-size: 1.5rem;
  }

  .referral-form-container {
    padding: 30px;
  }

  .philosophy-content blockquote {
    font-size: 1.3rem;
  }

  /* --- Mobile: transparent/sage panels → navy blue --- */
  .feature-card,
  .specialist-item,
  .testimonial-card,
  .location-card,
  .blog-card,
  .benefit-item,
  .filter-tab {
    background: var(--color-navy);
    border-color: rgba(179, 159, 104, 0.25);
  }

  .form-group input,
  .form-group textarea,
  .form-group select {
    background: var(--color-navy);
    border-color: rgba(179, 159, 104, 0.3);
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.8rem;
  }

  .section-title {
    font-size: 1.7rem;
  }

  .hero-logo {
    width: 140px;
  }

  .nav-inner {
    padding: 12px 20px;
  }

  .location-gallery {
    grid-template-columns: 1fr;
  }

  .lightbox-prev,
  .lightbox-next {
    width: 40px;
    height: 40px;
    font-size: 1.1rem;
  }

  .lightbox-prev {
    left: 12px;
  }

  .lightbox-next {
    right: 12px;
  }
}

/* Sage sections — mobile only: navy text with gold shimmer */
@media (max-width: 950px) {
  .section-sage .section-label {
    background: linear-gradient(
      90deg,
      #263347 0%,
      #263347 25%,
      #b39f68 40%,
      #f5e6a3 50%,
      #b39f68 60%,
      #263347 75%,
      #263347 100%
    );
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: sectionLabelShimmer 22s linear infinite;
  }
}
/* Fix bg1.png oversizing on mobile — use a smaller tiled repeat instead of cover */
@media (max-width: 950px) {
  .section-navy::before {
    background-size: 2000px auto;
    background-repeat: repeat;
  }

  .section-navy::after {
    -webkit-mask-size: 2000px auto;
    -webkit-mask-repeat: repeat;
    mask-size: 2000px auto;
    mask-repeat: repeat;
  }
}
