/* style/news.css */

/* Base styles for the page */
.page-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #f8f9fa; /* Default light text for dark body background */
  background-color: transparent; /* Inherit from body var(--dark-bg) */
}

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

.page-news__section-title {
  font-size: 2.5em;
  font-weight: bold;
  margin-bottom: 20px;
  text-align: center;
  line-height: 1.2;
  color: #26A9E0;
}

.page-news__section-description {
  font-size: 1.1em;
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: #f8f9fa;
}

/* Color contrast classes */
.page-news__dark-bg {
  background-color: #26A9E0;
  color: #ffffff;
}

.page-news__dark-bg .page-news__section-title, 
.page-news__dark-bg .page-news__section-description {
  color: #ffffff;
}

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

.page-news__light-bg .page-news__section-title, 
.page-news__light-bg .page-news__section-description {
  color: #333333;
}

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

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

.page-news__hero-content {
  max-width: 900px;
  margin-top: 40px;
  padding: 0 20px;
}

.page-news__main-title {
  font-weight: bold;
  line-height: 1.2;
  margin-bottom: 20px;
  color: #ffffff;
}

.page-news__hero-description {
  font-size: 1.2em;
  margin-bottom: 30px;
  color: #ffffff;
}

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 12px 25px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow long words to break */
  box-sizing: border-box;
  max-width: 100%;
}

.page-news__btn-primary {
  background-color: #EA7C07;
  color: #ffffff;
  border: 2px solid #EA7C07;
}

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

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

.page-news__btn-secondary:hover {
  background-color: #e0e0e0;
  color: #1e87b7;
  border-color: #1e87b7;
}

/* Latest News Section */
.page-news__latest-news {
  padding: 60px 0;
}

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

.page-news__news-card {
  background-color: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  color: #333333; /* Dark text for light card background */
}

.page-news__news-card:hover {
  transform: translateY(-5px);
}

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

.page-news__card-content {
  padding: 20px;
}

.page-news__card-title {
  font-size: 1.3em;
  font-weight: bold;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-news__card-title a {
  color: #26A9E0;
  text-decoration: none;
}

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

.page-news__card-date {
  font-size: 0.9em;
  color: #666666;
  margin-bottom: 15px;
  display: block;
}

.page-news__card-excerpt {
  font-size: 1em;
  margin-bottom: 20px;
}

.page-news__card-readmore {
  display: inline-block;
  color: #EA7C07;
  text-decoration: none;
  font-weight: bold;
}

.page-news__card-readmore:hover {
  text-decoration: underline;
}

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

/* Video Highlight Section */
.page-news__video-highlight {
  padding: 60px 0;
}

.page-news__video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  margin-bottom: 30px;
  background-color: #000;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.page-news__video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  max-width: 100%;
  cursor: pointer;
}

.page-news__video-cta-wrapper {
  text-align: center;
}

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

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

.page-news__faq-item {
  background-color: #f8f9fa;
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #333333;
}

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

.page-news__faq-item summary::-webkit-details-marker {
  display: none;
}

.page-news__faq-question:hover {
  background-color: #e2e6ea;
}

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

.page-news__faq-answer {
  padding: 20px;
  font-size: 1em;
  color: #555555;
  background-color: #f8f9fa;
}

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

.page-news__cta-container {
  max-width: 800px;
}

.page-news__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .page-news__hero-image {
    max-height: 500px;
  }
  .page-news__main-title {
    font-size: clamp(2em, 4vw, 3.5em);
  }
}

@media (max-width: 768px) {
  .page-news__hero-section {
    padding-bottom: 40px;
  }
  
  .page-news__hero-content {
    margin-top: 20px;
  }

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

  .page-news__hero-description {
    font-size: 1em;
  }

  .page-news__section-title {
    font-size: 2em;
  }

  .page-news__section-description {
    font-size: 0.9em;
  }

  /* Images */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-news__container,
  .page-news__news-card,
  .page-news__faq-item,
  .page-news__cta-container,
  .page-news__video-wrapper,
  .page-news__video-highlight,
  .page-news__latest-news,
  .page-news__hero-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow-x: hidden !important;
  }

  /* Videos */
  .page-news video,
  .page-news__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-news__video-wrapper {
    padding-bottom: 56.25% !important; /* Ensure aspect ratio is maintained */
    height: 0 !important;
    overflow: hidden !important;
  }

  .page-news__video-section {
    padding-top: 10px !important; /* Small top padding */
  }

  /* Buttons */
  .page-news__btn-primary,
  .page-news__btn-secondary,
  .page-news a[class*="button"],
  .page-news a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    margin-left: 0 !important; /* Remove margin for stacking */
  }

  .page-news__cta-buttons {
    flex-direction: column !important; /* Stack buttons vertically */
    gap: 15px !important;
    padding-left: 15px;
    padding-right: 15px;
  }

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

  .page-news__card-image {
    height: auto; /* Allow height to adjust on mobile */
  }

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

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