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

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

.page-blog__dark-bg {
  background-color: #E53935;
  color: #ffffff;
}

.page-blog__light-bg {
  background-color: #ffffff;
  color: #333333;
}

.page-blog__section-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: inherit; /* Inherit from section for contrast */
}

.page-blog__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0 60px 0; /* Small top padding, body handles main offset */
  overflow: hidden;
  background-color: #E53935; /* Fallback if image fails */
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-height: 700px; /* Limit hero image height */
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

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

.page-blog__hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  margin-top: -150px; /* Overlap slightly for visual effect, but text is below image */
  padding: 0 20px;
  color: #ffffff;
}

.page-blog__main-title {
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-blog__hero-description {
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.6;
  margin-bottom: 30px;
  color: #f0f0f0;
}

.page-blog__cta-button {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 18px;
  color: #ffffff;
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
  text-align: center;
  box-sizing: border-box;
}

.page-blog__cta-button:hover {
  background: linear-gradient(180deg, #E53935 0%, #FF5A4F 100%);
}

.page-blog__cta-button--secondary {
  background: #ffffff;
  color: #E53935;
  border: 2px solid #E53935;
  margin-left: 15px;
}

.page-blog__cta-button--secondary:hover {
  background: #f0f0f0;
  color: #E53935;
}

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

.page-blog__post-card {
  background-color: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.page-blog__post-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.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-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #333333;
}

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

.page-blog__post-date {
  font-size: 14px;
  color: #999999;
  text-align: right;
}

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

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

.page-blog__category-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #ffffff;
}

.page-blog__category-icon {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin-bottom: 20px;
}

.page-blog__category-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #ffffff;
}

.page-blog__category-description {
  font-size: 16px;
  line-height: 1.5;
  margin-bottom: 20px;
  color: #f0f0f0;
}

.page-blog__category-link {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 600;
  color: #E53935;
  background-color: #ffffff;
  transition: background-color 0.3s ease;
}

.page-blog__category-link:hover {
  background-color: #f0f0f0;
}

.page-blog__text-block {
  font-size: 17px;
  line-height: 1.7;
  margin-bottom: 20px;
  color: #333333;
}

.page-blog__about-image-container {
  text-align: center;
  margin: 40px 0;
}

.page-blog__about-image {
  width: 100%;
  height: auto;
  max-width: 800px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-blog__faq-section {
  background-color: #f8f8f8;
}

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

.page-blog__faq-item {
  background-color: #ffffff;
  border: 1px solid #E0E0E0;
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-blog__faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 18px;
  font-weight: 600;
  color: #333333;
  cursor: pointer;
  list-style: none;
  user-select: none;
  outline: none;
}

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

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

.page-blog__faq-toggle {
  font-size: 24px;
  line-height: 1;
  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: 0 25px 20px 25px;
  font-size: 16px;
  line-height: 1.6;
  color: #666666;
}

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

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

.page-blog__cta-banner {
  text-align: center;
  padding: 80px 20px;
}

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

.page-blog__cta-title {
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 800;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-blog__cta-description {
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.6;
  margin-bottom: 40px;
  color: #f0f0f0;
}

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

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

  .page-blog__section {
    padding: 40px 15px;
  }

  .page-blog__hero-content {
    margin-top: -100px;
  }

  .page-blog__main-title {
    font-size: clamp(28px, 6vw, 40px);
  }

  .page-blog__hero-description {
    font-size: clamp(15px, 2.5vw, 18px);
  }

  .page-blog__section-title {
    font-size: clamp(24px, 5vw, 36px);
    margin-bottom: 30px;
  }

  .page-blog__post-card {
    margin-bottom: 20px;
  }

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

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

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

  .page-blog__category-item {
    padding: 25px;
  }

  .page-blog__category-icon {
    width: 80px;
    height: 80px;
  }

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

  .page-blog__category-description {
    font-size: 15px;
  }

  .page-blog__text-block {
    font-size: 16px;
  }

  .page-blog__faq-item summary {
    padding: 15px 20px;
    font-size: 16px;
  }

  .page-blog__faq-answer {
    padding: 0 20px 15px 20px;
    font-size: 15px;
  }

  .page-blog__cta-banner {
    padding: 60px 15px;
  }

  .page-blog__cta-title {
    font-size: clamp(26px, 5vw, 40px);
  }

  .page-blog__cta-description {
    font-size: clamp(16px, 3vw, 20px);
  }

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

  .page-blog__cta-button,
  .page-blog__cta-button--secondary {
    width: 100% !important;
    margin-left: 0 !important;
    padding: 12px 20px;
    font-size: 16px;
  }

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

  .page-blog video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-blog__section,
  .page-blog__posts-grid,
  .page-blog__categories-grid,
  .page-blog__about-image-container,
  .page-blog__faq-list,
  .page-blog__cta-content {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  
  /* Ensure content images are not too small */
  .page-blog__post-image,
  .page-blog__category-icon,
  .page-blog__about-image {
    min-width: 200px;
    min-height: 200px;
  }
}

/* Contrast fixes for specific elements if needed - example, not strictly applied universally */
.page-blog__dark-bg .page-blog__section-title,
.page-blog__dark-bg .page-blog__category-title {
  color: #ffffff;
}
.page-blog__light-bg .page-blog__section-title,
.page-blog__light-bg .page-blog__post-title {
  color: #333333;
}