/* Report Component Styles */

/* Text selection styles for the essay grid */
.essay-text-container {
    position: relative;
}

.essay-text-container .sentence {
    position: relative;
    cursor: text;
    transition: all 0.2s ease;
}

.essay-text-container .sentence:hover {
    background-color: rgba(59, 130, 246, 0.1);
    border-radius: 2px;
}

.essay-text-container .sentence.selected {
    background-color: rgba(59, 130, 246, 0.2);
    border-radius: 2px;
}

/* Feedback highlight styles */
.feedback-highlight {
    position: relative;
    border-radius: 2px;
    transition: all 0.2s ease;
}

.feedback-highlight.type-grammar {
    background-color: rgba(239, 68, 68, 0.15);
    border-bottom: 2px wavy #ef4444;
}

.feedback-highlight.type-style {
    background-color: rgba(245, 158, 11, 0.15);
    border-bottom: 2px wavy #f59e0b;
}

.feedback-highlight.type-structure {
    background-color: rgba(59, 130, 246, 0.15);
    border-bottom: 2px wavy #3b82f6;
}

.feedback-highlight.type-content {
    background-color: rgba(16, 185, 129, 0.15);
    border-bottom: 2px wavy #10b981;
}

.feedback-highlight:hover {
    opacity: 0.8;
    transform: translateY(-1px);
}

/* Inline toolbar styles */
.inline-toolbar {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.inline-toolbar button {
    transition: all 0.2s ease;
}

.inline-toolbar button:hover {
    background-color: #f3f4f6;
    transform: scale(1.05);
}

/* Feedback card animations */
.feedback-card {
    transition: all 0.3s ease;
}

.feedback-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Radar chart styles */
.radar-chart-container {
    position: relative;
}

.radar-chart svg {
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

/* Dashboard card styles */
.dashboard-card {
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.dashboard-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-color: #d1d5db;
}

/* Statistics animations */
.stat-number {
    transition: all 0.5s ease;
}

.stat-card:hover .stat-number {
    transform: scale(1.1);
}

/* Progress bar animations */
.progress-bar {
    transition: width 1s ease-in-out;
}

/* Loading animations */
@keyframes pulse-slow {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.pulse-slow {
    animation: pulse-slow 2s infinite;
}

/* Smooth scrolling for report sections */
.report-section {
    scroll-margin-top: 2rem;
}

/* Custom scrollbar for report content */
.report-content::-webkit-scrollbar {
    width: 8px;
}

.report-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

.report-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.report-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Print styles for PDF generation */
@media print {
    .no-print {
        display: none !important;
    }
    
    .print-friendly {
        background: white !important;
        color: black !important;
    }
    
    .page-break {
        page-break-before: always;
    }
    
    .feedback-highlight {
        background-color: rgba(0, 0, 0, 0.1) !important;
        border-bottom: 1px solid #000 !important;
    }
}

/* Mobile responsiveness for report components */
@media (max-width: 768px) {
    .essay-text-container {
        font-size: 14px;
        line-height: 1.6;
    }
    
    .feedback-card {
        margin-bottom: 1rem;
    }
    
    .inline-toolbar {
        position: fixed !important;
        bottom: 1rem;
        left: 1rem;
        right: 1rem;
        top: auto !important;
    }
    
    .radar-chart-container {
        overflow-x: auto;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .feedback-highlight {
        border-width: 3px;
    }
    
    .dashboard-card {
        border-width: 2px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .feedback-card,
    .dashboard-card,
    .sentence,
    .stat-number {
        transition: none;
    }
    
    .pulse-slow {
        animation: none;
    }
}

/* Focus styles for accessibility */
.feedback-highlight:focus,
.sentence:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Selection styles */
::selection {
    background-color: rgba(59, 130, 246, 0.3);
    color: inherit;
}

/* Custom utilities */
.text-shadow {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.glass-effect {
    backdrop-filter: blur(10px);
    background-color: rgba(255, 255, 255, 0.8);
}

.gradient-border {
    background: linear-gradient(white, white) padding-box,
                linear-gradient(45deg, #3b82f6, #8b5cf6) border-box;
    border: 2px solid transparent;
}
