/* style/casino.css */

/* Custom properties for colors */
:root {
  --primary-color: #26A9E0;
  --secondary-color: #FFFFFF;
  --login-color: #EA7C07;
  --background-color: #FFFFFF;
  --text-dark: #333333;
  --text-light: #ffffff;
  --border-color: #e0e0e0;
}

.page-casino {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-dark); /* Default text color for light background */
  background-color: var(--background-color);
  padding-top: 0; /* Handled by shared.css body padding or hero section */
}

/* Hero Section */
.page-casino__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  background: linear-gradient(135deg, var(--primary-color), #87CEEB); /* Gradient with primary color */
  color: var(--text-light);
  padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
}

.page-casino__hero-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.page-casino__hero-image {
  width: 100%;
  margin-bottom: 30px;
}

.page-casino__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  border-radius: 8px;
  object-fit: cover;
}

.page-casino__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.page-casino__hero-content h1 {
  font-size: 3.2em;
  margin-bottom: 15px;
  color: var(--text-light);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.page-casino__hero-content p {
  font-size: 1.2em;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-light);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.page-casino__cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap; /* Added for mobile responsiveness */
}

/* General button styles */
.page-casino__cta-button,
.page-casino__btn-primary,
.page-casino__btn-secondary {
  display: inline-block;
  padding: 15px 40px;
  text-decoration: none;
  border-radius: 5px;
  font-size: 18px;
  font-weight: bold;
  transition: all 0.3s ease;
  cursor: pointer;
  max-width: 100%; /* For mobile responsiveness */
  box-sizing: border-box; /* For mobile responsiveness */
  white-space: normal; /* For mobile responsiveness */
  word-wrap: break-word; /* For mobile responsiveness */
}

.page-casino__btn-primary {
  background: var(--login-color); /* Use login color for primary CTA */
  color: var(--text-light);
  border: 2px solid transparent;
}

.page-casino__btn-primary:hover {
  background: #D16F00; /* Darker shade of #EA7C07 */
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-casino__btn-secondary {
  background: var(--secondary-color);
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.page-casino__btn-secondary:hover {
  background: var(--primary-color);
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-casino__btn-text {
  display: inline-block;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
  margin-top: 10px;
  transition: color 0.3s ease;
}

.page-casino__btn-text:hover {
  color: #1F88B4; /* Slightly darker shade of #26A9E0 */
}

/* General Section Styles */
.page-casino__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  box-sizing: border-box; /* Ensures padding is included in the element's total width */
}

.page-casino__section-title {
  font-size: 2.5em;
  margin-bottom: 20px;
  text-align: center;
  color: var(--primary-color);
}

.page-casino__section-description {
  font-size: 1.1em;
  text-align: center;
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-dark);
}

/* Section Backgrounds */
.page-casino__light-bg {
  background-color: var(--background-color);
  color: var(--text-dark);
}

.page-casino__dark-bg {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.page-casino__dark-bg .page-casino__section-title,
.page-casino__dark-bg .page-casino__section-description {
  color: var(--text-light);
}

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

.page-casino__feature-item {
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease;
  color: var(--text-dark);
}

.page-casino__feature-item:hover {
  transform: translateY(-5px);
}

.page-casino__feature-item img {
  width: 100%;
  max-width: 400px;
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
  min-height: 200px; /* Enforce min height for content images */
  min-width: 200px; /* Enforce min width for content images */
}

.page-casino__feature-item h3 {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: var(--primary-color);
}

/* Game Categories Section */
.page-casino__game-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-casino__game-card {
  background-color: var(--secondary-color);
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease;
  color: var(--text-dark);
}

.page-casino__game-card:hover {
  transform: translateY(-5px);
}

.page-casino__game-card img {
  width: 100%;
  height: auto;
  max-height: 250px; /* Limit height for uniform cards */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  min-height: 200px; /* Enforce min height for card images */
  min-width: 200px; /* Enforce min width for card images */
}

.page-casino__game-card h3 {
  font-size: 1.6em;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.page-casino__game-card h3 a {
  color: var(--primary-color);
  text-decoration: none;
}

.page-casino__game-card h3 a:hover {
  text-decoration: underline;
}

/* Promotions Section */
.page-casino__promo-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-casino__promo-item {
  background-color: var(--secondary-color);
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  color: var(--text-dark);
}

.page-casino__promo-item img {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  min-height: 200px; /* Enforce min height for promo images */
  min-width: 200px; /* Enforce min width for promo images */
}

.page-casino__promo-item h3 {
  font-size: 1.4em;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.page-casino__centered-cta {
  text-align: center;
  margin-top: 50px;
}

/* Security & Support Section */
.page-casino__security-support-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-casino__security-item {
  background-color: var(--secondary-color);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  color: var(--text-dark);
}

.page-casino__security-item img {
  width: 100%;
  max-width: 300px;
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
  min-height: 200px; /* Enforce min height for security images */
  min-width: 200px; /* Enforce min width for security images */
}

.page-casino__security-item h3 {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.page-casino__support-channels {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 20px;
  flex-wrap: wrap; /* For mobile responsiveness */
}


/* FAQ Section */
.page-casino__faq-list {
  margin-top: 40px;
}

/* FAQ容器样式 */
.page-casino__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* 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, opacity 0.4s ease;
  padding: 0 15px;
  opacity: 0;
  color: var(--text-dark);
}

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

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

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

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

/* 问题标题样式 */
.page-casino__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-dark);
}

/* 切换图标 */
.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; /* 防止图标阻止点击事件 */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-casino__faq-item.active .page-casino__faq-toggle {
  color: var(--primary-color);
  transform: rotate(45deg); /* Changed to rotate for a 'x' effect */
}


/* Call to Action Section */
.page-casino__call-to-action-section {
  text-align: center;
  padding: 80px 20px;
  background: linear-gradient(135deg, var(--primary-color), #007bb6);
  color: var(--text-light);
}

.page-casino__call-to-action-section .page-casino__section-title,
.page-casino__call-to-action-section .page-casino__section-description {
  color: var(--text-light);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-casino__hero-content h1 {
    font-size: 2.8em;
  }
  .page-casino__hero-content p {
    font-size: 1.1em;
  }
  .page-casino__section-title {
    font-size: 2em;
  }
}

@media (max-width: 768px) {
  /* Mobile Hero Section */
  .page-casino__hero-section {
    padding-top: var(--header-offset, 120px) !important; /* Ensure mobile header offset */
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-casino__hero-content h1 {
    font-size: 2em;
  }
}
}