/* Location Autocomplete Styles */
.location-wrapper {
    position: relative;
    width: 100%;
}

.location-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.location-suggestion {
    padding: 8px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.location-suggestion:hover {
    background-color: #f5f5f5;
}

.location-suggestion i {
    color: #666;
}

.location-suggestion span {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Google Places Autocomplete Styling */
.pac-container {
    background-color: #fff !important;
    border: 1px solid #ccc !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
    z-index: 1051 !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    margin-top: 2px !important;
}

.pac-item {
    padding: 12px 16px !important;
    cursor: pointer !important;
    border-bottom: 1px solid #f0f0f0 !important;
    transition: background-color 0.2s ease !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
}

.pac-item:hover {
    background-color: #f8f9fa !important;
}

.pac-item:last-child {
    border-bottom: none !important;
}

.pac-item-query {
    font-weight: 600 !important;
    color: #001f3f !important;
}

.pac-matched {
    font-weight: 700 !important;
    color: #003366 !important;
}

.pac-icon {
    margin-right: 8px !important;
    color: #001f3f !important;
}

.pac-item .pac-icon-marker {
    background-image: none !important;
    width: 16px !important;
    height: 16px !important;
}

.pac-item .pac-icon-marker::before {
    content: '\f3c5' !important;
    font-family: 'Font Awesome 6 Free' !important;
    font-weight: 900 !important;
    color: #001f3f !important;
    font-size: 14px !important;
}

/* Location Input Loading State */
.location-input.loading {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23001f3f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 12a9 9 0 11-6.219-8.56'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    background-size: 16px !important;
    animation: spin 1s linear infinite !important;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Location Search Container */
.location-search-container {
    position: relative;
    width: 100%;
}

.location-search {
    position: relative;
}

.location-search .form-text {
    color: #6c757d;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Location Input Focus State */
.location-input:focus {
    border-color: #001f3f !important;
    outline: 0 !important;
    box-shadow: 0 0 0 0.2rem rgba(0, 31, 63, 0.25) !important;
}

.location-input {
    border: 1px solid #ced4da;
    transition: all 0.3s ease;
}

.location-input:hover {
    border-color: #adb5bd;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .pac-container {
        max-width: calc(100vw - 40px) !important;
    }
    
    .pac-item {
        padding: 10px 12px !important;
        font-size: 13px !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .pac-container {
        border: 2px solid #000 !important;
    }
    
    .pac-item {
        border-bottom: 1px solid #000 !important;
    }
    
    .pac-item:hover {
        background-color: #000 !important;
        color: #fff !important;
    }
}
