/* Base Styles */
.page-download {
  color: var(--Text-Main); /* #F3F8FF for dark body background */
  background-color: var(--Deep-Navy); /* #08162B */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

.page-download__container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 15px;
  box-sizing: border-box;
}

.page-download__section {
  padding: 40px 0;
  text-align: center;
}

.page-download__section-title {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 30px;
  color: var(--Gold); /* #F2C14E */
}

/* Hero Section */
.page-download__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 10px; /* Small top padding, body handles header offset */
  padding-bottom: 40px;
  background-color: var(--Deep-Navy);
}

.page-download__hero-image-wrapper {
  width: 100%;
  max-width: 1200px;
  margin-bottom: 30px;
  border-radius: 10px;
  overflow: hidden;
}

.page-download__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.page-download__hero-content {
  max-width: 800px;
  padding: 0 15px;
}

.page-download__main-title {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 800;
  color: var(--Gold); /* #F2C14E */
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-download__intro-text {
  font-size: 18px;
  color: var(--Text-Secondary); /* #AFC4E8 */
  margin-bottom: 30px;
}

/* CTA Buttons */
.page-download__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 18px;
  transition: all 0.3s ease;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-download__cta-button--primary {
  background: linear-gradient(180deg, #2B73F6 0%, #1144A6 100%);
  color: #ffffff;
  border: none;
}

.page-download__cta-button--primary:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
}

.page-download__cta-button--secondary {
  background: var(--Card-B-G); /* #10233F */
  color: var(--Text-Main); /* #F3F8FF */
  border: 2px solid var(--Border); /* #244D84 */
  margin-left: 15px;
}

.page-download__cta-button--secondary:hover {
  background: var(--Border);
  transform: translateY(-2px);
}

.page-download__cta-buttons-group {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

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

.page-download__benefit-card {
  background: var(--Card-B-G); /* #10233F */
  padding: 25px;
  border-radius: 10px;
  text-align: center;
  border: 1px solid var(--Border);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-download__benefit-icon {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin-bottom: 20px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.page-download__benefit-title {
  font-size: 22px;
  color: var(--Gold); /* #F2C14E */
  margin-bottom: 10px;
}

.page-download__benefit-description {
  font-size: 16px;
  color: var(--Text-Secondary); /* #AFC4E8 */
}

/* Download Steps Section */
.page-download__dark-section {
  background-color: var(--Card-B-G); /* #10233F */
  color: var(--Text-Main); /* #F3F8FF */
}

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

.page-download__step-item {
  background: var(--Deep-Navy); /* #08162B */
  padding: 30px;
  border-radius: 10px;
  text-align: left;
  border: 1px solid var(--Border);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.page-download__step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--Gold); /* #F2C14E */
  color: var(--Deep-Navy);
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
}

.page-download__step-title {
  font-size: 20px;
  color: var(--Text-Main); /* #F3F8FF */
  margin-bottom: 10px;
}

.page-download__step-description {
  font-size: 16px;
  color: var(--Text-Secondary); /* #AFC4E8 */
}

.page-download__step-image {
  width: 100%;
  height: auto;
  display: block;
  margin-top: 20px;
  border-radius: 8px;
  object-fit: cover;
}

.page-download__cta-wrapper {
  margin-top: 40px;
}

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

.page-download__feature-card {
  background: var(--Card-B-G); /* #10233F */
  padding: 25px;
  border-radius: 10px;
  text-align: center;
  border: 1px solid var(--Border);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-download__feature-icon {
  width: 120px;
  height: 120px;
  object-fit: contain;
  margin-bottom: 20px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.page-download__feature-title {
  font-size: 22px;
  color: var(--Gold); /* #F2C14E */
  margin-bottom: 10px;
}

.page-download__feature-description {
  font-size: 16px;
  color: var(--Text-Secondary); /* #AFC4E8 */
}

/* FAQ Section */
details.page-download__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  border: 1px solid var(--Border);
  overflow: hidden;
  background: var(--Deep-Navy);
}
details.page-download__faq-item summary.page-download__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}
details.page-download__faq-item summary.page-download__faq-question::-webkit-details-marker {
  display: none;
}
details.page-download__faq-item summary.page-download__faq-question:hover {
  background: var(--Card-B-G);
}
.page-download__faq-qtext {
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: var(--Text-Main);
}
.page-download__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: var(--Gold);
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}
details.page-download__faq-item .page-download__faq-answer {
  padding: 0 20px 20px;
  background: var(--Card-B-G);
  border-radius: 0 0 5px 5px;
  color: var(--Text-Secondary);
  text-align: left;
}

/* Final CTA Section */
.page-download__cta-description {
  font-size: 18px;
  color: var(--Text-Secondary);
  margin-bottom: 30px;
}

/* Copyright */
.page-download__copyright-info {
    text-align: center;
    padding: 20px 15px;
    font-size: 14px;
    color: var(--Text-Secondary);
    background-color: var(--Card-B-G);
    margin-top: 40px;
}

/* Responsive Styles */
@media (max-width: 1023px) {
  /* Homepage trial layout specific styles - included as per strict requirement */
  .page-download__home-hero {
    display: block !important;
    grid-template-columns: none !important;
    height: auto !important;
    max-height: none !important;
    overflow-x: hidden;
    box-sizing: border-box;
  }
  .page-download__hero-brand,
  .page-download__hero-jackpot {
    display: none !important;
  }
  .page-download__game-trial {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: none !important;
    overflow: hidden !important;
    margin: 0 auto;
    padding: 0 0 12px !important;
    box-sizing: border-box;
  }
  .page-download__game-trial-shell {
    height: auto !important;
    max-height: none !important;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-download__game-trial-topbar,
  .page-download__game-trial-bottombar {
    display: none !important;
  }
  .page-download__game-trial-viewport {
    position: relative;
    width: 100%;
    aspect-ratio: 1024 / 768;
    flex: none !important;
    min-height: 240px;
    max-height: none !important;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-download__game-trial-frame {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    max-height: none !important;
    max-width: 100%;
    border: none;
    z-index: 1;
    overflow: hidden;
  }
  .page-download__game-trial-overlay {
    z-index: 5 !important;
    pointer-events: auto !important;
  }
  .page-download__game-trial-start {
    z-index: 6 !important;
    pointer-events: auto !important;
    touch-action: manipulation;
  }
}

@media (min-width: 1024px) {
  /* Homepage trial layout specific styles - included as per strict requirement */
  .page-download__home-hero {
    display: grid;
    grid-template-columns: 26% 48% 26%;
    gap: 16px;
    align-items: stretch;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 10px 16px 24px;
    box-sizing: border-box;
  }
  .page-download__hero-brand,
  .page-download__hero-jackpot,
  .page-download__game-trial {
    height: 300px;
    max-height: 300px;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-download__game-trial {
    max-width: none !important;
    width: 100%;
    margin: 0;
    padding: 0;
  }
  .page-download__game-trial-shell {
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 300px;
    box-sizing: border-box;
  }
  .page-download__game-trial-viewport {
    flex: 1;
    min-height: 0;
    position: relative;
    width: 100%;
  }
  .page-download__game-trial-frame {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    border: none;
  }
  .page-download__hero-jackpot-claim {
    background: #c62828 !important;
    color: #fff !important;
  }
  /* Placeholder for other homepage modules if they existed */
  .page-download__promo-strip { margin-top: 16px; /* Example */ }
}

@media (max-width: 768px) {
  .page-download__container,
  .page-download__hero-content,
  .page-download__cta-buttons-group {
    padding-left: 15px !important;
    padding-right: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-download__section-title {
    font-size: 28px;
    margin-bottom: 20px;
  }

  .page-download__main-title {
    font-size: clamp(24px, 7vw, 36px);
  }

  .page-download__intro-text {
    font-size: 16px;
  }

  .page-download__cta-button {
    max-width: 100% !important;
    width: 100% !important;
    font-size: 16px;
    padding: 12px 20px;
    white-space: normal !important;
    word-wrap: break-word !important;
  }
  
  .page-download__cta-button--secondary {
    margin-left: 0;
    margin-top: 15px;
  }

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

  .page-download img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-download__benefits-grid,
  .page-download__steps-grid,
  .page-download__features-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-download__benefit-title,
  .page-download__step-title,
  .page-download__feature-title {
    font-size: 20px;
  }

  details.page-download__faq-item summary.page-download__faq-question { padding: 15px; }
  .page-download__faq-qtext { font-size: 15px; }
  details.page-download__faq-item .page-download__faq-answer { padding: 0 15px 15px; }

  /* Placeholder for homepage modules if they existed */
  .page-download__promo-strip-track { grid-template-columns: repeat(2, 1fr); overflow-x: hidden; }
  .page-download__hot-games-grid { grid-template-columns: repeat(2, 1fr); }
  /* Ensuring general image/container responsiveness */
  .page-download__section,
  .page-download__card,
  .page-download__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
}

/* Common styles for game trial overlay/start from shared context - included as per strict requirement */
.page-download__game-trial-overlay {
  z-index: 5;
  pointer-events: auto;
}
.page-download__game-trial-overlay.is-hidden {
  display: none !important;
  pointer-events: none !important;
}
.page-download__game-trial-start {
  z-index: 6;
  pointer-events: auto;
  touch-action: manipulation;
}
.page-download__game-trial-shell {
  border: 1px solid rgba(212,175,55,.45);
  border-radius: 10px;
  overflow: hidden;
}
.page-download__reward-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
}
.page-download__reward-modal.is-hidden {
  display: none;
}
.page-download__reward-modal-content {
  background: var(--Card-B-G);
  padding: 30px;
  border-radius: 10px;
  max-width: 500px;
  text-align: center;
  position: relative;
  color: var(--Text-Main);
}
.page-download__reward-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--Text-Secondary);
  cursor: pointer;
}
.page-download__reward-modal-close:hover {
  color: var(--Gold);
}
.page-download__reward-modal h3 {
  color: var(--Gold);
  margin-bottom: 15px;
}
.page-download__reward-modal p {
  color: var(--Text-Secondary);
  margin-bottom: 20px;
}
.page-download__reward-modal .page-download__cta-button {
  margin: 0;
}