/* style/game-library.css */

/* Base styles for the page */
.page-game-library {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --card-bg: #11271B;
  --page-bg: #08160F;
  --text-main: #F2FFF6;
  --text-secondary: #A7D9B8;
  --border-color: #2E7A4E;
  --glow-color: #57E38D;
  --gold-color: #F2C14E;
  --divider-color: #1E3A2A;
  --deep-green-color: #0A4B2C;

  font-family: 'Arial', sans-serif;
  color: var(--text-main);
  background-color: var(--page-bg);
  line-height: 1.6;
}

.page-game-library__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.page-game-library__section {
  padding: 60px 0;
  text-align: center;
}

.page-game-library__dark-bg {
  background-color: var(--page-bg);
  color: var(--text-main);
}

.page-game-library__deep-green-bg {
  background-color: var(--deep-green-color);
  color: var(--text-main);
}

.page-game-library__card-bg {
  background-color: var(--card-bg);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.page-game-library__section-title {
  font-size: 2.8em;
  font-weight: 700;
  color: var(--gold-color);
  margin-bottom: 20px;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.page-game-library__section-title strong,
.page-game-library__main-title strong {
  color: var(--glow-color);
}

.page-game-library__description {
  font-size: 1.1em;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-game-library__text-block {
  font-size: 1.05em;
  color: var(--text-secondary);
  text-align: left;
  margin-bottom: 1.5em;
}

.page-game-library__text-block strong {
  color: var(--text-main);
}

.page-game-library__text-link {
  color: var(--glow-color);
  text-decoration: underline;
}

/* Buttons */
.page-game-library__btn-primary,
.page-game-library__btn-secondary {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1em;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-game-library__btn-primary {
  background: var(--button-gradient);
  color: var(--text-main);
  border: none;
  box-shadow: 0 4px 15px rgba(0, 255, 100, 0.3);
}

.page-game-library__btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 255, 100, 0.4);
  opacity: 0.9;
}

.page-game-library__btn-secondary {
  background: transparent;
  color: var(--glow-color);
  border: 2px solid var(--glow-color);
  margin-left: 20px;
}

.page-game-library__btn-secondary:hover {
  background: var(--glow-color);
  color: var(--page-bg);
  transform: translateY(-2px);
  opacity: 0.9;
}

.page-game-library__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.page-game-library__cta-buttons--center {
  margin-top: 50px;
}

/* Hero Section */
.page-game-library__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px 0 60px 0; /* body handles padding-top from header, only a small decorative padding-top here */
  overflow: hidden;
}

.page-game-library__hero-image-wrapper {
  width: 100%;
  max-height: 700px;
  overflow: hidden;
  position: relative;
  z-index: 0;
}

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

.page-game-library__hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 40px 20px;
  max-width: 900px;
  margin-top: -150px; /* Pull content slightly over image, but not covering text */
  background: linear-gradient(180deg, rgba(8, 22, 15, 0.8) 0%, rgba(8, 22, 15, 1) 100%);
  border-radius: 15px;
  padding-bottom: 60px;
}

.page-game-library__main-title {
  font-size: clamp(2.5em, 5vw, 3.8em);
  font-weight: 800;
  color: var(--gold-color);
  margin-bottom: 20px;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

/* Game Categories Grid */
.page-game-library__game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-game-library__game-card {
  border-radius: 15px;
  overflow: hidden;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-game-library__game-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 255, 100, 0.2);
}

.page-game-library__game-card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
}

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

.page-game-library__game-card-title {
  font-size: 1.6em;
  font-weight: 700;
  color: var(--glow-color);
  margin-bottom: 15px;
  line-height: 1.3;
}

.page-game-library__game-card-title a {
  color: inherit;
  text-decoration: none;
}

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

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

.page-game-library__game-card-btn {
  margin-top: auto;
  width: 100%;
  margin-left: 0;
}

/* Advantages Section */
.page-game-library__advantage-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-game-library__advantage-item {
  border-radius: 15px;
  padding: 30px;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.page-game-library__advantage-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 255, 100, 0.2);
}

.page-game-library__advantage-icon {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 20px;
  display: block; /* Ensure it respects width/height */
}

.page-game-library__advantage-title {
  font-size: 1.5em;
  font-weight: 700;
  color: var(--glow-color);
  margin-bottom: 15px;
}

.page-game-library__advantage-text {
  font-size: 0.95em;
  color: var(--text-secondary);
}

/* How to Start Section */
.page-game-library__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-game-library__step-item {
  border-radius: 15px;
  padding: 30px;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.page-game-library__step-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 255, 100, 0.2);
}

.page-game-library__step-icon {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin-bottom: 20px;
  display: block;
}

.page-game-library__step-title {
  font-size: 1.5em;
  font-weight: 700;
  color: var(--glow-color);
  margin-bottom: 15px;
}

.page-game-library__step-text {
  font-size: 0.95em;
  color: var(--text-secondary);
}

/* Promotions Section */
.page-game-library__promo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 50px;
}

.page-game-library__promo-card {
  border-radius: 15px;
  overflow: hidden;
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-game-library__promo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 255, 100, 0.2);
}

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

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

.page-game-library__promo-title {
  font-size: 1.6em;
  font-weight: 700;
  color: var(--gold-color);
  margin-bottom: 15px;
}

.page-game-library__promo-text {
  font-size: 0.95em;
  color: var(--text-secondary);
  margin-bottom: 20px;
  flex-grow: 1;
}

/* FAQ Section */
.page-game-library__faq-list {
  margin-top: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  text-align: left;
}

.page-game-library__faq-item {
  margin-bottom: 15px;
  border-radius: 10px;
  overflow: hidden;
  transition: background-color 0.3s ease;
}

.page-game-library__faq-item[open] {
  background-color: var(--deep-green-color);
}

.page-game-library__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.15em;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  list-style: none;
  background-color: var(--card-bg);
  border-radius: 10px;
}

.page-game-library__faq-item[open] .page-game-library__faq-question {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

.page-game-library__faq-question::-webkit-details-marker {
  display: none;
}

.page-game-library__faq-qtext {
  flex-grow: 1;
  color: var(--glow-color);
}

.page-game-library__faq-toggle {
  font-size: 1.8em;
  line-height: 1;
  margin-left: 15px;
  color: var(--gold-color);
}

.page-game-library__faq-answer {
  padding: 20px 25px;
  font-size: 1em;
  color: var(--text-secondary);
  background-color: var(--deep-green-color);
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
}

.page-game-library__faq-answer p {
  margin: 0;
  text-align: left;
}

/* Why Choose Section */
.page-game-library__why-choose .page-game-library__description {
  margin-bottom: 20px;
}

/* Global image settings for content area to prevent small icons */
.page-game-library img {
  min-width: 200px;
  min-height: 200px;
  object-fit: cover;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-game-library__section-title {
    font-size: 2.2em;
  }

  .page-game-library__hero-content {
    margin-top: -100px;
    padding: 30px 20px;
    padding-bottom: 50px;
  }

  .page-game-library__main-title {
    font-size: clamp(2em, 4.5vw, 3em);
  }

  .page-game-library__game-card-image,
  .page-game-library__promo-image {
    height: 220px;
  }
}

@media (max-width: 768px) {
  .page-game-library__section {
    padding: 40px 0;
  }

  .page-game-library__container {
    padding: 0 15px;
  }

  .page-game-library__section-title {
    font-size: 1.8em;
    margin-bottom: 15px;
  }

  .page-game-library__description,
  .page-game-library__text-block {
    font-size: 1em;
  }

  .page-game-library__hero-section {
    padding: 10px 0 40px 0;
  }

  .page-game-library__hero-content {
    margin-top: -80px;
    padding: 25px 15px;
    padding-bottom: 40px;
  }

  .page-game-library__main-title {
    font-size: clamp(1.8em, 6vw, 2.5em);
    margin-bottom: 15px;
  }

  .page-game-library__cta-buttons {
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
  }

  .page-game-library__btn-primary,
  .page-game-library__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    margin-left: 0 !important;
    padding: 12px 20px;
    font-size: 1em;
  }

  .page-game-library__game-grid,
  .page-game-library__advantage-list,
  .page-game-library__steps-grid,
  .page-game-library__promo-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 30px;
  }

  .page-game-library__game-card-image,
  .page-game-library__promo-image {
    height: 180px;
  }

  .page-game-library__game-card-title,
  .page-game-library__advantage-title,
  .page-game-library__step-title,
  .page-game-library__promo-title {
    font-size: 1.4em;
  }

  .page-game-library__faq-question {
    font-size: 1.05em;
    padding: 15px 20px;
  }

  .page-game-library__faq-answer {
    padding: 15px 20px;
  }

  /* Force responsive images and containers */
  .page-game-library img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    min-width: unset !important;
    min-height: unset !important;
  }

  .page-game-library__section,
  .page-game-library__card,
  .page-game-library__container,
  .page-game-library__hero-section,
  .page-game-library__hero-image-wrapper,
  .page-game-library__hero-content,
  .page-game-library__game-card,
  .page-game-library__advantage-item,
  .page-game-library__step-item,
  .page-game-library__promo-card,
  .page-game-library__faq-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden;
  }
}