"""Public marketing-site request/response schemas."""
from __future__ import annotations

from typing import Literal, Optional
from uuid import UUID

from pydantic import BaseModel, EmailStr, Field

ContactSubject = Literal["general", "support", "sales", "partnership", "feedback"]


class PublicContactRequest(BaseModel):
    first_name: str = Field(..., min_length=1, max_length=80)
    last_name: str = Field(..., min_length=1, max_length=80)
    email: EmailStr
    company: Optional[str] = Field(None, max_length=120)
    subject: ContactSubject
    message: str = Field(..., min_length=10, max_length=5000)
    website: Optional[str] = Field(None, max_length=500)


class PublicContactResponse(BaseModel):
    ok: bool = True
    id: Optional[UUID] = None
