/* Professional Dark Benchmark Styles */

.benchmark-section {
    padding: 4rem 2rem;
    background: var(--bg-primary);
    /* Dark slate background matching page */
    color: var(--text-primary);
}

.benchmark-container {
    max-width: 1400px;
    /* Wider for dashboard view */
    margin: 0 auto;
}

/* Header */
.benchmark-header {
    margin-bottom: 2rem;
}

.benchmark-title {
    font-size: 2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.benchmark-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 400;
}

/* Dashboard Layout */
.benchmark-dashboard {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
    background: var(--bg-secondary);
    /* Slightly lighter dark background for card */
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    min-height: 600px;
}

/* Sidebar */
.benchmark-sidebar {
    background: var(--bg-primary);
    border-right: 1px solid var(--border-color);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
}

.sidebar-title {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.sidebar-list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    overflow-y: auto;
}

.sidebar-item {
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
    user-select: none;
}

.sidebar-item:hover {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.sidebar-item.active {
    background: var(--bg-secondary);
    color: #fff;
    font-weight: 500;
    border-left: 3px solid var(--accent-tertiary);
    /* Purple accent */
}

.sidebar-item.inactive {
    opacity: 0.5;
}

/* Chart Area */
.benchmark-chart-wrapper {
    padding: 2rem;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

#benchmarkChart {
    width: 100%;
    height: 100%;
    min-height: 500px;
}

/* SVG Styles */
.line-chart-svg {
    overflow: visible;
}

/* Monochromatic Line Styles */
.line-path {
    fill: none;
    stroke-width: 2;
    stroke-opacity: 0.3;
    /* Default dimmed state */
    transition: all 0.3s ease;
}

.line-path.active {
    stroke-opacity: 1;
    stroke-width: 3;
    filter: drop-shadow(0 0 4px rgba(129, 43, 140, 0.5));
    /* Purple glow */
}

.line-path.hovered {
    stroke-width: 4;
    stroke-opacity: 1;
    z-index: 10;
}

.data-point {
    fill: var(--bg-secondary);
    /* Match bg */
    stroke-width: 2;
    r: 4;
    opacity: 0;
    /* Hide points by default for cleaner look */
    transition: all 0.2s ease;
}

.line-path.active+.data-points-group .data-point {
    opacity: 1;
}

.data-point:hover {
    r: 6;
    stroke-width: 3;
    cursor: pointer;
}

/* Tooltip */
.chart-tooltip {
    position: absolute;
    display: none;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    padding: 0.75rem;
    border-radius: 4px;
    color: var(--text-primary);
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 100;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.tooltip-year {
    color: var(--text-secondary);
    font-size: 0.8rem;
    margin-bottom: 0.25rem;
}

.tooltip-value {
    font-weight: 600;
    font-size: 1.1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .benchmark-dashboard {
        grid-template-columns: 1fr;
        height: auto;
    }

    .benchmark-sidebar {
        border-right: none;
        border-bottom: 1px solid #334155;
        max-height: 200px;
    }

    .sidebar-list {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .sidebar-item {
        flex: 1 1 auto;
        text-align: center;
        font-size: 0.85rem;
        padding: 0.5rem;
    }
}