/* Base styles for the blog page */
.page-blog {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light body background */
  background-color: var(--background-color, #ffffff); /* Inherit from shared or default white */
}

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  width: 100%;
  padding-top: 10px; /* Small top padding, relying on body for header offset */
  padding-bottom: 40px;
  background-color: #f0f8ff; /* Light blue tint */
  text-align: center;
  overflow: hidden;
}

.page-blog__hero-image {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
  opacity: 0.8;
}

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

.page-blog__hero-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 20px;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-blog__main-title {
  color: #26A9E0;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 20px;
}

.page-blog__hero-description {
  font-size: 1.1em;
  color: #555555;
  margin-bottom: 30px;
}

/* General Section Styles */
.page-blog__section {
  padding: 60px 0;
}

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

.page-blog__section-title {
  color: #26A9E0;
  text-align: center;
  margin-bottom: 40px;
  font-size: 2.2em;
  font-weight: 700;
}

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

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

.page-blog__dark-section {
  background-color: #26A9E0;
  color: #FFFFFF;
}

/* Article Body / Text Block */
.page-blog__article-body {
  max-width: 800px;
  margin: 0 auto;
  font-size: 1.05em;
  line-height: 1.8;
  color: #333333;
}

.page-blog__dark-section .page-blog__article-body {
  color: #FFFFFF;
}

.page-blog__article-body p {
  margin-bottom: 1em;
}

.page-blog__article-body a {
  color: #EA7C07; /* Login color for emphasis */
  text-decoration: underline;
}

/* Blog Post Grid */
.page-blog__posts-grid,
.page-blog__news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

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

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

.page-blog__post-link,
.page-blog__news-link {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.page-blog__post-thumbnail,
.page-blog__news-thumbnail {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  overflow: hidden;
}

.page-blog__post-thumbnail img,
.page-blog__news-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

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

.page-blog__post-title,
.page-blog__news-title {
  font-size: 1.3em;
  font-weight: 600;
  color: #333333;
  margin-bottom: 10px;
  min-height: 60px; /* Ensure titles have consistent height */
}

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

.page-blog__post-excerpt,
.page-blog__news-excerpt {
  font-size: 1em;
  color: #555555;
  margin-bottom: 15px;
  min-height: 70px; /* Consistent excerpt height */
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.page-blog__read-more {
  display: inline-block;
  color: #26A9E0;
  font-weight: 600;
  text-decoration: none;
}

.page-blog__read-more:hover {
  text-decoration: underline;
}

/* Buttons */
.page-blog__cta-buttons {
  margin-top: 40px;
  text-align: center;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 30px;
  border-radius: 5px;
  font-size: 1.1em;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
  max-width: 100%;
  box-sizing: border-box;
  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: #1a7fb3;
  border-color: #1a7fb3;
}

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

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

/* FAQ Section */
details.page-blog__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
  background: #fff;
}
details.page-blog__faq-item summary.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}
details.page-blog__faq-item summary.page-blog__faq-question::-webkit-details-marker {
  display: none;
}
details.page-blog__faq-item summary.page-blog__faq-question:hover {
  background: #f5f5f5;
}
.page-blog__faq-qtext {
  flex: 1;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #333333;
}
.page-blog__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #666;
  flex-shrink: 0;
  margin-left: 15px;
  width: 28px;
  text-align: center;
}
details.page-blog__faq-item .page-blog__faq-answer {
  padding: 0 20px 20px;
  background: #f9f9f9;
  border-radius: 0 0 5px 5px;
  color: #555555;
}
.page-blog__faq-answer p {
  margin: 0;
}


/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog__hero-content {
    padding: 30px;
  }
  .page-blog__main-title {
    font-size: clamp(2em, 5vw, 2.8em);
  }
  .page-blog__section-title {
    font-size: clamp(1.8em, 4vw, 2.2em);
  }
  .page-blog__posts-grid,
  .page-blog__news-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
  }
}

@media (max-width: 768px) {
  /* HERO Chủ đề chính */
  .page-blog__hero-section {
    padding-bottom: 20px;
    padding-top: 10px; /* Small top padding for mobile */
  }
}