/* style/faq.css */

:root {
  --primary-color: #1A202C;
  --secondary-color: #FFD700;
  --text-light: #ffffff;
  --text-dark: #333333;
  --background-dark: #0a0a0a;
  --card-background-light: #f9f9f9;
  --border-color: #e0e0e0;
}

.page-faq {
  color: var(--text-light); /* Body background is dark, so text is light */
  background-color: var(--background-dark);
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

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

/* Intro Section */
.page-faq__intro-section {
  padding-bottom: 40px;
  background-color: var(--background-dark);
  color: var(--text-light);
  text-align: center;
  /* 🚨 桌面端通用内容区域顶部间距（必须严格遵守） */
  padding-top: 120px; /* 桌面端：根据导航栏实际高度调整，通常为80-150px */
}

.page-faq__main-title {
  font-size: 3.2em;
  font-weight: bold;
  color: var(--secondary-color);
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-faq__intro-text {
  font-size: 1.1em;
  margin-bottom: 30px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-faq__intro-image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* FAQ Section */
.page-faq__faq-section {
  padding: 60px 0;
  background-color: var(--background-dark);
}

.page-faq__section-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--secondary-color);
  text-align: center;
  margin-bottom: 40px;
}

.page-faq__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

.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 15px;
  opacity: 0;
  background: var(--card-background-light);
  color: var(--text-dark);
}

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

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

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

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

.page-faq__faq-answer a {
  color: #007bff;
  text-decoration: none;
  font-weight: bold;
}

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

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: var(--primary-color);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
  color: var(--text-light);
}

.page-faq__faq-question:hover {
  background: #2a3345; /* Slightly lighter primary color on hover */
  border-color: rgba(255, 255, 255, 0.2);
}

.page-faq__faq-question:active {
  background: #3a4455;
}

.page-faq__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 1.1em;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none;
  color: var(--text-light);
}

.page-faq__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-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: 28px;
  height: 28px;
}

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

.page-faq__faq-answer-image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* CTA Section */
.page-faq__cta-section {
  padding: 60px 0;
  text-align: center;
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-faq__cta-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--secondary-color);
  margin-bottom: 20px;
}

.page-faq__cta-description {
  font-size: 1.1em;
  max-width: 800px;
  margin: 0 auto 30px auto;
}

.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: 1.2em;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-faq__cta-button:hover {
  background: #e6c200; /* Slightly darker gold */
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.highlight {
  color: var(--secondary-color);
  font-weight: bold;
}

/* 🚨 移动端响应式设计（必须严格遵守） */
@media (max-width: 768px) {
  .page-faq__intro-section {
    /* 🚨 移动端必须重新设置padding-top，覆盖桌面端样式 */
    padding-top: 100px !important; /* 移动端：根据移动端导航栏实际高度调整，通常为80-120px */
    padding-bottom: 20px;
  }

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

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

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

  .page-faq__section-title,
  .page-faq__cta-title {
    font-size: 1.8em;
    margin-bottom: 20px;
  }

  .page-faq__faq-question {
    padding: 15px;
    flex-wrap: wrap;
  }
  
  .page-faq__faq-question h3 {
    font-size: 1em;
    margin-bottom: 0;
    width: calc(100% - 40px);
  }
  
  .page-faq__faq-toggle {
    margin-left: 10px;
    width: 24px;
    height: 24px;
    font-size: 20px;
  }
  
  .page-faq__faq-answer {
    padding: 0 15px;
  }
  
  .page-faq__faq-item.active .page-faq__faq-answer {
    padding: 15px !important;
  }

  .page-faq__cta-button {
    padding: 12px 25px;
    font-size: 1em;
  }

  /* 🚨 移动端图片响应式适配要求（必须严格遵守，防止图片过大导致横向滚动条）： */
  .page-faq img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-faq__section,
  .page-faq__card,
  .page-faq__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}