/* style/news.css */
:root {
  --primary-color: #007bff;
  --secondary-color: #0056b3;
  --accent-color: #ffc107;
  --text-color-light: #ffffff;
  --text-color-dark: #333333;
  --background-dark: #0a0a0a;
  --background-light: #ffffff;
  --card-background-dark: rgba(255, 255, 255, 0.08);
  --card-background-light: #ffffff;
  --border-color: #e0e0e0;
}

.page-news {
  color: var(--text-color-light); /* Body background is dark, so text is light */
  background-color: var(--background-dark);
  padding-bottom: 80px;
}

/* Header spacing for fixed navigation */
.page-news__title-section {
  padding-top: 120px; /* Desktop: Adjust based on fixed header height */
  padding-bottom: 40px;
  background-color: var(--background-dark);
  color: var(--text-color-light);
}

.page-news__title-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  text-align: center;
}

.page-news__main-title {
  font-size: 3.2em;
  font-weight: 700;
  margin-bottom: 20px;
  line-height: 1.3;
  color: var(--text-color-light);
}

.page-news__title-description {
  font-size: 1.1em;
  line-height: 1.8;
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: rgba(255, 255, 255, 0.85);
}

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

.page-news__cta-button {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  border: none;
  cursor: pointer;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow text wrapping */
  max-width: 100%;
  box-sizing: border-box;
}

.page-news__btn-primary {
  background: var(--primary-color);
  color: var(--text-color-light);
}

.page-news__btn-primary:hover {
  background: var(--secondary-color);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.page-news__btn-secondary {
  background: var(--accent-color);
  color: var(--text-color-dark);
}

.page-news__btn-secondary:hover {
  background: #e0a800;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

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

.page-news__faq-container {
  max-width: 1000px;
  margin: 0 auto;
  background: var(--card-background-light); /* Light background for FAQ content */
  color: var(--text-color-dark); /* Dark text for light background */
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-news__faq-title {
  font-size: 2.2em;
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: var(--text-color-dark);
}

.page-news__faq-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.page-news__faq-item {
  margin-bottom: 5px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.page-news__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 25px;
  background: var(--background-light);
  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: #f0f0f0;
}

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

.page-news__faq-toggle {
  font-size: 28px;
  font-weight: bold;
  line-height: 1;
  color: var(--primary-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: 30px;
  height: 30px;
}

.page-news__faq-item.active .page-news__faq-toggle {
  color: var(--secondary-color);
  transform: rotate(45deg); /* Optional: Rotate for 'x' effect */
}

.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;
  background: #fdfdfd;
  color: var(--text-color-dark);
}

.page-news__faq-item.active .page-news__faq-answer {
  max-height: 2000px !important; /* Sufficiently large to contain any content */
  padding: 20px 25px !important;
  opacity: 1;
  border-top: 1px solid var(--border-color);
}

.page-news__faq-answer p {
  margin-bottom: 0;
  line-height: 1.7;
  color: var(--text-color-dark);
}

/* Brand Section */
.page-news__brand-section {
  padding: 60px 20px;
  background-color: var(--card-background-dark); /* Slightly lighter dark background */
  color: var(--text-color-light);
}

.page-news__brand-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.page-news__brand-title {
  font-size: 2.5em;
  font-weight: 700;
  margin-bottom: 50px;
  color: var(--text-color-light);
}

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

.page-news__brand-item {
  background: rgba(255, 255, 255, 0.05); /* Very subtle background for items */
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: left;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.page-news__brand-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.page-news__brand-image {
  width: 100%;
  max-width: 400px; /* Max width for images within brand items */
  height: auto;
  border-radius: 8px;
  margin-bottom: 20px;
  object-fit: cover;
  align-self: center;
}

.page-news__brand-item h3 {
  font-size: 1.5em;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--accent-color);
}

.page-news__brand-item p {
  font-size: 1em;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.75);
  flex-grow: 1;
}

/* Blog Section */
.page-news__blog-section {
  padding: 60px 20px;
  background-color: var(--background-dark);
}

.page-news__blog-container {
  max-width: 1200px;
  margin: 0 auto;
  background: var(--card-background-light); /* Light background for blog content */
  color: var(--text-color-dark); /* Dark text for light background */
  border-radius: 12px;
  padding: 40px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-news__blog-title {
  font-size: 2.2em;
  font-weight: 700;
  text-align: center;
  margin-bottom: 20px;
  color: var(--text-color-dark);
}

.page-news__blog-intro-text, .page-news__blog-outro-text {
  font-size: 1.05em;
  line-height: 1.7;
  text-align: center;
  margin-bottom: 40px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-color-dark);
}

.page-news__blog-outro-text {
  margin-top: 40px;
  margin-bottom: 0;
}

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

.page-news__blog-item {
  background: var(--background-light);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.page-news__blog-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

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

.page-news__blog-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 1px solid var(--border-color);
}

.page-news__blog-item-title {
  font-size: 1.3em;
  font-weight: 600;
  margin: 20px 20px 10px;
  line-height: 1.4;
  color: var(--primary-color);
}

.page-news__blog-item-excerpt {
  font-size: 0.95em;
  line-height: 1.6;
  margin: 0 20px 15px;
  color: var(--text-color-dark);
  flex-grow: 1;
}

.page-news__blog-item-date {
  font-size: 0.85em;
  color: #6c757d;
  margin: 0 20px 20px;
  display: block;
  text-align: right;
}

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

  .page-news__faq-title,
  .page-news__brand-title,
  .page-news__blog-title {
    font-size: 2em;
  }
}

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

  .page-news__title-section {
    padding-top: 100px !important; /* Mobile: Adjust based on mobile fixed header height */
    padding-bottom: 30px;
  }

  .page-news__title-container,
  .page-news__faq-container,
  .page-news__brand-container,
  .page-news__blog-container {
    padding: 25px 15px;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .page-news__main-title {
    font-size: 2.2em;
    margin-bottom: 15px;
  }

  .page-news__title-description {
    font-size: 1em;
    margin-bottom: 30px;
  }

  .page-news__cta-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .page-news__cta-button {
    width: 100% !important;
    padding: 12px 25px !important;
    font-size: 1em !important;
    box-sizing: border-box !important;
  }

  .page-news__faq-section,
  .page-news__brand-section,
  .page-news__blog-section {
    padding: 40px 15px;
  }

  .page-news__faq-title,
  .page-news__brand-title,
  .page-news__blog-title {
    font-size: 1.8em;
    margin-bottom: 30px;
  }

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

  .page-news__faq-question h3 {
    font-size: 1em;
  }

  .page-news__faq-toggle {
    font-size: 24px;
    width: 24px;
    height: 24px;
  }

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

  .page-news__brand-content,
  .page-news__blog-list {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .page-news__brand-item {
    padding: 25px;
  }

  .page-news__brand-item h3 {
    font-size: 1.3em;
  }

  .page-news__blog-item-title {
    font-size: 1.2em;
    margin: 15px 15px 8px;
  }

  .page-news__blog-item-excerpt,
  .page-news__blog-item-date {
    margin: 0 15px 15px;
  }

  /* Ensure all images are responsive */
  .page-news img {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    box-sizing: border-box !important;
  }

  .page-news__blog-image {
    height: 180px;
  }

  .page-news__blog-intro-text, .page-news__blog-outro-text {
    font-size: 0.95em;
    margin-bottom: 25px;
  }
}

@media (max-width: 480px) {
  .page-news__main-title {
    font-size: 1.8em;
  }

  .page-news__faq-title,
  .page-news__brand-title,
  .page-news__blog-title {
    font-size: 1.5em;
  }

  .page-news__cta-button {
    font-size: 0.9em !important;
    padding: 10px 20px !important;
  }

  .page-news__faq-question h3 {
    font-size: 0.95em;
  }
  .page-news__brand-item h3 {
    font-size: 1.1em;
  }
}