.attractions-map-container {
    position: relative;
    font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;
    width: 100%;
    overflow: hidden;
}

.attractions-map-controls {
    position: relative;
    z-index: 1;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 12px;
    border-radius: 5px 5px 0 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    color: #fff;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

.filter-label {
    font-weight: bold;
    margin-right: 5px;
    white-space: nowrap;
    font-size: 14px;
}

.filter-btn {
    background: none;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 10px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    white-space: nowrap;
    flex-shrink: 0;
    -webkit-tap-highlight-color: rgba(255,255,255,0.1);
    user-select: none;
    -webkit-user-select: none;
    min-height: 44px; /* Apple's recommended minimum touch target */
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.filter-btn:hover,
.filter-btn:focus {
    background: rgba(255,255,255,0.1);
    outline: none;
}

.filter-btn:active {
    background: rgba(255,255,255,0.2);
    transform: scale(0.98);
}

.filter-btn.active {
    background: rgba(255,255,255,0.2);
    border-color: rgba(255,255,255,0.5);
}

.attractions-map {
    width: 100%;
    min-height: 400px;
    position: relative;
    /* FIX: Removed 'touch-action: pan-x pan-y;' as it conflicts with Google's gesture handling */
}

/* Mobile-specific styles */
@media (max-width: 768px) {
    .attractions-map-container {
        margin: 0;
        border-radius: 0;
    }
    
    .attractions-map-controls {
        padding: 10px;
        gap: 6px;
        border-radius: 0;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }
    
    .attractions-map-controls::-webkit-scrollbar {
        display: none;
    }
    
    .filter-label {
        font-size: 13px;
        margin-right: 3px;
    }
    
    .filter-btn {
        padding: 8px 10px;
        font-size: 13px;
        min-height: 40px;
        min-width: 40px;
    }
    
    .attractions-map {
        min-height: 350px;
        height: 50vh;
        max-height: 500px;
    }
    
    .marker-preview {
        width: 16px !important;
        height: 16px !important;
        margin-right: 4px !important;
    }
}

@media (max-width: 480px) {
    .attractions-map-controls {
        padding: 8px;
        gap: 4px;
    }
    
    .filter-label {
        display: none;
    }
    
    .filter-btn {
        padding: 6px 8px;
        font-size: 12px;
        min-height: 36px;
        min-width: 36px;
    }
    
    .attractions-map {
        min-height: 300px;
        height: 45vh;
        max-height: 400px;
    }
}

.gm-style-iw {
    font-family: inherit !important;
    max-width: 300px !important;
}

@media (max-width: 768px) {
    .gm-style-iw {
        max-width: 250px !important;
    }
}

.gm-ui-hover-effect {
    width: 40px !important; 
    height: 24px !important;
}

.gm-ui-hover-effect > span {
    width: 14px !important; 
    height: 14px !important;
}

.attractions-map-controls .marker-preview {
    display: inline-block;
    vertical-align: middle;
    margin-right: 6px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.attractions-map-controls .marker-preview.default-pin {
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.2);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* FIX: Removed the overly broad rule that was disabling user-select on map elements */
/* and breaking interactions. The 'user-select' rule on .filter-btn is sufficient. */

/* Allow text selection in info windows */
.gm-style-iw * {
    -webkit-touch-callout: default;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}