/* style/faq.css */

:root {
  --primary-color: #FFD700;
  --secondary-color: #8B0000;
  --text-dark: #333333;
  --text-light: #ffffff;
  --bg-light: #f8f9fa;
  --border-color: #e0e0e0;
}

/* Body background is from shared.css (var(--dark-bg-1)). Assuming it's dark, use light text for general page content. */
.page-faq {
  color: var(--text-light); /* Use light text for content directly on the dark body background */
  background-color: transparent;
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

/* Fixed navbar spacing for the first section */
.page-faq__section-faq {
  padding-top: 120px; /* Desktop: Adjust based on fixed header height */
  padding-bottom: 60px;
  background-color: var(--dark-bg-1); /* Inherit from body or use a consistent dark background */
}

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

.page-faq__title {
  font-size: 38px;
  font-weight: bold;
  color: var(--primary-color);
  text-align: center;
  margin-bottom: 25px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-faq__intro-text {
  font-size: 18px;
  text-align: center;
  margin-bottom: 40px;
  color: var(--text-light);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__highlight {
  color: var(--primary-color);
  font-weight: bold;
}

.page-faq__faq-list {
  margin-bottom: 50px;
}

.page-faq__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: rgba(255, 255, 255, 0.08); /* Slightly transparent white for question background on dark theme */
  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: rgba(255, 255, 255, 0.15);
}

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

.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); /* Primary color for question text */
  pointer-events: none;
}

.page-faq__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: var(--primary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

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

.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: rgba(0, 0, 0, 0.3); /* Darker background for answer on dark theme */
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-light);
  font-size: 16px;
}

.page-faq__faq-item.active .page-faq__faq-answer {
  max-height: 2000px !important;
  padding: 20px 25px !important;
  opacity: 1;
  border-radius: 0 0 8px 8px;
}

.page-faq__faq-answer p {
  margin-bottom: 15px;
  color: var(--text-light);
}

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

.page-faq__faq-answer a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-faq__faq-answer a:hover {
  color: #FFC107;
  text-decoration: underline;
}

.page-faq__image-content {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  object-fit: cover;
}

.page-faq__cta-section {
  text-align: center;
  margin-top: 50px;
  padding: 40px 30px;
  background: rgba(255, 255, 255, 0.1); /* Light transparent background on dark theme */
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-faq__cta-text {
  font-size: 20px;
  color: var(--text-light);
  margin-bottom: 30px;
}

.page-faq__cta-button {
  display: inline-block;
  padding: 15px 40px;
  margin: 10px;
  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);
}

.page-faq__btn-primary {
  background: linear-gradient(135deg, var(--primary-color), #FFC107);
  color: var(--text-dark);
  border: 2px solid transparent;
}

.page-faq__btn-primary:hover {
  background: linear-gradient(135deg, #FFC107, var(--primary-color));
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.page-faq__btn-secondary {
  background: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.page-faq__btn-secondary:hover {
  background: var(--primary-color);
  color: var(--text-dark);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-faq__section-faq {
    padding-top: 100px !important; /* Mobile: Adjust based on fixed header height */
    padding-bottom: 40px;
  }

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

  .page-faq__title {
    font-size: 28px;
    margin-bottom: 20px;
  }

  .page-faq__intro-text {
    font-size: 16px;
    margin-bottom: 30px;
  }

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

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

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

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

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

  .page-faq__cta-section {
    padding: 30px 20px;
  }

  .page-faq__cta-text {
    font-size: 18px;
    margin-bottom: 20px;
  }

  .page-faq__cta-button {
    padding: 12px 30px;
    font-size: 16px;
    margin: 8px;
    width: calc(100% - 16px);
    max-width: 300px;
  }

  /* Mobile image adaptation */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  .page-faq__section-faq,
  .page-faq__container,
  .page-faq__faq-item,
  .page-faq__cta-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }
  
  .page-faq__faq-question {
    flex-wrap: wrap;
  }
  
  .page-faq__faq-question h3 {
    width: calc(100% - 40px);
  }
  
  .page-faq__faq-toggle {
    margin-left: auto;
  }
}