.page-faq {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light background */
  background-color: var(--background-color, #ffffff); /* Inherit from shared, default white */
}

.page-faq__hero-section {
  position: relative;
  padding: 80px 20px;
  padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
  background-color: #017439; /* Primary brand color */
  color: #ffffff;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
}

.page-faq__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
  box-sizing: border-box;
}

.page-faq__main-title {
  font-size: 2.8em;
  margin-bottom: 20px;
  line-height: 1.2;
  color: #ffffff;
}

.page-faq__description {
  font-size: 1.1em;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__btn-primary,
.page-faq__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  margin: 5px;
  box-sizing: border-box;
}

.page-faq__btn-primary {
  background-color: #C30808; /* Register/Login color */
  color: #FFFF00; /* Register/Login font color */
  border: 2px solid #C30808;
}

.page-faq__btn-primary:hover {
  background-color: #a00606;
  border-color: #a00606;
}

.page-faq__btn-secondary {
  background-color: #ffffff;
  color: #017439; /* Primary brand color */
  border: 2px solid #017439;
}

.page-faq__btn-secondary:hover {
  background-color: #f0f0f0;
  color: #005f2f;
  border-color: #005f2f;
}

.page-faq__content-area {
  padding: 60px 0;
  background-color: #ffffff;
  color: #333333;
}

.page-faq__section-title {
  font-size: 2em;
  color: #017439;
  text-align: center;
  margin-bottom: 30px;
}

.page-faq__intro-text {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 50px auto;
  font-size: 1.05em;
}

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

.page-faq__subsection-title {
  font-size: 1.6em;
  color: #017439;
  margin-top: 40px;
  margin-bottom: 20px;
  padding-left: 15px;
}

.page-faq__faq-item {
  margin-bottom: 15px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  background-color: #ffffff;
  color: #333333;
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background-color: #f8f8f8;
  cursor: pointer;
  font-weight: bold;
  color: #017439;
  transition: background-color 0.3s ease;
}

.page-faq__faq-question:hover {
  background-color: #e0e0e0;
}

.page-faq__faq-title {
  margin: 0;
  font-size: 1.1em;
  color: inherit;
}

.page-faq__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
  color: #017439;
}

.page-faq__faq-item.active .page-faq__faq-toggle {
  transform: rotate(45deg);
}

.page-faq__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  color: #333333;
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 1000px !important; /* Ensure it expands sufficiently */
  padding: 15px 20px;
}

.page-faq__faq-answer p {
  margin: 0 0 10px 0;
  line-height: 1.6;
}

.page-faq__faq-answer p:last-child {
  margin-bottom: 0;
}

.page-faq__support-cta {
  text-align: center;
  margin-top: 60px;
  padding: 40px 20px;
  background-color: #f8f8f8;
  border-radius: 10px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__support-title {
  font-size: 2em;
  color: #017439;
  margin-bottom: 15px;
}

.page-faq__support-text {
  font-size: 1.1em;
  margin-bottom: 30px;
}

.page-faq__button-group {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
}

/* Image specific styles */
.page-faq img {
  max-width: 100%;
  height: auto;
  display: block;
  object-fit: cover; /* Ensures images fill their space without distortion */
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .page-faq {
    font-size: 15px;
    line-height: 1.5;
  }

  .page-faq__hero-section {
    padding: 60px 15px;
    padding-top: var(--header-offset, 120px) !important; /* Re-apply for mobile */
    min-height: 300px;
  }

  .page-faq__main-title {
    font-size: 2em;
  }

  .page-faq__description {
    font-size: 1em;
  }

  .page-faq__btn-primary,
  .page-faq__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    margin: 5px 0 !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  .page-faq__button-group {
    flex-direction: column;
    gap: 10px;
  }

  .page-faq__content-area {
    padding: 40px 0;
  }

  .page-faq__section-title {
    font-size: 1.8em;
    margin-bottom: 25px;
  }

  .page-faq__intro-text {
    margin-bottom: 40px;
    padding: 0 15px;
  }

  .page-faq__subsection-title {
    font-size: 1.4em;
    padding-left: 15px;
  }

  .page-faq__faq-question {
    padding: 12px 15px;
  }

  .page-faq__faq-title {
    font-size: 1em;
  }

  .page-faq__faq-answer {
    padding: 0 15px;
  }

  .page-faq__faq-item.active .page-faq__faq-answer {
    padding: 10px 15px;
  }

  .page-faq__support-cta {
    margin-top: 40px;
    padding: 30px 15px;
  }

  .page-faq__support-title {
    font-size: 1.8em;
  }

  /* Responsive image rules for content area */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-faq__section,
  .page-faq__card,
  .page-faq__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}

@media (max-width: 480px) {
  .page-faq__main-title {
    font-size: 1.8em;
  }

  .page-faq__section-title {
    font-size: 1.6em;
  }

  .page-faq__support-title {
    font-size: 1.6em;
  }
}