/* style/blog.css */

/* Body background from shared.css is #111 (dark), so use light text */
.page-blog {
  font-family: 'Arial', sans-serif;
  color: #ffffff; /* Light text for dark body background */
  line-height: 1.6;
}

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

.page-blog__section-title {
  font-size: 2.5em;
  color: #26A9E0;
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
}

.page-blog__section-subtitle {
  font-size: 1.1em;
  color: #f0f0f0;
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-blog__description {
  font-size: 1.1em;
  color: #f0f0f0;
  line-height: 1.6;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  box-sizing: border-box;
  text-align: center;
  white-space: normal;
  word-wrap: break-word;
}

.page-blog__btn-primary {
  background-color: #26A9E0;
  color: #FFFFFF;
  border: 2px solid #26A9E0;
}

.page-blog__btn-primary:hover {
  background-color: #1a7bbd;
  border-color: #1a7bbd;
}

.page-blog__btn-secondary {
  background-color: transparent;
  color: #26A9E0;
  border: 2px solid #26A9E0;
}

.page-blog__btn-secondary:hover {
  background-color: #26A9E0;
  color: #FFFFFF;
}

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles header offset */
  overflow: hidden;
  background: linear-gradient(135deg, #1a2a6c, #b21f1f, #fdbb2d);
  box-sizing: border-box;
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  margin-bottom: 30px;
  box-sizing: border-box;
}

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

.page-blog__hero-content {
  max-width: 900px;
  text-align: center;
  z-index: 1;
}

.page-blog__main-title {
  color: #FFFFFF;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
  /* No fixed font-size to avoid mobile overflow, rely on clamp for responsiveness if needed */
}

.page-blog__hero-section .page-blog__description {
  margin-bottom: 30px;
}

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

/* Latest Posts Section */
.page-blog__latest-posts {
  padding: 80px 0;
  background-color: #1a1a1a; /* Lighter dark background for content */
  color: #ffffff;
}

.page-blog__latest-posts .page-blog__section-title {
  color: #FFFFFF;
}

.page-blog__latest-posts .page-blog__section-subtitle {
  color: #e0e0e0;
}

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

.page-blog__post-card {
  background-color: rgba(255, 255, 255, 0.05); /* Semi-transparent white for card background */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  color: #ffffff;
}

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

.page-blog__card-image {
  width: 100%;
  height: 220px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

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

.page-blog__card-title {
  font-size: 1.3em;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-blog__card-title a {
  color: #26A9E0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-blog__card-title a:hover {
  color: #FFFFFF;
}

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

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

.page-blog__card-readmore {
  display: inline-block;
  color: #26A9E0;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
  margin-top: auto;
}

.page-blog__card-readmore:hover {
  color: #FFFFFF;
}

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

/* Categories Section */
.page-blog__categories {
  padding: 80px 0;
  background-color: #26A9E0;
  color: #FFFFFF;
}

.page-blog__categories .page-blog__section-title,
.page-blog__categories .page-blog__section-subtitle {
  color: #FFFFFF;
}

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

.page-blog__category-card {
  background-color: rgba(255, 255, 255, 0.15); /* Slightly darker for contrast */
  border-radius: 10px;
  padding: 25px;
  text-align: center;
  text-decoration: none;
  color: #FFFFFF;
  transition: background-color 0.3s ease, transform 0.3s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-blog__category-card:hover {
  background-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-3px);
}

.page-blog__category-title {
  font-size: 1.4em;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-blog__category-description {
  font-size: 0.95em;
  opacity: 0.9;
}

/* Featured Article Section */
.page-blog__featured-article {
  padding: 80px 0;
  background-color: #1a1a1a;
  color: #ffffff;
}

.page-blog__featured-article .page-blog__section-title {
  color: #FFFFFF;
}

.page-blog__article-content {
  max-width: 900px;
  margin: 40px auto 0 auto;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-blog__article-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  margin-bottom: 30px;
}

.page-blog__article-heading {
  font-size: 2em;
  color: #26A9E0;
  margin-bottom: 15px;
  font-weight: bold;
}

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

.page-blog__article-paragraph {
  margin-bottom: 20px;
  font-size: 1.05em;
  line-height: 1.7;
  color: #e0e0e0;
}

.page-blog__featured-article .page-blog__btn-primary {
  margin-top: 20px;
}

/* FAQ Section */
.page-blog__faq-section {
  padding: 80px 0;
  background-color: #26A9E0;
  color: #FFFFFF;
}

.page-blog__faq-section .page-blog__section-title,
.page-blog__faq-section .page-blog__section-subtitle {
  color: #FFFFFF;
}

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

.page-blog__faq-item {
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-blog__faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 25px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: bold;
  font-size: 1.1em;
  color: #FFFFFF;
  transition: background-color 0.3s ease;
}

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

.page-blog__faq-item summary:hover {
  background-color: rgba(255, 255, 255, 0.25);
}

.page-blog__faq-qtext {
  flex-grow: 1;
  margin-right: 15px;
}

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
}

.page-blog__faq-item[open] .page-blog__faq-toggle {
  content: '−';
}

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

/* CTA Section */
.page-blog__cta-section {
  padding: 80px 0;
  background-color: #1a1a1a;
  color: #ffffff;
  text-align: center;
}

.page-blog__cta-section .page-blog__section-title {
  color: #FFFFFF;
}

.page-blog__cta-section .page-blog__description {
  max-width: 800px;
  margin: 0 auto 30px auto;
}

.page-blog__cta-image {
  width: 100%;
  max-width: 800px;
  height: auto;
  display: block;
  margin: 30px auto;
  border-radius: 10px;
  object-fit: cover;
}

.page-blog__cta-section .page-blog__cta-group {
  margin-top: 40px;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-blog__main-title {
    font-size: 2.8em;
  }
  .page-blog__section-title {
    font-size: 2.2em;
  }
}

@media (max-width: 768px) {
  .page-blog__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important;
  }
  .page-blog__hero-content {
    padding: 0 15px;
  }
  .page-blog__main-title {
    font-size: 2.2em;
  }
  .page-blog__section-title {
    font-size: 1.8em;
  }
  .page-blog__section-subtitle,
  .page-blog__description,
  .page-blog__article-paragraph,
  .page-blog__card-excerpt,
  .page-blog__category-description {
    font-size: 1em;
  }

  .page-blog__cta-group {
    flex-direction: column;
    gap: 15px;
  }
  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

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

  .page-blog__latest-posts,
  .page-blog__categories,
  .page-blog__featured-article,
  .page-blog__faq-section,
  .page-blog__cta-section {
    padding: 50px 0;
  }

  .page-blog__container,
  .page-blog__hero-image-wrapper,
  .page-blog__post-card,
  .page-blog__category-card,
  .page-blog__article-content,
  .page-blog__faq-list,
  .page-blog__cta-content {
    padding-left: 15px;
    padding-right: 15px;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

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

  /* Video responsiveness (if any) */
  .page-blog video,
  .page-blog__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-blog__video-section,
  .page-blog__video-container,
  .page-blog__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  .page-blog__video-section {
    padding-top: 10px !important;
  }
}

@media (max-width: 480px) {
  .page-blog__main-title {
    font-size: 1.8em;
  }
  .page-blog__section-title {
    font-size: 1.6em;
  }
  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    font-size: 0.9em;
    padding: 10px 20px;
  }
  .page-blog__card-image {
    height: 180px;
  }
}