/* Variable definitions for consistency */
:root {
  --primary-color: #007BFF;
  --secondary-color: #FFD700;
  --dark-bg-1: #0d0d0d; /* Assuming a dark background from shared.css */
  --light-text-color: #ffffff;
  --dark-text-color: #333333;
  --card-bg-color: #ffffff;
  --border-color: #e0e0e0;
}

/* Base styles for the news page */
.page-news {
  background-color: var(--dark-bg-1); /* Inheriting from body, assumed dark */
  color: var(--light-text-color);
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
}

/* Fixed header padding */
.page-news__hero-section {
  padding-top: 180px; /* Desktop: Adjust based on fixed header height */
  padding-bottom: 60px;
  background: linear-gradient(135deg, var(--primary-color), #0056b3); /* Darker blue gradient */
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-news__hero-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 30px;
  position: relative;
  z-index: 1;
  padding: 0 20px;
}

.page-news__hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.page-news__hero-title {
  font-size: 48px;
  color: var(--light-text-color);
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
}

.page-news__hero-description {
  font-size: 20px;
  color: #e0e0e0;
  margin-bottom: 30px;
}

.page-news__highlight {
  color: var(--secondary-color);
  font-weight: bold;
}

.page-news__cta-button {
  display: inline-block;
  padding: 15px 40px;
  background: var(--secondary-color);
  color: var(--dark-text-color);
  text-decoration: none;
  border-radius: 8px;
  font-size: 20px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  border: none;
  cursor: pointer;
}

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

.page-news__hero-image {
  width: 100%;
  max-width: 900px;
  margin-top: 30px;
}

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

.page-news__section {
  padding: 60px 0;
  position: relative;
}

.page-news__section:nth-of-type(even) {
  background-color: #1a1a1a; /* Slightly lighter dark background for contrast */
}

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

.page-news__section-title {
  font-size: 36px;
  color: var(--light-text-color);
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
}

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

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

.page-news__article-card {
  background: #2a2a2a; /* Darker card background for contrast on dark page bg */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

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

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

.page-news__article-title {
  font-size: 22px;
  font-weight: bold;
  color: var(--light-text-color);
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-news__article-link {
  color: var(--light-text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__article-link:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

.page-news__article-meta {
  font-size: 14px;
  color: #aaaaaa;
  margin-bottom: 15px;
}

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

.page-news__article-excerpt .page-news__link {
  color: var(--secondary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-news__article-excerpt .page-news__link:hover {
  color: #e6b800;
  text-decoration: underline;
}

.page-news__read-more {
  display: inline-flex;
  align-items: center;
  color: var(--secondary-color);
  text-decoration: none;
  font-weight: bold;
  font-size: 16px;
  transition: color 0.3s ease;
  margin-top: auto; /* Push to bottom */
}

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

.page-news__arrow {
  margin-left: 8px;
  transition: transform 0.3s ease;
}

.page-news__read-more:hover .page-news__arrow {
  transform: translateX(5px);
}

/* In-depth Analysis Section */
.page-news__analysis-content {
  background: #2a2a2a;
  border-radius: 10px;
  padding: 40px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-news__analysis-subtitle {
  font-size: 28px;
  color: var(--light-text-color);
  font-weight: bold;
  margin-top: 30px;
  margin-bottom: 15px;
}

.page-news__analysis-subtitle:first-of-type {
  margin-top: 0;
}

.page-news__analysis-text {
  font-size: 17px;
  color: #cccccc;
  margin-bottom: 25px;
  line-height: 1.7;
}

.page-news__analysis-text .page-news__link {
  color: var(--secondary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-news__analysis-text .page-news__link:hover {
  color: #e6b800;
  text-decoration: underline;
}

.page-news__analysis-img {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: cover;
  border-radius: 8px;
  margin: 20px 0;
  display: block;
}

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

.page-news__guide-card {
  background: #2a2a2a;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

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

.page-news__guide-title {
  font-size: 22px;
  font-weight: bold;
  color: var(--light-text-color);
  padding: 20px 25px 10px;
  line-height: 1.3;
}

.page-news__guide-link {
  color: var(--light-text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-news__guide-link:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

.page-news__guide-excerpt {
  font-size: 16px;
  color: #cccccc;
  padding: 0 25px 20px;
  flex-grow: 1;
}

/* FAQ Section */
.page-news__faq-section {
  background-color: #1a1a1a;
}

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

.page-news__faq-item {
  margin-bottom: 15px;
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.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;
  padding: 0 20px;
  opacity: 0;
  background: #2a2a2a; /* Darker background for answer */
  color: #cccccc;
  font-size: 16px;
}

.page-news__faq-item.active .page-news__faq-answer {
  max-height: 2000px !important; /* Ensure it expands fully */
  padding: 20px !important;
  opacity: 1;
  border-radius: 0 0 5px 5px;
}

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 20px;
  background: #3a3a3a; /* Darker background for question */
  border: 1px solid #4a4a4a;
  border-radius: 5px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.page-news__faq-question:hover {
  background: #4a4a4a;
  border-color: #5a5a5a;
}

.page-news__faq-question:active {
  background: #5a5a5a;
}

.page-news__faq-question h3 {
  margin: 0;
  padding: 0;
  flex: 1;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.5;
  pointer-events: none;
  color: var(--light-text-color);
}

.page-news__faq-toggle {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
  color: var(--secondary-color);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 15px;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
}

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

.page-news__faq-answer .page-news__link {
  color: var(--secondary-color);
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.page-news__faq-answer .page-news__link:hover {
  color: #e6b800;
  text-decoration: underline;
}

/* CTA Bottom Section */
.page-news__cta-bottom-section {
  background: linear-gradient(135deg, #0056b3, var(--primary-color));
  padding: 80px 20px;
  text-align: center;
}

.page-news__cta-bottom-container {
  max-width: 900px;
  margin: 0 auto;
}

.page-news__cta-bottom-title {
  font-size: 40px;
  color: var(--light-text-color);
  margin-bottom: 20px;
  font-weight: bold;
}

.page-news__cta-bottom-description {
  font-size: 20px;
  color: #e0e0e0;
  margin-bottom: 40px;
}

.page-news__cta-bottom-button {
  display: inline-block;
  padding: 18px 45px;
  background: var(--secondary-color);
  color: var(--dark-text-color);
  text-decoration: none;
  border-radius: 8px;
  font-size: 22px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
  border: none;
  cursor: pointer;
}

.page-news__cta-bottom-button:hover {
  background: #e6b800;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .page-news__hero-title {
    font-size: 42px;
  }

  .page-news__hero-description {
    font-size: 18px;
  }

  .page-news__cta-button {
    padding: 12px 30px;
    font-size: 18px;
  }

  .page-news__section-title {
    font-size: 32px;
  }

  .page-news__section-description {
    font-size: 16px;
  }

  .page-news__article-title, .page-news__guide-title {
    font-size: 20px;
  }

  .page-news__analysis-subtitle {
    font-size: 24px;
  }

  .page-news__cta-bottom-title {
    font-size: 36px;
  }

  .page-news__cta-bottom-button {
    padding: 15px 35px;
    font-size: 20px;
  }
}

@media (max-width: 768px) {
  .page-news__hero-section {
    padding-top: 140px !important; /* Mobile: Adjust based on mobile fixed header height */
    padding-bottom: 40px;
  }

  .page-news__hero-container {
    flex-direction: column-reverse; /* Image above text on mobile */
    gap: 20px;
  }

  .page-news__hero-title {
    font-size: 36px;
  }

  .page-news__hero-description {
    font-size: 16px;
  }

  .page-news__cta-button {
    padding: 10px 25px;
    font-size: 16px;
  }

  .page-news__hero-image {
    margin-top: 0;
  }

  .page-news__hero-img,
  .page-news__article-img,
  .page-news__analysis-img,
  .page-news__guide-img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
  }

  .page-news__section,
  .page-news__container,
  .page-news__article-card,
  .page-news__guide-card,
  .page-news__analysis-content,
  .page-news__faq-item,
  .page-news__cta-bottom-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-news__section {
    padding: 40px 0;
  }

  .page-news__section-title {
    font-size: 28px;
    margin-bottom: 15px;
  }

  .page-news__section-description {
    font-size: 15px;
    margin-bottom: 30px;
  }

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

  .page-news__article-img {
    height: 180px;
  }

  .page-news__article-title, .page-news__guide-title {
    font-size: 18px;
  }

  .page-news__article-excerpt, .page-news__guide-excerpt {
    font-size: 15px;
  }

  .page-news__analysis-content {
    padding: 30px 20px;
  }

  .page-news__analysis-subtitle {
    font-size: 22px;
  }

  .page-news__analysis-text {
    font-size: 15px;
  }

  .page-news__faq-question {
    padding: 15px;
    flex-wrap: wrap;
  }

  .page-news__faq-question h3 {
    font-size: 16px;
    margin-bottom: 0;
    width: calc(100% - 40px);
  }

  .page-news__faq-toggle {
    margin-left: 10px;
    width: 24px;
    height: 24px;
    font-size: 20px;
  }

  .page-news__faq-answer {
    padding: 0 15px;
  }

  .page-news__faq-item.active .page-news__faq-answer {
    padding: 15px !important;
  }

  .page-news__cta-bottom-section {
    padding: 60px 15px;
  }

  .page-news__cta-bottom-title {
    font-size: 30px;
  }

  .page-news__cta-bottom-description {
    font-size: 16px;
  }

  .page-news__cta-bottom-button {
    padding: 12px 30px;
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .page-news__hero-title {
    font-size: 32px;
  }

  .page-news__section-title {
    font-size: 24px;
  }

  .page-news__analysis-subtitle {
    font-size: 20px;
  }

  .page-news__article-title, .page-news__guide-title {
    font-size: 17px;
  }

  .page-news__cta-bottom-title {
    font-size: 26px;
  }
  .page-news__article-img {
    height: 160px;
  }
  .page-news__guide-img {
    height: 160px;
  }
}