/* style/news.css */

/* General page styling */
.page-news {
  background-color: var(--color-background, #0D0E12); /* Fallback to custom background if shared var is not set */
  color: var(--text-main, #FFF3E6); /* Main text color */
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

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

/* Hero Section */
.page-news__hero-section {
  position: relative;
  padding-top: 10px; /* Small top padding, assuming body handles --header-offset */
  color: #FFF3E6;
  text-align: center;
  overflow: hidden; /* Ensure image doesn't overflow */
}

.page-news__hero-image-wrapper {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  overflow: hidden;
}

.page-news__hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.page-news__hero-content {
  position: relative;
  z-index: 1;
  padding: 40px 20px;
  background: rgba(13, 14, 18, 0.7); /* Semi-transparent overlay for readability */
  margin-top: -100px; /* Overlap with image slightly for visual effect, but not text on image */
  padding-top: 120px; /* Adjust padding to make space for the overlap */
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
}

.page-news__main-title {
  font-size: 2.8em;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 15px;
  color: #FFB04D; /* Glow color for title */
  text-shadow: 0 0 8px rgba(255, 176, 77, 0.5);
}

.page-news__hero-description {
  font-size: 1.1em;
  max-width: 800px;
  margin: 0 auto 30px;
  color: #FFF3E6;
}

/* CTA Button */
.page-news__cta-button {
  display: inline-block;
  padding: 15px 30px;
  background: linear-gradient(180deg, #FFA53A 0%, #D96800 100%);
  color: #FFF3E6;
  text-decoration: none;
  border-radius: 8px;
  font-weight: bold;
  font-size: 1.1em;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(255, 165, 58, 0.4);
}

.page-news__cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 165, 58, 0.6);
}

/* Articles Section */
.page-news__articles-section {
  padding: 60px 0;
  background-color: #0D0E12; /* Background from custom colors */
}

.page-news__section-title {
  font-size: 2.2em;
  color: #FFB04D;
  text-align: center;
  margin-bottom: 40px;
  text-shadow: 0 0 5px rgba(255, 176, 77, 0.3);
}

.page-news__articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.page-news__article-card {
  background-color: #17191F; /* Card BG from custom colors */
  border: 1px solid #A84F0C; /* Border from custom colors */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: #FFF3E6; /* Text Main from custom colors */
  display: flex;
  flex-direction: column;
}

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

.page-news__article-image-wrapper {
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  position: relative;
  overflow: hidden;
}

.page-news__article-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

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

.page-news__article-title {
  font-size: 1.4em;
  margin-bottom: 10px;
  line-height: 1.3;
  flex-grow: 1; /* Allow title to take up available space */
}

.page-news__article-title a {
  color: #FFB04D; /* Glow color for title links */
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__article-title a:hover {
  color: #FFA53A;
}

.page-news__article-meta {
  font-size: 0.9em;
  color: rgba(255, 243, 230, 0.7);
  margin-bottom: 15px;
}

.page-news__article-excerpt {
  font-size: 1em;
  color: rgba(255, 243, 230, 0.9);
  margin-bottom: 20px;
}

.page-news__read-more-button {
  display: inline-block;
  padding: 10px 20px;
  background: #A84F0C; /* Border color as button background */
  color: #FFF3E6;
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  font-size: 0.95em;
  transition: background-color 0.3s ease;
  align-self: flex-start; /* Align to start in flex column */
}

.page-news__read-more-button:hover {
  background-color: #D96800; /* Deep Orange on hover */
}

/* Pagination */
.page-news__pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 50px;
  gap: 10px;
}

.page-news__pagination-link {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-width: 40px;
  height: 40px;
  padding: 0 15px;
  background-color: #17191F; /* Card BG */
  color: #FFF3E6; /* Text Main */
  text-decoration: none;
  border-radius: 5px;
  border: 1px solid #A84F0C; /* Border color */
  transition: background-color 0.3s ease, border-color 0.3s ease;
  font-weight: bold;
}

.page-news__pagination-link:hover {
  background-color: #FFA53A; /* Auxiliary color */
  border-color: #FFA53A;
  color: #17191F;
}

.page-news__pagination-link--active {
  background: linear-gradient(180deg, #FFA53A 0%, #D96800 100%); /* Button gradient */
  border-color: #FFA53A;
  color: #FFF3E6;
  cursor: default;
}

.page-news__pagination-link--active:hover {
  background: linear-gradient(180deg, #FFA53A 0%, #D96800 100%);
  border-color: #FFA53A;
  color: #FFF3E6;
}

/* CTA Section */
.page-news__cta-section {
  background-color: #0D0E12;
  padding: 80px 0;
}

.page-news__cta-container {
  display: flex;
  align-items: center;
  gap: 40px;
  background-color: #17191F; /* Card BG */
  border: 1px solid #A84F0C; /* Border color */
  border-radius: 15px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.page-news__cta-content {
  flex: 1;
  text-align: left;
}

.page-news__cta-title {
  font-size: 2em;
  color: #FFB04D;
  margin-bottom: 20px;
  line-height: 1.3;
}

.page-news__cta-description {
  font-size: 1.1em;
  color: #FFF3E6;
  margin-bottom: 30px;
}

.page-news__cta-image-wrapper {
  flex-shrink: 0;
  width: 50%;
  max-width: 500px;
  height: auto;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.page-news__cta-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.page-news__cta-button--secondary {
  background: #A84F0C; /* Border color */
  color: #FFF3E6;
  box-shadow: 0 4px 15px rgba(168, 79, 12, 0.4);
}

.page-news__cta-button--secondary:hover {
  background-color: #D96800; /* Deep Orange */
  box-shadow: 0 6px 20px rgba(168, 79, 12, 0.6);
}

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

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

details.page-news__faq-item {
  margin-bottom: 15px;
  border-radius: 10px;
  border: 1px solid #A84F0C; /* Border color */
  overflow: hidden;
  background-color: #17191F; /* Card BG */
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}
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;
  color: #FFB04D; /* Glow color for question text */
  font-weight: 600;
}
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-color: rgba(255, 165, 58, 0.1); /* Light hover effect */
}
.page-news__faq-qtext {
  flex: 1;
  font-size: 1.1em;
  line-height: 1.5;
  text-align: left;
}
.page-news__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  color: #FFA53A; /* Auxiliary color */
  flex-shrink: 0;
  margin-left: 15px;
  width: 30px;
  text-align: center;
}
details.page-news__faq-item .page-news__faq-answer {
  padding: 0 25px 20px;
  background-color: #0D0E12; /* Background color */
  border-top: 1px solid rgba(168, 79, 12, 0.5); /* Lighter border */
  border-radius: 0 0 10px 10px;
  color: #FFF3E6; /* Text Main */
}
.page-news__faq-answer p {
  margin: 0;
  padding-top: 15px;
}

/* Global Image Styles for Responsiveness */
.page-news img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-news__main-title {
    font-size: 2.2em;
  }
  .page-news__hero-description {
    font-size: 1em;
  }
  .page-news__articles-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .page-news__cta-container {
    flex-direction: column;
    text-align: center;
    padding: 30px;
  }
  .page-news__cta-content {
    text-align: center;
  }
  .page-news__cta-image-wrapper {
    width: 80%;
    max-width: 400px;
    margin-top: 30px;
  }
  .page-news__faq-qtext {
    font-size: 1em;
  }
  .page-news__faq-toggle {
    font-size: 24px;
  }
}

@media (max-width: 768px) {
  .page-news__container {
    padding: 0 15px; /* Mobile padding */
  }

  /* Hero Section */
  .page-news__hero-section {
    padding-top: 10px !important; /* Small top padding for mobile */
  }
  .page-news__hero-content {
    padding: 30px 15px;
    margin-top: -80px;
    padding-top: 100px;
  }
  .page-news__main-title {
    font-size: 1.8em;
    max-width: 100%;
    word-wrap: break-word;
  }
  .page-news__hero-description {
    font-size: 0.9em;
  }
  .page-news__cta-button {
    padding: 12px 25px;
    font-size: 1em;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* Articles Section */
  .page-news__articles-section {
    padding: 40px 0;
  }
  .page-news__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
    max-width: 100%;
    word-wrap: break-word;
  }
  .page-news__articles-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 25px;
  }
  .page-news__article-title {
    font-size: 1.2em;
    max-width: 100%;
    word-wrap: break-word;
  }
  .page-news__read-more-button {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    text-align: center;
  }
  .page-news__pagination {
    margin-top: 40px;
    flex-wrap: wrap;
    gap: 8px;
  }
  .page-news__pagination-link {
    min-width: 35px;
    height: 35px;
    padding: 0 10px;
    font-size: 0.9em;
  }

  /* CTA Section */
  .page-news__cta-section {
    padding: 50px 0;
  }
  .page-news__cta-container {
    padding: 30px 15px;
    flex-wrap: wrap;
    gap: 25px;
  }
  .page-news__cta-title {
    font-size: 1.6em;
    max-width: 100%;
    word-wrap: break-word;
  }
  .page-news__cta-description {
    font-size: 1em;
  }
  .page-news__cta-image-wrapper {
    width: 100%;
    max-width: none;
    margin-top: 25px;
  }
  .page-news__cta-button--secondary {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }

  /* FAQ Section */
  .page-news__faq-section {
    padding: 40px 0;
  }
  details.page-news__faq-item summary.page-news__faq-question {
    padding: 15px 18px;
  }
  .page-news__faq-qtext {
    font-size: 0.95em;
    max-width: calc(100% - 40px);
    word-wrap: break-word;
  }
  .page-news__faq-toggle {
    font-size: 22px;
    width: 25px;
  }
  details.page-news__faq-item .page-news__faq-answer {
    padding: 0 18px 15px;
  }
  
  /* Global Image & Container Responsiveness */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__section,
  .page-news__card,
  .page-news__container,
  .page-news__hero-section,
  .page-news__articles-section,
  .page-news__cta-section,
  .page-news__faq-section,
  .page-news__articles-grid,
  .page-news__cta-container,
  .page-news__button-group, /* If button group exists */
  .page-news__btn-container /* If button container exists */
  {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }
}