<?php
/**
* The template for displaying all single posts.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
*
* @package EliteWP WordPress Theme
* @copyright Copyright (C) 2025 ThemesDNA
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later
* @author ThemesDNA <themesdna@gmail.com>
*/

get_header(); ?>

<div class="elitewp-main-wrapper clearfix" id="elitewp-main-wrapper" itemscope="itemscope" itemtype="http://schema.org/Blog" role="main">
<div class="theiaStickySidebar">
<div class="elitewp-main-wrapper-inside clearfix">

<?php elitewp_before_main_content(); ?>

<?php elitewp_top_widgets(); ?>

<div class="elitewp-posts-wrapper" id="elitewp-posts-wrapper">

<?php while (have_posts()) : the_post(); ?>

    <?php get_template_part( 'template-parts/content', 'single' ); ?>

    <?php the_post_navigation(array('prev_text' => esc_html__( '&larr; %title', 'elitewp' ), 'next_text' => esc_html__( '%title &rarr;', 'elitewp' ))); ?>

    <?php
    // If comments are open or we have at least one comment, load up the comment template
    if ( comments_open() || get_comments_number() ) :
            comments_template();
    endif;
    ?>

<?php endwhile; ?>
<div class="clear"></div>

</div><!--/#elitewp-posts-wrapper -->

<?php elitewp_bottom_widgets(); ?>

<?php elitewp_after_main_content(); ?>

</div>
</div>
</div><!-- /#elitewp-main-wrapper -->

<?php get_sidebar(); ?>

<?php get_footer(); ?>