/* style/news.css */

/* --- General Styles --- */
.page-news {
  font-family: 'Arial', sans-serif;
  color: #333333; /* Dark text for light background */
  background-color: #FFFFFF; /* Default body background is white */
  line-height: 1.6;
  padding-top: 10px; /* Small top padding, body handles header offset */
}

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

.page-news__section-title {
  font-size: 32px;
  font-weight: 700;
  color: #26A9E0; /* Brand primary color for titles */
  text-align: center;
  margin-bottom: 40px;
  position: relative;
  padding-bottom: 15px;
}

.page-news__section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background-color: #26A9E0;
  border-radius: 2px;
}

.page-news__section-title--light {
  color: #FFFFFF; /* White text for dark backgrounds */
}

.page-news__section-title--light::after {
  background-color: #FFFFFF;
}

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

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

.page-news__btn-primary:hover {
  background-color: #1a8cc7;
  border-color: #1a8cc7;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

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

.page-news__btn-secondary:hover {
  background-color: #26A9E0;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

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

/* --- Hero Section --- */
.page-news__hero-section {
  position: relative;
  overflow: hidden;
  margin-bottom: 50px;
  background-color: #f0f8ff; /* Light background for contrast */
}

.page-news__hero-image-wrapper {
  width: 100%;
  max-height: 450px; /* Limit height of the hero image */
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.page-news__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  min-height: 200px; /* Minimum size */
}

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

.page-news__main-title {
  font-size: 44px;
  color: #26A9E0;
  margin-bottom: 20px;
  line-height: 1.2;
  font-weight: 800;
}

.page-news__intro-text {
  font-size: 18px;
  color: #555555;
  margin-bottom: 30px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* --- Articles Section --- */
.page-news__articles-section {
  padding: 50px 0;
  background-color: #FFFFFF;
}

.page-news__featured-grid {
  display: grid;
  grid-template-columns: 1fr; /* Featured article takes full width */
  gap: 30px;
  margin-bottom: 60px;
}

.page-news__featured-card {
  background-color: #FFFFFF;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-news__featured-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.page-news__featured-card .page-news__card-image-wrapper {
  width: 100%;
  height: 450px; /* Fixed height for featured image */
  overflow: hidden;
}

.page-news__featured-card .page-news__card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  min-height: 200px;
}

.page-news__featured-card:hover .page-news__card-image {
  transform: scale(1.05);
}

.page-news__featured-card .page-news__card-content {
  padding: 30px;
  flex-grow: 1;
}

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

.page-news__article-card {
  background-color: #FFFFFF;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.07);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-news__card-image-wrapper {
  width: 100%;
  height: 220px; /* Fixed height for article card image */
  overflow: hidden;
}

.page-news__card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  min-height: 200px;
}

.page-news__article-card:hover .page-news__card-image {
  transform: scale(1.05);
}

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

.page-news__card-date {
  font-size: 14px;
  color: #888888;
  margin-bottom: 10px;
  display: block;
}

.page-news__card-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 15px;
  line-height: 1.3;
}

.page-news__card-title a {
  color: #333333;
  text-decoration: none;
  transition: color 0.3s ease;
}

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

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

.page-news__read-more {
  display: inline-flex;
  align-items: center;
  font-size: 15px;
  font-weight: 600;
  color: #26A9E0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__read-more:hover {
  color: #1a8cc7;
}

.page-news__read-more span {
  margin-left: 5px;
  transition: transform 0.3s ease;
}

.page-news__read-more:hover span {
  transform: translateX(5px);
}

/* --- FAQ Section --- */
.page-news__faq-section {
  padding: 80px 0;
  background-color: #26A9E0; /* Dark background for FAQ */
  color: #FFFFFF; /* Light text for dark background */
}

.page-news__dark-bg {
  background-color: #26A9E0;
  color: #FFFFFF;
}

details.page-news__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
details.page-news__faq-item summary.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  cursor: pointer;
  user-select: none;
  list-style: none;
  transition: background-color 0.3s ease;
}
details.page-news__faq-item summary.page-news__faq-question::-webkit-details-marker {
  display: none;
}
details.page-news__faq-item summary.page-news__faq-question:hover {
  background: rgba(255, 255, 255, 0.2);
}
.page-news__faq-qtext {
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  text-align: left;
  color: #FFFFFF;
}
.page-news__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  color: #FFFFFF;
  flex-shrink: 0;
  margin-left: 20px;
  width: 30px;
  text-align: center;
}
details.page-news__faq-item .page-news__faq-answer {
  padding: 0 25px 25px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 0 0 8px 8px;
}
.page-news__faq-answer p {
  font-size: 16px;
  line-height: 1.7;
  color: #f0f0f0;
  margin: 0;
}


/* --- Responsive Styles --- */

/* Tablet & Mobile */
@media (max-width: 1024px) {
  .page-news__hero-content {
    margin: 30px auto;
  }
  .page-news__main-title {
    font-size: 38px;
  }
  .page-news__intro-text {
    font-size: 17px;
  }
  .page-news__section-title {
    font-size: 28px;
    margin-bottom: 30px;
  }
  .page-news__featured-card .page-news__card-content {
    padding: 25px;
  }
  .page-news__card-title {
    font-size: 20px;
  }
  .page-news__card-description {
    font-size: 14px;
  }
  details.page-news__faq-item summary.page-news__faq-question {
    padding: 15px 20px;
  }
  .page-news__faq-qtext {
    font-size: 17px;
  }
  .page-news__faq-toggle {
    font-size: 26px;
    width: 25px;
  }
  details.page-news__faq-item .page-news__faq-answer {
    padding: 0 20px 20px;
  }
  .page-news__faq-answer p {
    font-size: 15px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .page-news {
    padding-top: 10px !important; /* Small top padding, body handles header offset */
    font-size: 16px;
    line-height: 1.6;
  }
  .page-news__container {
    padding: 0 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Hero Section */
  .page-news__hero-section {
    margin-bottom: 30px;
  }
  .page-news__hero-image-wrapper {
    max-height: 250px;
  }
  .page-news__hero-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__hero-content {
    margin: 20px auto;
    padding: 0 15px;
  }
  .page-news__main-title {
    font-size: clamp(28px, 8vw, 36px); /* Clamp for h1 */
    margin-bottom: 15px;
  }
  .page-news__intro-text {
    font-size: 16px;
    margin-bottom: 25px;
  }
  .page-news__btn-primary {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  /* Articles Section */
  .page-news__articles-section {
    padding: 30px 0;
  }
  .page-news__section-title {
    font-size: 24px;
    margin-bottom: 25px;
  }
  .page-news__featured-grid {
    margin-bottom: 40px;
  }
  .page-news__featured-card .page-news__card-image-wrapper {
    height: 200px;
  }
  .page-news__featured-card .page-news__card-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__featured-card .page-news__card-content {
    padding: 20px;
  }
  .page-news__latest-grid {
    grid-template-columns: 1fr; /* Single column for latest articles */
    gap: 20px;
  }
  .page-news__article-card .page-news__card-image-wrapper {
    height: 180px;
  }
  .page-news__article-card .page-news__card-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__card-content {
    padding: 20px;
  }
  .page-news__card-title {
    font-size: 18px;
  }
  .page-news__card-description {
    font-size: 14px;
  }
  .page-news__read-more {
    font-size: 14px;
  }
  .page-news__view-all-button-wrapper {
    margin-top: 30px;
  }
  .page-news__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  /* FAQ Section */
  .page-news__faq-section {
    padding: 50px 0;
  }
  details.page-news__faq-item summary.page-news__faq-question {
    padding: 15px;
  }
  .page-news__faq-qtext {
    font-size: 16px;
  }
  .page-news__faq-toggle {
    font-size: 24px;
    margin-left: 15px;
    width: 28px;
  }
  details.page-news__faq-item .page-news__faq-answer {
    padding: 0 15px 15px;
  }
  .page-news__faq-answer p {
    font-size: 14px;
  }

  /* General image and button rules for mobile */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .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;
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-news__cta-buttons,
  .page-news__button-group,
  .page-news__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 10px;
    display: flex; /* Ensure flex context for gap */
    flex-direction: column; /* Default to column for multiple buttons */
  }
}