/**
 * FYP News Feed - Frontend Styles
 * Version: 1.0.0
 */

:root {
  --fyplugins-newsticker-bg-color: #ec8b00;
  --fyplugins-newsticker-text-color: #ffffff;
  --fyplugins-newsticker-link-color: #ffffff;
  --fyplugins-newsticker-height: 50px;
  --fyplugins-newsticker-font-size: 16px;
}

/* Base styles for all news feed templates */
.fyp-news-ticker {
  width: 100%;
  overflow: hidden;
  background-color: var(--fyplugins-newsticker-bg-color);
  position: relative;
  height: var(--fyplugins-newsticker-height);
}

.fyp-news-ticker-wrapper {
  height: 100%;
  position: relative;
  overflow: hidden;
  width: 100%;
}

.fyp-news-ticker-track {
  display: inline-flex;
  align-items: center;
  height: 100%;
  white-space: nowrap;
  will-change: transform;
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
}

.fyp-news-ticker-item {
  display: inline-flex;
  align-items: center;
  padding: 0 20px;
  height: 100%;
  flex-shrink: 0;
}

.fyp-news-ticker-icon,
.fyp-news-ticker-icon-badge {
  margin-right: 10px;
  display: inline-flex;
  align-items: center;
}

.fyp-news-ticker-text {
  color: var(--fyplugins-newsticker-text-color);
  font-size: var(--fyplugins-newsticker-font-size);
  font-weight: 500;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.fyp-news-ticker-text:hover {
  opacity: 0.8;
  text-decoration: underline;
}

a.fyp-news-ticker-text {
  color: var(--fyplugins-newsticker-link-color);
  cursor: pointer;
}

.fyp-news-ticker-separator {
  display: inline-flex;
  align-items: center;
  color: var(--fyplugins-newsticker-text-color);
  opacity: 0.6;
  font-size: 18px;
  flex-shrink: 0;
  padding: 0;
}

/* Animation pause on hover */
.fyp-news-ticker[data-pause="1"]:hover .fyp-news-ticker-track {
  animation-play-state: paused !important;
}

/* Default template specific styles */
.fyp-news-ticker-default .fyp-news-ticker-item {
  gap: 10px;
}

/* Modern template specific styles */
.fyp-news-ticker-modern .fyp-news-ticker-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 25px;
  padding: 8px 20px;
  margin: 0 10px;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.fyp-news-ticker-modern .fyp-news-ticker-card:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.fyp-news-ticker-modern .fyp-news-ticker-separator {
  display: none;
}

/* Minimal template specific styles */
.fyp-news-ticker-minimal {
  background: transparent;
  border-top: 2px solid var(--fyplugins-newsticker-bg-color);
  border-bottom: 2px solid var(--fyplugins-newsticker-bg-color);
}

.fyp-news-ticker-minimal .fyp-news-ticker-text {
  color: var(--fyplugins-newsticker-bg-color);
  font-weight: 400;
  font-size: 14px;
}

.fyp-news-ticker-minimal a.fyp-news-ticker-text {
  color: var(--fyplugins-newsticker-bg-color);
}

.fyp-news-ticker-minimal .fyp-news-ticker-separator {
  color: var(--fyplugins-newsticker-bg-color);
  opacity: 0.3;
}

/* Empty state */
.fyp-news-ticker-empty {
  padding: 15px;
  text-align: center;
  background: #f0f0f0;
  color: #666;
  border: 1px dashed #ccc;
  border-radius: 4px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .fyp-news-ticker {
    height: auto;
    min-height: var(--fyplugins-newsticker-height);
  }

  .fyp-news-ticker-text {
    font-size: 14px;
  }

  .fyp-news-ticker-item {
    padding: 0 15px;
  }

  .fyp-news-ticker-modern .fyp-news-ticker-card {
    padding: 6px 15px;
    margin: 0 8px;
  }
}

@media (max-width: 480px) {
  .fyp-news-ticker-text {
    font-size: 13px;
  }

  .fyp-news-ticker-item {
    padding: 0 15px;
  }

  .fyp-news-ticker-icon svg {
    width: 16px;
    height: 16px;
  }
}
