/* style/faq.css */

/* Base styles for the FAQ page */
.page-faq {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: transparent; /* Body background is handled by shared.css (#121212) */
}

/* Hero Section */
.page-faq__hero-section {
  position: relative;
  padding: 80px 20px;
  padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
  background-color: #017439; /* Brand primary color for hero background */
  color: #ffffff;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden; /* For image positioning */
  min-height: 500px;
}

.page-faq__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.2; /* Subtle background image */
}

.page-faq__hero-section .page-faq__container {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
}

.page-faq__main-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: #ffffff;
  font-weight: bold;
}

.page-faq__intro-text {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #f0f0f0;
}

.page-faq__btn-primary {
  display: inline-block;
  background-color: #C30808; /* Register/Login color */
  color: #FFFF00; /* Register/Login font color */
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: none;
}

.page-faq__btn-primary:hover {
  background-color: #a30606;
  transform: translateY(-2px);
}

/* Accordion Section */
.page-faq__accordion-section {
  padding: 60px 20px;
  background-color: #1a1a1a; /* Slightly lighter dark background for content */
  color: #ffffff;
  position: relative;
  overflow: hidden;
}

.page-faq__accordion-section .page-faq__container {
  max-width: 1000px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.page-faq__section-title {
  font-size: 2.5em;
  color: #ffffff;
  text-align: center;
  margin-bottom: 20px;
}

.page-faq__section-description {
  font-size: 1.1em;
  color: #cccccc;
  text-align: center;
  margin-bottom: 40px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__faq-list {
  margin-top: 30px;
}

.page-faq__faq-item {
  background-color: rgba(255, 255, 255, 0.08); /* Dark background with subtle transparency */
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  background-color: #017439; /* Brand primary color */
  color: #ffffff;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease;
}

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

.page-faq__faq-question h3 {
  margin: 0;
  font-size: 1.1em;
  color: #ffffff;
}

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

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

.page-faq__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 25px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background-color: rgba(255, 255, 255, 0.05);
  color: #f0f0f0;
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 1000px !important; /* Sufficiently large to show content */
  padding: 20px 25px !important;
}

.page-faq__faq-answer p {
  margin-bottom: 15px;
  color: #f0f0f0;
}

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

.page-faq__answer-link {
  color: #FFFF00; /* Highlight links */
  text-decoration: underline;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-faq__answer-link:hover {
  color: #fff;
}

/* CTA Section at the bottom */
.page-faq__cta-section {
  background-color: #017439; /* Brand primary color */
  color: #ffffff;
  padding: 50px 30px;
  text-align: center;
  border-radius: 10px;
  margin-top: 60px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
}

.page-faq__support-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.1;
}

.page-faq__cta-section .page-faq__cta-title,
.page-faq__cta-section .page-faq__cta-description,
.page-faq__cta-section .page-faq__button-group {
  position: relative;
  z-index: 1;
}

.page-faq__cta-title {
  font-size: 2.2em;
  margin-bottom: 15px;
  color: #ffffff;
}

.page-faq__cta-description {
  font-size: 1.1em;
  margin-bottom: 30px;
  color: #f0f0f0;
}

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

.page-faq__btn-secondary {
  display: inline-block;
  background-color: #ffffff; /* Auxiliary color */
  color: #017439; /* Brand primary color for text */
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease, transform 0.3s ease, color 0.3s ease;
  border: 2px solid #017439;
}

.page-faq__btn-secondary:hover {
  background-color: #f0f0f0;
  color: #005a2e;
  transform: translateY(-2px);
}

/* Global image responsiveness */
.page-faq img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .page-faq {
    font-size: 16px;
    line-height: 1.6;
  }

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

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

  .page-faq__intro-text {
    font-size: 1em;
  }

  .page-faq__btn-primary,
  .page-faq__btn-secondary {
    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-faq__button-group {
    flex-direction: column;
    gap: 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 0 15px;
  }

  .page-faq__accordion-section,
  .page-faq__cta-section {
    padding: 40px 15px;
  }

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

  .page-faq__section-description {
    font-size: 0.95em;
  }

  .page-faq__faq-question {
    padding: 15px 20px;
    font-size: 1em;
  }

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

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

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

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

  .page-faq__cta-description {
    font-size: 0.95em;
  }

  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-faq__container,
  .page-faq__faq-list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
}

/* Ensure contrast for all text elements */
.page-faq p, .page-faq li, .page-faq h1, .page-faq h2, .page-faq h3, .page-faq h4, .page-faq h5, .page-faq h6 {
  color: #ffffff; /* Default for dark background */
}

.page-faq__light-bg p, .page-faq__light-bg li, .page-faq__light-bg h1, .page-faq__light-bg h2, .page-faq__light-bg h3, .page-faq__light-bg h4, .page-faq__light-bg h5, .page-faq__light-bg h6 {
  color: #ffffff; /* Still light text on light dark background */
}

.page-faq__faq-question h3 {
  color: #ffffff;
}

.page-faq__faq-answer p {
  color: #f0f0f0;
}

.page-faq__answer-link {
  color: #FFFF00;
}

/* Specific color for Register/Login buttons */
.page-faq__btn-primary {
  background-color: #C30808;
  color: #FFFF00;
}

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