/* style/promo.css */

/* Root variables for colors based on the provided scheme */
:root {
  --ah88-primary-color: #F2C14E;
  --ah88-secondary-color: #FFD36B;
  --ah88-card-bg: #111111;
  --ah88-background: #0A0A0A;
  --ah88-text-main: #FFF6D6;
  --ah88-border: #3A2A12;
  --ah88-glow: #FFD36B;
  --ah88-button-gradient: linear-gradient(180deg, #FFD86A 0%, #DDA11D 100%);
}

.page-promo {
  font-family: Arial, sans-serif;
  color: var(--ah88-text-main); /* Default text color for the page */
  background-color: var(--page-bg); /* Inherited from shared.css, typically dark */
  line-height: 1.6;
}

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

/* Section styles */
.page-promo__section {
  padding: 60px 0;
  text-align: center;
}

.page-promo__section-title {
  font-size: clamp(2em, 4vw, 3.2em);
  color: var(--ah88-primary-color);
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: 0.05em;
}

.page-promo__section-description {
  font-size: 1.1em;
  color: var(--ah88-text-main);
  max-width: 900px;
  margin: 0 auto 40px;
}

/* Hero Section */
.page-promo__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 600px; /* Minimum height for hero */
  padding-top: 10px; /* Small top padding, body handles header offset */
  overflow: hidden;
  box-sizing: border-box;
}

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

.page-promo__video-link {
  display: block;
  width: 100%;
  height: 100%;
}

.page-promo__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.05); /* Slight scale to ensure full coverage */
}

.page-promo__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 40px 20px;
  text-align: center;
  background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent overlay for readability */
  border-radius: 10px;
}

.page-promo__main-title {
  font-size: clamp(2.8em, 5vw, 4.5em);
  color: var(--ah88-secondary-color);
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.1;
  letter-spacing: 0.05em;
}

.page-promo__hero-description {
  font-size: 1.3em;
  color: var(--ah88-text-main);
  margin-bottom: 30px;
  line-height: 1.5;
}

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

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

.page-promo__btn-primary {
  background: var(--ah88-button-gradient);
  color: var(--ah88-text-main);
  border: none;
  box-shadow: 0 4px 15px rgba(242, 193, 78, 0.4);
}

.page-promo__btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(242, 193, 78, 0.6);
}

.page-promo__btn-secondary {
  background-color: transparent;
  color: var(--ah88-primary-color);
  border: 2px solid var(--ah88-primary-color);
  box-shadow: 0 4px 15px rgba(242, 193, 78, 0.2);
}

.page-promo__btn-secondary:hover {
  background-color: var(--ah88-primary-color);
  color: #000000; /* Darker text for contrast on hover */
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(242, 193, 78, 0.4);
}

.page-promo__btn-text {
  background: none;
  color: var(--ah88-primary-color);
  border: 1px solid var(--ah88-primary-color);
  padding: 10px 20px;
  font-size: 0.95em;
}

.page-promo__btn-text:hover {
  background-color: var(--ah88-primary-color);
  color: #000000; /* Darker text for contrast on hover */
}

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

.page-promo__promo-card {
  background-color: var(--ah88-card-bg);
  border: 1px solid var(--ah88-border);
  border-radius: 12px;
  overflow: hidden;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-promo__promo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3), 0 0 15px var(--ah88-glow);
}

.page-promo__card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.page-promo__card-content {
  padding: 25px;
}

.page-promo__card-title {
  font-size: 1.5em;
  color: var(--ah88-primary-color);
  margin-bottom: 15px;
  line-height: 1.3;
}

.page-promo__card-text {
  font-size: 1em;
  color: var(--ah88-text-main);
  margin-bottom: 20px;
  line-height: 1.6;
}

/* How to Claim Section */
.page-promo__how-to-claim .page-promo__section-title {
  color: var(--ah88-primary-color);
}

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

.page-promo__step-item {
  background-color: var(--ah88-card-bg);
  border: 1px solid var(--ah88-border);
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-promo__step-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 0 10px var(--ah88-glow);
}

.page-promo__step-icon {
  width: 60px;
  height: 60px;
  background: var(--ah88-button-gradient);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2em;
  font-weight: bold;
  color: #000000; /* Ensure contrast on button gradient */
  margin: 0 auto 20px;
  box-shadow: 0 2px 8px rgba(242, 193, 78, 0.3);
}

.page-promo__step-title {
  font-size: 1.4em;
  color: var(--ah88-primary-color);
  margin-bottom: 10px;
}

.page-promo__step-text {
  font-size: 0.95em;
  color: var(--ah88-text-main);
}

/* Featured Games Section */
.page-promo__featured-games .page-promo__section-title {
  color: var(--ah88-primary-color);
}

.page-promo__game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(167px, 1fr)); /* Fixed width for game images */
  gap: 20px;
  margin-top: 50px;
  justify-content: center;
}

.page-promo__game-card {
  background-color: var(--ah88-card-bg);
  border: 1px solid var(--ah88-border);
  border-radius: 8px;
  padding: 15px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  width: 167px;
  height: auto;
  box-sizing: border-box;
  margin: 0 auto; /* Center individual cards in the grid */
}

.page-promo__game-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2), 0 0 8px var(--ah88-glow);
}

.page-promo__game-thumbnail {
  width: 167px; /* Fixed width as per requirement */
  height: 127px; /* Fixed height as per requirement */
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 10px;
  display: block;
}

.page-promo__game-title {
  font-size: 0.95em;
  color: var(--ah88-text-main);
  font-weight: bold;
}

/* Why ah88 Section */
.page-promo__why-ah88 {
  background-color: var(--ah88-background);
}

.page-promo__why-ah88 .page-promo__section-title {
  color: var(--ah88-secondary-color);
}

.page-promo__why-list {
  list-style: none;
  padding: 0;
  margin-top: 50px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  text-align: left;
}

.page-promo__why-item {
  background-color: var(--ah88-card-bg);
  border: 1px solid var(--ah88-border);
  border-radius: 12px;
  padding: 30px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-promo__why-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 0 10px var(--ah88-glow);
}

.page-promo__why-heading {
  font-size: 1.3em;
  color: var(--ah88-primary-color);
  margin-bottom: 10px;
}

.page-promo__why-text {
  font-size: 0.95em;
  color: var(--ah88-text-main);
}

/* FAQ Section */
.page-promo__faq-section {
  background-color: var(--ah88-background);
}

.page-promo__faq-section .page-promo__section-title {
  color: var(--ah88-primary-color);
}

.page-promo__faq-list {
  max-width: 900px;
  margin: 50px auto 0;
  text-align: left;
}

.page-promo__faq-item {
  background-color: var(--ah88-card-bg);
  border: 1px solid var(--ah88-border);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.page-promo__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  font-size: 1.1em;
  color: var(--ah88-primary-color);
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-promo__faq-question:hover {
  background-color: rgba(242, 193, 78, 0.1);
}

.page-promo__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  color: var(--ah88-secondary-color);
  transition: transform 0.3s ease;
}

.page-promo__faq-item.active .page-promo__faq-toggle {
  transform: rotate(45deg); /* Plus sign becomes 'x' or rotate */
}

.page-promo__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 25px;
  color: var(--ah88-text-main);
  transition: max-height 0.3s ease, padding 0.3s ease;
}

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

.page-promo__faq-answer p {
  margin: 0;
  font-size: 0.95em;
  line-height: 1.6;
}

/* Final CTA Section */
.page-promo__cta-final {
  background-color: var(--ah88-card-bg);
  padding: 80px 0;
}

.page-promo__cta-final .page-promo__section-title {
  color: var(--ah88-secondary-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-promo__hero-description {
    font-size: 1.1em;
  }
  .page-promo__main-title {
    font-size: clamp(2.5em, 4.5vw, 4em);
  }
}

@media (max-width: 768px) {
  .page-promo__section {
    padding: 40px 0;
  }
  .page-promo__section-title {
    font-size: clamp(1.8em, 6vw, 2.5em);
  }
  .page-promo__section-description {
    font-size: 1em;
    margin-bottom: 30px;
  }

  .page-promo__hero-section {
    min-height: 450px;
    padding-top: 10px !important;
  }
  .page-promo__hero-content {
    padding: 20px;
  }
  .page-promo__main-title {
    font-size: clamp(2em, 7vw, 3.5em);
    margin-bottom: 15px;
  }
  .page-promo__hero-description {
    font-size: 0.95em;
    margin-bottom: 20px;
  }
  .page-promo__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100%;
    max-width: 300px; /* Constrain buttons on mobile */
    margin: 0 auto;
    padding: 0 15px;
    box-sizing: border-box;
  }

  .page-promo__btn-primary,
  .page-promo__btn-secondary,
  .page-promo__btn-text,
  .page-promo a[class*="button"],
  .page-promo 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: 12px 20px;
    font-size: 1em;
  }

  .page-promo__promo-grid,
  .page-promo__steps-grid,
  .page-promo__why-list {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 30px;
  }

  .page-promo__card-image {
    height: 180px;
  }
  .page-promo__card-content,
  .page-promo__step-item,
  .page-promo__why-item {
    padding: 20px;
  }
  .page-promo__card-title,
  .page-promo__step-title,
  .page-promo__why-heading {
    font-size: 1.3em;
  }

  .page-promo__game-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
    margin-top: 30px;
  }

  .page-promo__game-card {
    width: 100%; /* Allow cards to fill grid column on mobile */
    max-width: 167px;
    margin: 0 auto;
  }
  .page-promo__game-thumbnail {
    width: 100%;
    height: auto;
    max-width: 167px;
    max-height: 127px;
  }

  .page-promo__faq-question {
    padding: 15px 20px;
    font-size: 1em;
  }
  .page-promo__faq-answer {
    padding: 0 20px;
  }
  .page-promo__faq-item.active .page-promo__faq-answer {
    padding: 10px 20px 20px;
  }

  /* Ensure all images are responsive */
  .page-promo img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-promo__section,
  .page-promo__card,
  .page-promo__container,
  .page-promo__video-wrapper,
  .page-promo__cta-buttons,
  .page-promo__button-group,
  .page-promo__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-promo__video-wrapper {
    padding-left: 0;
    padding-right: 0;
  }

  .page-promo__video-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  .page-promo__video {
    width: 100% !important;
    height: auto !important;
  }
}

@media (max-width: 480px) {
  .page-promo__hero-section {
    min-height: 400px;
  }
  .page-promo__main-title {
    font-size: clamp(1.8em, 8vw, 2.8em);
  }
  .page-promo__hero-description {
    font-size: 0.9em;
  }
  .page-promo__cta-buttons {
    gap: 10px;
  }
  .page-promo__game-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}