.page-blog {
  background-color: #F5F7FA;
  color: #333333;
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

.page-blog__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 10px; /* Small top padding as per rules */
  padding-bottom: 40px;
  background-color: #100224; /* Dark background for the hero section */
  overflow: hidden;
}

.page-blog__hero-image {
  width: 100%;
  height: auto;
  max-height: 600px; /* Adjust as needed */
  object-fit: cover;
  display: block;
}

.page-blog__hero-content {
  max-width: 960px;
  margin: 20px auto 0;
  padding: 0 20px;
  color: #FFFFFF;
  z-index: 1;
}

.page-blog__main-title {
  font-size: clamp(2rem, 4vw, 2.5rem); /* Using clamp as per rules */
  font-weight: bold;
  line-height: 1.2;
  margin-bottom: 15px;
  color: #FF5A4F;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-blog__intro-text {
  font-size: 1.1rem;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-blog__cta-button {
  display: inline-block;
  padding: 12px 30px;
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
  color: #FFFFFF;
  text-decoration: none;
  border-radius: 8px;
  font-weight: bold;
  transition: background-color 0.3s ease;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 250px;
  margin: 0 auto;
}

.page-blog__cta-button:hover {
  opacity: 0.9;
}

.page-blog__posts-section {
  padding: 60px 0;
  background-color: #F5F7FA;
}

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

.page-blog__section-title {
  font-size: 2.2rem;
  font-weight: bold;
  text-align: center;
  margin-bottom: 40px;
  color: #E53935;
  background: linear-gradient(to right, #FF5A4F, #E53935);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-fill-color: transparent;
}

.page-blog__categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
}

.page-blog__category-item {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 20px;
  background-color: #FFFFFF;
  border: 1px solid #E0E0E0;
  color: #333333;
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.page-blog__category-item:hover,
.page-blog__category-item--active {
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
  color: #FFFFFF;
  border-color: #E53935;
}

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

.page-blog__post-card {
  background-color: #FFFFFF;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #E0E0E0;
}

.page-blog__post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-blog__post-image {
  width: 100%;
  height: 225px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
  min-width: 200px;
  min-height: 200px;
}

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

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

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

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

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

.page-blog__post-excerpt {
  font-size: 1rem;
  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 {
  color: #FF5A4F;
}

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

.page-blog__view-all-button {
  display: inline-block;
  padding: 12px 30px;
  background: linear-gradient(180deg, #FF5A4F 0%, #E53935 100%);
  color: #FFFFFF;
  text-decoration: none;
  border-radius: 8px;
  font-weight: bold;
  transition: background-color 0.3s ease;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 250px;
  margin: 0 auto;
}

.page-blog__view-all-button:hover {
  opacity: 0.9;
}

/* Responsive adjustments */
@media (max-width: 849px) {
  .page-blog__hero-section {
    padding-bottom: 30px;
  }

  .page-blog__hero-image {
    height: auto;
    max-height: 400px;
  }

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

  .page-blog__intro-text {
    font-size: 1rem;
  }

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

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

  .page-blog__categories {
    gap: 8px;
    margin-bottom: 30px;
  }

  .page-blog__category-item {
    padding: 7px 15px;
    font-size: 0.9rem;
  }
}

@media (max-width: 768px) {
  .page-blog__hero-image {
    max-width: 100%;
    height: auto;
  }

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

  .page-blog__post-image {
    max-width: 100%;
    height: auto; /* Ensure images scale down */
    min-width: 200px;
    min-height: 200px;
  }

  .page-blog__post-card img {
    max-width: 100%;
    height: auto; /* Crucial for mobile overflow */
  }

  /* Ensure content area images are not too small */
  .page-blog__posts-section img {
    width: 100%; /* Make sure they fill their container */
    max-width: 100%;
    height: auto;
    min-width: 200px;
    min-height: 200px;
  }

  .page-blog__cta-button, .page-blog__view-all-button {
    width: 100%;
    max-width: 300px;
  }
}

@media (max-width: 549px) {
  .page-blog__hero-section {
    padding-bottom: 20px;
  }

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

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

  .page-blog__intro-text {
    font-size: 0.95rem;
  }

  .page-blog__section-title {
    font-size: 1.8rem;
  }

  .page-blog__categories {
    flex-direction: column;
    align-items: center;
    gap: 5px;
  }

  .page-blog__category-item {
    width: 100%;
    max-width: 200px;
  }
}