/* style/blog.css */
.page-blog {
  font-family: Arial, sans-serif;
  color: #333333; /* Dark text for light body background */
  line-height: 1.6;
  padding-top: var(--header-offset, 120px); /* Ensure space for fixed header on desktop */
}

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

.page-blog__section-title {
  font-size: 2.5em;
  color: #8B0000; /* Auxiliary color for titles */
  text-align: center;
  margin-bottom: 40px;
  padding-top: 40px;
  font-weight: bold;
}

.page-blog__hero-section {
  position: relative;
  width: 100%;
  overflow: hidden;
  background-color: #000; /* Fallback background */
}

.page-blog__hero-container {
  position: relative;
  width: 100%;
}

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

.page-blog__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6); /* Dark overlay for text readability */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 20px;
  box-sizing: border-box;
}

.page-blog__hero-title {
  font-size: 3.5em;
  color: #FFD700; /* Main color for hero title */
  margin-bottom: 20px;
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  max-width: 900px;
}

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

.page-blog__hero-cta-button {
  display: inline-block;
  background-color: #FFD700; /* Main color for CTA button */
  color: #8B0000; /* Auxiliary color for text on CTA */
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 1.2em;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-blog__hero-cta-button:hover {
  background-color: #e6c200;
  transform: translateY(-2px);
}

.page-blog__featured-articles,
.page-blog__latest-posts,
.page-blog__categories,
.page-blog__call-to-action,
.page-blog__about-blog {
  padding: 60px 0;
}

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

.page-blog__article-card,
.page-blog__category-card {
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: #333333;
}

.page-blog__article-card:hover,
.page-blog__category-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

.page-blog__article-image,
.page-blog__category-image {
  width: 100%;
  height: 220px; /* Minimum height for content images */
  object-fit: cover;
  display: block;
}

.page-blog__article-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-blog__article-title {
  font-size: 1.6em;
  color: #8B0000;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-blog__article-title a {
  color: #8B0000;
  text-decoration: none;
}

.page-blog__article-title a:hover {
  text-decoration: underline;
}

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

.page-blog__read-more-button {
  display: inline-block;
  background-color: #FFD700;
  color: #8B0000;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
  font-size: 0.95em;
  transition: background-color 0.3s ease;
  align-self: flex-start;
}

.page-blog__read-more-button:hover {
  background-color: #e6c200;
}

.page-blog__posts-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

.page-blog__post-item {
  display: flex;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-blog__post-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.12);
}

.page-blog__post-image {
  width: 350px; /* Fixed width for desktop */
  height: 250px;
  object-fit: cover;
  display: block;
}

.page-blog__post-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-blog__post-title {
  font-size: 1.5em;
  color: #8B0000;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-blog__post-title a {
  color: #8B0000;
  text-decoration: none;
}

.page-blog__post-title a:hover {
  text-decoration: underline;
}

.page-blog__post-excerpt {
  font-size: 0.95em;
  color: #555555;
  flex-grow: 1;
  margin-bottom: 15px;
}

.page-blog__category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.08);
  text-decoration: none;
  color: #333333;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-blog__category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.12);
}

.page-blog__category-image {
  width: 100%;
  max-width: 250px; /* Max width for category images */
  height: 180px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 15px;
}

.page-blog__category-name {
  font-size: 1.3em;
  font-weight: bold;
  color: #8B0000;
  text-align: center;
}

.page-blog__call-to-action {
  background-color: #8B0000; /* Auxiliary color for CTA background */
  color: #ffffff;
  text-align: center;
  padding: 80px 20px;
}

.page-blog__cta-title {
  font-size: 2.8em;
  color: #FFD700; /* Main color for CTA title */
  margin-bottom: 25px;
  font-weight: bold;
}

.page-blog__cta-description {
  font-size: 1.1em;
  max-width: 900px;
  margin: 0 auto 40px auto;
  line-height: 1.8;
}

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

.page-blog__cta-button {
  display: inline-block;
  padding: 16px 35px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 1.2em;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-blog__cta-button--primary {
  background-color: #FFD700;
  color: #8B0000;
}

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

.page-blog__cta-button--secondary {
  background-color: transparent;
  color: #FFD700;
  border: 2px solid #FFD700;
}

.page-blog__cta-button--secondary:hover {
  background-color: #FFD700;
  color: #8B0000;
  transform: translateY(-2px);
}

.page-blog__about-blog {
  background-color: #f9f9f9;
  padding-bottom: 80px;
}

.page-blog__about-text {
  font-size: 1.05em;
  color: #444444;
  margin-bottom: 20px;
  line-height: 1.7;
  text-align: justify;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .page-blog__hero-title {
    font-size: 3em;
  }
  .page-blog__hero-description {
    font-size: 1.2em;
  }
  .page-blog__section-title {
    font-size: 2em;
  }
  .page-blog__article-image, .page-blog__category-image {
    height: 180px;
  }
  .page-blog__post-image {
    width: 280px;
    height: 200px;
  }
  .page-blog__cta-title {
    font-size: 2.2em;
  }
}

@media (max-width: 768px) {
  .page-blog {
    padding-top: var(--header-offset, 120px); /* Ensure space for fixed header on mobile */
  }
  .page-blog__hero-title {
    font-size: 2.2em;
  }
  .page-blog__hero-description {
    font-size: 1em;
  }
  .page-blog__hero-cta-button {
    padding: 12px 25px;
    font-size: 1em;
  }
  .page-blog__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
    padding-top: 30px;
  }
  .page-blog__articles-grid {
    grid-template-columns: 1fr;
  }
  .page-blog__post-item {
    flex-direction: column;
  }
  .page-blog__post-image {
    width: 100%;
    max-width: 100%; /* Ensure images don't overflow */
    height: 220px;
  }
  .page-blog__post-item img, .page-blog__article-card img, .page-blog__category-card img {
    max-width: 100%;
    height: auto; /* Responsive image sizing for mobile */
  }
  .page-blog__category-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
  .page-blog__category-image {
    height: 120px;
  }
  .page-blog__category-name {
    font-size: 1.1em;
  }
  .page-blog__cta-title {
    font-size: 1.8em;
  }
  .page-blog__cta-description {
    font-size: 0.95em;
  }
  .page-blog__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-blog__cta-button {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }

  /* Image size enforcement for mobile content area */
  .page-blog__articles-grid img,
  .page-blog__posts-list img,
  .page-blog__category-grid img {
    min-width: 200px;
    min-height: 200px;
    width: 100%;
    height: auto;
  }
  .page-blog__hero-image {
    min-width: 200px;
    min-height: 200px;
  }

  /* Ensure no horizontal scroll for content area */
  .page-blog {
    overflow-x: hidden;
  }
}

/* Enforce minimum image sizes for all content images */
.page-blog__hero-image,
.page-blog__article-image,
.page-blog__post-image,
.page-blog__category-image {
  min-width: 200px;
  min-height: 200px;
}

/* Ensure no CSS filters on images */
.page-blog img {
  filter: none; /* Explicitly disable any potential filters */
}