.page-fortune-rabbit {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light backgrounds */
  background-color: #F5F7FA; /* Background color from custom palette */
}

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

/* Color contrast classes */
.page-fortune-rabbit__dark-bg {
  background-color: #E53935; /* Main brand color */
  color: #ffffff; /* White text for dark background */
}

.page-fortune-rabbit__light-bg {
  background-color: #F5F7FA; /* Light background color */
  color: #333333; /* Dark text for light background */
}

.page-fortune-rabbit__card {
  background-color: #FFFFFF; /* Card BG from custom palette */
  color: #333333; /* Text Main from custom palette */
  border: 1px solid #E0E0E0; /* Border from custom palette */
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
}

.page-fortune-rabbit__card:hover {
  transform: translateY(-5px);
}

/* Typography */
.page-fortune-rabbit__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive H1 font size */
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 20px;
  text-align: center;
}

.page-fortune-rabbit__section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 30px;
  text-align: center;
  color: inherit; /* Inherit color from parent section (dark/light bg) */
}

.page-fortune-rabbit__card-title {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 600;
  margin-top: 15px;
  margin-bottom: 10px;
  color: inherit;
}

.page-fortune-rabbit__hero-description,
.page-fortune-rabbit__text-block,
.page-fortune-rabbit__card-description,
.page-fortune-rabbit__faq-answer p {
  font-size: 1rem;
  margin-bottom: 15px;
}

/* Buttons */
.page-fortune-rabbit__btn-primary,
.page-fortune-rabbit__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
  max-width: 100%; /* For responsive buttons */
  box-sizing: border-box; /* For responsive buttons */
  white-space: normal; /* For responsive buttons */
  word-wrap: break-word; /* For responsive buttons */
}

.page-fortune-rabbit__btn-primary {
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%); /* Custom button gradient */
  color: #ffffff;
  border: none;
}

.page-fortune-rabbit__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.page-fortune-rabbit__btn-secondary {
  background-color: transparent;
  color: #E53935; /* Primary color for text */
  border: 2px solid #E53935;
}

.page-fortune-rabbit__btn-secondary:hover {
  background-color: #E53935;
  color: #ffffff;
}

.page-fortune-rabbit__cta-buttons {
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on small screens */
  justify-content: center;
  gap: 15px;
  margin-top: 30px;
}

/* Hero Section */
.page-fortune-rabbit__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 60px 0;
  overflow: hidden;
}

.page-fortune-rabbit__hero-image-wrapper {
  width: 100%;
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  z-index: 0;
}

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

.page-fortune-rabbit__hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  text-align: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.6); /* Semi-transparent overlay for text readability */
  border-radius: 10px;
  margin: 0 20px;
  box-sizing: border-box;
}

.page-fortune-rabbit__hero-content .page-fortune-rabbit__main-title,
.page-fortune-rabbit__hero-content .page-fortune-rabbit__hero-description {
  color: #ffffff;
}

/* Sections */
.page-fortune-rabbit__introduction-section,
.page-fortune-rabbit__how-to-play-section,
.page-fortune-rabbit__features-section,
.page-fortune-rabbit__why-choose-section,
.page-fortune-rabbit__video-section,
.page-fortune-rabbit__faq-section,
.page-fortune-rabbit__cta-section {
  padding: 60px 0;
}

.page-fortune-rabbit__how-to-play-section .page-fortune-rabbit__ordered-list {
  list-style-type: decimal;
  padding-left: 25px;
  max-width: 800px;
  margin: 0 auto 30px auto;
}

.page-fortune-rabbit__how-to-play-section .page-fortune-rabbit__ordered-list li {
  margin-bottom: 10px;
  font-size: 1rem;
  color: #ffffff; /* Inherited from dark-bg */
}

.page-fortune-rabbit__image-content {
  display: block;
  margin: 30px auto;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

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

.page-fortune-rabbit__feature-card {
  text-align: center;
}

.page-fortune-rabbit__card-image {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 15px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* Why Choose Grid */
.page-fortune-rabbit__why-choose-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
  margin-bottom: 40px;
}

.page-fortune-rabbit__reason-card {
  text-align: center;
}

/* Video Section */
.page-fortune-rabbit__video-section {
  padding-top: 10px; /* Small top padding, body handles header offset */
  padding-bottom: 60px;
  text-align: center;
}

.page-fortune-rabbit__video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  max-width: 100%;
  background: #000;
  margin: 30px auto;
  border-radius: 8px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  width: 100%; /* Ensure width for desktop */
}

.page-fortune-rabbit__video-wrapper .page-fortune-rabbit__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.page-fortune-rabbit__video-link {
  display: block;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2; /* Ensure link is clickable over video */
  cursor: pointer;
}

/* FAQ Section */
.page-fortune-rabbit__faq-list {
  max-width: 900px;
  margin: 40px auto 0 auto;
}

.page-fortune-rabbit__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  background-color: #FFFFFF; /* Card BG from custom palette */
  color: #333333; /* Text Main from custom palette */
  border: 1px solid #E0E0E0; /* Border from custom palette */
}

.page-fortune-rabbit__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background-color: #ffffff;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.1rem;
  color: #333333;
  transition: background-color 0.3s ease;
}

.page-fortune-rabbit__faq-question:hover {
  background-color: #f0f0f0;
}

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

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

.page-fortune-rabbit__faq-answer {
  padding: 0 25px 20px 25px;
  font-size: 1rem;
  color: #555555;
}

.page-fortune-rabbit__faq-answer p:last-child {
  margin-bottom: 0;
}

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

  .page-fortune-rabbit__container {
    padding: 0 15px; /* Adjust padding for mobile */
  }

  .page-fortune-rabbit__hero-section {
    padding: 40px 0;
  }

  .page-fortune-rabbit__hero-content {
    margin: 0 15px;
    padding: 15px;
  }

  .page-fortune-rabbit__main-title {
    font-size: clamp(2rem, 8vw, 2.5rem);
  }

  .page-fortune-rabbit__section-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
    margin-bottom: 20px;
  }

  .page-fortune-rabbit__cta-buttons {
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
  }

  .page-fortune-rabbit__btn-primary,
  .page-fortune-rabbit__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 10px 15px; /* Adjust button padding for mobile */
  }

  .page-fortune-rabbit__introduction-section,
  .page-fortune-rabbit__how-to-play-section,
  .page-fortune-rabbit__features-section,
  .page-fortune-rabbit__why-choose-section,
  .page-fortune-rabbit__video-section,
  .page-fortune-rabbit__faq-section,
  .page-fortune-rabbit__cta-section {
    padding: 40px 0;
  }

  /* Images responsive */
  .page-fortune-rabbit img {
    max-width: 100% !important;
    width: 100% !important; /* Ensure content images take full width */
    height: auto !important;
    display: block !important;
  }

  /* Image containers responsive */
  .page-fortune-rabbit__section,
  .page-fortune-rabbit__card,
  .page-fortune-rabbit__container,
  .page-fortune-rabbit__hero-image-wrapper,
  .page-fortune-rabbit__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
  
  .page-fortune-rabbit__video-section {
    padding-top: 10px !important; /* body handles header offset */
  }
  
  /* Video responsive */
  .page-fortune-rabbit video,
  .page-fortune-rabbit__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-fortune-rabbit__video-wrapper {
    margin-left: 15px; /* Add padding to video wrapper */
    margin-right: 15px;
    padding-bottom: 56.25% !important; /* Maintain aspect ratio */
  }

  .page-fortune-rabbit__how-to-play-section .page-fortune-rabbit__ordered-list {
    padding-left: 20px;
  }

  .page-fortune-rabbit__faq-question {
    padding: 15px 20px;
    font-size: 1rem;
  }

  .page-fortune-rabbit__faq-answer {
    padding: 0 20px 15px 20px;
  }
}