/* News Carousel - WordPress Enhanced Version */
.news-carousel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

.news-container {
  min-width: 0;
  display: flex;
  gap: 2rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 1rem 0;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-right: 2rem;
  padding-right: 2rem;
}

.news-container::-webkit-scrollbar {
  height: 8px;
}

.news-container::-webkit-scrollbar-track {
  background: var(--dark-gray);
  border-radius: 4px;
}

.news-container::-webkit-scrollbar-thumb {
  background: var(--primary-red);
  border-radius: 4px;
}

.news-item {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 0 0 400px;
  color: var(--dark-gray);
  background-color: var(--white);
  border-left: 4px solid var(--dark-gray-light);
  padding: 1.5rem;
  border-radius: 8px;
  transition: transform 0.3s ease;
  scroll-snap-align: start;
}

.news-item:hover {
  transform: translateY(-5px);
}

.news-item p {
  color: var(--dark-gray);
  margin: 0 0 0.5rem 0;
  font-size: 1.2rem;
}

.news-item h3 {
  color: var(--dark-gray);
  margin: 0 0 0.5rem 0;
  font-size: 1.2rem;
}

.news-item .news-date {
  color: var(--primary-red);
  font-size: 0.9rem;
  font-weight: bold;
  margin: 0 0 1rem 0;
}

.news-header {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.news-item p:last-child {
  margin-bottom: 0;
}

.news-item img {
  width: 150px;
  max-width: 150px;
  height: auto;
  border-radius: 8px;
  margin-bottom: 0rem;
  flex-shrink: 0;
}

.news-item-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* WordPress-specific enhancements */
.news-short.clamp {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 1rem;
}

.news-full {
  margin-bottom: 1rem;
}

.see-more, .see-less {
  color: var(--primary-red);
  text-decoration: none;
  font-weight: bold;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  display: inline-block;
  transition: color 0.3s ease;
}

.see-more:hover, .see-less:hover {
  color: var(--dark-gray);
  text-decoration: underline;
}

.wp-original-link {
  color: var(--dark-gray);
  text-decoration: none;
  font-size: 0.85rem;
  font-style: italic;
  border: 1px solid var(--dark-gray-light);
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  display: inline-block;
  margin-top: 0.5rem;
  transition: all 0.3s ease;
}

.wp-original-link:hover {
  background-color: var(--primary-red);
  color: var(--white);
  border-color: var(--primary-red);
  text-decoration: none;
}

/* News Indicators */
.news-indicators-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 1rem;
}

.news-indicator {
  width: 12px;
  height: 12px;
  margin: 0 6px;
  border-radius: 50%;
  background: #bbb;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
  vertical-align: middle;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.news-indicator.active {
  background: var(--primary-red);
}

.news-indicator:hover {
  background: var(--primary-red);
  box-shadow: 0 0 0 3px rgba(176, 0, 0, 0.2);
}

/* WordPress content styling */
.news-item-content .wp-block-paragraph {
  margin-bottom: 1rem;
}

.news-item-content .wp-block-image {
  margin: 1rem 0;
}

.news-item-content .wp-block-image img {
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

/* Responsive layout for mobile */
@media (max-width: 900px) {
  .news-carousel {
    gap: 1rem;
  }

  .news-item {
    flex: 0 0 250px;
  }
}

/* Hide arrows only on very small screens (smartphones) */
@media (max-width: 480px) {
  .news-carousel {
    flex-direction: column;
    align-items: stretch;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
    gap: 0;
  }
  
  .news-container {
    display: flex;
    overflow-x: auto;
    width: 100%;
    max-width: 100%;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    padding: 0;
    gap: 0;
  }
  
  .news-item {
    width: 100%;
    max-width: 100%;
    flex: 0 0 100%;
    box-sizing: border-box;
    margin: 0;
    scroll-snap-align: start;
  }

  .wp-original-link {
    font-size: 0.8rem;
    padding: 0.25rem 0.5rem;
  }
}
