.page-news {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light backgrounds */
  background-color: #FFFFFF; /* Matches body background var(--secondary-color) */
}

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

.page-news__hero-section {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 0 60px 0;
  background-color: #26A9E0;
  color: #ffffff;
  text-align: center;
}

.page-news__hero-image-wrapper {
  width: 100%;
  overflow: hidden;
}

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

.page-news__hero-content {
  padding: 40px 20px;
  max-width: 900px;
  z-index: 1;
}

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

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

.page-news__cta-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
}

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

.page-news__btn-primary {
  background-color: #EA7C07; /* Login color for primary CTA */
  color: #ffffff;
  border: 2px solid #EA7C07;
}

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

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

.page-news__btn-secondary:hover {
  background-color: #ffffff;
  color: #26A9E0;
}

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

.page-news__btn-tertiary:hover {
  background-color: #1e87c0;
  border-color: #1e87c0;
}

.page-news__intro-section,
.page-news__latest-news-section,
.page-news__categories-section,
.page-news__cta-section {
  padding: 60px 0;
}

.page-news__benefits-section {
  padding: 60px 0;
  background-color: #26A9E0;
  color: #ffffff;
}

.page-news__section-title {
  font-size: 2.5em;
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: #26A9E0; /* Default for light backgrounds */
}

.page-news__benefits-section .page-news__section-title {
  color: #ffffff; /* Override for dark background */
}

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

.page-news__text-block {
  font-size: 1.05em;
  margin-bottom: 20px;
  text-align: justify;
}

.page-news__highlight {
  color: #26A9E0; /* Primary color for highlights on light backgrounds */
  font-weight: bold;
}

.page-news__dark-bg .page-news__highlight {
  color: #ffffff; /* White for highlights on dark backgrounds */
}

.page-news__latest-news-section .page-news__section-title {
  margin-bottom: 60px;
}

.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: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
}

.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: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-news__card-title {
  font-size: 1.4em;
  font-weight: 600;
  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: #777777;
  margin-bottom: 15px;
}

.page-news__card-text {
  font-size: 1em;
  color: #555555;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-news__read-more-btn {
  display: inline-block;
  padding: 8px 15px;
  background-color: #26A9E0;
  color: #ffffff;
  border-radius: 5px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.3s ease;
  align-self: flex-start;
}

.page-news__read-more-btn:hover {
  background-color: #1e87c0;
}

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

.page-news__categories-section .page-news__category-item {
  margin-bottom: 40px;
}

.page-news__category-title {
  font-size: 1.8em;
  font-weight: 600;
  color: #26A9E0;
  margin-bottom: 20px;
  text-align: center;
}

.page-news__benefits-section .page-news__benefit-item {
  margin-bottom: 40px;
}

.page-news__benefit-title {
  font-size: 1.8em;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 20px;
  text-align: center;
}

.page-news__benefits-section .page-news__text-block {
  color: #f0f0f0;
}

.page-news__cta-section {
  text-align: center;
  background-color: #f5f5f5;
}

.page-news__description--center {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  font-size: 1.1em;
  margin-bottom: 40px;
}

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

.page-news__btn-large {
  padding: 15px 30px;
  font-size: 1.1em;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
  .page-news__container {
    padding: 0 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-news__hero-section {
    padding: 10px 0 40px 0;
  }

  .page-news__hero-content {
    padding: 30px 15px;
  }

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

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

  .page-news__cta-group {
    flex-direction: column;
    gap: 10px;
  }

  .page-news__btn-primary,
  .page-news__btn-secondary,
  .page-news__btn-tertiary,
  .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;
    padding-left: 15px;
    padding-right: 15px;
    text-align: center;
  }

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

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

  .page-news__intro-section,
  .page-news__latest-news-section,
  .page-news__categories-section,
  .page-news__benefits-section,
  .page-news__cta-section {
    padding: 40px 0;
  }

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

  .page-news__card-title {
    font-size: 1.2em;
  }

  .page-news__category-title,
  .page-news__benefit-title {
    font-size: 1.5em;
  }

  /* Image and video responsiveness */
  .page-news img,
  .page-news video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-news__hero-image-wrapper,
  .page-news__news-card,
  .page-news__cta-buttons,
  .page-news__category-item,
  .page-news__benefit-item,
  .page-news__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important; /* Ensure no overflow */
  }
  
  .page-news__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }
  
  .page-news__news-card {
    margin: 0 15px;
  }
}

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

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

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

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

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

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

.page-news__read-more-btn {
  background-color: #26A9E0;
  color: #ffffff;
}

.page-news__section-title {
  color: #26A9E0;
}

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

.page-news__category-title,
.page-news__benefit-title {
  color: #26A9E0;
}

.page-news__dark-bg .page-news__benefit-title {
  color: #ffffff;
}