/* about_contact.css */

/* Reset any conflicting styles */
#about,
#contact {
  font-family: "Poppins", sans-serif;
  position: relative; /* Crucial for z-index context */
  overflow: visible !important; /* To prevent clipping by .overflow-hidden class in HTML */
  padding: 100px 0;
  margin: 0;
  /* z-index: 1; /* Section itself forms a stacking context */
  /* Let each section define its z-index and background specifically */
}

/* ABOUT SECTION */
#about {
  position: relative; /* Establishes stacking context */
  z-index: 1; /* On top of default flow, below header */
  background-color: transparent; /* IMPORTANT: Allow its .diagonal-background to be visible */
  margin-bottom: 0px; /* Removed the margin-bottom: 50px; to allow natural flow or controlled spacing with #contact */
  /* If you need space, consider padding-bottom on #about or padding-top on #contact */
}

/* CONTACT SECTION */
#contact {
  position: relative; /* Establishes stacking context */
  z-index: 1; /* Same level as #about in terms of base stacking */
  background-color: #ffffff; /* Solid white background as per your previous styles */
  padding-bottom: 120px; /* Extra padding at bottom */
  /* margin-top: 0 !important; /* Ensure no negative margin pulling it up, handled by #about's margin-bottom or #contact's padding-top if needed */
}

/* DIAGONAL BACKGROUND (TARGETING ONLY #about's diagonal) */
/* To ensure this only applies to #about, you'd normally have it inside #about in HTML,
   or use a more specific selector if .diagonal-background is also used elsewhere.
   Assuming .diagonal-background is a direct child of #about as per index.php */
#about .diagonal-background {
  position: absolute;
  top: -50px;
  left: -5%;
  right: -5%;
  bottom: -50px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  transform: skewY(-3deg); /* Reduced angle */
  transform-origin: top left;
  z-index: 0; /* CORRECTED: Behind .container (z-index: 2) but in front of page body, within #about stacking context */
  pointer-events: none;
}

/* Container styles */
#about .container,
#contact .container {
  position: relative; /* Establishes stacking context for content within section */
  z-index: 2; /* Content is above the section's .diagonal-background (if any) or base background */
}

.about-title,
#about .section-heading,
#contact .section-heading {
  font-family: "Poppins", sans-serif;
  font-weight: 800;
  font-size: 2.5rem;
  background: linear-gradient(135deg, #2d6365 0%, #4c9fa2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  color: #3a7d7f;
  margin-bottom: 1.5rem;
  position: relative;
}

/* Section text */
.about-subtitle,
#about .section-text,
#contact .section-text {
  font-family: "Poppins", sans-serif;
  font-weight: 300;
  font-size: 1.2rem;
  color: #6c757d;
  max-width: 800px;
  margin: 0 auto 2rem;
  position: relative;
}

#about .badge,
#contact .badge {
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  background: linear-gradient(135deg, #4c9fa2, #45959b);
  padding: 0.7rem 2rem;
  border-radius: 30px;
  box-shadow: 0 4px 15px rgba(76, 159, 162, 0.2);
  border: none;
  color: white !important;
  display: inline-block;
  margin-bottom: 1rem;
  position: relative;
}

#about .card.hover-card,
#contact .card.hover-card,
.hover-card {
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  background: rgba(255, 255, 255, 0.95);
  border-radius: 15px;
  height: 100%;
  position: relative;
}

.hover-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1) !important;
}

/* Icon styles */
.icon-circle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: linear-gradient(135deg, #4c9fa2, #45959b);
  color: white;
  box-shadow: 0 8px 20px rgba(76, 159, 162, 0.2);
  transition: all 0.3s ease;
  flex-shrink: 0;
  position: relative;
}

/* Map container */
.map-container {
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.map-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Feature list */
.feature-list li {
  padding: 1rem 1.5rem;
  border-radius: 10px;
  transition: all 0.3s ease;
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
}

.feature-list li:hover {
  background: rgba(76, 159, 162, 0.08);
  transform: translateX(8px);
}

.feature-list .fa-check-circle {
  color: #4c9fa2;
  font-size: 1.4rem;
  margin-right: 1rem;
}

/* Value cards */
.value-card {
  background: linear-gradient(165deg, #ffffff 0%, #f8f9fa 100%);
  border-radius: 15px;
  padding: 2rem;
  height: 100%;
}

.value-card .icon-circle {
  margin: -3rem auto 1.5rem;
  width: 90px;
  height: 90px;
  font-size: 2.2rem;
}

/* Contact info card */
.contact-info-card,
.map-card {
  background: linear-gradient(165deg, #ffffff 0%, #f8f9fa 100%);
  border-radius: 20px;
  overflow: hidden;
  height: 100%;
}

/* Info items */
.info-item {
  padding: 1.2rem;
  border-radius: 12px;
  transition: all 0.3s ease;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
}

.info-item:hover {
  background: rgba(76, 159, 162, 0.08);
  transform: translateX(8px);
}

/* Social links */
.social-links .btn {
  width: 50px;
  height: 50px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  border-radius: 50%;
  font-size: 1.3rem;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  border: none;
}

.social-links .btn:hover {
  background: linear-gradient(135deg, #4c9fa2, #45959b);
  color: white;
  transform: translateY(-5px) scale(1.1);
  box-shadow: 0 8px 20px rgba(76, 159, 162, 0.2);
}

@media (max-width: 768px) {
  #about,
  #contact {
    padding: 60px 0;
  }

  .about-title,
  .section-heading {
    font-size: 2rem;
  }

  .about-subtitle,
  .section-text {
    font-size: 1.1rem;
  }

  .value-card .icon-circle {
    width: 70px;
    height: 70px;
    font-size: 1.8rem;
    margin: -2rem auto 1rem;
  }
}
