/* BEM Naming: .page-blog__element-name */
/* Colors: #017439 (main), #FFFFFF (auxiliary), #C30808 (register/login), #FFFF00 (reg/login font) */

:root {
  --page-blog-primary-color: #017439;
  --page-blog-secondary-color: #FFFFFF;
  --page-blog-register-color: #C30808;
  --page-blog-login-color: #C30808;
  --page-blog-reg-login-font-color: #FFFF00;
  --page-blog-text-dark: #333333;
  --page-blog-text-light: #ffffff;
  --page-blog-background-light: #f8f8f8;
  --page-blog-border-color: #e0e0e0;
}

.page-blog {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--page-blog-text-dark);
  background-color: var(--secondary-color); /* Assuming body background is light */
}

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

.page-blog__section-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--page-blog-primary-color);
  text-align: center;
  margin-bottom: 40px;
}

.page-blog__sub-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--page-blog-primary-color);
  margin-top: 30px;
  margin-bottom: 15px;
}

.page-blog__description {
  font-size: 18px;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 30px;
  line-height: 1.8;
}

.page-blog__dark-section {
  background-color: var(--page-blog-primary-color);
  color: var(--page-blog-text-light);
}

.page-blog__dark-section .page-blog__section-title,
.page-blog__dark-section .page-blog__sub-title {
  color: var(--page-blog-text-light);
}

.page-blog__light-bg {
  background-color: var(--page-blog-background-light);
  color: var(--page-blog-text-dark);
}

/* Buttons */
.page-blog__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-blog__btn-primary {
  background-color: var(--page-blog-register-color); /* Using register color for primary CTA */
  color: var(--page-blog-text-light);
  border: 2px solid var(--page-blog-register-color);
}

.page-blog__btn-primary:hover {
  background-color: #e00;
  border-color: #e00;
}

.page-blog__btn-secondary {
  background-color: transparent;
  color: var(--page-blog-text-light);
  border: 2px solid var(--page-blog-text-light);
}

.page-blog__btn-secondary:hover {
  background-color: var(--page-blog-text-light);
  color: var(--page-blog-primary-color);
}

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  padding: 80px 0 60px;
  text-align: center;
  overflow: hidden;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
}

.page-blog__hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.page-blog__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.2; /* Subtle overlay for text readability */
}

.page-blog__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 15px;
}

.page-blog__main-title {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--page-blog-text-light);
  margin-bottom: 20px;
  max-width: 90%; /* Ensure H1 doesn't get too wide */
  margin-left: auto;
  margin-right: auto;
}

/* Latest Posts Section */
.page-blog__latest-posts {
  padding: 60px 0;
}

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

.page-blog__post-card {
  background-color: var(--page-blog-secondary-color);
  border-radius: 10px;
  overflow: hidden;
  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-blog__post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.page-blog__post-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

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

.page-blog__post-date {
  font-size: 14px;
  color: #666;
  margin-bottom: 10px;
}

.page-blog__post-title {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 15px;
}

.page-blog__post-title a {
  color: var(--page-blog-text-dark);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-blog__post-title a:hover {
  color: var(--page-blog-primary-color);
}

.page-blog__post-excerpt {
  font-size: 16px;
  color: #555;
  margin-bottom: 15px;
  flex-grow: 1;
}

.page-blog__read-more {
  display: inline-block;
  color: var(--page-blog-primary-color);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: color 0.3s ease;
}

.page-blog__read-more:hover {
  text-decoration: underline;
}

.page-blog__view-all {
  text-align: center;
}

/* Categories Section */
.page-blog__categories {
  padding: 50px 0;
  text-align: center;
}

.page-blog__category-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 15px;
}

.page-blog__category-item a {
  display: block;
  padding: 10px 20px;
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 25px;
  color: var(--page-blog-text-light);
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.page-blog__category-item a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: var(--page-blog-text-light);
}

/* Featured Article Section */
.page-blog__featured-article {
  padding: 60px 0;
}

.page-blog__text-block ol,
.page-blog__text-block ul {
  margin-left: 20px;
  margin-bottom: 20px;
}

.page-blog__text-block li {
  margin-bottom: 10px;
}

/* CTA Section */
.page-blog__cta-section {
  padding: 80px 0;
}

.page-blog__cta-section .page-blog__container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
}

.page-blog__cta-content {
  flex: 1;
  min-width: 300px;
  text-align: left;
}

.page-blog__cta-content .page-blog__section-title {
  text-align: left;
  margin-bottom: 20px;
}

.page-blog__cta-content .page-blog__description {
  text-align: left;
  margin: 0 0 30px 0;
}

.page-blog__cta-image-wrapper {
  flex: 1;
  min-width: 300px;
  max-width: 500px;
  text-align: center;
}

.page-blog__cta-image {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* FAQ Section */
.page-blog__faq-section {
  padding: 60px 0;
}

details.page-blog__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  border: 1px solid var(--page-blog-border-color);
  overflow: hidden;
  background: var(--page-blog-secondary-color);
}

details.page-blog__faq-item summary.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}

details.page-blog__faq-item summary.page-blog__faq-question::-webkit-details-marker {
  display: none;
}

details.page-blog__faq-item summary.page-blog__faq-question:hover {
  background: #f5f5f5;
}

.page-blog__faq-qtext {
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: var(--page-blog-text-dark);
}

.page-blog__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #666;
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}

details.page-blog__faq-item .page-blog__faq-answer {
  padding: 0 20px 20px;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
  color: #555;
}

/* General image sizing for content area */
.page-blog img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Responsive Styles */
@media (max-width: 1023px) {
  .page-blog__home-hero {
    display: block !important;
    grid-template-columns: none !important;
    height: auto !important;
    max-height: none !important;
    overflow-x: hidden;
    box-sizing: border-box;
  }
  .page-blog__hero-brand,
  .page-blog__hero-jackpot {
    display: none !important;
  }
  .page-blog__game-trial {
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: none !important;
    overflow: hidden !important;
    margin: 0 auto;
    padding: 0 0 12px !important;
    box-sizing: border-box;
  }
  .page-blog__game-trial-shell {
    height: auto !important;
    max-height: none !important;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-blog__game-trial-topbar,
  .page-blog__game-trial-bottombar {
    display: none !important;
  }
  .page-blog__game-trial-viewport {
    position: relative;
    width: 100%;
    aspect-ratio: 1024 / 768;
    flex: none !important;
    min-height: 240px;
    max-height: none !important;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-blog__game-trial-frame {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    max-height: none !important;
    max-width: 100%;
    border: none;
    z-index: 1;
    overflow: hidden;
  }
  .page-blog__game-trial-overlay {
    z-index: 5 !important;
    pointer-events: auto !important;
  }
  .page-blog__game-trial-start {
    z-index: 6 !important;
    pointer-events: auto !important;
    touch-action: manipulation;
  }
}

@media (min-width: 1024px) {
  /* This is a blog page, not homepage, so these rules are mostly ignored for direct application to .page-blog__home-hero */
  /* However, if any shared components or layout patterns were to use these, they'd apply. */
  .page-blog__home-hero {
    display: grid;
    grid-template-columns: 26% 48% 26%;
    gap: 16px;
    align-items: stretch;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 10px 16px 24px;
    box-sizing: border-box;
  }
  .page-blog__hero-brand,
  .page-blog__hero-jackpot,
  .page-blog__game-trial {
    height: 300px;
    max-height: 300px;
    overflow: hidden;
    box-sizing: border-box;
  }
  .page-blog__game-trial {
    max-width: none !important;
    width: 100%;
    margin: 0;
    padding: 0;
  }
  .page-blog__game-trial-shell {
    display: flex;
    flex-direction: column;
    height: 100%;
    max-height: 300px;
    box-sizing: border-box;
  }
  .page-blog__game-trial-viewport {
    flex: 1;
    min-height: 0;
    position: relative;
    width: 100%;
  }
  .page-blog__game-trial-frame {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 0;
    border: none;
  }
  .page-blog__hero-jackpot-claim {
    background: #c62828 !important;
    color: #fff !important;
  }
}

@media (max-width: 768px) {
  .page-blog {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-blog__hero-section {
    padding: 60px 0 40px;
  }

  .page-blog__main-title {
    font-size: 36px;
  }

  .page-blog__description {
    font-size: 16px;
  }

  .page-blog__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px;
  }

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 16px;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-blog__section-title {
    font-size: 28px;
    margin-bottom: 30px;
  }

  .page-blog__post-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-blog__post-image {
    height: 180px;
  }

  .page-blog__post-title {
    font-size: 20px;
  }

  .page-blog__post-excerpt {
    font-size: 15px;
  }

  .page-blog__category-list {
    flex-direction: column;
    gap: 10px;
    padding: 0 15px;
  }

  .page-blog__category-item a {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .page-blog__cta-section .page-blog__container {
    flex-direction: column;
    gap: 30px;
  }

  .page-blog__cta-content {
    text-align: center;
  }

  .page-blog__cta-content .page-blog__section-title,
  .page-blog__cta-content .page-blog__description {
    text-align: center;
  }

  details.page-blog__faq-item summary.page-blog__faq-question {
    padding: 15px;
  }
  .page-blog__faq-qtext {
    font-size: 16px;
  }
  details.page-blog__faq-item .page-blog__faq-answer {
    padding: 0 15px 15px;
  }

  /* Universal mobile image adaptation */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-blog__section,
  .page-blog__card,
  .page-blog__container,
  .page-blog__hero-section,
  .page-blog__latest-posts,
  .page-blog__categories,
  .page-blog__featured-article,
  .page-blog__cta-section,
  .page-blog__faq-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-blog__cta-buttons {
    padding-left: 0;
    padding-right: 0;
  }
}

/* Common styles for game trial overlay/modal, not directly used on blog but required in output */
.page-blog__game-trial-overlay{z-index:5;pointer-events:auto;}.page-blog__game-trial-overlay.is-hidden{display:none!important;pointer-events:none!important;}.page-blog__game-trial-start{z-index:6;pointer-events:auto;touch-action:manipulation;}.page-blog__game-trial-shell{border:1px solid rgba(212,175,55,.45);border-radius:10px;overflow:hidden;}.page-blog__reward-modal{position:fixed;inset:0;z-index:10000;}.page-blog__reward-modal-close{position:absolute;top:15px;right:15px;font-size:30px;color:#fff;cursor:pointer;background:none;border:none;z-index:10001;}