/* style/blog.css */
.page-blog {
  color: var(--text-main); /* Default text color for dark background */
  background-color: var(--background); /* Use custom background color */
}

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

.page-blog__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding as body handles --header-offset */
  background-color: var(--background);
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  border-radius: 12px;
  margin-bottom: 30px;
}

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

.page-blog__hero-content {
  text-align: center;
  max-width: 900px;
}

.page-blog__main-title {
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 20px;
}

.page-blog__description {
  font-size: 1.1em;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 30px;
}

.page-blog__cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  white-space: normal;
  word-wrap: break-word;
  box-sizing: border-box;
  max-width: 100%;
}

.page-blog__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #ffffff; /* Forced white text for contrast */
  border: none;
}

.page-blog__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

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

.page-blog__btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.page-blog__introduction-section,
.page-blog__latest-news-section,
.page-blog__guides-strategies-section,
.page-blog__promotions-vip-section,
.page-blog__community-support-section,
.page-blog__faq-section,
.page-blog__conclusion-section {
  padding: 60px 0;
  background-color: var(--background);
}

.page-blog__section-title {
  font-size: 2.5em;
  font-weight: bold;
  color: var(--text-main);
  text-align: center;
  margin-bottom: 40px;
  line-height: 1.3;
}

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

.page-blog__content-block {
  background-color: var(--card-bg);
  padding: 30px;
  border-radius: 12px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.page-blog__sub-title {
  font-size: 1.5em;
  font-weight: bold;
  color: var(--text-main);
  margin-bottom: 15px;
}

.page-blog__content-block p {
  line-height: 1.7;
  color: var(--text-secondary);
}

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

.page-blog__article-card {
  background-color: var(--card-bg);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: var(--text-main);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
}

.page-blog__article-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.page-blog__article-image {
  width: 100%;
  height: 220px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

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

.page-blog__article-title {
  font-size: 1.3em;
  font-weight: bold;
  margin-bottom: 10px;
  color: var(--text-main);
}

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

.page-blog__article-excerpt {
  font-size: 1em;
  line-height: 1.6;
  color: var(--text-secondary);
}

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

.page-blog__faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.page-blog__faq-item {
  background-color: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-blog__faq-item summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-weight: bold;
  cursor: pointer;
  color: var(--text-main);
  font-size: 1.1em;
  transition: background-color 0.3s ease;
}

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

.page-blog__faq-item summary:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
  color: var(--glow);
}

.page-blog__faq-item[open] .page-blog__faq-toggle {
  transform: rotate(45deg);
}

.page-blog__faq-answer {
  padding: 0 20px 20px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.page-blog__floating-cta {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1000;
}

.page-blog__floating-btn {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #ffffff;
  padding: 12px 25px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: bold;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  white-space: nowrap;
  font-size: 1em;
}

.page-blog__floating-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
}

/* Responsive Styles */
@media (max-width: 768px) {
  .page-blog__container {
    padding: 0 15px;
  }

  .page-blog__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important;
  }

  .page-blog__main-title {
    font-size: clamp(2em, 8vw, 2.5em); /* Use clamp for H1 */
    margin-bottom: 15px;
  }

  .page-blog__description {
    font-size: 1em;
    margin-bottom: 25px;
  }

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

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 15px;
    font-size: 1em;
  }

  .page-blog__introduction-section,
  .page-blog__latest-news-section,
  .page-blog__guides-strategies-section,
  .page-blog__promotions-vip-section,
  .page-blog__community-support-section,
  .page-blog__faq-section,
  .page-blog__conclusion-section {
    padding: 40px 0;
  }

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

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

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

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

  .page-blog__article-title {
    font-size: 1.2em;
  }

  .page-blog__article-meta,
  .page-blog__article-excerpt {
    font-size: 0.95em;
  }

  .page-blog__floating-cta {
    bottom: 15px;
    right: 15px;
    gap: 8px;
  }

  .page-blog__floating-btn {
    padding: 10px 20px;
    font-size: 0.9em;
  }

  /* Ensure all images are responsive */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-blog__hero-image-wrapper,
  .page-blog__content-block,
  .page-blog__article-card,
  .page-blog__view-all-button-wrapper,
  .page-blog__faq-item,
  .page-blog__cta-buttons,
  .page-blog__floating-cta {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

  .page-blog__hero-image-wrapper { /* Override to remove extra padding on image wrapper */
    padding-left: 0;
    padding-right: 0;
  }

  .page-blog__content-block,
  .page-blog__article-card,
  .page-blog__faq-item {
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* Custom Colors */
:root {
  --main-color: #11A84E;
  --accent-color: #22C768;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --card-bg: #11271B;
  --background: #08160F;
  --text-main: #F2FFF6;
  --text-secondary: #A7D9B8;
  --border: #2E7A4E;
  --glow: #57E38D;
  --gold: #F2C14E;
  --divider: #1E3A2A;
  --deep-green: #0A4B2C;
}