.performance-section {
    padding: 30px;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 50%, #f8f9fa 100%);
    border-radius: 20px;
}

.performance-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f0f4ff 100%);
    border: 1px solid #e0e7ff;
    padding: 40px;
    border-radius: 16px;
    margin-bottom: 40px;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.08);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.performance-header:hover {
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.12);
}

.performance-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.05) 0%, transparent 70%);
    border-radius: 50%;
}

.performance-header::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.03) 0%, transparent 70%);
    border-radius: 50%;
}

.performance-score-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    position: relative;
    z-index: 1;
}

.performance-score-circle {
    position: relative;
    width: 180px;
    height: 180px;
}

.performance-score-text {
    flex: 1;
    min-width: 300px;
    color: #1a365d;
}

.performance-score-badge {
    margin-bottom: 15px;
}

.score-grade {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 0.95em;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: white;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.performance-main-score {
    margin: 10px 0;
    font-size: 4em;
    font-weight: 800;
    line-height: 1;
    text-shadow: none;
    letter-spacing: -2px;
    color: #1a365d;
}

.score-divider {
    font-size: 0.6em;
    opacity: 0.6;
    margin: 0 5px;
    color: #475569;
}

.score-max {
    font-size: 0.5em;
    opacity: 0.7;
    color: #475569;
}

.performance-score-label {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    font-weight: 600;
    opacity: 0.85;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #475569;
}

.performance-message {
    margin: 15px 0 0 0;
    font-size: 1em;
    opacity: 0.8;
    line-height: 1.6;
    max-width: 600px;
    color: #2d3748;
}

.performance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.performance-card {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid #f0f0f0;
    position: relative;
    overflow: hidden;
}

.performance-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.performance-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.2);
    border-color: #667eea;
}

.performance-card:hover::before {
    transform: scaleX(1);
}

.performance-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.performance-card-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.performance-card-title h3 {
    margin: 0;
    font-size: 1.3em;
    color: #2c3e50;
}

.performance-icon {
    font-size: 1.8em;
}

.performance-badge {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-excellent {
    background: #d4edda;
    color: #155724;
}

.badge-good {
    background: #d1ecf1;
    color: #0c5460;
}

.badge-fair {
    background: #fff3cd;
    color: #856404;
}

.badge-poor {
    background: #f8d7da;
    color: #721c24;
}

.metric-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f5f5f5;
}

.metric-row:last-child {
    border-bottom: none;
}

.metric-label {
    color: #666;
    font-size: 0.95em;
}

.metric-value {
    font-weight: 600;
    font-size: 1.1em;
    color: #2c3e50;
}

.metric-value.success {
    color: #28a745;
}

.metric-value.warning {
    color: #ffc107;
}

.metric-value.danger {
    color: #dc3545;
}

/* Size Display Styles */
.size-primary-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 16px;
    background: #f5f7fa;
    border: 1px solid #d0d8e0;
    border-radius: 8px;
    margin-bottom: 16px;
}

.size-primary-highlight {
    flex: 1;
}

.size-primary-label {
    font-size: 0.8em;
    font-weight: 600;
    color: #4a5568;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.size-primary-value {
    font-size: 1.8em;
    font-weight: 700;
    color: #1a202c;
    line-height: 1;
    margin-bottom: 4px;
}

.size-primary-description {
    font-size: 0.85em;
    color: #718096;
    font-weight: 500;
}

.size-info-button {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #e2e8f0;
    border: 1px solid #cbd5e0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, border-color 0.2s ease;
    flex-shrink: 0;
    font-size: 16px;
}

.size-info-button:hover {
    background: #cbd5e0;
    border-color: #a0aec0;
}

.size-info-button.active {
    background: #e6efff;
    border-color: #4a90e2;
}

.size-explanation-panel {
    padding: 16px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 16px;
    border-left: 3px solid #4a90e2;
}

.explanation-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.explanation-item {
    padding: 12px;
    background: white;
    border-radius: 6px;
    border-left: 3px solid #cbd5e0;
}

.explanation-item.savings {
    border-left-color: #48bb78;
}

.explanation-title {
    font-weight: 600;
    color: #1a202c;
    font-size: 0.9em;
    margin-bottom: 4px;
}

.explanation-text {
    color: #4a5568;
    font-size: 0.85em;
    line-height: 1.5;
    margin: 0;
}

.size-comparison-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 16px;
    padding: 16px;
    background: #f5f7fa;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.size-comparison-item {
    flex: 1;
    text-align: center;
    padding: 0;
}

.size-comparison-item.highlight {
    background: #f0f4ff;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #d0d8ff;
}

.comparison-label {
    display: block;
    font-size: 0.8em;
    color: #718096;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 6px;
}

.comparison-value {
    display: block;
    font-size: 1.5em;
    font-weight: 700;
    color: #1a202c;
}

.size-comparison-item.highlight .comparison-value {
    color: #4a90e2;
}

.size-comparison-divider {
    width: 1px;
    height: 50px;
    background: #cbd5e0;
}

.size-breakdown-chart {
    margin: 20px 0;
}

.size-bar {
    display: flex;
    height: 40px;
    border-radius: 8px;
    overflow: hidden;
    margin: 15px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.size-segment {
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.85em;
    transition: all 0.3s;
    cursor: pointer;
}

.size-segment:hover {
    opacity: 0.8;
    transform: scaleY(1.05);
}

.segment-html {
    background: #e74c3c;
}

.segment-css {
    background: #3498db;
}

.segment-js {
    background: #f39c12;
}

.segment-images {
    background: #9b59b6;
}

.segment-fonts {
    background: #1abc9c;
}

.segment-other {
    background: #95a5a6;
}

.size-legend {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.legend-text {
    font-size: 0.9em;
    color: #666;
}

.legend-value {
    font-weight: 600;
    color: #2c3e50;
    margin-left: auto;
}

.compression-gauge {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 20px auto;
}

.gauge-background {
    fill: none;
    stroke: #e0e0e0;
    stroke-width: 20;
}

.gauge-progress {
    fill: none;
    stroke-width: 20;
    stroke-linecap: round;
    transition: stroke-dasharray 1s ease-in-out;
}

.gauge-text {
    text-align: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.gauge-percentage {
    font-size: 2.5em;
    font-weight: 700;
    color: #2c3e50;
}

.gauge-label {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
}

.compression-breakdown {
    margin-top: 20px;
}

.compression-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}

.compression-bar-container {
    flex: 1;
    margin: 0 15px;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
}

.compression-bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease-in-out;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.resource-count-card {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    transition: transform 0.3s;
}

.resource-count-card:hover {
    transform: scale(1.05);
}

.resource-count {
    font-size: 2.5em;
    font-weight: 700;
    margin: 10px 0;
}

.resource-label {
    font-size: 0.85em;
    opacity: 0.9;
}

.perf-deprecated-checklist {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.perf-deprecated-item-wrapper {
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
}

.perf-deprecated-item-clickable {
    display: flex;
    align-items: center;
    padding: 15px 18px;
    cursor: pointer;
    transition: all 0.3s ease;
    gap: 12px;
}

.perf-deprecated-item-clickable:hover {
    background: linear-gradient(145deg, #f8f9fa 0%, #f0f0f0 100%);
    transform: translateX(3px);
}

.perf-deprecated-item-clickable.perf-deprecated-expanded {
    background: linear-gradient(145deg, #f0f4ff 0%, #f8f9fa 100%);
}

.perf-deprecated-label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.95em;
}

.perf-deprecated-count {
    font-size: 0.85em;
    color: #666;
    margin-top: 3px;
}

.perf-deprecated-expand-icon {
    margin-left: auto;
    color: #667eea;
    font-size: 0.9em;
    transition: transform 0.3s ease;
}

.perf-deprecated-expand-icon i {
    display: inline-block;
    transition: transform 0.3s ease;
}

.perf-deprecated-explanation-pane {
    padding: 15px 18px;
    background: linear-gradient(135deg, #f0f4ff 0%, #f8fafc 100%);
    border-top: 1px solid #e0e7ff;
    border-left: 4px solid #667eea;
    animation: slideDown 0.3s ease forwards;
    display: none;
}

.perf-deprecated-reason {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 8px;
}

.perf-deprecated-details {
    color: #555;
    font-size: 0.9em;
    line-height: 1.6;
    margin-top: 10px;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.perf-inline-status-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 15px;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 10px;
    border: 1px solid #e0e0e0;
    margin-bottom: 12px;
    gap: 15px;
}

.perf-inline-status-content {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.perf-inline-status-icon {
    font-size: 1.6em;
    min-width: 40px;
    text-align: center;
    animation: pulse 2s ease-in-out infinite;
}

.perf-inline-status-icon.high {
    color: #dc3545;
}

.perf-inline-status-icon.medium {
    color: #ffc107;
}

.perf-inline-status-icon.low {
    color: #28a745;
}

.perf-inline-status-text {
    flex: 1;
}

.perf-inline-status-label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.9em;
    margin-bottom: 3px;
}

.perf-inline-status-message {
    color: #666;
    font-size: 0.8em;
    line-height: 1.4;
}

.perf-inline-toggle-btn {
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85em;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.perf-inline-toggle-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.25);
}

.perf-inline-toggle-btn:active {
    transform: translateY(0);
}

.perf-inline-styles-container {
    border-top: 1px solid #e0e7ff;
    padding-top: 10px;
    animation: slideDown 0.3s ease forwards;
}

.perf-inline-styles-list {
    max-height: 300px;
    overflow-y: auto;
    padding-right: 6px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.perf-inline-styles-list::-webkit-scrollbar {
    width: 6px;
}

.perf-inline-styles-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.perf-inline-styles-list::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 3px;
}

.perf-inline-styles-list::-webkit-scrollbar-thumb:hover {
    background: #764ba2;
}

.perf-inline-style-item {
    padding: 10px;
    background: linear-gradient(145deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 6px;
    border-left: 3px solid #667eea;
    transition: all 0.2s ease;
}

.perf-inline-style-item:hover {
    background: linear-gradient(145deg, #f0f4ff 0%, #f8f9fa 100%);
    transform: translateX(3px);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.08);
}

.perf-inline-style-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
    font-size: 0.8em;
}

.perf-inline-style-tag {
    font-weight: 600;
    color: #2c3e50;
    font-family: 'Courier New', monospace;
}

.perf-inline-style-num {
    color: #999;
    font-size: 0.75em;
}

.perf-inline-style-code {
    font-family: 'Courier New', monospace;
    font-size: 0.75em;
    color: #2c3e50;
    background: #ffffff;
    padding: 6px;
    border-radius: 4px;
    word-break: break-all;
    line-height: 1.3;
    border: 1px solid #e0e0e0;
}

.perf-inline-note {
    margin-top: 10px;
    padding: 8px 10px;
    background: #fff3cd;
    border-radius: 5px;
    color: #856404;
    font-size: 0.8em;
    text-align: center;
    border-left: 3px solid #ffc107;
}

.optimization-checks {
    margin-top: 20px;
}

.check-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 18px 20px;
    margin: 12px 0;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 12px;
    border-left: 5px solid transparent;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.check-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.check-item.pass {
    border-left-color: #28a745;
    background: linear-gradient(145deg, #f0fff4 0%, #e8f5e9 100%);
}

.check-item.pass:hover {
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.15);
}

.check-item.warning {
    border-left-color: #ffc107;
    background: linear-gradient(145deg, #fffbf0 0%, #fff9e6 100%);
}

.check-item.warning:hover {
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.15);
}

.check-item.fail {
    border-left-color: #dc3545;
    background: linear-gradient(145deg, #fff5f5 0%, #ffe6e6 100%);
}

.check-item.fail:hover {
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.15);
}

.check-icon {
    font-size: 1.5em;
    min-width: 30px;
}

.check-icon.pass {
    color: #28a745;
}

.check-icon.warning {
    color: #ffc107;
}

.check-icon.fail {
    color: #dc3545;
}

.check-content {
    flex: 1;
}

.check-title {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.check-description {
    color: #666;
    font-size: 0.9em;
    line-height: 1.5;
}

.check-recommendation {
    margin-top: 10px;
    padding: 12px;
    background: white;
    border-radius: 6px;
    font-size: 0.9em;
    color: #555;
    line-height: 1.6;
    white-space: pre-line;
}

/* Speedometer Container */
.speedometer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 35px;
    margin: 30px 0;
    padding: 30px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 50%, #f0f7ff 100%);
    border-radius: 20px;
    box-shadow: inset 0 2px 10px rgba(102, 126, 234, 0.05);
}

.speedometer-gauge {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 25px 20px;
    background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.speedometer-gauge::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.speedometer-gauge:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 15px 30px rgba(102, 126, 234, 0.25);
    border-color: #667eea;
}

.speedometer-gauge:hover::before {
    transform: scaleX(1);
}

.speedometer-icon {
    font-size: 2.5em;
    margin-bottom: 10px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.speedometer-chart {
    position: relative;
    width: 160px;
    height: 120px;
    margin: 15px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.speedometer-value {
    margin-top: 5px;
    text-align: center;
    width: 100%;
    z-index: 10;
}

.speedometer-number {
    font-size: 1.5em;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1;
}

.speedometer-status {
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

.speedometer-label {
    font-size: 1em;
    font-weight: 600;
    color: #2c3e50;
    text-align: center;
    margin-top: 10px;
    margin-bottom: 5px;
}

.speedometer-threshold {
    font-size: 0.75em;
    color: #6c757d;
    text-align: center;
    padding: 4px 12px;
    background: #f8f9fa;
    border-radius: 12px;
    margin-top: 5px;
}

.timing-breakdown {
    margin: 20px 0;
}

.timing-item {
    margin: 15px 0;
}

.timing-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.timing-label {
    font-weight: 600;
    color: #2c3e50;
}

.timing-value {
    color: #667eea;
    font-weight: 600;
}

.timing-bar {
    height: 24px;
    background: #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.timing-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    transition: width 0.5s ease-in-out;
    display: flex;
    align-items: center;
    padding: 0 10px;
    color: white;
    font-size: 0.85em;
    font-weight: 600;
}

.protocol-badges {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.protocol-badge {
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9em;
}

.protocol-badge.active {
    background: #28a745;
    color: white;
}

.protocol-badge.inactive {
    background: #e0e0e0;
    color: #666;
}

.inline-styles-list {
    max-height: 300px;
    overflow-y: auto;
    margin-top: 15px;
}

.inline-style-item {
    padding: 10px;
    margin: 8px 0;
    background: #f8f9fa;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 0.85em;
}

.inline-style-header {
    display: flex;
    justify-content: space-between;
    color: #666;
    margin-bottom: 5px;
}

.inline-style-code {
    color: #2c3e50;
    word-break: break-all;
}

.perf-expandable-card .perf-card-clickable {
    cursor: pointer;
    transition: background 0.2s ease;
}

.perf-expandable-card .perf-card-clickable:hover {
    background: linear-gradient(145deg, #f8f9fa 0%, #f0f4ff 100%);
}

.perf-card-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.perf-card-info-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.perf-card-hint {
    font-size: 0.75em;
    color: #667eea;
    font-weight: 500;
    opacity: 1;
    transition: opacity 0.5s ease;
    white-space: nowrap;
    animation: perfHintPulse 2s ease-in-out infinite;
}

.perf-card-hint.perf-hint-fade {
    opacity: 0;
    pointer-events: none;
}

@keyframes perfHintPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.perf-card-info-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 0.9em;
    font-weight: bold;
    transition: all 0.3s ease;
    cursor: pointer;
}

.perf-card-info-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.perf-card-info-icon.perf-info-active {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    transform: scale(1.1);
}

.perf-card-info-icon span {
    font-style: normal;
    line-height: 1;
}

.perf-card-explanation-panel {
    padding: 20px;
    background: linear-gradient(135deg, #f0f4ff 0%, #f8fafc 100%);
    border-top: 1px solid #e0e7ff;
    border-bottom: 1px solid #e0e7ff;
    margin: 0 -30px;
    padding: 20px 30px;
    animation: perfSlideDown 0.3s ease forwards;
}

@keyframes perfSlideDown {
    from {
        opacity: 0;
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
    }
    to {
        opacity: 1;
        max-height: 500px;
        padding-top: 20px;
        padding-bottom: 20px;
    }
}

.perf-explanation-header {
    margin-bottom: 12px;
}

.perf-explanation-importance {
    display: inline-block;
    padding: 6px 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.perf-explanation-desc {
    color: #2c3e50;
    font-size: 0.95em;
    line-height: 1.7;
    margin: 0 0 15px 0;
}

.perf-explanation-impact {
    padding: 12px 15px;
    background: linear-gradient(145deg, #fff3cd 0%, #fffbf0 100%);
    border-left: 4px solid #ffc107;
    border-radius: 0 8px 8px 0;
    margin-bottom: 15px;
    font-size: 0.9em;
    color: #856404;
    line-height: 1.6;
}

.perf-explanation-metrics {
    padding: 12px 15px;
    background: linear-gradient(145deg, #d1ecf1 0%, #e8f4f8 100%);
    border-left: 4px solid #17a2b8;
    border-radius: 0 8px 8px 0;
    font-size: 0.9em;
    color: #0c5460;
}

.perf-explanation-metrics ul {
    margin: 10px 0 0 0;
    padding-left: 20px;
}

.perf-explanation-metrics li {
    margin: 8px 0;
    line-height: 1.5;
}

.perf-explanation-metrics li::marker {
    color: #17a2b8;
}

.status-message {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95em;
    line-height: 1.5;
}

.status-message.success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.status-message.warning {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
}

.status-message.error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.status-message.info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.status-icon {
    font-size: 1.2em;
    font-weight: bold;
}

.recommendation-box {
    padding: 15px;
    background: #e7f3ff;
    border-left: 4px solid #2196F3;
    border-radius: 4px;
    margin-top: 15px;
}

.expandable-section {
    margin-top: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.expand-toggle {
    width: 100%;
    padding: 12px 15px;
    background: #f8f9fa;
    border: none;
    text-align: left;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background 0.2s;
}

.expand-toggle:hover {
    background: #e9ecef;
}

.expand-toggle span {
    transition: transform 0.2s;
    display: inline-block;
}

.expand-toggle.expanded span {
    transform: rotate(90deg);
}

.expandable-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    background: white;
}

.expandable-content.expanded {
    max-height: 2000px;
    padding: 15px;
    border-top: 1px solid #e0e0e0;
}

.resource-item {
    padding: 10px;
    margin-bottom: 10px;
    background: #f8f9fa;
    border-radius: 4px;
    border-left: 3px solid #6c757d;
}

.resource-url {
    font-size: 0.85em;
    word-break: break-all;
    margin-bottom: 5px;
    color: #495057;
}

.resource-details {
    font-size: 0.8em;
    color: #6c757d;
}

.minification-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}

.minification-table th {
    background: #f8f9fa;
    padding: 10px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #dee2e6;
}

.minification-table td {
    padding: 10px;
    border-bottom: 1px solid #e9ecef;
}

.minification-table .file-url {
    word-break: break-all;
    max-width: 400px;
    font-size: 0.85em;
}

.error-item {
    padding: 12px;
    margin-bottom: 10px;
    background: #fff5f5;
    border-left: 3px solid #dc3545;
    border-radius: 4px;
}

.error-number {
    font-weight: bold;
    color: #dc3545;
    margin-bottom: 5px;
}

.error-message {
    font-family: monospace;
    font-size: 0.85em;
    color: #495057;
    margin-bottom: 5px;
}

.error-type {
    font-size: 0.8em;
    color: #6c757d;
}

.amp-checklist {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 10px;
    margin-top: 15px;
}

.amp-check-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    border-radius: 6px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
}

.amp-check-item.pass {
    background: #d4edda;
    border-color: #c3e6cb;
}

.amp-check-item.fail {
    background: #f8d7da;
    border-color: #f5c6cb;
}

.amp-check-item.info {
    background: #d1ecf1;
    border-color: #bee5eb;
}

.amp-check-icon {
    font-size: 1.1em;
    font-weight: bold;
}

.amp-check-item.pass .amp-check-icon {
    color: #28a745;
}

.amp-check-item.fail .amp-check-icon {
    color: #dc3545;
}

.amp-check-item.info .amp-check-icon {
    color: #17a2b8;
}

.amp-check-label {
    font-size: 0.9em;
    font-weight: 500;
}

.badge-neutral {
    background: #6c757d !important;
}

.compact-card {
    margin-bottom: 15px !important;
}

.compact-card .performance-card-header {
    padding: 12px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.compact-card .performance-card-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.compact-card .performance-card-title h3 {
    font-size: 1em;
    margin: 0;
}

.performance-icon-sm {
    font-size: 1.2em;
}

.performance-badge-sm {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: 600;
}

.performance-card-content-compact {
    padding: 10px 15px;
}

.compact-status {
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.9em;
    margin-bottom: 8px;
}

.compact-status.success {
    background: #d4edda;
    color: #155724;
}

.compact-status.warning {
    background: #fff3cd;
    color: #856404;
}

.compact-status.error {
    background: #f8d7da;
    color: #721c24;
}

.compact-status.info {
    background: #d1ecf1;
    color: #0c5460;
}

.compact-metrics {
    display: flex;
    gap: 15px;
    font-size: 0.85em;
    color: #666;
    margin-bottom: 8px;
}

.compact-toggle {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85em;
    cursor: pointer;
    width: 100%;
    text-align: left;
    margin-top: 8px;
    transition: all 0.2s;
}

.compact-toggle:hover {
    background: #e9ecef;
}

.compact-toggle.open {
    background: #e9ecef;
    border-color: #adb5bd;
}

.compact-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    margin-top: 8px;
}

.compact-details.show {
    max-height: 500px;
    overflow-y: auto;
}

.detail-line {
    padding: 6px 10px;
    background: #f8f9fa;
    border-left: 3px solid #6c757d;
    margin-bottom: 5px;
    font-size: 0.85em;
    word-break: break-all;
}

.error-line {
    border-left-color: #dc3545;
    background: #fff5f5;
}

.compact-table {
    width: 100%;
    font-size: 0.8em;
    border-collapse: collapse;
}

.compact-table td {
    padding: 5px 8px;
    border-bottom: 1px solid #e9ecef;
}

.compact-table .save-size {
    color: #28a745;
    font-weight: 600;
}

.amp-compact-checks {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
    font-size: 0.85em;
}

.amp-mini-check {
    padding: 5px 8px;
    border-radius: 4px;
    background: #f8f9fa;
}

.amp-mini-check.pass {
    background: #d4edda;
    color: #155724;
}

.amp-mini-check.fail {
    background: #f8d7da;
    color: #721c24;
}

.amp-mini-check.info {
    background: #d1ecf1;
    color: #0c5460;
}

.compact-card .performance-card-header {
    cursor: pointer;
    transition: background 0.2s;
}

.compact-card .performance-card-header:hover {
    background: #f8f9fa;
}

.compact-expanded {
    border-color: #17a2b8 !important;
}

.compact-explanation-panel {
    padding: 15px;
    background: linear-gradient(135deg, #f8fafc 0%, #e7f3ff 100%);
    border-top: 1px solid #e0e7ff;
    border-bottom: 1px solid #e0e7ff;
    margin: 0;
    font-size: 0.9em;
}

.compact-explanation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.compact-explanation-header strong {
    color: #2c3e50;
    font-size: 1.05em;
}

.compact-explanation-importance {
    background: #17a2b8;
    color: white;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
}

.compact-explanation-desc {
    color: #495057;
    line-height: 1.5;
    margin: 10px 0;
}

.compact-explanation-impact {
    background: #fff3cd;
    border-left: 3px solid #ffc107;
    padding: 8px 12px;
    margin: 10px 0;
    border-radius: 4px;
    color: #856404;
    font-size: 0.9em;
}

.compact-explanation-metrics {
    margin-top: 10px;
}

.compact-explanation-metrics strong {
    color: #2c3e50;
    display: block;
    margin-bottom: 5px;
}

.compact-explanation-metrics ul {
    margin: 0;
    padding-left: 20px;
}

.compact-explanation-metrics li {
    color: #495057;
    margin-bottom: 4px;
    line-height: 1.4;
}

.resources-total-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    margin-bottom: 15px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

.resources-total-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.resources-total-icon {
    font-size: 2.5em;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.resources-total-info {
    flex: 1;
}

.resources-total-number {
    font-size: 2.2em;
    font-weight: 800;
    color: white;
    line-height: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.resources-total-label {
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 5px;
}

.resources-compact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.resource-compact-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid #6c757d;
    transition: all 0.2s;
}

.resource-compact-item:hover {
    background: #e9ecef;
    transform: translateY(-1px);
}

.resource-compact-icon {
    font-size: 1.3em;
    line-height: 1;
}

.resource-compact-info {
    flex: 1;
    min-width: 0;
}

.resource-compact-count {
    font-size: 1.1em;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1;
}

.resource-compact-label {
    font-size: 0.75em;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
}

.resources-compact-summary {
    display: flex;
    justify-content: space-around;
    padding: 10px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 6px;
    margin-bottom: 10px;
}

.summary-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
}

.summary-label {
    font-size: 0.75em;
    color: #6c757d;
    text-transform: uppercase;
    font-weight: 600;
}

.summary-value {
    font-size: 1.1em;
    font-weight: 700;
    color: #2c3e50;
}

.summary-value.success {
    color: #28a745;
}

.summary-value.warning {
    color: #ffc107;
}

.summary-value.failed {
    color: #dc3545;
}

.protocol-compact-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.protocol-compact-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border-radius: 6px;
    background: #f8f9fa;
    border-left: 3px solid #6c757d;
}

.protocol-compact-item.active {
    background: #d4edda;
    border-left-color: #28a745;
}

.protocol-compact-item.inactive {
    opacity: 0.6;
}

.protocol-label {
    font-size: 0.9em;
    font-weight: 600;
    color: #495057;
}

.protocol-count {
    font-size: 1em;
    font-weight: 700;
    color: #2c3e50;
}

.protocol-compact-item.active .protocol-count {
    color: #28a745;
}

@media (max-width: 768px) {
    .performance-grid {
        grid-template-columns: 1fr;
    }
    
    .performance-score-container {
        flex-direction: column;
        text-align: center;
    }
    
    .resources-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .resources-compact-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .speedometer-container {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 15px;
    }
    
    .speedometer-gauge {
        padding: 15px;
    }
    
    .speedometer-icon {
        font-size: 2em;
    }
    
    .speedometer-number {
        font-size: 1.3em;
    }
    
    .amp-checklist {
        grid-template-columns: 1fr;
    }
    
    .minification-table {
        font-size: 0.8em;
    }
    
    .minification-table .file-url {
        max-width: 200px;
    }
    
    .resources-compact-summary {
        flex-direction: column;
        gap: 8px;
    }
    
    .summary-item {
        flex-direction: row;
        justify-content: space-between;
    }
}
