.page-blog {
  color: #ffffff; /* Body background is dark (#0a0a0a), so use light text */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

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

.page-blog__hero-section {
  padding-top: 10px; /* Small top padding, relying on body padding-top for header offset */
  padding-bottom: 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background-color: #017439; /* Primary brand color as background */
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-height: 500px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
}

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

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

.page-blog__main-title {
  font-size: clamp(2em, 4vw, 3.5em);
  font-weight: bold;
  color: #FFFFFF;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-blog__hero-description {
  font-size: 1.1em;
  color: #f0f0f0;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-blog__btn-primary {
  display: inline-block;
  background-color: #C30808; /* Custom color for register/login */
  color: #FFFF00; /* Custom font color for register/login */
  padding: 12px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
}

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

.page-blog__section-title {
  font-size: 2.5em;
  color: #017439;
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
}

.page-blog__dark-bg .page-blog__section-title {
  color: #FFFFFF;
}

.page-blog__section-intro {
  font-size: 1.1em;
  text-align: center;
  margin-bottom: 40px;
  color: #666666;
}

.page-blog__dark-bg .page-blog__section-intro {
  color: #f0f0f0;
}

.page-blog__light-bg {
  background-color: #FFFFFF;
  color: #333333;
  padding: 60px 0;
}

.page-blog__dark-bg {
  background-color: #017439;
  color: #ffffff;
  padding: 60px 0;
}

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

.page-blog__article-card {
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  color: #333333;
}

.page-blog__article-card:hover {
  transform: translateY(-5px);
}

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

.page-blog__article-content {
  padding: 20px;
}

.page-blog__article-title {
  font-size: 1.4em;
  font-weight: bold;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-blog__article-title a {
  color: #017439;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-blog__article-title a:hover {
  color: #C30808;
}

.page-blog__article-excerpt {
  font-size: 0.95em;
  color: #666666;
  margin-bottom: 15px;
}

.page-blog__article-date {
  font-size: 0.85em;
  color: #999999;
  display: block;
}

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

.page-blog__btn-secondary {
  display: inline-block;
  background-color: #FFFFFF;
  color: #017439;
  border: 2px solid #017439;
  padding: 12px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
}

.page-blog__btn-secondary:hover {
  background-color: #017439;
  color: #FFFFFF;
}

.page-blog__categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 15px;
  text-align: center;
}

.page-blog__category-item {
  display: block;
  background-color: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  padding: 15px 10px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.page-blog__category-item:hover {
  background-color: #FFFFFF;
  color: #017439;
}

.page-blog__about-content {
  font-size: 1.1em;
  line-height: 1.8;
  text-align: justify;
}

.page-blog__about-content p {
  margin-bottom: 1.5em;
  color: #333333;
}

.page-blog__about-content strong {
  color: #017439;
}

.page-blog__faq-list {
  margin-top: 30px;
}

.page-blog__faq-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #ffffff;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 1.2em;
  font-weight: bold;
  cursor: pointer;
  color: #ffffff;
  background-color: rgba(0, 0, 0, 0.2);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  list-style: none;
}

.page-blog__faq-item[open] > .page-blog__faq-question {
  background-color: rgba(0, 0, 0, 0.3);
}

.page-blog__faq-question::-webkit-details-marker, 
.page-blog__faq-question::marker {
  display: none;
  content: "";
}

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

.page-blog__faq-toggle {
  font-size: 1.5em;
  margin-left: 15px;
  transition: transform 0.3s ease;
}

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

.page-blog__faq-answer {
  padding: 15px 25px 20px;
  font-size: 1em;
  color: #f0f0f0;
}

.page-blog__faq-answer p {
  margin-bottom: 1em;
}

.page-blog__faq-answer a {
  color: #FFFF00;
  text-decoration: underline;
}

.page-blog__faq-answer a:hover {
  color: #C30808;
}

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

.page-blog__cta-image {
  width: 100%;
  max-width: 800px;
  height: auto;
  border-radius: 10px;
  margin-bottom: 30px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

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

/* Button responsive styles */
.page-blog__btn-primary,
.page-blog__btn-secondary,
.page-blog a[class*="button"],
.page-blog a[class*="btn"] {
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-blog__view-all-button-container,
.page-blog__cta-section .page-blog__container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Media Queries for responsiveness */
@media (max-width: 1024px) {
  .page-blog__main-title {
    font-size: clamp(2em, 5vw, 3em);
  }

  .page-blog__section-title {
    font-size: 2em;
  }

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

  .page-blog__category-item {
    padding: 12px 8px;
    font-size: 0.95em;
  }
}

@media (max-width: 768px) {
  /* HERO Section */
  .page-blog__hero-section {
    padding-top: 10px !important;
    padding-bottom: 30px;
  }

  .page-blog__hero-content {
    padding: 0 15px;
  }

  .page-blog__main-title {
    font-size: 2.2em !important;
    margin-bottom: 15px;
  }

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

  /* General Sections */
  .page-blog__light-bg, .page-blog__dark-bg {
    padding: 40px 0;
  }

  .page-blog__container {
    padding-left: 15px;
    padding-right: 15px;
  }

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

  .page-blog__section-intro {
    font-size: 0.95em;
    margin-bottom: 30px;
  }

  /* Article Grid */
  .page-blog__articles-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

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

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

  .page-blog__article-excerpt {
    font-size: 0.9em;
  }

  /* Categories Grid */
  .page-blog__categories-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
  }

  .page-blog__category-item {
    font-size: 0.85em;
    padding: 10px;
  }

  /* About Blog Section */
  .page-blog__about-content {
    font-size: 1em;
    line-height: 1.7;
  }

  /* FAQ Section */
  .page-blog__faq-question {
    font-size: 1em;
    padding: 15px 20px;
  }

  .page-blog__faq-toggle {
    font-size: 1.2em;
  }

  .page-blog__faq-answer {
    padding: 10px 20px 15px;
    font-size: 0.9em;
  }

  /* CTA Section */
  .page-blog__cta-image {
    max-width: 100%;
    width: 100%;
    height: auto;
    margin-bottom: 20px;
  }

  /* Universal Image Adaption */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  /* Universal Content/Card/Container Adaption */
  .page-blog__section,
  .page-blog__card,
  .page-blog__container,
  .page-blog__hero-section,
  .page-blog__latest-articles,
  .page-blog__popular-categories,
  .page-blog__about-blog,
  .page-blog__faq-section,
  .page-blog__cta-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  /* Button responsive styles */
  .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;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
    margin-bottom: 10px; /* Add some space between stacked buttons */
  }
  
  /* Button container mobile adaptation */
  .page-blog__view-all-button-container,
  .page-blog__cta-section .page-blog__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    /* If multiple buttons are in a flex container, ensure they wrap or stack */
    display: flex;
    flex-direction: column; /* Stack buttons vertically */
    gap: 10px;
  }
}