/* 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: var(--black-color); /* Inherited from shared.css */
}

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

.page-faq__section {
  padding: 60px 0;
  text-align: center;
}

.page-faq__dark-bg {
  background-color: #26A9E0;
  color: #ffffff;
}

.page-faq__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-faq__section-title {
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 700;
  margin-bottom: 20px;
  color: inherit;
  line-height: 1.2;
}

.page-faq__text-block {
  font-size: 18px;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: inherit;
}

/* Hero Section */
.page-faq__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 0 60px 0; /* body handles top padding, this is decorative */
  overflow: hidden;
}

.page-faq__hero-image-wrapper {
  width: 100%;
  max-height: 500px;
  overflow: hidden;
  position: relative;
}

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

.page-faq__hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 40px 20px;
  max-width: 900px;
  margin-top: -100px; /* Adjust this to bring content closer to the image, without overlapping */
  background-color: rgba(38, 169, 224, 0.9); /* Semi-transparent brand color background */
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-faq__main-title {
  font-size: clamp(32px, 4vw, 50px);
  font-weight: 800;
  margin-bottom: 20px;
  color: #ffffff;
  line-height: 1.2;
}

.page-faq__description {
  font-size: 18px;
  margin-bottom: 30px;
  color: #f0f0f0;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-faq__btn-primary,
.page-faq__btn-secondary {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

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

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

.page-faq__btn-secondary {
  background-color: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

.page-faq__btn-secondary:hover {
  background-color: #ffffff;
  color: #26A9E0;
}

.page-faq__btn-full-width {
  width: 100%;
  max-width: 300px; /* Limit max width for better aesthetics on desktop */
  margin: 20px auto 0 auto;
}

/* FAQ Items */
.page-faq__faq-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #ffffff;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 2000px; /* Sufficiently large value */
  padding-bottom: 20px;
  transition: max-height 0.5s ease-out, padding-bottom 0.5s ease-out;
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  background-color: rgba(255, 255, 255, 0.05);
  transition: background-color 0.3s ease;
}

.page-faq__faq-item.active .page-faq__faq-question {
  background-color: rgba(255, 255, 255, 0.1);
}

.page-faq__faq-question:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.page-faq__faq-qtext {
  flex-grow: 1;
  margin-right: 15px;
}

.page-faq__faq-toggle {
  font-size: 24px;
  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;
  padding: 0 25px;
  overflow: hidden;
  font-size: 16px;
  color: #f0f0f0;
  transition: max-height 0.5s ease-in, padding 0.5s ease-in;
}

.page-faq__faq-answer p,
.page-faq__faq-answer ol,
.page-faq__faq-answer ul {
  margin-top: 15px;
  margin-bottom: 15px;
  color: inherit;
}

.page-faq__faq-answer li {
  margin-bottom: 8px;
}

/* Details element specific styling */
.page-faq__faq-item[open] .page-faq__faq-answer {
  max-height: none; /* Let content define height */
  padding-bottom: 20px;
}

.page-faq__faq-item details > summary {
  list-style: none;
}

.page-faq__faq-item details > summary::-webkit-details-marker {
  display: none;
}

/* Images within content sections */
.page-faq__image-content {
  width: 100%;
  height: auto;
  display: block;
  margin: 40px auto;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  max-width: 800px; /* Ensure images don't stretch too wide on desktop */
}

/* Specific section colors for better contrast */
.page-faq__introduction-section,
.page-faq__transaction-section {
  background-color: var(--black-color);
  color: #ffffff;
}

.page-faq__registration-section .page-faq__text-block,
.page-faq__registration-section .page-faq__faq-question,
.page-faq__registration-section .page-faq__faq-answer {
  color: #333333;
}

.page-faq__registration-section .page-faq__faq-item {
  background-color: rgba(38, 169, 224, 0.1);
  border: 1px solid rgba(38, 169, 224, 0.3);
}

.page-faq__registration-section .page-faq__faq-question {
  background-color: rgba(38, 169, 224, 0.05);
}

.page-faq__registration-section .page-faq__faq-item.active .page-faq__faq-question,
.page-faq__registration-section .page-faq__faq-question:hover {
  background-color: rgba(38, 169, 224, 0.15);
}

.page-faq__registration-section .page-faq__btn-primary {
  background-color: #26A9E0;
  border-color: #26A9E0;
  color: #ffffff;
}

.page-faq__registration-section .page-faq__btn-primary:hover {
  background-color: #1f8ec4;
  border-color: #1f8ec4;
}

.page-faq__cta-buttons--bottom {
  margin-top: 60px;
}

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

  .page-faq__container {
    padding: 0 15px;
  }

  .page-faq__section {
    padding: 40px 0;
  }

  .page-faq__section-title {
    font-size: 28px;
  }

  .page-faq__text-block {
    font-size: 16px;
    margin-bottom: 30px;
  }

  .page-faq__hero-content {
    padding: 30px 15px;
    margin-top: -60px;
  }

  .page-faq__main-title {
    font-size: 30px;
  }

  .page-faq__description {
    font-size: 16px;
  }

  .page-faq__cta-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .page-faq__btn-primary,
  .page-faq__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 20px;
  }

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

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

  .page-faq__faq-item[open] .page-faq__faq-answer {
    padding-bottom: 15px;
  }

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

  .page-faq__hero-image-wrapper,
  .page-faq__section,
  .page-faq__container,
  .page-faq__hero-content,
  .page-faq__faq-item,
  .page-faq__cta-buttons,
  .page-faq__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-faq__hero-section {
    padding-top: 10px !important;
    padding-left: 0;
    padding-right: 0;
  }

  .page-faq__hero-image-wrapper {
    padding-left: 0;
    padding-right: 0;
  }

  .page-faq__image-content {
    margin-left: 0;
    margin-right: 0;
  }

  .page-faq__cta-buttons {
    flex-wrap: wrap !important;
    gap: 10px;
    padding-left: 0;
    padding-right: 0;
  }
}