/* style/index.css */

/* Base styles */
.page-index {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #F2FFF6; /* Text Main */
  background-color: #08160F; /* Background */
}

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

.page-index__dark-section {
  background-color: #0A4B2C; /* Deep Green */
  color: #F2FFF6;
}

.page-index__section-title {
  font-size: 32px;
  font-weight: 700;
  color: #F2FFF6; /* Text Main */
  text-align: center;
  margin-bottom: 20px;
  padding-top: 40px;
}

.page-index__section-description {
  font-size: 18px;
  color: #A7D9B8; /* Text Secondary */
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-index__main-title {
  font-size: 40px;
  font-weight: 800;
  color: #F2C14E; /* Gold */
  text-align: center;
  margin-bottom: 20px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.2;
}

.page-index__intro-description {
  font-size: 18px;
  color: #F2FFF6; /* Text Main */
  text-align: center;
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-index__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  margin-bottom: 60px;
}

.page-index__btn-primary,
.page-index__btn-secondary,
.page-index__btn-link {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.3s ease;
  text-align: center;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
  box-sizing: border-box;
}

.page-index__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #ffffff; /* White text for primary button */
  border: none;
}

.page-index__btn-primary:hover {
  background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
  box-shadow: 0 0 15px #57E38D; /* Glow */
}

.page-index__btn-secondary {
  background: transparent;
  color: #F2C14E; /* Gold */
  border: 2px solid #F2C14E; /* Gold border */
}

.page-index__btn-secondary:hover {
  background: rgba(242, 193, 78, 0.1);
  color: #F2C14E;
  box-shadow: 0 0 15px #F2C14E; /* Gold glow */
}

.page-index__btn-link {
  color: #57E38D; /* Glow */
  text-decoration: none;
  font-weight: 600;
  padding: 0;
  border: none;
  background: transparent;
}

.page-index__btn-link:hover {
  text-decoration: underline;
  color: #2AD16F;
}

/* Highlight text */
.page-index .highlight {
  color: #F2C14E; /* Gold */
  font-weight: 700;
}

/* --- HERO Section --- */
.page-index__hero-section {
  position: relative;
  padding-bottom: 0;
  padding-left: 0;
  padding-right: 0;
  padding-top: 10px; /* Assuming shared.css has body padding-top */
  margin-top: 0;
  background-color: #08160F; /* Background */
}

.page-index__hero-container {
  position: relative;
  margin: 0 auto;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.page-index__hero-image {
  width: 100%;
  margin: 0;
}

.page-index__hero-image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  object-fit: cover;
}

/* --- Products Section --- */
.page-index__products-section {
  width: 100%;
  padding: 60px 20px;
  background-color: #08160F; /* Background */
}

.page-index__products-container {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 4fr 2fr;
  gap: 20px;
}

.page-index__products-grid {
  display: grid;
  gap: 20px;
}

.page-index__products-grid--small {
  grid-template-columns: repeat(4, 1fr);
}

.page-index__products-grid--large {
  grid-template-columns: repeat(2, 1fr);
}

.page-index__product-card {
  width: 100%;
  max-width: 300px; /* Max width for each card */
  border-radius: 0; /* No round corners */
  overflow: hidden;
  background: transparent;
  box-shadow: none; /* No shadow */
  transition: transform 0.3s ease;
  margin: 0 auto; /* Center cards in their grid cell */
}

.page-index__product-card:hover {
  transform: translateY(-5px); /* Only slight lift on hover */
}

.page-index__product-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.page-index__product-card-image {
  width: 100%;
  max-width: 300px; /* Max width for image container */
  overflow: hidden;
}

.page-index__product-card-image img {
  max-width: 100%;
  width: 100%;
  height: auto; /* Maintain aspect ratio */
  display: block;
}

/* --- Quick Access Section --- */
.page-index__quick-access-section {
  padding: 80px 20px;
  background-color: #11271B; /* Card BG */
}

.page-index__quick-links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 25px;
}

.page-index__quick-link-card {
  background-color: #0A4B2C; /* Deep Green */
  padding: 30px;
  border-radius: 10px;
  text-decoration: none;
  color: #F2FFF6; /* Text Main */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: block;
  text-align: center;
  border: 1px solid #2E7A4E; /* Border */
}

.page-index__quick-link-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3), 0 0 20px #57E38D; /* Glow */
}

.page-index__quick-link-card h3 {
  font-size: 22px;
  margin-top: 0;
  margin-bottom: 10px;
  color: #F2C14E; /* Gold */
}

.page-index__quick-link-card p {
  font-size: 16px;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 0;
}

/* --- Games Section --- */
.page-index__games-section {
  padding: 80px 20px;
}

.page-index__game-category {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-bottom: 80px;
}

.page-index__game-category.reverse {
  flex-direction: row-reverse;
}

.page-index__game-content {
  flex: 1;
}

.page-index__game-content h3 {
  font-size: 28px;
  color: #F2C14E; /* Gold */
  margin-bottom: 15px;
}

.page-index__game-content p {
  font-size: 17px;
  color: #F2FFF6; /* Text Main */
  margin-bottom: 20px;
}

.page-index__game-content ul {
  list-style: none;
  padding: 0;
  margin-bottom: 20px;
}

.page-index__game-content ul li {
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 10px;
  position: relative;
  padding-left: 25px;
}

.page-index__game-content ul li::before {
  content: '✓';
  color: #57E38D; /* Glow */
  position: absolute;
  left: 0;
  font-weight: bold;
}

.page-index__game-image {
  flex: 1;
  min-width: 400px; /* Ensure image has minimum width */
}

.page-index__game-image img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  border: 1px solid #2E7A4E; /* Border */
}

/* --- Promotions Section --- */
.page-index__promotions-section {
  padding: 80px 20px;
  background-color: #08160F; /* Background */
}

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

.page-index__promotion-card {
  background-color: #11271B; /* Card BG */
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  border: 1px solid #2E7A4E; /* Border */
}

.page-index__promotion-card img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block;
}

.page-index__promotion-card h3 {
  font-size: 20px;
  color: #F2C14E; /* Gold */
  margin-bottom: 10px;
}

.page-index__promotion-card p {
  font-size: 16px;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 20px;
}

/* --- Security & Support Section --- */
.page-index__security-support-section {
  padding: 80px 20px;
}

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

.page-index__feature-card {
  background-color: #11271B; /* Card BG */
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  border: 1px solid #2E7A4E; /* Border */
}

.page-index__feature-card h3 {
  font-size: 22px;
  color: #F2C14E; /* Gold */
  margin-bottom: 15px;
}

.page-index__feature-card p {
  font-size: 16px;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 0;
}

.page-index__feature-card p a {
  color: #57E38D; /* Glow */
  text-decoration: underline;
}

.page-index__feature-card p a:hover {
  color: #2AD16F;
}

/* --- FAQ Section --- */
.page-index__faq-section {
  padding: 80px 20px;
  background-color: #08160F; /* Background */
}

.page-index__faq-list {
  max-width: 900px;
  margin: 0 auto;
}

details.page-index__faq-item {
  margin-bottom: 15px;
  border-radius: 10px;
  border: 1px solid #2E7A4E; /* Border */
  overflow: hidden;
  background-color: #11271B; /* Card BG */
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

details.page-index__faq-item summary.page-index__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}

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

details.page-index__faq-item summary.page-index__faq-question:hover {
  background-color: #0A4B2C; /* Deep Green */
}

.page-index__faq-qtext {
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #F2FFF6; /* Text Main */
}

.page-index__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #57E38D; /* Glow */
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}

details.page-index__faq-item .page-index__faq-answer {
  padding: 0 25px 25px;
  background-color: #0A4B2C; /* Deep Green */
  border-radius: 0 0 10px 10px;
}

details.page-index__faq-item .page-index__faq-answer p {
  color: #A7D9B8; /* Text Secondary */
  font-size: 16px;
  margin-bottom: 0;
}

details.page-index__faq-item .page-index__faq-answer a {
  color: #57E38D; /* Glow */
  text-decoration: underline;
}

details.page-index__faq-item .page-index__faq-answer a:hover {
  color: #2AD16F;
}

/* --- Blog Section --- */
.page-index__blog-section {
  padding: 80px 20px;
}

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

.page-index__blog-card {
  background-color: #11271B; /* Card BG */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  border: 1px solid #2E7A4E; /* Border */
}

.page-index__blog-card img {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

.page-index__blog-content {
  padding: 20px;
}

.page-index__blog-content h3 {
  font-size: 20px;
  margin-top: 0;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-index__blog-content h3 a {
  color: #F2C14E; /* Gold */
  text-decoration: none;
}

.page-index__blog-content h3 a:hover {
  text-decoration: underline;
  color: #F2C14E; /* Gold */
}

.page-index__blog-date {
  font-size: 14px;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 15px;
}

.page-index__blog-content p {
  font-size: 16px;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 20px;
}

.page-index__view-all-button {
  text-align: center;
  margin-top: 50px;
}

/* --- Global Image Styles for Content Area --- */
.page-index img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* --- Divider --- */
.page-index__divider {
  width: 100%;
  height: 1px;
  background-color: #1E3A2A; /* Divider */
  margin: 40px auto;
}

/* ==================================================================================================== */
/* @media (max-width: 1024px) */
/* ==================================================================================================== */
@media (max-width: 1024px) {
  .page-index__section-title {
    font-size: 28px;
  }

  .page-index__main-title {
    font-size: 36px;
  }

  .page-index__products-container {
    grid-template-columns: 1fr; /* Stack product grids vertically */
  }

  .page-index__products-grid--small {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-index__products-grid--large {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-index__game-category {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 60px;
  }

  .page-index__game-category.reverse {
    flex-direction: column;
  }

  .page-index__game-image {
    min-width: unset;
    width: 100%;
  }

  .page-index__game-content h3 {
    font-size: 24px;
  }

  .page-index__quick-links-grid,
  .page-index__promotions-grid,
  .page-index__features-grid,
  .page-index__blog-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }

  .page-index__faq-qtext {
    font-size: 17px;
  }
}

/* ==================================================================================================== */
/* @media (max-width: 768px) - 必写清单 */
/* ==================================================================================================== */
@media (max-width: 768px) {
  /* 1. HERO 主图区域 */
  .page-index__hero-section {
    padding-top: 10px !important; /* Fixed header spacing */
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .page-index__hero-image img {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
  }

  /* 2. 产品展示图区域 */
  .page-index__products-section {
    padding: 40px 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
  }

  .page-index__products-container {
    grid-template-columns: 1fr !important;
    gap: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
  }

  .page-index__products-grid--small {
    grid-template-columns: repeat(2, 1fr) !important; /* 4-grid layout (2x2) */
    gap: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .page-index__products-grid--small .page-index__product-card,
  .page-index__products-grid--small .page-index__product-card-image {
    max-width: 100% !important; /* Max width 300px already set for desktop, ensure it's still respected or responsive */
    width: 100% !important;
  }

  .page-index__products-grid--small .page-index__product-card-image img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important; /* Maintain aspect ratio */
  }

  .page-index__products-grid--large {
    grid-template-columns: 1fr !important; /* Each large card takes full width */
    gap: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-index__products-grid--large .page-index__product-card,
  .page-index__products-grid--large .page-index__product-card-image {
    max-width: 100% !important; /* Max width 300px already set for desktop, ensure it's still respected or responsive */
    width: 100% !important;
  }

  .page-index__products-grid--large .page-index__product-card-image img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important; /* Maintain aspect ratio */
  }

  /* 3. 通用图片与容器 */
  .page-index img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-index__container,
  .page-index__intro-section,
  .page-index__quick-access-section,
  .page-index__games-section,
  .page-index__promotions-section,
  .page-index__security-support-section,
  .page-index__faq-section,
  .page-index__blog-section,
  .page-index__quick-links-grid,
  .page-index__promotions-grid,
  .page-index__features-grid,
  .page-index__blog-grid {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  /* 4. 按钮与按钮容器 */
  .page-index__cta-button,
  .page-index__btn-primary,
  .page-index__btn-secondary,
  .page-index a[class*="button"],
  .page-index 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 15px !important; /* Adjust padding for smaller screens */
  }

  .page-index__cta-buttons,
  .page-index__button-group,
  .page-index__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    flex-direction: column !important; /* Stack buttons vertically */
    gap: 15px !important; /* Space between stacked buttons */
    overflow: hidden !important;
  }

  /* 5. 其他内容模块 */
  .page-index__section-title {
    font-size: 24px !important;
    padding-top: 20px !important;
  }

  .page-index__section-description {
    font-size: 16px !important;
    margin-bottom: 30px !important;
  }

  .page-index__main-title {
    font-size: 30px !important;
    padding-top: 20px !important;
  }

  .page-index__intro-description {
    font-size: 16px !important;
    margin-bottom: 30px !important;
  }

  .page-index__quick-link-card {
    padding: 25px !important;
  }

  .page-index__quick-link-card h3 {
    font-size: 20px !important;
  }

  .page-index__game-category {
    flex-direction: column !important;
    gap: 20px !important;
    margin-bottom: 40px !important;
  }

  .page-index__game-category.reverse {
    flex-direction: column !important;
  }

  .page-index__game-content h3 {
    font-size: 22px !important;
  }

  .page-index__game-content p,
  .page-index__game-content ul li {
    font-size: 15px !important;
  }

  .page-index__promotion-card,
  .page-index__feature-card,
  .page-index__blog-card {
    padding: 20px !important;
  }

  .page-index__promotion-card h3,
  .page-index__feature-card h3,
  .page-index__blog-content h3 {
    font-size: 18px !important;
  }

  .page-index__promotion-card p,
  .page-index__feature-card p,
  .page-index__blog-content p {
    font-size: 15px !important;
  }

  details.page-index__faq-item summary.page-index__faq-question {
    padding: 15px !important;
  }

  .page-index__faq-qtext {
    font-size: 16px !important;
  }

  .page-index__faq-toggle {
    font-size: 20px !important;
    width: 24px !important;
    height: 24px !important;
  }

  details.page-index__faq-item .page-index__faq-answer {
    padding: 0 15px 15px !important;
  }

  details.page-index__faq-item .page-index__faq-answer p {
    font-size: 15px !important;
  }

  .page-index__blog-card img {
    
  }

  .page-index__blog-date {
    font-size: 13px !important;
  }

  .page-index__view-all-button {
    margin-top: 30px !important;
  }

  .page-index__intro-section,
  .page-index__quick-access-section,
  .page-index__games-section,
  .page-index__promotions-section,
  .page-index__security-support-section,
  .page-index__faq-section,
  .page-index__blog-section {
    padding: 40px 15px !important;
  }
}