/* Comment Transparency UI Styles */

/* Score Breakdown Section */
.score-breakdown-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 1px solid #dee2e6;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.score-breakdown-section:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Why This Score Button */
.btn-outline-info.btn-sm {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-width: 1px;
    transition: all 0.2s ease;
}

.btn-outline-info.btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(23, 162, 184, 0.3);
}

/* Score Component Styling */
.score-component, .evidence-component {
    background: white;
    border-radius: 6px;
    padding: 15px;
    border: 1px solid #e9ecef;
    height: 100%;
}

.score-details .d-flex {
    font-size: 0.9rem;
}

.score-details hr {
    border-color: #dee2e6;
    opacity: 0.5;
}

/* Fallacy Item Styling */
.fallacy-item {
    background: #fff5f5;
    border: 1px solid #fed7d7;
    border-left: 4px solid #dc3545;
    transition: all 0.2s ease;
}

.fallacy-item:hover {
    background: #fef2f2;
    border-left-width: 6px;
}

.fallacy-item-compact {
    background: #fff8f8;
    border: 1px solid #ffe6e6;
    border-left: 3px solid #dc3545;
    font-size: 0.8rem;
}

/* Evidence Progress Bars */
.progress {
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    transition: width 1s ease-in-out;
}

/* Reasoning Badges */
.reasoning-badges .badge {
    font-size: 0.8rem;
    margin: 2px;
    padding: 0.3rem 0.6rem;
}

/* No Fallacies Alert */
.no-fallacies-section .alert-success {
    background-color: #d1edff;
    border-color: #bee5eb;
    color: #0c5460;
    padding: 0.75rem;
}

/* Help Section */
.help-section {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 12px;
}

.help-section a {
    text-decoration: none;
    font-weight: 500;
}

.help-section a:hover {
    text-decoration: underline;
}

/* Compact Styling for Nested Comments */
.fallacies-compact .fallacy-item-compact {
    padding: 0.5rem;
    margin-bottom: 0.5rem;
}

.evidence-compact .progress {
    height: 6px;
    margin: 0.5rem 0;
}

.score-summary {
    background: white;
    border-radius: 4px;
    padding: 0.75rem;
    border: 1px solid #e9ecef;
}

/* Animation for Score Breakdown */
.collapse.show {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Icon Styling */
.text-info .fas,
.text-primary .fas,
.text-success .fas,
.text-danger .fas {
    opacity: 0.8;
}

/* Badge Enhancements */
.badge.bg-danger {
    background-color: #dc3545 !important;
    box-shadow: 0 1px 3px rgba(220, 53, 69, 0.3);
}

.badge.bg-info {
    background-color: #0dcaf0 !important;
    box-shadow: 0 1px 3px rgba(13, 202, 240, 0.3);
}

/* Quality Indicator Enhancements */
.quality-indicators .badge {
    transition: all 0.2s ease;
}

.quality-indicators .badge:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Card Title Styling */
.card-title {
    color: #495057;
    font-weight: 600;
}

.card-title .fas {
    color: #17a2b8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .score-component, .evidence-component {
        margin-bottom: 1rem;
    }

    .fallacy-item {
        padding: 0.75rem;
    }

    .btn-outline-info.btn-sm {
        font-size: 0.7rem;
        padding: 0.2rem 0.4rem;
    }

    .score-details .d-flex {
        font-size: 0.85rem;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .score-breakdown-section {
        border-width: 2px;
    }

    .fallacy-item {
        border-width: 2px;
        border-left-width: 6px;
    }

    .badge {
        font-weight: bold;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .btn-outline-info.btn-sm,
    .fallacy-item,
    .quality-indicators .badge {
        transition: none;
    }

    .collapse.show {
        animation: none;
    }

    .progress-bar {
        transition: none;
    }
}

/* Focus Styles for Accessibility */
.btn-outline-info:focus {
    box-shadow: 0 0 0 0.2rem rgba(23, 162, 184, 0.25);
}

/* Print Styles */
@media print {
    .btn-outline-info,
    .collapse {
        display: none !important;
    }

    .score-breakdown-section {
        border: 1px solid #000;
        background: white !important;
    }
}

/* Tooltip Enhancements */
[data-bs-toggle="tooltip"] {
    cursor: help;
}

/* Color Coding for Score Ranges */
.score-excellent {
    color: #28a745;
    font-weight: 600;
}

.score-good {
    color: #17a2b8;
    font-weight: 600;
}

.score-fair {
    color: #ffc107;
    font-weight: 600;
}

.score-poor {
    color: #dc3545;
    font-weight: 600;
}

/* Enhanced Alert Styling */
.alert {
    border-radius: 6px;
    border-width: 1px;
}

.alert-warning {
    background-color: #fff3cd;
    border-color: #ffeaa7;
    color: #856404;
}

.alert-success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

/* Fallacy Type Color Coding */
.badge.fallacy-ad-hominem {
    background-color: #e74c3c !important;
}

.badge.fallacy-strawman {
    background-color: #e67e22 !important;
}

.badge.fallacy-false-dilemma {
    background-color: #f39c12 !important;
}

.badge.fallacy-slippery-slope {
    background-color: #9b59b6 !important;
}

.badge.fallacy-circular-reasoning {
    background-color: #34495e !important;
}

/* Loading States */
.score-loading {
    opacity: 0.6;
    position: relative;
}

.score-loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        90deg,
        transparent,
        transparent 2px,
        rgba(255,255,255,0.5) 2px,
        rgba(255,255,255,0.5) 4px
    );
    animation: loading-shimmer 1.5s infinite;
}

@keyframes loading-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Clickable Fallacy Badge Styles */
.fallacy-badge-clickable {
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.fallacy-badge-clickable:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
    filter: brightness(1.1);
}

.fallacy-badge-clickable:active {
    transform: translateY(0);
}

.fallacy-badge-clickable:focus {
    outline: 2px solid rgba(220, 53, 69, 0.5);
    outline-offset: 2px;
}
