<?php get_header(); 
$dance_studio_lite_custom_sidebar_post_layout = get_theme_mod('dance_studio_lite_custom_sidebar_post_layout', 'singleleft');
?>
<style>
<?php
$csscovers = 'col-md-8 col-lg-8 col-sm-12';
    if( $dance_studio_lite_custom_sidebar_post_layout == 'singleright'){
        echo '#sidebar { float:right !important; }'; 
    }
?>
</style>


<?php 
    if($dance_studio_lite_custom_sidebar_post_layout == 'sitefull'){
        $csscovers = "col-md-12 col-lg-12 col-sm-12";
    } 
?>
<div class="container" id="contentdiv">
    <div class="row">
    <?php 
        if($dance_studio_lite_custom_sidebar_post_layout != 'nosidebar' && $dance_studio_lite_custom_sidebar_post_layout != 'sitefull'){
           ?>
           <div class="col-md-4 col-lg-4 col-sm-12" id="sidebar">
                <?php get_sidebar(); ?>
            </div><!--col-md-4-->
           <?php
        } 
    ?>
        <div class="<?php echo esc_attr($csscovers); ?> site-main">
            <div class="pagelayout_area">
                <section class="site-maincontentarea">
                    <?php while (have_posts()) : the_post(); ?>
                        <?php get_template_part('template', 'contentsingle'); ?>
                        <?php the_post_navigation(); ?>
                        <?php
                        if (comments_open() || get_comments_number()) :
                            comments_template();
                        endif;
                        ?>
                    <?php endwhile; // end of the loop.  
                    ?>
                </section>
            </div><!--pagelayout_area-->
        </div><!--col-md-8 site-main-->
        <div class="clear"></div>
    </div><!-- row -->
</div><!-- container -->
<?php get_footer(); ?>