<?php
if (!defined('ABSPATH')) {
    exit; // Exit if accessed directly.
}
get_header();

?>
<section id="archive-content" class="d-flex block-at-md contained">
    <main>
        <?php if (have_posts()) :
            while (have_posts()) :
                the_post();
                if (is_category('news')) get_template_part('templates/loops/news', 'item');
                else get_template_part('templates/loops/item', 'content');
            endwhile;
        endif;
        ?>
    </main> 
    <?php if (is_active_sidebar('blog-sidebar')) : ?>
        <aside>
            <?php get_sidebar(); ?>
        </aside>
    <?php endif; ?>
</section>
<?php get_footer(); ?>