/* style/lottery.css */

/* --- Base Styles --- */
.page-lottery {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: var(--dark-bg-1); /* Inherited from shared.css */
}

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

.page-lottery__section-title {
  font-size: 2.5em;
  color: #ffffff;
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
}

.page-lottery__text-block {
  font-size: 1.1em;
  color: #f0f0f0;
  margin-bottom: 20px;
  text-align: justify;
}

.page-lottery__text-center {
  text-align: center;
}

/* --- Hero Section --- */
.page-lottery__hero-section {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 600px;
  overflow: hidden;
  padding-top: var(--header-offset, 120px); /* Fixed header offset */
  background-color: #017439; /* Fallback for image */
}

.page-lottery__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.page-lottery__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6); /* Dark overlay for text readability */
  z-index: 2;
}

.page-lottery__hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  max-width: 900px;
  padding: 20px;
  color: #ffffff;
}

.page-lottery__hero-title {
  font-size: 3.5em;
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: bold;
  color: #ffffff;
}

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

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

/* --- Buttons --- */
.page-lottery__btn-primary,
.page-lottery__btn-secondary,
.page-lottery__card-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  box-sizing: border-box;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
}

.page-lottery__btn-primary {
  background-color: #C30808; /* Custom color for Register/Login type buttons */
  color: #ffffff; /* Adjusted for WCAG AA contrast against #C30808 */
  border: 2px solid #C30808;
}

.page-lottery__btn-primary:hover {
  background-color: #e02a2a;
  border-color: #e02a2a;
}

.page-lottery__btn-secondary {
  background-color: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

.page-lottery__btn-secondary:hover {
  background-color: #ffffff;
  color: #017439;
}

.page-lottery__card-button {
  background-color: #017439;
  color: #ffffff;
  border: 2px solid #017439;
  padding: 10px 20px;
  font-size: 0.9em;
}

.page-lottery__card-button:hover {
  background-color: #005a2e;
  border-color: #005a2e;
}

/* --- Sections --- */
.page-lottery__introduction,
.page-lottery__why-choose,
.page-lottery__tips-strategies,
.page-lottery__faq {
  padding: 80px 0;
}

.page-lottery__lottery-types,
.page-lottery__how-to-play,
.page-lottery__promotions,
.page-lottery__cta-final {
  padding: 80px 0;
  background-color: #017439; /* Primary brand color for dark sections */
}

.page-lottery__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-lottery__light-bg .page-lottery__section-title,
.page-lottery__light-bg .page-lottery__text-block,
.page-lottery__light-bg .page-lottery__card-title,
.page-lottery__light-bg .page-lottery__card-description,
.page-lottery__light-bg .page-lottery__feature-title,
.page-lottery__light-bg .page-lottery__feature-description,
.page-lottery__light-bg .page-lottery__step-title,
.page-lottery__light-bg .page-lottery__step-item,
.page-lottery__light-bg .page-lottery__list-item,
.page-lottery__light-bg .page-lottery__faq-qtext,
.page-lottery__light-bg .page-lottery__faq-answer p {
  color: #333333;
}

.page-lottery__light-bg .page-lottery__btn-secondary {
  color: #017439;
  border-color: #017439;
}

.page-lottery__light-bg .page-lottery__btn-secondary:hover {
  background-color: #017439;
  color: #ffffff;
}

.page-lottery__dark-bg {
  background-color: #017439;
  color: #ffffff;
}

.page-lottery__dark-bg .page-lottery__section-title,
.page-lottery__dark-bg .page-lottery__text-block,
.page-lottery__dark-bg .page-lottery__card-title,
.page-lottery__dark-bg .page-lottery__card-description,
.page-lottery__dark-bg .page-lottery__feature-title,
.page-lottery__dark-bg .page-lottery__feature-description,
.page-lottery__dark-bg .page-lottery__step-title,
.page-lottery__dark-bg .page-lottery__step-item,
.page-lottery__dark-bg .page-lottery__list-item,
.page-lottery__dark-bg .page-lottery__faq-qtext,
.page-lottery__dark-bg .page-lottery__faq-answer p {
  color: #ffffff;
}

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

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

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

.page-lottery__card-title {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: #017439;
  font-weight: bold;
}

.page-lottery__card-description {
  font-size: 1em;
  color: #555555;
  margin-bottom: 20px;
  flex-grow: 1;
}

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

.page-lottery__feature-item {
  background-color: #f9f9f9;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-lottery__feature-icon {
  width: 80px;
  height: 80px;
  margin-bottom: 20px;
  object-fit: contain;
}

.page-lottery__feature-title {
  font-size: 1.3em;
  color: #017439;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-lottery__feature-description {
  font-size: 0.95em;
  color: #555555;
}

.page-lottery__step-list {
  list-style: none;
  padding: 0;
  margin-top: 40px;
}

.page-lottery__step-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-left: 5px solid #C30808;
  padding: 20px 30px;
  margin-bottom: 20px;
  border-radius: 8px;
  color: #ffffff;
}

.page-lottery__step-title {
  font-size: 1.4em;
  color: #ffffff;
  margin-bottom: 10px;
}

.page-lottery__step-item p {
  color: #f0f0f0;
}

.page-lottery__tips-list,
.page-lottery__promo-list {
  list-style: none;
  padding: 0;
  margin-top: 30px;
}

.page-lottery__list-item {
  background-color: #f9f9f9;
  padding: 15px 20px;
  margin-bottom: 10px;
  border-radius: 8px;
  font-size: 1em;
  color: #333333;
  border-left: 4px solid #017439;
}

.page-lottery__promo-image {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 30px auto 40px auto;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

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

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

.page-lottery__faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.1em;
  font-weight: bold;
  cursor: pointer;
  outline: none;
  color: #017439;
  list-style: none; /* Hide default marker */
}

.page-lottery__faq-item summary::-webkit-details-marker {
  display: none; /* Hide default marker for webkit browsers */
}

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

.page-lottery__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  color: #C30808; /* Use accent color for toggle */
}

.page-lottery__faq-answer {
  padding: 0 25px 20px 25px;
  font-size: 1em;
  color: #555555;
}

.page-lottery__faq-answer p {
  margin-bottom: 0;
  color: #555555; /* Ensure text color for answer */
}

.page-lottery__support-cta {
  margin-top: 50px;
}

/* --- Final CTA --- */
.page-lottery__cta-final {
  padding: 80px 0;
  text-align: center;
}

.page-lottery__cta-final .page-lottery__section-title {
  margin-bottom: 20px;
}

.page-lottery__cta-final .page-lottery__text-block {
  max-width: 800px;
  margin: 0 auto 40px auto;
}

.page-lottery__button-group {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow wrapping for multiple buttons */
}

/* --- Image specific styles (Global for page-lottery) --- */
.page-lottery img {
  max-width: 100%;
  height: auto;
  display: block;
}

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

@media (max-width: 768px) {
  .page-lottery__hero-section {
    min-height: 500px;
    padding-top: var(--header-offset, 120px) !important; /* Ensure mobile offset */
  }
  .page-lottery__hero-title {
    font-size: 2.2em;
  }
  .page-lottery__hero-description {
    font-size: 1em;
  }
  .page-lottery__hero-cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-lottery__btn-primary,
  .page-lottery__btn-secondary,
  .page-lottery__card-button {
    width: 100%;
    max-width: 100% !important;
    padding: 12px 20px;
  }

  .page-lottery__section-title {
    font-size: 1.8em;
  }
  .page-lottery__text-block {
    font-size: 0.95em;
  }

  .page-lottery__introduction,
  .page-lottery__why-choose,
  .page-lottery__tips-strategies,
  .page-lottery__faq,
  .page-lottery__lottery-types,
  .page-lottery__how-to-play,
  .page-lottery__promotions,
  .page-lottery__cta-final {
    padding: 60px 0;
  }

  .page-lottery__container {
    padding: 0 15px; /* Add side padding for mobile */
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  /* Mobile image responsiveness */
  .page-lottery img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  /* All containers with images/content */
  .page-lottery__section,
  .page-lottery__card,
  .page-lottery__container,
  .page-lottery__grid,
  .page-lottery__feature-grid,
  .page-lottery__step-list,
  .page-lottery__tips-list,
  .page-lottery__promo-list,
  .page-lottery__faq-list,
  .page-lottery__button-group {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important; /* Prevent horizontal scroll */
  }

  /* Specific card image handling for smaller screens if needed */
  .page-lottery__card-image {
    height: auto; /* Allow height to adjust naturally */
    min-height: 200px; /* Enforce minimum size */
  }

  /* FAQ toggle for mobile */
  .page-lottery__faq-item summary {
    padding: 15px 20px;
    font-size: 1em;
  }
  .page-lottery__faq-answer {
    padding: 0 20px 15px 20px;
  }
}

@media (max-width: 480px) {
  .page-lottery__hero-title {
    font-size: 1.8em;
  }
  .page-lottery__hero-description {
    font-size: 0.9em;
  }
  .page-lottery__section-title {
    font-size: 1.5em;
  }
  .page-lottery__btn-primary,
  .page-lottery__btn-secondary {
    font-size: 0.9em;
    padding: 10px 15px;
  }
  .page-lottery__card {
    padding: 20px;
  }
  .page-lottery__card-title {
    font-size: 1.3em;
  }
  .page-lottery__feature-item {
    padding: 20px;
  }
}

/* Contrast Fixes - Ensure these are applied if needed */
.page-lottery__contrast-fix {
  background: #ffffff !important;
  color: #333333 !important;
  border: 1px solid #e0e0e0 !important;
}

.page-lottery__text-contrast-fix {
  color: #333333 !important;
  text-shadow: none !important;
}