/* style/casino.css */

:root {
  --kbet-primary: #11A84E;
  --kbet-secondary: #22C768;
  --kbet-card-bg: #11271B;
  --kbet-bg: #08160F;
  --kbet-text-main: #F2FFF6;
  --kbet-text-secondary: #A7D9B8;
  --kbet-border: #2E7A4E;
  --kbet-glow: #57E38D;
  --kbet-gold: #F2C14E;
  --kbet-divider: #1E3A2A;
  --kbet-deep-green: #0A4B2C;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

/* Base styles for the casino page */
.page-casino {
  background-color: var(--kbet-bg); /* Dark background from custom palette */
  color: var(--kbet-text-main); /* Light text for dark background */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

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

.page-casino__section-title {
  font-size: 2.5em;
  color: var(--kbet-gold);
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
  line-height: 1.2;
}

.page-casino__text-block {
  font-size: 1.1em;
  color: var(--kbet-text-secondary);
  margin-bottom: 20px;
  text-align: center;
}

/* Hero Section */
.page-casino__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles header offset */
  overflow: hidden;
  background-color: var(--kbet-deep-green);
}

.page-casino__hero-image {
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
  margin-bottom: 30px;
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

.page-casino__hero-content {
  text-align: center;
  max-width: 900px;
  width: 100%;
}

.page-casino__main-title {
  font-size: clamp(2em, 4vw, 3.5em); /* Responsive H1 font size */
  color: var(--kbet-text-main);
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.page-casino__description {
  font-size: 1.2em;
  color: var(--kbet-text-secondary);
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-casino__btn-primary,
.page-casino__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  min-width: 150px;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-casino__btn-primary {
  background: var(--button-gradient);
  color: #ffffff; /* White text for contrast */
  border: 2px solid transparent;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-casino__btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  opacity: 0.9;
}

.page-casino__btn-secondary {
  background: transparent;
  color: var(--kbet-primary); /* Brand color for text */
  border: 2px solid var(--kbet-primary);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-casino__btn-secondary:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  background: rgba(var(--kbet-primary), 0.1);
}

/* Introduction Section */
.page-casino__introduction-section {
  padding: 60px 0;
  background-color: var(--kbet-bg);
}

/* Games Section */
.page-casino__games-section {
  padding: 60px 0;
  background-color: var(--kbet-deep-green);
}

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

.page-casino__card {
  background-color: var(--kbet-card-bg); /* Card background from custom palette */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  text-align: center;
  padding-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  border: 1px solid var(--kbet-border);
}

.page-casino__card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  margin-bottom: 15px;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  display: block;
}

.page-casino__card-title {
  font-size: 1.5em;
  color: var(--kbet-gold);
  margin-bottom: 10px;
  font-weight: bold;
}

.page-casino__card-link {
  color: inherit;
  text-decoration: none;
}

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

.page-casino__card-text {
  color: var(--kbet-text-secondary);
  padding: 0 20px;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-casino__card-button {
  margin-top: auto; /* Push button to bottom */
}

/* Live Section */
.page-casino__live-section {
  padding: 60px 0;
  background-color: var(--kbet-bg);
}

.page-casino__image-full-width {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

/* Promotions Section */
.page-casino__promotions-section {
  padding: 60px 0;
  background-color: var(--kbet-deep-green);
}

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

.page-casino__cta-buttons--center {
  margin-top: 40px;
}

/* Security Section */
.page-casino__security-section {
  padding: 60px 0;
  background-color: var(--kbet-bg);
}

/* FAQ Section */
.page-casino__faq-section {
  padding: 60px 0;
  background-color: var(--kbet-deep-green);
}

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

.page-casino__faq-item {
  background-color: var(--kbet-card-bg);
  border: 1px solid var(--kbet-border);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: var(--kbet-text-main);
}

.page-casino__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.2em;
  font-weight: bold;
  cursor: pointer;
  background-color: var(--kbet-deep-green);
  color: var(--kbet-text-main);
  border-bottom: 1px solid var(--kbet-border);
}

.page-casino__faq-question::-webkit-details-marker {
  display: none; /* Hide default marker for details summary */
}

.page-casino__faq-question::marker {
  display: none; /* Hide default marker for details summary */
}

.page-casino__faq-qtext {
  flex-grow: 1;
}

.page-casino__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  transition: transform 0.3s ease;
}

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

.page-casino__faq-answer {
  padding: 20px;
  font-size: 1.05em;
  color: var(--kbet-text-secondary);
  background-color: var(--kbet-card-bg);
}

/* Call to Action Bottom Section */
.page-casino__cta-bottom-section {
  padding: 60px 0;
  background-color: var(--kbet-deep-green);
  text-align: center;
}

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

/* Responsive styles */
@media (max-width: 768px) {
  .page-casino {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-casino__container,
  .page-casino__hero-section,
  .page-casino__introduction-section,
  .page-casino__games-section,
  .page-casino__live-section,
  .page-casino__promotions-section,
  .page-casino__security-section,
  .page-casino__faq-section,
  .page-casino__cta-bottom-section {
    padding-left: 15px !important;
    padding-right: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-casino__hero-section {
    padding-top: 10px !important;
    padding-bottom: 40px !important;
  }

  .page-casino__main-title {
    font-size: clamp(1.8em, 8vw, 2.5em);
  }

  .page-casino__description {
    font-size: 1em;
  }

  .page-casino__section-title {
    font-size: 2em;
    margin-bottom: 30px;
  }

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

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

  .page-casino__btn-primary,
  .page-casino__btn-secondary,
  .page-casino a[class*="button"],
  .page-casino a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

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

  .page-casino__card-image,
  .page-casino__image-full-width {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-casino__faq-question {
    font-size: 1.1em;
    padding: 15px;
  }

  .page-casino__faq-answer {
    font-size: 0.95em;
    padding: 15px;
  }
}

/* Ensure images in content areas are not too small */
.page-casino img:not(.page-casino__hero-image) {
  min-width: 200px;
  min-height: 200px;
}

/* Specific override for any img under .page-casino to ensure minimum size */
.page-casino img {
  /* This rule applies to all images within .page-casino, ensuring they are not too small */
  /* It's a fallback to ensure no image is rendered smaller than 200px by CSS rules */
  /* Actual displayed size will be determined by layout and max-width: 100% */
  min-width: 200px;
  min-height: 200px;
  object-fit: cover;
}

/* Ensure CSS width/height for images does not contradict HTML attributes, use auto for height if max-width is 100% */
.page-casino img[width][height] {
  /* Prevent CSS from overriding explicit HTML width/height if it results in smaller than 200px */
  /* This is a general rule, specific elements might need more tailored responsive handling */
  width: auto;
  height: auto;
}

/* Contrast fixes for safety */
.page-casino p, .page-casino li {
  color: var(--kbet-text-secondary);
}

.page-casino h1, .page-casino h2, .page-casino h3, .page-casino h4, .page-casino h5, .page-casino h6 {
  color: var(--kbet-text-main);
}

.page-casino__card .page-casino__card-title a {
  color: var(--kbet-gold);
}

.page-casino__faq-question .page-casino__faq-qtext {
  color: var(--kbet-text-main);
}

.page-casino__faq-answer {
  color: var(--kbet-text-secondary);
}