/* style/faq.css */
:root {
  --primary-color: #1A2A44;
  --secondary-color: #FFCC00;
  --text-dark: #333333;
  --text-light: #ffffff;
  --bg-light: #f9f9f9;
  --bg-white: #ffffff;
  --border-light: #e0e0e0;
  --button-hover-dark: #121f33;
  --button-hover-light: #e6b800;
}

.page-faq {
  font-family: 'Arial', sans-serif;
  color: var(--text-dark); /* Default text color for light backgrounds */
  background: var(--bg-light); /* Assuming body background is light for main content */
}

/* Fixed Nav Bar Spacing - Desktop */
.page-faq__hero-section {
  padding-top: 180px; /* Adjust based on fixed header height */
  padding-bottom: 60px;
  background: var(--primary-color);
  color: var(--text-light);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-faq__hero-container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-faq__hero-title {
  font-size: 42px;
  font-weight: bold;
  margin-bottom: 20px;
  line-height: 1.2;
  color: var(--secondary-color); /* Highlight with secondary color */
}

.page-faq__hero-description {
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 30px;
  color: var(--text-light);
}

.page-faq__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: var(--secondary-color);
  color: var(--primary-color);
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border: none;
}

.page-faq__cta-button:hover {
  background: var(--button-hover-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.page-faq__content-section {
  padding: 60px 20px;
  background: var(--bg-light);
}

.page-faq__content-container {
  max-width: 960px;
  margin: 0 auto;
}

.page-faq__faq-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

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

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

.page-faq__faq-question:hover {
  background: var(--bg-light);
  border-color: #d0d0d0;
}

.page-faq__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--primary-color);
  pointer-events: none; /* Allows click on parent */
}

.page-faq__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 20px;
  pointer-events: none; /* Allows click on parent */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-faq__faq-item.active .page-faq__faq-toggle {
  transform: rotate(45deg); /* Rotate for 'x' effect */
  color: var(--secondary-color);
  background-color: var(--button-hover-dark);
}

.page-faq__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: var(--bg-white);
  border: 1px solid var(--border-light);
  border-top: none;
  border-radius: 0 0 8px 8px;
  color: var(--text-dark);
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 2000px !important; /* Sufficiently large */
  padding: 20px 25px !important;
  opacity: 1;
}

.page-faq__faq-answer p {
  margin-bottom: 15px;
  line-height: 1.7;
  font-size: 16px;
}

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

.page-faq__faq-answer ul,
.page-faq__faq-answer ol {
  margin-left: 25px;
  margin-bottom: 15px;
  line-height: 1.7;
}

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

.page-faq__faq-answer a {
  color: var(--primary-color);
  text-decoration: underline;
}

.page-faq__faq-answer a:hover {
  color: var(--secondary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
  /* Fixed Nav Bar Spacing - Mobile */
  .page-faq__hero-section {
    padding-top: 160px !important; /* Adjust based on mobile fixed header height */
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-faq__hero-title {
    font-size: 32px;
  }

  .page-faq__hero-description {
    font-size: 16px;
  }

  .page-faq__cta-button {
    padding: 12px 30px;
    font-size: 16px;
  }

  .page-faq__content-section {
    padding: 30px 15px;
  }

  .page-faq__faq-item {
    border-radius: 6px;
  }

  .page-faq__faq-question {
    padding: 15px 18px;
    border-radius: 6px;
  }

  .page-faq__faq-question h3 {
    font-size: 16px;
  }

  .page-faq__faq-toggle {
    font-size: 24px;
    width: 28px;
    height: 28px;
    margin-left: 15px;
  }

  .page-faq__faq-answer {
    padding: 0 18px;
    border-radius: 0 0 6px 6px;
  }

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

  .page-faq__faq-answer p,
  .page-faq__faq-answer li {
    font-size: 15px;
  }

  /* Image responsive adaptation */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-faq__hero-section,
  .page-faq__content-section,
  .page-faq__content-container,
  .page-faq__faq-item,
  .page-faq__faq-question,
  .page-faq__faq-answer {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}