.page-blog {
  color: #333333; /* Dark text for light body background */
}

.page-blog__hero-section {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
}

.page-blog__hero-container {
  position: relative;
  max-width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.page-blog__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: brightness(0.6); /* Slightly darken image for text readability */
}

.page-blog__hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: #FFFFFF;
  max-width: 90%;
  padding: 20px;
  background: rgba(0, 0, 0, 0.4); /* Semi-transparent dark background for text */
  border-radius: 8px;
}

.page-blog__hero-title {
  font-size: 2.8em;
  margin-bottom: 15px;
  line-height: 1.2;
  color: #FFFFFF;
}

.page-blog__hero-description {
  font-size: 1.2em;
  margin-bottom: 30px;
  line-height: 1.6;
  color: #FFFFFF;
}

.page-blog__hero-button {
  display: inline-block;
  background-color: #FCBC45; /* Login color for primary action */
  color: #000000; /* Dark text for contrast */
  padding: 14px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease;
}

.page-blog__hero-button:hover {
  background-color: #e0a53b;
}

.page-blog__section-title {
  font-size: 2.5em;
  color: #000000;
  text-align: center;
  margin: 60px 0 40px;
}

.page-blog__featured-posts,
.page-blog__latest-posts,
.page-blog__categories,
.page-blog__cta-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

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

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

.page-blog__post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

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

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

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

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

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

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

.page-blog__post-excerpt {
  font-size: 1em;
  color: #333333;
  line-height: 1.6;
  margin-bottom: 20px;
}

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

.page-blog__read-more:hover {
  color: #e0a53b;
}

.page-blog__post-list {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.page-blog__list-item {
  display: flex;
  background-color: #FFFFFF;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-blog__list-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.page-blog__list-image {
  width: 250px; /* Min 200px */
  height: 166px; /* Aspect ratio for 250x166, which is > 200px */
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

.page-blog__list-content {
  padding: 20px;
  flex-grow: 1;
}

.page-blog__list-title {
  font-size: 1.3em;
  margin-bottom: 8px;
  line-height: 1.4;
}

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

.page-blog__list-title a:hover {
  color: #FCBC45;
}

.page-blog__list-meta {
  font-size: 0.85em;
  color: #666666;
  margin-bottom: 10px;
}

.page-blog__list-excerpt {
  font-size: 0.95em;
  color: #333333;
  line-height: 1.5;
}

.page-blog__cta-section {
  background-color: #000000;
  color: #FFFFFF;
  text-align: center;
  padding: 80px 20px;
  border-radius: 10px;
  margin-top: 60px;
  margin-bottom: 60px;
}

.page-blog__cta-title {
  font-size: 2.8em;
  margin-bottom: 20px;
  color: #FFFFFF;
}

.page-blog__cta-description {
  font-size: 1.3em;
  margin-bottom: 40px;
  line-height: 1.6;
  color: #FFFFFF;
}

.page-blog__cta-button {
  display: inline-block;
  background-color: #FCBC45;
  color: #000000;
  padding: 16px 35px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.2em;
  transition: background-color 0.3s ease, transform 0.3s ease;
  margin: 0 10px;
}

.page-blog__cta-button--login {
  background-color: #FFFFFF;
  color: #000000;
}

.page-blog__cta-button:hover {
  background-color: #e0a53b;
  transform: translateY(-2px);
}

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

.page-blog__category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.page-blog__category-card {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #FCBC45;
  color: #000000;
  padding: 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  text-align: center;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.page-blog__category-card:hover {
  background-color: #e0a53b;
  transform: translateY(-3px);
}

/* Responsive Design */
@media (max-width: 992px) {
  .page-blog__hero-title {
    font-size: 2.2em;
  }

  .page-blog__hero-description {
    font-size: 1em;
  }

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

  .page-blog__post-title {
    font-size: 1.3em;
  }

  .page-blog__list-item {
    flex-direction: column;
  }

  .page-blog__list-image {
    width: 100%;
    height: 200px; /* Ensure minimum height */
  }

  .page-blog__cta-title {
    font-size: 2.2em;
  }

  .page-blog__cta-description {
    font-size: 1.1em;
  }

  .page-blog__cta-button {
    padding: 12px 25px;
    font-size: 1.1em;
  }
}

@media (max-width: 768px) {
  .page-blog__hero-section {
    padding-top: var(--header-offset, 120px);
  }

  .page-blog__hero-content {
    width: 95%;
    padding: 15px;
  }

  .page-blog__hero-title {
    font-size: 1.8em;
  }

  .page-blog__hero-description {
    font-size: 0.9em;
    margin-bottom: 20px;
  }

  .page-blog__hero-button {
    padding: 10px 20px;
    font-size: 1em;
  }

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

  .page-blog__list-image {
    max-width: 100%;
    height: auto; /* Ensure responsive scaling for mobile */
  }

  /* CRITICAL: Mobile content images must be responsive and not cause overflow */
  .page-blog img {
    max-width: 100%;
    height: auto; /* IMPORTANT: Ensures images within content area are responsive */
  }

  .page-blog__list-item {
    width: 100%;
  }

  .page-blog__cta-section {
    padding: 50px 15px;
  }

  .page-blog__cta-title {
    font-size: 1.8em;
  }

  .page-blog__cta-description {
    font-size: 1em;
    margin-bottom: 30px;
  }

  .page-blog__cta-button {
    display: block;
    margin: 15px auto;
    width: calc(100% - 20px);
  }

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

  /* Ensure no horizontal scrolling */
  .page-blog {
    overflow-x: hidden;
  }
}

/* Ensure all content area images are at least 200px wide/high */
.page-blog__post-image,
.page-blog__list-image {
  min-width: 200px;
  min-height: 200px;
}

/* Override specific smaller dimensions if they conflict with min-width/height */
@media (max-width: 768px) {
  .page-blog__list-image {
    height: auto; /* Allow auto height to maintain aspect ratio with max-width: 100% */
  }
}