export interface LoginRequest {
  email: string;
  password: string;
}

export interface LoginResponse {
  data: User;
  token: string;
}

export interface RegisterRequest {
  name: string;
  email: string;
  password: string;
  password_confirmation: string;
}

export interface User {
  id: number;
  name: string;
  name_en: string;
  name_ar: string;
  email: string;
  phone: string | null;
  locale: string;
  is_active: boolean;
  company: Company;
  branch?: Branch;
  branches?: Branch[];
  roles: string[];
  permissions: string[];
  created_at: string;
  updated_at: string;
}

export interface Company {
  id: number;
  name: string;
  name_en: string;
  name_ar: string;
  short_name: string | null;
  prefix: string;
  email: string;
  phone: string;
  fax: string | null;
  website: string | null;
  address: string;
  city: string | null;
  country_code: string | null;
  postal_code: string | null;
  tax_number: string | null;
  commercial_register: string | null;
  currency: string;
  locale: string;
  timezone: string;
  fiscal_year_start_month: number;
  logo: string | null;
  is_active: boolean;
  created_at: string;
  updated_at: string;
}

export interface Branch {
  id: number;
  company_id: number;
  name: string;
  name_en: string;
  name_ar: string;
  code: string;
  phone: string | null;
  email: string | null;
  address: string;
  city: string | null;
  country: string;
  is_active: boolean;
  is_main: boolean;
  created_at: string;
  updated_at: string;
}
