"use client" import type React from "react" import { useState } from "react" import { Button } from "@/components/ui/button" import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card" import { Input } from "@/components/ui/input" import { Textarea } from "@/components/ui/textarea" import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select" import { Checkbox } from "@/components/ui/checkbox" import { Calendar } from "@/components/ui/calendar" import { Popover, PopoverContent, PopoverTrigger } from "@/components/ui/popover" import { CalendarIcon, DollarSign, User, MessageSquare } from "lucide-react" import { format } from "date-fns" import Link from "next/link" import { artists } from "@/data/artists" const timeSlots = ["10:00 AM", "11:00 AM", "12:00 PM", "1:00 PM", "2:00 PM", "3:00 PM", "4:00 PM", "5:00 PM", "6:00 PM"] const tattooSizes = [ { size: "Small (2-4 inches)", duration: "1-2 hours", price: "150-300" }, { size: "Medium (4-6 inches)", duration: "2-4 hours", price: "300-600" }, { size: "Large (6+ inches)", duration: "4-6 hours", price: "600-1000" }, { size: "Full Session", duration: "6-8 hours", price: "1000-1500" }, ] interface BookingFormProps { artistId?: string } export function BookingForm({ artistId }: BookingFormProps) { const [step, setStep] = useState(1) const [selectedDate, setSelectedDate] = useState() const [formData, setFormData] = useState({ // Personal Info firstName: "", lastName: "", email: "", phone: "", age: "", // Appointment Details artistId: artistId || "", preferredDate: "", preferredTime: "", alternateDate: "", alternateTime: "", // Tattoo Details tattooDescription: "", tattooSize: "", placement: "", isFirstTattoo: false, hasAllergies: false, allergyDetails: "", referenceImages: "", // Additional Info specialRequests: "", depositAmount: 100, agreeToTerms: false, agreeToDeposit: false, }) const selectedArtist = artists.find((a) => String(a.id) === formData.artistId || a.slug === formData.artistId) const selectedSize = tattooSizes.find((size) => size.size === formData.tattooSize) const handleInputChange = (field: string, value: any) => { setFormData((prev) => ({ ...prev, [field]: value })) } const handleSubmit = (e: React.FormEvent) => { e.preventDefault() // Handle form submission console.log("Booking submitted:", formData) // In a real app, this would send data to your backend } const nextStep = () => setStep((prev) => Math.min(prev + 1, 4)) const prevStep = () => setStep((prev) => Math.max(prev - 1, 1)) return (
{/* Header */}

Book Your Appointment

Let's create something amazing together. Fill out the form below to schedule your tattoo session.

{/* Progress Indicator */}
{[1, 2, 3, 4].map((stepNumber) => (
= stepNumber ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground" }`} > {stepNumber}
{stepNumber < 4 && (
stepNumber ? "bg-primary" : "bg-muted"}`} /> )}
))}
{/* Step 1: Personal Information */} {step === 1 && ( Personal Information
handleInputChange("firstName", e.target.value)} required />
handleInputChange("lastName", e.target.value)} required />
handleInputChange("email", e.target.value)} required />
handleInputChange("phone", e.target.value)} required />
handleInputChange("age", e.target.value)} required />

Must be 18 or older

handleInputChange("isFirstTattoo", checked)} />
handleInputChange("hasAllergies", checked)} />
{formData.hasAllergies && (