/* style/terms-conditions.css */
.page-terms-conditions {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #f0f0f0; /* Light text for dark body background */
  background-color: #121212; /* Inherited from shared, but for clarity */
}

.page-terms-conditions__hero-section {
  position: relative;
  width: 100%;
  padding: 80px 20px;
  padding-top: var(--header-offset, 120px); /* Ensures content is below fixed header */
  background-color: #0a0a0a;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #ffffff;
}

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

.page-terms-conditions__main-title {
  font-size: 48px;
  font-weight: bold;
  margin-bottom: 20px;
  color: #FFD700; /* Gold accent */
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-terms-conditions__description {
  font-size: 18px;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: #e0e0e0;
}

.page-terms-conditions__cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-terms-conditions__cta-button {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  white-space: normal;
  word-wrap: break-word;
  max-width: 100%;
  box-sizing: border-box;
}

.page-terms-conditions__btn-primary {
  background: #FFD700; /* Primary gold */
  color: #000000; /* Black text for contrast */
  border: 2px solid #FFD700;
}

.page-terms-conditions__btn-primary:hover {
  background: #e6c200;
  border-color: #e6c200;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-terms-conditions__btn-secondary {
  background: transparent;
  color: #FFD700; /* Gold text */
  border: 2px solid #FFD700;
}

.page-terms-conditions__btn-secondary:hover {
  background: #FFD700;
  color: #000000;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-terms-conditions__content-section {
  padding: 60px 20px;
  background-color: #1a1a1a;
}

.page-terms-conditions__section-title {
  font-size: 36px;
  font-weight: bold;
  margin-bottom: 40px;
  text-align: center;
  color: #FFD700; /* Gold accent */
  text-transform: uppercase;
}

.page-terms-conditions__intro-text {
  font-size: 17px;
  margin-bottom: 40px;
  text-align: justify;
  color: #cccccc;
}

.page-terms-conditions__article {
  background-color: #222222;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.page-terms-conditions__article-heading {
  font-size: 24px;
  font-weight: bold;
  margin-top: 30px;
  margin-bottom: 15px;
  color: #FFD700; /* Gold accent */
}

.page-terms-conditions__article p {
  margin-bottom: 15px;
  color: #e0e0e0;
  text-align: justify;
}

.page-terms-conditions__article a {
  color: #8B0000; /* Dark red for links */
  text-decoration: underline;
  transition: color 0.3s ease;
}

.page-terms-conditions__article a:hover {
  color: #FFD700;
}

.page-terms-conditions__list {
  list-style-type: disc;
  margin-left: 25px;
  margin-bottom: 20px;
  color: #e0e0e0;
}

.page-terms-conditions__list li {
  margin-bottom: 10px;
  color: #e0e0e0;
}

.page-terms-conditions__list li strong {
  color: #FFD700;
}

.page-terms-conditions__image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-terms-conditions__faq-section {
  padding: 60px 20px;
  background-color: #0a0a0a;
}

.page-terms-conditions__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

/* FAQ容器样式 */
.page-terms-conditions__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  background-color: #222222;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* FAQ默认状态 - 答案隐藏 */
.page-terms-conditions__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 20px;
  opacity: 0;
  color: #e0e0e0;
}

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.page-terms-conditions__faq-item.active .page-terms-conditions__faq-answer {
  max-height: 2000px !important; /* 🚨 使用!important确保优先级，值足够大以容纳任何内容 */
  padding: 20px !important;
  opacity: 1;
  background: #2c2c2c;
  border-radius: 0 0 5px 5px;
}

/* 问题样式 */
.page-terms-conditions__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #222222;
  border: 1px solid #333333;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
  color: #ffffff;
}

.page-terms-conditions__faq-question:hover {
  background: #2c2c2c;
  border-color: #FFD700;
}

.page-terms-conditions__faq-question:active {
  background: #3a3a3a;
}

/* 问题标题样式 */
.page-terms-conditions__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* 防止h3标签阻止点击事件 */
  color: #FFD700;
}

/* 切换图标 */
.page-terms-conditions__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: #FFD700;
  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: 30px;
  height: 30px;
}

.page-terms-conditions__faq-item.active .page-terms-conditions__faq-toggle {
  color: #ffffff;
  transform: rotate(45deg); /* Change to X shape when active */
}

/* 🚨 移动端响应式设计 */
@media (max-width: 768px) {
  .page-terms-conditions {
    font-size: 15px;
  }

  .page-terms-conditions__hero-section {
    padding: 60px 15px;
    padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
  }

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

  .page-terms-conditions__description {
    font-size: 16px;
    margin-bottom: 30px;
  }

  .page-terms-conditions__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px; /* Add padding to prevent overflow */
  }

  .page-terms-conditions__cta-button {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 25px;
    font-size: 16px;
  }

  .page-terms-conditions__content-section,
  .page-terms-conditions__faq-section {
    padding: 40px 15px;
  }

  .page-terms-conditions__section-title {
    font-size: 28px;
    margin-bottom: 30px;
  }

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

  .page-terms-conditions__article {
    padding: 20px;
  }

  .page-terms-conditions__article-heading {
    font-size: 20px;
    margin-top: 25px;
    margin-bottom: 10px;
  }

  .page-terms-conditions__article p {
    font-size: 15px;
  }

  .page-terms-conditions__list {
    margin-left: 20px;
  }

  .page-terms-conditions__list li {
    font-size: 15px;
  }

  /* Mobile FAQ styles */
  .page-terms-conditions__faq-question {
    padding: 15px;
    flex-wrap: wrap;
  }
  
  .page-terms-conditions__faq-question h3 {
    font-size: 16px;
    width: calc(100% - 40px);
    margin-bottom: 0;
  }
  
  .page-terms-conditions__faq-toggle {
    margin-left: 10px;
    width: 24px;
    height: 24px;
    font-size: 22px;
  }
  
  .page-terms-conditions__faq-answer {
    padding: 0 15px;
  }
  
  .page-terms-conditions__faq-item.active .page-terms-conditions__faq-answer {
    padding: 15px !important;
  }

  /* Ensure images do not overflow on mobile */
  .page-terms-conditions img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  .page-terms-conditions__container,
  .page-terms-conditions__article,
  .page-terms-conditions__faq-list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0;
    padding-right: 0;
    overflow: hidden;
  }

  .page-terms-conditions__content-section,
  .page-terms-conditions__faq-section {
    padding-left: 15px;
    padding-right: 15px;
  }
}