/* style/blog.css */
.page-blog {
  background-color: #F4F7FB; /* Nền trang theo màu tùy chỉnh */
  color: #1F2D3D; /* Màu chữ chính theo tùy chỉnh */
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

.page-blog a {
  color: #2F6BFF;
  text-decoration: none;
}

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

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

.page-blog__section-spacing {
  padding: 60px 0;
}

/* Hero Section */
.page-blog__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: 10px; /* Chỉ 10px top padding để không bị double với body padding */
  padding-bottom: 40px;
  background-color: #FFFFFF;
  border-bottom: 1px solid #D6E2FF;
}

.page-blog__hero-image {
  width: 100%;
  max-width: 1200px;
  margin-bottom: 30px;
  overflow: hidden;
  border-radius: 10px;
}

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

.page-blog__hero-content {
  max-width: 900px;
  padding: 0 20px;
}

.page-blog__main-title {
  font-size: clamp(2.5rem, 5vw, 3.2rem);
  color: #1F2D3D;
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-blog__subtitle {
  font-size: 1.1rem;
  color: #1F2D3D;
  margin-bottom: 30px;
}

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

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  transition: all 0.3s ease;
  white-space: normal;
  word-wrap: break-word;
  box-sizing: border-box;
  max-width: 100%;
}

.page-blog__btn-primary {
  background: linear-gradient(180deg, #4A8BFF 0%, #2F6BFF 100%);
  color: #ffffff;
  border: none;
}

.page-blog__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

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

.page-blog__btn-secondary:hover {
  background: #F0F5FF;
  transform: translateY(-2px);
}

/* Section Titles */
.page-blog__section-title {
  font-size: clamp(2rem, 4vw, 2.5rem);
  color: #000000; /* Custom Color_1776249996415 */
  text-align: center;
  margin-bottom: 15px;
  font-weight: 700;
}

.page-blog__section-description {
  font-size: 1.05rem;
  color: #1F2D3D;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
}

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

.page-blog__post-card {
  background: #FFFFFF;
  border: 1px solid #D6E2FF;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px 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 8px 25px rgba(0, 0, 0, 0.1);
}

.page-blog__card-image-wrapper {
  width: 100%;
  padding-top: 56.25%; /* 16:9 Aspect Ratio */
  position: relative;
  overflow: hidden;
}

.page-blog__card-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

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

.page-blog__card-title {
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.4;
}

.page-blog__card-title a {
  color: #1F2D3D;
}

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

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

.page-blog__card-excerpt {
  font-size: 1rem;
  color: #1F2D3D;
  margin-bottom: 20px;
}

.page-blog__read-more {
  display: inline-block;
  font-weight: 600;
  color: #2F6BFF;
}

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

/* Recent Posts List */
.page-blog__posts-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 25px;
  margin-bottom: 40px;
}

.page-blog__list-item {
  display: flex;
  align-items: flex-start;
  background: #FFFFFF;
  border: 1px solid #D6E2FF;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px 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 5px 15px rgba(0, 0, 0, 0.08);
}

.page-blog__list-image-wrapper {
  flex-shrink: 0;
  width: 200px;
  height: 112px; /* 16:9 aspect ratio for 200px width */
  overflow: hidden;
}

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

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

.page-blog__list-title {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.3;
}

.page-blog__list-title a {
  color: #1F2D3D;
}

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

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

.page-blog__list-excerpt {
  font-size: 0.95rem;
  color: #1F2D3D;
}

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

/* Categories Grid */
.page-blog__categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 25px;
}

.page-blog__category-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #FFFFFF;
  border: 1px solid #D6E2FF;
  border-radius: 10px;
  padding: 30px 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-blog__category-icon {
  width: 100%;
  max-width: 150px;
  height: auto;
  object-fit: contain;
  margin-bottom: 20px;
}

.page-blog__category-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1F2D3D;
}

.page-blog__category-card:hover .page-blog__category-title {
  color: #2F6BFF;
}

/* CTA Section */
.page-blog__cta-section {
  background: #2F6BFF; /* Sử dụng màu chính cho nền tối */
  color: #ffffff; /* Chữ trắng trên nền tối */
  text-align: center;
  border-radius: 10px;
  margin-top: 60px;
  margin-bottom: 60px;
  padding: 60px 20px;
}

.page-blog__cta-title {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-blog__cta-description {
  font-size: 1.1rem;
  max-width: 800px;
  margin: 0 auto 30px auto;
  color: #ffffff;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog__hero-content {
    max-width: 768px;
  }

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

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

@media (max-width: 768px) {
  .page-blog {
    font-size: 16px !important;
    line-height: 1.6 !important;
  }

  .page-blog__container {
    padding: 0 15px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  /* HERO 主图区域 */
  .page-blog__hero-section {
    padding-top: 10px !important;
    padding-bottom: 30px !important;
  }

  .page-blog__main-title {
    font-size: clamp(2rem, 8vw, 2.5rem) !important;
    margin-bottom: 15px !important;
  }

  .page-blog__subtitle {
    font-size: 1rem !important;
    margin-bottom: 25px !important;
  }

  .page-blog__cta-buttons {
    flex-direction: column !important;
    gap: 15px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-blog__btn-primary,
  .page-blog__btn-secondary,
  .page-blog a[class*="button"],
  .page-blog a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  /* 长文区 - General text blocks */
  .page-blog__section-spacing {
    padding: 40px 0 !important;
  }

  .page-blog__section-title {
    font-size: clamp(1.8rem, 7vw, 2rem) !important;
    margin-bottom: 10px !important;
  }

  .page-blog__section-description {
    font-size: 0.95rem !important;
    margin-bottom: 30px !important;
  }

  /* 博客区 - Featured Posts Grid */
  .page-blog__posts-grid {
    grid-template-columns: 1fr !important; /* Single column */
    gap: 20px !important;
  }

  .page-blog__post-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-blog__card-title {
    font-size: 1.2rem !important;
  }

  .page-blog__card-excerpt {
    font-size: 0.9rem !important;
  }

  /* 博客区 - Recent Posts List */
  .page-blog__list-item {
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-blog__list-image-wrapper {
    width: 100% !important;
    height: auto !important;
    padding-top: 56.25% !important; /* Maintain aspect ratio */
  }

  .page-blog__list-image {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  .page-blog__list-content {
    padding: 15px !important;
  }

  .page-blog__list-title {
    font-size: 1.1rem !important;
  }

  .page-blog__list-excerpt {
    font-size: 0.85rem !important;
  }

  /* 博客区 - Categories Grid */
  .page-blog__categories-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  .page-blog__category-icon {
    max-width: 100px !important;
    margin-bottom: 15px !important;
  }

  .page-blog__category-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 20px 15px !important;
  }

  /* 通用图片与容器 */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-blog__hero-image,
  .page-blog__card-image-wrapper,
  .page-blog__list-image-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  /* CTA Section */
  .page-blog__cta-section {
    padding: 40px 15px !important;
    margin-top: 40px !important;
    margin-bottom: 40px !important;
  }

  .page-blog__cta-title {
    font-size: clamp(1.8rem, 7vw, 2rem) !important;
  }

  .page-blog__cta-description {
    font-size: 1rem !important;
  }
}