/* style/casino.css */
/* BEM Naming: page-casino__element-name */
/* Color Palette: #26A9E0 (Primary), #FFFFFF (Secondary), #EA7C07 (Login/Accent), #000000 (Text) */
/* Body background is var(--black-color) from shared.css, so text should be light by default */

.page-casino {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: transparent; /* Body background from shared.css */
}

/* Fixed header offset for main content */
.page-casino__hero-section {
  position: relative;
  padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 70vh; /* Adjust as needed */
  background-color: rgba(0, 0, 0, 0.7); /* Overlay for hero image */
  overflow: hidden;
}

.page-casino__hero-image-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.page-casino__hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.6); /* Slightly darken image for text readability */
}

.page-casino__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 20px;
}

.page-casino__hero-title {
  font-size: 3.5em;
  color: #FFFFFF;
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-casino__hero-description {
  font-size: 1.3em;
  color: #f0f0f0;
  margin-bottom: 30px;
}

.page-casino__hero-cta {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

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

.page-casino__section-title {
  font-size: 2.5em;
  color: #26A9E0;
  text-align: center;
  margin-bottom: 30px;
  font-weight: bold;
}

.page-casino__text-block {
  font-size: 1.1em;
  margin-bottom: 20px;
  text-align: center;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: #f0f0f0; /* Default for dark background */
}

.page-casino__about-section,
.page-casino__promotions-section,
.page-casino__payment-section,
.page-casino__cta-section {
  padding: 60px 0;
}

.page-casino__dark-bg {
  background-color: #000000; /* Use black background for contrast */
  color: #ffffff;
}

/* Buttons */
.page-casino__btn-primary,
.page-casino__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box; /* Crucial for responsive buttons */
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
}

.page-casino__btn-primary {
  background-color: #26A9E0;
  color: #FFFFFF;
  border: 2px solid #26A9E0;
}

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

.page-casino__btn-secondary {
  background-color: transparent;
  color: #26A9E0;
  border: 2px solid #26A9E0;
}

.page-casino__btn-secondary:hover {
  background-color: #26A9E0;
  color: #FFFFFF;
}

.page-casino__btn-text {
    display: inline-block;
    color: #26A9E0;
    text-decoration: none;
    font-weight: bold;
    margin-top: 15px;
    transition: color 0.3s ease;
}

.page-casino__btn-text:hover {
    color: #1a7fb3;
    text-decoration: underline;
}

.page-casino__button-group {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  flex-wrap: wrap; /* Ensure buttons wrap on smaller screens */
}

.page-casino__button-group--center {
  margin-top: 40px;
}

/* Video section */
.page-casino__video-section {
  padding: 60px 0;
  background-color: #0d0d0d; /* Slightly different dark background */
}

.page-casino__video-wrapper {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  background-color: #000;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  cursor: pointer;
}

.page-casino__video-link {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block; /* Make the whole area clickable */
}

.page-casino__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
}

/* Game Grid */
.page-casino__games-section {
  padding: 60px 0;
  background-color: #1a1a1a;
}

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

.page-casino__game-card {
  background-color: #262626;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-casino__game-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  margin-bottom: 15px;
}

.page-casino__card-title {
  font-size: 1.5em;
  color: #26A9E0;
  margin-bottom: 10px;
  padding: 0 15px;
}

.page-casino__card-title a {
    color: #26A9E0;
    text-decoration: none;
}

.page-casino__card-title a:hover {
    text-decoration: underline;
}

.page-casino__card-description {
  font-size: 0.95em;
  color: #cccccc;
  padding: 0 15px;
  margin-bottom: 15px;
  flex-grow: 1; /* Allows description to take available space */
}

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

.page-casino__promotion-card {
  background-color: #262626;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-casino__promotion-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  margin-bottom: 15px;
}

/* Security Section */
.page-casino__security-section {
  padding: 60px 0;
  background-color: #0d0d0d;
}

/* Payment Section */
.page-casino__payment-icons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 30px;
  margin-top: 40px;
  margin-bottom: 40px;
}

.page-casino__payment-icon {
  width: 150px; /* Adjust size as needed */
  height: auto;
  object-fit: contain;
  filter: grayscale(100%) brightness(1.8); /* Make icons light for dark background */
}

/* FAQ Section */
.page-casino__faq-section {
  padding: 60px 0;
  background-color: #1a1a1a;
}

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

.page-casino__faq-item {
  background-color: #262626;
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-casino__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  cursor: pointer;
  background-color: #262626;
  color: #FFFFFF;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-casino__faq-question:hover {
  background-color: #333333;
}

.page-casino__faq-title {
  font-size: 1.2em;
  margin: 0;
  color: #FFFFFF;
}

.page-casino__faq-toggle {
  font-size: 1.8em;
  line-height: 1;
  transition: transform 0.3s ease;
  color: #26A9E0;
}

.page-casino__faq-item.active .page-casino__faq-toggle {
  transform: rotate(45deg);
}

.page-casino__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background-color: #333333;
  color: #cccccc;
}

.page-casino__faq-item.active .page-casino__faq-answer {
  max-height: 1000px !important; /* Sufficiently large to show content */
  padding: 20px !important;
}

.page-casino__faq-answer p {
  margin: 0;
  color: #cccccc;
}

/* CTA Section */
.page-casino__cta-section {
  padding: 80px 0;
  background-image: url('[GALLERY:cta_bg:1920x400:lucky8 casino,online gambling,luxury,abstract,blue,white]');
  background-size: cover;
  background-position: center;
  background-color: #26A9E0; /* Fallback */
  text-align: center;
}

.page-casino__cta-content {
  max-width: 800px;
}

.page-casino__cta-section .page-casino__section-title {
  color: #FFFFFF;
}

.page-casino__cta-section .page-casino__text-block {
  color: #f0f0f0;
}

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

@media (max-width: 768px) {
  .page-casino__hero-section {
    padding-top: var(--header-offset, 120px) !important; /* Reapply for mobile */
    min-height: 60vh;
  }

  .page-casino__hero-title {
    font-size: 2.5em;
  }

  .page-casino__hero-description {
    font-size: 1.1em;
  }

  .page-casino__hero-cta {
    flex-direction: column;
    gap: 15px;
  }

  .page-casino__btn-primary,
  .page-casino__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    padding: 12px 20px;
    font-size: 1em;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-casino__button-group {
    flex-direction: column;
    gap: 15px;
  }

  .page-casino__container {
    padding: 30px 15px;
  }

  .page-casino__section-title {
    font-size: 1.8em;
    margin-bottom: 20px;
  }

  .page-casino__text-block {
    font-size: 1em;
  }

  /* Images and Videos Responsive */
  .page-casino img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-casino video,
  .page-casino__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-casino__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0;
    padding-right: 0;
    overflow: hidden !important;
  }

  .page-casino__game-grid,
  .page-casino__promotion-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-casino__faq-item,
  .page-casino__game-card,
  .page-casino__promotion-card,
  .page-casino__cta-section .page-casino__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  
  .page-casino__faq-answer {
    padding: 15px !important; /* Adjust padding for mobile */
  }

  .page-casino__payment-icons {
    gap: 15px;
  }

  .page-casino__payment-icon {
    width: 120px;
  }
}

/* Ensure content area does not cause horizontal scroll */
.page-casino {
    overflow-x: hidden;
}

/* Global image/video container rules for mobile overflow prevention */
.page-casino__section,
.page-casino__card,
.page-casino__container,
.page-casino__video-section,
.page-casino__video-container,
.page-casino__video-wrapper,
.page-casino__cta-buttons,
.page-casino__button-group,
.page-casino__btn-container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden; /* Prevent content inside from overflowing */
}

/* Specific button styles for login/register if needed, using custom color #EA7C07 */
.page-casino__btn-login {
  background-color: #EA7C07;
  color: #FFFFFF;
  border: 2px solid #EA7C07;
}

.page-casino__btn-login:hover {
  background-color: #d16e06;
  border-color: #d16e06;
}

/* Color contrast fixes - already handled by dark background default text */
/* If any specific element needs a contrast fix, it would be added here */
.page-casino__light-bg .page-casino__text-block,
.page-casino__light-bg .page-casino__card-description {
    color: #333333; /* For sections with explicit light backgrounds */
}