Generated on: {{ $generated_at }}
Date Range: {{ $filters['dateRange'] ?? 'All Dates' }}
Company Name
Position
Qualification
Work Experience
Salary
Vacants
@php
// ✅ Group vacancies by category and sort alphabetically (same as PDF)
$groupedVacancies = $vacancies
->sortBy(fn($job) => $job->category->name ?? 'Unknown')
->groupBy(fn($job) => $job->category->name ?? 'Uncategorized');
// ✅ Compute grand total of available vacancies
$grandTotal = $vacancies->sum('available');
@endphp
@forelse ($groupedVacancies as $categoryName => $jobs)