/* Google Fonts Import */
@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;900&family=Open+Sans:wght@400;600;700&display=swap");

/* Base Styles */
body {
  font-family:
    "Open Sans",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background-color: #f9fafb;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Montserrat", sans-serif;
}

html {
  scroll-behavior: smooth;
}

/* Hero Section */
.hero-bg {
  /* Using Wideshot_Bestlandscape_Person.jpg for the hero background */
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.5)),
    url("../../hernandez_images/web_Wideshot_Bestlandscape_Person.jpeg");
  background-attachment: scroll; /* Creates the parallax effect on desktop */
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  min-height: 100vh;
}

/* Mobile optimization for hero background */
@media (max-width: 768px) {
  .hero-bg {
    background-image:
      linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.65)),
      url("../../hernandez_images/web_hero_mobile.jpg");
    background-attachment: scroll; /* Disable parallax on mobile for better performance */
    background-position: center center;
    background-size: cover;
    min-height: 100vh;
  }
}

@media (min-width: 1024px) {
  .hero-bg {
    background-attachment: fixed;
  }
}

/* Hero content block – dark backdrop so text stays readable */
.hero-content-backdrop {
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

/* Hero Text Shadow – strong contrast over photo background */
.hero-heading {
  text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.9),
    0 4px 16px rgba(0, 0, 0, 0.7),
    0 0 32px rgba(0, 0, 0, 0.4);
}
.hero-subtitle {
  text-shadow:
    0 1px 4px rgba(0, 0, 0, 0.95),
    0 2px 10px rgba(0, 0, 0, 0.7);
}
.hero-text-shadow {
  text-shadow:
    0 2px 8px rgba(0, 0, 0, 0.5),
    0 4px 16px rgba(0, 0, 0, 0.3);
}

/* Floating Animation */
@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
  100% {
    transform: translateY(0px);
  }
}
.floating {
  animation: float 3s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .floating {
    animation: none;
  }
}

/* Before/After Slider */
.before-after-container {
  position: relative;
  width: 100%;
  max-width: 600px;
  margin: 0 auto 2rem auto;
  overflow: hidden;
  border-radius: 0.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}
.before-after-slider {
  position: relative;
  width: 100%;
  height: 400px;
}
.before-after-slider img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.after-image {
  clip-path: polygon(50% 0, 100% 0, 100% 100%, 50% 100%);
}
.slider-handle {
  position: absolute;
  top: 0;
  left: 50%;
  width: 4px;
  height: 100%;
  background: white;
  cursor: ew-resize;
  transform: translateX(-50%);
  z-index: 10;
}
.slider-handle::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 40px;
  height: 40px;
  background: white;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Service Card Hover Effects */
.service-card {
  transition: all 0.3s ease;
}
.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Testimonial Slider */
.testimonial-slider {
  overflow: hidden;
}
.testimonial-track {
  display: flex;
  transition: transform 0.5s ease;
}
.testimonial-slide {
  min-width: 100%;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Loader */
.loader {
  border: 3px solid #f3f3f3;
  border-radius: 50%;
  border-top: 3px solid #22c55e;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Header Scrolled State */
.header-scrolled {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}
.modal-content {
  background-color: white;
  padding: 2rem;
  border-radius: 0.5rem;
  text-align: center;
  max-width: 90%;
  width: 400px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  position: relative;
}

/* Back to Top Button */
#backToTopBtn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background-color: #22c55e;
  color: white;
  padding: 1rem;
  border-radius: 50%;
  font-size: 1.5rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  cursor: pointer;
}
#backToTopBtn.show {
  opacity: 1;
  visibility: visible;
}

/* Reveal Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.6s ease-out,
    transform 0.6s ease-out;
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}
.reveal-left {
  opacity: 0;
  transform: translateX(-30px);
  transition:
    opacity 0.6s ease-out,
    transform 0.6s ease-out;
}
.reveal-left.active {
  opacity: 1;
  transform: translateX(0);
}
.reveal-right {
  opacity: 0;
  transform: translateX(30px);
  transition:
    opacity 0.6s ease-out,
    transform 0.6s ease-out;
}
.reveal-right.active {
  opacity: 1;
  transform: translateX(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal,
  .reveal-left,
  .reveal-right {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Trust Badge */
.trust-badge {
  transition: transform 0.2s ease;
}
.trust-badge:hover {
  transform: translateY(-2px);
}

/* Accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #22c55e;
  outline-offset: 2px;
}

/* Process Step */
.process-step {
  position: relative;
}
.process-step::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -2rem;
  width: 1.5rem;
  height: 2px;
  background: #22c55e;
}
.process-step:last-child::after {
  display: none;
}
@media (max-width: 768px) {
  .process-step::after {
    display: none;
  }
}
