/* style/news.css */

/* Base styles for news page */
.page-news {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #f0f0f0; /* Light text for dark body background */
  background-color: transparent; /* Inherit from body or shared.css */
  padding-top: 120px; /* Spacing for fixed header on desktop */
}

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

.page-news__section-title {
  font-size: 36px;
  color: #FFD700; /* Gold for titles */
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.page-news__section-description {
  font-size: 18px;
  color: #ffffff;
  text-align: center;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.page-news__section-description a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__section-description a:hover {
  text-decoration: underline;
}

/* Hero Banner Section */
.page-news__hero-banner {
  background: linear-gradient(135deg, #003366, #0d1117);
  padding: 80px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-news__hero-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 2;
}

.page-news__hero-title {
  font-size: 48px;
  color: #FFD700;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.page-news__hero-description {
  font-size: 20px;
  color: #f0f0f0;
  margin-bottom: 40px;
  line-height: 1.7;
}

.page-news__hero-description a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__hero-description a:hover {
  text-decoration: underline;
}

.page-news__hero-button {
  display: inline-block;
  background-color: #FFD700;
  color: #003366;
  padding: 15px 30px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 20px;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: none;
  cursor: pointer;
}

.page-news__hero-button:hover {
  background-color: #e0b800;
  transform: translateY(-3px);
}

.page-news__hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.15;
}

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

/* Latest Articles Section */
.page-news__latest-articles {
  padding: 80px 0;
  background-color: #0d1117;
}

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

.page-news__article-card {
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

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

.page-news__article-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-news__article-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
  border-bottom: 2px solid #FFD700;
}

.page-news__article-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.page-news__article-title {
  font-size: 24px;
  color: #FFD700;
  margin-bottom: 15px;
  line-height: 1.4;
  font-weight: 600;
}

.page-news__article-title a {
  color: #FFD700;
  text-decoration: none;
}

.page-news__article-title a:hover {
  text-decoration: underline;
}

.page-news__article-excerpt {
  font-size: 16px;
  color: #f0f0f0;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-news__article-excerpt a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__article-excerpt a:hover {
  text-decoration: underline;
}

.page-news__article-date {
  font-size: 14px;
  color: #999;
  text-align: right;
  display: block;
}

.page-news__button-wrapper {
    text-align: center;
}

.page-news__view-all-button {
  display: inline-block;
  background-color: #003366;
  color: #FFD700;
  padding: 12px 25px;
  border-radius: 5px;
  text-decoration: none;
  font-size: 18px;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease;
  border: 2px solid #FFD700;
}

.page-news__view-all-button:hover {
  background-color: #FFD700;
  color: #003366;
}

/* Categories Section */
.page-news__categories-section {
  padding: 80px 0;
  background-color: #0d1117;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.page-news__category-item {
  background-color: rgba(0, 51, 102, 0.6);
  border: 1px solid #004488;
  border-radius: 12px;
  padding: 30px;
  text-align: center;
  transition: background-color 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.page-news__category-item:hover {
  background-color: #004488;
  transform: translateY(-5px);
  border-color: #FFD700;
}

.page-news__category-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  height: 100%;
  justify-content: center;
}

.page-news__category-title {
  font-size: 28px;
  color: #FFD700;
  margin-bottom: 15px;
  font-weight: bold;
}

.page-news__category-description {
  font-size: 16px;
  color: #f0f0f0;
  line-height: 1.6;
}

.page-news__category-description a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__category-description a:hover {
  text-decoration: underline;
}

/* Promo CTA Section */
.page-news__promo-cta {
  padding: 80px 0;
  background-color: #003366;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.page-news__promo-title {
  font-size: 40px;
  color: #FFD700;
  margin-bottom: 20px;
  font-weight: bold;
}

.page-news__promo-description {
  font-size: 20px;
  color: #f0f0f0;
  margin-bottom: 40px;
  line-height: 1.7;
}

.page-news__promo-description a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__promo-description a:hover {
  text-decoration: underline;
}

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

.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 20px;
  font-weight: bold;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid transparent;
}

.page-news__btn-primary {
  background-color: #FFD700;
  color: #003366;
}

.page-news__btn-primary:hover {
  background-color: #e0b800;
  transform: translateY(-3px);
}

.page-news__btn-secondary {
  background-color: transparent;
  color: #FFD700;
  border-color: #FFD700;
}

.page-news__btn-secondary:hover {
  background-color: #FFD700;
  color: #003366;
  transform: translateY(-3px);
}

/* FAQ Section */
.page-news__faq-section {
  padding: 80px 0;
  background-color: #0d1117;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.page-news__faq-item {
  margin-bottom: 15px;
  border-radius: 8px;
  overflow: hidden;
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  background-color: rgba(0, 51, 102, 0.7);
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-news__faq-question:hover {
  background-color: #004488;
  border-color: #FFD700;
}

.page-news__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  color: #FFD700;
  pointer-events: none; /* Prevent h3 from blocking click event */
}

.page-news__faq-question h3 a {
  color: #FFD700;
  text-decoration: none;
}

.page-news__faq-question h3 a:hover {
  text-decoration: underline;
}

.page-news__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: #FFD700;
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 20px;
  pointer-events: none; /* Prevent icon from blocking click event */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
}

.page-news__faq-item.active .page-news__faq-toggle {
  color: #ffffff;
  transform: rotate(45deg);
}

.page-news__faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
  padding: 0 25px;
  opacity: 0;
  color: #f0f0f0;
  background-color: rgba(0, 51, 102, 0.4);
}

.page-news__faq-item.active .page-news__faq-answer {
  max-height: 2000px !important; /* Ensure enough height for content */
  padding: 20px 25px !important;
  opacity: 1;
  border-radius: 0 0 8px 8px;
}

.page-news__faq-answer p {
  margin: 0;
  font-size: 16px;
  line-height: 1.7;
}

.page-news__faq-answer a {
  color: #FFD700;
  text-decoration: none;
  font-weight: bold;
}

.page-news__faq-answer a:hover {
  text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-news__hero-title {
    font-size: 42px;
  }
  .page-news__section-title {
    font-size: 32px;
  }
  .page-news__article-image {
    height: 220px;
  }
  .page-news__article-title {
    font-size: 22px;
  }
  .page-news__promo-title {
    font-size: 36px;
  }
}

@media (max-width: 768px) {
  .page-news {
    padding-top: 100px; /* Spacing for fixed header on mobile */
    font-size: 16px;
    line-height: 1.6;
  }
  .page-news__container,
  .page-news__hero-content,
  .page-news__promo-content,
  .page-news__faq-list {
    padding-left: 15px !important;
    padding-right: 15px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__hero-banner {
    padding: 60px 0;
  }
  .page-news__hero-title {
    font-size: 32px;
  }
  .page-news__hero-description {
    font-size: 16px;
  }
  .page-news__hero-button {
    padding: 12px 25px;
    font-size: 18px;
  }
  .page-news__latest-articles,
  .page-news__categories-section,
  .page-news__promo-cta,
  .page-news__faq-section {
    padding: 60px 0;
  }
  .page-news__section-title {
    font-size: 28px;
  }
  .page-news__section-description {
    font-size: 16px;
    margin-bottom: 30px;
  }
  .page-news__articles-grid,
  .page-news__category-grid {
    gap: 20px;
  }
  .page-news__article-image {
    height: 200px;
  }
  .page-news__article-title {
    font-size: 20px;
  }
  .page-news__article-content {
    padding: 20px;
  }
  .page-news__promo-title {
    font-size: 30px;
  }
  .page-news__promo-description {
    font-size: 16px;
  }
  .page-news__promo-buttons {
    flex-direction: column;
    gap: 15px;
  }
  .page-news__btn-primary,
  .page-news__btn-secondary {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    font-size: 18px;
  }
  .page-news__faq-question {
    padding: 18px 20px;
  }
  .page-news__faq-question h3 {
    font-size: 16px;
  }
  .page-news__faq-toggle {
    font-size: 24px;
    width: 28px;
    height: 28px;
    margin-left: 15px;
  }
  .page-news__faq-item.active .page-news__faq-answer {
    padding: 15px 20px !important;
  }
}

@media (max-width: 480px) {
  .page-news__hero-title {
    font-size: 28px;
  }
  .page-news__section-title {
    font-size: 24px;
  }
  .page-news__article-title {
    font-size: 18px;
  }
  .page-news__category-title {
    font-size: 24px;
  }
  .page-news__promo-title {
    font-size: 26px;
  }
}