/* Reset margin and padding */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Initial Section */
.intro-section {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh; /* Ensure it at least covers the full viewport height */
  padding: 20px;
  background: linear-gradient(135deg, #121212, #333); /* Dark gradient background */
  color: white;
  text-align: center;
}

/* Ensure content doesn't overflow on smaller screens */
.intro-content {
  max-width: 800px;
  width: 100%; /* Full width for smaller screens */
}

.headline {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.5rem;
  font-weight: bold;
  margin-bottom: 20px;
  line-height: 1.4;
}

.introduction {
  font-family: 'Arial', sans-serif;
  font-size: 1rem;
  margin-bottom: 20px;
  line-height: 1.6;
}

.highlights p {
  margin-bottom: 10px;
  font-size: 1rem;
  line-height: 1.5;
}

.highlights strong {
  color: #ff6f61; /* Pop of color */
}

.cta {
  margin-top: 20px;
}

.cta p {
  font-size: 1rem;
  margin-bottom: 10px;
}

.cta-button {
  display: inline-block;
  padding: 10px 20px;
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  color: white;
  background-color: #ff6f61;
  border: none;
  border-radius: 5px;
  text-decoration: none;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.cta-button:hover {
  background-color: #e05548;
  transform: scale(1.05); /* Subtle animation */
}

/* Grid Section */
.grid-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 50vh 50vh; /* Maintain 2x2 grid */
  width: 100%;
  overflow: hidden; /* Prevent extra scrollbars */
}

.grid-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.3s ease;
}

.grid-item:hover img {
  filter: brightness(70%);
}

.hover-text {
  position: absolute;
  color: white;
  font-size: 1.5rem;
  font-weight: bold;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.grid-item:hover .hover-text {
  opacity: 1;
}

/* Responsive Behavior */
@media (max-width: 600px), (max-height: 500px) {
  .intro-section {
    min-height: auto; /* Let the section expand beyond 100vh */
    padding: 40px 20px; /* Add padding for better spacing */
  }

  .headline {
    font-size: 2rem; /* Slightly smaller headline */
  }

  .introduction {
    font-size: 0.9rem;
  }

  .cta-button {
    font-size: 0.9rem;
    padding: 8px 16px;
  }

  .grid-container {
    grid-template-columns: 1fr; /* Single column layout */
    grid-template-rows: repeat(4, 50vh); /* Maintain consistent height */
    height: auto; /* Allow scrolling for additional rows */
  }
}

#main-content {
  opacity: 0; /* Initially hidden */
  transition: opacity 0.5s ease-in-out;
}

#main-content.visible {
  opacity: 1; /* Fully visible */
}
