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

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

.page-faq__top-section {
  background: linear-gradient(90deg, #26A9E0, #34C6FF); /* Primary color gradient */
  color: #ffffff;
  padding-top: 10px; /* Small top padding, relying on body for header offset */
  padding-bottom: 40px;
  text-align: center;
}

.page-faq__main-title {
  font-size: clamp(2em, 3.5vw, 3em);
  font-weight: 700;
  margin-bottom: 15px;
  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;
  color: #f0f0f0;
}

.page-faq__description a {
  color: #ffffff;
  text-decoration: underline;
}

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

.page-faq__btn-primary,
.page-faq__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-faq__btn-primary {
  background-color: #EA7C07; /* Login color for primary action */
  color: #ffffff;
  border: 2px solid transparent;
}

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

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

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

.page-faq__faq-section {
  padding: 50px 0;
  background-color: #f9f9f9; /* Light background for FAQ content */
}

.page-faq__category-title {
  font-size: 2.2em;
  color: #26A9E0; /* Primary brand color for category titles */
  margin-top: 40px;
  margin-bottom: 30px;
  text-align: center;
  font-weight: 700;
}

.page-faq__category-title:first-of-type {
  margin-top: 0;
}

.page-faq__faq-item {
  background-color: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 10px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.page-faq__faq-question {
  padding: 18px 25px;
  font-size: 1.25em;
  font-weight: bold;
  color: #333333;
  cursor: pointer;
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #fefefe;
  border-bottom: 1px solid transparent; /* Placeholder for active state */
}

.page-faq__faq-question::after {
  content: '+';
  font-size: 1.5em;
  font-weight: normal;
  transition: transform 0.3s ease;
}

.page-faq__faq-item.active .page-faq__faq-question::after {
  content: '-';
  transform: rotate(0deg); /* No rotation needed for +/- */
}

.page-faq__faq-item.active .page-faq__faq-question {
  border-bottom-color: #e0e0e0;
}

.page-faq__faq-answer {
  padding: 0 25px;
  font-size: 1.05em;
  color: #555555;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-out, padding 0.4s ease-out;
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 2000px; /* Sufficiently large to accommodate content */
  padding-top: 15px;
  padding-bottom: 25px;
}

.page-faq__faq-answer p {
  margin-bottom: 1em;
}

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

.page-faq__faq-answer a {
  color: #26A9E0;
  text-decoration: underline;
}

.page-faq__faq-answer a:hover {
  color: #1a7bbd;
}

.page-faq__image-wrapper {
  margin: 20px 0;
  text-align: center;
}

.page-faq__image-wrapper img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  display: block;
  margin: 0 auto;
}

.page-faq__image-caption {
  font-size: 0.9em;
  color: #777777;
  margin-top: 10px;
}

.page-faq__info-box,
.page-faq__warning-box {
  padding: 25px;
  border-radius: 10px;
  margin-top: 30px;
  margin-bottom: 30px;
  text-align: center;
}

.page-faq__info-box {
  background-color: #e6f7ff; /* Light blue background */
  border: 1px solid #91d5ff;
  color: #004d66;
}

.page-faq__info-box-title {
  font-size: 1.5em;
  color: #26A9E0;
  margin-bottom: 15px;
}

.page-faq__info-box p {
  margin-bottom: 20px;
}

.page-faq__warning-box {
  background-color: #fffbe6; /* Light yellow background */
  border: 1px solid #ffe58f;
  color: #614700;
}

.page-faq__warning-box p {
  margin-bottom: 0;
}

/* --- Responsive Styles --- */

/* Tablet */
@media (max-width: 1024px) {
  .page-faq__main-title {
    font-size: 2.5em;
  }

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

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

  .page-faq__faq-answer {
    font-size: 1em;
    padding: 0 20px;
  }

  .page-faq__faq-item.active .page-faq__faq-answer {
    padding-top: 10px;
    padding-bottom: 20px;
  }

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

/* Mobile */
@media (max-width: 768px) {
  /* 1. Top section (padding/spacing, CTA stacking) */
  .page-faq__top-section {
    padding-top: 10px !important; /* Enforce small top padding */
    padding-bottom: 30px;
  }

  .page-faq__main-title {
    font-size: 1.8em;
    margin-bottom: 10px;
  }

  .page-faq__description {
    font-size: 0.95em;
    margin-bottom: 20px;
  }

  .page-faq__cta-buttons {
    flex-direction: column; /* Stack buttons vertically */
    gap: 10px;
    padding: 0 15px;
  }

  /* 4. Buttons and button containers */
  .page-faq__btn-primary,
  .page-faq__btn-secondary,
  .page-faq a[class*="button"],
  .page-faq 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-faq__cta-buttons,
  .page-faq__button-group,
  .page-faq__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 10px;
  }

  /* 2. Single-column long text container */
  .page-faq__container {
    padding: 0 15px; /* Adjust padding for smaller screens */
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-faq__faq-section {
    padding: 30px 0;
  }

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

  /* 5. FAQ section (font sizes, padding) */
  .page-faq__faq-question {
    font-size: 1.05em;
    padding: 15px 20px;
  }

  .page-faq__faq-answer {
    font-size: 0.95em;
    padding: 0 20px;
  }

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

  /* 3. General images and figures */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-faq__image-wrapper {
    margin: 15px 0;
  }

  .page-faq__info-box,
  .page-faq__warning-box {
    padding: 20px;
    margin-top: 25px;
    margin-bottom: 25px;
  }

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