/* style/news.css */
.page-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Dark text for light background */
  background-color: var(--background-color, #FFFFFF); /* Default to white if shared.css doesn't define */
}

.page-news__hero-section {
  position: relative;
  width: 100%;
  padding: 60px 20px;
  padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
  background-color: #017439; /* Brand main color for hero */
  color: #ffffff; /* White text for dark background */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.page-news__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  opacity: 0.3;
}

.page-news__hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  margin: 0 auto;
}

.page-news__hero-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: #ffffff;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

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

.page-news__hero-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  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;
  word-wrap: break-word;
  box-sizing: border-box;
  max-width: 100%;
}

.page-news__btn-primary {
  background-color: #C30808; /* Register/Login color */
  color: #FFFF00; /* Register/Login font color */
  border: 2px solid #C30808;
}

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

.page-news__btn-secondary {
  background-color: #ffffff;
  color: #017439; /* Brand main color */
  border: 2px solid #017439;
}

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

.page-news__content-area {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
  background-color: #ffffff; /* Light background for content */
  color: #333333;
}

.page-news__section-title {
  font-size: 2.2em;
  color: #017439; /* Brand main color */
  margin-top: 40px;
  margin-bottom: 20px;
  text-align: center;
}

.page-news__paragraph {
  font-size: 1.1em;
  margin-bottom: 20px;
  line-height: 1.7;
  text-align: justify;
}

.page-news__image-text-block {
  display: flex;
  align-items: flex-start;
  gap: 30px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.page-news__image-inline {
  flex: 1;
  min-width: 300px;
  border-radius: 8px;
  object-fit: cover;
  height: auto;
  max-width: 100%; /* Ensure images are responsive */
  min-height: 200px; /* Minimum size for content images */
}

.page-news__text-block {
  flex: 2;
  min-width: 300px;
}

.page-news__image-full-width {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 30px 0;
  object-fit: cover;
  min-height: 200px; /* Minimum size for content images */
}

.page-news__cta-block {
  background-color: #f5f5f5;
  padding: 30px;
  border-radius: 8px;
  text-align: center;
  margin: 40px 0;
  border: 1px solid #e0e0e0;
}

.page-news__cta-text {
  font-size: 1.3em;
  margin-bottom: 20px;
  color: #333333;
  font-weight: bold;
}

.page-news__final-cta {
  text-align: center;
  margin-top: 50px;
  margin-bottom: 50px;
}

/* FAQ Section */
.page-news__faq-container {
  margin-top: 40px;
  border-top: 1px solid #e0e0e0;
}

.page-news__faq-item {
  border-bottom: 1px solid #e0e0e0;
}

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  cursor: pointer;
  font-size: 1.2em;
  font-weight: bold;
  color: #333333;
  transition: color 0.3s ease;
}

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

.page-news__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
  color: #017439;
}

.page-news__faq-item.active .page-news__faq-toggle {
  transform: rotate(0deg); /*  becomes "-" */
}

.page-news__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 15px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  color: #555555;
}

.page-news__faq-item.active .page-news__faq-answer {
  max-height: 1000px !important; /* Sufficiently large to show content */
  padding: 15px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-news__hero-title {
    font-size: 2.8em;
  }

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

@media (max-width: 768px) {
  .page-news__hero-section {
    padding-left: 15px;
    padding-right: 15px;
    padding-top: var(--header-offset, 120px) !important;
  }

  .page-news__hero-title {
    font-size: 2.2em;
  }

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

  .page-news__hero-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .page-news__btn-primary,
  .page-news__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 1em;
  }

  .page-news__content-area {
    padding: 20px 15px;
  }

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

  .page-news__paragraph {
    font-size: 1em;
  }

  .page-news__image-text-block {
    flex-direction: column;
    gap: 20px;
  }

  .page-news__image-inline,
  .page-news__image-full-width {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    min-height: 200px !important;
  }

  .page-news__cta-block {
    padding: 20px 15px;
  }

  .page-news__cta-text {
    font-size: 1.1em;
  }

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

  /* Ensure all content containers are responsive */
  .page-news__content-area,
  .page-news__hero-section,
  .page-news__image-text-block,
  .page-news__cta-block,
  .page-news__faq-container,
  .page-news__final-cta {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }
  
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
}

/* Color Contrast Fixes (if needed, though initial design should be good) */
.page-news__dark-bg {
  color: #ffffff; /* Deep background with light text */
  background: #017439;
}

.page-news__light-bg {
  color: #333333; /* Light background with dark text */
  background: #ffffff;
}