/* Request Airport Button */
.request-airport-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #4285f4;
    color: #fff;
    border: none;
    border-radius: 8px;
    width: 32px;
    height: 32px;
    margin-left: 8px;
    font-size: 20px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(66,133,244,0.08);
    transition: background 0.2s, transform 0.2s;
    cursor: pointer;
}
.request-airport-btn:hover {
    background: #3367d6;
    transform: scale(1.08);
}
/* Streamer Mode Toggle Styles */
.streamer-toggle-container {
    margin-top: 8px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}
.streamer-toggle-label {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    margin-left: 0;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    font-size: 14px;
    color: #333;
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    margin-left: 0;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    font-size: 15px;
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
/* Reset default margins and padding */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Set html and body to full height */
html, body {
    height: 100%;
    width: 100%;
    overflow: hidden;
}

/* Full screen map container */
#map {
    height: 100vh;
    width: 100vw;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

/* Ensure Leaflet controls are properly positioned */
.leaflet-control-container {
    z-index: 1000;
}

/* Search Container */
.search-container {
    position: fixed;
    top: 20px;
    left: 80px; /* Position next to map controls (zoom buttons are ~70px) */
    z-index: 2000;
    width: 320px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.search-bar {
    position: relative;
    display: flex;
    align-items: center;
}

#airport-search {
    width: 100%;
    padding: 12px 40px 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    outline: none;
}

#airport-search:focus {
    border-color: #4285f4;
    box-shadow: 0 4px 16px rgba(66, 133, 244, 0.2);
}

.clear-search-btn {
    position: absolute;
    right: 8px;
    background: white;
    color: #fff;
    padding: 6px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-family: inherit;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border: 1px solid #333;
    margin-left: 0;
    opacity: 1;
    color: #333;
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-top: 4px;
    max-height: 300px;
    overflow-y: auto;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    z-index: 2001;
}

.search-results.hidden {
    display: none;
}

.search-result-item {
        background: white;
        border: 2px solid #e0e0e0;
        border-radius: 8px;
        cursor: pointer;
        margin-left: 8px;
        padding: 6px 10px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    font-size: 14px;
        color: #333;
        box-shadow: 0 4px 12px rgba(0,0,0,0.08);
        transition: background 0.2s, color 0.2s, box-shadow 0.2s;
        outline: none;
}

.search-result-item:hover {
    background: #f8f9ff;
}

.search-result-codes {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.search-result-code {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.search-result-code.icao {
    background: #e8f0fe;
    color: #1976d2;
}

.search-result-code.iata {
    background: #f3e5f5;
    color: #7b1fa2;
}
        background: #f1f3f4;
        color: #4285f4;
        box-shadow: 0 6px 16px rgba(66,133,244,0.10);
    color: #333;
    font-weight: 500;
}

.search-no-results {
    padding: 16px;
    text-align: center;
    color: #666;
    font-size: 14px;
}

/* Loading overlay that covers the entire screen */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.loading-overlay.hidden {
    display: none;
}

.loading-content {
    text-align: center;
    background: white;
    padding: 40px 30px;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    max-width: 320px;
    animation: slideUp 0.3s ease-out;
}

.loading-content h2 {
    margin: 20px 0 10px 0;
    color: #333;
    font-size: 24px;
    font-weight: 600;
}

.loading-content p {
    margin: 0 0 30px 0;
    color: #666;
    font-size: 16px;
    line-height: 1.4;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e3e3e3;
    border-top: 4px solid #4285f4;
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 1s linear infinite;
}

.skip-button {
    background: #f1f3f4;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #3c4043;
    cursor: pointer;
    transition: all 0.2s ease;
}

.skip-button:hover {
    background: #e8eaed;
    transform: translateY(-1px);
}

.skip-button:active {
    transform: translateY(0);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Optional: Style for loading screen or overlays */
.loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2000;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 8px;
    font-family: Arial, sans-serif;
    display: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .leaflet-control-zoom {
        font-size: 14px;
    }
    
    .leaflet-control-attribution {
        font-size: 10px;
    }
}

/* Custom map controls styling */
.leaflet-bar a {
    background-color: #fff;
    border-bottom: 1px solid #ccc;
    width: 34px;
    height: 34px;
    line-height: 34px;
    display: block;
    text-align: center;
    text-decoration: none;
    color: black;
}

.leaflet-bar a:hover {
    background-color: #f4f4f4;
}

/* Ensure map tiles load smoothly */
.leaflet-tile-container {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Google Maps-style user location marker */
.user-location-marker {
    background: transparent !important;
    border: none !important;
}

.location-dot {
    width: 20px;
    height: 20px;
    background: #4285f4;
    border: 3px solid #ffffff;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: locationPulse 2s infinite;
}

.location-dot::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    width: 20px;
    height: 20px;
    background: #4285f4;
    border-radius: 50%;
    opacity: 0.3;
    animation: locationRipple 2s infinite;
}

@keyframes locationPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes locationRipple {
    0% {
        transform: scale(1);
        opacity: 0.3;
    }
    100% {
        transform: scale(2.5);
        opacity: 0;
    }
}

/* Airport Information Panel */
.airport-panel {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 350px;
    max-height: calc(100vh - 40px);
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    z-index: 2000;
    overflow: hidden;
    transition: all 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.airport-panel.hidden {
    transform: translateX(120%);
    opacity: 0;
}

.panel-header {
    background: #4285f4;
    color: white;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.panel-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.close-button {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.close-button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.panel-content {
    padding: 20px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.airport-details {
    margin-bottom: 24px;
}

.airport-codes {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.code {
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
}

.code.icao {
    background: #e8f0fe;
    color: #1976d2;
}

.code.iata {
    background: #f3e5f5;
    color: #7b1fa2;
}

.airport-info p {
    margin: 8px 0;
    font-size: 14px;
    color: #333;
    line-height: 1.4;
}

.chart-providers {
    border-top: 1px solid #e0e0e0;
    padding-top: 20px;
}

.chart-providers h4 {
    margin: 0 0 16px 0;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.provider-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.provider-btn {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    background: white;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.provider-btn:hover {
    border-color: #4285f4;
    background: #f8f9ff;
    transform: translateY(-1px);
}

.provider-btn.skyvector {
    border-color: #0066cc;
    color: #0066cc;
}

.provider-btn.skyvector:hover {
    background: #e6f2ff;
    border-color: #0066cc;
}

.provider-btn.foreflight {
    border-color: #ff6b35;
    color: #ff6b35;
}

.provider-btn.foreflight:hover {
    background: #fff4f1;
    border-color: #ff6b35;
}

.provider-btn.airnav {
    border-color: #28a745;
    color: #28a745;
}

.provider-btn.airnav:hover {
    background: #f1f8f3;
    border-color: #28a745;
}

.provider-btn.faa {
    border-color: #6f42c1;
    color: #6f42c1;
}

.provider-btn.faa:hover {
    background: #f4f1ff;
    border-color: #6f42c1;
}

.provider-btn.chartfox {
    border-color: #ff8c00;
    color: #ff8c00;
}

.provider-btn.chartfox:hover {
    background: #fff8f0;
    border-color: #ff8c00;
}

.provider-btn.navigraph {
    border-color: #1e90ff;
    color: #1e90ff;
}

.provider-btn.navigraph:hover {
    background: #f0f8ff;
    border-color: #1e90ff;
}

/* Sim Content Section */
.sim-content {
    border-top: 1px solid #e0e0e0;
    padding-top: 20px;
    margin-top: 20px;
}

.sim-content h4 {
    margin: 0 0 16px 0;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.sim-content-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sim-content-item {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    background: white;
    border-radius: 8px;
    transition: all 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.sim-content-item:hover {
    border-color: #4285f4;
    background: #f8f9ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.sim-content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.sim-content-type {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    background: #e8f0fe;
    color: #1976d2;
}

.sim-content-payware {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.sim-content-payware.payware {
    background: #fff3e0;
    color: #f57c00;
}

.sim-content-payware.freeware {
    background: #e8f5e8;
    color: #388e3c;
}

.sim-content-creator {
    font-size: 13px;
    color: #666;
    font-weight: 500;
}

.sim-content-empty {
    padding: 16px;
    text-align: center;
    color: #666;
    font-size: 14px;
    border: 1px dashed #e0e0e0;
    border-radius: 8px;
    background: #fafafa;
}

/* Airport markers */
.airport-marker {
    background: transparent !important;
    border: none !important;
}

.airport-icon {
    width: 36px;
    height: 24px;
    background: #4285f4;
    border: 2px solid white;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    font-weight: bold;
    color: white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
}

.airport-icon:hover {
    transform: scale(1.1);
    background: #3367d6;
}

/* Responsive design for mobile */
@media (max-width: 768px) {
    .search-container {
        width: calc(100vw - 90px); /* Account for left positioning */
        left: 80px;
    }
    
    .airport-panel {
        width: calc(100vw - 40px);
        right: 20px;
        left: 20px;
        top: 80px; /* Adjust to account for search bar */
    }
    
    .provider-buttons {
        grid-template-columns: 1fr;
    }
}