<?php
/**
 * Enterprise HRM ERP System - Database Configuration
 * No hard-coded values - all settings loaded from database
 */

// Prevent direct access
if (!defined('HRM_ACCESS')) {
    die('Direct access not allowed');
}

// Database Configuration
define('DB_HOST', 'localhost');
define('DB_USER', 'root');
define('DB_PASS', '');
define('DB_NAME', 'hrm2');
define('DB_CHARSET', 'utf8mb4');

// Application Configuration
define('APP_NAME', 'Enterprise HRM ERP');
define('APP_VERSION', '1.0.0');
define('BASE_PATH', dirname(dirname(__FILE__)));
define('BASE_URL', '/hrm');

// Session Configuration
define('SESSION_NAME', 'HRM_SESSION');
define('SESSION_LIFETIME', 3600); // Will be overridden by database setting

// Security Configuration
define('PASSWORD_MIN_LENGTH', 8);
define('PASSWORD_REQUIRE_UPPERCASE', true);
define('PASSWORD_REQUIRE_LOWERCASE', true);
define('PASSWORD_REQUIRE_NUMBER', true);
define('PASSWORD_REQUIRE_SPECIAL', true);

// File Upload Configuration
define('UPLOAD_DIR', BASE_PATH . '/uploads');
define('UPLOAD_MAX_SIZE', 5242880); // 5MB
define('ALLOWED_IMAGE_TYPES', ['image/jpeg', 'image/png', 'image/gif']);

// Error Reporting (disable in production)
define('DEBUG_MODE', true);
if (DEBUG_MODE) {
    error_reporting(E_ALL);
    ini_set('display_errors', 1);
} else {
    error_reporting(0);
    ini_set('display_errors', 0);
}

// Timezone
date_default_timezone_set('UTC'); // Will be overridden by database setting

