/* style/news.css */

/* General styles for the news page */
.page-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Default text color for light backgrounds */
  background-color: #ffffff; /* Default background for sections that aren't dark */
}

/* Ensure the main content area has the correct padding-top to avoid being hidden by fixed header */
.page-news__hero-section {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding-top: var(--header-offset, 120px); /* Apply header offset here */
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 500px; /* Minimum height for hero section */
}

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

.page-news__hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5); /* Dark overlay for text readability */
  z-index: 2;
}

.page-news__hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  color: #ffffff;
  max-width: 800px;
  padding: 20px;
}

.page-news__hero-title {
  font-size: 3.5rem;
  margin-bottom: 20px;
  color: #ffffff;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-news__hero-description {
  font-size: 1.25rem;
  margin-bottom: 30px;
  color: #f0f0f0;
}

/* Section general styles */
.page-news__section {
  padding: 60px 20px;
  margin-bottom: 20px;
}

.page-news__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px; /* Add horizontal padding for content */
}

.page-news__section-title {
  font-size: 2.5rem;
  color: #26A9E0; /* Brand primary color */
  text-align: center;
  margin-bottom: 20px;
}

.page-news__section-intro {
  font-size: 1.1rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
  color: #555555;
}

/* Dark section styles for contrast */
.page-news__dark-section {
  background-color: #26A9E0; /* Brand primary color as background */
  color: #ffffff; /* White text for contrast */
}

.page-news__dark-section .page-news__section-title {
  color: #ffffff; /* White title on dark background */
}

.page-news__dark-section .page-news__section-intro {
  color: #f0f0f0;
}

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 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; /* Brand primary color */
  color: #ffffff;
  border: 2px solid #26A9E0;
  margin: 10px;
}

.page-news__btn-primary:hover {
  background-color: #1f8ec4;
  border-color: #1f8ec4;
}

.page-news__btn-secondary {
  background-color: #ffffff;
  color: #26A9E0; /* Brand primary color */
  border: 2px solid #26A9E0;
  margin: 10px;
}

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

/* Latest News Section */
.page-news__news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-news__news-card {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

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

.page-news__news-card-title {
  font-size: 1.4rem;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-news__news-card-title a {
  color: #26A9E0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__news-card-title a:hover {
  color: #1f8ec4;
}

.page-news__news-excerpt {
  font-size: 0.95rem;
  color: #555555;
  margin-bottom: 15px;
  flex-grow: 1;
}

.page-news__read-more {
  display: inline-block;
  color: #26A9E0;
  text-decoration: none;
  font-weight: bold;
  margin-top: auto; /* Push to bottom */
}

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

/* Industry Insights Section */
.page-news__insight-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-news__insight-item {
  background-color: rgba(255, 255, 255, 0.1); /* Slightly transparent white on dark background */
  border-radius: 8px;
  padding: 30px;
  text-align: center;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.page-news__insight-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 20px;
  display: block;
}

.page-news__insight-title {
  font-size: 1.6rem;
  color: #ffffff;
  margin-bottom: 15px;
}

.page-news__insight-text {
  font-size: 1rem;
  color: #f0f0f0;
}

/* Game Reviews Section */
.page-news__review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.page-news__review-card {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
}

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

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

.page-news__review-title {
  font-size: 1.4rem;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-news__review-title a {
  color: #26A9E0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__review-title a:hover {
  color: #1f8ec4;
}

.page-news__review-text {
  font-size: 0.95rem;
  color: #555555;
  margin-bottom: 15px;
  flex-grow: 1;
}

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

.page-news__promotion-item {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 30px;
  text-align: center;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.page-news__promotion-title {
  font-size: 1.6rem;
  color: #ffffff;
  margin-bottom: 15px;
}

.page-news__promotion-text {
  font-size: 1rem;
  color: #f0f0f0;
  margin-bottom: 20px;
  flex-grow: 1;
}

/* Video Section */
.page-news__video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  max-width: 100%;
  background: #000;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  margin-top: 40px;
}

.page-news__video-link {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  cursor: pointer;
  text-decoration: none;
}

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

/* FAQ Section */
.page-news__faq-list {
  max-width: 800px;
  margin: 40px auto 0 auto;
}

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

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  cursor: pointer;
  background-color: #f9f9f9;
  transition: background-color 0.3s ease;
}

.page-news__faq-question:hover {
  background-color: #f0f0f0;
}

.page-news__faq-title {
  font-size: 1.2rem;
  color: #26A9E0;
  margin: 0;
}

.page-news__faq-toggle {
  font-size: 1.5rem;
  font-weight: bold;
  color: #26A9E0;
  transition: transform 0.3s ease;
}

.page-news__faq-item.active .page-news__faq-toggle {
  transform: rotate(45deg); /* Change + to X or - */
}

.page-news__faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background-color: #ffffff;
}

.page-news__faq-item.active .page-news__faq-answer {
  max-height: 1000px !important; /* Ensure enough height for content */
  padding: 20px;
}

.page-news__faq-answer p {
  margin: 0;
  color: #555555;
}

/* CTA Section */
.page-news__cta-section {
  text-align: center;
  padding: 80px 20px;
}

.page-news__cta-container {
  max-width: 900px;
}

.page-news__cta-title {
  font-size: 2.8rem;
  color: #ffffff;
  margin-bottom: 25px;
}

.page-news__cta-description {
  font-size: 1.2rem;
  color: #f0f0f0;
  margin-bottom: 40px;
}

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

/* Responsive adjustments */
@media (max-width: 1024px) {
  .page-news__hero-title {
    font-size: 3rem;
  }
  .page-news__hero-description {
    font-size: 1.1rem;
  }
  .page-news__section-title {
    font-size: 2.2rem;
  }
  .page-news__cta-title {
    font-size: 2.4rem;
  }
}

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

  .page-news__hero-section {
    min-height: 400px;
    padding-top: var(--header-offset, 120px) !important; /* Ensure offset on mobile */
  }

  .page-news__hero-title {
    font-size: 2.2rem;
  }
  .page-news__hero-description {
    font-size: 1rem;
  }
  .page-news__btn-primary,
  .page-news__btn-secondary {
    padding: 12px 20px;
    font-size: 0.9rem;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    margin: 5px 0; /* Stack buttons vertically */
  }
  .page-news__cta-buttons {
    flex-direction: column;
    gap: 10px;
    padding: 0 15px; /* Add padding to button container */
  }

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

  .page-news__section-title {
    font-size: 1.8rem;
  }
  .page-news__section-intro {
    font-size: 1rem;
  }

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

  .page-news__news-image,
  .page-news__insight-image,
  .page-news__review-image {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  /* Ensure all image containers are responsive */
  .page-news__news-card,
  .page-news__insight-item,
  .page-news__review-card,
  .page-news__promotion-item {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-news__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 0;
    padding-right: 0;
    overflow: hidden !important;
  }

  .page-news__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }

  .page-news__cta-title {
    font-size: 2rem;
  }
  .page-news__cta-description {
    font-size: 1rem;
  }

  .page-news__faq-question {
    padding: 15px;
  }
  .page-news__faq-title {
    font-size: 1.1rem;
  }
  .page-news__faq-answer {
    padding: 0 15px;
  }
  .page-news__faq-item.active .page-news__faq-answer {
    padding: 15px;
  }
}

@media (max-width: 480px) {
  .page-news__hero-title {
    font-size: 1.8rem;
  }
  .page-news__section-title {
    font-size: 1.6rem;
  }
  .page-news__cta-title {
    font-size: 1.8rem;
  }
}