/* style/game-rules.css */
:root {
  --cpc188-primary: #11A84E;
  --cpc188-secondary: #22C768;
  --cpc188-bg-dark: #08160F; /* Background */
  --cpc188-card-bg: #11271B; /* Card BG */
  --cpc188-text-main: #F2FFF6; /* Text Main */
  --cpc188-text-secondary: #A7D9B8; /* Text Secondary */
  --cpc188-border: #2E7A4E;
  --cpc188-glow: #57E38D;
  --cpc188-gold: #F2C14E;
  --cpc188-divider: #1E3A2A;
  --cpc188-deep-green: #0A4B2C;
  --cpc188-btn-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

.page-game-rules {
  background-color: var(--cpc188-bg-dark);
  color: var(--cpc188-text-main);
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

.page-game-rules__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 10px; /* Small top padding, body handles header offset */
  padding-bottom: 60px;
  overflow: hidden;
}

.page-game-rules__hero-image-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
  margin-bottom: 30px;
}

.page-game-rules__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: brightness(0.7);
}

.page-game-rules__hero-content {
  max-width: 900px;
  padding: 0 20px;
  z-index: 10;
  margin-top: -80px; /* Pull content slightly up over image for visual flow */
}

.page-game-rules__main-title {
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 700;
  color: var(--cpc188-gold);
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 0 0 10px rgba(87, 227, 141, 0.5);
}

.page-game-rules__description {
  font-size: 1.1rem;
  color: var(--cpc188-text-secondary);
  margin-bottom: 30px;
}

.page-game-rules__section {
  padding: 60px 20px;
  text-align: center;
  background-color: var(--cpc188-bg-dark);
  color: var(--cpc188-text-main);
}

.page-game-rules__container {
  max-width: 1200px;
  margin: 0 auto;
}

.page-game-rules__section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  color: var(--cpc188-primary);
  margin-bottom: 40px;
  position: relative;
  padding-bottom: 15px;
}

.page-game-rules__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: var(--cpc188-btn-gradient);
  border-radius: 2px;
}

.page-game-rules__text-block {
  font-size: 1rem;
  color: var(--cpc188-text-secondary);
  margin-bottom: 20px;
  text-align: left;
}

.page-game-rules__cta-button {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 8px;
  background: var(--cpc188-btn-gradient);
  color: #ffffff;
  text-decoration: none;
  font-weight: bold;
  font-size: 1rem;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(34, 199, 104, 0.4);
  margin: 10px;
}

.page-game-rules__cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(34, 199, 104, 0.6);
}

.page-game-rules__btn-secondary {
  background: none;
  border: 2px solid var(--cpc188-primary);
  color: var(--cpc188-primary);
  box-shadow: none;
}

.page-game-rules__btn-secondary:hover {
  background: rgba(34, 199, 104, 0.1);
  color: var(--cpc188-text-main);
  box-shadow: none;
}

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

.page-game-rules__rule-card {
  background-color: var(--cpc188-card-bg);
  border-radius: 10px;
  padding: 25px;
  text-align: left;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  border: 1px solid var(--cpc188-divider);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  color: var(--cpc188-text-main);
}

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

.page-game-rules__card-title {
  font-size: 1.4rem;
  color: var(--cpc188-primary);
  margin-bottom: 15px;
  line-height: 1.3;
}

.page-game-rules__rule-card p {
  font-size: 0.95rem;
  color: var(--cpc188-text-secondary);
}

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

.page-game-rules__game-category {
  background-color: var(--cpc188-card-bg);
  border-radius: 10px;
  padding: 30px;
  margin-bottom: 40px;
  text-align: left;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  border: 1px solid var(--cpc188-divider);
  color: var(--cpc188-text-main);
}

.page-game-rules__category-title {
  font-size: 1.6rem;
  color: var(--cpc188-gold);
  margin-bottom: 20px;
}

.page-game-rules__category-image {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 25px;
}

.page-game-rules__list {
  list-style: none;
  padding-left: 0;
  margin-bottom: 20px;
  text-align: left;
}

.page-game-rules__list li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 15px;
  color: var(--cpc188-text-secondary);
  font-size: 1rem;
}

.page-game-rules__list li::before {
  content: '✔️';
  position: absolute;
  left: 0;
  color: var(--cpc188-primary);
  font-weight: bold;
}

.page-game-rules__list li strong {
  color: var(--cpc188-text-main);
}

.page-game-rules__conclusion p a {
  color: var(--cpc188-gold);
  text-decoration: underline;
}

.page-game-rules__conclusion p a:hover {
  color: var(--cpc188-primary);
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-game-rules__hero-content {
    margin-top: -50px;
  }
  .page-game-rules__main-title {
    font-size: clamp(2rem, 5vw, 3rem);
  }
  .page-game-rules__section-title {
    font-size: clamp(1.6rem, 4vw, 2.5rem);
  }
}

@media (max-width: 768px) {
  .page-game-rules__hero-section {
    padding-bottom: 40px;
  }
  .page-game-rules__hero-content {
    margin-top: -30px;
    padding: 0 15px;
  }
  .page-game-rules__main-title {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
  }
  .page-game-rules__description {
    font-size: 1rem;
  }
  .page-game-rules__section {
    padding: 40px 15px;
  }
  .page-game-rules__section-title {
    font-size: clamp(1.4rem, 5vw, 2rem);
  }
  .page-game-rules__rule-card-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .page-game-rules__cta-button,
  .page-game-rules__btn-primary,
  .page-game-rules__btn-secondary,
  .page-game-rules a[class*="button"],
  .page-game-rules a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    margin: 5px 0 !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-game-rules__cta-group {
    flex-direction: column;
    gap: 10px;
  }
  .page-game-rules img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-game-rules__section,
  .page-game-rules__card,
  .page-game-rules__container,
  .page-game-rules__game-category,
  .page-game-rules__rule-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
}

@media (max-width: 480px) {
  .page-game-rules__main-title {
    font-size: clamp(1.5rem, 7vw, 2.2rem);
  }
  .page-game-rules__description {
    font-size: 0.9rem;
  }
  .page-game-rules__section-title {
    font-size: clamp(1.2rem, 6vw, 1.8rem);
  }
  .page-game-rules__rule-card,
  .page-game-rules__game-category {
    padding: 20px;
  }
  .page-game-rules__card-title {
    font-size: 1.2rem;
  }
  .page-game-rules__category-title {
    font-size: 1.4rem;
  }
  .page-game-rules__text-block, .page-game-rules__list li {
    font-size: 0.9rem;
  }
}