/* style/faq.css */

/* Base styles for the FAQ page */
.page-faq {
  font-family: 'Arial', sans-serif;
  color: #f0f0f0; /* Light text for dark body background */
  line-height: 1.6;
  background-color: transparent; /* Body background from shared.css */
}

/* Hero Section */
.page-faq__hero-section {
  position: relative;
  width: 100%;
  height: 60vh;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #ffffff;
  padding-top: var(--header-offset, 120px); /* Fixed header offset */
  overflow: hidden;
}

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

.page-faq__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: -1;
}

.page-faq__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  padding: 0 20px;
}

.page-faq__main-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: #FFFFFF; /* White for strong contrast */
  line-height: 1.2;
}

.page-faq__intro-text {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #f0f0f0;
}

.page-faq__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.3s ease;
  white-space: normal;
  word-wrap: break-word;
  box-sizing: border-box;
  max-width: 100%;
}

.page-faq__btn-primary {
  background-color: #017439; /* Brand primary color */
  color: #ffffff; /* White text for contrast */
  border: 2px solid #017439;
}

.page-faq__btn-primary:hover {
  background-color: #005a2e;
  transform: translateY(-2px);
}

.page-faq__btn-secondary {
  background-color: #ffffff;
  color: #017439;
  border: 2px solid #017439;
  margin-left: 15px;
}

.page-faq__btn-secondary:hover {
  background-color: #f0f0f0;
  transform: translateY(-2px);
}

/* Content Section */
.page-faq__content-section {
  padding: 60px 0;
  background-color: #1a1a2e; /* Dark background from body */
  color: #f0f0f0; /* Light text */
}

.page-faq__container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
}

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

/* FAQ List */
.page-faq__faq-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.page-faq__faq-item {
  background-color: rgba(255, 255, 255, 0.08); /* Slightly transparent white for cards */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.page-faq__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.2em;
  font-weight: bold;
  cursor: pointer;
  color: #ffffff;
  background-color: rgba(1, 116, 57, 0.7); /* Brand color with transparency */
  transition: background-color 0.3s ease;
  list-style: none; /* Remove default marker for details/summary */
}

.page-faq__faq-question::-webkit-details-marker {
  display: none;
}

.page-faq__faq-question:hover {
  background-color: #017439;
}

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

.page-faq__faq-toggle {
  font-size: 1.5em;
  margin-left: 15px;
  width: 25px;
  text-align: center;
}

.page-faq__faq-answer {
  padding: 20px 25px;
  font-size: 1.1em;
  color: #f0f0f0;
  background-color: rgba(255, 255, 255, 0.05); /* Lighter background for answer */
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.page-faq__faq-answer p {
  margin-bottom: 15px;
}

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

.page-faq__image-inline {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.page-faq__button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 20px;
  justify-content: center;
}

.page-faq__btn-link {
  display: inline-block;
  padding: 10px 20px;
  background-color: rgba(1, 116, 57, 0.8); /* Brand color with transparency */
  color: #ffffff;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  white-space: normal;
  word-wrap: break-word;
  box-sizing: border-box;
  max-width: 100%;
}

.page-faq__btn-link:hover {
  background-color: #017439;
}

.page-faq__game-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  justify-content: center;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-faq__main-title {
    font-size: 2.8em;
  }

  .page-faq__intro-text {
    font-size: 1.1em;
  }

  .page-faq__section-title {
    font-size: 2em;
  }

  .page-faq__faq-question {
    font-size: 1.1em;
  }

  .page-faq__faq-answer {
    font-size: 1em;
  }
}

@media (max-width: 768px) {
  .page-faq__hero-section {
    height: auto;
    min-height: 300px;
    padding: 80px 0;
    padding-top: var(--header-offset, 120px) !important; /* Mobile header offset */
  }

  .page-faq__hero-content {
    padding: 0 15px;
  }

  .page-faq__main-title {
    font-size: 2em;
  }

  .page-faq__intro-text {
    font-size: 1em;
  }

  .page-faq__cta-button {
    width: 100% !important; /* Force full width on mobile */
    margin-left: 0 !important;
    margin-bottom: 15px;
    max-width: 100% !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 20px;
  }

  .page-faq__button-group {
    flex-direction: column;
    gap: 10px;
    padding: 0 15px;
  }

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

  .page-faq__container {
    padding: 0 15px;
  }

  .page-faq__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
  }

  .page-faq__faq-question {
    font-size: 1em;
    padding: 15px 20px;
  }

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

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

  .page-faq__section,
  .page-faq__card,
  .page-faq__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  
  .page-faq__game-links {
    flex-direction: column;
    gap: 10px;
    padding: 0 15px;
  }

  .page-faq__btn-link {
    width: 100%;
    max-width: 100% !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }
}

@media (max-width: 480px) {
  .page-faq__main-title {
    font-size: 1.8em;
  }
}

/* Ensure details summary toggle works */
details > summary {
  list-style: none;
}
details > summary::-webkit-details-marker {
  display: none;
}

/* Color Contrast Adjustments for specific elements if needed */
/* (These are general examples, actual implementation above already considers contrast) */
.page-faq p, .page-faq li {
  color: #f0f0f0; /* Ensure light text on dark background */
}

.page-faq__faq-item {
  background-color: rgba(255, 255, 255, 0.08);
  color: #f0f0f0;
}

.page-faq__faq-question {
  background-color: #017439;
  color: #ffffff;
}

.page-faq__faq-answer {
  background-color: rgba(255, 255, 255, 0.05);
  color: #f0f0f0;
}