<?php get_header(); ?>
<?php $blog_type = get_theme_mod( 'blog_type' ); ?>

<main class="page-content container_wrap">
    <div class="container">

        <div class="posts-wrap">
        
            <?php if(is_home() && !is_front_page()) { ?>
            <h1 class="page-title"><?php single_post_title(); ?></h1>
            <?php } ?>

            <?php if ( have_posts() ) { ?>
            <div class="posts-loop <?php echo $blog_type ?>">

                <?php while ( have_posts() ) {
                    the_post();
                    get_template_part( 'template-parts/post/content', 'preview' );
                }; ?>

            </div>
            <?php the_posts_pagination();
            } else {
                get_template_part( 'template-parts/post/content', 'none' );
            }; ?>
        
        </div> 
        
        <?php get_sidebar(); ?> 
  
    </div>
</main>
    

<?php get_footer(); ?>