<?= $this->extend('layout/email_layout') ?>

<?= $this->section('content') ?>
<h2>🎓 New Student Registered</h2>

<p>
    <strong>Student Name:</strong>
    <?= esc($student['firstname'] ?? '') . ' ' . esc($student['lastname'] ?? '') ?>
</p>

<?php if (!empty($student['parents']) && is_array($student['parents'])): ?>
    <h3>👪 Parent Info</h3>
    <?php $parent = $student['parents']; ?>
    <p>
        <strong>Parent:</strong>
        <?= esc($parent['firstname'] ?? '') . ' ' . esc($parent['lastname'] ?? '') ?>
        <br>
        <strong>Email:</strong>
        <?= esc($parent['email'] ?? 'N/A') ?>
    </p>
<?php endif; ?>

<p>
    The student has just been registered. Please review their information and verify if needed.
</p>
<?= $this->endSection() ?>