/* style/news.css */

/* Global styles for page-news scope */
.page-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-main-color, #F2FFF6); /* Default text color for dark background */
  background-color: var(--background-main-color, #08160F); /* Body background from shared */
}

/* Color variables based on provided palette */
:root {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  --card-bg-color: #11271B;
  --background-main-color: #08160F;
  --text-main-color: #F2FFF6;
  --text-secondary-color: #A7D9B8;
  --border-color: #2E7A4E;
  --glow-color: #57E38D;
  --gold-color: #F2C14E;
  --divider-color: #1E3A2A;
  --deep-green-color: #0A4B2C;
}

/* Container for consistent spacing */
.page-news__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Section styling */
.page-news__hero-section,
.page-news__introduction-section,
.page-news__featured-news-section,
.page-news__updates-section,
.page-news__promotions-section,
.page-news__guides-section,
.page-news__community-section,
.page-news__faq-section,
.page-news__cta-bottom-section {
  padding: 60px 0;
  text-align: center;
}

/* Background colors for sections */
.page-news__light-bg {
  background-color: var(--background-main-color); /* Still dark, but lighter than pure black */
  color: var(--text-main-color);
}

.page-news__dark-bg {
  background-color: var(--card-bg-color); /* Slightly darker for contrast */
  color: var(--text-main-color);
}

/* Hero Section */
.page-news__hero-section {
  padding: 10px 0 60px 0; /* Small top padding, not var(--header-offset) */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

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

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

.page-news__main-title {
  color: var(--gold-color); /* Using gold for main title for emphasis */
  font-weight: bold;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
  /* No fixed font-size, rely on clamp if needed, otherwise let browser decide */
}

.page-news__description {
  color: var(--text-secondary-color);
  font-size: 1.1em;
  margin-bottom: 30px;
}

/* Section Titles */
.page-news__section-title {
  color: var(--gold-color);
  font-size: 2.5em;
  margin-bottom: 40px;
  font-weight: bold;
}

/* Text Blocks */
.page-news__text-block {
  color: var(--text-main-color);
  margin-bottom: 1em;
  font-size: 1.05em;
}

/* Buttons */
.page-news__cta-button {
  display: inline-block;
  background: var(--button-gradient);
  color: #ffffff;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  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(0, 0, 0, 0.2);
}

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

.page-news__cta-button--secondary {
  background: none;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  box-shadow: none;
  margin-left: 15px;
}

.page-news__cta-button--secondary:hover {
  background: var(--primary-color);
  color: #ffffff;
}

.page-news__button-group {
  margin-top: 30px;
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap; /* Allow wrapping on small screens */
}

/* News Grid / Card Layouts */
.page-news__news-grid,
.page-news__promo-grid,
.page-news__guide-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-news__news-card,
.page-news__promo-card,
.page-news__guide-card {
  background-color: var(--card-bg-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  text-align: left;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
}

.page-news__news-card:hover,
.page-news__promo-card:hover,
.page-news__guide-card:hover {
  transform: translateY(-5px);
}

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

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

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

.page-news__card-title a {
  color: var(--text-main-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__card-title a:hover {
  color: var(--gold-color);
}

.page-news__card-meta {
  font-size: 0.9em;
  color: var(--text-secondary-color);
  margin-bottom: 15px;
}

.page-news__card-excerpt {
  color: var(--text-secondary-color);
  font-size: 1em;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-news__read-more-button {
  display: inline-block;
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-news__read-more-button:hover {
  color: var(--gold-color);
}

/* Updates Section */
.page-news__update-item {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-bottom: 40px;
  background-color: var(--card-bg-color);
  border-radius: 12px;
  padding: 30px;
  text-align: left;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.page-news__update-item:last-child {
  margin-bottom: 0;
}

.page-news__update-image {
  width: 50%;
  border-radius: 8px;
  object-fit: cover;
  display: block;
  min-width: 200px; /* Ensure minimum size */
  height: auto;
}

.page-news__update-content {
  width: 50%;
}

.page-news__update-title {
  font-size: 1.8em;
  color: var(--text-main-color);
  margin-bottom: 10px;
}

.page-news__update-date {
  font-size: 0.9em;
  color: var(--text-secondary-color);
  margin-bottom: 15px;
}

/* Community Section */
.page-news__community-image {
  width: 100%;
  max-width: 800px;
  height: auto;
  border-radius: 12px;
  margin: 40px auto 0 auto;
  display: block;
}

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

.page-news__faq-item {
  background-color: var(--card-bg-color);
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.page-news__faq-item summary {
  list-style: none; /* Hide default marker */
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.1em;
  color: var(--text-main-color);
  background-color: var(--deep-green-color); /* Slightly different background for summary */
  border-bottom: 1px solid var(--divider-color);
  transition: background-color 0.3s ease;
}

.page-news__faq-item summary::-webkit-details-marker {
  display: none; /* Hide default marker for webkit browsers */
}

.page-news__faq-item summary:hover {
  background-color: var(--primary-color);
}

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

.page-news__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  margin-left: 15px;
  color: var(--gold-color);
}

.page-news__faq-item[open] .page-news__faq-toggle {
  content: "−"; /* Change to minus when open, handled by JS if not details */
}

.page-news__faq-answer {
  padding: 20px 25px;
  font-size: 1em;
  color: var(--text-secondary-color);
}

/* Call to action at bottom */
.page-news__cta-bottom-section {
  padding: 80px 0;
  background-color: var(--deep-green-color);
}

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

/* --- Responsive Design --- */
@media (max-width: 1024px) {
  .page-news__main-title {
    font-size: 2.2em;
  }
  .page-news__section-title {
    font-size: 2em;
  }
  .page-news__update-item {
    flex-direction: column;
  }
  .page-news__update-image,
  .page-news__update-content {
    width: 100%;
  }
  .page-news__update-image {
    margin-bottom: 20px;
  }
}

@media (max-width: 768px) {
  .page-news__hero-section,
  .page-news__introduction-section,
  .page-news__featured-news-section,
  .page-news__updates-section,
  .page-news__promotions-section,
  .page-news__guides-section,
  .page-news__community-section,
  .page-news__faq-section,
  .page-news__cta-bottom-section {
    padding: 40px 0;
  }

  .page-news__container {
    padding: 0 15px;
  }

  .page-news__main-title {
    font-size: 1.8em;
  }
  .page-news__section-title {
    font-size: 1.8em;
    margin-bottom: 30px;
  }
  .page-news__description,
  .page-news__text-block {
    font-size: 1em;
  }
  .page-news__cta-button {
    font-size: 1em;
    padding: 12px 25px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }
  .page-news__cta-button--secondary {
    margin-left: 0;
    margin-top: 15px; /* Stack buttons vertically */
  }
  .page-news__button-group {
    flex-direction: column;
    gap: 15px;
  }

  .page-news__news-grid,
  .page-news__promo-grid,
  .page-news__guide-cards {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-news__card-image {
    height: 180px;
  }
  .page-news__card-title {
    font-size: 1.2em;
  }

  .page-news__update-item {
    padding: 20px;
  }

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

  /* Image responsiveness */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-news__section,
  .page-news__card,
  .page-news__container,
  .page-news__hero-section,
  .page-news__introduction-section,
  .page-news__featured-news-section,
  .page-news__updates-section,
  .page-news__promotions-section,
  .page-news__guides-section,
  .page-news__community-section,
  .page-news__faq-section,
  .page-news__cta-bottom-section {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    overflow: hidden !important; /* Ensure no overflow */
  }
  .page-news__hero-section {
    padding-top: 10px !important; /* body already handles offset */
  }

  /* Video responsiveness (if any, though none explicitly added yet, but good to have rules) */
  .page-news video,
  .page-news__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-news__video-section,
  .page-news__video-container,
  .page-news__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    overflow: hidden !important;
  }
}