/* style/jackpot-games.css */

/* Custom Colors */
:root {
  --hello88-primary: #11A84E;
  --hello88-secondary: #22C768;
  --hello88-button-gradient-start: #2AD16F;
  --hello88-button-gradient-end: #13994A;
  --hello88-card-bg: #11271B;
  --hello88-bg: #08160F;
  --hello88-text-main: #F2FFF6;
  --hello88-text-secondary: #A7D9B8;
  --hello88-border: #2E7A4E;
  --hello88-glow: #57E38D;
  --hello88-gold: #F2C14E;
  --hello88-divider: #1E3A2A;
  --hello88-deep-green: #0A4B2C;
}

/* Base styles for the page content area */
.page-jackpot-games {
  color: var(--hello88-text-main); /* Assuming dark body background based on custom colors */
  background-color: var(--hello88-bg); /* Use the specified background color */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

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

/* Hero Section */
.page-jackpot-games__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column; /* Image on top, content below */
  align-items: center;
  justify-content: center;
  overflow: hidden;
  text-align: center;
  padding-bottom: 60px; /* Space below content */
  padding-top: 10px; /* Small top padding, body handles header offset */
}

.page-jackpot-games__hero-image-wrapper {
  width: 100%;
  max-width: 100%; /* Ensure it doesn't overflow */
  margin-bottom: 30px; /* Space between image and text content */
}

.page-jackpot-games__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  border-radius: 10px;
}

.page-jackpot-games__hero-content {
  max-width: 900px;
  padding: 0 20px;
}

.page-jackpot-games__hero-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive font size for H1 */
  font-weight: bold;
  color: var(--hello88-gold);
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 0 0 10px rgba(242, 193, 78, 0.5);
}

.page-jackpot-games__hero-description {
  font-size: 1.2rem;
  color: var(--hello88-text-secondary);
  margin-bottom: 30px;
}

.page-jackpot-games__cta-buttons {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on small screens */
  gap: 20px;
  justify-content: center;
  width: 100%; /* For mobile responsiveness */
  max-width: 600px; /* Limit width on larger screens */
  margin: 0 auto;
}

.page-jackpot-games__btn-primary,
.page-jackpot-games__btn-secondary,
.page-jackpot-games__btn-small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  cursor: pointer;
  box-sizing: border-box;
  max-width: 100%; /* Ensure buttons adapt to container */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text breaking */
}

.page-jackpot-games__btn-primary {
  background: var(--hello88-button-gradient-start); /* Fallback for gradient */
  background: linear-gradient(180deg, var(--hello88-button-gradient-start) 0%, var(--hello88-button-gradient-end) 100%);
  color: var(--hello88-text-main);
  border: none;
  box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-jackpot-games__btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

.page-jackpot-games__btn-secondary {
  background-color: transparent;
  color: var(--hello88-secondary);
  border: 2px solid var(--hello88-secondary);
}

.page-jackpot-games__btn-secondary:hover {
  background-color: var(--hello88-secondary);
  color: var(--hello88-text-main);
}

.page-jackpot-games__btn-small {
  padding: 10px 20px;
  font-size: 0.95rem;
  background: linear-gradient(180deg, var(--hello88-button-gradient-start) 0%, var(--hello88-button-gradient-end) 100%);
  color: var(--hello88-text-main);
  border: none;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(42, 209, 111, 0.3);
}

.page-jackpot-games__btn-small:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(42, 209, 111, 0.5);
}

/* General Section Styles */
.page-jackpot-games__section-title {
  font-size: 2.5rem;
  color: var(--hello88-gold);
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
  line-height: 1.3;
}

.page-jackpot-games__sub-title {
  font-size: 1.8rem;
  color: var(--hello88-secondary);
  margin-bottom: 20px;
  font-weight: bold;
}

.page-jackpot-games__description-text,
.page-jackpot-games__text-block {
  font-size: 1.1rem;
  color: var(--hello88-text-secondary);
  text-align: center;
  max-width: 900px;
  margin: 0 auto 30px auto;
}

.page-jackpot-games__text-block {
  text-align: left;
  margin-bottom: 20px;
}

.page-jackpot-games__note-text {
  font-style: italic;
  font-size: 1rem;
  color: var(--hello88-text-secondary);
  text-align: center;
  margin-top: 30px;
}

/* Dark background sections */
.page-jackpot-games__dark-section {
  background-color: var(--hello88-deep-green); /* Use deep green for dark sections */
  padding: 80px 0;
  color: var(--hello88-text-main);
}

.page-jackpot-games__dark-section .page-jackpot-games__section-title {
  color: var(--hello88-gold);
}

.page-jackpot-games__dark-section .page-jackpot-games__sub-title {
  color: var(--hello88-secondary);
}

.page-jackpot-games__dark-section .page-jackpot-games__description-text,
.page-jackpot-games__dark-section .page-jackpot-games__text-block,
.page-jackpot-games__dark-section .page-jackpot-games__note-text {
  color: var(--hello88-text-secondary);
}

/* Image and Text Layout */
.page-jackpot-games__image-and-text {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-top: 40px;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.page-jackpot-games__content-image {
  flex: 1;
  min-width: 300px; /* Minimum width for image before wrapping */
  width: 100%; /* Default width for image */
  height: auto;
  display: block;
  border-radius: 10px;
  object-fit: cover;
}

.page-jackpot-games__text-content {
  flex: 2;
  min-width: 300px; /* Minimum width for text before wrapping */
}

.page-jackpot-games__list {
  list-style: none;
  padding-left: 0;
  margin-top: 20px;
}

.page-jackpot-games__list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 15px;
  font-size: 1.1rem;
  color: var(--hello88-text-main);
}

.page-jackpot-games__list li::before {
  content: '✅';
  position: absolute;
  left: 0;
  color: var(--hello88-secondary);
  font-size: 1.2em;
  line-height: 1;
}

/* Game Grid Showcase */
.page-jackpot-games__games-showcase {
  padding: 80px 0;
}

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

.page-jackpot-games__game-card,
.page-jackpot-games__promo-card,
.page-jackpot-games__step-card {
  background-color: var(--hello88-card-bg);
  border: 1px solid var(--hello88-border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-jackpot-games__game-card:hover,
.page-jackpot-games__promo-card:hover,
.page-jackpot-games__step-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.3);
}

.page-jackpot-games__card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
  border-bottom: 1px solid var(--hello88-divider);
}

.page-jackpot-games__card-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--hello88-gold);
  margin: 20px 20px 10px 20px;
  text-align: center;
}

.page-jackpot-games__card-title a {
  color: var(--hello88-gold);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-jackpot-games__card-title a:hover {
  color: var(--hello88-glow);
}

.page-jackpot-games__card-description {
  font-size: 0.95rem;
  color: var(--hello88-text-secondary);
  padding: 0 20px;
  margin-bottom: 20px;
  flex-grow: 1; /* Make description take available space */
  text-align: center;
}

.page-jackpot-games__game-card .page-jackpot-games__btn-small,
.page-jackpot-games__promo-card .page-jackpot-games__btn-small,
.page-jackpot-games__step-card .page-jackpot-games__btn-small {
  margin: 0 20px 20px 20px;
  width: calc(100% - 40px);
  text-align: center;
}

.page-jackpot-games__cta-center {
  text-align: center;
  margin-top: 50px;
}

/* How to Play Section */
.page-jackpot-games__how-to-play {
  padding: 80px 0;
}

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

.page-jackpot-games__step-card {
  text-align: center;
}

.page-jackpot-games__step-icon {
  width: 60px;
  height: 60px;
  background-color: var(--hello88-secondary);
  color: var(--hello88-text-main);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: bold;
  margin: 0 auto 20px auto;
  box-shadow: 0 0 15px var(--hello88-secondary);
}

/* Promotions Section */
.page-jackpot-games__promotions {
  padding: 80px 0;
}

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

/* FAQ Section */
.page-jackpot-games__faq-section {
  padding: 80px 0;
}

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

.page-jackpot-games__faq-item {
  background-color: var(--hello88-card-bg);
  border: 1px solid var(--hello88-border);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.page-jackpot-games__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.15rem;
  font-weight: bold;
  color: var(--hello88-text-main);
  cursor: pointer;
  background-color: var(--hello88-deep-green);
  border-bottom: 1px solid var(--hello88-divider);
  transition: background-color 0.3s ease;
  list-style: none; /* For details/summary */
}

.page-jackpot-games__faq-question::-webkit-details-marker {
  display: none; /* Hide default marker for Chrome */
}

.page-jackpot-games__faq-item[open] .page-jackpot-games__faq-question {
  background-color: var(--hello88-primary);
}

.page-jackpot-games__faq-question:hover {
  background-color: var(--hello88-primary);
}

.page-jackpot-games__faq-toggle {
  font-size: 1.8rem;
  line-height: 1;
  color: var(--hello88-gold);
  transition: transform 0.3s ease;
}

.page-jackpot-games__faq-item[open] .page-jackpot-games__faq-toggle {
  transform: rotate(45deg); /* Rotate plus to form cross */
}

.page-jackpot-games__faq-answer {
  padding: 20px 25px;
  font-size: 1rem;
  color: var(--hello88-text-secondary);
}

.page-jackpot-games__faq-answer p {
  margin-bottom: 0;
  text-align: left;
}


/* Contact CTA Section */
.page-jackpot-games__contact-cta {
  padding: 80px 0;
  text-align: center;
  background: var(--hello88-deep-green);
}

.page-jackpot-games__contact-cta .page-jackpot-games__section-title {
  color: var(--hello88-gold);
}

.page-jackpot-games__contact-cta .page-jackpot-games__description-text {
  color: var(--hello88-text-secondary);
}


/* Responsive Design */
@media (max-width: 1024px) {
  .page-jackpot-games__hero-title {
    font-size: clamp(2rem, 6vw, 3rem);
  }

  .page-jackpot-games__section-title {
    font-size: 2rem;
  }

  .page-jackpot-games__sub-title {
    font-size: 1.6rem;
  }

  .page-jackpot-games__image-and-text {
    flex-direction: column;
    text-align: center;
  }

  .page-jackpot-games__text-content {
    order: 2;
  }

  .page-jackpot-games__content-image {
    order: 1;
    margin-bottom: 30px;
  }
}

@media (max-width: 768px) {
  .page-jackpot-games__hero-section {
    padding-bottom: 40px;
  }

  .page-jackpot-games__hero-title {
    font-size: clamp(1.8rem, 8vw, 2.5rem);
  }

  .page-jackpot-games__hero-description {
    font-size: 1rem;
  }

  .page-jackpot-games__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .page-jackpot-games__btn-primary,
  .page-jackpot-games__btn-secondary,
  .page-jackpot-games__btn-small {
    padding: 12px 20px;
    font-size: 1rem;
    width: 100% !important; /* Force full width on mobile */
    max-width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    margin-left: auto;
    margin-right: auto;
  }

  .page-jackpot-games__section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
  }

  .page-jackpot-games__sub-title {
    font-size: 1.4rem;
  }

  .page-jackpot-games__description-text,
  .page-jackpot-games__text-block,
  .page-jackpot-games__list li {
    font-size: 1rem;
  }

  .page-jackpot-games__dark-section,
  .page-jackpot-games__games-showcase,
  .page-jackpot-games__how-to-play,
  .page-jackpot-games__promotions,
  .page-jackpot-games__faq-section,
  .page-jackpot-games__contact-cta {
    padding: 60px 0;
  }

  .page-jackpot-games__container {
    padding: 0 15px; /* Add padding to containers on mobile */
  }

  /* Mobile image adaptation */
  .page-jackpot-games img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-jackpot-games__section,
  .page-jackpot-games__card,
  .page-jackpot-games__container,
  .page-jackpot-games__hero-image-wrapper,
  .page-jackpot-games__image-and-text,
  .page-jackpot-games__game-grid,
  .page-jackpot-games__promo-grid,
  .page-jackpot-games__steps-grid,
  .page-jackpot-games__faq-list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px; /* Ensure content is not edge-to-edge */
    padding-right: 15px;
  }
  
  .page-jackpot-games__hero-section {
    padding-top: 10px !important; /* body already handles --header-offset */
  }

  .page-jackpot-games__card-image {
    height: 180px; /* Adjust card image height for mobile */
  }

  .page-jackpot-games__faq-question {
    padding: 15px 20px;
    font-size: 1rem;
  }

  .page-jackpot-games__faq-answer {
    padding: 15px 20px;
  }
}