nav a {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px auto;
  padding: 20px;
  width: 80%;
  height: 200px;
  overflow: hidden;
  position: relative;
  background: url('images/sample-image.jpg') center / cover no-repeat;
  font-size: calc(5vw + 5vh);
  text-decoration: none;
  color: white;
  transform: translateZ(0);
  transition: transform 0.5s ease;
  text-shadow: 4px 4px 8px rgba(0, 0, 0, 0.7); /* Add text shadow */
}

nav a::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0); /* Start with fully transparent background */
  transition: background 0.5s ease;
}

nav a:hover::before {
  background: rgba(0, 0, 0, 0.5); /* Darken the background on hover */
}

nav a:hover {
  transform: scale(1.1); /* Scale the image on hover */
}

nav a span {
  z-index: 1;
  transition: transform 0.5s ease;
}

nav a:hover span {
  transform: scale(1.2); /* Increase text scale on hover */
}

footer {
  background: #1c1c1c;
  color: #e0e0e0;
  padding: 20px;
  margin-top: 20px;
}

.image-container {
  width: 100%;
  height: 300px;
  background-size: cover;
  background-position: center;
  transition: background-image 1s ease-in-out;
}

#heroImages {
  position: relative;
  width: 100%;
  height: 300px; 
  background-size: cover;
  background-position: center;
  transition: background-image 1s ease-in-out;
}

#heroImages {
  padding: 50px 0;
}

#hero {
  position: relative;
  width: 100%;

  background-size: cover;
  background-position: center;
  overflow: hidden;
}

#heroImages::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4); /* Adds a subtle dark overlay for better text contrast */
  z-index: 1;
}

.hero-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  text-align: left;
  z-index: 2; /* Ensures text is above the overlay */
  font-family: 'Arial', sans-serif; /* Stylish and readable font */
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5); /* Soft shadow for better legibility */
  width: 90%; /* Ensures text doesn't span the full width of the hero for better readability */
}

.hero-text p {
  font-size: 2rem; /* Larger font size for impact */
  margin: 0.5rem 0; /* Space between lines */
  opacity: 0.85;
  transition: opacity 0.3s ease-in-out;
}

.hero-text p:hover {
  opacity: 1; /* Highlight text on hover for interactive feel */
}


@media (max-width: 768px) {
  nav a {
    width: 90%;
    height: 150px;
    font-size: calc(4vw + 4vh);
  }
}