/* style/blog.css */

/* Base styles for the blog page */
.page-blog {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #ffffff; /* Default text color for dark body background */
  background-color: transparent; /* Rely on shared.css for body background */
}

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

/* Hero Section */
.page-blog__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 0;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  text-align: center;
  background: #26A9E0; /* Brand color as background */
  color: #ffffff;
  overflow: hidden;
}

.page-blog__hero-image-wrapper {
  width: 100%;
  max-height: 675px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 30px;
}

.page-blog__hero-image {
  width: 1200px;
  height: 675px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

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

.page-blog__main-title {
  font-size: clamp(2em, 4vw, 2.8em);
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.2;
  color: #ffffff;
}

.page-blog__intro-text {
  font-size: 1.1em;
  margin-bottom: 30px;
  color: #f0f0f0;
}

/* CTA Buttons */
.page-blog__cta-buttons {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-blog__btn-primary,
.page-blog__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 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: #EA7C07; /* Login color */
  color: #ffffff;
  border: 2px solid transparent;
}

.page-blog__btn-primary:hover {
  background-color: #d16b05;
}

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

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

.page-blog__btn-link {
  display: inline-block;
  color: #26A9E0;
  text-decoration: none;
  font-weight: bold;
  margin-top: 10px;
}

.page-blog__btn-link:hover {
  text-decoration: underline;
}

/* Section Titles */
.page-blog__section-title {
  font-size: 2.2em;
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: inherit;
}

/* Content Sections */
.page-blog__content-section {
  padding: 80px 0;
}

.page-blog__dark-bg {
  background-color: #26A9E0;
  color: #ffffff;
}

.page-blog__light-bg {
  background-color: #ffffff;
  color: #333333;
}

/* Article Grid (for two-column layouts) */
.page-blog__article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-blog__article-item {
  background: rgba(255, 255, 255, 0.1); /* Semi-transparent white for dark-bg sections */
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  color: inherit;
}

.page-blog__light-bg .page-blog__article-item {
  background: #f8f8f8; /* Light background for light-bg sections */
  color: #333333;
}

.page-blog__article-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
}

.page-blog__article-subtitle {
  font-size: 1.5em;
  font-weight: 600;
  margin-bottom: 15px;
  color: inherit;
}

.page-blog__article-text {
  font-size: 1em;
  line-height: 1.7;
  color: inherit;
}

/* Text Block (for single column content) */
.page-blog__text-block {
  max-width: 800px;
  margin: 0 auto;
  color: inherit;
}

.page-blog__subtitle {
  font-size: 1.8em;
  font-weight: 600;
  margin-top: 30px;
  margin-bottom: 15px;
  color: inherit;
}

.page-blog__text-block p {
  margin-bottom: 20px;
  color: inherit;
}

.page-blog__ordered-list,
.page-blog__unordered-list {
  margin-bottom: 20px;
  padding-left: 20px;
  color: inherit;
}

.page-blog__ordered-list li,
.page-blog__unordered-list li {
  margin-bottom: 10px;
  color: inherit;
}

/* Blog List (for article cards) */
.page-blog__blog-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-blog__blog-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  color: #ffffff;
}

.page-blog__light-bg .page-blog__blog-card {
  background: #f8f8f8;
  color: #333333;
}

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

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

.page-blog__blog-card-title {
  font-size: 1.3em;
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.4;
}

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

.page-blog__blog-card-title a:hover {
  text-decoration: underline;
}

.page-blog__blog-card-meta {
  font-size: 0.9em;
  color: #cccccc;
  margin-bottom: 15px;
}

.page-blog__light-bg .page-blog__blog-card-meta {
  color: #666666;
}

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

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

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

.page-blog__faq-item {
  background-color: #f8f8f8;
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  color: #333333;
}

.page-blog__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.15em;
  font-weight: 600;
  cursor: pointer;
  background-color: #eef;
  border-bottom: 1px solid #e0e0e0;
  color: #26A9E0;
  list-style: none;
  user-select: none;
}

.page-blog__faq-item[open] .page-blog__faq-question {
  background-color: #e0e0f0;
  border-bottom: 1px solid #d0d0e0;
}

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

.page-blog__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  transition: transform 0.3s ease;
}

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

.page-blog__faq-answer {
  padding: 20px;
  font-size: 1em;
  line-height: 1.7;
  color: #555555;
}

/* Conclusion Section */
.page-blog__conclusion-section {
  padding: 80px 0;
  text-align: center;
  background-color: #26A9E0;
  color: #ffffff;
}

.page-blog__conclusion-text {
  max-width: 800px;
  margin: 0 auto 30px auto;
  font-size: 1.1em;
  line-height: 1.7;
  color: #f0f0f0;
}

.page-blog__cta-buttons--center {
  margin-top: 30px;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-blog__hero-image-wrapper {
    max-height: 500px;
  }
  .page-blog__hero-image {
    width: 1000px;
    height: 563px;
  }
}

@media (max-width: 768px) {
  .page-blog__container {
    padding: 0 15px !important;
  }

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

  .page-blog__hero-image-wrapper {
    max-height: 300px;
    margin-bottom: 20px;
  }
  .page-blog__hero-image {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
  }

  .page-blog__main-title {
    font-size: 1.8em !important;
  }

  .page-blog__intro-text {
    font-size: 1em !important;
  }

  .page-blog__cta-buttons {
    flex-direction: column !important;
    gap: 10px !important;
  }

  .page-blog__btn-primary,
  .page-blog__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  .page-blog__section-title {
    font-size: 1.8em !important;
    margin-bottom: 30px !important;
  }

  .page-blog__content-section {
    padding: 50px 0 !important;
  }

  .page-blog__article-item {
    padding: 20px !important;
  }

  .page-blog__article-image {
    height: 180px !important;
    max-width: 100% !important;
    width: 100% !important;
  }

  .page-blog__article-subtitle {
    font-size: 1.3em !important;
  }

  .page-blog__text-block {
    padding: 0 15px;
  }

  .page-blog__subtitle {
    font-size: 1.5em !important;
  }

  .page-blog__blog-list {
    grid-template-columns: 1fr !important;
  }

  .page-blog__blog-card-image {
    height: 180px !important;
    max-width: 100% !important;
    width: 100% !important;
  }

  .page-blog__blog-card-title {
    font-size: 1.2em !important;
  }

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

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

  .page-blog__conclusion-text {
    font-size: 1em !important;
  }

  /* Ensure all images are responsive in content areas */
  .page-blog img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-blog__section,
  .page-blog__card,
  .page-blog__container,
  .page-blog__hero-section,
  .page-blog__content-section,
  .page-blog__faq-section,
  .page-blog__conclusion-section,
  .page-blog__blog-card,
  .page-blog__article-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
}

@media (max-width: 480px) {
  .page-blog__main-title {
    font-size: 1.6em !important;
  }
  .page-blog__section-title {
    font-size: 1.6em !important;
  }
  .page-blog__subtitle {
    font-size: 1.3em !important;
  }
}