/* style/g.css */
/* body 已 padding-top: var(--header-offset)；页面禁止再写该变量 */
.page-g {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default light text for dark body background */
  background-color: transparent; /* body handles main background */
}

.page-g__dark-bg {
  background-color: #0a0a0a;
  color: #ffffff;
}

.page-g__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-g__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding for first section */
  text-align: center;
  overflow: hidden;
}

.page-g__hero-image {
  width: 100%;
  height: auto;
  object-fit: cover;
  position: relative; /* Ensure it's in normal flow, not absolutely positioned for text overlay */
  display: block;
}

.page-g__hero-content {
  position: relative; /* Not absolute, for normal flow below image */
  z-index: 1;
  max-width: 800px;
  margin-top: 40px; /* Spacing below the image */
  padding: 0 20px;
}

.page-g__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 700;
  color: #26A9E0;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-g__hero-description {
  font-size: 1.1rem;
  margin-bottom: 30px;
  color: #f0f0f0;
}

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

.page-g__btn-primary,
.page-g__btn-secondary,
.page-g__btn-tertiary {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text breaking */
  box-sizing: border-box;
  max-width: 100%;
}

.page-g__btn-primary {
  background-color: #26A9E0;
  color: #ffffff;
  border: 2px solid #26A9E0;
}

.page-g__btn-primary:hover {
  background-color: #1e87bb;
  border-color: #1e87bb;
}

.page-g__btn-secondary {
  background-color: transparent;
  color: #ffffff;
  border: 2px solid #ffffff;
}

.page-g__btn-secondary:hover {
  background-color: #ffffff;
  color: #26A9E0;
}

.page-g__btn-tertiary {
  background-color: #EA7C07;
  color: #ffffff;
  border: 2px solid #EA7C07;
  padding: 10px 20px;
  font-size: 0.95rem;
}

.page-g__btn-tertiary:hover {
  background-color: #cc6a00;
  border-color: #cc6a00;
}

.page-g__section {
  padding: 80px 20px;
  text-align: center;
}

.page-g__container {
  max-width: 1200px;
  margin: 0 auto;
  box-sizing: border-box;
  padding: 0 15px; /* Ensure content has side padding */
}

.page-g__section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 40px;
  line-height: 1.2;
  color: inherit;
}

.page-g__about-cockfighting p {
  font-size: 1.05rem;
  max-width: 900px;
  margin: 0 auto 20px auto;
  text-align: left;
}

.page-g__about-cockfighting h3 {
  font-size: 1.5rem;
  margin-top: 30px;
  margin-bottom: 15px;
  color: #26A9E0;
  text-align: left;
}

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

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

.page-g__card {
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: transform 0.3s ease;
  height: 100%;
  box-sizing: border-box;
}

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

.page-g__card-image {
  width: 100%;
  max-width: 400px; /* Ensure images in cards are not too wide */
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
  display: block;
  min-width: 200px;
  min-height: 200px;
}

.page-g__card-title {
  font-size: 1.6rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: #26A9E0;
}

.page-g__card p {
  font-size: 1rem;
  color: #333333;
  text-align: left;
}

.page-g__ordered-list,
.page-g__unordered-list {
  list-style: none;
  padding: 0;
  margin: 40px auto 0 auto;
  max-width: 900px;
}

.page-g__ordered-list li,
.page-g__unordered-list li {
  background-color: rgba(255, 255, 255, 0.95);
  border-left: 5px solid #26A9E0;
  padding: 25px;
  margin-bottom: 20px;
  border-radius: 8px;
  text-align: left;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  color: #333333;
}

.page-g__ordered-list li h3,
.page-g__unordered-list li h3 {
  font-size: 1.4rem;
  color: #26A9E0;
  margin-top: 0;
  margin-bottom: 10px;
}

.page-g__ordered-list li p,
.page-g__unordered-list li p {
  font-size: 1rem;
  margin-bottom: 10px;
  color: #333333;
}

.page-g__faq-list {
  margin-top: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-g__faq-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #ffffff;
}

.page-g__faq-item summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.15rem;
  font-weight: 600;
  cursor: pointer;
  background-color: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.page-g__faq-item summary::-webkit-details-marker {
  display: none;
}

.page-g__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.page-g__faq-qtext {
  flex-grow: 1;
  text-align: left;
}

.page-g__faq-toggle {
  font-size: 1.5rem;
  font-weight: bold;
  margin-left: 15px;
  color: #26A9E0;
}

.page-g__faq-item[open] .page-g__faq-toggle {
  content: '−';
}

.page-g__faq-answer {
  padding: 20px 25px;
  font-size: 1rem;
  text-align: left;
  color: #f0f0f0;
}

.page-g__faq-answer p {
  margin: 0;
}

.page-g__conclusion p {
  font-size: 1.1rem;
  max-width: 900px;
  margin: 0 auto 25px auto;
  text-align: center;
}

.page-g__conclusion .page-g__cta-buttons {
  margin-top: 40px;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .page-g__main-title {
    font-size: clamp(2rem, 6vw, 3rem);
  }
  .page-g__section-title {
    font-size: 2rem;
  }
}

@media (max-width: 768px) {
  .page-g {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-g__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important;
  }

  .page-g__hero-content {
    margin-top: 20px;
  }

  .page-g__main-title {
    font-size: clamp(1.8rem, 8vw, 2.5rem);
  }

  .page-g__hero-description {
    font-size: 1rem;
  }

  .page-g__cta-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .page-g__btn-primary,
  .page-g__btn-secondary,
  .page-g__btn-tertiary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 1rem;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-g__section {
    padding: 50px 15px;
  }

  .page-g__container {
    padding: 0;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .page-g__section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
  }

  .page-g__grid-3-columns,
  .page-g__grid-2-columns {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-g__card {
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  }

  .page-g__card-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    min-width: 200px !important;
    min-height: 200px !important;
  }

  .page-g__card-title {
    font-size: 1.4rem;
  }

  .page-g__ordered-list li,
  .page-g__unordered-list li {
    padding: 20px;
    margin-bottom: 15px;
  }

  .page-g__faq-item summary {
    font-size: 1rem;
    padding: 15px 20px;
  }

  .page-g__faq-answer {
    padding: 15px 20px;
  }

  .page-g img,
  .page-g video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-g__video-section,
  .page-g__video-container,
  .page-g__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
}

/* Ensure content area images are not too small */
.page-g__section img {
  min-width: 200px;
  min-height: 200px;
}