<x-app-layout>
    <x-slot name="title">New Site Survey / Inquiry</x-slot>
    
    <div class="mb-6">
        <a href="{{ route('site-surveys.index') }}" class="text-primary-600 hover:text-primary-900 text-sm font-medium">&larr; Back to Inquiries</a>
    </div>

    <div class="bg-white rounded-xl shadow-sm border border-gray-100 overflow-hidden">
        <div class="px-6 py-5 border-b border-gray-100 bg-gray-50 flex justify-between items-center">
            <div>
                <h3 class="text-lg font-bold text-gray-900">Client Inquiry & Site Visit Form</h3>
                <p class="text-sm text-gray-500">Record a new construction inquiry or schedule a site visit.</p>
            </div>
        </div>

        <form action="{{ route('site-surveys.store') }}" method="POST" class="p-6 space-y-8">
            @csrf

            <div>
                <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                    <div>
                        <label class="block text-sm font-medium text-gray-700 mb-1">Client Name *</label>
                        <input type="text" name="customer_name" required class="w-full border-gray-300 rounded-md shadow-sm focus:ring-primary-500 focus:border-primary-500 sm:text-sm">
                    </div>
                    <div>
                        <label class="block text-sm font-medium text-gray-700 mb-1">Mobile No. *</label>
                        <input type="text" name="mobile" required class="w-full border-gray-300 rounded-md shadow-sm focus:ring-primary-500 focus:border-primary-500 sm:text-sm">
                    </div>
                    <div>
                        <label class="block text-sm font-medium text-gray-700 mb-1">City / Area</label>
                        <input type="text" name="city" class="w-full border-gray-300 rounded-md shadow-sm focus:ring-primary-500 focus:border-primary-500 sm:text-sm">
                    </div>
                    <div>
                        <label class="block text-sm font-medium text-gray-700 mb-1">Structure Type *</label>
                        <select name="structure_type" required class="w-full border-gray-300 rounded-md shadow-sm focus:ring-primary-500 focus:border-primary-500 sm:text-sm">
                            <option value="">Select Type</option>
                            <option value="A-Frame Cottage">A-Frame Cottage</option>
                            <option value="Dome Glamp">Dome Glamp</option>
                            <option value="Prefabricated Cottage">Prefabricated Cottage</option>
                            <option value="Luxury Cottage">Luxury Cottage</option>
                            <option value="Farmhouse">Farmhouse</option>
                        </select>
                    </div>
                    <div class="md:col-span-2">
                        <label class="inline-flex items-center">
                            <input type="checkbox" name="site_visit_required" value="1" class="rounded border-gray-300 text-primary-600 shadow-sm focus:border-primary-300 focus:ring focus:ring-primary-200 focus:ring-opacity-50">
                            <span class="ml-2 text-sm text-gray-700 font-medium">Site Visit Required?</span>
                        </label>
                    </div>
                </div>
            </div>
            
            <div class="pt-5 border-t border-gray-200 flex justify-end gap-3">
                <a href="{{ route('site-surveys.index') }}" class="px-4 py-2 border border-gray-300 shadow-sm text-sm font-medium rounded-md text-gray-700 bg-white hover:bg-gray-50">Cancel</a>
                <button type="submit" class="px-4 py-2 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-primary-600 hover:bg-primary-700">Submit Inquiry</button>
            </div>
        </form>
    </div>
</x-app-layout>
