/* Source filtering styles */

/* Source badge styles */
.source-badge {
  position: relative;
  transition: all 0.3s ease;
}

/* Excluded source badge */
.source-badge.excluded {
  opacity: 0.7;
  background-color: rgba(239, 68, 68, 0.2) !important;
  color: #ef4444 !important;
  text-decoration: line-through;
}

/* Exclude button */
.exclude-button {
  position: absolute;
  top: 50%;
  right: 4px;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 1;
  transition: all 0.2s ease;
  z-index: 5;
  letter-spacing: 1px; /* Add letter spacing to give the cross more room */
  padding: 0 0 1px 0; /* Add bottom padding to center the cross vertically */
}

.exclude-button:hover {
  background-color: #ef4444;
  color: white;
  border-color: #ef4444;
}

.source-badge.excluded .exclude-button {
  background-color: var(--primary);
  color: white;
  opacity: 1;
}

.source-badge.excluded .exclude-button:hover {
  background-color: var(--primary-hover);
}

/* Excluded sources filter */
.excluded-sources-filter {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}

.excluded-source {
  background-color: rgba(239, 68, 68, 0.1) !important;
  color: #ef4444 !important;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Tooltip for excluded sources */
.source-badge.excluded::after {
  content: 'Source excluded - click to include';
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--surface);
  color: var(--text);
  padding: 5px 8px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 10;
}

.source-badge.excluded:hover::after {
  opacity: 1;
}

/* Responsive styles */
@media (max-width: 768px) {
  .exclude-button {
    opacity: 1;
    transform: scale(1);
  }
}