/* Tag Analysis Specific Styles */

.tag-analysis-container {
    background: var(--radiance-bg-secondary);
    min-height: 100vh;
}

.tag-analysis-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.tag-analysis-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.tag-analysis-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Alert Styles */
.architectural-alert {
    border-left: 4px solid;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
}

.architectural-alert:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.alert-severity-high {
    border-left-color: #dc3545;
    background: linear-gradient(90deg, rgba(220, 53, 69, 0.1) 0%, transparent 100%);
}

.alert-severity-medium {
    border-left-color: #ffc107;
    background: linear-gradient(90deg, rgba(255, 193, 7, 0.1) 0%, transparent 100%);
}

.alert-severity-low {
    border-left-color: #17a2b8;
    background: linear-gradient(90deg, rgba(23, 162, 184, 0.1) 0%, transparent 100%);
}

/* Chart Container Styles */
.chart-container {
    position: relative;
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.chart-container:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.chart-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #dee2e6;
}

.chart-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.chart-body {
    padding: 1.5rem;
}

/* Metric Cards */
.metric-card {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
}

.metric-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.metric-card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 1.5rem;
}

.metric-card-body {
    padding: 1.5rem;
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.metric-label {
    font-size: 0.875rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Tag Trend Items */
.tag-trend-item {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.3s ease;
}

.tag-trend-item:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
}

.tag-trend-up {
    border-left: 4px solid #28a745;
}

.tag-trend-down {
    border-left: 4px solid #dc3545;
}

.tag-trend-new {
    border-left: 4px solid #ffc107;
}

.tag-trend-stable {
    border-left: 4px solid #6c757d;
}

.tag-key {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    background: #f8f9fa;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    color: #495057;
}

/* Repository Details */
.repository-details {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 0.75rem;
    padding: 2rem;
    margin-top: 2rem;
}

.repository-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.875rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Filter Controls */
.filter-controls {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
}

.filter-group {
    margin-bottom: 1rem;
}

.filter-group:last-child {
    margin-bottom: 0;
}

.filter-label {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    display: block;
}

.filter-select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ced4da;
    border-radius: 0.5rem;
    background: white;
    font-size: 0.875rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

/* Progress Bars */
.entropy-progress {
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.entropy-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #28a745 0%, #ffc107 50%, #dc3545 100%);
    transition: width 0.6s ease;
}

/* Loading States */
.loading-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: #6c757d;
}

.loading-spinner .spinner-border {
    width: 3rem;
    height: 3rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .tag-analysis-title {
        font-size: 2rem;
    }
    
    .repository-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .metric-value {
        font-size: 2rem;
    }
    
    .chart-body {
        padding: 1rem;
    }
}

@media (max-width: 576px) {
    .repository-stats {
        grid-template-columns: 1fr;
    }
    
    .filter-controls {
        padding: 1rem;
    }
}

/* Dark Theme Support */
@media (prefers-color-scheme: dark) {
    .tag-analysis-container {
        background: #1a1a1a;
        color: #e9ecef;
    }
    
    .chart-container,
    .metric-card,
    .filter-controls {
        background: #2d3748;
        border-color: #4a5568;
    }
    
    .chart-header {
        background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
        border-bottom-color: #4a5568;
    }
    
    .tag-trend-item {
        background: #2d3748;
        border-color: #4a5568;
    }
    
    .tag-key {
        background: #4a5568;
        color: #e9ecef;
    }
    
    .filter-select {
        background: #2d3748;
        border-color: #4a5568;
        color: #e9ecef;
    }
}
