.page-news {
  background-color: #F4F7FB; /* Light background as per custom color */
  color: #1F2D3D; /* Dark text for contrast */
  font-family: Arial, sans-serif;
  line-height: 1.6;
  padding-bottom: 60px; /* Ensure space above footer */
}

/* Hero Section */
.page-news__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column; /* Image above text */
  align-items: center;
  text-align: center;
  padding: 10px 20px 60px; /* Small top padding, more bottom padding */
  overflow: hidden;
  box-sizing: border-box;
}

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

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

.page-news__hero-content {
  max-width: 900px;
  margin: 0 auto;
  position: relative; /* Ensure content is not absolutely positioned over image */
  z-index: 1;
}

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

.page-news__subtitle {
  font-size: 1.1em;
  color: #1F2D3D;
  margin-bottom: 30px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.page-news__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  box-sizing: border-box;
  max-width: 100%; /* Ensure buttons don't overflow */
  white-space: normal; /* Allow text to wrap */
  word-wrap: break-word; /* Allow text to break words */
}

.page-news__btn-primary {
  background: linear-gradient(180deg, #4A8BFF 0%, #2F6BFF 100%);
  color: #ffffff;
  border: 2px solid transparent;
}

.page-news__btn-primary:hover {
  background: linear-gradient(180deg, #2F6BFF 0%, #4A8BFF 100%);
  box-shadow: 0 5px 15px rgba(47, 107, 255, 0.4);
}

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

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

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

.page-news__section-title {
  font-size: 2.5em;
  color: #1F2D3D;
  text-align: center;
  margin-bottom: 40px;
  font-weight: 700;
}

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

.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: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; /* Ensure cards have equal height */
  display: flex;
  flex-direction: column;
}

.page-news__news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

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

.page-news__card-title {
  font-size: 1.4em;
  color: #1F2D3D;
  margin-bottom: 10px;
  font-weight: 600;
  line-height: 1.3;
}

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

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

.page-news__read-more {
  display: inline-block;
  color: #2F6BFF;
  font-weight: 600;
  text-decoration: none;
}

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

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

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

.page-news__categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.page-news__category-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 20px;
  background: #F4F7FB;
  border-radius: 10px;
  text-decoration: none;
  color: #1F2D3D;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-news__category-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-news__category-icon {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin-bottom: 15px;
}

.page-news__category-name {
  font-weight: 600;
  font-size: 1.1em;
}

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

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

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

.page-news__faq-item summary {
  list-style: none; /* Hide default marker */
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-weight: 600;
  font-size: 1.1em;
  color: #1F2D3D;
  cursor: pointer;
  outline: none;
}

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

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

.page-news__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  color: #2F6BFF;
}

.page-news__faq-answer {
  padding: 0 25px 20px;
  color: #1F2D3D;
  font-size: 1em;
}

/* CTA Banner Section */
.page-news__cta-banner {
  padding: 80px 0;
  background: linear-gradient(90deg, #2F6BFF, #6FA3FF);
  text-align: center;
}

.page-news__cta-content {
  max-width: 800px;
  margin: 0 auto;
  color: #ffffff;
}

.page-news__cta-title {
  font-size: 2.2em;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.page-news__cta-description {
  font-size: 1.1em;
  margin-bottom: 40px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .page-news {
    font-size: 16px;
    line-height: 1.6;
  }

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

  .page-news__main-title {
    font-size: clamp(1.8em, 7vw, 2.5em);
    margin-bottom: 15px;
  }

  .page-news__subtitle {
    font-size: 1em;
    margin-bottom: 25px;
  }

  .page-news__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px;
  }

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

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

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

  .page-news__container {
    padding: 0 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

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

  .page-news__card-image {
    height: 200px !important; /* Adjusted to meet min 200px height requirement */
  }

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

  .page-news__categories-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); /* Ensure category items are at least 200px wide */
  }

  .page-news__category-icon {
    width: 150px !important; /* Adjusted to meet min 200px width requirement for parent container */
    height: 150px !important; /* Adjusted to meet min 200px height requirement for parent container */
  }

  .page-news__faq-item summary {
    padding: 15px 20px;
    font-size: 1em;
  }

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

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

  .page-news__cta-description {
    font-size: 1em;
    margin-bottom: 30px;
  }

  /* Image responsive rules */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-news__hero-image-wrapper,
  .page-news__news-card,
  .page-news__category-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
}

/* Ensure contrast for all text */
.page-news p,
.page-news li,
.page-news__card-description,
.page-news__faq-answer p {
  color: #1F2D3D; /* Text Main */
}

.page-news__dark-section {
  background: #2F6BFF;
  color: #ffffff;
}

.page-news__cta-banner {
  background: linear-gradient(90deg, #2F6BFF, #6FA3FF); /* As per custom color */
  color: #ffffff;
}

/* Additional contrast safety for links/buttons */
.page-news a {
  color: #2F6BFF;
}

.page-news a:hover {
  color: #4A8BFF;
}