/* style/casino.css */
/* 
  Tất cả các class phải tuân thủ quy tắc BEM: .page-casino__element-name.
  Không sử dụng bộ chọn con cháu (descendant selectors) hoặc bộ chọn toàn cục.
  Phạm vi style phải giới hạn trong .page-casino.
*/

.page-casino {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Body background is dark, so text is light */
  background-color: #000000; /* Matching body background for consistency */
  overflow-x: hidden;
}

/* Top spacing for the first content module due to fixed header */
.page-casino__intro-section {
  padding-top: 120px; /* Desktop spacing */
}

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

.page-casino__dark-bg {
  background-color: #000000;
  color: #ffffff;
}

.page-casino__light-bg {
  background-color: #f8f9fa;
  color: #333333;
}

.page-casino__title {
  font-size: 3.2em;
  color: #ffc107;
  text-align: center;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.page-casino__subtitle {
  font-size: 2.5em;
  color: #ffc107;
  text-align: center;
  margin-bottom: 30px;
  font-weight: 600;
  line-height: 1.3;
}

.page-casino__subtitle--cta {
  color: #ffffff;
  font-size: 2.8em;
}

.page-casino__text {
  font-size: 1.1em;
  text-align: center;
  max-width: 900px;
  margin: 0 auto 30px auto;
  color: #f0f0f0;
}

.page-casino__text--cta {
  color: #ffffff;
  font-size: 1.2em;
  margin-bottom: 40px;
}

.page-casino__button-group {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.page-casino__btn {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  border: 2px solid transparent;
}

.page-casino__btn--primary {
  background-color: #ffc107;
  color: #000000;
  border-color: #ffc107;
}

.page-casino__btn--primary:hover {
  background-color: #e0a800;
  border-color: #e0a800;
}

.page-casino__btn--secondary {
  background-color: transparent;
  color: #ffc107;
  border-color: #ffc107;
}

.page-casino__btn--secondary:hover {
  background-color: #ffc107;
  color: #000000;
}

.page-casino__btn--small {
  padding: 10px 20px;
  font-size: 0.95em;
  border-radius: 5px;
}

.page-casino__btn--large {
  padding: 18px 40px;
  font-size: 1.3em;
  border-radius: 10px;
}

.page-casino__intro-section {
  background: linear-gradient(135deg, #000000, #333333);
  padding: 80px 0;
}

.page-casino__why-choose-section {
  padding: 60px 0;
}

.page-casino__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-casino__feature-card {
  background-color: #ffffff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: #333333;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-casino__feature-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.page-casino__feature-icon {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 20px;
  max-width: 100%;
  height: auto;
}

.page-casino__card-title {
  font-size: 1.5em;
  color: #0056b3;
  margin-bottom: 15px;
  font-weight: 600;
}

.page-casino__card-text {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
  text-align: center;
}

.page-casino__games-section {
  padding: 60px 0;
}

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

.page-casino__game-card {
  background-color: rgba(255, 255, 255, 0.08);
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-casino__game-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

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

.page-casino__game-card .page-casino__card-title {
  color: #ffc107;
  font-size: 1.6em;
}

.page-casino__game-card .page-casino__card-text {
  color: #e0e0e0;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-casino__guide-section {
  padding: 60px 0;
}

.page-casino__guide-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-casino__step-item {
  background-color: #ffffff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  color: #333333;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-casino__step-number {
  width: 60px;
  height: 60px;
  line-height: 60px;
  border-radius: 50%;
  background-color: #0056b3;
  color: #ffffff;
  font-size: 2em;
  font-weight: bold;
  margin-bottom: 20px;
}

.page-casino__step-item .page-casino__card-title {
  color: #0056b3;
}

.page-casino__step-item .page-casino__card-text {
  color: #555555;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-casino__promotions-section {
  padding: 60px 0;
}

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

.page-casino__promo-card {
  background-color: rgba(255, 255, 255, 0.08);
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-casino__promo-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

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

.page-casino__promo-card .page-casino__card-title {
  color: #ffc107;
  font-size: 1.6em;
}

.page-casino__promo-card .page-casino__card-text {
  color: #e0e0e0;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-casino__faq-section {
  padding: 60px 0;
}

.page-casino__faq-list {
  margin-top: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

/* FAQ默认状态 - 答案隐藏 */
.page-casino__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease;
  padding: 0 15px;
  opacity: 0;
}

/* FAQ展开状态 - 🚨 Sử dụng !important và đủ lớn max-height để đảm bảo mở rộng */
.page-casino__faq-item.active .page-casino__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;
  color: #333333; /* Dark text for light background */
}

/* Vấn đề style */
.page-casino__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;
  color: #333333; /* Dark text for light background */
}

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

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

/* Tiêu đề câu hỏi style */
.page-casino__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 1.1em;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none; /* Ngăn thẻ h3 chặn sự kiện click */
  color: #0056b3; /* Brand color for question title */
}

/* Biểu tượng chuyển đổi */
.page-casino__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; /* Ngăn biểu tượng chặn sự kiện click */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-casino__faq-item.active .page-casino__faq-toggle {
  color: #333;
}

.page-casino__cta-section {
  padding: 80px 0;
  text-align: center;
}

.page-casino__cta-content {
  background-color: #0056b3;
  border-radius: 15px;
  padding: 50px 30px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

/* Responsive design */
@media (max-width: 1024px) {
  .page-casino__title {
    font-size: 2.8em;
  }
  .page-casino__subtitle {
    font-size: 2em;
  }
  .page-casino__subtitle--cta {
    font-size: 2.2em;
  }
  .page-casino__btn--large {
    font-size: 1.1em;
    padding: 15px 30px;
  }
}

@media (max-width: 768px) {
  .page-casino__intro-section {
    padding-top: 100px; /* Mobile spacing */
  }
  .page-casino__container {
    padding: 30px 15px;
  }
  .page-casino__title {
    font-size: 2.2em;
  }
  .page-casino__subtitle {
    font-size: 1.8em;
  }
  .page-casino__subtitle--cta {
    font-size: 1.9em;
  }
  .page-casino__text {
    font-size: 1em;
  }
  .page-casino__text--cta {
    font-size: 1.1em;
  }
  .page-casino__button-group {
    flex-direction: column;
    gap: 15px;
  }
  .page-casino__btn {
    width: 100%;
    padding: 12px 20px;
    font-size: 1em;
  }
  .page-casino__btn--large {
    padding: 15px 30px;
    font-size: 1.2em;
  }
  .page-casino__features-grid, .page-casino__games-grid, .page-casino__guide-steps, .page-casino__promo-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .page-casino__feature-card, .page-casino__game-card, .page-casino__step-item, .page-casino__promo-card {
    padding: 20px;
  }
  .page-casino__feature-icon {
    width: 60px;
    height: 60px;
  }
  .page-casino__card-title {
    font-size: 1.3em;
  }
  .page-casino__faq-question {
    padding: 15px;
    flex-wrap: wrap;
  }
  .page-casino__faq-question h3 {
    font-size: 1em;
    margin-bottom: 0;
    width: calc(100% - 40px);
  }
  .page-casino__faq-toggle {
    margin-left: 10px;
    width: 24px;
    height: 24px;
    font-size: 20px;
  }
  .page-casino__faq-answer {
    padding: 0 15px;
  }
  .page-casino__faq-item.active .page-casino__faq-answer {
    padding: 15px !important;
  }

  /* Mobile image responsiveness */
  .page-casino img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-casino__section,
  .page-casino__card,
  .page-casino__container,
  .page-casino__feature-card,
  .page-casino__game-card,
  .page-casino__step-item,
  .page-casino__promo-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-casino__cta-content {
    padding: 30px 20px;
  }
}