/* style/news.css */
/* Body padding-top is handled by shared.css */

.page-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light background */
  background-color: #ffffff; /* Default background for main content */
}

/* Hero Section */
.page-news__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column; /* Image on top, text below */
  align-items: center;
  padding: 10px 0 60px 0; /* Small top padding, more bottom padding */
  text-align: center;
  overflow: hidden; /* Ensure content doesn't overflow */
}

.page-news__hero-image-wrapper {
  width: 100%;
  max-width: 100%; /* Ensure image wrapper itself is responsive */
  margin-bottom: 30px; /* Space between image and text */
}

.page-news__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 500px; /* Limit height for aesthetic */
}

.page-news__hero-content {
  max-width: 900px;
  padding: 0 20px;
  box-sizing: border-box;
}

.page-news__main-title {
  font-size: clamp(2em, 4vw, 3.2em); /* Responsive H1 font size */
  color: #26A9E0;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
}

.page-news__description {
  font-size: 1.1em;
  margin-bottom: 30px;
  color: #555555;
}

.page-news__btn-primary,
.page-news__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;
  cursor: pointer;
  max-width: 100%; /* Ensure buttons are responsive */
  box-sizing: border-box;
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Break long words */
}

.page-news__btn-primary {
  background-color: #26A9E0;
  color: #ffffff;
  border: 2px solid #26A9E0;
  margin-right: 15px;
}

.page-news__btn-primary:hover {
  background-color: #1a7fb0;
  border-color: #1a7fb0;
}

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

.page-news__btn-secondary:hover {
  background-color: #f0f0f0;
}

/* General Container */
.page-news__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Section Titles */
.page-news__section-title {
  font-size: 2.2em;
  color: #26A9E0;
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
}

.page-news__section-title--white {
  color: #ffffff;
}

/* Latest News Section */
.page-news__latest-news-section {
  padding: 60px 0;
  background-color: #f8f8f8; /* Light background for contrast */
}

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

.page-news__news-card {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; /* Ensure cards have consistent height */
  display: flex;
  flex-direction: column;
}

.page-news__news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

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

.page-news__card-image {
  width: 100%;
  height: 220px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

.page-news__card-content {
  padding: 20px;
  flex-grow: 1; /* Allow content to fill space */
  display: flex;
  flex-direction: column;
}

.page-news__card-title {
  font-size: 1.3em;
  color: #26A9E0;
  margin-bottom: 10px;
  font-weight: bold;
}

.page-news__card-meta {
  font-size: 0.9em;
  color: #888888;
  margin-bottom: 15px;
}

.page-news__card-excerpt {
  font-size: 1em;
  color: #555555;
  margin-bottom: 15px;
  flex-grow: 1; /* Allow excerpt to grow */
}

.page-news__read-more {
  display: inline-block;
  color: #26A9E0;
  font-weight: bold;
  text-decoration: none;
  margin-top: auto; /* Push to bottom */
}

.page-news__read-more:hover {
  text-decoration: underline;
}

.page-news__view-all {
  text-align: center;
}

/* Why Follow Section */
.page-news__why-follow-section {
  background-color: #26A9E0; /* Brand color as background */
  padding: 80px 0;
  color: #ffffff;
}

.page-news__features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  text-align: center;
}

.page-news__feature-item {
  background-color: rgba(255, 255, 255, 0.1); /* Semi-transparent white background */
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-news__feature-title {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: #ffffff;
  font-weight: bold;
}

.page-news__feature-description {
  font-size: 1em;
  color: #f0f0f0;
}

/* FAQ Section */
.page-news__faq-section {
  padding: 60px 0;
  background-color: #ffffff;
}

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

.page-news__faq-item {
  background-color: #f9f9f9;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-news__faq-item[open] {
  background-color: #eaf6fa; /* Lighter background when open */
}

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  font-size: 1.1em;
  font-weight: bold;
  color: #26A9E0;
  cursor: pointer;
  list-style: none; /* Remove default marker for summary */
}

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

.page-news__faq-qtext {
  flex-grow: 1;
}

.page-news__faq-toggle {
  font-size: 1.5em;
  margin-left: 15px;
  color: #26A9E0;
}

.page-news__faq-answer {
  padding: 0 25px 20px 25px;
  font-size: 1em;
  color: #555555;
  border-top: 1px solid #e0e0e0;
  margin-top: -1px; /* Overlap border for cleaner look */
}

.page-news__faq-answer p {
  margin: 0;
}

/* Call to Action Section */
.page-news__cta-section {
  background-color: #26A9E0; /* Brand color background */
  padding: 80px 0;
  color: #ffffff;
  text-align: center;
}

.page-news__cta-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-news__cta-content {
  margin-bottom: 30px;
}

.page-news__description--white {
  color: #f0f0f0;
  font-size: 1.1em;
}

.page-news__cta-buttons {
  display: flex;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
  justify-content: center;
  gap: 15px; /* Space between buttons */
  width: 100%; /* Full width for container */
  max-width: 500px; /* Limit max width for button group */
  box-sizing: border-box;
}

/* Responsive adjustments */
@media (max-width: 992px) {
  .page-news__hero-image {
    max-height: 400px;
  }
  .page-news__main-title {
    font-size: clamp(1.8em, 5vw, 2.8em);
  }
  .page-news__section-title {
    font-size: 1.8em;
  }
  .page-news__news-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
  .page-news__card-image {
    height: 180px;
  }
}

@media (max-width: 768px) {
  .page-news__hero-section {
    padding: 10px 0 40px 0;
  }
  .page-news__hero-image-wrapper {
    margin-bottom: 20px;
  }
  .page-news__hero-image {
    max-height: 300px;
  }
  .page-news__main-title {
    font-size: clamp(1.5em, 6vw, 2.2em);
  }
  .page-news__description {
    font-size: 1em;
  }
  .page-news__btn-primary,
  .page-news__btn-secondary {
    width: 100% !important; /* Force full width on mobile */
    margin-right: 0 !important;
    margin-bottom: 15px;
    max-width: 100% !important;
    height: auto !important;
    padding: 15px 20px !important;
  }
  .page-news__cta-buttons {
    flex-direction: column; /* Stack buttons vertically */
    gap: 15px;
    padding: 0 15px;
  }

  .page-news__section-title {
    font-size: 1.6em;
    margin-bottom: 30px;
  }
  .page-news__latest-news-section,
  .page-news__why-follow-section,
  .page-news__faq-section,
  .page-news__cta-section {
    padding: 40px 0;
  }
  .page-news__news-grid {
    grid-template-columns: 1fr; /* Single column layout */
    padding: 0 15px;
  }
  .page-news__news-card {
    margin-bottom: 20px;
  }
  .page-news__card-image {
    height: 180px;
  }
  .page-news__container {
    padding: 0 15px; /* Add padding to general container */
  }
  .page-news__feature-item {
    padding: 20px;
  }
  .page-news__faq-question {
    padding: 15px 20px;
    font-size: 1em;
  }
  .page-news__faq-answer {
    padding: 0 20px 15px 20px;
  }

  /* Mobile image responsiveness */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-news__section,
  .page-news__card,
  .page-news__container,
  .page-news__hero-image-wrapper,
  .page-news__cta-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-news__hero-section {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  .page-news__hero-content {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }
  .page-news__video-section {
    padding-top: 10px !important;
  }
}