<?php
/**
 * DESCRIPTION: Classic-theme single event — wraps the shared block layout from
 * single-nemtly_event.html in the active theme's header and footer.
 *
 * @package Nemtly_Booking
 */

use NemtlyBooking\Core\Classic_Template_Loader;

if ( ! defined( 'ABSPATH' ) ) {
    exit;
}

get_header();

while ( have_posts() ) :
    the_post();
    ?>
    <main class="nemtly-single-event">
        <?php
        // Block HTML rendered by WordPress core; escaping it would corrupt the markup.
        echo Classic_Template_Loader::render_block_body( 'single-nemtly_event', get_the_ID() ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
        ?>
    </main>
    <?php
endwhile;

get_footer();
