/* style/blog.css */
.page-blog {
  font-family: 'Arial', sans-serif;
  color: var(--text-main);
  background-color: var(--background-color);
  line-height: 1.6;
  font-size: 16px;
}

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

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  padding-bottom: 60px;
  text-align: center;
  overflow: hidden;
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-height: 500px;
  overflow: hidden;
  position: relative;
}

.page-blog__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: brightness(0.6); /* Darken image for better text contrast if needed */
}

.page-blog__hero-content {
  position: relative;
  z-index: 2;
  margin-top: 40px;
  max-width: 800px;
  padding: 0 20px;
}

.page-blog__main-title {
  font-size: clamp(2em, 4vw, 3.2em);
  color: var(--text-main);
  font-weight: 700;
  margin-bottom: 15px;
  line-height: 1.2;
}

.page-blog__description {
  font-size: 1.1em;
  color: var(--text-main);
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* General Section Styling */
.page-blog__section-title {
  font-size: clamp(1.8em, 3vw, 2.5em);
  color: var(--primary-color);
  font-weight: 700;
  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: 4px;
  background: var(--deep-orange);
  border-radius: 2px;
}

.page-blog__text-block {
  font-size: 1em;
  color: var(--text-main);
  text-align: center;
  max-width: 900px;
  margin: 0 auto 50px auto;
}

/* Introduction Section */
.page-blog__introduction-section {
  padding: 60px 0;
  background-color: var(--card-bg);
}

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

.page-blog__feature-item {
  background-color: var(--background-color);
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.page-blog__feature-item:hover {
  transform: translateY(-10px);
}

.page-blog__feature-icon {
  width: 100%;
  max-width: 250px;
  height: auto;
  margin-bottom: 20px;
  border-radius: 8px;
  min-width: 200px;
  min-height: 200px;
}

.page-blog__feature-title {
  font-size: 1.4em;
  color: var(--glow-color);
  margin-bottom: 15px;
  font-weight: 600;
}

.page-blog__feature-text {
  font-size: 0.95em;
  color: var(--text-main);
}

/* Categories Section */
.page-blog__categories-section {
  padding: 80px 0;
}

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

.page-blog__category-card {
  background-color: var(--card-bg);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

.page-blog__category-card:hover {
  transform: translateY(-10px);
}

.page-blog__category-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
  min-width: 200px;
  min-height: 200px;
}

.page-blog__category-title {
  font-size: 1.3em;
  color: var(--text-main);
  margin: 20px 20px 10px 20px;
  font-weight: 600;
}

.page-blog__category-title a {
  color: inherit;
  text-decoration: none;
}

.page-blog__category-title a:hover {
  color: var(--primary-color);
}

.page-blog__category-description {
  font-size: 0.9em;
  color: var(--text-main);
  padding: 0 20px 20px 20px;
  flex-grow: 1;
}

.page-blog__btn-secondary {
  display: inline-block;
  padding: 10px 25px;
  margin: 0 20px 20px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 600;
  transition: background-color 0.3s ease, color 0.3s ease;
  background: #ffffff;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.page-blog__btn-secondary:hover {
  background: var(--primary-color);
  color: #ffffff;
}

/* Latest Posts Section */
.page-blog__latest-posts-section {
  padding: 80px 0;
  background-color: var(--card-bg);
}

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

.page-blog__post-card {
  background-color: var(--background-color);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.page-blog__post-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  min-width: 200px;
  min-height: 200px;
}

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

.page-blog__post-title {
  font-size: 1.2em;
  color: var(--text-main);
  margin-bottom: 10px;
  font-weight: 600;
  line-height: 1.4;
}

.page-blog__post-title a {
  color: inherit;
  text-decoration: none;
}

.page-blog__post-title a:hover {
  color: var(--primary-color);
}

.page-blog__post-date {
  font-size: 0.85em;
  color: var(--glow-color);
  margin-bottom: 15px;
  opacity: 0.8;
}

.page-blog__post-excerpt {
  font-size: 0.9em;
  color: var(--text-main);
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-blog__read-more {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
  align-self: flex-start;
}

.page-blog__read-more:hover {
  color: var(--glow-color);
}

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

.page-blog__btn-primary {
  display: inline-block;
  padding: 12px 30px;
  background: linear-gradient(180deg, #FFA53A 0%, #D96800 100%);
  color: #ffffff;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 700;
  transition: opacity 0.3s ease;
  border: none;
  cursor: pointer;
}

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

/* FAQ Section */
.page-blog__faq-section {
  padding: 80px 0;
}

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

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

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.1em;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  background-color: var(--background-color);
  border-bottom: 1px solid var(--border-color);
  user-select: none;
}

.page-blog__faq-item[open] .page-blog__faq-question {
  border-bottom: 1px solid var(--border-color);
}

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

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  color: var(--glow-color);
  margin-left: 15px;
}

.page-blog__faq-answer {
  padding: 20px;
  font-size: 0.95em;
  color: var(--text-main);
  background-color: var(--card-bg);
}

.page-blog__faq-answer p {
  margin: 0;
  color: var(--text-main);
}

.page-blog__faq-answer a {
  color: var(--primary-color);
  text-decoration: none;
}

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

/* CTA Section */
.page-blog__cta-section {
  padding: 80px 0;
  background-color: var(--primary-color);
  text-align: center;
}

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

.page-blog__cta-section .page-blog__section-title::after {
  background: #ffffff;
}

.page-blog__cta-section .page-blog__text-block {
  color: #ffffff;
  margin-bottom: 40px;
}

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

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog__hero-content {
    margin-top: 20px;
  }
  .page-blog__hero-image {
    filter: brightness(0.5);
  }
}

@media (max-width: 768px) {
  .page-blog {
    font-size: 15px;
  }

  .page-blog__container {
    padding: 0 15px;
  }

  .page-blog__hero-section {
    padding-top: 10px !important;
    padding-bottom: 40px;
  }

  .page-blog__hero-content {
    margin-top: 20px;
  }

  .page-blog__main-title {
    font-size: clamp(1.8em, 7vw, 2.5em);
  }

  .page-blog__description {
    font-size: 1em;
  }

  .page-blog__section-title {
    font-size: clamp(1.5em, 6vw, 2em);
    margin-bottom: 30px;
  }

  .page-blog__text-block {
    margin-bottom: 30px;
  }

  .page-blog__introduction-section, .page-blog__categories-section, .page-blog__latest-posts-section, .page-blog__faq-section, .page-blog__cta-section {
    padding: 40px 0;
  }

  .page-blog__features-grid, .page-blog__category-grid, .page-blog__post-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .page-blog__feature-icon, .page-blog__category-image, .page-blog__post-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    min-width: 200px !important;
    min-height: 200px !important;
  }

  .page-blog__feature-item, .page-blog__category-card, .page-blog__post-card {
    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: 12px 15px;
  }

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

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

  .page-blog__faq-answer {
    padding: 15px;
  }

  .page-blog__view-all-button-container {
    padding: 0 15px;
  }

  .page-blog__category-title, .page-blog__category-description, .page-blog__btn-secondary {
    margin-left: 15px;
    margin-right: 15px;
  }

  .page-blog__category-title {
    margin-top: 15px;
  }
}

@media (max-width: 480px) {
  .page-blog__hero-content {
    margin-top: 10px;
  }
  .page-blog__main-title {
    font-size: clamp(1.6em, 8vw, 2em);
  }
  .page-blog__description {
    font-size: 0.9em;
  }
  .page-blog__section-title {
    font-size: clamp(1.3em, 7vw, 1.8em);
  }
}