/* Aviation Map Styling */

/* Map container */
#aviation-map {
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Airport marker custom styles */
.airport-marker {
    cursor: pointer;
    transition: transform 0.2s ease;
}

.airport-marker:hover {
    transform: scale(1.3);
    z-index: 1000 !important;
}

/* Airport popup styling */
.airport-popup {
    font-family: 'Roboto', sans-serif;
    min-width: 200px;
}

.airport-popup h4 {
    margin: 0 0 8px 0;
    color: #1976d2;
    font-size: 16px;
    font-weight: 500;
    border-bottom: 2px solid #1976d2;
    padding-bottom: 4px;
}

.airport-popup p {
    margin: 4px 0;
    font-size: 13px;
    color: #424242;
}

.airport-popup p strong {
    color: #212121;
}

/* Leaflet control customization for aviation theme */
.leaflet-control-zoom a {
    background-color: #1976d2 !important;
    color: white !important;
}

.leaflet-control-zoom a:hover {
    background-color: #1565c0 !important;
}

/* Route polyline animation */
@keyframes dash {
    to {
        stroke-dashoffset: 0;
    }
}

.route-line {
    stroke-dasharray: 10, 5;
    stroke-dashoffset: 100;
    animation: dash 2s linear forwards;
}

/* Map legend (for future use) */
.map-legend {
    background: white;
    padding: 10px;
    border-radius: 4px;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.4);
    font-size: 12px;
}

.map-legend-item {
    display: flex;
    align-items: center;
    margin: 4px 0;
}

.map-legend-color {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    margin-right: 8px;
    border: 2px solid white;
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
}

/* Loading overlay for map */
.map-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    border-radius: 4px;
}

/* Responsive adjustments */
@media (max-width: 960px) {
    #aviation-map {
        height: 400px !important;
    }

    .airport-popup {
        min-width: 150px;
    }

    .airport-popup h4 {
        font-size: 14px;
    }

    .airport-popup p {
        font-size: 12px;
    }
}

/* Custom marker cluster styles (if using Leaflet.markercluster in future) */
.marker-cluster-small {
    background-color: rgba(25, 118, 210, 0.6);
}

.marker-cluster-small div {
    background-color: rgba(25, 118, 210, 0.8);
}

.marker-cluster-medium {
    background-color: rgba(255, 152, 0, 0.6);
}

.marker-cluster-medium div {
    background-color: rgba(255, 152, 0, 0.8);
}

.marker-cluster-large {
    background-color: rgba(244, 67, 54, 0.6);
}

.marker-cluster-large div {
    background-color: rgba(244, 67, 54, 0.8);
}

/* Aviation-specific styling */
.waypoint-marker {
    width: 6px;
    height: 6px;
    background-color: #9C27B0;
    border: 1px solid white;
    border-radius: 50%;
    box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
}

/* Route marker styling for subtle appearance */
.route-airport-marker,
.route-waypoint-marker {
    transition: all 0.2s ease;
    cursor: pointer;
}

.route-airport-marker:hover,
.route-waypoint-marker:hover {
    transform: scale(1.15);
    z-index: 1000 !important;
}

.route-airport-marker div,
.route-waypoint-marker div {
    transition: all 0.2s ease;
}

.route-airport-marker:hover div,
.route-waypoint-marker:hover div {
    filter: brightness(1.1);
}

.vor-marker {
    width: 8px;
    height: 8px;
    background-color: #00BCD4;
    border: 2px solid white;
    border-radius: 50%;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
}

.ndb-marker {
    width: 6px;
    height: 6px;
    background-color: #FF9800;
    border: 2px solid white;
    transform: rotate(45deg);
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
}

/* Flight plan panel scrollbar styling */
.mud-paper::-webkit-scrollbar {
    width: 8px;
}

.mud-paper::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.mud-paper::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.mud-paper::-webkit-scrollbar-thumb:hover {
    background: #555;
}
