/* ============================================
   LOCATION AUTOCOMPLETE
   Single field with Google Maps/Uber-style suggestions
   ============================================ */

.location-autocomplete-container {
    margin: 24px 0;
}

.location-field-single {
    position: relative;
}

/* ===== INPUT WRAPPER ===== */

.location-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.location-autocomplete-input {
    width: 100%;
    padding: 14px 50px 14px 16px;
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    color: #1e293b;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.3s ease;
    outline: none;
}

.location-autocomplete-input:focus {
    border-color: #D4AF37;
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.location-autocomplete-input::placeholder {
    color: #94a3b8;
    font-style: italic;
}

/* ===== LOCATION ICON ===== */

.location-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== SUGGESTIONS DROPDOWN ===== */

.location-suggestions {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
}

.location-suggestion-item {
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 12px;
}

.location-suggestion-item:last-child {
    border-bottom: none;
}

.location-suggestion-item:hover {
    background-color: #fffbf0;
}

.location-suggestion-item.active {
    background-color: #fffbf0;
}

/* ===== SUGGESTION CONTENT ===== */

.location-suggestion-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #D4AF37;
}

.location-suggestion-text {
    flex: 1;
}

.location-suggestion-city {
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 2px;
}

.location-suggestion-country {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    color: #64748b;
}

/* ===== LOADING STATE ===== */

.location-suggestions-loading {
    padding: 16px;
    text-align: center;
    color: #64748b;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
}

.location-suggestions-empty {
    padding: 16px;
    text-align: center;
    color: #94a3b8;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-style: italic;
}

/* ===== SELECTED STATE ===== */

.location-autocomplete-input.has-selection {
    border-color: #10b981;
    background-color: #f0fdf4;
}

.location-autocomplete-input.has-selection:focus {
    border-color: #059669;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

/* ===== FIELD DESCRIPTION ===== */

.location-field-single .field-description {
    margin-top: 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    color: #64748b;
    font-style: italic;
}

/* ===== RESPONSIVE ===== */

@media (max-width: 768px) {
    .location-autocomplete-input {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 12px 45px 12px 14px;
    }
    
    .location-suggestions {
        max-height: 250px;
    }
    
    .location-suggestion-item {
        padding: 10px 14px;
    }
}

/* ===== ACCESSIBILITY ===== */

.location-autocomplete-input:disabled {
    background-color: #f1f5f9;
    cursor: not-allowed;
    opacity: 0.6;
}

.location-suggestion-item:focus {
    outline: 2px solid #D4AF37;
    outline-offset: -2px;
}

/* ===== SCROLLBAR STYLING ===== */

.location-suggestions::-webkit-scrollbar {
    width: 8px;
}

.location-suggestions::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 0 12px 12px 0;
}

.location-suggestions::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 4px;
}

.location-suggestions::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
