/* style/index.css */

/* Base styles for page-index */
.page-index {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: var(--dark-bg-1);
}

/* Padding for main content to avoid overlap with fixed header */
.page-index__container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 20px;
  box-sizing: border-box;
}

.page-index__heading {
  font-size: 36px;
  font-weight: 700;
  color: #FFD700; /* Auxiliary color for headings */
  text-align: center;
  margin-bottom: 30px;
  line-height: 1.3;
}

.page-index__sub-heading {
  font-size: 20px;
  font-weight: 500;
  color: #f0f0f0;
  text-align: center;
  margin-bottom: 40px;
}

.page-index__text-block {
  font-size: 17px;
  color: #f0f0f0;
  margin-bottom: 20px;
  text-align: center;
}

.page-index__text-block strong {
  color: #FFD700;
}

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

.page-index__button-center {
  text-align: center;
  margin-top: 40px;
}

.page-index__btn-primary,
.page-index__btn-secondary,
.page-index__link-btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
}

.page-index__btn-primary {
  background: #CC0000;
  color: #ffffff;
  border: 2px solid #CC0000;
}

.page-index__btn-primary:hover {
  background: #FFD700;
  color: #CC0000;
  border-color: #FFD700;
}

.page-index__btn-secondary {
  background: none;
  color: #FFD700;
  border: 2px solid #FFD700;
}

.page-index__btn-secondary:hover {
  background: #FFD700;
  color: #CC0000;
  border-color: #FFD700;
}

.page-index__link-btn {
  background: #FFD700;
  color: #CC0000;
  border: 2px solid #FFD700;
  padding: 10px 20px;
  font-size: 16px;
  margin-top: 20px;
}

.page-index__link-btn:hover {
  background: #CC0000;
  color: #ffffff;
  border-color: #CC0000;
}

/* Section backgrounds */
.page-index__dark-section {
  background-color: #1a1a1a; /* Slightly lighter dark for contrast */
  color: #f0f0f0;
}

/* HERO主图区域样式 */
.page-index__hero-section {
  position: relative;
  width: 100%;
  padding-bottom: 0;
  padding-left: 0;
  padding-right: 0;
  margin-top: 0; /* Ensures it's at the very top */
}

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

.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;
}

/* LOGO轮播区域样式 */
.page-index__logo-carousel-section {
  width: 100%;
  padding: 40px 20px;
  background: #0d0d0d;
}

.page-index__logo-carousel-container {
  max-width: 1400px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

.page-index__logo-carousel {
  display: flex;
  gap: 20px;
  overflow: hidden;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
  padding: 10px 0;
  user-select: none;
  -webkit-user-select: none;
  pointer-events: none;
}

.page-index__logo-carousel::-webkit-scrollbar {
  display: none;
}

.page-index__logo-item {
  flex-shrink: 0;
  width: 200px;
  height: 200px;
  border-radius: 8px;
  overflow: hidden;
  background: #2a2a2a; /* Dark background for logos */
  border: 1px solid #3a3a3a;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  pointer-events: auto;
}

.page-index__logo-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 12px rgba(255, 215, 0, 0.2);
}

.page-index__logo-item a {
  display: block;
  width: 100%;
  height: 100%;
  padding: 15px;
  box-sizing: border-box;
  pointer-events: auto;
}

.page-index__logo-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* 游戏展示区域样式 */
.page-index__games-section {
  width: 100%;
  padding: 60px 20px;
  background: #0d0d0d;
}

.page-index__games-container {
  max-width: 1400px;
  margin: 0 auto;
}

.page-index__games-layout {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 30px;
  align-items: start;
}

.page-index__featured-game-area {
  width: 100%;
}

.page-index__featured-game-title {
  font-size: 28px;
  font-weight: bold;
  margin: 0 0 20px 0;
  color: #FFD700; /* Yellow text */
  text-align: left;
}

.page-index__featured-game {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__featured-game:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 24px rgba(255, 215, 0, 0.3);
}

.page-index__featured-game-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.page-index__featured-game-image {
  width: 100%;
  height: 500px;
  overflow: hidden;
}

.page-index__featured-game-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.page-index__games-grid-area {
  width: 100%;
}

.page-index__games-tabs {
  display: flex;
  gap: 25px;
  margin-bottom: 25px;
  align-items: center;
  justify-content: flex-start;
}

.page-index__games-tab {
  background: none;
  border: none;
  padding: 0;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  color: #999999;
  transition: color 0.3s ease, text-decoration 0.3s ease;
  text-decoration: none;
  position: relative;
}

.page-index__games-tab:hover {
  color: #FFD700;
}

.page-index__games-tab.active {
  color: #CC0000; /* Red text */
  text-decoration: underline;
  text-decoration-color: #FFD700;
  text-underline-offset: 5px;
}

.page-index__games-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  display: none;
}

.page-index__games-grid.active {
  display: grid;
}

.page-index__game-card {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__game-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 12px rgba(255, 215, 0, 0.15);
}

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

.page-index__game-card-image {
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.page-index__game-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.page-index__game-card-title {
  font-size: 14px;
  font-weight: 500;
  margin: 10px 0 10px 0;
  padding: 0 5px;
  color: #f0f0f0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  line-height: 1.4;
}

/* Quick Access Section */
.page-index__quick-access-section {
  padding: 60px 20px;
  background: #0d0d0d;
}

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

.page-index__link-card {
  background: #1a1a1a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__link-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.2);
}

.page-index__link-card-title {
  font-size: 22px;
  color: #FFD700;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index__link-card p {
  color: #cccccc;
  font-size: 15px;
  margin-bottom: 20px;
}

/* Core Games Section */
.page-index__core-games-section {
  padding: 60px 20px;
}

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

.page-index__game-category-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__game-category-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.2);
}

.page-index__game-category-card img {
  width: 100%;
  max-width: 250px;
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
}

.page-index__game-category-card h3 {
  font-size: 24px;
  color: #FFD700;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index__game-category-card p {
  color: #cccccc;
  font-size: 16px;
  margin-bottom: 25px;
}

/* Promotions Section */
.page-index__promotions-section {
  padding: 60px 20px;
  background: #0d0d0d;
}

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

.page-index__promo-card {
  background: #1a1a1a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-index__promo-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.2);
}

.page-index__promo-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

.page-index__promo-card h3 {
  font-size: 22px;
  color: #FFD700;
  margin: 20px 20px 10px 20px;
  font-weight: bold;
}

.page-index__promo-card p {
  color: #cccccc;
  font-size: 16px;
  margin: 0 20px 20px 20px;
  flex-grow: 1;
}

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

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

.page-index__feature-item {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-index__feature-item img {
  width: 80px;
  height: 80px;
  margin-bottom: 20px;
  object-fit: contain;
}

.page-index__feature-item h3 {
  font-size: 22px;
  color: #FFD700;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-index__feature-item p {
  color: #cccccc;
  font-size: 16px;
}

/* FAQ Section */
.page-index__faq-section {
  padding: 60px 20px;
  background: #0d0d0d;
}

.page-index__faq-list {
  margin-top: 40px;
}

.page-index__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
}

.page-index__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 15px;
  opacity: 0;
  color: #cccccc;
  font-size: 16px;
}

.page-index__faq-item.active .page-index__faq-answer {
  max-height: 2000px !important;
  padding: 20px 15px !important;
  opacity: 1;
  background: #1a1a1a;
  border-radius: 0 0 5px 5px;
}

.page-index__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-index__faq-question:hover {
  background: #3a3a3a;
  border-color: #4a4a4a;
}

.page-index__faq-question:active {
  background: #4a4a4a;
}

.page-index__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none;
  color: #f0f0f0;
}

.page-index__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: #FFD700;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

.page-index__faq-item.active .page-index__faq-toggle {
  color: #CC0000;
  transform: rotate(45deg); /* Change to X */
}

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

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

.page-index__blog-card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-index__blog-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.2);
}

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

.page-index__blog-content {
  padding: 20px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-index__blog-card h3 {
  font-size: 22px;
  margin-bottom: 10px;
  line-height: 1.4;
  flex-grow: 1;
}

.page-index__blog-card h3 a.page-index__blog-link {
  color: #FFD700;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index__blog-card h3 a.page-index__blog-link:hover {
  color: #CC0000;
}

.page-index__blog-card p {
  color: #cccccc;
  font-size: 16px;
  margin-bottom: 15px;
}

.page-index__blog-date {
  font-size: 14px;
  color: #999999;
  display: block;
  margin-top: auto;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .page-index__container {
    padding: 30px 15px;
  }

  .page-index__heading {
    font-size: 32px;
  }

  .page-index__text-block {
    font-size: 16px;
  }

  .page-index__games-layout {
    grid-template-columns: 1fr;
  }

  .page-index__games-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .page-index__featured-game-image {
    height: 400px;
  }

  .page-index__logo-item {
    width: 180px;
    height: 180px;
  }
}

@media (max-width: 992px) {
  .page-index__heading {
    font-size: 28px;
  }

  .page-index__sub-heading {
    font-size: 18px;
  }

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

  .page-index__featured-game-image {
    height: 350px;
  }

  .page-index__game-category-card img {
    max-width: 200px;
  }

  .page-index__promo-card img {
    height: 180px;
  }

  .page-index__logo-item {
    width: 150px;
    height: 150px;
  }
}

@media (max-width: 768px) {
  .page-index__container {
    padding: 20px 15px;
  }

  .page-index__heading {
    font-size: 24px;
    margin-bottom: 20px;
  }

  .page-index__sub-heading {
    font-size: 16px;
    margin-bottom: 30px;
  }

  .page-index__text-block {
    font-size: 15px;
  }

  .page-index__btn-primary,
  .page-index__btn-secondary,
  .page-index__link-btn {
    padding: 10px 20px;
    font-size: 16px;
  }

  .page-index__button-group {
    flex-direction: column;
    gap: 15px;
  }

  /* HERO */
  .page-index__hero-section {
    padding-bottom: 0;
    padding-left: 0;
    padding-right: 0;
  }
  
  .page-index__hero-image img {
    width: 100% !important;
    height: auto !important;
  }

  /* LOGO Carousel */
  .page-index__logo-carousel-section {
    padding: 30px 15px;
  }
  
  .page-index__logo-item {
    width: 120px;
    height: 120px;
  }
  
  .page-index__logo-carousel {
    gap: 15px;
  }

  /* Games Section */
  .page-index__games-section {
    padding: 40px 15px;
  }

  .page-index__games-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .page-index__featured-game-title {
    font-size: 22px;
  }

  .page-index__featured-game-image {
    height: 250px;
  }

  .page-index__games-tabs {
    gap: 15px;
    margin-bottom: 20px;
  }

  .page-index__games-tab {
    font-size: 16px;
  }

  .page-index__games-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }

  .page-index__game-card-image {
    height: 140px;
  }

  .page-index__game-card-title {
    font-size: 13px;
    margin: 8px 0 8px 0;
  }

  /* Quick Access */
  .page-index__quick-access-section {
    padding: 40px 15px;
  }

  .page-index__link-card {
    padding: 25px;
  }

  .page-index__link-card-title {
    font-size: 20px;
  }

  /* Core Games */
  .page-index__core-games-section {
    padding: 40px 15px;
  }

  .page-index__game-categories {
    gap: 20px;
  }

  .page-index__game-category-card img {
    max-width: 150px;
  }

  .page-index__game-category-card h3 {
    font-size: 20px;
  }

  .page-index__game-category-card p {
    font-size: 15px;
  }

  /* Promotions */
  .page-index__promotions-section {
    padding: 40px 15px;
  }

  .page-index__promo-grid {
    gap: 20px;
  }

  .page-index__promo-card img {
    height: 160px;
  }

  .page-index__promo-card h3 {
    font-size: 20px;
    margin: 15px 15px 8px 15px;
  }

  .page-index__promo-card p {
    font-size: 15px;
    margin: 0 15px 15px 15px;
  }

  /* Security & Support */
  .page-index__security-support-section {
    padding: 40px 15px;
  }

  .page-index__features-grid {
    gap: 20px;
  }

  .page-index__feature-item {
    padding: 25px;
  }

  .page-index__feature-item img {
    width: 70px;
    height: 70px;
  }

  .page-index__feature-item h3 {
    font-size: 20px;
  }

  .page-index__feature-item p {
    font-size: 15px;
  }

  /* FAQ */
  .page-index__faq-section {
    padding: 40px 15px;
  }

  .page-index__faq-question {
    padding: 15px;
    flex-wrap: wrap;
  }
  
  .page-index__faq-question h3 {
    font-size: 15px;
    margin-bottom: 0;
    width: calc(100% - 40px);
  }
  
  .page-index__faq-toggle {
    margin-left: 10px;
    width: 24px;
    height: 24px;
    font-size: 20px;
  }
  
  .page-index__faq-answer {
    padding: 0 15px;
  }
  
  .page-index__faq-item.active .page-index__faq-answer {
    padding: 15px !important;
  }

  /* Blog */
  .page-index__blog-section {
    padding: 40px 15px;
  }

  .page-index__blog-grid {
    gap: 20px;
  }

  .page-index__blog-card img {
    height: 180px;
  }

  .page-index__blog-card h3 {
    font-size: 20px;
  }

  .page-index__blog-card p {
    font-size: 15px;
  }
}

@media (max-width: 576px) {
  .page-index__hero-image img {
    height: 200px !important;
  }

  .page-index__games-grid {
    grid-template-columns: 1fr;
  }

  .page-index__featured-game-image {
    height: 200px;
  }

  .page-index__game-card-image {
    height: 120px;
  }

  .page-index__game-card-title {
    font-size: 12px;
  }

  .page-index__links-grid,
  .page-index__game-categories,
  .page-index__promo-grid,
  .page-index__features-grid,
  .page-index__blog-grid {
    grid-template-columns: 1fr;
  }

  .page-index__logo-item {
    width: 100px;
    height: 100px;
  }

  .page-index__logo-carousel {
    gap: 10px;
  }

  .page-index__promo-card img {
    height: 150px;
  }

  .page-index__blog-card img {
    height: 150px;
  }

  .page-index__faq-question h3 {
    font-size: 14px;
  }
}

/* Ensure all images are responsive */
.page-index img {
  max-width: 100%;
  height: auto;
  display: block;
}

.page-index__section,
.page-index__card,
.page-index__container,
.page-index__link-card,
.page-index__game-category-card,
.page-index__promo-card,
.page-index__feature-item,
.page-index__blog-card {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

@media (max-width: 768px) {
  .page-index img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-index__section,
  .page-index__card,
  .page-index__container,
  .page-index__link-card,
  .page-index__game-category-card,
  .page-index__promo-card,
  .page-index__feature-item,
  .page-index__blog-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-index__hero-section .page-index__hero-container, 
  .page-index__logo-carousel-section .page-index__logo-carousel-container, 
  .page-index__games-section .page-index__games-container {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
}