<?= $this->extend('backend/layouts/main') ?>

<?= $this->section('main') ?>
    <div class="bg-white p-8 rounded-lg shadow-md max-w-4xl mx-auto">
        <h3 class="text-2xl font-semibold mb-6 border-b pb-4"><?= lang('Admin/Churches.editChurch', [esc($church->name)]) ?></h3>
        <?= $this->include('backend/layouts/_notifications') ?>
        <?= form_open(route_to('admin.churches.update', $church->id)) ?>
            <?= $this->include('backend/churches/_form') ?>
            <div class="mt-8 flex justify-end gap-4">
                <a href="<?= route_to('admin.churches.index') ?>" class="bg-gray-200 text-gray-800 px-4 py-2 rounded-md hover:bg-gray-300"><?= lang('Admin/Churches.btnCancel') ?></a>
                <button type="submit" class="bg-indigo-600 text-white font-bold px-4 py-2 rounded-md hover:bg-indigo-700"><?= lang('Admin/Churches.btnUpdate') ?></button>
            </div>
        <?= form_close() ?>
    </div>
<?= $this->endSection() ?>