.page-news {
  background-color: var(--bg-color, #08160F); /* Default to custom background if --bg-color is not set */
  color: #F2FFF6; /* Text Main */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

.page-news__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
  width: 100%; /* Ensure full width on desktop within max-width */
}

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

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

.page-news__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 30px; /* Space between image and content */
}

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

.page-news__main-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem); /* Responsive font size for H1 */
  font-weight: bold;
  color: #F2FFF6; /* Text Main */
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-news__hero-description {
  font-size: 1.15rem;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

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

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
  text-align: center;
}

.page-news__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%); /* Button custom color */
  color: #F2FFF6; /* Text Main */
  border: none;
  box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-news__btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
}

.page-news__btn-secondary {
  background-color: transparent;
  color: #2AD16F; /* Green from button gradient */
  border: 2px solid #2AD16F;
}

.page-news__btn-secondary:hover {
  background-color: #2AD16F;
  color: #F2FFF6;
  transform: translateY(-2px);
}

/* Section Titles */
.page-news__section-title {
  font-size: clamp(2rem, 4vw, 3rem);
  color: #F2FFF6; /* Text Main */
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
}

/* News List Section */
.page-news__news-list-section {
  padding: 60px 0;
  background-color: #08160F; /* Background custom color */
}

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

.page-news__news-card {
  background-color: #11271B; /* Card BG custom color */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #2E7A4E; /* Border custom color */
  display: flex;
  flex-direction: column;
}

.page-news__news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

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

.page-news__card-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.page-news__card-date {
  font-size: 0.9rem;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 10px;
  display: block;
}

.page-news__card-title {
  font-size: 1.3rem;
  font-weight: bold;
  margin-bottom: 15px;
  line-height: 1.4;
  flex-grow: 1;
}

.page-news__card-title a {
  color: #F2FFF6; /* Text Main */
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__card-title a:hover {
  color: #2AD16F; /* Green from button gradient */
}

.page-news__card-excerpt {
  font-size: 1rem;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-news__card-link {
  display: inline-block;
  color: #57E38D; /* Glow custom color */\  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
  margin-top: auto;
}

.page-news__card-link:hover {
  text-decoration: underline;
  color: #F2C14E; /* Gold custom color */
}

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

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

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

.page-news__faq-item {
  background-color: #11271B; /* Card BG custom color */
  border: 1px solid #2E7A4E; /* Border custom color */
  border-radius: 10px;
  margin-bottom: 15px;
  overflow: hidden;
}

.page-news__faq-item summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.1rem;
  color: #F2FFF6; /* Text Main */
  background-color: #11271B; /* Card BG custom color */
  transition: background-color 0.3s ease;
}

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

.page-news__faq-item summary:hover {
  background-color: #1E3A2A; /* Divider custom color, slightly darker hover */
}

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

.page-news__faq-toggle {
  font-size: 1.5rem;
  margin-left: 15px;
  color: #57E38D; /* Glow custom color */
  transition: transform 0.3s ease;
}

.page-news__faq-item[open] .page-news__faq-toggle {
  transform: rotate(45deg);
}

.page-news__faq-answer {
  padding: 0 25px 20px;
  font-size: 1rem;
  color: #A7D9B8; /* Text Secondary */
  line-height: 1.6;
}

.page-news__faq-answer a {
  color: #57E38D; /* Glow custom color */
  text-decoration: underline;
}

.page-news__faq-answer a:hover {
  color: #F2C14E; /* Gold custom color */
}

/* CTA Bottom Section */
.page-news__cta-bottom-section {
  padding: 60px 0;
  background-color: #08160F; /* Background custom color */
  text-align: center;
}

.page-news__cta-bottom-section .page-news__section-title {
  margin-bottom: 20px;
}

.page-news__cta-description {
  font-size: 1.1rem;
  color: #A7D9B8; /* Text Secondary */
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 20px;
}

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

/* Mobile Floating Buttons */
.page-news__mobile-floating-buttons {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  justify-content: space-around;
  background-color: #11271B; /* Card BG custom color */
  border-top: 1px solid #2E7A4E; /* Border custom color */
  padding: 10px 0;
  z-index: 1000;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.3);
  display: none; /* Hidden by default, shown on mobile via media query */
}

.page-news__floating-btn {
  flex: 1;
  text-align: center;
  padding: 12px 0;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1rem;
  border-radius: 5px;
  margin: 0 5px;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.page-news__floating-register {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #F2FFF6;
}

.page-news__floating-register:hover {
  opacity: 0.9;
}

.page-news__floating-login {
  background-color: #1E3A2A; /* Divider custom color */
  color: #A7D9B8; /* Text Secondary */
}

.page-news__floating-login:hover {
  background-color: #2E7A4E; /* Border custom color */
  color: #F2FFF6;
}


/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .page-news__hero-section {
        padding: 40px 0;
        padding-top: 10px;
    }
    .page-news__main-title {
        font-size: clamp(2.2rem, 4.5vw, 3rem);
    }
    .page-news__hero-description {
        font-size: 1rem;
    }
    .page-news__section-title {
        font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    }
    .page-news__news-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 25px;
    }
    .page-news__card-title {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
  .page-news__hero-section {
    padding: 30px 0;
    padding-top: 10px !important; /* body handles header offset */
  }

  .page-news__hero-image {
    margin-bottom: 20px;
  }

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

  .page-news__hero-description {
    font-size: 0.95rem;
    margin-bottom: 25px;
    padding: 0 15px;
  }

  .page-news__hero-cta {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px;
  }

  .page-news__btn-primary,
  .page-news__btn-secondary {
    max-width: 100% !important;
    width: 100% !important;
    padding: 12px 20px;
    font-size: 1rem;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  .page-news__section-title {
    font-size: clamp(1.6rem, 6vw, 2.2rem);
    margin-bottom: 30px;
  }

  .page-news__news-list-section,
  .page-news__faq-section,
  .page-news__cta-bottom-section {
    padding: 40px 0;
  }

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

  .page-news__card-image {
    height: 180px;
  }

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

  .page-news__card-title {
    font-size: 1.15rem;
  }

  .page-news__card-excerpt {
    font-size: 0.9rem;
  }

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

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

  .page-news__faq-answer {
    padding: 0 20px 15px;
    font-size: 0.95rem;
  }

  .page-news__cta-description {
    font-size: 1rem;
    padding: 0 15px;
  }

  .page-news__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px;
  }
  
  /* Mobile floating buttons */
  .page-news__mobile-floating-buttons {
    display: flex !important;
  }

  /* Universal image/video/container responsive rules */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-news video,
  .page-news__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-news__section,
  .page-news__card,
  .page-news__container,
  .page-news__video-section,
  .page-news__video-container,
  .page-news__video-wrapper,
  .page-news__cta-buttons,
  .page-news__button-group,
  .page-news__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  /* Specific padding for content containers to prevent edge-to-edge content */
  .page-news__news-list-section > .page-news__container,
  .page-news__faq-section > .page-news__container,
  .page-news__cta-bottom-section > .page-news__container {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  .page-news__news-card img {
    min-width: unset !important; /* Override desktop min-width for mobile */
    min-height: unset !important;
  }
}

/* Ensure content area images are not too small (desktop) */
.page-news__news-card img {
  min-width: 200px;
  min-height: 200px;
}

/* Color contrast fixes if needed */
.page-news__dark-bg {
  color: #ffffff;
  background: #11A84E;
}
.page-news__light-bg {
  color: #333333;
  background: #ffffff;
}
.page-news__medium-bg {
  color: #000000;
  background: #22C768;
}

/* Ensure no filter on images */
.page-news img {
  filter: none !important;
}