/* style/blog.css */

:root {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --card-bg: #11271B;
  --background-color-page: #08160F; /* Using a different name to avoid conflict with shared.css body background */
  --text-main: #F2FFF6;
  --text-secondary: #A7D9B8;
  --border-color: #2E7A4E;
  --glow-color: #57E38D;
  --gold-color: #F2C14E;
  --divider-color: #1E3A2A;
  --deep-green: #0A4B2C;
}

.page-blog {
  font-family: 'Arial', sans-serif;
  color: var(--text-main); /* Default text color for the page, as body background is dark */
  background-color: var(--background-color-page); /* Page specific background */
}

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

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

.page-blog__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  margin-bottom: 30px;
}

.page-blog__hero-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  object-fit: cover;
}

.page-blog__hero-content {
  max-width: 900px;
  z-index: 1;
}

.page-blog__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  color: var(--gold-color);
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: 700;
}

.page-blog__hero-description {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 30px;
}

.page-blog__section-title {
  font-size: clamp(2rem, 4vw, 2.8rem);
  color: var(--text-main);
  text-align: center;
  margin-bottom: 20px;
  font-weight: 600;
}

.page-blog__section-description {
  font-size: 1.1rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 40px;
  line-height: 1.5;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.page-blog__card {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  color: var(--text-main);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-blog__card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box;
}

.page-blog__btn-primary {
  background: var(--button-gradient);
  color: #ffffff; /* White text for primary button */
  border: none;
}

.page-blog__btn-primary:hover {
  opacity: 0.9;
  box-shadow: 0 0 15px var(--glow-color);
}

.page-blog__btn-secondary {
  background: none;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.page-blog__btn-secondary:hover {
  background: var(--primary-color);
  color: #ffffff;
  box-shadow: 0 0 10px var(--primary-color);
}

/* Video Section */
.page-blog__video-section {
  padding: 60px 20px;
  text-align: center;
}

.page-blog__video-container {
  width: 100%; /* Desktop width: 100% with max-width */
  max-width: 1000px;
  margin: 0 auto;
  box-sizing: border-box;
}

.page-blog__video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  margin-bottom: 30px;
  border-radius: 10px;
  border: 2px solid var(--border-color);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.page-blog__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.page-blog__video-cta {
  margin-top: 20px;
}

/* Categories Section */
.page-blog__categories-section {
  padding: 60px 0;
}

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

.page-blog__category-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-blog__category-icon {
  width: 100%;
  height: auto;
  max-width: 250px;
  margin-bottom: 20px;
  border-radius: 8px;
  object-fit: cover;
}

.page-blog__category-title {
  font-size: 1.4rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.page-blog__category-title a {
  color: var(--text-main);
  text-decoration: none;
}

.page-blog__category-title a:hover {
  color: var(--gold-color);
}

.page-blog__category-text {
  color: var(--text-secondary);
  line-height: 1.5;
  font-size: 1rem;
}

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

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

.page-blog__post-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-align: left;
}

.page-blog__post-thumbnail {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  display: block;
}

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

.page-blog__post-title {
  font-size: 1.3rem;
  margin-bottom: 10px;
  line-height: 1.4;
  font-weight: 600;
}

.page-blog__post-title a {
  color: var(--text-main);
  text-decoration: none;
}

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

.page-blog__post-meta {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 15px;
}

.page-blog__post-summary {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 20px;
}

.page-blog__read-more {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
}

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

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

/* Game Guides Section */
.page-blog__game-guides-section {
  padding: 60px 0;
}

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

.page-blog__guide-item {
  text-align: center;
}

.page-blog__guide-title {
  font-size: 1.4rem;
  margin-bottom: 10px;
  font-weight: 600;
}

.page-blog__guide-title a {
  color: var(--text-main);
  text-decoration: none;
}

.page-blog__guide-title a:hover {
  color: var(--gold-color);
}

.page-blog__guide-text {
  color: var(--text-secondary);
  line-height: 1.5;
  font-size: 1rem;
}

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

.page-blog__faq-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.page-blog__faq-item {
  overflow: hidden;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  padding: 15px 20px;
  background-color: var(--deep-green);
  border-radius: 8px;
  transition: background-color 0.3s ease;
}

.page-blog__faq-question:hover {
  background-color: var(--primary-color);
}

.page-blog__faq-qtext {
  flex-grow: 1;
}

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

.page-blog__faq-answer {
  padding: 15px 20px;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-secondary);
  background-color: rgba(17, 39, 27, 0.7); /* Slightly lighter than card-bg */
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
  border-top: 1px solid var(--border-color);
}

/* Details tag specific styles */
details.page-blog__faq-item > summary {
  list-style: none;
}

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

details.page-blog__faq-item[open] .page-blog__faq-toggle {
  content: '−'; /* Change to minus sign when open */
}

/* CTA Section */
.page-blog__cta-section {
  padding: 60px 0;
  text-align: center;
}

.page-blog__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-blog__hero-content {
    max-width: 700px;
  }
  .page-blog__posts-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

@media (max-width: 768px) {
  .page-blog__hero-section {
    padding: 40px 15px;
  }

  .page-blog__main-title {
    font-size: clamp(2rem, 8vw, 2.8rem);
  }

  .page-blog__hero-description {
    font-size: 1rem;
  }

  .page-blog__section-title {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
  }

  .page-blog__section-description {
    font-size: 0.95rem;
  }

  .page-blog__container {
    padding: 0 15px;
  }

  /* Mobile images responsiveness */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-blog__section,
  .page-blog__card,
  .page-blog__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-blog__video-section {
    padding-top: 10px !important; /* body already handles --header-offset */
  }

  /* Mobile video responsiveness */
  .page-blog video,
  .page-blog__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-blog__video-section,
  .page-blog__video-container,
  .page-blog__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

  /* Mobile button responsiveness */
  .page-blog__cta-button,
  .page-blog__btn-primary,
  .page-blog__btn-secondary,
  .page-blog a[class*="button"],
  .page-blog a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important; /* Ensure buttons take full width */
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-blog__cta-buttons,
  .page-blog__button-group,
  .page-blog__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-direction: column !important; /* Stack buttons vertically */
    gap: 15px; /* Adjust gap for stacked buttons */
  }

  .page-blog__category-grid,
  .page-blog__posts-grid,
  .page-blog__guide-grid {
    grid-template-columns: 1fr;
  }

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

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

  .page-blog__faq-question {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .page-blog__hero-section {
    padding: 30px 10px;
  }

  .page-blog__main-title {
    font-size: clamp(1.8rem, 9vw, 2.5rem);
  }

  .page-blog__section-title {
    font-size: clamp(1.6rem, 8vw, 2.2rem);
  }

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    padding: 12px 20px;
    font-size: 1rem;
  }
}