/* style/nuw88-news.css */

/* Variables and general page settings */
:root {
  --primary-color: #0A192F; /* Deep Navy Blue */
  --secondary-color: #FFD700; /* Gold */
  --text-light: #ffffff;
  --text-dark: #333333;
  --bg-light: #f8f9fa;
  --bg-dark: var(--primary-color);
  --card-bg-light: #ffffff;
  --border-color: #e0e0e0;
}

/* Page specific styles - BEM naming */
.page-nuw88-news {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-light); /* Default text color for dark body background */
  background-color: var(--bg-dark); /* Inherited from shared.css body */
  overflow-x: hidden; /* Prevent horizontal scroll */
}

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

/* Fixed header spacing */
.page-nuw88-news__hero-section {
  padding-top: 120px; /* Desktop: Adjust based on fixed header height */
  position: relative;
  overflow: hidden;
}

.page-nuw88-news__dark-bg {
  background-color: var(--bg-dark);
  color: var(--text-light);
}

.page-nuw88-news__light-bg {
  background-color: var(--bg-light);
  color: var(--text-dark);
}

/* Hero Section */
.page-nuw88-news__hero-section {
  text-align: center;
  padding-bottom: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  position: relative;
}

.page-nuw88-news__hero-title {
  font-size: 3.2em;
  margin-bottom: 20px;
  color: var(--secondary-color); /* Gold title */
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}

.page-nuw88-news__hero-description {
  font-size: 1.2em;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-light);
}

.page-nuw88-news__hero-cta {
  margin-top: 30px;
}

/* Buttons */
.page-nuw88-news__btn-primary,
.page-nuw88-news__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 1.1em;
  font-weight: bold;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.page-nuw88-news__btn-primary {
  background-color: var(--secondary-color); /* Gold */
  color: var(--primary-color); /* Deep Navy Blue text for contrast */
}

.page-nuw88-news__btn-primary:hover {
  background-color: #e6c200; /* Darken gold */
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.page-nuw88-news__btn-secondary {
  background-color: var(--primary-color); /* Deep Navy Blue */
  color: var(--secondary-color); /* Gold text */
  border: 2px solid var(--secondary-color);
}

.page-nuw88-news__btn-secondary:hover {
  background-color: var(--secondary-color); /* Gold background */
  color: var(--primary-color); /* Deep Navy Blue text */
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* Articles Section */
.page-nuw88-news__articles-section {
  padding: 80px 0;
}

.page-nuw88-news__section-title {
  font-size: 2.5em;
  text-align: center;
  margin-bottom: 60px;
  color: var(--primary-color);
  font-weight: bold;
}

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

.page-nuw88-news__article-card {
  background-color: var(--card-bg-light);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}

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

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

.page-nuw88-news__article-image {
  width: 100%;
  height: 200px; /* Fixed height for consistency */
  object-fit: cover;
  display: block;
}

.page-nuw88-news__article-content {
  padding: 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  color: var(--text-dark); /* Dark text on light card background */
}

.page-nuw88-news__article-title {
  font-size: 1.5em;
  margin-top: 0;
  margin-bottom: 10px;
  color: var(--primary-color);
  line-height: 1.3;
}

.page-nuw88-news__article-excerpt {
  font-size: 0.95em;
  margin-bottom: 15px;
  flex-grow: 1;
}

.page-nuw88-news__article-date {
  font-size: 0.85em;
  color: #777;
  text-align: right;
  display: block;
}

.page-nuw88-news__load-more-cta {
  text-align: center;
  margin-top: 50px;
}

/* CTA Section */
.page-nuw88-news__cta-section {
  text-align: center;
  padding: 100px 0;
}

.page-nuw88-news__cta-title {
  font-size: 2.8em;
  margin-bottom: 20px;
  color: var(--secondary-color);
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.4);
}

.page-nuw88-news__cta-description {
  font-size: 1.1em;
  margin-bottom: 40px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-light);
}

/* Responsive design */
@media (max-width: 1024px) {
  .page-nuw88-news__hero-title {
    font-size: 2.8em;
  }
  .page-nuw88-news__section-title,
  .page-nuw88-news__cta-title {
    font-size: 2.2em;
  }
  .page-nuw88-news__article-title {
    font-size: 1.3em;
  }
}

@media (max-width: 768px) {
  .page-nuw88-news__container {
    padding: 0 15px;
  }

  /* Fixed header spacing for mobile */
  .page-nuw88-news__hero-section {
    padding-top: 100px !important; /* Mobile: Adjust based on fixed header height */
    padding-bottom: 60px;
  }

  .page-nuw88-news__hero-title {
    font-size: 2.2em;
  }

  .page-nuw88-news__hero-description {
    font-size: 1em;
  }

  .page-nuw88-news__articles-section {
    padding: 60px 0;
  }

  .page-nuw88-news__section-title,
  .page-nuw88-news__cta-title {
    font-size: 1.8em;
    margin-bottom: 40px;
  }

  .page-nuw88-news__articles-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
  }

  .page-nuw88-news__article-image {
    height: 180px;
  }

  .page-nuw88-news__article-content {
    padding: 20px;
  }

  .page-nuw88-news__article-title {
    font-size: 1.2em;
  }

  .page-nuw88-news__btn-primary,
  .page-nuw88-news__btn-secondary {
    width: 100% !important;
    max-width: 100% !important;
    padding: 12px 20px;
    font-size: 1em;
    white-space: normal !important;
    word-wrap: break-word !important;
    box-sizing: border-box !important;
  }

  .page-nuw88-news__hero-cta,
  .page-nuw88-news__load-more-cta,
  .page-nuw88-news__cta-section .page-nuw88-news__container > a {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    padding: 0 15px; /* Ensure padding on container for full width buttons */
  }

  .page-nuw88-news__cta-section {
    padding: 60px 0;
  }

  /* Image responsive adaptation (mandatory) */
  .page-nuw88-news img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  /* Ensure containers with images are also responsive */
  .page-nuw88-news__section,
  .page-nuw88-news__card,
  .page-nuw88-news__container,
  .page-nuw88-news__hero-section,
  .page-nuw88-news__articles-section,
  .page-nuw88-news__cta-section,
  .page-nuw88-news__articles-grid,
  .page-nuw88-news__article-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    /* Remove padding here to allow children to have padding without overflow */
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  
  /* Re-add padding to the main container for content alignment */
  .page-nuw88-news__container {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

}

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