<?php if($events->isEmpty()): ?>
    <?php if (isset($component)) { $__componentOriginal074a021b9d42f490272b5eefda63257c = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginal074a021b9d42f490272b5eefda63257c = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.empty-state','data' => ['title' => 'No upcoming events','message' => 'School events and functions will appear here.']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('empty-state'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['title' => 'No upcoming events','message' => 'School events and functions will appear here.']); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginal074a021b9d42f490272b5eefda63257c)): ?>
<?php $attributes = $__attributesOriginal074a021b9d42f490272b5eefda63257c; ?>
<?php unset($__attributesOriginal074a021b9d42f490272b5eefda63257c); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal074a021b9d42f490272b5eefda63257c)): ?>
<?php $component = $__componentOriginal074a021b9d42f490272b5eefda63257c; ?>
<?php unset($__componentOriginal074a021b9d42f490272b5eefda63257c); ?>
<?php endif; ?>
<?php else: ?>
    <div class="table-wrap"><table><thead><tr><th>Date</th><th>Title</th><th>Type</th><th>Location</th><th>Organizer</th></tr></thead><tbody>
        <?php $__currentLoopData = $events; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $event): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <tr>
                <td><?php echo e($event->starts_at->format('d M Y')); ?><br><span style="color:var(--text3);font-size:12px;"><?php echo e($event->starts_at->format('H:i')); ?></span></td>
                <td><strong><?php echo e($event->title); ?></strong><?php if($event->description): ?><br><span style="color:var(--text2);font-size:13px;"><?php echo e(str($event->description)->limit(80)); ?></span><?php endif; ?></td>
                <td><?php echo e(ucfirst($event->event_type ?? 'event')); ?></td>
                <td><?php echo e($event->location ?? '—'); ?></td>
                <td>
                    <?php if($event->organizer_type === 'student_leadership'): ?>
                        <?php echo e($event->studentOrganizer?->full_name ?? 'Student'); ?>

                        <?php if($event->studentOrganizer?->leadership_role): ?><br><span style="font-size:12px;color:var(--text3);"><?php echo e($eventsService->leadershipLabel($event->studentOrganizer->leadership_role)); ?></span><?php endif; ?>
                    <?php else: ?>
                        Administration
                    <?php endif; ?>
                </td>
            </tr>
        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
    </tbody></table></div>
<?php endif; ?>
<?php /**PATH C:\laragon\www\southend\resources\views\events\_list.blade.php ENDPATH**/ ?>