/* style/blog.css */

/* Base styles for the blog page */
.page-blog {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light backgrounds */
  background-color: #FFFFFF; /* Default body background */
}

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

.page-blog__section-title {
  font-size: clamp(28px, 4vw, 42px);
  color: #26A9E0;
  text-align: center;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.page-blog__section-subtitle {
  font-size: clamp(16px, 2vw, 20px);
  color: #666666;
  text-align: center;
  margin-bottom: 40px;
}

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

.page-blog__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  margin-bottom: 30px;
}

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

.page-blog__hero-content {
  max-width: 900px;
  margin: 0 auto;
}

.page-blog__main-title {
  font-size: clamp(32px, 5vw, 48px);
  color: #26A9E0;
  margin-bottom: 20px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.page-blog__hero-description {
  font-size: clamp(18px, 2.5vw, 22px);
  color: #333333;
  margin-bottom: 30px;
}

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

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

.page-blog__btn-primary {
  background-color: #26A9E0;
  color: #FFFFFF;
  border: 2px solid #26A9E0;
}

.page-blog__btn-primary:hover {
  background-color: #1a7fb3;
  border-color: #1a7fb3;
}

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

.page-blog__btn-secondary:hover {
  background-color: #e0f0f8;
  color: #1a7fb3;
  border-color: #1a7fb3;
}

/* Latest Posts Section */
.page-blog__latest-posts {
  padding: 60px 0;
  background-color: #FFFFFF;
  color: #333333;
}

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

.page-blog__post-card {
  background-color: #FFFFFF;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

.page-blog__card-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

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

.page-blog__post-title {
  font-size: 22px;
  font-weight: 700;
  color: #26A9E0;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-blog__post-meta {
  font-size: 14px;
  color: #999999;
  margin-bottom: 15px;
}

.page-blog__post-excerpt {
  font-size: 16px;
  color: #555555;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-blog__read-more {
  display: inline-flex;
  align-items: center;
  color: #26A9E0;
  font-weight: 600;
  font-size: 16px;
}

.page-blog__arrow {
  margin-left: 8px;
  transition: transform 0.3s ease;
}

.page-blog__post-card:hover .page-blog__arrow {
  transform: translateX(5px);
}

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

/* Categories Section */
.page-blog__categories-section {
  padding: 60px 0;
  background-color: #26A9E0;
  color: #FFFFFF;
}

.page-blog__categories-section .page-blog__section-title,
.page-blog__categories-section .page-blog__section-subtitle {
  color: #FFFFFF;
}

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

.page-blog__category-card {
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  text-decoration: none;
  color: #FFFFFF;
  transition: background-color 0.3s ease, transform 0.3s ease;
  box-sizing: border-box;
}

.page-blog__category-card:hover {
  background-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-5px);
}

.page-blog__category-title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #FFFFFF;
}

.page-blog__category-description {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.8);
}

/* Featured Article Section */
.page-blog__featured-article {
  padding: 60px 0;
  background-color: #FFFFFF;
  color: #333333;
}

.page-blog__article-wrapper {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.page-blog__article-image {
  flex: 1;
  max-width: 50%;
  height: auto;
  border-radius: 12px;
  object-fit: cover;
  display: block;
}

.page-blog__article-content {
  flex: 1;
}

.page-blog__article-title {
  font-size: 32px;
  font-weight: 700;
  color: #26A9E0;
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-blog__article-meta {
  font-size: 15px;
  color: #999999;
  margin-bottom: 25px;
}

.page-blog__article-text {
  font-size: 17px;
  color: #444444;
  margin-bottom: 15px;
  line-height: 1.7;
}

/* Call to Action Section */
.page-blog__cta-section {
  padding: 80px 20px;
  background-color: #26A9E0;
  color: #FFFFFF;
  text-align: center;
}

.page-blog__cta-section .page-blog__section-title,
.page-blog__cta-section .page-blog__section-subtitle {
  color: #FFFFFF;
}

.page-blog__cta-section .page-blog__btn-primary {
  background-color: #EA7C07; /* Login color */
  border-color: #EA7C07;
  margin-top: 30px;
  padding: 16px 32px;
  font-size: 20px;
}

.page-blog__cta-section .page-blog__btn-primary:hover {
  background-color: #c76706;
  border-color: #c76706;
}

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

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

.page-blog__faq-item {
  background-color: #f9f9f9;
  border: 1px solid #eeeeee;
  border-radius: 10px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 18px;
  font-weight: 600;
  color: #26A9E0;
  cursor: pointer;
  background-color: #eaf7fc;
  border-bottom: 1px solid #eeeeee;
  transition: background-color 0.3s ease;
  list-style: none; /* For details/summary */
}

.page-blog__faq-question::-webkit-details-marker {
  display: none; /* Hide default marker for details/summary */
}

.page-blog__faq-question:hover {
  background-color: #d8edf7;
}

.page-blog__faq-item[open] .page-blog__faq-question {
  background-color: #d8edf7;
  border-bottom-color: transparent;
}

.page-blog__faq-qtext {
  flex-grow: 1;
  text-align: left;
}

.page-blog__faq-toggle {
  font-size: 24px;
  font-weight: 300;
  line-height: 1;
  margin-left: 15px;
  color: #26A9E0;
}

.page-blog__faq-answer {
  padding: 0 25px 20px;
  font-size: 16px;
  color: #555555;
  background-color: #fcfcfc;
}

.page-blog__faq-answer p {
  margin-bottom: 0;
  padding-top: 15px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog__hero-section {
    padding: 40px 15px;
  }

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

  .page-blog__hero-image {
    height: 400px;
  }

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

  .page-blog__article-wrapper {
    flex-direction: column;
  }

  .page-blog__article-image {
    max-width: 100%;
    margin-bottom: 30px;
  }
}

@media (max-width: 768px) {
  .page-blog__hero-section {
    padding: 30px 15px;
  }

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

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

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

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    font-size: 16px;
    padding: 12px 20px;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-blog__post-grid {
    grid-template-columns: 1fr;
  }

  .page-blog__post-image {
    height: 200px;
  }

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

  .page-blog__article-title {
    font-size: 26px;
  }

  .page-blog__category-grid {
    grid-template-columns: 1fr;
  }

  .page-blog__section-title {
    font-size: 26px;
  }

  .page-blog__section-subtitle {
    font-size: 16px;
  }

  /* Mobile image responsiveness */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-blog__hero-image-wrapper,
  .page-blog__post-card,
  .page-blog__category-card,
  .page-blog__article-wrapper,
  .page-blog__article-image,
  .page-blog__faq-item,
  .page-blog__container,
  .page-blog__latest-posts,
  .page-blog__categories-section,
  .page-blog__featured-article,
  .page-blog__cta-section,
  .page-blog__faq-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

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