/* style/game-guides.css */

/* Custom color variables */
:root {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --card-bg-color: #11271B;
  --background-color: #08160F;
  --text-main-color: #F2FFF6;
  --text-secondary-color: #A7D9B8;
  --border-color: #2E7A4E;
  --glow-color: #57E38D;
  --gold-color: #F2C14E;
  --divider-color: #1E3A2A;
  --deep-green-color: #0A4B2C;
}

/* body 已 padding-top: var(--header-offset)；页面禁止再写该变量 */

/* Global styles for page-game-guides scope */
.page-game-guides {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: var(--text-main-color, #F2FFF6); /* Default text color from custom palette */
  background-color: var(--background-color, #08160F); /* Default background color from custom palette */
}

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

/* Ensure contrast for text on various backgrounds */
.page-game-guides h1,
.page-game-guides h2,
.page-game-guides h3,
.page-game-guides h4,
.page-game-guides h5,
.page-game-guides h6 {
  color: var(--gold-color, #F2C14E); /* Titles generally use gold */
}

.page-game-guides p,
.page-game-guides li,
.page-game-guides a {
  color: var(--text-secondary-color, #A7D9B8); /* General text uses secondary light green */
}

/* Specific overrides for sections to ensure contrast */
.page-game-guides__dark-section .page-game-guides__text-block,
.page-game-guides__dark-section .page-game-guides__list-item {
  color: var(--text-secondary-color, #A7D9B8);
}

.page-game-guides__dark-section .page-game-guides__section-title {
  color: var(--gold-color, #F2C14E);
}

.page-game-guides__dark-section .page-game-guides__sub-title {
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__faq-question {
  color: var(--text-main-color, #F2FFF6);
}
.page-game-guides__faq-answer {
  color: var(--text-secondary-color, #A7D9B8);
}

/* Hero Section */
.page-game-guides__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding as body handles header offset */
  overflow: hidden; /* Ensure no overflow */
  min-height: 500px;
}

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

.page-game-guides__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3; /* Slightly dim the background image for text readability */
}

.page-game-guides__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.2;
  color: var(--gold-color, #F2C14E); /* Using Gold color for main title */
}

.page-game-guides__description {
  font-size: 1.2rem;
  margin-bottom: 30px;
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

.page-game-guides__cta-buttons--center {
  margin-top: 40px;
}

.page-game-guides__btn-primary,
.page-game-guides__btn-secondary,
.page-game-guides a[class*="button"],
.page-game-guides a[class*="btn"] {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.3s ease;
  box-sizing: border-box;
  max-width: 100%; /* Ensure responsiveness */
  text-align: center;
}

.page-game-guides__btn-primary {
  background: var(--button-gradient);
  color: #ffffff;
  border: none;
}

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

.page-game-guides__btn-secondary {
  background: transparent;
  color: var(--text-main-color, #F2FFF6);
  border: 2px solid var(--border-color, #2E7A4E);
}

.page-game-guides__btn-secondary:hover {
  background: var(--border-color, #2E7A4E);
  color: #ffffff;
}

/* Section Styling */
.page-game-guides__introduction-section,
.page-game-guides__guide-section,
.page-game-guides__strategy-section,
.page-game-guides__faq-section,
.page-game-guides__conclusion-section {
  padding: 80px 0;
}

.page-game-guides__dark-section {
  background-color: var(--card-bg-color, #11271B); /* Darker background for contrast */
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__section-title {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: var(--gold-color, #F2C14E); /* Using Gold color for section titles */
}

.page-game-guides__sub-title {
  font-size: 1.8rem;
  font-weight: 600;
  margin-top: 40px;
  margin-bottom: 20px;
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__text-block {
  font-size: 1.1rem;
  margin-bottom: 20px;
  color: var(--text-secondary-color, #A7D9B8);
}

.page-game-guides__text-block strong {
  color: var(--text-main-color, #F2FFF6);
}

.page-game-guides__image-content {
  display: block;
  margin: 30px auto;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  max-width: 100%;
  height: auto;
  width: 800px; /* Example display width for content images */
  height: 600px; /* Example display height for content images */
}

/* List styles */
.page-game-guides__list {
  list-style: disc;
  padding-left: 25px;
  margin-bottom: 20px;
  color: var(--text-secondary-color, #A7D9B8);
}

.page-game-guides__list-item {
  margin-bottom: 10px;
  font-size: 1.1rem;
}

.page-game-guides__list-item strong {
  color: var(--text-main-color, #F2FFF6);
}

/* FAQ Section */
.page-game-guides__faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.page-game-guides__faq-item {
  background-color: var(--card-bg-color, #11271B);
  border: 1px solid var(--border-color, #2E7A4E);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-game-guides__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-main-color, #F2FFF6);
  cursor: pointer;
  background-color: var(--deep-green-color, #0A4B2C); /* Slightly different background for question header */
  user-select: none;
  list-style: none; /* For details/summary */
}

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

.page-game-guides__faq-item summary {
  list-style: none; /* Remove default marker for summary */
}

.page-game-guides__faq-item summary::-webkit-details-marker {
  display: none; /* Remove default marker for summary in webkit */
}

.page-game-guides__faq-qtext {
  flex-grow: 1;
}

.page-game-guides__faq-toggle {
  font-size: 1.5rem;
  margin-left: 15px;
  width: 24px;
  text-align: center;
}

.page-game-guides__faq-answer {
  padding: 0 20px 20px 20px;
  font-size: 1.1rem;
  color: var(--text-secondary-color, #A7D9B8);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}

.page-game-guides__faq-item[open] .page-game-guides__faq-answer {
  max-height: 500px; /* Sufficiently large for content */
  padding-top: 10px;
}

.page-game-guides__faq-item[open] .page-game-guides__faq-question .page-game-guides__faq-toggle {
  content: "−"; /* Changed by JS for better control */
}

.page-game-guides__faq-answer p {
  margin-bottom: 10px;
  color: var(--text-secondary-color, #A7D9B8);
}

.page-game-guides__faq-answer a {
  color: var(--primary-color, #11A84E); /* Link color */
  text-decoration: underline;
}

.page-game-guides__faq-answer a:hover {
  color: var(--glow-color, #57E38D);
}

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

  .page-game-guides__container {
    padding: 0 15px !important; /* Force padding for mobile */
  }

  .page-game-guides__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important; /* Small top padding for mobile */
    min-height: 400px;
  }

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

  .page-game-guides__description {
    font-size: 1rem;
  }

  .page-game-guides__cta-buttons {
    flex-direction: column;
    gap: 15px;
    width: 100%; /* Ensure container takes full width */
    max-width: 100%;
    box-sizing: border-box;
    padding: 0 15px;
  }

  .page-game-guides__btn-primary,
  .page-game-guides__btn-secondary,
  .page-game-guides a[class*="button"],
  .page-game-guides a[class*="btn"] {
    width: 100% !important;
    max-width: 100% !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding: 12px 20px;
  }

  .page-game-guides__introduction-section,
  .page-game-guides__guide-section,
  .page-game-guides__strategy-section,
  .page-game-guides__faq-section,
  .page-game-guides__conclusion-section {
    padding: 40px 0;
  }

  .page-game-guides__section-title {
    font-size: 2rem;
    margin-bottom: 30px;
  }

  .page-game-guides__sub-title {
    font-size: 1.5rem;
    margin-top: 30px;
    margin-bottom: 15px;
  }

  .page-game-guides__text-block,
  .page-game-guides__list-item,
  .page-game-guides__faq-question,
  .page-game-guides__faq-answer {
    font-size: 1rem;
  }

  /* Image responsiveness */
  .page-game-guides img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    min-width: 200px !important; /* Enforce minimum size */
    min-height: 200px !important; /* Enforce minimum size */
  }

  .page-game-guides__image-content {
    width: 100% !important;
    height: auto !important;
  }

  /* Ensure all image containers are responsive */
  .page-game-guides__hero-image-wrapper,
  .page-game-guides__guide-section .page-game-guides__container,
  .page-game-guides__strategy-section .page-game-guides__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  /* FAQ specific mobile styles */
  .page-game-guides__faq-question {
    padding: 15px;
  }
  .page-game-guides__faq-answer {
    padding: 0 15px 15px 15px;
  }
}