/* style/about.css */

/* Custom properties for colors */
:root {
  --primary-color: #26A9E0;
  --secondary-color: #FFFFFF;
  --login-color: #EA7C07;
  --background-color: #FFFFFF;
  --text-dark: #333333;
  --text-light: #ffffff;
  --border-color: #e0e0e0;
}

.page-about {
  font-family: 'Arial', sans-serif;
  color: var(--text-dark); /* Default text color for light body background */
  background-color: var(--background-color);
  line-height: 1.6;
}

/* Hero Section */
.page-about__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
  background: linear-gradient(135deg, var(--primary-color) 0%, #FFFFFF 100%);
  color: var(--text-light); /* Text on gradient background */
  overflow: hidden;
}

.page-about__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.page-about__hero-image {
  width: 100%;
  margin-bottom: 30px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.page-about__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  object-fit: cover;
}

.page-about__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.page-about__hero-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  font-weight: 700;
  color: var(--text-light);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-about__hero-description {
  font-size: 1.2em;
  max-width: 800px;
  margin: 0 auto 30px auto;
  color: var(--text-light);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

.page-about__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: var(--login-color); /* Using login color for CTA for prominence */
  color: var(--text-light);
  text-decoration: none;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  margin-top: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-about__cta-button:hover {
  background: #e06c00; /* Slightly darker orange */
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* General Section Styling */
.page-about__section {
  padding: 80px 20px;
  margin-bottom: 0;
  border-bottom: 1px solid var(--border-color);
}

.page-about__section:last-of-type {
  border-bottom: none;
}

.page-about__container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-about__section-title {
  font-size: 2.5em;
  font-weight: 700;
  text-align: center;
  margin-bottom: 50px;
  color: var(--primary-color);
  position: relative;
}

.page-about__section-title::after {
  content: '';
  display: block;
  width: 80px;
  height: 4px;
  background: var(--login-color);
  margin: 20px auto 0 auto;
  border-radius: 2px;
}

.page-about__sub-title {
  font-size: 1.8em;
  color: var(--primary-color);
  margin-top: 30px;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-about__text-block p {
  margin-bottom: 15px;
  font-size: 1.1em;
  line-height: 1.7;
}

.page-about__text-block strong {
  color: var(--primary-color);
}

/* Grid Layouts */
.page-about__content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.page-about__content-grid--reverse {
  grid-template-areas: "image text";
}

.page-about__content-grid--reverse .page-about__text-block {
  grid-area: text;
}

.page-about__content-grid--reverse .page-about__image-block {
  grid-area: image;
}

.page-about__grid-3-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-about__grid-2-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.page-about__image-block img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
  object-fit: cover;
}

/* Card Styling */
.page-about__card {
  background: var(--secondary-color);
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-dark); /* Ensure text is dark on light card background */
}

.page-about__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.page-about__card img {
  width: 100%;
  height: 250px; /* Fixed height for consistency in cards */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-about__card-title {
  font-size: 1.5em;
  font-weight: 600;
  color: var(--primary-color);
  margin-top: 15px;
  margin-bottom: 10px;
}

.page-about__card p {
  font-size: 1em;
  line-height: 1.6;
}

/* Feature List */
.page-about__feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-about__feature-list li {
  font-size: 1.1em;
  margin-bottom: 15px;
  padding-left: 30px;
  position: relative;
  line-height: 1.7;
}

.page-about__feature-list li::before {
  content: '✔';
  color: var(--login-color);
  position: absolute;
  left: 0;
  font-weight: bold;
  font-size: 1.2em;
  line-height: 1;
}

.page-about__btn-primary {
  display: inline-block;
  padding: 15px 40px;
  background: var(--login-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  margin-top: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-about__btn-primary:hover {
  background: #e06c00;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* Dark Background Section */
.page-about__dark-bg {
  background: var(--primary-color);
  color: var(--text-light);
}

.page-about__dark-bg .page-about__section-title {
  color: var(--text-light);
}

.page-about__dark-bg .page-about__section-title::after {
  background: var(--login-color);
}

.page-about__dark-bg .page-about__card {
  background: rgba(255, 255, 255, 0.15); /* Slightly transparent white on dark background */
  color: var(--text-light);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-about__dark-bg .page-about__card-title {
  color: var(--text-light);
}

/* Call to Action Section */
.page-about__call-to-action {
  padding: 100px 20px;
  text-align: center;
  background: var(--primary-color);
  color: var(--text-light);
}

.page-about__call-to-action .page-about__section-title {
  color: var(--text-light);
}

.page-about__call-to-action .page-about__section-title::after {
  background: var(--login-color);
}

.page-about__call-to-action .page-about__description {
  font-size: 1.3em;
  max-width: 800px;
  margin: 0 auto 40px auto;
  line-height: 1.7;
}

/* FAQ Section */
.page-about__faq {
  padding-bottom: 80px;
}

.page-about__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

.page-about__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.page-about__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: var(--secondary-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-about__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.page-about__faq-question:active {
  background: #eeeeee;
}

.page-about__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 1.15em;
  font-weight: 600;
  line-height: 1.5;
  color: var(--primary-color);
  pointer-events: none; /* Prevent h3 from blocking click event */
}

.page-about__faq-toggle {
  font-size: 2em;
  font-weight: bold;
  line-height: 1;
  color: #666;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none; /* Prevent icon from blocking click event */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
}

.page-about__faq-item.active .page-about__faq-toggle {
  color: var(--primary-color);
  transform: rotate(45deg); /* Rotate for 'x' effect */
}

.page-about__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 25px;
  opacity: 0;
  background: #f9f9f9;
  color: var(--text-dark);
}

.page-about__faq-item.active .page-about__faq-answer {
  max-height: 2000px !important; /* Use !important and large value */
  padding: 20px 25px !important;
  opacity: 1;
  border-radius: 0 0 8px 8px;
  border: 1px solid var(--border-color);
  border-top: none;
}

.page-about__faq-answer p {
  margin: 0;
  font-size: 1em;
  line-height: 1.6;
}

/* Responsive Design for Mobile */
@media (max-width: 768px) {
  /* Hero Section */
  .page-about__hero-section {
    padding-top: var(--header-offset, 120px) !important;
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-about__hero-title {
    font-size: 2em;
    line-height: 1.3;
  }

  .page-about__hero-description {
    font-size: 1em;
  }

  .page-about__cta-button {
    padding: 12px 25px;
    font-size: 1em;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* General Section Styling */
  .page-about__section {
    padding: 40px 15px;
  }

  .page-about__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
  }

  .page-about__sub-title {
    font-size: 1.4em;
    margin-top: 20px;
  }

  .page-about__text-block p,
  .page-about__feature-list li {
    font-size: 0.95em;
  }

  /* Grid Layouts */
  .page-about__content-grid,
  .page-about__grid-3-cols,
  .page-about__grid-2-cols {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .page-about__content-grid--reverse .page-about__text-block,
  .page-about__content-grid--reverse .page-about__image-block {
    grid-area: unset; /* Reset grid area for mobile */
  }

  .page-about__image-block {
    order: -1; /* Image first on mobile */
  }

  /* Card Styling */
  .page-about__card {
    padding: 20px;
  }

  .page-about__card img {
    height: 200px;
  }

  .page-about__card-title {
    font-size: 1.3em;
  }

  /* Call to Action Section */
  .page-about__call-to-action {
    padding: 60px 15px;
  }

  .page-about__call-to-action .page-about__description {
    font-size: 1em;
  }

  /* FAQ Section */
  .page-about__faq-question {
    padding: 15px 20px;
  }

  .page-about__faq-question h3 {
    font-size: 1em;
  }

  .page-about__faq-toggle {
    font-size: 1.8em;
    width: 25px;
    height: 25px;
  }

  .page-about__faq-answer {
    padding: 0 20px;
  }

  .page-about__faq-item.active .page-about__faq-answer {
    padding: 15px 20px !important;
  }

  /* Image responsiveness - Mandatory for all images */
  .page-about img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  /* Container responsiveness - Mandatory for all image/button containers */
  .page-about__section,
  .page-about__card,
  .page-about__container,
  .page-about__hero-container,
  .page-about__image-block,
  .page-about__text-block {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0; /* Adjust padding for inner elements if needed */
    padding-right: 0; /* Adjust padding for inner elements if needed */
  }
  .page-about__container {
    padding-left: 15px; /* Re-add padding to the main container for content */
    padding-right: 15px;
  }

  /* Button responsiveness - Mandatory for all buttons */
  .page-about__cta-button,
  .page-about__btn-primary,
  .page-about__btn-secondary,
  .page-about a[class*="button"],
  .page-about a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-about__btn-join {
    margin-top: 20px; /* Adjust margin for mobile */
  }

  .page-about__text-center .page-about__cta-button {
    margin-left: 0;
    margin-right: 0;
  }
}