/* style/index.css */
:root {
  --primary-color: #FFD700; /* Gold */
  --secondary-color: #8B0000; /* Dark Red */
  --text-dark: #333333;
  --text-light: #ffffff;
  --bg-light: #f1f3f5;
  --bg-white: #ffffff;
  --border-light: #e0e0e0;
}

.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(--dark-bg-1); /* Assuming dark-bg-1 from shared.css is dark */
}

/* HERO Section */
.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(--secondary-color);
  overflow: hidden;
}

.page-index__hero-container {
  position: relative;
  width: 100%;
  max-width: 1400px; /* Slightly wider for hero */
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.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: 12px;
  object-fit: cover;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

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

.page-index__hero-title {
  font-size: 3.5em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

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

.page-index__cta-button {
  display: inline-block;
  padding: 18px 45px;
  background: linear-gradient(135deg, var(--primary-color), #FFA500);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 10px;
  font-size: 1.2em;
  font-weight: bold;
  margin-top: 20px;
  transition: all 0.3s ease;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.25);
  border: none;
  cursor: pointer;
}

.page-index__cta-button:hover {
  background: linear-gradient(135deg, #FFA500, var(--primary-color));
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

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

.page-index__game-leaderboard-container {
  max-width: 1200px;
  margin: 0 auto;
}

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

.page-index__game-leaderboard {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.page-index__game-card {
  display: flex;
  align-items: center;
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

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

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

.page-index__segment-1 {
  min-width: 120px;
  max-width: 150px;
  padding-left: 0;
  flex-direction: row;
  gap: 15px;
}

.page-index__rank-badge {
  width: 35px; /* Adjusting size as per instruction */
  height: 35px; /* Adjusting size as per instruction */
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-weight: bold;
  font-size: 1.2em;
  flex-shrink: 0;
  box-shadow: 0 2px 5px 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); /* Default Orange */
}

.page-index__game-icon {
  max-width: 100px;
  height: auto;
  display: block;
  border-radius: 8px;
  flex-shrink: 0;
}

.page-index__segment-2 {
  flex: 1;
  text-align: center;
}

.page-index__game-name {
  font-size: 1.5em;
  font-weight: bold;
  color: var(--text-dark);
  margin-bottom: 8px;
  text-transform: uppercase;
  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: 0.95em;
  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;
}

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

.page-index__segment-3 {
  min-width: 160px;
  max-width: 200px;
  text-align: center;
}

.page-index__game-rating {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  font-size: 1.1em;
}

.page-index__stars {
  color: #FFD700;
  margin-right: 5px;
  font-weight: bold;
}

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

.page-index__promotion-text {
  font-size: 0.9em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.page-index__promotion-link {
  color: #0066cc;
  text-decoration: none;
  font-weight: bold;
}

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

.page-index__hot-badge {
  background: var(--secondary-color);
  color: var(--text-light);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.8em;
  font-weight: bold;
  text-transform: uppercase;
}

.page-index__segment-4 {
  min-width: 180px;
  max-width: 220px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.page-index__cta-button {
  width: 100%;
  padding: 12px 15px; /* Adjusted for better fit */
  font-size: 0.95em;
  font-weight: bold;
  text-align: center;
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  border: none;
  cursor: pointer;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
  line-height: 1.3; /* Adjust line height for wrapped text */
}

.page-index__btn-download {
  background: linear-gradient(135deg, var(--primary-color), #FFA500);
  color: var(--text-light);
}

.page-index__btn-download:hover {
  background: linear-gradient(135deg, #FFA500, var(--primary-color));
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.page-index__btn-review {
  background: var(--secondary-color);
  color: var(--text-light);
}

.page-index__btn-review:hover {
  background: #B22222;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

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

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

.page-index__review-content-card {
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 40px;
}

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

.page-index__review-content-card h3 {
  font-size: 1.6em;
  font-weight: bold;
  color: var(--text-dark);
  margin-top: 28px;
  margin-bottom: 15px;
}

.page-index__review-body p {
  margin-bottom: 16px;
  font-size: 1.1em;
  line-height: 1.7;
  color: var(--text-dark);
}

.page-index__review-body strong {
  color: var(--secondary-color);
}

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

.page-index__intro-container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-index__intro-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.page-index__intro-description {
  font-size: 1.1em;
  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: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 25px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, background 0.3s ease;
}

.page-index__feature-item:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.15);
}

.page-index__feature-icon {
  max-width: 100px; /* Min size 200x200 requirement for imageRequirements, but here it's an icon, so I'll generate a larger image and scale it down. */
  height: auto;
  margin-bottom: 15px;
  border-radius: 8px;
}

.page-index__feature-item h3 {
  font-size: 1.4em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.page-index__feature-item p {
  font-size: 0.95em;
  color: var(--text-light);
}

/* Core Games/Services Section */
.page-index__games-services-section {
  padding: 60px 20px;
  background: var(--bg-light);
  color: var(--text-dark);
}

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

.page-index__games-services-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--text-dark);
  text-align: center;
  margin-bottom: 40px;
}

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

.page-index__game-card-large {
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 25px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-index__game-card-large:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.page-index__game-card-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-index__game-card-title {
  font-size: 1.6em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.page-index__game-card-description {
  font-size: 1em;
  color: var(--text-dark);
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-index__game-card-button {
  display: inline-block;
  padding: 12px 25px;
  background: var(--secondary-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 8px;
  font-size: 1em;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-index__game-card-button:hover {
  background: #B22222;
}

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

.page-index__promotions-container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-index__promotions-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 20px;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.page-index__promotions-intro {
  font-size: 1.1em;
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

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

.page-index__promotion-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, background 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-index__promotion-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.15);
}

.page-index__promotion-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-index__promotion-card-title {
  font-size: 1.4em;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.page-index__promotion-card-description {
  font-size: 0.95em;
  color: var(--text-light);
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-index__promotion-button {
  display: inline-block;
  padding: 12px 25px;
  background: linear-gradient(135deg, var(--primary-color), #FFA500);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 8px;
  font-size: 1em;
  font-weight: bold;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-index__promotion-button:hover {
  background: linear-gradient(135deg, #FFA500, var(--primary-color));
  transform: translateY(-2px);
}

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

.page-index__blog-container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-index__blog-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--text-dark);
  text-align: center;
  margin-bottom: 40px;
}

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

.page-index__blog-card {
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.page-index__blog-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 12px 12px 0 0;
}

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

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

.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-summary {
  font-size: 0.95em;
  color: var(--text-dark);
  margin-bottom: 15px;
  flex-grow: 1;
}

.page-index__blog-date {
  font-size: 0.85em;
  color: #666666;
  margin-top: auto;
  margin-bottom: 15px;
}

.page-index__blog-readmore {
  display: inline-block;
  padding: 10px 20px;
  background: var(--secondary-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 8px;
  font-size: 0.9em;
  font-weight: bold;
  transition: background-color 0.3s ease;
  align-self: flex-start;
}

.page-index__blog-readmore:hover {
  background: #B22222;
}

.page-index__view-all-news {
  text-align: center;
  margin-top: 40px;
}

.page-index__view-all-button {
  display: inline-block;
  padding: 15px 35px;
  background: var(--primary-color);
  color: var(--text-light);
  text-decoration: none;
  border-radius: 10px;
  font-size: 1.1em;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.page-index__view-all-button:hover {
  background: #FFA500;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 1200px) {
  .page-index__hero-title {
    font-size: 3em;
  }
  .page-index__page-title,
  .page-index__review-title,
  .page-index__intro-title,
  .page-index__games-services-title,
  .page-index__promotions-title,
  .page-index__blog-title {
    font-size: 2.2em;
  }
}

@media (max-width: 992px) {
  .page-index__hero-title {
    font-size: 2.5em;
  }
  .page-index__hero-description {
    font-size: 1.1em;
  }
  .page-index__cta-button {
    padding: 15px 35px;
    font-size: 1.1em;
  }
  .page-index__game-card {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
  }
  .page-index__game-card-segment {
    border-left: none !important;
    padding: 10px 15px;
    width: 100%;
  }
  .page-index__segment-1 {
    flex-direction: column;
    gap: 10px;
    min-width: unset;
    max-width: unset;
    width: 100%;
  }
  .page-index__segment-2 {
    order: 3;
  }
  .page-index__segment-3 {
    order: 2;
    flex-direction: row;
    gap: 15px;
    min-width: unset;
    max-width: unset;
    width: 100%;
  }
  .page-index__segment-4 {
    order: 4;
    flex-direction: row;
    gap: 10px;
    min-width: unset;
    max-width: unset;
    width: 100%;
  }
  .page-index__game-icon {
    max-width: 80px;
  }
  .page-index__rank-badge {
    width: 30px;
    height: 30px;
    font-size: 1em;
  }
  .page-index__game-name {
    font-size: 1.3em;
  }
  .page-index__game-description {
    font-size: 0.9em;
  }
  .page-index__game-rating,
  .page-index__promotion-text {
    justify-content: center;
  }
  .page-index__cta-button {
    flex: 1;
    font-size: 0.85em; /* Further reduce font size for mobile buttons */
    padding: 10px 10px; /* Further reduce padding for mobile buttons */
    line-height: 1.2;
  }
  .page-index__intro-features,
  .page-index__game-grid,
  .page-index__promotion-grid,
  .page-index__blog-grid {
    grid-template-columns: 1fr;
  }
  .page-index__feature-icon {
    max-width: 80px;
  }
  .page-index__game-card-image {
    height: 180px;
  }
  .page-index__promotion-image {
    height: 150px;
  }
}

@media (max-width: 768px) {
  .page-index__hero-section {
    padding-top: 160px !important; /* Mobile: Adjust for fixed header */
    padding-bottom: 40px;
  }
  .page-index__hero-title {
    font-size: 2em;
  }
  .page-index__hero-description {
    font-size: 1em;
  }
  .page-index__cta-button {
    padding: 12px 30px;
    font-size: 1em;
  }
  .page-index__page-title,
  .page-index__review-title,
  .page-index__intro-title,
  .page-index__games-services-title,
  .page-index__promotions-title,
  .page-index__blog-title {
    font-size: 1.8em;
  }
  .page-index__review-content-card {
    padding: 25px;
  }
  .page-index__review-content-card h3 {
    font-size: 1.4em;
  }
  .page-index__review-body p {
    font-size: 1em;
  }
  .page-index__intro-section,
  .page-index__games-services-section,
  .page-index__promotions-section,
  .page-index__blog-section {
    padding: 40px 15px;
  }
  .page-index img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-index__section,
  .page-index__card,
  .page-index__container,
  .page-index__hero-container,
  .page-index__game-leaderboard-container,
  .page-index__review-content-container,
  .page-index__intro-container,
  .page-index__games-services-container,
  .page-index__promotions-container,
  .page-index__blog-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}

@media (max-width: 480px) {
  .page-index__hero-title {
    font-size: 1.8em;
  }
  .page-index__hero-description {
    font-size: 0.9em;
  }
  .page-index__cta-button {
    padding: 10px 25px;
    font-size: 0.9em;
  }
  .page-index__page-title,
  .page-index__review-title,
  .page-index__intro-title,
  .page-index__games-services-title,
  .page-index__promotions-title,
  .page-index__blog-title {
    font-size: 1.5em;
  }
  .page-index__game-name {
    font-size: 1.1em;
  }
  .page-index__game-description {
    font-size: 0.8em;
  }
  .page-index__game-card-segment {
    padding: 8px 10px;
  }
  .page-index__cta-button {
    font-size: 0.8em; /* Smallest font size for buttons */
    padding: 8px 10px; /* Smallest padding for buttons */
  }
  .page-index__rank-badge {
    width: 28px;
    height: 28px;
    font-size: 0.9em;
  }
  .page-index__game-icon {
    max-width: 60px;
  }
}