/* Base styles for blog page */
.page-blog {
  font-family: 'Arial', sans-serif;
  color: #FFF6D6; /* Text Main */
  background-color: #0A0A0A; /* Background */
  line-height: 1.6;
}

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

.page-blog__section-title {
  font-size: 36px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 20px;
  color: #F2C14E; /* Primary color for titles */
}

.page-blog__section-subtitle {
  font-size: 18px;
  text-align: center;
  margin-bottom: 40px;
  color: #FFF6D6; /* Text Main */
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  padding-top: 10px; /* Small top padding, assuming body already has header offset */
  padding-bottom: 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  min-height: 500px;
}

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

.page-blog__hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.5); /* Darken image for text readability */
}

.page-blog__hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 20px;
  color: #ffffff;
}

.page-blog__main-title {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 20px;
  color: #FFD36B; /* Accent color for main title */
  line-height: 1.2;
}

.page-blog__hero-description {
  font-size: 20px;
  margin-bottom: 30px;
  color: #f0f0f0;
}

/* Buttons */
.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 700;
  font-size: 18px;
  transition: all 0.3s ease;
  margin: 10px;
  cursor: pointer;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-blog__btn-primary {
  background: linear-gradient(180deg, #FFD86A 0%, #DDA11D 100%); /* Button color */
  color: #111111; /* Dark text for bright button */
  border: none;
}

.page-blog__btn-primary:hover {
  background: linear-gradient(180deg, #FFE082 0%, #E6B02A 100%);
  transform: translateY(-2px);
}

.page-blog__btn-secondary {
  background: transparent;
  color: #FFD36B; /* Glow color */
  border: 2px solid #FFD36B; /* Glow color */
}

.page-blog__btn-secondary:hover {
  background: rgba(255, 211, 107, 0.1);
  transform: translateY(-2px);
}

/* Latest Posts Section */
.page-blog__latest-posts {
  padding: 60px 20px;
  background-color: #0A0A0A; /* Background */
  color: #FFF6D6; /* Text Main */
}

.page-blog__posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.page-blog__post-card {
  background: #111111; /* 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;
}

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

.page-blog__post-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.page-blog__post-image-wrapper {
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.page-blog__post-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.page-blog__post-card:hover .page-blog__post-image {
  transform: scale(1.05);
}

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

.page-blog__post-category {
  display: inline-block;
  background-color: #F2C14E; /* Primary color */
  color: #111111;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 10px;
}

.page-blog__post-date {
  display: block;
  font-size: 14px;
  color: #888;
  margin-bottom: 10px;
}

.page-blog__post-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 15px;
  color: #FFD36B; /* Glow color */
}

.page-blog__post-excerpt {
  font-size: 16px;
  color: #b0b0b0;
  margin-bottom: 20px;
}

.page-blog__read-more {
  color: #F2C14E; /* Primary color */
  font-weight: 600;
  display: flex;
  align-items: center;
}

.page-blog__read-more span[aria-hidden="true"] {
  margin-left: 5px;
  transition: transform 0.3s ease;
}

.page-blog__post-link:hover .page-blog__read-more span[aria-hidden="true"] {
  transform: translateX(5px);
}

.page-blog__pagination {
  display: flex;
  justify-content: center;
  margin-top: 40px;
  gap: 10px;
}

.page-blog__pagination-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 15px;
  border-radius: 5px;
  text-decoration: none;
  color: #FFD36B; /* Glow color */
  border: 1px solid #3A2A12; /* Border */
  background-color: #111111; /* Card BG */
  transition: all 0.3s ease;
  font-weight: 600;
}

.page-blog__pagination-link:hover:not(.page-blog__pagination-link--active):not(.page-blog__pagination-link--disabled) {
  background-color: #F2C14E;
  color: #111111;
  border-color: #F2C14E;
}

.page-blog__pagination-link--active {
  background-color: #F2C14E;
  color: #111111;
  border-color: #F2C14E;
  cursor: default;
}

.page-blog__pagination-link--disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Categories Section */
.page-blog__categories {
  padding: 60px 20px;
  background-color: #0A0A0A; /* Background */
}

.page-blog__category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 40px;
}

.page-blog__category-item {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #111111; /* Card BG */
  border: 1px solid #3A2A12; /* Border */
  border-radius: 8px;
  padding: 20px;
  text-decoration: none;
  color: #FFD36B; /* Glow color */
  font-size: 18px;
  font-weight: 600;
  min-height: 100px;
  transition: all 0.3s ease;
}

.page-blog__category-item:hover {
  background: #F2C14E;
  color: #111111;
  border-color: #F2C14E;
  transform: translateY(-3px);
}

/* CTA Section */
.page-blog__cta-section {
  padding: 80px 20px;
  text-align: center;
  background-color: #0A0A0A; /* Background */
  color: #FFF6D6; /* Text Main */
}

/* FAQ Section */
.page-blog__faq-section {
  padding: 60px 20px;
  background-color: #0A0A0A; /* Background */
}

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

details.page-blog__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  border: 1px solid #3A2A12; /* Border */
  overflow: hidden;
  background: #111111; /* Card BG */
}

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: rgba(242, 193, 78, 0.1);
}

.page-blog__faq-qtext {
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #FFD36B; /* Glow color */
}

.page-blog__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #F2C14E; /* Primary color */
  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: rgba(17, 17, 17, 0.8); /* Slightly transparent Card BG */
  border-radius: 0 0 8px 8px;
  color: #b0b0b0;
  font-size: 16px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog__posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-blog__category-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .page-blog__main-title {
    font-size: 40px;
  }

  .page-blog__hero-description {
    font-size: 18px;
  }
}

@media (max-width: 768px) {
  .page-blog__hero-section {
    padding-top: 10px !important; /* Small top padding, assuming body already has header offset */
    padding-bottom: 40px;
    min-height: 400px;
  }

  .page-blog__hero-image {
    object-fit: contain !important; /* Specific for banner, as per U888 module 4 */
  }

  .page-blog__main-title {
    font-size: 32px !important;
    margin-bottom: 15px;
  }

  .page-blog__hero-description {
    font-size: 16px !important;
    margin-bottom: 20px;
  }

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    display: block !important;
    margin: 10px auto !important;
    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;
  }

  .page-blog__hero-content {
    padding: 0 15px;
  }

  .page-blog__posts-grid {
    grid-template-columns: 1fr !important;
    gap: 20px;
  }

  .page-blog__post-image-wrapper {
    height: 180px;
  }

  .page-blog__post-title {
    font-size: 20px;
  }

  .page-blog__post-excerpt {
    font-size: 15px;
  }

  .page-blog__section-title {
    font-size: 28px !important;
  }

  .page-blog__section-subtitle {
    font-size: 16px !important;
    margin-bottom: 30px;
  }

  .page-blog__category-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 15px;
  }

  .page-blog__category-item {
    font-size: 16px;
    padding: 15px;
    min-height: 80px;
  }

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

  /* General images for mobile */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  /* FAQ specific mobile styles */
  details.page-blog__faq-item summary.page-blog__faq-question {
    padding: 15px !important;
  }
  .page-blog__faq-qtext {
    font-size: 16px !important;
  }
  .page-blog__faq-toggle {
    font-size: 20px !important;
    width: 24px !important;
    height: 24px !important;
  }
  details.page-blog__faq-item .page-blog__faq-answer {
    padding: 0 15px 15px !important;
  }
}