/* about.css */

.hero-image {
  background-image: url('../images/meet-team.jpg');
  background-size: cover;
  background-position: center 15%;
  height: 60vh;
  width: 100%;
  position: relative;
  z-index: 1;
}

main {
  position: relative;
  z-index: 2;
  background-color: var(--faint-background);
  color: var(--gray);
}

/* Section Base Style */
section[class^="about-"] {
  padding: 4rem 1rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}

section .container {
  max-width: 1000px;
  margin: 0 auto;
}

/* Subsection Titles */
section h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: var(--dark);
  text-align: center;
  position: relative;
}

section h2::after {
  content: "";
  display: block;
  width: 80px;
  height: 3px;
  background: var(--dark);
  margin: 0.5rem auto 0;
}

/* Paragraphs */
section p {
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.centered {
  text-align: center;
}

/* Links */
section a {
  color: var(--dark);
  font-weight: 600;
  text-decoration: underline;
}

section a:hover {
  color: var(--dark);
}

/* Lists */
section ul {
  font-size: 1.4rem;
  padding-left: 1.5rem;
  margin-top: 1rem;
}

section li {
  margin-bottom: 0.75rem;
  line-height: 1.6;
}

/* Alternating Backgrounds for Contrast */
.about-who-we-are {
  background-color: var(--background);
}
.about-who-we-are h2 {
  font-size: 3rem;
}
.about-who-we-are h2::after {
  width: 100px;
}
.about-who-we-are p {
  font-size: 1.5rem;
}

.section-image {
  flex: 1;
  max-width: 600px;
  margin: 0 2rem;
  border-radius:10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.areas-image {
  max-width: 600px;
}

.about-seniors,
.about-services {
  background-color: var(--faint-background);
  border-left: 4px solid;
  border-image: linear-gradient(to bottom, var(--light-background), var(--dark), var(--light-background)) 1;
  margin: 10px 16px;
}

.about-areas,
.about-why-choose {
  background-color: var(--faint-background);
  border-right: 4px solid;
  border-image: linear-gradient(to bottom, var(--light-background), var(--dark), var(--light-background)) 1;
  margin: 10px 16px;
}

/* CTA Section */
.about-cta {
  background-color: var(--background);
  color: var(--gray);
  text-align: center;
}

.about-cta h2 {
  color: var(--dark);
}

.about-cta h2::after {
  background: var(--dark);
}

.about-cta a {
  color: var(--dark);
  font-weight: bold;
  text-decoration: none;
  border-bottom: 1px solid var(--dark);
}

.about-cta a:hover {
  color: var(--darker);
  border-color: var(--darker);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .about-hero h1 {
    font-size: 2rem;
  }

  section h2 {
    font-size: 1.5rem;
  }

  section p, section li {
    font-size: 1rem;
  }
}


/* --- Responsive Design --- */
@media (max-width: 1024px) {
  section[class^="about-"] {
    flex-direction: column;
    text-align: center;
  }

  .section-image {
    margin: 2rem 0;
  }

  section.about-seniors.centered{
    flex-direction: column-reverse;
  }
}

@media (max-width: 768px) {
  .hero-image {
    height: 30vh;
    background-position: center center;
  }

  .about-hero h1 {
    font-size: 2rem;
  }

  section h2 {
    font-size: 1.8rem;
  }

  section p,
  section li {
    font-size: 1rem;
  }

  section[class^="about-"] {
    padding: 2rem 1rem;
    border: none;
  }

  .section-image,
  .areas-image {
    width: 100%;
    height: auto;
    object-fit: cover;
    margin: 1rem 0;
    max-width: 500px;
  }
}

@media (max-width: 480px) {
  section h2 {
    font-size: 1.5rem;
  }

  section p,
  section li {
    font-size: 0.95rem;
  }

  section[class^="about-"] {
    padding: 1.5rem 0.5rem;
  }
}