/* Base styles for the Tin Tức page */
.page-tin-tuc {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333333; /* Default dark text for light body background */
  background-color: #FFFFFF; /* Default body background */
}

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

.page-tin-tuc__section-title {
  font-size: 2.5em;
  color: #017439;
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  line-height: 1.2;
}

.page-tin-tuc__section-description {
  font-size: 1.1em;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 40px auto;
  color: #555555;
}

/* Hero Section */
.page-tin-tuc__hero-section {
  position: relative;
  padding-top: 10px; /* Small top padding, relying on body padding-top from shared */
  margin-bottom: 50px;
  text-align: center;
  overflow: hidden;
}

.page-tin-tuc__hero-image {
  width: 100%;
  overflow: hidden;
}

.page-tin-tuc__hero-image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 600px; /* Limit height for hero image */
}

.page-tin-tuc__hero-content {
  padding: 40px 20px;
  background-color: #f8f8f8; /* Slightly off-white background for text */
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.page-tin-tuc__main-title {
  font-size: 3em;
  color: #017439;
  margin-bottom: 15px;
  font-weight: bold;
  line-height: 1.2;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.page-tin-tuc__hero-description {
  font-size: 1.2em;
  color: #555555;
  max-width: 900px;
  margin: 0 auto 30px auto;
}

.page-tin-tuc__hero-cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
}

/* Buttons */
.page-tin-tuc__btn-primary,
.page-tin-tuc__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  box-sizing: border-box;
  max-width: 100%;
  white-space: normal;
  word-wrap: break-word;
}

.page-tin-tuc__btn-primary {
  background-color: #017439;
  color: #FFFFFF; /* High contrast for brand primary */
  border: 2px solid #017439;
}

.page-tin-tuc__btn-primary:hover {
  background-color: #005f2e;
  border-color: #005f2e;
}

.page-tin-tuc__btn-secondary {
  background-color: #FFFFFF;
  color: #017439;
  border: 2px solid #017439;
}

.page-tin-tuc__btn-secondary:hover {
  background-color: #f0f0f0;
  color: #005f2e;
  border-color: #005f2e;
}

/* Custom colors for Register/Login buttons (prioritizing contrast) */
.page-tin-tuc__btn-register,
.page-tin-tuc__btn-login {
  background-color: #C30808;
  color: #FFFFFF; /* Overriding #FFFF00 for WCAG AA contrast (4.6:1) */
  border-color: #C30808;
}

.page-tin-tuc__btn-register:hover,
.page-tin-tuc__btn-login:hover {
  background-color: #a00606;
  border-color: #a00606;
}

/* Latest News Section */
.page-tin-tuc__latest-news-section {
  padding: 60px 0;
  background-color: #fdfdfd;
}

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

.page-tin-tuc__news-card {
  background-color: #FFFFFF;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid #eee;
}

.page-tin-tuc__news-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.page-tin-tuc__news-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.page-tin-tuc__news-card-image {
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.page-tin-tuc__news-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.page-tin-tuc__news-card:hover .page-tin-tuc__news-card-image img {
  transform: scale(1.05);
}

.page-tin-tuc__news-card-content {
  padding: 25px;
}

.page-tin-tuc__news-card-title {
  font-size: 1.5em;
  color: #017439;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-tin-tuc__news-card-meta {
  font-size: 0.9em;
  color: #777777;
  margin-bottom: 15px;
}

.page-tin-tuc__news-card-excerpt {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
}

.page-tin-tuc__view-all-button-container {
  text-align: center;
  margin-top: 50px;
}

/* Full News Archive Section */
.page-tin-tuc__full-news-archive {
  padding: 60px 0;
  background-color: #f2f2f2;
}

.page-tin-tuc__archive-item {
  background-color: #FFFFFF;
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  margin-bottom: 25px;
  transition: box-shadow 0.3s ease;
}

.page-tin-tuc__archive-item:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.page-tin-tuc__archive-item-title {
  font-size: 1.8em;
  margin-bottom: 10px;
  line-height: 1.3;
}

.page-tin-tuc__archive-item-title a {
  color: #017439;
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-tin-tuc__archive-item-title a:hover {
  color: #005f2e;
  text-decoration: underline;
}

.page-tin-tuc__archive-item-meta {
  font-size: 0.9em;
  color: #777777;
  margin-bottom: 15px;
}

.page-tin-tuc__archive-item-excerpt {
  font-size: 1em;
  color: #555555;
  line-height: 1.6;
}

/* CTA Section */
.page-tin-tuc__cta-section {
  padding: 80px 0;
  background-color: #017439; /* Brand primary color as background */
  color: #FFFFFF; /* White text for contrast */
  text-align: center;
}

.page-tin-tuc__cta-section .page-tin-tuc__section-title {
  color: #FFFFFF;
}

.page-tin-tuc__cta-section .page-tin-tuc__section-description {
  color: #f0f0f0;
}

.page-tin-tuc__cta-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-tin-tuc__main-title {
    font-size: 2.5em;
  }
  .page-tin-tuc__section-title {
    font-size: 2em;
  }
  .page-tin-tuc__news-card-content {
    padding: 20px;
  }
  .page-tin-tuc__news-card-title {
    font-size: 1.3em;
  }
  .page-tin-tuc__archive-item-title {
    font-size: 1.5em;
  }
}

@media (max-width: 768px) {
  .page-tin-tuc {
    font-size: 16px;
    line-height: 1.6;
  }
  .page-tin-tuc__container {
    padding: 0 15px;
  }

  /* Hero Section */
  .page-tin-tuc__hero-section {
    margin-bottom: 30px;
  }
  .page-tin-tuc__hero-content {
    padding: 30px 15px;
  }
  .page-tin-tuc__main-title {
    font-size: 2em;
    margin-bottom: 10px;
  }
  .page-tin-tuc__hero-description {
    font-size: 1em;
    margin-bottom: 20px;
  }
  .page-tin-tuc__hero-cta-buttons,
  .page-tin-tuc__cta-buttons {
    flex-direction: column;
    gap: 15px;
    padding: 0 15px; /* Add padding to container */
  }

  /* Buttons - Forced mobile adaptation */
  .page-tin-tuc__btn-primary,
  .page-tin-tuc__btn-secondary,
  .page-tin-tuc a[class*="button"],
  .page-tin-tuc a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    text-align: center;
  }
  .page-tin-tuc__hero-cta-buttons,
  .page-tin-tuc__cta-buttons,
  .page-tin-tuc__button-group,
  .page-tin-tuc__btn-container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
    overflow: hidden !important;
    flex-wrap: wrap !important; /* Ensure multiple buttons wrap */
  }

  /* Section Titles */
  .page-tin-tuc__section-title {
    font-size: 1.8em;
    margin-bottom: 15px;
  }
  .page-tin-tuc__section-description {
    font-size: 1em;
    margin-bottom: 30px;
  }

  /* News Grid */
  .page-tin-tuc__news-grid {
    grid-template-columns: 1fr; /* Single column for news cards */
    gap: 20px;
  }
  .page-tin-tuc__news-card-image {
    height: 180px;
  }
  .page-tin-tuc__news-card-content {
    padding: 15px;
  }
  .page-tin-tuc__news-card-title {
    font-size: 1.2em;
  }

  /* Archive Items */
  .page-tin-tuc__archive-item {
    padding: 20px;
  }
  .page-tin-tuc__archive-item-title {
    font-size: 1.3em;
  }

  /* Images - Forced mobile adaptation */
  .page-tin-tuc img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  .page-tin-tuc__hero-image,
  .page-tin-tuc__news-card-image,
  .page-tin-tuc__section,
  .page-tin-tuc__card,
  .page-tin-tuc__container {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-left: 15px !important;
    padding-right: 15px !important; /* Ensure content padding */
  }
  .page-tin-tuc__latest-news-section,
  .page-tin-tuc__full-news-archive,
  .page-tin-tuc__cta-section {
    padding: 40px 0;
  }

  /* Blog section (if present, general rules for content blocks) */
  .page-tin-tuc__blog-slider-track {
    display: flex;
    flex-wrap: nowrap; /* Keep horizontal scroll for cards if slider */
    overflow-x: auto; /* Allow horizontal scroll for slider */
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
  }
  .page-tin-tuc__blog-slide {
    flex: 0 0 90%; /* Adjust width for mobile slider */
    max-width: 90%;
    scroll-snap-align: start;
  }
}

@media (max-width: 480px) {
  .page-tin-tuc__main-title {
    font-size: 1.8em;
  }
  .page-tin-tuc__section-title {
    font-size: 1.5em;
  }
  .page-tin-tuc__hero-cta-buttons,
  .page-tin-tuc__cta-buttons {
    flex-direction: column;
    gap: 10px;
  }
  .page-tin-tuc__btn-primary,
  .page-tin-tuc__btn-secondary {
    padding: 12px 20px;
    font-size: 1em;
  }
  .page-tin-tuc__news-card-image {
    height: 160px;
  }
  .page-tin-tuc__news-card-title {
    font-size: 1.1em;
  }
  .page-tin-tuc__archive-item-title {
    font-size: 1.2em;
  }
  .page-tin-tuc__blog-slide {
    flex: 0 0 100%; /* Full width for mobile slider */
    max-width: 100%;
  }
}