/* ===== Global ===== */

/* Prevent browser hash scrolling */
html {
  scroll-behavior: auto !important;
}

/* Ensure all sections have proper scroll margin */
#home,
#services,
#testimonials,
#contact {
  scroll-margin-top: 130px;
}

#about {
  scroll-margin-top: 130px;
}

/* Re-enable smooth scroll after page load */
html.ready {
  scroll-behavior: smooth;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #25254d;
  --secondary: #e05e00;
  --secondarybg: #d9d8e5;
  --light: #2c429b;
  --dark: #07032d;
  --gray: #e2e5e7;
  --white: #ffff;
  --success: #198754;
  --stars: #ffb400;
  --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  --shadow2: 0 0 3px 3px rgba(37, 37, 77, 0.2);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: sans-serif;
  line-height: 1.6;
  color: var(--dark);
  background-color: #fff;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-display: swap;
}

main {
  flex: 1;
}

header {
  transition: transform 0.3s ease-in-out;
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
}

header.hidden {
  transform: translateY(-100%);
  box-shadow: none;
}

h1,
h2,
h3,
h4 {
  font-family: sans-serif;
  font-weight: 1000;
  line-height: 1.3;
  min-height: 1.2rem;
}

p {
  font-family: sans-serif;
  font-weight: 500;
  font-size: 1.4rem;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.section,
.section-blue {
  padding-top: 80px;
  padding-bottom: 100px;
  text-align: center;
}

.section-blue {
  background: var(--primary);
}

.section-blue .section-title h2 {
  color: var(--white);
}

.section-title {
  min-height: 120px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.section-title h2 {
  min-height: 2.2rem;
  display: inline-block;
  position: relative;
  color: var(--white);
  font-size: 2.2rem;
  padding: 15px;
}

.section-title h2 {
  position: relative;
}

.section-title p {
  padding: 15px 0;
  color: var(--white);
  min-height: 1.6rem;
}

.title-decoration {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  padding: 15px 0;
}

.decoration-hyphen:first-child {
  animation-delay: 0.2s;
}

.decoration-hyphen:last-child {
  animation-delay: 0.2s;
}

.decoration-hyphen {
  width: 0; /* Adjust length of the hyphen lines */
  height: 6px; /* Adjust thickness of the hyphen lines */
  background: var(--white);
  opacity: 1;
  /* REMOVE: animation: growLine 0.8s ease-out forwards; */
}

.decoration-text {
  font-family: "Imperial Script", cursive;
  font-weight: 400;
  font-style: normal;
  font-size: 2rem;
  color: var(--white);
  opacity: 0;
  /* REMOVE: animation: fadeIn 0.8s ease-out 0.4s forwards; */
}

/* Animation Trigger Class */
.title-decoration.animate-in .decoration-hyphen {
  animation: growLine 0.8s ease-out forwards;
}

.title-decoration.animate-in .decoration-text {
  animation: fadeIn 0.8s ease-out 0.4s forwards;
}

/* Re-apply the staggered delay for the hyphens *within* the animation state */
.title-decoration.animate-in .decoration-hyphen:first-child {
  animation-delay: 0.8s; /* Starts after a 0.2s delay */
}

.title-decoration.animate-in .decoration-hyphen:last-child {
  animation-delay: 0.8s; /* (0.2s from first-child + 0.4s text animation + 0.2s for sequential look) */
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

.section-blue .container p {
  color: var(--white);
}

.visually-hidden {
  display: none;
}

.container-home-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  text-align: center;
  position: relative;
  z-index: 2;
}

.home-logo {
  margin-bottom: 2rem;
  margin-bottom: 0.5rem;
}

.home-logo img {
  max-width: auto;
  height: 200px;
}

.home-other h1 {
  font-size: 3rem;
  line-height: 1.2;
  text-align: left;
  padding: 0.5rem 0;
}

.home-other p {
  padding-top: 4rem;
  padding-bottom: 4rem;
  opacity: 0.9;
  text-shadow: 1px 1px 3px rgba(37, 37, 77, 1);
}

.home-other {
  position: relative;
  height: 100vh;
  min-height: 500px;
  display: flex;
  align-items: center;
  color: white;
  overflow: hidden;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.section {
  background: var(--secondarybg);
}

video {
  max-width: 100%;
  height: auto;
}

/* ===== Header & Navigation ===== */

.mobile-header {
  display: none;
}

header {
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
}

header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: -1;
}

.main-header {
  height: 145px;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease-in-out;
  z-index: 1000;
}

.main-header {
  transition: transform 0.3s ease-in-out;
  transform: translateY(0);
}

.main-header.hidden {
  transform: translateY(-100%);
}

/* Grid Layout - Exactly like reference site */
.header-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  height: 130px; /* Total header height */
}

/* Column 1: Logo */
.logo {
  grid-column: 1;
  display: flex;
  align-items: center;
  height: 100%;
  padding-top: 20px;
}

.logo img {
  height: 100px;
  width: auto;
  transition: transform 0.3s ease;
}

.logo:hover img {
  transform: scale(1.05);
}

.logo-icon {
  color: var(--primary);
  font-size: 2.5rem;
}

.mobile-header {
  display: none;
}

/* Column 2: Split into rows */
.header-content {
  grid-column: 2;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding-top: 10px;
}

/* Row 1: Contact Section */
.contact-section-top {
  display: flex;
  padding-top: 30px;
  justify-content: flex-end;
  align-items: center;
  height: 50px;
}

.nav-contact {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 25px;
}

.nav-contact li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.contact-icon-top {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.contact-top {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
  font-size: 1.4rem;
  transition: color 0.3s ease;
  white-space: nowrap;
}

.contact-top:hover {
  color: var(--secondary);
}

.nav-contact li:hover .contact-icon-top {
  transform: scale(1.1);
}

/* Row 2: Navigation */

nav {
  padding-top: 25px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  height: 50px;
}

nav ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 3rem;
  font-size: 1.4rem;
}

nav ul li {
  position: relative;
}

nav ul li:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  gap: 10px;
}

nav ul li.active > a {
  color: var(--white);
}

nav ul li.active > a:after {
  width: 100% !important;
}

nav a {
  text-decoration: none;
  color: var(--dark);
  font-weight: 500;
  transition: color 0.3s;
  position: relative;
  transition: 0.5s;
}

nav a:hover {
  color: var(--primary);
}

nav a:after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--primary);
  transition: width 0.3s;
}

nav a:hover:after {
  width: 100%;
}

.dropdown-menu {
  flex-direction: column;
  position: absolute;
  top: 120%;
  left: auto;
  right: auto;
  width: auto;
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  min-width: 300px;
  border-radius: 5px;
  padding: 5px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 1000;
}

.dropdown-menu li {
  width: 100%;
}

.dropdown-menu a {
  display: block;
  padding: 1px 10px;
  color: var(--dark);
  transition: all 0.3s;
}

.dropdown-menu a:hover {
  background: var(--light);
  color: var(--white);
}

nav a.active {
  background: var(--primary);
  color: var(--white);
  padding: 1px 15px;
  border-radius: 5px;
  font-weight: 500;
  font-size: 1.4rem;
}

nav a.active:after {
  width: 100% !important;
  color: var(--white);
  background: var(--primary);
}

.dropdown-menu a.active {
  background: var(--light);
  color: var(--white);
}

.dropdown-menu a.active:after {
  display: none;
}

/* ===== Home  Section ===== */

.home h1 {
  font-size: 3rem;
  line-height: 1.2;
  text-align: left;
  padding: 1rem 0;
}

.home p {
  padding-top: 2rem;
  padding-bottom: 2rem;
  opacity: 0.9;
  max-width: 700px;
  text-shadow: 1px 1px 2px rgba(37, 37, 77, 1);
}

.home {
  position: relative;
  height: 100vh;
  min-height: 500px;
  display: flex;
  align-items: center;
  color: white;
  overflow: hidden;
  justify-content: center;
}

/* ===== Home Background Carousel ===== */
.bg-carousel {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  /* Prevent flash of white */
  background-color: var(--primary);
}

.bg-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
}

.bg-slide.active {
  opacity: 1;
}

.bg-slide::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    rgba(37, 37, 77, 0.1),
    rgba(37, 37, 77, 0.2),
    rgba(37, 37, 77, 0.3),
    rgba(37, 37, 77, 0.4),
    rgba(37, 37, 77, 0.5),
    rgba(37, 37, 77, 0.6),
    rgba(37, 37, 77, 0.7),
    rgba(37, 37, 77, 0.8),
    rgba(37, 37, 77, 0.9),
    rgba(37, 37, 77, 1)
  );
  z-index: 1;
}

/* Home Content */
.home-content {
  top: 70px;
  max-width: 850px;
  position: relative;
  z-index: 2;
}

.home-content h1 {
  font-size: 2.5rem;
  line-height: 1.2;
  text-align: center;
  margin-bottom: 4rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  margin-top: -4rem;
}

/* Slide animation for smooth right-to-left transition */
@keyframes slideIn {
  0% {
    transform: translateX(100%);
    opacity: 0;
  }
  100% {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOut {
  0% {
    transform: translateX(0);
    opacity: 1;
  }
  100% {
    transform: translateX(-100%);
    opacity: 0;
  }
}

/* Mobile adjustments */
@media (max-width: 768px) {
  /* Miniature Navbar State */
  .mobile-header.scrolled {
    height: 70px; /* Smaller height */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  }

  /* Logo in the Navbar (Hidden by default) */
  .mobile-logo img {
    opacity: 0;
    transform: translateY(-20px) scale(0.5); /* Start hidden and small */
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    max-height: 50px; /* Miniature size */
    width: auto;
  }

  /* Modern Entrance: Logo appears when scrolled */
  .mobile-header.scrolled .mobile-logo img {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  /* Home Section Logo */
  .home-logo img {
    transition: opacity 0.3s ease, transform 0.3s ease;
  }

  /* Hide Home Logo when it exits view to prevent duplicates */
  .home-logo.out-of-view img {
    opacity: 0;
    transform: scale(0.9);
  }

  /* Adjust the hamburger position for the smaller navbar */
  #mobile-menu-toggle {
    transition: top 0.4s ease;
  }

  .mobile-header.scrolled #mobile-menu-toggle {
    top: 50%;
    transform: translateY(-50%);
  }

  .decoration-text {
    font-size: 1.5rem;
  }

  .home::before {
    display: none; /* Remove the old background */
  }

  .bg-slide {
    background-position: center;
    background-size: contain;
    background: linear-gradient(
        to right,
        rgba(37, 37, 77, 1),
        rgba(37, 37, 77, 0.1)
      )
      no-repeat right 25% center/cover;
  }
}

.bg-slide:nth-child(3) {
  background-position: left;
}

.bg-slide:nth-child(4) {
  background-position: left;
}

.bg-slide:nth-child(6) {
  background-position: right;
}

.bg-slide:nth-child(7) {
  background-position: right;
}

.bg-slide:nth-child(8) {
  background-position: center;
}

.bg-slide:nth-child(9) {
  background-position: left;
}

.btn-callnow {
  display: inline-block;
  padding: 15px 35px;
  background: var(--secondary);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  font-weight: 600;
  font-size: 1.2rem;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  text-shadow: none;
}

.btn-callnow:hover {
  background: #c75200; /* Darker shade of your secondary color */
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(224, 94, 0, 0.4);
}

/* - Home & Services Carousel - */

/* Carousel base styles */
.home-carousel,
.service-carousel {
  width: 100%;
  overflow: hidden;
  position: absolute;
  left: 0;
  padding: 10px 0;
  white-space: nowrap;
  z-index: 10;
  background: var(--primary);
}

.values-carousel {
  width: 100%;
  overflow: hidden;
  position: absolute;
  left: 0;
  padding: 10px 0;
  white-space: nowrap;
  z-index: 10;
  background: var(--primary);
}

.home-carousel,
.service-carousel {
  bottom: 0;
}

.values-carousel {
  top: 0;
}

/* Carousel tracks */
.home-carousel-track,
.service-carousel-track,
.values-carousel-track {
  font-size: 1.1rem;
  display: flex;
  flex-direction: row;
  gap: 40px;
  width: max-content;
}

.home-carousel-track,
.service-carousel-track {
  animation: scroll 30s linear infinite;
}

.values-carousel-track {
  font-style: italic;
  animation: scroll 60s linear infinite;
}

/* Carousel items */
.home-carousel-item,
.service-carousel-item,
.values-carousel-item {
  flex: 0 0 auto;
  padding: 10px 30px;
  border-radius: 50px;
  backdrop-filter: blur(5px);
  white-space: nowrap;
}

.home-carousel-item,
.service-carousel-item,
.values-carousel-item {
  background: var(--primary);
  color: white;
}

/* Keyframe animation */
@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Pause on hover */
.home-carousel-container:hover .home-carousel-track,
.service-carousel-container:hover .service-carousel-track {
  animation-play-state: paused;
}

/* ===== Services Section ===== */

/* Services */

#services,
#contact {
  background: linear-gradient(
    to bottom,
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 1),
    rgba(37, 37, 77, 0.9),
    rgba(37, 37, 77, 0.8),
    rgba(37, 37, 77, 0.7),
    rgba(37, 37, 77, 0.6),
    rgba(37, 37, 77, 0.5),
    rgba(37, 37, 77, 0.4),
    rgba(37, 37, 77, 0.3),
    rgba(37, 37, 77, 0.2),
    rgba(37, 37, 77, 0.1),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.4),
    rgba(37, 37, 77, 0.2)
  );
}

#gallery,
#gallery-team {
  background: var(--primary);
}

.service-content h3 {
  color: var(--primary);
  padding-bottom: 20px;
}

.service-content p {
  margin-bottom: 20px;
  font-size: 1rem;
  flex-grow: 1;
}

.service-content {
  padding: 25px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

/* ===== SERVICES GRID & VIDEO HOVER ===== */

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  padding: 60px 0;
}

.service-card {
  display: block;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(37, 77, 77, 0.1);
  text-decoration: none;
  aspect-ratio: 4 / 3;
  background: #fff;
  cursor: pointer;
}

/* Image and Video Base Styles */
.service-img,
.service-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.4s ease, transform 0.5s ease;
  display: block;
}

/* Video Positioning */
.service-video {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  z-index: 2; /* Above image but below overlay */
}

/* Image should be below video */
.service-img {
  position: relative;
  z-index: 1;
}

.drain-cleaning .service-video .service-card:hover {
  opacity: 0;
}

/* Hover States - Video appears, image stays visible but fades */
.service-card:hover .service-video {
  opacity: 1;
}

/* SCENARIO A: If the card HAS a video inside, fade out image */
.service-card:has(.service-video):hover .service-img {
  opacity: 0;
}

/* SCENARIO B: If the card DOES NOT have a video, zoom the image */
.service-card:not(:has(.service-video)):hover .service-img {
  opacity: 1; /* Keep image visible */
  transform: scale(1.1); /* Zoom effect */
}

/* Blue Overlay - FIXED: Proper z-index and pointer-events */
.service-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--primary);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 3; /* Between video and content */
  pointer-events: none; /* CRITICAL: Allow hover events to pass through */
}

.service-card:hover::after {
  opacity: 0; /* Blue overlay on hover */
}

/* Content Overlay */
.service-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.25rem;
  color: #fff;
  z-index: 4; /* Above everything */
  background: linear-gradient(
    to top,
    rgba(37, 37, 77, 0.9) 0%,
    rgba(37, 37, 77, 0.7) 50%,
    transparent 100%
  );
  transform: translateY(calc(100% - 4.5rem));
  transition: transform 0.35s ease-out, background 0.35s ease-out;
  pointer-events: none; /* Allow clicks to pass through to video */
}

.service-card:hover .service-content {
  transform: translateY(0);
  background: linear-gradient(
    to bottom,
    rgba(37, 37, 77, 0),
    rgba(37, 37, 77, 0.5),
    rgba(37, 37, 77, 0.8),
    rgba(37, 37, 77, 1)
  );
}

/* Content Text Styles */
.service-content h3 {
  margin: 0 0 0.5rem 0;
  font-size: 1.25rem;
  color: #fff;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.service-content p {
  margin: 0;
  font-size: 0.9rem;
  color: #f0f0f0;
  line-height: 1.4;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.3s ease 0.1s, max-height 0.3s ease 0.1s;
}

.service-card:hover .service-content p {
  opacity: 1;
  max-height: 100px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .services-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .service-content {
    transform: translateY(0);
    background: rgba(37, 37, 77, 0.7);
  }

  .service-content p {
    opacity: 1;
    max-height: none;
  }

  /* On mobile, don't play videos automatically */
  .service-video {
    display: none;
  }
}

/* ===== Individual Service Pages ===== */

.hero-content {
  height: 60vh;
}

/* - Scroll Arrow - Services - */

.scroll-down {
  position: absolute;
  bottom: 100px;
  left: 49%;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}

.arrow {
  width: 40px;
  height: 40px;
  border-bottom: 3px solid var(--secondary);
  border-right: solid var(--secondary);
  transform: rotate(45deg);
  animation: bounce 2s infinite;
  opacity: 0.8;
  transition: all 0.3s ease;
}

.arrow:hover {
  opacity: 1;
  border-color: white;
}

/* - Services Gallery Grid - */

.gallery-grid-services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 0;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  height: 250px;
}

.gallery-item:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 0 5px 5px rgba(0, 0, 0, 0.05);
}

.gallery-item img {
  transition: transform 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
}

.gallery-item img {
  transition: transform 0.3s ease;
}

.water-heater img {
  width: 100%;
  object-fit: cover;
  object-position: top 25%;
}

/* - Services Individual Pages - */

#drain-cleaning::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("s/s/banner-drain-cleaning.webp") no-repeat center bottom/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#drain-inspection::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-drain-inspection.webp") no-repeat center bottom/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#water-heater::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-heater.webp") no-repeat center center/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#plumbing-repairs::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-repairs.webp") no-repeat center center/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#sewer-jetting::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-jetting.webp") no-repeat center center/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#maintenance::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-maintenance.webp") no-repeat center top/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#milling::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-milling.webp") no-repeat center top/cover;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

#excavation::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to left,
      rgb(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.9)
    ),
    url("/images/banner-excavation.webp") no-repeat center 45%;
  z-index: -1;
  animation: background-motion 5s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 50%;
}

/* ===== About Section ===== */

.about-us-section-title h2 {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.about-content h4 {
  font-size: 1.5rem;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  color: var(--white);
}

.about-content p {
  text-align: left;
}

.about-features {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  padding-top: 50px;
}

.feature-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0.5rem;
}

.feature-item h4 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.5rem;
  margin-top: 1rem;
  margin-bottom: 0.5rem;
  color: var(--white);
  width: 100%;
  line-height: 1.2;
}

.video-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 45px 0;
  align-self: center;
  max-width: 1000px;
}

#CDSVideo {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

.about-icons {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  margin: 0;
  padding: 0;
}

.feature-item p {
  text-align: left;
  font-size: 1.3rem;
  margin-top: 0.5rem;
  /* No padding needed since icon and heading are on same line */
}

.payment-methods {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 15px;
  margin-top: 20px;
  margin-bottom: 50px;
}

.payment-methods img {
  width: auto;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.payment-methods img:hover {
  opacity: 1;
}

#visa {
  height: 30px;
}

#mastercard {
  height: 60px;
}

#interact {
  height: 40px;
}

.btn-more-about-us {
  padding: 10px 20px;
  font-size: 1.2rem;
  background: var(--secondary);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  font-weight: 500;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-align: center;
  box-shadow: var(--shadow);
}

.btn-more-about-us:hover {
  background: var(--success);
  color: white;
  transform: translateY(-3px);
}

/* ===== Reviews section ===== */

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.section.reviews {
  padding: 60px 0;
  min-height: 400px;
}

#google-reviews {
  padding-top: 45px;
  min-height: 400px;
}

#testimonials {
  min-height: 600px;
  position: relative;
}

/* - Review Cards Information - */

.review-avatar {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--gray);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 32px;
  flex-shrink: 0;
}

review-avatar-icon {
  width: 5px;
  height: 5px;
}

.review-author-info {
  display: flex;
  align-items: center;
  gap: 15px;
  min-height: 60px;
}

.review-name-date {
  display: flex;
  flex-direction: column;
}

.review-author {
  font-weight: bold;
  color: var(--primary);
  font-size: large;
}

.review-date {
  color: #777;
  font-size: 1rem;
  margin-top: 3px;
}

.review-source {
  width: 50px;
  height: 50px;
}

.google-icon {
  width: 50px;
  height: 50px;
  aspect-ratio: 1;
}

.review-stars {
  margin-bottom: 10px;
  color: var(--stars);
}

.review-text {
  font-size: medium;
  text-align: justify;
  line-height: 1.4;
  color: #333;
}

/* - Reviews Carousel Section - */

.reviews-skeleton {
  display: none;
}

.reviews-loading .reviews-skeleton {
  display: block;
}

.reviews-loading .reviews-carousel {
  display: none;
}

.skeleton-card {
  background: #f0f0f0;
  border-radius: 8px;
  padding: 20px;
  min-height: 200px;
  animation: pulse 1.5s ease-in-out infinite;
}

.reviews-carousel-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  max-width: 1200px;
  min-height: 300px;
  margin: 0 auto;
}

.reviews-carousel {
  display: flex;
  transition: transform 0.5s ease;
  will-change: transform;
}

.review-card {
  flex: 0 0 calc(33.333% - 20px);
  margin: 0 10px;
  box-sizing: border-box;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 20px;
  min-height: 200px;
  opacity: 1;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.review-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.review-date {
  color: #999;
  font-size: 13px;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--gray);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 20px;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-arrow.prev {
  left: -30px;
}

.carousel-arrow.next {
  right: -30px;
}

.carousel-arrow:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* ===== Contact Section ===== */

.payment-methods-mobile {
  display: none;
}

.contact {
  font-size: 1.1rem;
  background: var(--white);
}

.contact-item h4 {
  font-size: 1.2rem;
  color: var(--dark);
  text-align: start;
}

.contact-item p {
  color: var(--primary);
  text-align: left;
  font-size: 1.1rem;
  padding-top: 5px;
}

.contact-item a {
  text-decoration: none;
  color: var(--primary);
  text-align: left;
  font-size: 1.1rem;
  padding-top: 5px;
}

.section-blue .container .contact-info p {
  font-size: 1.1rem;
  color: var(--primary);
  text-align: start;
}

#emergency-text {
  color: var(--secondary);
  font-size: medium;
  padding: 20px 0px;
  font-weight: bold;
  font-size: 1.2rem;
}

.contact-grid {
  padding-top: 45px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.contact-item {
  display: flex;
  gap: 15px;
  color: var(--primary);
  print-color-adjust: var(--primary);
  background: white;
  box-shadow: var(--shadow2);
  padding: 20px;
  border-radius: 8px;
  transition: transform 0.3s;
}

.contact-item:hover {
  transform: translateY(-5px);
}

.contact-icon {
  font-size: 1.8rem;
  color: var(--primary);
  min-width: 40px;
}

/* - Contact Form - */

.form-group {
  font-size: 1.1rem;
}

.contact-form-layout {
  background: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: var(--shadow2);
}

.contact-form-layout h3 {
  font-size: 1.3rem;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  text-align: start;
  margin-bottom: 8px;
  font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--primary);
  outline: none;
}

.form-group textarea {
  height: 150px;
  resize: vertical;
}

.error-message {
  color: #dc3545;
  font-size: 0.8rem;
  margin-top: 5px;
}

input.error,
textarea.error,
select.error {
  border-color: #dc3545 !important;
}

/* - Form Messages - */
.form-message {
  display: none;
  margin-top: 15px;
  padding: 10px;
  border-radius: 5px;
}

.form-message.success {
  background: #d4edda;
  color: var(--success);
}

.form-message.error {
  background: #f8d7da;
  color: #721c24;
}

.is-loading {
  pointer-events: none;
  opacity: 0.8;
}

.is-loading #submitText {
  visibility: hidden;
}

.is-loading .spinner {
  display: inline-block;
}

.btn-form {
  display: inline-block;
  padding: 12px 30px;
  background: var(--primary);
  color: white;
  text-decoration: none;
  border-radius: 5px;
  font-weight: 500;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-align: center;
  font-size: 1.1rem;
}

.btn-form:hover {
  background: var(--secondary);
  color: white;
  transform: translateY(-3px);
}

/* ===== Our Team Page ===== */

#our-team::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
      to bottom,
      rgba(37, 37, 77, 0.1),
      rgba(37, 37, 77, 0.2),
      rgba(37, 37, 77, 0.3),
      rgba(37, 37, 77, 0.4),
      rgba(37, 37, 77, 0.5),
      rgba(37, 37, 77, 0.6),
      rgba(37, 37, 77, 0.7),
      rgba(37, 37, 77, 0.8),
      rgba(37, 37, 77, 0.85),
      rgba(37, 37, 77, 0.9),
      rgba(37, 37, 77, 0.95),
      rgba(37, 37, 77, 1)
    ),
    url("/images/team-CDS.webp") no-repeat top/cover;
  z-index: -1;
  background-position: top 100%;
  animation: background-motion 10s linear infinite alternate; /* 20s duration, linear, infinite, reverses direction */
  transform-origin: 50% 100%;
}

#our-team h1 {
  color: var(--primary);
  text-shadow: var(--white) 1px 1px;
}

#our-team p {
  color: var(--white);
  padding-top: 5px;
}

.our-team-gallery {
  padding-top: 60px;
  padding-bottom: 60px;
}

.our-team-details {
  padding: 60px 0;
  text-align: center;
}

.our-team-details p {
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.1rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 50px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 0;
}

.team-card {
  background: linear-gradient(
    to bottom,

    rgba(217, 216, 229, 0.1),
    rgba(217, 216, 229, 0.2),
    rgba(217, 216, 229, 0.3),
    rgba(217, 216, 229, 0.4),
    rgba(217, 216, 229, 0.5),
    rgba(217, 216, 229, 0.6),
    rgba(217, 216, 229, 0.7),
    rgba(217, 216, 229, 0.8),
    rgba(217, 216, 229, 0.9),
    rgba(217, 216, 229, 1)
  );
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 400px;
}

.team-card:hover {
  transform: translateY(-5px);
}

.team-card:hover p {
  color: var(--secondary);
}

.team-card:hover .certifications {
  color: var(--success);
  font-size: large;
}

.team-card:hover h3 {
  color: var(--primary);
}

.team-img-container {
  height: 250px;
  overflow: hidden;
}

.team-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s ease;
}

.team-card:hover img {
  transform: scale(1.05);
}

/* In main.css, find the section for gallery-team or add this block: */

/* ===== Team Card Animations ===== */

/* Initial hidden state for all team cards */
.gallery-grid .team-card {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* When the parent section is in view, apply the final state */
#gallery-team.in-view .gallery-grid .team-card {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Apply staggered delays using nth-child */
#gallery-team.in-view .gallery-grid .team-card:nth-child(1) {
  transition-delay: 0.1s;
}

#gallery-team.in-view .gallery-grid .team-card:nth-child(2) {
  transition-delay: 0.2s;
}

#gallery-team.in-view .gallery-grid .team-card:nth-child(3) {
  transition-delay: 0.3s;
}

#gallery-team.in-view .gallery-grid .team-card:nth-child(4) {
  transition-delay: 0.4s;
}

#gallery-team.in-view .gallery-grid .team-card:nth-child(5) {
  transition-delay: 0.5s;
}

#gallery-team.in-view .gallery-grid .team-card:nth-child(6) {
  transition-delay: 0.6s;
}
/* Add more :nth-child rules as needed for all your cards */

.team-info {
  padding: 10px;
  text-align: center;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.team-info h3 {
  color: var(--secondary);
  margin-bottom: 5px;
  font-size: 1.3rem;
}

.position {
  color: var(--primary);
  font-weight: bold;
  margin-bottom: 10px;
}

.certifications {
  color: var(--secondary);
  font-size: 1rem;
  font-style: italic;
  font-weight: bold;
  padding-bottom: 20px;
}

/* ===== Footer ===== */

footer {
  background-color: var(--primary);
  background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.1),
      rgba(255, 255, 255, 1),
      rgba(255, 255, 255, 1)
    ),
    url("/images/footer.webp") no-repeat center center/cover;
  background-size: cover;
  background-blend-mode: var(--dark);
  background-position: center;
  background-repeat: no-repeat;
  background-blend-mode: color;
  position: relative;
}

.footer {
  background: var(--dark);
  color: white;
}

.footer-links-mobile {
  display: none;
}

/* Footer Services List */
.footer-services-list {
  margin-top: 15px;
}

.footer-services-list ul {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.footer-services-list a {
  color: var(--white);
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.3s;
}

.footer-services-list a:hover {
  color: var(--secondary);
}

.footer-content p {
  font-size: 1rem;
  color: white;
  text-align: justify;
  padding: 15px 0;
}

.social-icons-footer {
  display: flex;
  justify-content: center;
  gap: 15px;
}

.social-icons-footer img {
  width: 50px;
  height: 50px;
  aspect-ratio: 1;
  transition: all 0.3s ease;
  border-radius: 10%;
}

.fb-icon img {
  width: 45px;
  height: 45px;
  aspect-ratio: 1;
  transition: all 0.3s ease;
}

.li-icon img {
  width: 45px;
  height: 45px;
  aspect-ratio: 1;
  transition: all 0.3s ease;
}

.social-icons-footer a:hover img {
  transform: translateY(-2px);
}

.social-icons-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 40px;
  color: white;
  padding-top: 30px;
}

.footer-content-mobile {
  display: none;
}

.footer-logo {
  display: flex;
  justify-content: left;
  width: 100%;
  line-height: 0;
}

.footer-logo img {
  max-width: 100%;
  height: auto;
}

.footer-links {
  text-align: center;
  padding-top: 15px;
}

.footer-links h3 {
  font-size: 1.8rem;
  color: var(--secondary);
  margin-bottom: 30px;
  position: relative;
  border-bottom: var(--secondary);
}

.footer-links li {
  display: flex;
  flex-direction: column;
  text-align: center;
  margin-bottom: 8px;
  color: var(--white);
}

.footer-links ul li {
  color: var(--white) !important;
}

.footer-links i {
  color: var(--primary);
  width: 20px;
}

.footer-links a {
  color: var(--white);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-links a:hover {
  color: var(--secondary);
  transform: translateY(-1px);
}

/* Contact Items in Footer */
.footer-links .contact-item-footer {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  text-align: left;
}

.footer-links .contact-icon {
  align-self: flex-end;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-bottom: 4px;
  padding-left: 20px;
}

/* Footer Legal Links Styles */
.footer-legal-links {
  text-align: center;
  padding: 15px 0;
}

.footer-legal-links a {
  color: var(--white);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
  padding: 0 10px;
}

.footer-legal-links a:hover {
  color: var(--secondary);
}

.pipe-separator {
  color: var(--white);
  opacity: 0.7;
  padding: 0 5px;
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .footer-legal-links {
    padding: 12px 0;
    margin-bottom: 15px;
  }

  .footer-legal-links a {
    font-size: 0.85rem;
    padding: 0 8px;
  }
}

/* Footer Badges */
.footer-badges {
  margin-top: 20px;
  text-align: left;
}

.badge-images {
  padding: 0 20px;
  display: flex;
  justify-content: center;
  gap: 20px;
}

.badge-images img {
  left: 0;
  border-radius: 10%;
  height: 60px;
  width: auto;
  opacity: 0.9;
  transition: opacity 0.3s ease;
}

.white-background {
  background: white;
  padding: 10px;
}

.badge-images img:hover {
  opacity: 1;
}

#BSDI-logo {
  height: 100px;
  width: auto;
}

#radiodection-logo {
  align-items: center;
  align-self: center;
}

.badge-images2 {
  gap: 0;
}

.copyright {
  padding-top: 15px;
  padding-bottom: 30px;
  border-top: 1px solid var(--gray);
  color: var(--white);
}

.copyright p {
  text-align: center;
  font-size: 0.8rem;
}

.footer-links h3:after {
  background: var(--secondary);
  width: 60px;
  transform: none;
}

.copyright-img {
  width: 15px;
  height: 15px;
  color: var(--white);
}

/* ===== Animations ===== */

@keyframes ring {
  0%,
  100% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(-1deg);
  }
  75% {
    transform: rotate(1deg);
  }
}

@keyframes fadeInOut {
  0%,
  100% {
    opacity: 0.6;
  }
  50% {
    opacity: 0.9;
  }
}

@keyframes bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0) rotate(45deg);
  }
  40% {
    transform: translateY(-20px) rotate(45deg);
  }
  60% {
    transform: translateY(-10px) rotate(45deg);
  }
}

@keyframes text-bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-20px);
  }
  60% {
    transform: translateY(-10px);
  }
}

@keyframes background-motion {
  0% {
    transform: scale(1) translateY(0);
    transform-origin: 50% 16%;
  }
  100% {
    transform: scale(1.05) translateY(0);
    transform-origin: 50% 16%;
  }
}

@keyframes growLine {
  0% {
    width: 0; /* Start invisible (no width) */
  }
  100% {
    width: 100px; /* Full width */
  }
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ===== Phones & Tablets ===== */

@media (max-width: 768px) {
  /* ===== Navbar ===== */

  .badge-images img {
    height: 50px;
  }

  #BSDI-logo {
    height: 90px;
    width: auto;
  }

  .container {
    padding: 30px;
  }

  .top-bar-content {
    justify-content: center;
    align-items: center;
  }

  .logo-nav-mobile {
    display: block;
    height: 105px;
    width: auto;
  }

  .mobile-header {
    display: flex !important;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  }

  #mobile-menu-toggle {
    position: absolute;
    width: 50px;
    height: 20px;
    top: 40%;
    left: 40px;
    z-index: 1001;
    border: none;
    background: transparent;
    cursor: pointer;
  }

  .dropdown-toggle::after {
    content: "";
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid #000; /* Change color as needed */
    transition: transform 0.3s ease;
  }

  #mobile-menu-toggle span {
    display: block;
    position: absolute;
    height: 4px;
    width: 100%;
    background: var(--primary);
    border-radius: 5px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: 0.25s ease-in-out;
  }

  #mobile-menu-toggle span:nth-child(1) {
    top: 0px;
  }

  #mobile-menu-toggle span:nth-child(2) {
    top: 7px;
  }

  #mobile-menu-toggle span:nth-child(3) {
    top: 14px;
  }

  #mobile-menu-toggle.open span:nth-child(1) {
    top: 7px;
    transform: rotate(135deg);
  }

  #mobile-menu-toggle.open span:nth-child(2) {
    opacity: 0;
    left: -60px;
  }

  #mobile-menu-toggle.open span:nth-child(3) {
    top: 7px;
    transform: rotate(-135deg);
  }

  #mobile-nav-panel {
    list-style: none;
    position: fixed;
    top: 0;
    left: -100%;
    right: auto;
    width: 70%;
    max-width: 400px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 999;
    padding: 80px 30px 30px;
    transition: left 0.3s ease-in-out;
    overflow-y: auto;
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.1);
  }

  #mobile-nav-panel.open {
    left: 0;
  }

  #mobile-nav-panel img {
    justify-content: center;
  }

  .mobile-header a {
    text-decoration: none;
  }

  #mobile-nav-panel h2 {
    color: var(--primary);
    margin-bottom: 30px;
    text-align: center;
    font-size: 1.5rem;
    position: relative;
  }

  #mobile-nav-panel h2:after {
    content: "";
    position: absolute;
    width: 60px;
    height: 3px;
    background: var(--secondary);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0;
  }

  #mobile-nav-panel ul {
    list-style: none;
    text-decoration: none;
  }

  #mobile-nav-panel li {
    padding: 20px 0;
    list-style: none;
    text-decoration: none;
  }

  #mobile-nav-panel a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    display: block;
    transition: color 0.3s;
  }

  #mobile-nav-panel a:hover {
    color: var(--secondary);
  }

  .mobile-dropdown-menu {
    padding-left: 20px;
    margin-top: 10px;
    display: none;
  }

  .mobile-dropdown-menu.active {
    display: block;
  }

  .mobile-dropdown-menu li {
    border-bottom: none !important;
    margin-bottom: 8px !important;
    padding-bottom: 0 !important;
  }

  .mobile-dropdown-menu a {
    font-size: 1rem !important;
    color: var(--dark);
    position: relative;
    padding-left: 15px;
  }

  .dropdown-toggle {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .dropdown-toggle.active:after {
    transform: rotate(180deg);
  }

  .mobile-contact {
    text-align: center;
    padding: 20px;
  }

  .mobile-contact a {
    display: block;
    font-size: 1.2rem;
    color: var(--primary);
    font-weight: 600;
  }

  .mobile-contact a i {
    margin-right: 10px;
    color: var(--primary);
    font-size: 1.5rem;
  }

  .mobile-social {
    display: flex;
    justify-content: center;
    gap: 15px;
  }

  .mobile-social a {
    width: 40px;
    height: 40px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
  }

  .mobile-social a:hover {
    transform: translateY(-3px);
  }

  .hours-of-operation-mobile {
    padding-top: 20px;
    border-top: 1px solid rgba(37, 37, 77, 0.1); /* Keep the visual divider */
    text-align: center;
  }

  .hours-of-operation-mobile p {
    color: var(--primary);
    font-size: 1rem;
    line-height: 1.4;
    margin: 10px 0;
    text-align: center;
  }

  .hours-of-operation-mobile strong {
    font-weight: 600;
  }

  #mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
  }

  #mobile-overlay.open {
    opacity: 1;
    visibility: visible;
  }

  .mobile-logo {
    display: flex;
    align-items: center;
    padding: 40px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: relative;
    width: 100%;
    z-index: 997;
    height: 110px;
    justify-content: flex-end;
  }

  .mobile-logo img {
    height: 90px;
  }

  .mobile-logo-text {
    display: none;
  }

  /* ===== Global ===== */

  .main-header {
    display: none !important;
  }

  h1,
  .home-other h1 {
    font-size: 2rem;
  }

  .section,
  .section-blue {
    padding-top: 80px;
  }

  .section-title h2 {
    font-size: 1.5rem;
  }

  .home,
  .home-other {
    padding-top: 30px;
    padding-bottom: 0;
    height: auto;
    text-align: center;
  }

  p,
  .home p,
  .section-title p,
  .section p,
  .section-blue p,
  .home-other p {
    font-size: 1.1rem;
    text-align: left;
    text-shadow: rgba(0, 0, 0, 0.08);
  }

  /* Home Section */

  .home {
    height: 100vh;
    padding-top: 150px;
    padding-bottom: 120px;
  }

  .home-other {
    height: 100hv;
    padding-top: 150px;
    padding-bottom: 70px;
  }

  .home h1 {
    text-align: center;
    padding: 20px;
  }

  .btn-callnow {
    /*Services sections*/
    padding: 10px 20px;
    font-size: 1rem;
  }

  .home-carousel,
  .values-carousel,
  .service-carousel {
    width: 100%;
    max-height: 50px;
    overflow: hidden;
    position: absolute;
    bottom: 0;
    left: 0;
    background: var(--primary);
    padding: 2px 0;
    font-size: 0.8rem;
    white-space: nowrap;
    padding: 5px 0;
  }

  .home-carousel-track,
  .values-carousel-track,
  .service-carousel-track {
    gap: 5px;
  }

  /* Services Section */

  .scroll-down {
    bottom: 90px;
  }

  .scroll-text {
    color: solid var(--secondary);
    font-size: 0.9rem;
  }

  .arrow {
    width: 20px;
    height: 20px;
    border-bottom: 3px solid var(--secondary);
  }

  .services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .service-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.25rem;
    color: #fff;
    z-index: 2;
    background: linear-gradient(
      to top,
      rgba(37, 37, 77, 0.8) 10%,
      transparent 90%
    );
    transform: translateY(calc(100% - 6rem));
    transition: transform 0.35s ease-out;
    transform: translateY(0);
    background: rgba(37, 37, 77, 0.7);
  }

  .service-content h3 {
    padding: 0;
  }

  .service-content:hover {
    display: none;
  }

  /* About section */

  .feature-item {
    padding-top: 10px;
  }

  .about-content h4 {
    font-size: 1.1rem;
  }

  .about-features {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  #CDSVideo {
    max-width: 100%;
  }

  /* Team gallery */
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .payment-methods {
    padding-top: 20px;
  }

  .btn-more-about-us {
    padding: 5px 10px;
    font-size: 1rem;
  }

  /* Google Reviews  */

  /* --- IN main.css @media (max-width: 768px) --- */

  .reviews-carousel-wrapper {
    /* Ensure the wrapper hides the overflow */
    overflow: hidden;
    width: 100%;
    position: relative;
    padding: 0; /* Remove padding so cards can go edge-to-edge if needed */
  }

  .reviews-carousel {
    display: flex; /* Horizontal Layout */
    width: max-content; /* Allow it to grow */
    gap: 0; /* We will use margin on cards instead for better calculation control */
    padding: 20px 0; /* Space for shadows */
  }

  .review-card {
    /* "Peeking" Sizing */
    width: 40vw; /* Occupy 85% of the viewport width */
    max-width: 300px; /* Don't get too huge on tablets */
    flex-shrink: 0; /* Prevent squishing */

    margin: 0 10px; /* Gap between cards */

    /* Reset heights */
    height: auto;
    min-height: 250px;

    /* Visuals */
    background: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    opacity: 1; /* JS handles opacity, but default is visible */
    transition: transform 0.3s ease, opacity 0.3s ease;
  }

  .reviews-carousel-section {
    min-height: 400px;
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  .google-icon {
    width: 30px;
    height: 30px;
    aspect-ratio: 1;
  }

  .review-header {
    display: flex;
    align-items: flex-start;
    margin-bottom: 8px;
  }

  .review-author-info {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 35px;
  }

  .review-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--gray);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 16px;
    flex-shrink: 0;
  }

  .review-name-date {
    display: flex;
    flex-direction: column;
  }

  .review-author {
    font-weight: 600;
    color: var(--primary);
    font-size: 0.85rem;
    line-height: 1.2;
  }

  .review-date {
    color: #888;
    font-size: 0.75rem;
    margin-top: 2px;
  }

  .review-source {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
  }

  .review-stars {
    margin-bottom: 8px;
    color: var(--stars);
    font-size: 0.8rem;
  }

  .review-text {
    text-align: justify;
    min-height: inherit;
    line-height: 1.4;
    color: #444;
    font-size: 0.85rem;
    display: -webkit-box;
    -webkit-box-orient: vertical;
  }

  .all-reviews-link {
    padding-top: 0;
  }

  /* Carousel dots for mobile */
  .carousel-dots {
    display: flex;
    justify-content: center;
    margin-top: 15px;
    gap: 6px;
  }

  .carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ddd;
    cursor: pointer;
    transition: background 0.3s;
  }

  .carousel-dot.active {
    background: var(--primary);
  }

  .btn-reviews {
    padding: 5px 10px;
    font-size: 1rem;
  }

  /* Contact */

  .contact-item {
    display: none;
  }

  .contact-grid {
    padding-top: 0;
  }

  /* Footer */

  #footer .container {
    padding: 20px;
  }

  .footer-links {
    display: none;
  }

  .footer-logo img {
    height: 100px;
    width: auto;
  }

  .footer-logo {
    justify-content: flex-start;
  }
  .footer-content-mobile {
    display: block !important;
    width: 100%;
    max-width: 100%;
    margin: 20px 0;
  }

  .footer-links-mobile {
    display: block !important;
    width: 100%;
  }

  .footer-links-mobile h3 {
    display: block !important;
    color: white;
    margin-bottom: 15px;
    text-align: center;
    font-size: 1.2rem;
    border-bottom: 2px solid var(--secondary);
    padding-bottom: 8px;
  }

  .footer-links-mobile ul {
    list-style: none;
    padding: 0;
    margin: 0;
  }

  .footer-links-mobile li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 15px;
    gap: 12px;
    color: white;
    font-size: 0.9rem;
    line-height: 1.4;
  }

  .footer-links-mobile li img {
    width: 18px;
    height: 18px;
    filter: brightness(0) invert(1);
    flex-shrink: 0;
    margin-top: 2px;
  }

  .reviews-carousel-wrapper {
    padding: 0 10px;
  }

  .footer-links .contact-item-footer {
    gap: 8px;
  }

  .footer-links .contact-icon {
    width: 14px;
    height: 14px;
  }
}

@media (max-width: 480px) {
  h1,
  .home h1,
  .home-other h1 {
    font-size: 1.5rem;
  }

  .btn-form {
    font-size: 0.9rem;
    padding: 5px 10px;
  }

  p {
    font-size: 0.9rem;
  }
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
  100% {
    opacity: 1;
  }
}

/*new carousel*/
/* ===== Endless Carousel Styles ===== */

.reviews-carousel-container {
  width: 100%;
  overflow: hidden;
  position: relative;
}

.reviews-carousel-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== Enhanced Navbar Entrance Animations ===== */

/* ===== Enhanced Navbar Entrance Animations ===== */

/* Homepage Animations */
.container-home-logo {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  animation: fadeUpScale 1.2s ease-out 0.5s forwards;
}

.home-content h1 span {
  display: inline-block;
  opacity: 0;
  transform: translateY(100%);
  animation: slideUpFade 0.8s ease-out forwards;
}

.home-content h1 span:nth-child(1) {
  animation-delay: 1s;
}
.home-content h1 span:nth-child(2) {
  animation-delay: 1s;
}

.btn-callnow {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.8s ease-out 1s forwards, pulse 2s ease-in-out 3s infinite;
}

@keyframes fadeUpScale {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes slideUpFade {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

/* ===== Enhanced Navbar Entrance Animations - FIXED ===== */

/* Animate the inner content instead of the main header */
.main-header .header-grid {
  opacity: 0;
  transform: translateY(-20px);
  animation: navbarEntrance 0.8s ease-out 0.2s forwards;
}

/* Logo animation */
.logo img {
  opacity: 0;
  transform: scale(0.8);
  animation: logoReveal 1s ease-out 0.3s forwards;
}

/* Contact info animation */
.contact-section-top {
  opacity: 0;
  transform: translateY(-10px);
  animation: fadeInDown 0.6s ease-out 0.7s forwards;
}

/* Navigation items staggered entrance */
#nav-menu li {
  opacity: 0;
  transform: translateY(-10px);
  animation: navItemEntrance 0.6s ease-out forwards;
}

#nav-menu li:nth-child(1) {
  animation-delay: 0.8s;
}
#nav-menu li:nth-child(2) {
  animation-delay: 0.9s;
}
#nav-menu li:nth-child(3) {
  animation-delay: 1s;
}
#nav-menu li:nth-child(4) {
  animation-delay: 1.1s;
}
#nav-menu li:nth-child(5) {
  animation-delay: 1.2s;
}

/* Contact items animation */
.nav-contact li {
  opacity: 0;
  transform: translateX(10px);
  animation: slideInRight 0.5s ease-out forwards;
}

.nav-contact li:nth-child(1) {
  animation-delay: 0.6s;
}
.nav-contact li:nth-child(2) {
  animation-delay: 0.7s;
}

/* Keyframes - keep existing */
@keyframes navbarEntrance {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes logoReveal {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  70% {
    transform: scale(1.05);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes navItemEntrance {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ===== Scroll-Triggered Animations - Staggered ===== */

/* Initial hidden state */
#about .about-us-section-title,
#about .section-title p,
#about .video-container,
#about .btn-more-about-us {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease-out;
}

/* Feature items start hidden */
#about .feature-item {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

#about .feature-item:nth-child(1) {
  transform: translateX(-50px);
}

#about .feature-item:nth-child(2) {
  transform: translateX(50px);
}

/* Video scale animation */
#about .video-container {
  transform: scale(0.9);
}

/* When main section comes into view */
#about.in-view .about-us-section-title {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

#about.in-view .section-title p {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}

#about.in-view .video-container {
  opacity: 1;
  transform: scale(1);
  transition-delay: 0.5s;
}

#about.in-view .btn-more-about-us {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.7s;
}

/* When features come into view (later) */
#about.features-in-view .feature-item:nth-child(1) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.2s;
}

#about.features-in-view .feature-item:nth-child(2) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.4s;
}

/* ===== Services Section Enhanced Animations ===== */

#services .section-title h2,
#services .section-title p,
#services .title-decoration {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

#services .service-card {
  opacity: 0;
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Cards fade in from different directions for visual interest */
#services .service-card:nth-child(odd) {
  transform: translateX(-50px);
}

#services .service-card:nth-child(even) {
  transform: translateX(50px);
}

#services.in-view .section-title h2 {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

/* 2. The Decoration waits for the Heading */
#services.in-view .title-decoration {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.5s; /* This ensures it waits for the heading */
}

/* 3. The Paragraph follows the Decoration */
#services.in-view .section-title p {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.8s ease-out;
  transition-delay: 0.7s; /* Wait for Decoration */
}

#services.in-view .service-card {
  opacity: 1;
  transform: translateX(0);
}

/* Stagger the card animations */
#services.in-view .service-card:nth-child(1) {
  transition-delay: 0.5s;
}
#services.in-view .service-card:nth-child(2) {
  transition-delay: 0.6s;
}
#services.in-view .service-card:nth-child(3) {
  transition-delay: 0.7s;
}
#services.in-view .service-card:nth-child(4) {
  transition-delay: 0.8s;
}
#services.in-view .service-card:nth-child(5) {
  transition-delay: 0.9s;
}
#services.in-view .service-card:nth-child(6) {
  transition-delay: 1s;
}
#services.in-view .service-card:nth-child(7) {
  transition-delay: 1.1s;
}
#services.in-view .service-card:nth-child(8) {
  transition-delay: 1.2s;
}

#services.in-view .service-card:nth-child(9) {
  transition-delay: 1.2s;
}

/* ===== Testimonials Section Scroll Animations ===== */

/* Initial hidden state for static content */

#testimonials .section-title h2 {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease-out;
}

#testimonials .section-title p,
#testimonials .values-carousel {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Initial state for review cards */
#testimonials.in-view .review-card {
  transform: translateY(30px) scale(0.95);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* When testimonials section comes into view */
#testimonials.in-view .section-title h2 {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

#testimonials.in-view .section-title p {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}

#testimonials.in-view .values-carousel {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.5s;
}

/* Ensure the cards are visible too (since you animate them separately) */
#testimonials.in-view .review-card {
  opacity: 1 !important;
}

/* Carousel arrows animation */
#testimonials.in-view .carousel-arrow {
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.5s ease-out;
}

#testimonials.in-view .carousel-arrow.prev {
  opacity: 1;
  transform: scale(1);
  transition-delay: 0.9s;
}

#testimonials.in-view .carousel-arrow.next {
  opacity: 1;
  transform: scale(1);
  transition-delay: 1s;
}

/* Staggered review cards animation */
#testimonials.in-view .review-card:nth-child(1) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.1s;
}

#testimonials.in-view .review-card:nth-child(2) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.2s;
}

#testimonials.in-view .review-card:nth-child(3) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.3s;
}

#testimonials.in-view .review-card:nth-child(4) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.4s;
}

#testimonials.in-view .review-card:nth-child(5) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.5s;
}

#testimonials.in-view .review-card:nth-child(6) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.6s;
}

#testimonials.in-view .review-card:nth-child(7) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.7s;
}

#testimonials.in-view .review-card:nth-child(8) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.8s;
}

#testimonials.in-view .review-card:nth-child(9) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 1.9s;
}

/* All reviews link animation */
#testimonials.in-view .all-reviews-link {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 2s;
}

/* Enhanced hover effects for review cards */
#testimonials.in-view .review-card:hover {
  transform: translateY(-5px) scale(1.02);
  transition: all 0.3s ease;
}

/* Enhanced form focus animations */
#contact .form-group input,
#contact .form-group textarea,
#contact .form-group select {
  transition: all 0.3s ease;
}

#contact .form-group input:focus,
#contact .form-group textarea:focus,
#contact .form-group select:focus {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(37, 37, 77, 0.1);
}

/* Button loading state animation */
.btn-form.is-loading {
  position: relative;
  overflow: hidden;
}

.btn-form.is-loading:after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid transparent;
  border-top: 2px solid white;
  border-radius: 50%;
  animation: button-spin 0.8s linear infinite;
}

@keyframes button-spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* ===== Contact Section Scroll Animations ===== */

/* Initial hidden state for static content */
#contact .section-title h2,
#contact .section-title p,
#contact .contact-grid {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Contact info items */
#contact .contact-item {
  opacity: 0;
  transform: translateX(-30px);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Contact form layout */
#contact .contact-form-layout {
  opacity: 0;
  transform: translateX(30px) scale(0.95);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Form elements */
#contact .contact-form-layout h3,
#contact #emergency-text,
#contact .form-group,
#contact .btn-form {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Payment methods */
#contact .payment-methods img {
  opacity: 0;
  transform: scale(0.8);
  transition: all 0.4s ease-out;
}

/* When contact section comes into view */
#contact.in-view .section-title h2 {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.1s;
}

#contact.in-view .section-title p {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}

#contact.in-view .contact-grid {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.5s;
}

/* Contact info items staggered animation */
#contact.in-view .contact-item:nth-child(1) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.7s;
}

#contact.in-view .contact-item:nth-child(2) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.8s;
}

#contact.in-view .contact-item:nth-child(3) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 0.9s;
}

#contact.in-view .contact-item:nth-child(4) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 1s;
}

#contact.in-view .contact-item:nth-child(5) {
  opacity: 1;
  transform: translateX(0);
  transition-delay: 1.1s;
}

/* Contact form layout */
#contact.in-view .contact-form-layout {
  opacity: 1;
  transform: translateX(0) scale(1);
  transition-delay: 0.6s;
}

/* Form elements staggered animation */
#contact.in-view .contact-form-layout h3 {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.8s;
}

#contact.in-view #emergency-text {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.9s;
}

#contact.in-view .form-group:nth-child(1) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1s;
}

#contact.in-view .form-group:nth-child(2) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.1s;
}

#contact.in-view .form-group:nth-child(3) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.2s;
}

#contact.in-view .form-group:nth-child(4) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.3s;
}

#contact.in-view .form-group:nth-child(5) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.4s;
}

#contact.in-view .btn-form {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.6s;
}

/* Payment methods animation */
#contact.in-view .payment-methods img:nth-child(1) {
  opacity: 1;
  transform: scale(1);
  transition-delay: 1.2s;
}

#contact.in-view .payment-methods img:nth-child(2) {
  opacity: 1;
  transform: scale(1);
  transition-delay: 1.3s;
}

#contact.in-view .payment-methods img:nth-child(3) {
  opacity: 1;
  transform: scale(1);
  transition-delay: 1.4s;
}

/* Enhanced hover effects */
#contact.in-view .contact-item:hover {
  transform: translateX(5px);
  transition: all 0.3s ease;
}

#contact.in-view .btn-form:hover {
  transform: translateY(-3px);
  transition: all 0.3s ease;
}

/* ===== Page Transition Animations ===== */

@keyframes pageFadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Service Page Hero Animations ===== */

/* Hero section initial state */
.home-other .hero-content h1,
.home-other .hero-content p,
.home-other .btn-callnow,
.home-other .scroll-down {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Service carousel initial state */
.home-other .service-carousel {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease-out;
}

/* When page loads, animate hero content */
.page-loaded .home-other .hero-content h1 {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.3s;
}

.page-loaded .home-other .hero-content p {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.5s;
}

.page-loaded .home-other {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.7s;
}

.page-loaded .home-other .scroll-down {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.9s;
}

.page-loaded .home-other .service-carousel {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 1.1s;
}

/* ===== Gallery Section Animations ===== */

.gallery-grid-services .gallery-item {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(1) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.3s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(2) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.4s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(3) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.5s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(4) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.6s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(5) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.7s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(6) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.8s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(7) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.9s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(8) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.9s;
}

.page-loaded .gallery-grid-services .gallery-item:nth-child(9) {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition-delay: 0.9s;
}

/* Enhanced hover effects */
.page-loaded .gallery-item:hover {
  transform: translateY(-5px) scale(1.02);
  transition: all 0.3s ease;
}

/* Mobile optimizations for gallery */
@media (max-width: 768px) {
  .section,
  .section-blue {
    padding-top: 0;
  }

  #testimonials .section-blue {
    padding-top: 80px;
  }

  #gallery .gallery-item {
    transform: translateY(30px) scale(0.98);
  }

  #gallery.in-view .gallery-item {
    transform: translateY(0) scale(1);
  }

  /* Faster animations on mobile */
  #gallery .gallery-item,
  #gallery .gallery-item img {
    transition-duration: 0.5s;
  }

  /* Shorter delays on mobile */
  #gallery.in-view .gallery-item:nth-child(1) {
    transition-delay: 0.2s;
  }
  #gallery.in-view .gallery-item:nth-child(2) {
    transition-delay: 0.3s;
  }
  #gallery.in-view .gallery-item:nth-child(3) {
    transition-delay: 0.4s;
  }
  #gallery.in-view .gallery-item:nth-child(4) {
    transition-delay: 0.5s;
  }
  #gallery.in-view .gallery-item:nth-child(5) {
    transition-delay: 0.6s;
  }
  #gallery.in-view .gallery-item:nth-child(6) {
    transition-delay: 0.7s;
  }
  #gallery.in-view .gallery-item:nth-child(7) {
    transition-delay: 0.8s;
  }
  #gallery.in-view .gallery-item:nth-child(8) {
    transition-delay: 0.8s;
  }
  #gallery.in-view .gallery-item:nth-child(9) {
    transition-delay: 0.8s;
  }

  #gallery.in-view .gallery-item:nth-child(1) img {
    transition-delay: 0.3s;
  }
  #gallery.in-view .gallery-item:nth-child(2) img {
    transition-delay: 0.4s;
  }
  #gallery.in-view .gallery-item:nth-child(3) img {
    transition-delay: 0.5s;
  }
  #gallery.in-view .gallery-item:nth-child(4) img {
    transition-delay: 0.6s;
  }
  #gallery.in-view .gallery-item:nth-child(5) img {
    transition-delay: 0.7s;
  }
  #gallery.in-view .gallery-item:nth-child(6) img {
    transition-delay: 0.8s;
  }
  #gallery.in-view .gallery-item:nth-child(7) img {
    transition-delay: 0.9s;
  }
  #gallery.in-view .gallery-item:nth-child(8) img {
    transition-delay: 0.9s;
  }
  #gallery.in-view .gallery-item:nth-child(9) img {
    transition-delay: 0.9s;
  }
}

/* ===== Progressive Image Loading ===== */

.gallery-item {
  position: relative;
  overflow: hidden;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.5s ease;
}

/* Loading shimmer effect */
.gallery-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  transition: left 0.6s ease;
  z-index: 1;
}

.gallery-item.loaded::before {
  left: 100%;
}

/* Image zoom on hover */
.gallery-item:hover img {
  transform: scale(1.1);
}

/* Caption overlay on hover */
.gallery-item::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0;
  transition: height 0.3s ease;
  display: flex;
  align-items: flex-end;
  padding: 20px;
  color: white;
  font-weight: 500;
}

.gallery-item:hover::after {
  height: 60px;
}

/* Add to your CSS */
.navbar-animations-disabled .main-header .header-grid,
.navbar-animations-disabled .logo img,
.navbar-animations-disabled .contact-section-top,
.navbar-animations-disabled #nav-menu li,
.navbar-animations-disabled .nav-contact li {
  animation: none !important;
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
}

.container-policy {
  font-family: Arial, sans-serif;
  line-height: 1.7;
  color: var(--dark);
  background-color: var(--white);
  margin: 20px;
  padding: 0;
  max-width: 850px;
  margin: 0 auto;
  padding: 20px 30px;
  background-color: var(--white);
  box-shadow: var(--shadow);
}

/* Typography and Headings */
.container-policy h1 {
  color: var(--primary);
  border-bottom: 3px solid var(--secondary);
  padding-bottom: 15px;
  margin-bottom: 30px;
  font-size: 2.2em;
}
.container-policy h2 {
  color: var(--primary);
  margin-top: 35px;
  margin-bottom: 15px;
  font-size: 1.5em;
}
.container-policy p {
  margin-bottom: 20px;
}

/* Emphasis and Links */
.container-policy strong {
  color: var(--secondary);
}
.container-policy a {
  color: var(--light);
  text-decoration: none;
}
.container-policy a:hover {
  text-decoration: underline;
}

/* Hide logo when the mobile menu is toggled open */
#mobile-menu-toggle.open ~ .logo-and-text-wrapper,
#mobile-menu-toggle.open ~ .mobile-logo img,
.mobile-header:has(#mobile-menu-toggle.open) .mobile-logo img {
  opacity: 0 !important;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}

/* Optional: Center the toggle or adjust branding text if needed when logo is hidden */
.mobile-header:has(#mobile-menu-toggle.open) .mobile-logo-text {
  opacity: 0;
}
