/* Main Content Sections */
main {
  padding-top: 30px;
}

.content-section {
  padding: 40px 30px; /* More padding */
  margin-bottom: 30px;
  background-color: var(--color-white);
  border-radius: 12px; /* More rounded corners */
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1); /* Softer, larger shadow */
}

.content-section.bg-image-section {
  background-size: cover;
  background-position: center;
  color: var(--color-white); /* Default text color for bg image sections */
  position: relative;
  z-index: 1;
}
.content-section.bg-image-section::before {
  /* Overlay for readability */
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5); /* Adjust opacity as needed */
  border-radius: 12px;
  z-index: -1;
}
.content-section.bg-image-section h2,
.content-section.bg-image-section p,
.content-section.bg-image-section li {
  color: var(--color-white); /* Ensure text is white on dark overlay */
}
.content-section.bg-image-section h2 {
  border-bottom-color: rgba(255, 255, 255, 0.5);
}
.content-section.bg-image-section ul li::before {
  color: var(--color-white); /* Make bullets white */
}

.content-section h2 {
  color: var(--color-blue);
  margin-top: 0;
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 3px solid var(--color-green);
  font-size: 2em;
  font-weight: 600;
}

.text-image-layout {
  display: flex;
  align-items: center;
  gap: 30px; /* Space between text and image */
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
}
.text-image-layout .text-content {
  flex: 1;
  min-width: 300px; /* Ensure text content has enough space */
}
.text-image-layout .image-content {
  flex: 1;
  min-width: 300px; /* Ensure image content has enough space */
  max-width: 500px; /* Limit image width */
}
.text-image-layout .image-content img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Specific section styling */
#quienes-somos .image-content img {
  border: 5px solid var(--color-green); /* Example border */
}

#valores ul {
  list-style: none;
  padding-left: 0;
  columns: 2; /* Display values in two columns if space allows */
  column-gap: 30px;
}

#valores ul li {
  margin-bottom: 12px;
  padding-left: 25px;
  position: relative;
  font-size: 1.1em;
}

#valores ul li::before {
  content: "\2714"; /* Checkmark */
  color: var(--color-green);
  position: absolute;
  left: 0;
  font-weight: bold;
  font-size: 1.1em;
}

#valores.bg-image-section {
  background-image: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)),
    url("/public/images/values-bg.jpg");
}

/* Photo Gallery */
.gallery-title h2 {
  /* Shared title style for gallery */
  text-align: center;
  color: var(--color-blue);
  margin-bottom: 30px;
  font-size: 2em;
  font-weight: 600;
  padding-bottom: 15px;
  border-bottom: 3px solid var(--color-green);
}
.photo-gallery {
  display: grid; /* Using grid for more complex layouts */
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.photo-gallery img {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover; /* Crop images to fit */
  border-radius: 10px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 4px solid var(--color-white);
}

.photo-gallery img:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 992px) {
  /* Tablet */
  .site-title h1 {
    font-size: 2.2em;
  }
  .site-title p {
    font-size: 1.1em;
  }
  .text-image-layout {
    flex-direction: column;
  }
  .text-image-layout .image-content {
    max-width: 100%; /* Allow image to take full width when stacked */
    margin-top: 20px;
  }
  #valores ul {
    columns: 1;
  }
}

@media (max-width: 768px) {
  /* Mobile */
  .hero-header {
    padding: 20px 0;
  }
  .hero-header .header-content {
    min-height: auto;
  }
  .site-title h1 {
    font-size: 1.8em;
  }
  .site-title p {
    font-size: 1em;
  }
  nav ul {
    flex-direction: column;
    align-items: center;
  }
  nav ul li {
    margin: 8px 0;
    width: 80%;
    max-width: 300px;
  }
  nav ul li a {
    display: block;
    text-align: center;
  }

  .content-section {
    padding: 30px 20px;
  }
  .content-section h2 {
    font-size: 1.7em;
  }
  .footer-columns {
    flex-direction: column;
    align-items: center;
  }
  .footer-column {
    text-align: center;
    min-width: unset;
    width: 90%;
  }
  .photo-gallery {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }
  .photo-gallery img {
    height: 200px;
  }
}

@media (max-width: 480px) {
  /* Small Mobile */
  .site-title h1 {
    font-size: 1.6em;
  }
  .site-title p {
    font-size: 0.9em;
  }
  .content-section h2 {
    font-size: 1.5em;
  }
  .logo-placeholder {
    width: 60px;
    height: 60px;
    font-size: 1em;
  }
  .photo-gallery {
    grid-template-columns: 1fr; /* Single column on very small screens */
  }
  .photo-gallery img {
    height: 180px;
  }
}
