/* Map Overlay Components Styling */

.legend {
    position: absolute;
    top: 1.5%;
    left: 1.5%;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid #ccc;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    min-width: 150px;
    z-index: 1000;
    font-family: Arial, sans-serif;
    font-size: 8px;
}

.legend-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 5px;
    cursor: pointer;
    user-select: none;
    border-radius: 5px 5px 0 0;
}

.legend-header:hover {
    background: rgba(240, 240, 240, 0.8);
}

.legend h3 {
    margin: 0;
    font-size: 14px;
    font-weight: bold;
    color: #333;
}

.legend-toggle {
    font-size: 16px;
    font-weight: bold;
    color: #666;
    line-height: 1;
}

.legend-content {
    padding: 0 5px 5px 5px;
    max-height: 500px;
    overflow-y: auto;
    transition: max-height 0.3s ease-out;
}

.legend-content.collapsed {
    max-height: 0;
    padding: 0 10px;
    overflow: hidden;
}

.legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 2px;
}

.legend-item:last-child {
    margin-bottom: 0;
}

.legend-symbol {
    width: 20px;
    height: 16px;
    margin-right: 8px;
    border: 1px solid #333;
    border-radius: 2px;
    display: inline-block;
    flex-shrink: 0;
}

.legend-symbol.point {
    border-radius: 50%;
    width: 12px;
    height: 12px;
    margin-right: 10px;
}

.legend-label {
    flex-grow: 1;
    color: #333;
}

/*INfo Buffotn*/
.label-with-info {
    display: flex;
    align-items: center;   /* vertically align icon with text */
    gap: 6px;              /* space between label and icon */
}