/* --- Tooltip Styles --- */
#orderbook-tooltip {
    position: absolute; /* Crucial for positioning */
    background-color: rgba(40, 45, 55, 0.95); /* Dark, slightly transparent background */
    color: var(--text-primary, #e0e0e0); /* Use theme color or default */
    border: 1px solid var(--border, #555);
    border-radius: 6px;
    padding: 10px 15px;
    font-size: 0.8rem;
    z-index: 1000; /* Ensure it's on top */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    max-width: 280px; /* Prevent it from getting too wide */
    pointer-events: none; /* Tooltip shouldn't block mouse events on elements below */
    white-space: normal; /* Allow text wrapping */
    opacity: 0; /* Start hidden for transition */
    transition: opacity 0.15s ease-in-out, transform 0.15s ease-in-out;
    transform: translate(10px, 10px); /* Slight offset initially */
}

#orderbook-tooltip.visible {
    opacity: 1;
    transform: translate(15px, 15px); /* Final position offset from cursor */
}

#orderbook-tooltip .tooltip-header {
    font-weight: 600;
    margin-bottom: 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid var(--border, #555);
    color: var(--text-accent, #6fa8dc); /* Or a specific highlight color */
}

#orderbook-tooltip .tooltip-exchanges-list {
    list-style: none;
    padding: 0;
    margin: 0 0 8px 0; /* Space before cumulative info */
}

#orderbook-tooltip .tooltip-exchange-item {
    display: flex;
    align-items: center;
    margin-bottom: 4px;
    line-height: 1.4;
}

#orderbook-tooltip .exchange-color-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
    flex-shrink: 0;
}

#orderbook-tooltip .exchange-name {
    flex-grow: 1; /* Takes available space */
    margin-right: 8px;
    /* text-transform: capitalize; */ /* Optional: Capitalize exchange names */
    font-weight: 500;
}

#orderbook-tooltip .exchange-volume {
    min-width: 60px; /* Align volumes somewhat */
    text-align: right;
    margin-right: 8px;
    color: var(--text-secondary, #aaa);
}

#orderbook-tooltip .exchange-percentage {
    min-width: 45px; /* Align percentages */
    text-align: right;
    font-weight: 500;
    color: var(--text-accent, #6fa8dc);
}

#orderbook-tooltip .tooltip-cumulative {
    font-size: 0.75rem;
    color: var(--text-secondary, #aaa);
    border-top: 1px dashed var(--border, #555);
    padding-top: 8px;
    margin-top: 8px;
}