/* News Reliability Color System
 *
 * This CSS file contains styles specifically for news content reliability visualization
 * in the news browse page. It extends the general trust score color system with
 * news-specific enhancements.
 */

/* News Article Card Trust Score Styling */
.news-article-card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    position: relative;
}

.news-article-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Trust score card background tints for news cards */
.news-article-card.trust-high {
    background-color: rgba(40, 167, 69, 0.02);
    border-left: 4px solid #28a745;
}

.news-article-card.trust-medium {
    background-color: rgba(255, 193, 7, 0.02);
    border-left: 4px solid #ffc107;
}

.news-article-card.trust-low {
    background-color: rgba(253, 126, 20, 0.02);
    border-left: 4px solid #fd7e14;
}

.news-article-card.trust-very-low {
    background-color: rgba(220, 53, 69, 0.02);
    border-left: 4px solid #dc3545;
}

.news-article-card.trust-unknown {
    background-color: rgba(108, 117, 125, 0.02);
    border-left: 4px solid #6c757d;
}

/* Enhanced trust score badge styling for news */
.trust-score-badge {
    font-size: 0.75em;
    font-weight: 600;
    padding: 0.4em 0.6em;
    border-radius: 0.375rem;
    text-shadow: none;
    min-width: 60px;
    text-align: center;
    color: white !important;
    border: none;
}

.trust-score-badge:hover {
    transform: scale(1.05);
    transition: transform 0.1s ease-in-out;
    cursor: help;
}

/* Color-coded card headers for news */
.news-article-card .card-header {
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.news-article-card.trust-high .card-header {
    border-bottom-color: rgba(40, 167, 69, 0.3);
}

.news-article-card.trust-medium .card-header {
    border-bottom-color: rgba(255, 193, 7, 0.3);
}

.news-article-card.trust-low .card-header {
    border-bottom-color: rgba(253, 126, 20, 0.3);
}

.news-article-card.trust-very-low .card-header {
    border-bottom-color: rgba(220, 53, 69, 0.3);
}

/* Reliability progress bar styling for news cards */
.reliability-progress-wrapper {
    margin-top: 0.5rem;
}

.reliability-progress-wrapper .trust-score-progress-mini {
    height: 6px;
    border-radius: 3px;
    background-color: #e9ecef;
    overflow: hidden;
}

.reliability-progress-wrapper .trust-score-progress-bar {
    height: 100%;
    transition: width 0.3s ease-in-out;
    border-radius: 3px;
}

/* Trust legend styling */
.trust-legend-color {
    width: 16px;
    height: 16px;
    border-radius: 3px;
    margin-right: 6px;
    border: 1px solid rgba(0,0,0,0.1);
    flex-shrink: 0;
}

.trust-legend-item {
    display: flex;
    align-items: center;
    margin-right: 1rem;
    margin-bottom: 0.25rem;
}

.trust-legend-wrapper {
    background-color: #f8f9fa;
    border-radius: 0.375rem;
    padding: 0.75rem;
    margin-bottom: 1rem;
}

/* News article link styling based on trust score */
.news-article-card.trust-high .card-title a:hover {
    color: #155724 !important;
}

.news-article-card.trust-medium .card-title a:hover {
    color: #856404 !important;
}

.news-article-card.trust-low .card-title a:hover {
    color: #8b4513 !important;
}

.news-article-card.trust-very-low .card-title a:hover {
    color: #721c24 !important;
}

/* Responsive design for mobile */
@media (max-width: 768px) {
    .trust-legend-wrapper {
        text-align: center;
    }

    .trust-legend-wrapper .d-flex {
        flex-direction: column;
        align-items: center;
    }

    .trust-legend-item {
        margin-right: 0;
        margin-bottom: 0.5rem;
    }

    .news-article-card {
        margin-bottom: 1rem;
    }
}
