/* CSS file for FAQ page */

/* Base styles for .page-faq */
.page-faq {
  background-color: #B71C1C; /* Custom Background color */
  color: #FFF5E1; /* Custom Text Main color */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

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

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

.page-faq__section-title {
  font-size: 2.5em;
  color: #F4D34D; /* Gold color for titles */
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
  line-height: 1.2;
}

.page-faq__content-area {
  display: flex;
  flex-direction: column;
  gap: 30px;
  align-items: center;
}

.page-faq__content-area p {
  font-size: 1.1em;
  color: #FFF5E1;
  max-width: 800px;
  text-align: justify;
}

/* Hero Section */
.page-faq__hero-section {
  padding-top: 10px; /* Small top padding, relying on body for header offset */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  overflow: hidden;
  position: relative;
}

.page-faq__hero-image-wrapper {
  width: 100%;
  max-height: 600px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.page-faq__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  min-height: 200px; /* Enforce min size */
}

.page-faq__hero-content {
  position: relative;
  z-index: 1;
  padding: 30px 20px;
  max-width: 900px;
  margin-top: 20px; /* Space between image and text */
}

.page-faq__main-title {
  font-size: clamp(2.5em, 4vw, 3.5em); /* Responsive font size for H1 */
  color: #F4D34D; /* Gold for H1 */
  margin-bottom: 15px;
  font-weight: bold;
  line-height: 1.2;
}

.page-faq__hero-description {
  font-size: 1.2em;
  color: #FFF5E1;
  margin-bottom: 30px;
}

/* CTA Buttons */
.page-faq__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  flex-wrap: wrap;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.page-faq__btn-primary {
  background: linear-gradient(180deg, #FFD86A 0%, #E6B800 100%); /* Custom Button color */
  color: #333333; /* Dark text for contrast on gold button */
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
  text-align: center;
  display: inline-block;
}

.page-faq__btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 15px rgba(255, 216, 106, 0.6);
}

/* FAQ Accordion Styles */
.page-faq__faq-group {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

.page-faq__faq-item {
  background-color: #D32F2F; /* Card BG color */
  border: 1px solid #F2B544; /* Border color */
  border-radius: 10px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #FFF5E1; /* Text Main color for card content */
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.15em;
  color: #FFF5E1; /* Text Main color for question */
  position: relative;
  list-style: none; /* Hide default marker for details summary */
}

.page-faq__faq-question::-webkit-details-marker, 
.page-faq__faq-question::marker {
  display: none;
}

.page-faq__faq-qtext {
  flex-grow: 1;
}

.page-faq__faq-toggle {
  font-size: 1.5em;
  margin-left: 15px;
  transition: transform 0.3s ease;
}

.page-faq__faq-item[open] .page-faq__faq-toggle {
  transform: rotate(45deg);
}

.page-faq__faq-answer {
  padding: 0 25px 20px;
  font-size: 1em;
  line-height: 1.6;
  color: #FFF5E1;
}

.page-faq__faq-answer p {
  margin-bottom: 10px;
  color: #FFF5E1; /* Ensure paragraphs in answer are also Text Main color */
}

.page-faq__content-image {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  margin: 20px auto;
  min-width: 200px; /* Enforce min size */
  min-height: 200px; /* Enforce min size */
}

/* Specific content area layouts */
.page-faq__deposit-withdrawal .page-faq__content-area,
.page-faq__games-products .page-faq__content-area,
.page-faq__customer-support .page-faq__content-area,
.page-faq__technical-safety .page-faq__content-area {
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
}

.page-faq__deposit-withdrawal .page-faq__content-area .page-faq__content-image,
.page-faq__games-products .page-faq__content-area .page-faq__content-image,
.page-faq__customer-support .page-faq__content-area .page-faq__content-image,
.page-faq__technical-safety .page-faq__content-area .page-faq__content-image {
  flex: 1 1 400px;
  max-width: 50%;
  margin: 0;
  order: 1;
}

.page-faq__deposit-withdrawal .page-faq__content-area .page-faq__faq-group,
.page-faq__games-products .page-faq__content-area .page-faq__faq-group,
.page-faq__customer-support .page-faq__content-area .page-faq__faq-group,
.page-faq__technical-safety .page-faq__content-area .page-faq__faq-group {
  flex: 1 1 450px;
  max-width: 50%;
  order: 2;
}

.page-faq__technical-safety .page-faq__content-area .page-faq__content-image {
  order: 2; /* Reverse order for this section */
}

.page-faq__technical-safety .page-faq__content-area .page-faq__faq-group {
  order: 1; /* Reverse order for this section */
}

/* Conclusion Section */
.page-faq__conclusion .page-faq__description {
  text-align: center;
  margin-bottom: 20px;
  font-size: 1.1em;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

/* General image and container responsiveness */
.page-faq img {
  max-width: 100%;
  height: auto;
  display: block;
}

.page-faq__section,
.page-faq__container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Mobile responsiveness */
@media (max-width: 1024px) {
  .page-faq__container {
    padding: 15px;
  }

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

  .page-faq__hero-content {
    padding: 20px;
  }

  .page-faq__main-title {
    font-size: clamp(2em, 5vw, 3em);
  }

  .page-faq__hero-description {
    font-size: 1.1em;
  }

  .page-faq__faq-question {
    font-size: 1.1em;
    padding: 18px 20px;
  }

  .page-faq__faq-answer {
    padding: 0 20px 18px;
  }

  .page-faq__deposit-withdrawal .page-faq__content-area .page-faq__content-image,
  .page-faq__games-products .page-faq__content-area .page-faq__content-image,
  .page-faq__customer-support .page-faq__content-area .page-faq__content-image,
  .page-faq__technical-safety .page-faq__content-area .page-faq__content-image {
    max-width: 100%;
    flex: 1 1 100%;
    order: 1;
  }

  .page-faq__deposit-withdrawal .page-faq__content-area .page-faq__faq-group,
  .page-faq__games-products .page-faq__content-area .page-faq__faq-group,
  .page-faq__customer-support .page-faq__content-area .page-faq__faq-group,
  .page-faq__technical-safety .page-faq__content-area .page-faq__faq-group {
    max-width: 100%;
    flex: 1 1 100%;
    order: 2;
  }

  .page-faq__technical-safety .page-faq__content-area .page-faq__content-image {
    order: 1; /* Keep image first for mobile */
  }

  .page-faq__technical-safety .page-faq__content-area .page-faq__faq-group {
    order: 2; /* Keep faq group second for mobile */
  }
}

@media (max-width: 768px) {
  /* HERO 主图区域 */
  .page-faq__hero-section {
    padding-top: 10px; /* Small top padding */
  }

  .page-faq__main-title {
    font-size: clamp(1.8em, 7vw, 2.5em) !important;
  }

  .page-faq__hero-description {
    font-size: 1em !important;
  }

  /* 长文金框区 (Not applicable directly, adapting for general content sections) */
  .page-faq__content-area p {
    font-size: 1em !important;
  }

  /* 游戏轮播 (Not applicable for FAQ page) */
  /* 合作品牌六宫格 (Not applicable for FAQ page) */
  /* 博客卡片区 (Not applicable for FAQ page) */

  /* 通用图片与容器 */
  .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;
  }

  /* 按钮与按钮容器 */
  .page-faq__cta-button,
  .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-direction: column !important; /* Force vertical stacking for multiple buttons */
    gap: 10px;
  }

  .page-faq__section-title {
    font-size: 1.8em !important;
    margin-bottom: 25px !important;
  }

  .page-faq__faq-question {
    font-size: 1em !important;
    padding: 15px 18px !important;
  }

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