/* style/news.css */

:root {
  --primary-color: #11A84E;
  --secondary-color: #22C768;
  --card-bg-color: #11271B;
  --background-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;
  --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
}

/* Base styles for page-news scope */
.page-news {
  font-family: 'Arial', sans-serif;
  color: var(--text-main-color); /* Default text color for the page */
  background-color: var(--background-color); /* Ensure body background is respected */
}

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

.page-news__section-title {
  font-size: clamp(28px, 4vw, 42px);
  color: var(--text-main-color);
  text-align: center;
  margin-bottom: 20px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

.page-news__section-description {
  font-size: 16px;
  color: var(--text-secondary-color);
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
  line-height: 1.6;
}

.page-news__cta-button {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 8px;
  background: var(--button-gradient);
  color: #ffffff;
  font-size: 18px;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  max-width: 100%; /* Ensure button responsiveness */
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.page-news__cta-button:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.page-news__cta-button--secondary {
  background: var(--card-bg-color);
  border: 1px solid var(--border-color);
  color: var(--text-main-color);
}

.page-news__cta-button--secondary:hover {
  background: var(--deep-green-color);
  border-color: var(--secondary-color);
}

.page-news__cta-button--small {
  padding: 8px 20px;
  font-size: 16px;
}

.page-news__button-wrapper {
  text-align: center;
  margin-top: 40px;
}

/* Hero Section */
.page-news__hero-section {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 20px;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  overflow: hidden;
  box-sizing: border-box;
}

.page-news__hero-image-wrapper {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  box-sizing: border-box;
}

.page-news__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.page-news__hero-content {
  text-align: center;
  max-width: 900px;
  margin-top: 40px;
}

.page-news__main-title {
  font-size: clamp(36px, 5vw, 60px);
  color: var(--gold-color);
  margin-bottom: 20px;
  font-weight: 800;
  line-height: 1.1;
}

.page-news__hero-description {
  font-size: 20px;
  color: var(--text-secondary-color);
  margin-bottom: 30px;
  line-height: 1.6;
}

/* Latest News Section */
.page-news__latest-news-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

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

.page-news__news-card {
  background-color: var(--card-bg-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-news__news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

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

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

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

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

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

.page-news__news-card-excerpt {
  font-size: 16px;
  color: var(--text-secondary-color);
  margin-bottom: 15px;
  line-height: 1.6;
  flex-grow: 1;
}

.page-news__news-card-date {
  font-size: 14px;
  color: var(--secondary-color);
  margin-top: auto;
}

/* Promotions & Events Section */
.page-news__promotions-events-section {
  padding: 80px 0;
  background-color: var(--primary-color);
  color: #ffffff;
}

.page-news__promotions-events-section .page-news__section-title,
.page-news__promotions-events-section .page-news__section-description {
  color: #ffffff;
}

.page-news__promotions-wrapper {
  display: flex;
  align-items: center;
  gap: 50px;
  flex-wrap: wrap;
}

.page-news__promotions-image {
  flex: 1;
  min-width: 300px;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  width: 100%; /* Ensure responsiveness */
  height: auto;
  display: block;
}

.page-news__promotions-list {
  flex: 1.5;
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-news__promotions-item {
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 20px;
  position: relative;
  padding-left: 30px;
}

.page-news__promotions-item::before {
  content: '✔';
  color: var(--gold-color);
  position: absolute;
  left: 0;
  font-weight: 700;
}

/* Ecosystem Section */
.page-news__ecosystem-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

.page-news__ecosystem-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  margin-bottom: 40px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

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

.page-news__game-category {
  background-color: var(--card-bg-color);
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-news__category-title {
  font-size: 24px;
  color: var(--text-main-color);
  margin-bottom: 15px;
  font-weight: 700;
}

.page-news__category-description {
  font-size: 16px;
  color: var(--text-secondary-color);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.page-news__game-category .page-news__cta-button {
  margin-top: auto;
}

/* Why Choose Section */
.page-news__why-choose-section {
  padding: 80px 0;
  background-color: var(--deep-green-color);
  color: #ffffff;
}

.page-news__why-choose-section .page-news__section-title,
.page-news__why-choose-section .page-news__section-description {
  color: #ffffff;
}

.page-news__why-choose-content {
  display: flex;
  align-items: center;
  gap: 50px;
  flex-wrap: wrap-reverse;
}

.page-news__why-choose-list {
  flex: 1.5;
  list-style: none;
  padding: 0;
  margin: 0;
}

.page-news__why-choose-item {
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 20px;
  position: relative;
  padding-left: 30px;
}

.page-news__why-choose-item::before {
  content: '★';
  color: var(--gold-color);
  position: absolute;
  left: 0;
  font-weight: 700;
}

.page-news__why-choose-image {
  flex: 1;
  min-width: 300px;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  width: 100%;
  height: auto;
  display: block;
}

/* FAQ Section */
.page-news__faq-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

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

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

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-main-color);
  cursor: pointer;
  background-color: var(--card-bg-color);
  border-bottom: 1px solid var(--divider-color);
  transition: background-color 0.3s ease;
}

.page-news__faq-question:hover {
  background-color: var(--deep-green-color);
}

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

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

.page-news__faq-answer {
  padding: 20px 25px;
  font-size: 16px;
  color: var(--text-secondary-color);
  line-height: 1.6;
}

/* Details tag styling */
.page-news__faq-item summary {
  list-style: none;
}

.page-news__faq-item summary::-webkit-details-marker {
  display: none;
}

.page-news__faq-item[open] .page-news__faq-question {
  border-bottom: none;
}

/* Responsive adjustments */
@media (max-width: 992px) {
  .page-news__hero-content {
    margin-top: 30px;
  }
  .page-news__hero-description {
    font-size: 18px;
  }
  .page-news__promotions-wrapper, .page-news__why-choose-content {
    flex-direction: column;
    text-align: center;
  }
  .page-news__promotions-image, .page-news__why-choose-image {
    order: -1;
  }
  .page-news__promotions-list, .page-news__why-choose-list {
    text-align: left;
    width: 100%;
  }
  .page-news__game-categories {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .page-news__container {
    padding: 0 15px;
  }
  .page-news__hero-section {
    padding: 40px 15px;
    padding-top: 10px !important; /* body handles --header-offset, this is for visual spacing */
  }
  .page-news__main-title {
    font-size: clamp(30px, 8vw, 45px);
  }
  .page-news__hero-description {
    font-size: 16px;
  }
  .page-news__section-title {
    font-size: clamp(24px, 6vw, 36px);
  }
  .page-news__section-description {
    font-size: 15px;
  }
  .page-news__cta-button {
    padding: 10px 20px;
    font-size: 16px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
  }
  .page-news__button-wrapper {
    padding: 0 15px;
    box-sizing: border-box;
  }
  .page-news__news-grid {
    grid-template-columns: 1fr;
  }
  .page-news__news-card-title {
    font-size: 20px;
  }
  .page-news__news-card-excerpt, .page-news__promotions-item, .page-news__why-choose-item {
    font-size: 15px;
  }
  .page-news__faq-question {
    font-size: 16px;
    padding: 15px 20px;
  }
  .page-news__faq-answer {
    font-size: 15px;
    padding: 15px 20px;
  }
  /* Image responsive rules */
  .page-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }
  .page-news__hero-image-wrapper,
  .page-news__news-card-image,
  .page-news__promotions-image,
  .page-news__ecosystem-image,
  .page-news__why-choose-image {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
  /* General section padding for mobile */
  .page-news__latest-news-section,
  .page-news__promotions-events-section,
  .page-news__ecosystem-section,
  .page-news__why-choose-section,
  .page-news__faq-section {
    padding: 40px 0;
  }
  .page-news__game-category {
    padding: 20px;
  }
  .page-news__promotions-list,
  .page-news__why-choose-list {
    padding: 0 15px;
    box-sizing: border-box;
  }
  .page-news__promotions-item::before,
  .page-news__why-choose-item::before {
    left: 15px;
  }
  .page-news__promotions-item,
  .page-news__why-choose-item {
    padding-left: 40px;
  }
}