/* style/index.css */

:root {
  --primary-color: #1A2B4C;
  --secondary-color: #FFD700;
  --text-light: #ffffff;
  --text-dark: #333333;
  --background-dark: #000;
  --background-light: #f1f3f5;
  --border-light: #e4e4e4;
  --shadow-light: rgba(0, 0, 0, 0.1);
  --shadow-medium: rgba(0, 0, 0, 0.2);
}

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

/* HERO Main Image Area */
.page-index__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
  padding-top: 180px; /* Desktop: Adjust for fixed header */
  background: var(--primary-color);
  color: var(--text-light);
}

.page-index__hero-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.page-index__hero-image {
  width: 100%;
  margin-bottom: 30px;
}

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

.page-index__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
}

.page-index__hero-title {
  font-size: 42px;
  font-weight: bold;
  margin-bottom: 20px;
  color: var(--secondary-color); /* Gold color for title */
}

.page-index__hero-description {
  font-size: 18px;
  margin-bottom: 30px;
  color: var(--text-light);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-index__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: linear-gradient(135deg, #FFD700, #FFA500);
  color: var(--text-dark);
  text-decoration: none;
  border-radius: 5px;
  font-size: 18px;
  font-weight: bold;
  margin-top: 30px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px var(--shadow-medium);
}

.page-index__cta-button:hover {
  background: linear-gradient(135deg, #FFA500, #FFC107);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px var(--shadow-medium);
}

/* Game Leaderboard Section */
.page-index__game-leaderboard-section {
  padding: 40px 20px;
  background: var(--background-dark);
  color: var(--text-light);
}

.page-index__page-title {
  font-size: 32px;
  font-weight: bold;
  color: var(--secondary-color);
  text-align: center;
  margin-bottom: 40px;
}

.page-index__game-leaderboard {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.page-index__game-card {
  background: var(--text-light);
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 20px;
  display: flex;
  align-items: center;
  color: var(--text-dark);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-index__game-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px var(--shadow-medium);
}

.page-index__game-card-segment {
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100%;
}

.page-index__game-card-segment:not(:first-child) {
  border-left: 1px solid var(--border-light);
}

.page-index__segment-1 {
  flex-shrink: 0;
  width: 120px; /* Fixed width */
  padding-left: 0;
  padding-right: 20px;
  flex-direction: row;
  gap: 10px;
}

.page-index__rank-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-weight: bold;
  font-size: 16px;
  flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.page-index__rank-1 {
  background: linear-gradient(135deg, #FFD700, #FFA500); /* Gold */
}

.page-index__rank-2 {
  background: linear-gradient(135deg, #C0C0C0, #A0A0A0); /* Silver */
}

.page-index__rank-3 {
  background: linear-gradient(135deg, #CD7F32, #B87333); /* Bronze */
}

.page-index__rank-badge:not(.page-index__rank-1):not(.page-index__rank-2):not(.page-index__rank-3) {
  background: linear-gradient(135deg, #ff6b35, #ff8c42); /* Orange for 4th+ */
}

.page-index__game-icon {
  max-width: 80px;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
}

.page-index__segment-2 {
  flex: 1; /* Flexible width */
  text-align: center;
}

.page-index__game-name {
  font-size: 24px;
  font-weight: bold;
  color: var(--text-dark);
  margin-bottom: 8px;
  text-align: center;
}

.page-index__game-name-link {
  color: var(--text-dark);
  text-decoration: none;
  transition: color 0.3s ease, text-decoration 0.3s ease;
}

.page-index__game-name-link:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.page-index__game-description {
  font-size: 14px;
  color: var(--text-dark);
  font-weight: bold;
  text-align: center;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.page-index__game-description a {
  color: #0066cc;
  font-weight: bold;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index__game-description a:hover {
  color: #004499;
  text-decoration: underline;
}

.page-index__segment-3 {
  flex-shrink: 0;
  width: 150px; /* Fixed width */
}

.page-index__game-rating {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--secondary-color);
  font-size: 16px;
  margin-bottom: 8px;
  font-weight: bold;
}

.page-index__stars {
  color: var(--secondary-color);
  font-weight: bold;
}

.page-index__rating-number {
  font-weight: bold;
  color: var(--text-dark);
}

.page-index__promotion-text {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 14px;
}

.page-index__promotion-link {
  color: #0066cc;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-index__promotion-link:hover {
  color: #004499;
  text-decoration: underline;
}

.page-index__hot-badge {
  background: #dc3545;
  color: var(--text-light);
  padding: 3px 8px;
  border-radius: 3px;
  font-size: 12px;
  font-weight: bold;
}

.page-index__segment-4 {
  flex-shrink: 0;
  width: 180px; /* Fixed width for buttons */
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.page-index__btn-download,
.page-index__btn-review {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 15px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: bold;
  text-align: center;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 8px var(--shadow-light);
  border: none;
  width: 100%;
  box-sizing: border-box;
}

.page-index__btn-download {
  background: linear-gradient(135deg, #4CAF50, #2E8B57); /* Greenish for download */
  color: var(--text-light);
}

.page-index__btn-download:hover {
  background: linear-gradient(135deg, #2E8B57, #4CAF50);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px var(--shadow-medium);
}

.page-index__btn-review {
  background: linear-gradient(135deg, #007bff, #0056b3); /* Blueish for review */
  color: var(--text-light);
}

.page-index__btn-review:hover {
  background: linear-gradient(135deg, #0056b3, #007bff);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px var(--shadow-medium);
}

/* Brand Review Content Section */
.page-index__review-content-section {
  padding: 40px 20px;
  background: var(--background-dark); /* Match body background */
  color: var(--text-light);
}

.page-index__review-content-container {
  max-width: 1400px; /* Wider than leaderboard */
  margin: 0 auto;
}

.page-index__review-content-card {
  background: var(--text-light); /* White background for readability */
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 40px;
  color: var(--text-dark); /* Dark text for light background */
}

.page-index__review-title {
  font-size: 28px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 24px;
  text-align: center;
}

.page-index__review-subtitle {
  font-size: 20px;
  font-weight: bold;
  color: var(--primary-color);
  margin-top: 24px;
  margin-bottom: 12px;
}

.page-index__review-body {
  line-height: 1.7;
}

.page-index__review-body p {
  margin-bottom: 16px;
  font-size: 16px;
}

/* Homepage Introduction Section */
.page-index__intro-section {
  padding: 60px 20px;
  background: var(--background-dark);
  color: var(--text-light);
}

.page-index__intro-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  background: var(--text-light);
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 40px;
  color: var(--text-dark);
}

.page-index__intro-title {
  font-size: 32px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.page-index__intro-description {
  font-size: 18px;
  color: var(--text-dark);
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-index__feature-item {
  background: var(--background-light);
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-dark);
}

.page-index__feature-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.page-index__feature-icon {
  width: 120px; /* Increased size for content image, not small icon */
  height: auto;
  margin-bottom: 15px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.page-index__feature-title {
  font-size: 22px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

/* Core Game/Service Introduction Section */
.page-index__games-showcase-section {
  padding: 60px 20px;
  background: var(--background-dark);
  color: var(--text-light);
}

.page-index__games-showcase-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  background: var(--text-light);
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 40px;
  color: var(--text-dark);
}

.page-index__games-showcase-title {
  font-size: 32px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.page-index__games-showcase-description {
  font-size: 18px;
  color: var(--text-dark);
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-index__game-category-card {
  background: var(--background-light);
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-dark);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-index__game-category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.page-index__category-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 15px;
}

.page-index__category-title {
  font-size: 22px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.page-index__category-link {
  display: inline-block;
  margin-top: 15px;
  padding: 10px 20px;
  background: var(--primary-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-index__category-link:hover {
  background: #2b3d63;
}

/* Promotions Section */
.page-index__promotions-section {
  padding: 60px 20px;
  background: var(--background-dark);
  color: var(--text-light);
}

.page-index__promotions-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  background: var(--text-light);
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 40px;
  color: var(--text-dark);
}

.page-index__promotions-title {
  font-size: 32px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.page-index__promotions-description {
  font-size: 18px;
  color: var(--text-dark);
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-index__promo-card {
  background: var(--background-light);
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: var(--text-dark);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-index__promo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.page-index__promo-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 15px;
}

.page-index__promo-title {
  font-size: 22px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.page-index__promo-button {
  display: inline-block;
  margin-top: 15px;
  padding: 10px 20px;
  background: var(--secondary-color);
  color: var(--text-dark);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-index__promo-button:hover {
  background: #e0b800;
}

/* Latest Blog Content Section */
.page-index__blog-section {
  padding: 60px 20px;
  background: var(--background-dark);
  color: var(--text-light);
}

.page-index__blog-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  background: var(--text-light);
  border-radius: 8px;
  box-shadow: 0 2px 8px var(--shadow-light);
  padding: 40px;
  color: var(--text-dark);
}

.page-index__blog-title {
  font-size: 32px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.page-index__blog-description {
  font-size: 18px;
  color: var(--text-dark);
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-index__blog-card {
  background: var(--background-light);
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  color: var(--text-dark);
  text-align: left;
}

.page-index__blog-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

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

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

.page-index__blog-card-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-index__blog-card-title a {
  color: var(--primary-color);
  text-decoration: none;
}

.page-index__blog-card-title a:hover {
  text-decoration: underline;
}

.page-index__blog-excerpt {
  font-size: 15px;
  color: #555;
  margin-bottom: 15px;
}

.page-index__blog-date {
  font-size: 13px;
  color: #888;
}

.page-index__view-all-button-wrapper {
  margin-top: 40px;
}

.page-index__view-all-button {
  display: inline-block;
  padding: 12px 30px;
  background: var(--primary-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.page-index__view-all-button:hover {
  background: #2b3d63;
}

/* Responsive Design */

/* All images responsive by default */
.page-index img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Mobile-specific adjustments */
@media (max-width: 768px) {
  .page-index__hero-section {
    padding-top: 160px !important; /* Mobile: Adjust for fixed header */
    padding-bottom: 40px;
    padding-left: 15px;
    padding-right: 15px;
  }
  
  .page-index__hero-title {
    font-size: 32px;
  }
  
  .page-index__hero-description {
    font-size: 16px;
  }
  
  .page-index__cta-button {
    padding: 12px 30px;
    font-size: 16px;
  }

  .page-index__page-title,
  .page-index__review-title,
  .page-index__intro-title,
  .page-index__games-showcase-title,
  .page-index__promotions-title,
  .page-index__blog-title {
    font-size: 26px;
    margin-bottom: 25px;
  }

  .page-index__game-card {
    flex-direction: column;
    align-items: stretch;
    padding: 15px;
  }

  .page-index__game-card-segment {
    width: 100% !important;
    padding: 10px 0 !important;
    border-left: none !important;
    border-bottom: 1px solid var(--border-light);
  }
  
  .page-index__game-card-segment:last-child {
    border-bottom: none;
  }

  .page-index__segment-1 {
    flex-direction: row;
    justify-content: center;
    align-items: center;
    width: 100%;
  }
  
  .page-index__game-icon {
    max-width: 60px;
  }

  .page-index__game-name {
    font-size: 20px;
  }

  .page-index__game-description {
    font-size: 13px;
    line-height: 1.4;
  }

  .page-index__segment-3 {
    width: 100%;
    flex-direction: row;
    justify-content: center;
    gap: 20px;
  }
  
  .page-index__game-rating, .page-index__promotion-text {
    margin-bottom: 0;
  }

  .page-index__segment-4 {
    width: 100% !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
  }
  
  .page-index__btn-download,
  .page-index__btn-review {
    max-width: 100% !important;
    width: 100% !important;
    font-size: 12px !important;
    padding: 8px 12px !important;
    white-space: normal;
    word-wrap: break-word;
    min-width: auto;
  }

  .page-index__review-content-section,
  .page-index__intro-section,
  .page-index__games-showcase-section,
  .page-index__promotions-section,
  .page-index__blog-section {
    padding: 20px 15px;
  }
  
  .page-index__review-content-card,
  .page-index__intro-container,
  .page-index__games-showcase-container,
  .page-index__promotions-container,
  .page-index__blog-container {
    padding: 24px 20px;
  }
  
  .page-index__review-subtitle,
  .page-index__feature-title,
  .page-index__category-title,
  .page-index__promo-title,
  .page-index__blog-card-title {
    font-size: 18px;
  }
  
  .page-index__review-body p,
  .page-index__intro-description,
  .page-index__games-showcase-description,
  .page-index__promotions-description,
  .page-index__blog-excerpt {
    font-size: 15px;
  }
  
  .page-index__feature-icon {
    width: 100px; /* Adjusted for mobile */
  }
  
  /* Ensure all images and their containers are responsive */
  .page-index__section,
  .page-index__card,
  .page-index__container,
  .page-index__intro-features,
  .page-index__game-categories,
  .page-index__promo-grid,
  .page-index__blog-grid {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0px !important; /* Adjusted for inner content cards */
    padding-right: 0px !important;
  }
  
  .page-index__game-card-segment:first-child {
    padding-left: 10px !important;
  }
}

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

/* Mobile-specific force responsiveness for all image containers */
@media (max-width: 768px) {
  .page-index img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-index__hero-image,
  .page-index__game-icon,
  .page-index__feature-icon,
  .page-index__category-image,
  .page-index__promo-image,
  .page-index__blog-image {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
}