:root {
  --phwin-gold: #FFD700;
  --phwin-blue: #1E90FF;
  --phwin-dark-text: #333333;
  --phwin-light-text: #ffffff;
  --phwin-background-light: #f5f5f5;
  --phwin-background-dark: #222222;
}

.page-index {
  color: var(--phwin-dark-text); /* Default body background is white, so use dark text */
}

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

.page-index__section-title {
  font-size: 2.5rem;
  color: var(--phwin-blue);
  text-align: center;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.page-index__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: var(--phwin-gold);
  border-radius: 2px;
}

.page-index__section-description {
  font-size: 1.1rem;
  text-align: center;
  color: #555;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-index__button {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  font-size: 1rem;
  cursor: pointer;
  border: none;
}

.page-index__button--primary {
  background-color: var(--phwin-gold);
  color: var(--phwin-dark-text);
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4);
}

.page-index__button--primary:hover {
  background-color: #e6c200;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6);
}

.page-index__button--secondary {
  background-color: var(--phwin-blue);
  color: var(--phwin-light-text);
  box-shadow: 0 4px 15px rgba(30, 144, 255, 0.4);
}

.page-index__button--secondary:hover {
  background-color: #1a7ae0;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(30, 144, 255, 0.6);
}

.page-index__button--outline {
  background-color: transparent;
  color: var(--phwin-blue);
  border: 2px solid var(--phwin-blue);
}

.page-index__button--outline:hover {
  background-color: var(--phwin-blue);
  color: var(--phwin-light-text);
}

.page-index__button--text {
  background: none;
  border: none;
  color: var(--phwin-blue);
  padding: 0;
  font-size: 1rem;
  text-decoration: underline;
}

.page-index__button--text:hover {
  color: #1a7ae0;
}

/* Hero Section */
.page-index__hero-section {
  position: relative;
  overflow: hidden;
  color: var(--phwin-light-text);
  text-align: center;
  padding-top: var(--header-offset, 120px); /* Ensure content is below fixed header */
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-index__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  filter: brightness(0.6);
}

.page-index__hero-container {
  position: relative;
  z-index: 1;
  padding: 40px 20px;
  max-width: 900px;
  margin: 0 auto;
}

.page-index__hero-content {
  background: rgba(0, 0, 0, 0.5);
  padding: 30px;
  border-radius: 15px;
}

.page-index__hero-title {
  font-size: 3.5rem;
  margin-bottom: 20px;
  line-height: 1.2;
  color: var(--phwin-gold);
}

.page-index__hero-description {
  font-size: 1.3rem;
  margin-bottom: 30px;
  line-height: 1.5;
  color: var(--phwin-light-text);
}

.page-index__hero-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
}

/* About Section */
.page-index__about-section {
  padding: 80px 0;
  background-color: var(--phwin-background-light);
}

.page-index__about-content {
  display: flex;
  gap: 40px;
  align-items: center;
}

.page-index__about-text {
  flex: 1;
  font-size: 1.1rem;
  line-height: 1.7;
}

.page-index__about-text p {
  margin-bottom: 20px;
}

.page-index__about-image {
  flex: 1;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  width: 100%;
  height: auto;
  min-width: 200px;
  min-height: 200px;
  object-fit: cover;
}

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

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

.page-index__game-card {
  background-color: var(--phwin-light-text);
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  text-align: center;
  padding-bottom: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-index__game-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  margin-bottom: 15px;
  min-width: 200px;
  min-height: 200px;
}

.page-index__game-title {
  font-size: 1.5rem;
  color: var(--phwin-blue);
  margin-bottom: 10px;
  padding: 0 15px;
}

.page-index__game-title a {
  color: inherit;
  text-decoration: none;
}

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

.page-index__game-text {
  font-size: 0.95rem;
  color: #666;
  margin-bottom: 20px;
  padding: 0 15px;
}

/* Promo Section */
.page-index__promo-section {
  padding: 80px 0;
  background-color: var(--phwin-background-light);
}

.page-index__promo-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.page-index__promo-card {
  display: flex;
  background-color: var(--phwin-light-text);
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-index__promo-image {
  width: 50%;
  height: auto;
  object-fit: cover;
  min-width: 200px;
  min-height: 200px;
}

.page-index__promo-content {
  flex: 1;
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.page-index__promo-title {
  font-size: 1.8rem;
  color: var(--phwin-blue);
  margin-bottom: 15px;
}

.page-index__promo-title a {
  color: inherit;
  text-decoration: none;
}

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

.page-index__promo-text {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 25px;
}

/* Login Guide Section */
.page-index__login-guide-section {
  padding: 80px 0;
}

.page-index__guide-content {
  display: flex;
  gap: 40px;
  align-items: center;
}

.page-index__guide-steps {
  flex: 1;
}

.page-index__step-card {
  background-color: var(--phwin-light-text);
  border-left: 5px solid var(--phwin-gold);
  padding: 20px 25px;
  margin-bottom: 20px;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.page-index__step-title {
  font-size: 1.4rem;
  color: var(--phwin-blue);
  margin-bottom: 10px;
}

.page-index__step-text {
  font-size: 1rem;
  color: #555;
}

.page-index__guide-actions {
  display: flex;
  gap: 20px;
  margin-top: 30px;
  justify-content: center;
}

.page-index__guide-image {
  flex: 1;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  width: 100%;
  height: auto;
  min-width: 200px;
  min-height: 200px;
  object-fit: cover;
}

/* App Download Section */
.page-index__app-download-section {
  padding: 80px 0;
  background-color: var(--phwin-blue);
  color: var(--phwin-light-text);
}

.page-index__app-content {
  display: flex;
  gap: 40px;
  align-items: center;
}

.page-index__app-text {
  flex: 1;
}

.page-index__app-download-section .page-index__section-title {
  color: var(--phwin-gold);
}

.page-index__app-download-section .page-index__section-description {
  color: var(--phwin-light-text);
  text-align: left;
  margin-bottom: 30px;
  margin-left: 0;
  margin-right: 0;
}

.page-index__app-image {
  flex: 1;
  max-width: 400px;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  width: 100%;
  height: auto;
  min-width: 200px;
  min-height: 200px;
  object-fit: cover;
}

/* Why Choose Section */
.page-index__why-choose-section {
  padding: 80px 0;
}

.page-index__why-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
}

.page-index__why-item {
  background-color: var(--phwin-background-light);
  padding: 25px;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  font-size: 1.05rem;
  line-height: 1.6;
  color: #444;
}

.page-index__why-item strong {
  color: var(--phwin-blue);
  font-size: 1.15rem;
  display: block;
  margin-bottom: 10px;
}

/* CTA Section */
.page-index__cta-section {
  padding: 80px 0;
  background: linear-gradient(135deg, var(--phwin-blue) 0%, #007bff 100%);
  text-align: center;
  color: var(--phwin-light-text);
}

.page-index__cta-title {
  font-size: 2.8rem;
  color: var(--phwin-gold);
  margin-bottom: 20px;
}

.page-index__cta-description {
  font-size: 1.2rem;
  margin-bottom: 40px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* Responsive Design */
@media (max-width: 992px) {
  .page-index__hero-title {
    font-size: 2.8rem;
  }
  .page-index__hero-description {
    font-size: 1.1rem;
  }
  .page-index__about-content, .page-index__guide-content, .page-index__app-content {
    flex-direction: column;
    text-align: center;
  }
  .page-index__about-image, .page-index__guide-image, .page-index__app-image {
    max-width: 100%;
  }
  .page-index__promo-card {
    flex-direction: column;
  }
  .page-index__promo-image {
    width: 100%;
    height: 300px;
  }
  .page-index__promo-content {
    padding: 20px;
  }
  .page-index__promo-title {
    font-size: 1.5rem;
  }
}

@media (max-width: 768px) {
  .page-index__hero-section {
    min-height: 500px;
  }
  .page-index__hero-title {
    font-size: 2.2rem;
  }
  .page-index__hero-description {
    font-size: 1rem;
  }
  .page-index__hero-actions {
    flex-direction: column;
    gap: 15px;
  }
  .page-index__button {
    width: 100%;
    max-width: 250px;
  }
  .page-index__section-title {
    font-size: 2rem;
  }
  .page-index__section-description {
    font-size: 1rem;
  }
  .page-index__games-section, .page-index__promo-section, .page-index__login-guide-section, .page-index__app-download-section, .page-index__why-choose-section, .page-index__cta-section {
    padding: 60px 0;
  }
  .page-index__game-grid {
    grid-template-columns: 1fr;
  }
  .page-index__promo-cards {
    gap: 30px;
  }
  .page-index__guide-actions {
    flex-direction: column;
    gap: 15px;
  }
  .page-index__app-download-section .page-index__section-description {
    text-align: center;
  }
  .page-index__app-text .page-index__button {
    margin: 0 auto;
  }
  /* Mobile content area images must not overflow */
  .page-index img {
    max-width: 100%;
    height: auto;
  }
}

@media (max-width: 576px) {
  .page-index__hero-title {
    font-size: 1.8rem;
  }
  .page-index__hero-description {
    font-size: 0.9rem;
  }
  .page-index__section-title {
    font-size: 1.8rem;
  }
  .page-index__cta-title {
    font-size: 2.2rem;
  }
}