/* Mobile Navigation & Responsive Improvements CSS */
/* File: assets/css/mobile-navigation.css */

/* CSS Variables */
:root {
    --navy-blue: #1e3a8a;
    --ocean-blue: #3b82f6;
    --gold-accent: #f59e0b;
}

/* Navigation Base Styles */
.navbar {
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.navbar .dropdown-menu {
    z-index: 1020 !important;
    background-color: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0,0,0,.15) !important;
    border-radius: 8px !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
}

.navbar .dropdown-item {
    color: #212529 !important;
    padding: 0.75rem 1rem !important;
    transition: all 0.2s ease;
    border-radius: 4px !important;
    margin: 0.1rem 0.5rem !important;
}

.navbar .dropdown-item:hover {
    background-color: var(--ocean-blue) !important;
    color: white !important;
    transform: translateX(5px);
}

.navbar .dropdown-item i {
    width: 20px;
    text-align: center;
}

/* Mobile Navigation Improvements */
@media (max-width: 991.98px) {
    .navbar-nav {
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        border-radius: 8px;
        padding: 1rem;
        margin-top: 1rem;
    }
    
    .navbar-nav .nav-link {
        color: var(--navy-blue) !important;
        padding: 0.75rem 1rem !important;
        border-radius: 5px;
        margin: 0.2rem 0;
    }
    
    .navbar-nav .nav-link:hover {
        background-color: var(--ocean-blue);
        color: white !important;
    }
    
    .navbar-nav .nav-link.active {
        background-color: var(--gold-accent);
        color: white !important;
    }
}

/* Language Switcher Mobile */
@media (max-width: 575.98px) {
    .language-switcher {
        justify-content: center !important;
        margin: 1rem 0 !important;
        flex-wrap: wrap !important;
        gap: 0.5rem !important;
    }
    
    .language-switcher img {
        height: 24px !important;
        border-radius: 4px !important;
    }
}

/* Touch-friendly improvements */
@media (pointer: coarse) {
    .nav-link, .dropdown-item {
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
    }
    
    .btn {
        min-height: 44px !important;
        padding: 0.75rem 1.5rem !important;
    }
}

/* Prevent zoom on mobile form inputs */
@media screen and (max-width: 767px) {
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    textarea,
    select {
        font-size: 16px !important;
    }
}

/* Loading state for better perceived performance */
.navbar-brand img {
    transition: opacity 0.3s ease;
}

.navbar-brand img:not([src]) {
    opacity: 0;
}

/* Smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

/* Focus improvements for accessibility */
.nav-link:focus,
.dropdown-item:focus {
    outline: 2px solid var(--gold-accent) !important;
    outline-offset: 2px !important;
}

/* Mobile Map Specific Styles */
@media (max-width: 767.98px) {
    .map-section {
        padding: 40px 0 !important;
    }
    
    .section-title {
        font-size: 1.5rem !important;
        margin-bottom: 1rem !important;
    }
    
    .section-subtitle {
        font-size: 0.9rem !important;
        margin-bottom: 1.5rem !important;
    }
    
    /* Map container mobile adjustments */
    #map {
        height: 300px !important;
        min-height: 250px !important;
        touch-action: manipulation !important;
    }
    
    /* Places list mobile adjustments */
    .places-container {
        height: 350px !important;
        max-height: 40vh !important;
    }
    
    /* Button group mobile */
    .btn-group {
        display: flex !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 0.3rem !important;
    }
    
    .btn {
        flex: 0 0 auto !important;
        margin: 0 !important;
    }
    
    /* Touch-friendly list items */
    .place-item {
        min-height: 80px !important;
        padding: 1rem 0.8rem !important;
    }
    
    /* Responsive text sizes */
    .place-item h6 {
        font-size: 0.95rem !important;
        line-height: 1.3 !important;
    }
    
    .place-item small {
        font-size: 0.8rem !important;
    }
    
    /* Force hardware acceleration on mobile */
    #map, #map * {
        -webkit-transform: translate3d(0,0,0);
        transform: translate3d(0,0,0);
    }
}

/* Tablet adjustments */
@media (min-width: 768px) and (max-width: 991.98px) {
    #map {
        height: 350px !important;
    }
    
    .places-container {
        height: 350px !important;
    }
}

/* Desktop - larger map */
@media (min-width: 992px) {
    #map {
        height: 400px !important;
    }
    
    .places-container {
        height: 400px !important;
    }
}

/* Fix for iOS Safari */
.map-container {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

/* Prevent zoom on double tap for map area */
#map * {
    touch-action: manipulation !important;
}

/* Fullscreen map styles for mobile */
.fullscreen-map {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9999 !important;
    border-radius: 0 !important;
}

/* Google Maps Container Fix for Mobile */
#map {
    width: 100% !important;
    height: 100% !important;
    position: relative !important;
}

/* Ensure map images load on mobile */
#map img {
    max-width: none !important;
    height: auto !important;
}

/* Fix for map tiles on mobile */
#map .gm-style {
    width: 100% !important;
    height: 100% !important;
}

#map .gm-style > div:first-child {
    width: 100% !important;
    height: 100% !important;
}

/* Google Maps InfoWindow Mobile Fix */
.gm-style-iw {
    min-width: 250px !important;
}

.gm-style-iw-c {
    padding: 0 !important;
}

.gm-style-iw-d {
    overflow: auto !important;
    max-height: none !important;
}



/* Center all text in Google Maps InfoWindow popups */
.gm-style-iw-c {
    text-align: center !important;
}

.gm-style-iw-d {
    text-align: center !important;
}

/* Keep buttons/links layout as is */
.gm-style-iw-d a {
    text-align: center !important;
}


/* Mobile specific InfoWindow adjustments */
@media (max-width: 768px) {
    .gm-style .gm-style-iw-c {
        max-width: 90vw !important;
        min-width: 250px !important;
    }
    
    .gm-style-iw-d {
        font-size: 14px !important;
        padding: 5px !important;
    }
    
    .gm-style-iw-t::after {
        top: -1px !important;
    }
}

/* Mobile info panel with smooth unfold animation */
.mobile-info {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: #fff;
    padding: 15px;
    border-top: 1px solid #ddd;
    font-family: Arial, sans-serif;
    max-height: 50vh;
    overflow-y: auto;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    z-index: 1000;
    
    /* Smooth slide-up animation */
    transform: translateY(100%);
    transition: transform 0.3s ease-out;
}

.mobile-info:not(.hidden) {
    transform: translateY(0);
}

.mobile-info.hidden {
    transform: translateY(100%);
    pointer-events: none;
}

#close-panel {
    float: right;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Hide mobile panel on desktop */
@media (min-width: 768px) {
    #mobile-info {
        display: none !important;
    }
}


