/* style/blog.css */
.page-blog {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light background */
  background-color: #F5F7FA; /* Custom background color */
}

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

/* Hero Section (Top Content) */
.page-blog__hero-section {
  text-align: center;
  padding: 60px 0 40px;
  background: #F5F7FA; /* Light background for the top section */
  padding-top: 10px; /* Small top padding as body handles header offset */
}

.page-blog__hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.page-blog__main-title {
  font-size: clamp(2em, 4vw, 2.8em); /* Responsive font size */
  color: #E53935; /* Brand color for main title */
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: bold;
}

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

.page-blog__hero-cta {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.page-blog__btn {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-blog__btn-primary {
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
  color: #ffffff;
  border: none;
}

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

.page-blog__btn-secondary {
  background: #ffffff;
  color: #E53935;
  border: 2px solid #E53935;
}

.page-blog__btn-secondary:hover {
  background: #E53935;
  color: #ffffff;
}

/* Articles Section */
.page-blog__articles-section {
  padding: 50px 0;
  background: #E53935; /* Dark background for this section */
  color: #ffffff; /* Light text for dark background */
}

.page-blog__section-title {
  font-size: 2.2em;
  text-align: center;
  margin-bottom: 40px;
  color: #ffffff;
  font-weight: bold;
}

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

.page-blog__article-card {
  background: #ffffff; /* Card BG */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  color: #333333; /* Dark text for light card background */
}

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

.page-blog__article-image-wrapper {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  overflow: hidden;
}

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

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

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

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

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

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

.page-blog__article-excerpt {
  font-size: 1em;
  color: #555555;
  margin-bottom: 20px;
}

.page-blog__read-more {
  display: inline-block;
  color: #E53935;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

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

.page-blog__view-all {
  text-align: center;
  margin-top: 50px;
}

/* Main Content Section */
.page-blog__content-section {
  padding: 60px 0;
  background: #F5F7FA; /* Light background */
  color: #333333;
}

.page-blog__article-wrap {
  max-width: 900px; /* Narrower for long-form content */
  margin: 0 auto;
  padding: 0 20px;
}

.page-blog__content-section p {
  margin-bottom: 1em;
  font-size: 1.05em;
}

.page-blog__content-section ul {
  list-style: disc inside;
  margin-bottom: 1em;
  padding-left: 20px;
}

.page-blog__content-section li {
  margin-bottom: 0.5em;
}

.page-blog__sub-title {
  font-size: 1.8em;
  color: #E53935;
  margin-top: 40px;
  margin-bottom: 20px;
  font-weight: bold;
}

.page-blog__figure {
  margin: 30px 0;
  text-align: center;
}

.page-blog__figure img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  display: block; /* Ensures proper spacing and max-width behavior */
  margin: 0 auto;
  min-width: 200px; /* Min size for images */
  min-height: 200px;
}

.page-blog__figcaption {
  font-size: 0.9em;
  color: #666666;
  margin-top: 10px;
}

.page-blog__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 40px;
  flex-wrap: wrap;
}

/* FAQ Section */
.page-blog__faq-section {
  padding: 60px 0;
  background: #E53935; /* Dark background */
  color: #ffffff;
}

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

.page-blog__faq-item {
  background: #ffffff; /* Card BG */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  color: #333333; /* Dark text for light card background */
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 1.15em;
  font-weight: bold;
  cursor: pointer;
  background: #f8f8f8;
  border-bottom: 1px solid #E0E0E0; /* Border color */
  color: #333333;
  list-style: none; /* Hide default marker for details/summary */
}

.page-blog__faq-item[open] > .page-blog__faq-question {
  border-bottom: 1px solid #E53935;
}

.page-blog__faq-question::-webkit-details-marker, /* Hide default marker */
.page-blog__faq-question::marker {
  display: none;
}

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

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  color: #E53935; /* Brand color for toggle */
}

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

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

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .page-blog {
    font-size: 15px;
    line-height: 1.5;
  }

  /* Top Section */
  .page-blog__hero-section {
    padding: 40px 0 30px;
    padding-top: 10px !important; /* Small top padding for mobile */
  }

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

  .page-blog__hero-description {
    font-size: 1em;
    padding: 0 10px;
  }

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

  .page-blog__btn {
    max-width: 100% !important;
    width: 100% !important;
    padding: 12px 15px;
    font-size: 1em;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* Articles Section */
  .page-blog__articles-section {
    padding: 30px 0;
  }

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

  .page-blog__articles-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0 15px;
  }

  .page-blog__article-image-wrapper {
    height: 200px;
  }

  .page-blog__article-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

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

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

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

  .page-blog__view-all {
    margin-top: 30px;
    padding: 0 15px;
  }

  /* Main Content Section */
  .page-blog__content-section {
    padding: 40px 0;
  }

  .page-blog__article-wrap {
    padding: 0 15px;
  }

  .page-blog__sub-title {
    font-size: 1.5em;
    margin-top: 30px;
    margin-bottom: 15px;
  }

  .page-blog__figure {
    margin: 20px 0;
  }

  .page-blog__figure img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    min-width: 200px !important;
    min-height: 200px !important;
  }

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

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

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

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

  .page-blog__faq-answer {
    padding: 10px 20px 15px;
  }

  /* Universal image and container rules for mobile */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-blog__section, 
  .page-blog__card, 
  .page-blog__container, 
  .page-blog__articles-grid, 
  .page-blog__article-card, 
.page-blog__article-image-wrapper, 
  .page-blog__faq-list, 
  .page-blog__faq-item, 
  .page-blog__hero-cta, 
  .page-blog__cta-buttons {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    /* padding-left and padding-right are handled by specific sections */
  }
}