/* Latest News Cards Styling */
.latest-news-container {
  margin-top: 0rem;
  margin-bottom: 0rem;
  padding: 0;
  overflow: hidden;        /* clip the scrolling track */
  position: relative;
}

/* Fade edges — disabled, uncomment to re-enable
.latest-news-container::before,
.latest-news-container::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 60px;
  z-index: 2;
  pointer-events: none;
}
.latest-news-container::before {
  left: 0;
  background: linear-gradient(to right, var(--global-bg-color, #fff), transparent);
}
.latest-news-container::after {
  right: 0;
  background: linear-gradient(to left, var(--global-bg-color, #fff), transparent);
}
*/

@keyframes news-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }  /* move exactly one copy-width */
}

.news-scroll-wrapper {
  display: flex;
  gap: 1.5rem;
  padding: 1rem 0;
  margin-bottom: 1rem;
  width: max-content;            /* shrink-wraps all cards */
  animation: news-scroll 25s linear infinite;
}

/* Pause on hover over any card or the wrapper itself */
.latest-news-container:hover .news-scroll-wrapper {
  animation-play-state: paused;
}

.news-card {
  flex: 0 0 320px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.news-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  transform: translateY(-2px);
  border-color: #0066cc;
}

.news-card-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
  overflow: hidden;
  flex-shrink: 0;
}

.news-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-card-content {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.news-card-date {
  font-size: 0.85rem;
  color: #999;
  margin-bottom: 0.5rem;
}

.news-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0.5rem 0;
  color: #333;
  line-height: 1.4;
}

.news-card-excerpt {
  font-size: 0.95rem;
  color: #666;
  margin: 0.75rem 0;
  flex-grow: 1;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-card-link {
  color: #00A6D6;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  margin-top: auto;
  transition: color 0.2s ease;
}

.news-card-link:hover {
  color: #0052a3;
  text-decoration: underline;
}

/* Responsive design */
@media (max-width: 768px) {
  .news-card {
    flex: 0 0 280px;
  }
  
  .news-card-title {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .news-card {
    flex: 0 0 260px;
  }
  
  .news-card-content {
    padding: 1rem;
  }
  
  .news-card-excerpt {
    -webkit-line-clamp: 2;
    font-size: 0.9rem;
  }
}
