/* Base styles for the blog page */
.page-blog {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #FFF1E8; /* Text Main */
  background-color: #140C0C; /* Background */
}

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

.page-blog__hero-section {
  padding-top: 10px; /* Small top padding, assuming shared.css handles body padding-top */
  background-color: #140C0C; /* Background */
  text-align: center;
  padding-bottom: 40px;
}

.page-blog__hero-image-wrapper {
  margin-bottom: 20px;
}

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

.page-blog__main-title {
  font-size: clamp(2em, 4vw, 3.5em);
  color: #F3C54D; /* Gold */
  margin-bottom: 15px;
  line-height: 1.2;
  font-weight: bold;
}

.page-blog__hero-description {
  font-size: 1.1em;
  color: #FFF1E8;
  max-width: 800px;
  margin: 0 auto 30px auto;
}

.page-blog__btn-primary {
  display: inline-block;
  background: linear-gradient(180deg, #FFB04A 0%, #D86A14 100%); /* Button gradient */
  color: #ffffff;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-blog__btn-primary:hover {
  opacity: 0.9;
}

.page-blog__section-title {
  font-size: 2.5em;
  color: #F3C54D; /* Gold */
  text-align: center;
  margin-bottom: 40px;
  position: relative;
  padding-bottom: 10px;
}

.page-blog__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background-color: #F3C54D;
  border-radius: 2px;
}

.page-blog__latest-posts-section {
  padding: 60px 0;
  background-color: #140C0C; /* Background */
}

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

.page-blog__blog-card-link {
  text-decoration: none;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-blog__blog-card {
  background-color: #2A1212; /* Card BG */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid #6A1E1E; /* Border */
}

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

.page-blog__blog-card-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

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

.page-blog__blog-card-title {
  font-size: 1.5em;
  color: #F3C54D; /* Gold */
  margin-bottom: 10px;
  line-height: 1.3;
}

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

.page-blog__blog-card-date {
  font-size: 0.85em;
  color: #E53030;
  margin-top: auto;
  margin-bottom: 15px;
}

.page-blog__btn-outline {
  display: inline-block;
  color: #F3C54D; /* Gold */
  border: 1px solid #F3C54D; /* Gold */
  padding: 8px 15px;
  border-radius: 5px;
  text-decoration: none;
  font-size: 0.9em;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease;
  text-align: center;
  margin-top: auto;
}

.page-blog__btn-outline:hover {
  background-color: #F3C54D;
  color: #140C0C; /* Background */
}

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

.page-blog__btn-secondary {
  display: inline-block;
  background-color: #E53030;
  color: #ffffff;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-blog__btn-secondary:hover {
  background-color: #C61F1F;
}

.page-blog__categories-section {
  padding: 60px 0;
  background-color: #1A0D0D; /* Slightly different dark background */
}

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

.page-blog__category-card {
  background-color: #2A1212; /* Card BG */
  border-radius: 10px;
  padding: 25px;
  text-align: center;
  text-decoration: none;
  color: #FFF1E8;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #6A1E1E; /* Border */
}

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

.page-blog__category-image {
  max-width: 100px;
  height: auto;
  margin: 0 auto 15px auto;
  display: block;
  border-radius: 5px;
}

.page-blog__category-title {
  font-size: 1.3em;
  color: #F3C54D; /* Gold */
  margin-bottom: 10px;
}

.page-blog__category-description {
  font-size: 0.9em;
  color: #FFF1E8;
}

.page-blog__cta-banner {
  background: linear-gradient(90deg, #C61F1F 0%, #E53030 100%);
  padding: 60px 0;
  text-align: center;
  color: #ffffff;
}

.page-blog__cta-content {
  max-width: 900px;
}

.page-blog__cta-title {
  font-size: 2.8em;
  color: #F3C54D; /* Gold */
  margin-bottom: 20px;
  line-height: 1.2;
}

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

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

.page-blog__faq-section {
  padding: 60px 0;
  background-color: #140C0C; /* Background */
}

.page-blog__faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.page-blog__faq-item {
  background-color: #2A1212; /* Card BG */
  border: 1px solid #6A1E1E; /* Border */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #FFF1E8;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 1.2em;
  font-weight: bold;
  cursor: pointer;
  color: #F3C54D; /* Gold */
  list-style: none;
  position: relative;
}

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

.page-blog__faq-question::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none; /* Allow clicks on children */
}

.page-blog__faq-item[open] .page-blog__faq-toggle {
  content: '-';
  transform: rotate(180deg);
}

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
  color: #FFF1E8;
}

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

.page-blog__faq-answer p {
  margin: 0;
}

/* General image and button responsiveness */
.page-blog img {
  max-width: 100%;
  height: auto;
  display: block;
}

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

.page-blog__cta-buttons,
.page-blog__button-group,
.page-blog__btn-container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Responsive styles for mobile (max-width: 768px) */
@media (max-width: 768px) {
  .page-blog {
    font-size: 15px;
    line-height: 1.5;
  }

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

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

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

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

  /* 博客卡片区 */
  .page-blog__blog-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-blog__blog-card-image {
    height: 180px;
  }

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

  .page-blog__blog-card-excerpt {
    font-size: 0.9em;
  }

  .page-blog__categories-section {
    padding: 40px 0;
  }

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

  .page-blog__category-card {
    padding: 15px;
  }

  .page-blog__category-image {
    max-width: 80px;
  }

  .page-blog__category-title {
    font-size: 1.1em;
  }

  .page-blog__cta-banner {
    padding: 40px 0;
  }

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

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

  .page-blog__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }

  /* 通用图片与容器 */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  .page-blog__section,
  .page-blog__card,
  .page-blog__container {
    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__btn-outline,
  .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;
    padding-right: 15px;
  }
  
  .page-blog__cta-buttons,
  .page-blog__button-group,
  .page-blog__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 10px;
  }

  .page-blog__faq-section {
    padding: 40px 0;
  }

  .page-blog__faq-question {
    font-size: 1.1em;
    padding: 15px 20px;
  }

  .page-blog__faq-answer {
    padding: 0 20px 15px 20px;
    font-size: 0.95em;
  }
}