/**
 * Shared constants for tOS
 */

export const APP_NAME = 'tOS';
export const APP_DESCRIPTION = 'Enterprise Web Operating System';
export const APP_VERSION = '0.1.0';

export const API_VERSION = 'v1';
export const API_PREFIX = `/api/${API_VERSION}`;

export const DEFAULT_PAGE_SIZE = 20;
export const MAX_PAGE_SIZE = 100;

// Time tracking configuration
export const DEFAULT_BREAK_MINUTES = 30;
export const MIN_BREAK_AFTER_HOURS = 6;
export const REQUIRED_BREAK_MINUTES = 30;
export const MAX_BREAK_AFTER_HOURS = 9;
export const EXTENDED_BREAK_MINUTES = 45;

// Vacation configuration (German law defaults)
export const DEFAULT_VACATION_DAYS = 30;
export const MIN_VACATION_DAYS = 20;

// Working hours configuration
export const STANDARD_WORKING_HOURS_PER_WEEK = 40;
export const STANDARD_WORKING_HOURS_PER_DAY = 8;
export const MAX_WORKING_HOURS_PER_DAY = 10;

// Skill matrix levels
export const SKILL_LEVELS = {
  0: 'No knowledge',
  1: 'Basic understanding',
  2: 'Independent work',
  3: 'Expert',
  4: 'Can train others',
} as const;

export type SkillLevel = keyof typeof SKILL_LEVELS;

// 3S categories (Seiri, Seiton, Seiso)
export const S3_CATEGORIES = {
  SEIRI: 'Sort',
  SEITON: 'Set in Order',
  SEISO: 'Shine',
} as const;

export type S3Category = keyof typeof S3_CATEGORIES;

// Morning meeting SQCDM categories
export const SQCDM_CATEGORIES = {
  S: 'Safety',
  Q: 'Quality',
  C: 'Cost',
  D: 'Delivery',
  M: 'Morale',
} as const;

export type SQCDMCategory = keyof typeof SQCDM_CATEGORIES;

export const HTTP_STATUS = {
  OK: 200,
  CREATED: 201,
  NO_CONTENT: 204,
  BAD_REQUEST: 400,
  UNAUTHORIZED: 401,
  FORBIDDEN: 403,
  NOT_FOUND: 404,
  CONFLICT: 409,
  UNPROCESSABLE_ENTITY: 422,
  INTERNAL_SERVER_ERROR: 500,
  SERVICE_UNAVAILABLE: 503,
} as const;

export const DATE_FORMATS = {
  ISO: 'yyyy-MM-dd',
  DE_SHORT: 'dd.MM.yyyy',
  DE_LONG: 'dd. MMMM yyyy',
  TIME_24H: 'HH:mm',
  DATETIME_DE: 'dd.MM.yyyy HH:mm',
} as const;
