"""Phase 4: Launch templates for the Template Marketplace.

20 templates covering common use cases, each leveraging Phase 3 features:
- Conditional fields
- Validation rules
- Calculated fields
- Multi-step support
"""

LAUNCH_TEMPLATES = [
    # 1. Contact Us — Simple, universal
    {
        "slug": "contact-us",
        "name": "Contact Us",
        "description": "Classic contact form with name, email, phone, subject, and message.",
        "category": "Support",
        "is_featured": 1,
        "success_message": "Thanks for reaching out! We'll get back to you within 24 hours.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": False,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "subject",
                "label": "Subject",
                "type": "select",
                "required": True,
                "options": ["General Inquiry", "Support", "Partnership", "Feedback", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "message",
                "label": "Message",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 2000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 2. Quote Request — With conditionals
    {
        "slug": "quote-request",
        "name": "Quote Request",
        "description": "Business quote form with service type selection and conditional fields.",
        "category": "Business",
        "is_featured": 1,
        "success_message": "Quote request received! We'll send you an estimate within 1-2 business days.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "company",
                "label": "Company Name",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": False,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "service_type",
                "label": "Service Needed",
                "type": "select",
                "required": True,
                "options": ["Web Development", "Marketing", "Consulting", "Design", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "project_details",
                "label": "Project Details",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 20, "maxLength": 2000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "timeline",
                "label": "Desired Timeline",
                "type": "select",
                "required": False,
                "options": ["ASAP", "Within 2 weeks", "Within a month", "Flexible"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "budget_range",
                "label": "Budget Range",
                "type": "select",
                "required": False,
                "options": ["Under $1,000", "$1,000 - $5,000", "$5,000 - $10,000", "$10,000+", "Not sure yet"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 3. Event RSVP — With conditionals (+1, dietary)
    {
        "slug": "event-rsvp",
        "name": "Event RSVP",
        "description": "RSVP form with attendance confirmation and conditional +1/dietary fields.",
        "category": "Events",
        "is_featured": 1,
        "success_message": "RSVP received! We'll send you a confirmation email with event details.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "attending",
                "label": "Will you be attending?",
                "type": "select",
                "required": True,
                "options": ["Yes, I'll be there!", "Maybe", "No, I can't make it"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "guest_count",
                "label": "Number of guests (including yourself)",
                "type": "number",
                "required": False,
                "validation": {"min": 1, "max": 10},
                "condition": {"field": "attending", "operator": "equals", "value": "Yes, I'll be there!"},
                "calculation": None,
                "step": 1,
            },
            {
                "name": "dietary_restrictions",
                "label": "Dietary Restrictions",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": {"field": "attending", "operator": "equals", "value": "Yes, I'll be there!"},
                "calculation": None,
                "step": 1,
            },
            {
                "name": "special_requests",
                "label": "Special Requests or Accessibility Needs",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 4. Job Application — With conditionals (experience-based)
    {
        "slug": "job-application",
        "name": "Job Application",
        "description": "Job application form with experience level conditionals and start date.",
        "category": "Hiring",
        "is_featured": 0,
        "success_message": "Application received! We'll review it and get back to you within 5 business days.",
        "field_config": [
            {
                "name": "first_name",
                "label": "First Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 1, "maxLength": 50},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "last_name",
                "label": "Last Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 1, "maxLength": 50},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "position",
                "label": "Position Applying For",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "experience_level",
                "label": "Experience Level",
                "type": "select",
                "required": True,
                "options": ["Entry Level (0-2 years)", "Mid Level (3-5 years)", "Senior (6-10 years)", "Lead/Manager (10+ years)"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "portfolio_url",
                "label": "Portfolio / LinkedIn URL",
                "type": "url",
                "required": False,
                "validation": {"pattern": "^https?://"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "start_date",
                "label": "Earliest Start Date",
                "type": "select",
                "required": True,
                "options": ["Immediately", "Within 2 weeks", "Within a month", "More than a month"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "cover_letter",
                "label": "Why are you interested in this position?",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 50, "maxLength": 2000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 5. Feedback/Survey — With rating and conditional follow-up
    {
        "slug": "feedback-survey",
        "name": "Feedback & Survey",
        "description": "Customer feedback form with rating, category, and conditional follow-up fields.",
        "category": "Support",
        "is_featured": 1,
        "success_message": "Thank you for your feedback! It helps us improve.",
        "field_config": [
            {
                "name": "rating",
                "label": "How would you rate your experience?",
                "type": "select",
                "required": True,
                "options": ["5 - Excellent", "4 - Very Good", "3 - Good", "2 - Fair", "1 - Poor"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "category",
                "label": "What is your feedback about?",
                "type": "select",
                "required": True,
                "options": ["Product Quality", "Customer Service", "Website/UX", "Delivery/Shipping", "Pricing", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "positive_feedback",
                "label": "What went well?",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": {"field": "rating", "operator": "not_equals", "value": "1 - Poor"},
                "calculation": None,
                "step": 1,
            },
            {
                "name": "improvement_feedback",
                "label": "What can we improve?",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 1000},
                "condition": {"field": "rating", "operator": "not_equals", "value": "5 - Excellent"},
                "calculation": None,
                "step": 1,
            },
            {
                "name": "would_recommend",
                "label": "Would you recommend us to others?",
                "type": "select",
                "required": True,
                "options": ["Definitely", "Probably", "Not Sure", "Probably Not", "Definitely Not"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "follow_up_email",
                "label": "Email (optional - for follow-up)",
                "type": "email",
                "required": False,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
 
    # 7. Product Order — With calculation (total)
    {
        "slug": "product-order",
        "name": "Product Order",
        "description": "Product order form with shipping address, product selection, and quantity.",
        "category": "E-commerce",
        "is_featured": 1,
        "success_message": "Order received! We'll send a confirmation email with shipping details.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "address_line1",
                "label": "Shipping Address",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 300},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "address_line2",
                "label": "Apt / Suite (optional)",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "city",
                "label": "City",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "state",
                "label": "State / Province",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "zip_code",
                "label": "ZIP / Postal Code",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 20},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "product",
                "label": "Product",
                "type": "select",
                "required": True,
                "options": ["Seed Packet - Heirloom Tomatoes ($8.99)", "Seed Packet - Heritage Corn ($7.49)", "Seed Packet - Rainbow Carrots ($6.99)", "Seasonal Starter Kit ($24.99)", "Full Garden Bundle ($49.99)"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "quantity",
                "label": "Quantity",
                "type": "number",
                "required": True,
                "validation": {"min": 1, "max": 99},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "special_instructions",
                "label": "Special Instructions",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
  
   
    # 11. Photography Consultation (Photography) — Featured
    {
        "slug": "photography-consultation",
        "name": "Photography Consultation",
        "description": "Book a free consultation to discuss your photography needs for weddings, portraits, events, and more.",
        "category": "Photography",
        "is_featured": 1,
        "success_message": "Consultation request received! We'll reach out to schedule a chat about your needs.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_type",
                "label": "Event Type",
                "type": "select",
                "required": True,
                "options": ["Wedding", "Portrait", "Corporate", "Family", "Event", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_date",
                "label": "Event Date",
                "type": "date",
                "required": False,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_location",
                "label": "Event Location",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 300},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "package_interest",
                "label": "Package Interest",
                "type": "select",
                "required": False,
                "options": ["Basic", "Standard", "Premium", "Custom"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "number_of_hours",
                "label": "Number of Hours",
                "type": "number",
                "required": False,
                "validation": {"min": 1, "max": 16},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "estimated_guests",
                "label": "Estimated Guests/Subjects",
                "type": "number",
                "required": False,
                "validation": {"min": 1, "max": 10000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "special_requests",
                "label": "Special Requests",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "referral_source",
                "label": "How Did You Hear About Us",
                "type": "select",
                "required": False,
                "options": ["Google Search", "Social Media", "Friend/Family", "Wedding Venue", "Advertisement", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 12. Event Photography Booking (Photography) — Featured
    {
        "slug": "event-photography-booking",
        "name": "Event Photography Booking",
        "description": "Book professional photography coverage for your event with flexible delivery options.",
        "category": "Photography",
        "is_featured": 1,
        "success_message": "Booking request submitted! We'll confirm availability and send a contract for review.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_name",
                "label": "Event Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_date",
                "label": "Event Date",
                "type": "date",
                "required": True,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_start_time",
                "label": "Event Start Time",
                "type": "time",
                "required": True,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_end_time",
                "label": "Event End Time",
                "type": "time",
                "required": True,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_address",
                "label": "Event Address",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 300},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "event_type",
                "label": "Event Type",
                "type": "select",
                "required": True,
                "options": ["Wedding", "Corporate Event", "Birthday Party", "Conference", "Gala", "Sports Event", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "number_of_guests",
                "label": "Number of Guests",
                "type": "number",
                "required": False,
                "validation": {"min": 1, "max": 10000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "delivery_format",
                "label": "Delivery Format",
                "type": "select",
                "required": True,
                "options": ["Digital", "Print", "Both"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "rush_delivery",
                "label": "Rush Delivery Needed",
                "type": "select",
                "required": True,
                "options": ["Yes", "No"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "special_instructions",
                "label": "Special Instructions",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 13. Photo Session Inquiry (Photography)
    {
        "slug": "photo-session-inquiry",
        "name": "Photo Session Inquiry",
        "description": "Inquire about photo sessions for families, couples, seniors, newborns, pets, and more.",
        "category": "Photography",
        "is_featured": 0,
        "success_message": "Session inquiry received! We'll get back to you with availability and pricing.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "session_type",
                "label": "Session Type",
                "type": "select",
                "required": True,
                "options": ["Family", "Couple", "Senior", "Graduation", "Newborn", "Pet", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "number_of_people",
                "label": "Number of People",
                "type": "number",
                "required": True,
                "validation": {"min": 1, "max": 50},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "preferred_location",
                "label": "Preferred Location",
                "type": "select",
                "required": True,
                "options": ["Studio", "Outdoor", "Client Location"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "session_length",
                "label": "Session Length",
                "type": "select",
                "required": True,
                "options": ["1hr", "2hrs", "3hrs"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "preferred_date",
                "label": "Preferred Date",
                "type": "date",
                "required": False,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "outfit_ideas",
                "label": "Outfit Ideas",
                "type": "select",
                "required": True,
                "options": ["Yes", "No"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "addons_interest",
                "label": "Add-Ons Interest",
                "type": "select",
                "required": False,
                "options": ["Album", "Canvas", "Photos", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 14. Property Showing Request (Real Estate)
    {
        "slug": "property-showing-request",
        "name": "Property Showing Request",
        "description": "Schedule a property showing with your real estate agent for any available listing.",
        "category": "Real Estate",
        "is_featured": 0,
        "success_message": "Showing request submitted! Your agent will contact you to confirm the appointment.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "property_address",
                "label": "Property Address (or 'Any available')",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 300},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "preferred_date",
                "label": "Preferred Date",
                "type": "date",
                "required": True,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "preferred_time",
                "label": "Preferred Time",
                "type": "time",
                "required": True,
                "validation": None,
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "party_size",
                "label": "Number of People in Party",
                "type": "number",
                "required": True,
                "validation": {"min": 1, "max": 10},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "pre_approved",
                "label": "Pre-Approved",
                "type": "select",
                "required": True,
                "options": ["Yes", "No", "Maybe"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "must_have_features",
                "label": "Must-Have Features",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "nice_to_have_features",
                "label": "Nice-to-Have Features",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "questions",
                "label": "Questions or Special Requests",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 15. Home Buyer Consultation (Real Estate) — Featured
    {
        "slug": "home-buyer-consultation",
        "name": "Home Buyer Consultation",
        "description": "Get personalized guidance from our agents as you search for your next home.",
        "category": "Real Estate",
        "is_featured": 1,
        "success_message": "Consultation request received! We'll match you with the perfect agent for your needs.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "looking_to_buy",
                "label": "Looking To Buy",
                "type": "select",
                "required": True,
                "options": ["Yes", "No", "Just Browsing"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "property_type",
                "label": "Property Type",
                "type": "select",
                "required": False,
                "options": ["Single Family", "Condo", "Townhouse", "Land", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "price_range",
                "label": "Price Range",
                "type": "select",
                "required": False,
                "options": ["Under $100K", "$100K–$250K", "$250K–$500K", "$500K–$1M", "Over $1M", "Not Sure"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "preferred_location",
                "label": "Preferred Location",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "timeline",
                "label": "Timeline",
                "type": "select",
                "required": False,
                "options": ["ASAP", "Within Month", "Within 3 Months", "Flexible"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "mortgage_status",
                "label": "Mortgage Status",
                "type": "select",
                "required": False,
                "options": ["Pre-Approved", "Pre-Qualified", "In Process", "Cash Buyer", "Not Sure", "Not Applicable"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "current_situation",
                "label": "Current Situation",
                "type": "select",
                "required": False,
                "options": ["First Time", "Upgrading", "Downsizing", "Investment"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "special_requirements",
                "label": "Special Requirements",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 16. Seller Listing Consultation (Real Estate)
    {
        "slug": "seller-listing-consultation",
        "name": "Seller Listing Consultation",
        "description": "Get a free consultation and market analysis for listing your property with us.",
        "category": "Real Estate",
        "is_featured": 0,
        "success_message": "Listing consultation requested! We'll provide a free market analysis and schedule a meeting.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "property_address",
                "label": "Property Address",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 300},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "property_type",
                "label": "Property Type",
                "type": "select",
                "required": True,
                "options": ["Single Family", "Condo", "Townhouse", "Duplex", "Land", "Commercial", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "square_footage",
                "label": "Square Footage",
                "type": "number",
                "required": False,
                "validation": {"min": 0, "max": 100000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "beds_baths",
                "label": "Bedrooms/Bathrooms",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 20},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "year_built",
                "label": "Year Built",
                "type": "number",
                "required": False,
                "validation": {"min": 1800, "max": 2030},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "reason_for_selling",
                "label": "Reason for Selling",
                "type": "select",
                "required": False,
                "options": ["Relocation", "Upgrading", "Downsizing", "Financial", "Investment Sale", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "desired_price",
                "label": "Desired Price Range",
                "type": "select",
                "required": False,
                "options": ["Under $100K", "$100K–$250K", "$250K–$500K", "$500K–$1M", "Over $1M", "Not Sure"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "timeline",
                "label": "Timeline",
                "type": "select",
                "required": False,
                "options": ["ASAP", "Within Month", "Within 3 Months", "Within 6 Months", "Flexible"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "already_have_agent",
                "label": "Already Have an Agent",
                "type": "select",
                "required": True,
                "options": ["Yes", "No"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 17. Client Intake Form (Consulting) — Featured
    {
        "slug": "client-intake-form",
        "name": "Client Intake Form",
        "description": "New client intake form to understand your company, challenges, and goals for consulting.",
        "category": "Consulting",
        "is_featured": 1,
        "success_message": "Intake form submitted! We'll review your information and schedule an initial consultation.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "company",
                "label": "Company",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "company_size",
                "label": "Company Size",
                "type": "select",
                "required": False,
                "options": ["1–10", "11–50", "51–200", "201–1000", "1000+"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "industry",
                "label": "Industry",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "current_challenges",
                "label": "Current Challenges",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "goals",
                "label": "Goals",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "budget_range",
                "label": "Budget Range",
                "type": "select",
                "required": False,
                "options": ["Under $5,000", "$5,000–$15,000", "$15,000–$50,000", "$50,000–$100,000", "Over $100,000", "Not Sure"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "timeline",
                "label": "Timeline",
                "type": "select",
                "required": False,
                "options": ["ASAP", "Within Month", "Within 3 Months", "Within 6 Months", "Flexible"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "referral_source",
                "label": "How Did You Hear About Us",
                "type": "select",
                "required": False,
                "options": ["Google Search", "LinkedIn", "Referral", "Conference", "Advertisement", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "anything_else",
                "label": "Anything Else",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 18. Business Proposal Request (Consulting)
    {
        "slug": "business-proposal-request",
        "name": "Business Proposal Request",
        "description": "Request a tailored business proposal for strategy, operations, marketing, tech, or financial consulting.",
        "category": "Consulting",
        "is_featured": 0,
        "success_message": "Proposal request received! We'll prepare a customized proposal based on your requirements.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "company",
                "label": "Company",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "service_type",
                "label": "Service Type",
                "type": "select",
                "required": True,
                "options": ["Strategy", "Operations", "Marketing", "Tech", "Financial", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "current_situation",
                "label": "Current Situation",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "desired_outcome",
                "label": "Desired Outcome",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "project_scope",
                "label": "Project Scope",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "timeline",
                "label": "Timeline",
                "type": "select",
                "required": False,
                "options": ["ASAP", "Within Month", "Within 3 Months", "Within 6 Months", "Flexible"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "budget_range",
                "label": "Budget Range",
                "type": "select",
                "required": False,
                "options": ["Under $5,000", "$5,000–$15,000", "$15,000–$50,000", "$50,000–$100,000", "Over $100,000", "Not Sure"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "decision_maker",
                "label": "Decision Maker",
                "type": "select",
                "required": True,
                "options": ["Yes", "No"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "competitors",
                "label": "Competitors to Consider",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    # 19. IT Support Ticket (Consulting)
    {
        "slug": "it-support-ticket",
        "name": "IT Support Ticket",
        "description": "Submit a support ticket for hardware, software, network, or security issues.",
        "category": "Consulting",
        "is_featured": 0,
        "success_message": "Support ticket created! We'll review your issue and respond as soon as possible.",
        "field_config": [
            {
                "name": "name",
                "label": "Full Name",
                "type": "text",
                "required": True,
                "validation": {"minLength": 2, "maxLength": 100},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "email",
                "label": "Email Address",
                "type": "email",
                "required": True,
                "validation": {"pattern": "^[^@\\s]+@[^@\\s]+\\.[^@\\s]+$", "maxLength": 255},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "phone",
                "label": "Phone Number",
                "type": "tel",
                "required": True,
                "validation": {"pattern": "^[\\d\\-\\+\\(\\)\\s]{7,20}$"},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "issue_type",
                "label": "Issue Type",
                "type": "select",
                "required": True,
                "options": ["Hardware", "Software", "Network", "Security", "Other"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "device_system",
                "label": "Device/System Affected",
                "type": "text",
                "required": True,
                "validation": {"maxLength": 200},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "error_message",
                "label": "Error Message",
                "type": "text",
                "required": False,
                "validation": {"maxLength": 500},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "steps_tried",
                "label": "Steps Already Tried",
                "type": "textarea",
                "required": False,
                "validation": {"maxLength": 1000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "urgency",
                "label": "Urgency",
                "type": "select",
                "required": True,
                "options": ["Critical", "High", "Medium", "Low"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "description",
                "label": "Description",
                "type": "textarea",
                "required": True,
                "validation": {"minLength": 10, "maxLength": 2000},
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "screenshots_needed",
                "label": "Screenshots Needed",
                "type": "select",
                "required": True,
                "options": ["Yes", "No"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
            {
                "name": "best_time_callback",
                "label": "Best Time to Call Back",
                "type": "select",
                "required": False,
                "options": ["Morning (8am-12pm)", "Afternoon (12pm-5pm)", "Evening (5pm-8pm)", "Any Time"],
                "condition": None,
                "calculation": None,
                "step": 1,
            },
        ],
    },
    
]
