export interface Payee1099ListItem {
  id: number; legalName: string; displayName?: string;
  memberId?: number; memberName?: string; taxClassification: string;
  is1099Tracked: boolean; tinType?: string; tinLast4?: string;
  w9Status: string; isActive: boolean;
}

export interface Payee1099 extends Payee1099ListItem {
  addressLine1?: string; addressLine2?: string; city?: string; state?: string; zip?: string;
  email?: string; phone?: string; w9ReceivedDate?: string; hasW9Document: boolean; notes?: string;
}

export interface SavePayee1099Request {
  legalName: string; displayName?: string; memberId?: number | null;
  taxClassification: string; is1099Tracked: boolean;
  tinType?: string; tin?: string | null;
  addressLine1?: string; addressLine2?: string; city?: string; state?: string; zip?: string;
  email?: string; phone?: string; w9Status: string; w9ReceivedDate?: string | null;
  isActive: boolean; notes?: string;
}

export interface Form1099Box {
  id: number; boxCode: string; name_en: string; name_zh?: string; formType: string; sortOrder: number;
}

export interface Form1099RecipientRow {
  payeeId: number; legalName: string; tinLast4?: string; w9Status: string;
  necTotal: number; rentsTotal: number; grandTotal: number; meetsThreshold: boolean; w9Missing: boolean;
}

export interface Form1099Summary {
  taxYear: number; rows: Form1099RecipientRow[];
  totalReportable: number; recipientsAtThreshold: number; recipientsMissingW9: number;
}

export interface Form1099Payment {
  paidDate: string; description: string; categoryName: string; boxCode: string; amount: number;
}

export interface Form1099RecipientDetail {
  payeeId: number; legalName: string; tinLast4?: string; w9Status: string;
  taxYear: number; payments: Form1099Payment[];
}
