/* BEM: page-game-bai__element-name */

.page-game-bai {
  --primary: #FF8C1A;
  --secondary: #FFA53A;
  --card-bg: #17191F;
  --bg: #0D0E12;
  --text-main: #FFF3E6;
  --border: #A84F0C;
  --glow: #FFB04D;
  --deep-orange: #D96800;
  --btn-gradient: linear-gradient(180deg, #FFA53A 0%, #D96800 100%);
  background: var(--bg);
  color: var(--text-main);
  font-family: 'Be Vietnam Pro', system-ui, sans-serif;
  line-height: 1.6;
}

/* Hero Section - Image on top, content below */
.page-game-bai__hero {
  padding-top: 10px;
}

.page-game-bai__hero-image-wrapper {
  width: 100%;
  max-width: 1020px;
  margin: 0 auto;
}

.page-game-bai__hero-image {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(255, 140, 26, 0.15);
}

.page-game-bai__hero-content {
  text-align: center;
  padding: 16px 16px 0;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
}

.page-game-bai__hero-title {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  max-width: 720px;
  margin: 0 auto 8px;
  color: var(--text-main);
}

.page-game-bai__hero-subtitle {
  max-width: 640px;
  margin: 0 auto;
  color: rgba(255, 243, 230, 0.85);
}

.page-game-bai__hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

/* Button Base */
.page-game-bai__btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, opacity .2s;
  text-align: center;
}

.page-game-bai__btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 140, 26, 0.3);
}

/* Primary Button - Gradient */
.page-game-bai__btn--primary {
  background: var(--btn-gradient);
  color: #fff;
}

/* Secondary Button */
.page-game-bai__btn--secondary {
  background: transparent;
  color: var(--text-main);
  border: 2px solid var(--deep-orange);
}

.page-game-bai__btn--secondary:hover {
  background: rgba(255, 140, 26, 0.1);
}

/* Intro Section */
.page-game-bai__intro-container {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 16px;
}

.page-game-bai__intro-title {
  color: var(--secondary);
  font-weight: 700;
  margin-bottom: 12px;
  text-align: center;
}

.page-game-bai__intro-text {
  margin-bottom: 12px;
}

/* Section Title */
.page-game-bai__section-title {
  color: var(--secondary);
  font-weight: 700;
  text-align: center;
  margin-bottom: 24px;
}

/* Popular Games */
.page-game-bai__game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 16px;
}

.page-game-bai__game-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
}

.page-game-bai__game-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(255, 140, 26, 0.2);
}

.page-game-bai__game-image {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.page-game-bai__game-name {
  color: var(--secondary);
  font-weight: 700;
  margin: 12px 0 8px;
}

.page-game-bai__game-desc {
  color: rgba(255, 243, 230, 0.8);
  margin-bottom: 16px;
  font-size: 0.95rem;
}

/* Features */
.page-game-bai__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  max-width: 1020px;
  margin: 0 auto;
  padding: 0 16px;
}

.page-game-bai__feature-item {
  text-align: center;
  padding: 16px;
}

.page-game-bai__feature-image {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.page-game-bai__feature-title {
  color: var(--secondary);
  font-weight: 600;
  margin: 12px 0 8px;
}

.page-game-bai__feature-desc {
  color: rgba(255, 243, 230, 0.8);
}

/* Guide Section */
.page-game-bai__guide-inner {
  max-width: 1020px;
  margin: 0 auto;
  padding: 40px 16px;
}

.page-game-bai__guide-title {
  color: var(--secondary);
  font-weight: 700;
  text-align: center;
  margin-bottom: 8px;
}

.page-game-bai__guide-step {
  text-align: center;
  color: rgba(255, 243, 230, 0.8);
  margin-bottom: 24px;
}

.page-game-bai__guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.page-game-bai__guide-figure {
  margin: 0;
  text-align: center;
}

.page-game-bai__guide-figure img {
  width: 100%;
  max-width: 400px;
  height: auto;
  border-radius: 8px;
}

.page-game-bai__guide-figure figcaption {
  color: var(--text-main);
  margin-top: 8px;
  font-size: 0.95rem;
}

/* Promo Section */
.page-game-bai__promo {
  text-align: center;
  padding: 40px 16px;
  background: linear-gradient(180deg, rgba(255, 140, 26, 0.1), rgba(217, 104, 0, 0.05));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.page-game-bai__promo-title {
  color: var(--secondary);
  font-weight: 700;
  margin-bottom: 8px;
}

.page-game-bai__promo-text {
  max-width: 640px;
  margin: 0 auto 20px;
  color: rgba(255, 243, 230, 0.85);
}

/* FAQ Section */
.page-game-bai__faq {
  max-width: 700px;
  margin: 0 auto;
  padding: 40px 16px;
}

.page-game-bai__faq-title {
  color: var(--secondary);
  font-weight: 700;
  text-align: center;
  margin-bottom: 16px;
}

.page-game-bai__faq-item {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 12px;
  padding: 12px 16px;
}

.page-game-bai__faq-item summary {
  cursor: pointer;
  font-weight: 500;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.page-game-bai__faq-icon {
  display: inline-block;
  width: 24px;
  height: 24px;
  background: var(--btn-gradient);
  border-radius: 50%;
  color: #fff;
  text-align: center;
  line-height: 24px;
  font-weight: 700;
  flex-shrink: 0;
}

.page-game-bai__faq-answer {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
  color: rgba(255, 243, 230, 0.85);
}

@media (max-width: 1024px) {
  .page-game-bai__hero {
    padding-top: 8px;
  }
}

@media (max-width: 768px) {
  .page-game-bai__hero {
    padding-top: 8px;
  }

  .page-game-bai__hero-image {
    aspect-ratio: 2/1;
    object-fit: cover;
  }

  .page-game-bai__hero-title {
    font-size: 1.1rem;
  }

  .page-game-bai__hero-actions .page-game-bai__btn {
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
  }

  .page-game-bai__img,
  .page-game-bai :is(img) {
    max-width: 100% !important;
    height: auto !important;
  }

  .page-game-bai {
    max-width: 100%;
    overflow-x: hidden;
  }
}