/* style/blog.css */

/* Custom Colors */
:root {
  --page-blog-primary-color: #11A84E;
  --page-blog-secondary-color: #22C768;
  --page-blog-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --page-blog-card-bg: #11271B;
  --page-blog-background: #08160F;
  --page-blog-text-main: #F2FFF6;
  --page-blog-text-secondary: #A7D9B8;
  --page-blog-border-color: #2E7A4E;
  --page-blog-glow-color: #57E38D;
  --page-blog-gold-color: #F2C14E;
  --page-blog-divider-color: #1E3A2A;
  --page-blog-deep-green-color: #0A4B2C;
}

.page-blog {
  font-family: 'Arial', sans-serif;
  color: var(--page-blog-text-main); /* Default text color for the page */
  background-color: var(--page-blog-background); /* Default background for the page, from custom colors */
}

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

/* Hero Section */
.page-blog__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 10px; /* Small top padding, body handles header offset */
  padding-bottom: 60px;
  background-color: var(--page-blog-background);
}

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

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

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

.page-blog__main-title {
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--page-blog-text-main);
  margin-bottom: 20px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
  font-size: clamp(2.5rem, 5vw, 3.8rem); /* Use clamp for H1 */
}

.page-blog__hero-description {
  font-size: 1.1rem;
  line-height: 1.6;
  color: var(--page-blog-text-secondary);
  margin-bottom: 30px;
}

.page-blog__cta-buttons {
  display: flex;
  gap: 15px;
  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-weight: bold;
  text-decoration: none;
  transition: all 0.3s ease;
  min-width: 180px;
  text-align: center;
  box-sizing: border-box;
}

.page-blog__btn-primary {
  background: var(--page-blog-button-gradient);
  color: var(--page-blog-text-main);
  border: none;
  box-shadow: 0 4px 10px rgba(42, 209, 111, 0.4);
}

.page-blog__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(42, 209, 111, 0.6);
}

.page-blog__btn-secondary {
  background-color: transparent;
  color: var(--page-blog-secondary-color);
  border: 2px solid var(--page-blog-secondary-color);
}

.page-blog__btn-secondary:hover {
  background-color: var(--page-blog-secondary-color);
  color: var(--page-blog-background);
  transform: translateY(-2px);
}

/* General Section Styles */
.page-blog__section-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: var(--page-blog-text-main);
  text-align: center;
  margin-bottom: 30px;
  font-weight: bold;
  line-height: 1.3;
}

.page-blog__text-block {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--page-blog-text-secondary);
  margin-bottom: 20px;
  text-align: justify;
}

.page-blog__dark-section {
  background-color: var(--page-blog-background);
  padding: 60px 0;
}

.page-blog__light-bg {
  background-color: #0d1e15; /* A slightly lighter dark green for contrast */
  padding: 60px 0;
  color: var(--page-blog-text-main);
}

/* Intro Section */
.page-blog__intro-section .page-blog__text-block {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

/* Categories Section */
.page-blog__category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-blog__card {
  background-color: var(--page-blog-card-bg);
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  display: flex;
  flex-direction: column;
  color: var(--page-blog-text-main);
  height: 100%;
  border: 1px solid var(--page-blog-border-color);
}

.page-blog__card-title {
  font-size: 1.4rem;
  font-weight: bold;
  color: var(--page-blog-text-main);
  margin-bottom: 15px;
  line-height: 1.4;
}

.page-blog__card-description {
  font-size: 0.95rem;
  color: var(--page-blog-text-secondary);
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-blog__card-link {
  display: inline-block;
  color: var(--page-blog-secondary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-blog__card-link:hover {
  color: var(--page-blog-glow-color);
}

/* Featured Posts & Latest News Sections */
.page-blog__post-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: var(--page-blog-card-bg);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--page-blog-border-color);
}

.page-blog__post-thumbnail,
.page-blog__news-thumbnail {
  width: 100%;
  height: 220px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

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

.page-blog__post-title,
.page-blog__news-title {
  font-size: 1.25rem;
  font-weight: bold;
  line-height: 1.4;
  margin-bottom: 10px;
}

.page-blog__post-title a,
.page-blog__news-title a {
  color: var(--page-blog-text-main);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-blog__post-title a:hover,
.page-blog__news-title a:hover {
  color: var(--page-blog-secondary-color);
}

.page-blog__post-meta,
.page-blog__news-meta {
  font-size: 0.85rem;
  color: var(--page-blog-text-secondary);
  margin-bottom: 15px;
}

.page-blog__post-excerpt,
.page-blog__news-excerpt {
  font-size: 0.95rem;
  color: var(--page-blog-text-secondary);
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 20px;
}

.page-blog__read-more {
  display: inline-block;
  color: var(--page-blog-secondary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
  margin-top: auto; /* Pushes to the bottom */
}

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

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

/* Benefits Section */
.page-blog__benefits-list {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.page-blog__benefits-item {
  background-color: var(--page-blog-card-bg);
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
  border: 1px solid var(--page-blog-border-color);
}

.page-blog__benefits-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--page-blog-text-main);
  margin-bottom: 10px;
}

.page-blog__benefits-description {
  font-size: 0.95rem;
  color: var(--page-blog-text-secondary);
  line-height: 1.6;
}

/* FAQ Section */
.page-blog__faq-list {
  margin-top: 40px;
}

.page-blog__faq-item {
  background-color: var(--page-blog-card-bg);
  border-radius: 8px;
  margin-bottom: 15px;
  border: 1px solid var(--page-blog-border-color);
  overflow: hidden;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 1.1rem;
  font-weight: bold;
  color: var(--page-blog-text-main);
  cursor: pointer;
  background-color: var(--page-blog-deep-green-color); /* Slightly different background for question */
  border-bottom: 1px solid var(--page-blog-border-color);
  list-style: none; /* For details/summary */
}

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

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

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

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

.page-blog__faq-answer {
  padding: 15px 25px 20px;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--page-blog-text-secondary);
}

/* Bottom CTA Section */
.page-blog__cta-bottom-section {
  padding: 80px 0;
  text-align: center;
}

.page-blog__cta-bottom-section .page-blog__section-title {
  margin-bottom: 25px;
}

.page-blog__cta-bottom-section .page-blog__text-block {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 40px;
}

/* Responsive Styles */

/* All images basic responsive styles */
.page-blog img {
  max-width: 100%;
  height: auto;
  display: block;
}

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

/* All button containers basic responsive styles */
.page-blog__cta-buttons,
.page-blog__button-group,
.page-blog__btn-container {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

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

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

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

  .page-blog__hero-description {
    font-size: 1rem;
    margin-bottom: 25px;
  }

  .page-blog__cta-buttons {
    flex-direction: column;
    gap: 10px;
    padding: 0 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;
    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;
    overflow: hidden !important;
  }

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

  .page-blog__text-block {
    font-size: 0.95rem;
  }

  .page-blog__category-grid,
  .page-blog__post-grid,
  .page-blog__news-grid,
  .page-blog__benefits-list {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-blog__card,
  .page-blog__post-card,
  .page-blog__news-card,
  .page-blog__benefits-item {
    padding: 20px;
  }

  .page-blog__card-title,
  .page-blog__post-title,
  .page-blog__news-title,
  .page-blog__benefits-title {
    font-size: 1.1rem;
  }

  .page-blog__post-thumbnail,
  .page-blog__news-thumbnail {
    height: 180px; /* Adjust height for mobile */
  }

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

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

  .page-blog__dark-section,
  .page-blog__light-bg {
    padding: 40px 0;
  }

  .page-blog__cta-bottom-section {
    padding: 60px 0;
  }
  
  /* Image responsive override */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  
  /* Container responsive override */
  .page-blog__container,
  .page-blog__hero-image-wrapper,
  .page-blog__category-grid,
  .page-blog__post-grid,
  .page-blog__news-grid,
  .page-blog__benefits-list,
  .page-blog__faq-list {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
}