/* A compact, single-line legend using the map's original dot-and-label style. */
#layer-legend.map-legend {
    flex-direction: row;
    align-items: center;
    flex-wrap: nowrap;
    gap: 12px;
    min-width: 0;
    min-height: 40px;
    margin-top: 4px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, .2) transparent;
}
#layer-legend .map-legend-choices {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    flex-wrap: nowrap;
    gap: 10px;
}
#layer-legend .map-legend-choice {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 40px;
    min-height: 40px;
    padding: 0 2px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--muted, #9ca3af);
    font: inherit;
    font-size: 11.5px;
    font-weight: 500;
    line-height: 1.4;
    white-space: nowrap;
    text-decoration: underline;
    text-decoration-color: transparent;
    text-underline-offset: 6px;
    text-decoration-thickness: 2px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: color .16s, text-decoration-color .16s;
}
#layer-legend .map-legend-choice:hover { color: var(--text, #f3f4f6); }
#layer-legend .map-legend-choice[aria-pressed="true"] { color: var(--text, #f3f4f6); text-decoration-color: #7eb7ff; }
#layer-legend .map-legend-choice:focus-visible { outline: 2px solid #7eb7ff; outline-offset: -2px; border-radius: 4px; }
#layer-legend .map-legend-dot { flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; }
#layer-legend .map-legend-note { flex: 0 0 auto; margin-left: auto; color: var(--faint, #6b7280); font-size: 10.5px; white-space: nowrap; }
@media (prefers-reduced-motion: reduce) {
    #layer-legend .map-legend-choice { transition: none; }
}
