<?php
// app/init.php
if (session_status() === PHP_SESSION_NONE) session_start();

require_once __DIR__ . '/helpers.php';
require_once __DIR__ . '/db.php';

// simple auth guard
if (!isset($_SESSION['user_id']) || !isset($_SESSION['company_id'])) {
  header('Location: /auth/login.php');
  exit;
}
