/* style/terms-conditions.css */
/* Biến CSS tùy chỉnh */
:root {
  --primary-color: #007bff; /* Màu xanh chủ đạo */
  --secondary-color: #ffc107; /* Màu vàng phụ trợ */
  --text-dark: #333333; /* Màu chữ tối */
  --text-light: #ffffff; /* Màu chữ sáng */
  --background-dark: #121212; /* Màu nền tối từ body */
  --background-light: #ffffff; /* Màu nền sáng */
  --border-color: #e0e0e0; /* Màu viền */
}

/* Đảm bảo nội dung không bị che bởi header cố định */
.page-terms-conditions {
  padding-top: 100px; /* Desktop: Điều chỉnh dựa trên chiều cao header */
  background-color: var(--background-dark); /* Nền tối cho toàn bộ trang */
  color: var(--text-light); /* Chữ sáng trên nền tối */
  font-family: Arial, sans-serif;
  line-height: 1.6;
  font-size: 16px;
}

/* --- Hero Section --- */
.page-terms-conditions__hero-section {
  position: relative;
  width: 100%;
  padding: 80px 20px;
  text-align: center;
  background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('[GALLERY:hero:8kbrt,vietnam-betting,online-entertainment,platform-background]') no-repeat center center/cover;
  color: var(--text-light);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 400px;
}

.page-terms-conditions__hero-section .page-terms-conditions__container {
  max-width: 900px;
}

.page-terms-conditions__main-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: var(--text-light);
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-terms-conditions__description {
  font-size: 1.2em;
  margin-bottom: 40px;
  color: #f0f0f0;
}

.page-terms-conditions__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Cho phép các nút xuống dòng trên di động */
}

.page-terms-conditions__cta-button {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border: none;
  cursor: pointer;
}

.page-terms-conditions__btn-primary {
  background: var(--primary-color);
  color: var(--text-light);
}

.page-terms-conditions__btn-primary:hover {
  background: #0056b3;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.page-terms-conditions__btn-secondary {
  background: var(--secondary-color);
  color: var(--text-dark);
}

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

/* --- Content Section --- */
.page-terms-conditions__content-section {
  background-color: var(--background-light);
  color: var(--text-dark);
  padding: 60px 20px;
}

.page-terms-conditions__container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 15px;
}

.page-terms-conditions__section-title {
  font-size: 2.2em;
  color: var(--primary-color);
  margin-top: 40px;
  margin-bottom: 25px;
  font-weight: bold;
}

.page-terms-conditions__section-title--light {
  color: var(--text-light);
}

.page-terms-conditions__content-section p {
  margin-bottom: 20px;
  line-height: 1.7;
  font-size: 1em;
}

.page-terms-conditions__content-section ul {
  list-style: disc;
  margin-left: 25px;
  margin-bottom: 20px;
}

.page-terms-conditions__content-section li {
  margin-bottom: 10px;
}

/* --- Image Styles --- */
.page-terms-conditions__image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  object-fit: cover;
}

.page-terms-conditions__image--large {
  width: 80%;
  max-height: 500px;
}

.page-terms-conditions__image--medium {
  width: 70%;
  max-height: 400px;
}

.page-terms-conditions__image--small {
  width: 60%;
  max-height: 350px;
}

/* --- FAQ Section --- */
.page-terms-conditions__faq-section {
  background-color: var(--background-dark);
  color: var(--text-light);
  padding: 60px 20px;
}

.page-terms-conditions__faq-list {
  margin-top: 40px;
}

.page-terms-conditions__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08); /* Nền hơi sáng hơn để nổi bật */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.page-terms-conditions__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: rgba(255, 255, 255, 0.15); /* Nền câu hỏi sáng hơn nữa */
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-terms-conditions__faq-question:hover {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.3);
}

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

.page-terms-conditions__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-color); /* Màu vàng cho dấu toggle */
  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-terms-conditions__faq-item.active .page-terms-conditions__faq-toggle {
  color: var(--text-light);
  transform: rotate(45deg); /* Thêm hiệu ứng xoay cho dấu + */
}

.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 15px;
  opacity: 0;
  color: #e0e0e0; /* Màu chữ hơi nhạt hơn cho câu trả lời */
}

.page-terms-conditions__faq-item.active .page-terms-conditions__faq-answer {
  max-height: 2000px !important;
  padding: 20px 15px !important;
  opacity: 1;
  background: rgba(255, 255, 255, 0.05); /* Nền câu trả lời */
  border-radius: 0 0 5px 5px;
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .page-terms-conditions__main-title {
    font-size: 2.8em;
  }
  .page-terms-conditions__section-title {
    font-size: 1.8em;
  }
  .page-terms-conditions__image--large { width: 90%; }
  .page-terms-conditions__image--medium { width: 80%; }
  .page-terms-conditions__image--small { width: 70%; }
}

@media (max-width: 768px) {
  .page-terms-conditions {
    padding-top: 80px !important; /* Mobile: Điều chỉnh dựa trên chiều cao header di động */
    font-size: 15px;
  }

  .page-terms-conditions__hero-section {
    padding: 60px 15px;
    min-height: 300px;
  }

  .page-terms-conditions__main-title {
    font-size: 2em;
    margin-bottom: 15px;
  }

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

  .page-terms-conditions__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100%;
    max-width: 300px; /* Giới hạn chiều rộng nút trên mobile */
    margin: 0 auto;
  }

  .page-terms-conditions__cta-button {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding: 12px 25px;
    font-size: 1em;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

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

  .page-terms-conditions__section-title {
    font-size: 1.6em;
    margin-top: 30px;
    margin-bottom: 20px;
  }

  .page-terms-conditions__image {
    margin: 20px auto;
  }
  .page-terms-conditions__image--large,
  .page-terms-conditions__image--medium,
  .page-terms-conditions__image--small {
    width: 100%; /* Đảm bảo hình ảnh full width trên mobile */
    max-height: none; /* Bỏ giới hạn chiều cao để ảnh hiển thị đầy đủ */
  }

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

/* Đảm bảo hình ảnh không bị filter */
.page-terms-conditions img {
  filter: none !important;
}

/* Đảm bảo các container chứa ảnh/video/nút không bị tràn trên mobile */
.page-terms-conditions__container,
.page-terms-conditions__hero-section,
.page-terms-conditions__content-section,
.page-terms-conditions__faq-section,
.page-terms-conditions__cta-buttons {
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden; /* Ngăn tràn ngang */
}