/**
 * Currency Impact Chart Styles
 * 
 * @package ITX_Economic_Calendar
 * @since 2.0.0
 * @version 1.0.0
 */

/* Currency Impact Section */
.dashboard-currency-impact-section {
    margin: 30px 0;
}

/* Chart is always visible now */

.dashboard-currency-impact-section .dashboard-section-header {
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dashboard-currency-impact-section .dashboard-section-header .dashboard-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Chart update button now uses itx-ec-load-ai-btn styles */

#chartdiv {
    width: 100%;
    height: 500px;
    max-width: 100%;
}

/* Loading State */
#currency-impact-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    font-size: 16px;
    color: #666;
    z-index: 10;
}

#currency-impact-loading::before {
    content: '';
    display: block;
    width: 40px;
    height: 40px;
    margin: 0 auto 10px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Chart Legend */
.chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
}

.legend-marker {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid;
    display: inline-block;
}

.legend-marker.legend-better {
    background-color: #4caf50;
    border-color: #2e7d32;
}

.legend-marker.legend-worse {
    background-color: #f44336;
    border-color: #c62828;
}

.legend-marker.legend-equal {
    background-color: #ffc107;
    border-color: #f57c00;
}

/* Chart Description */
.dashboard-currency-impact-section .chart-description {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-left: 4px solid #3498db;
    border-radius: 4px;
}

.dashboard-currency-impact-section .chart-description p {
    margin: 0 0 10px 0;
    color: #555;
    font-size: 14px;
    line-height: 1.6;
}

.dashboard-currency-impact-section .chart-description p:last-child {
    margin-bottom: 0;
}

/* Error State */
.itx-ec-error {
    padding: 30px;
    text-align: center;
    color: #f44336;
    font-size: 16px;
}

.itx-ec-error i {
    font-size: 32px;
    margin-bottom: 10px;
    display: block;
}

/* Responsive Design */
@media (max-width: 768px) {
    #chartdiv {
        height: 400px;
    }

    .chart-legend {
        flex-direction: column;
        gap: 10px;
    }

    .dashboard-currency-impact-section .chart-description {
        padding: 10px;
        font-size: 13px;
    }
}

/* Dark Mode Support (Optional) */
@media (prefers-color-scheme: dark) {
    .chart-legend {
        background: #2a2a2a;
    }

    .legend-item {
        color: #e0e0e0;
    }

    .dashboard-currency-impact-section .chart-description {
        background: #2a2a2a;
        border-left-color: #64b5f6;
    }

    .dashboard-currency-impact-section .chart-description p {
        color: #b0b0b0;
    }
}



