/* style/responsible-gambling.css */

:root {
  --primary-color: #FFD700;
  --secondary-color: #1E90FF;
  --text-color-dark: #333333;
  --text-color-light: #ffffff;
  --background-light: #f9f9f9;
  --background-dark: #0d0d0d;
}

.page-responsible-gambling {
  font-family: 'Arial', sans-serif;
  color: var(--text-color-dark);
  line-height: 1.6;
  background-color: #ffffff; /* Default white body background */
}

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

.page-responsible-gambling__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px;
  padding-top: var(--header-offset, 120px);
  background-color: #1a1a1a; /* Dark background for hero */
  color: var(--text-color-light);
  overflow: hidden;
}

.page-responsible-gambling__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
  z-index: 0;
}

.page-responsible-gambling__hero-section .page-responsible-gambling__container {
  position: relative;
  z-index: 1;
}

.page-responsible-gambling__main-title {
  font-size: 48px;
  font-weight: bold;
  margin-bottom: 20px;
  color: var(--primary-color);
  text-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.page-responsible-gambling__hero-description {
  font-size: 18px;
  max-width: 800px;
  margin: 0 auto 40px auto;
  color: #e0e0e0;
}

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

.page-responsible-gambling__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 18px;
  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-responsible-gambling__cta-button {
  background-color: var(--primary-color);
  color: var(--text-color-light);
}

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

.page-responsible-gambling__cta-button--secondary {
  background-color: var(--secondary-color);
  color: var(--text-color-light);
}

.page-responsible-gambling__cta-button--secondary:hover {
  background-color: #1a7fdd; /* Darker blue */
}

.page-responsible-gambling__section-title {
  font-size: 36px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 40px;
  color: var(--secondary-color);
  position: relative;
  padding-bottom: 15px;
}

.page-responsible-gambling__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

.page-responsible-gambling__policy-section,
.page-responsible-gambling__tools-section,
.page-responsible-gambling__problem-gambling-section,
.page-responsible-gambling__minor-protection-section,
.page-responsible-gambling__support-organizations-section,
.page-responsible-gambling__faq-section,
.page-responsible-gambling__conclusion-section {
  padding: 80px 0;
  background-color: #ffffff;
}

.page-responsible-gambling__policy-section {
  background-color: var(--background-light);
}

.page-responsible-gambling__text-block {
  font-size: 16px;
  text-align: justify;
  max-width: 900px;
  margin: 0 auto 30px auto;
  color: var(--text-color-dark);
}

.page-responsible-gambling__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-responsible-gambling__feature-item {
  background-color: #ffffff;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-responsible-gambling__feature-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.page-responsible-gambling__feature-icon {
  width: 100%;
  max-width: 200px;
  height: auto;
  margin-bottom: 20px;
  border-radius: 8px;
  object-fit: cover;
}

.page-responsible-gambling__feature-title {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 15px;
  color: var(--secondary-color);
}

.page-responsible-gambling__feature-description {
  font-size: 15px;
  color: #555555;
}

.page-responsible-gambling__tool-card {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-bottom: 60px;
  background-color: var(--background-light);
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.page-responsible-gambling__tool-card--reverse {
  flex-direction: row-reverse;
  background-color: #eaf6ff; /* Lighter blue tint */
}

.page-responsible-gambling__tool-image {
  flex: 1;
  max-width: 50%;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-responsible-gambling__tool-content {
  flex: 1;
}

.page-responsible-gambling__tool-title {
  font-size: 28px;
  font-weight: bold;
  margin-bottom: 20px;
  color: var(--secondary-color);
}

.page-responsible-gambling__tool-description {
  font-size: 17px;
  line-height: 1.7;
  margin-bottom: 30px;
  color: #444444;
}

.page-responsible-gambling__tool-button {
  display: inline-block;
  padding: 12px 25px;
  background-color: var(--primary-color);
  color: var(--text-color-light);
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.page-responsible-gambling__tool-button:hover {
  background-color: #e6c200;
  transform: translateY(-2px);
}

.page-responsible-gambling__problem-gambling-section {
  background-color: #fff;
}

.page-responsible-gambling__checklist {
  list-style: none;
  padding: 0;
  margin: 30px auto 40px auto;
  max-width: 900px;
}

.page-responsible-gambling__checklist-item {
  position: relative;
  padding-left: 35px;
  margin-bottom: 15px;
  font-size: 17px;
  color: #333333;
  line-height: 1.5;
}

.page-responsible-gambling__checklist-item::before {
  content: '✔';
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
  font-size: 20px;
  top: -2px;
}

.page-responsible-gambling__cta-button--dark {
  background-color: #333333;
  color: var(--text-color-light);
  margin-top: 30px;
}

.page-responsible-gambling__cta-button--dark:hover {
  background-color: #000000;
}

.page-responsible-gambling__minor-protection-section {
  background-color: var(--background-light);
}

.page-responsible-gambling__protection-tips {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-top: 50px;
  background-color: #ffffff;
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.page-responsible-gambling__protection-image {
  flex: 1;
  max-width: 50%;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-responsible-gambling__protection-content {
  flex: 1;
}

.page-responsible-gambling__protection-content h3 {
  font-size: 28px;
  font-weight: bold;
  margin-bottom: 20px;
  color: var(--secondary-color);
}

.page-responsible-gambling__support-organizations-section {
  background-color: #fff;
}

.page-responsible-gambling__support-list {
  list-style: none;
  padding: 0;
  margin-top: 50px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-responsible-gambling__support-item {
  display: flex;
  align-items: center;
  gap: 20px;
  background-color: var(--background-light);
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-responsible-gambling__support-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.page-responsible-gambling__support-logo {
  width: 80px;
  height: 80px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid #e0e0e0;
}

.page-responsible-gambling__support-info h3 {
  font-size: 20px;
  margin-bottom: 5px;
}

.page-responsible-gambling__support-info h3 a {
  color: var(--secondary-color);
  text-decoration: none;
}

.page-responsible-gambling__support-info h3 a:hover {
  text-decoration: underline;
}

.page-responsible-gambling__support-info p {
  font-size: 15px;
  color: #666666;
}

.page-responsible-gambling__faq-section {
  background-color: var(--background-light);
}

.page-responsible-gambling__faq-list {
  max-width: 900px;
  margin: 50px auto 0 auto;
}

/* FAQ容器样式 */
.page-responsible-gambling__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

/* FAQ默认状态 - 答案隐藏 */
.page-responsible-gambling__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;
}

/* FAQ展开状态 - 🚨 使用!important和足够大的max-height确保一定能展开 */
.page-responsible-gambling__faq-item.active .page-responsible-gambling__faq-answer {
  max-height: 2000px !important; /* 🚨 Sử dụng !important để đảm bảo độ ưu tiên, giá trị đủ lớn để chứa mọi nội dung */
  padding: 20px 15px !important;
  opacity: 1;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
}

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

.page-responsible-gambling__faq-question:hover {
  background: #f5f5f5;
  border-color: #d0d0d0;
}

.page-responsible-gambling__faq-question:active {
  background: #eeeeee;
}

/* 问题标题样式 */
.page-responsible-gambling__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* 防止h3标签阻止点击事件 */
  color: var(--text-color-dark);
}

/* 切换图标 */
.page-responsible-gambling__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #666;
  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-responsible-gambling__faq-item.active .page-responsible-gambling__faq-toggle {
  color: var(--primary-color);
  transform: rotate(45deg); /* Change to X shape or rotate */
}

.page-responsible-gambling__conclusion-section {
  text-align: center;
  background-color: #1a1a1a;
  color: var(--text-color-light);
}

.page-responsible-gambling__conclusion-section .page-responsible-gambling__section-title {
  color: var(--primary-color);
}

.page-responsible-gambling__conclusion-section .page-responsible-gambling__text-block {
  color: #e0e0e0;
}

.page-responsible-gambling__cta-button--primary {
  background-color: var(--primary-color);
  color: var(--text-color-light);
  margin-top: 40px;
}

.page-responsible-gambling__cta-button--primary:hover {
  background-color: #e6c200;
}

/* Global image responsiveness for content area */
.page-responsible-gambling img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* 🚨 移动端响应式设计 */
@media (max-width: 992px) {
  .page-responsible-gambling__main-title {
    font-size: 40px;
  }

  .page-responsible-gambling__hero-description {
    font-size: 16px;
  }

  .page-responsible-gambling__section-title {
    font-size: 30px;
  }

  .page-responsible-gambling__tool-card,
  .page-responsible-gambling__protection-tips {
    flex-direction: column;
    gap: 30px;
    padding: 30px;
  }

  .page-responsible-gambling__tool-card--reverse {
    flex-direction: column;
  }

  .page-responsible-gambling__tool-image,
  .page-responsible-gambling__protection-image {
    max-width: 100%;
  }

  .page-responsible-gambling__features-grid {
    grid-template-columns: 1fr;
  }

  .page-responsible-gambling__support-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .page-responsible-gambling {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-responsible-gambling__hero-section {
    padding: 60px 15px;
    padding-top: var(--header-offset, 120px) !important;
  }

  .page-responsible-gambling__main-title {
    font-size: 32px;
    margin-bottom: 15px;
  }

  .page-responsible-gambling__hero-description {
    font-size: 15px;
    margin-bottom: 30px;
  }

  .page-responsible-gambling__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 0 15px;
  }

  .page-responsible-gambling__cta-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 20px;
    font-size: 16px;
  }

  .page-responsible-gambling__policy-section,
  .page-responsible-gambling__tools-section,
  .page-responsible-gambling__problem-gambling-section,
  .page-responsible-gambling__minor-protection-section,
  .page-responsible-gambling__support-organizations-section,
  .page-responsible-gambling__faq-section,
  .page-responsible-gambling__conclusion-section {
    padding: 40px 0;
  }

  .page-responsible-gambling__container {
    padding: 0 15px;
  }

  .page-responsible-gambling__section-title {
    font-size: 24px;
    margin-bottom: 30px;
  }

  .page-responsible-gambling__text-block {
    font-size: 15px;
    margin-bottom: 20px;
  }

  .page-responsible-gambling__feature-item {
    padding: 25px;
  }

  .page-responsible-gambling__feature-title {
    font-size: 20px;
  }

  .page-responsible-gambling__tool-card,
  .page-responsible-gambling__protection-tips {
    padding: 25px;
    gap: 20px;
    margin-bottom: 40px;
  }

  .page-responsible-gambling__tool-title,
  .page-responsible-gambling__protection-content h3 {
    font-size: 22px;
    margin-bottom: 15px;
  }

  .page-responsible-gambling__tool-description {
    font-size: 15px;
    margin-bottom: 25px;
  }

  .page-responsible-gambling__tool-button {
    padding: 10px 20px;
    font-size: 15px;
  }

  .page-responsible-gambling__checklist-item {
    font-size: 15px;
    padding-left: 30px;
    margin-bottom: 10px;
  }

  .page-responsible-gambling__checklist-item::before {
    font-size: 18px;
    top: 0;
  }

  .page-responsible-gambling__support-item {
    padding: 20px;
    gap: 15px;
  }

  .page-responsible-gambling__support-logo {
    width: 60px;
    height: 60px;
  }

  .page-responsible-gambling__support-info h3 {
    font-size: 18px;
  }

  .page-responsible-gambling__support-info p {
    font-size: 14px;
  }

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

  /* Force all content images to be responsive */
  .page-responsible-gambling img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  .page-responsible-gambling__hero-image,
  .page-responsible-gambling__feature-icon,
  .page-responsible-gambling__tool-image,
  .page-responsible-gambling__protection-image,
  .page-responsible-gambling__support-logo {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    box-sizing: border-box !important;
  }

  /* Ensure containers do not overflow */
  .page-responsible-gambling__section,
  .page-responsible-gambling__card,
  .page-responsible-gambling__container,
  .page-responsible-gambling__tool-card,
  .page-responsible-gambling__protection-tips {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-responsible-gambling__cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }
}