<?php get_header(); 
global $post, $pixomi_data;
$blog_style 	= $pixomi_data['blog_style'];
$header_layout  = pixomi_choose_header(); 
if($blog_style == 'classic'){
	$blog_style_class = 'blog-classic'; } 
elseif($blog_style == 'list'){
	$blog_style_class = 'blog-list'; } 
else{ $blog_style_class = 'blog-classic'; }

// Blog Layout
$blog_layout = $pixomi_data['blog_layout'];
if($blog_layout == 'right_sidebar'){
    $blog_layout_class = 'right-sidebar col-lg-9 col-md-9 col-sm-12'; }
elseif($blog_layout == 'left_sidebar'){
    $blog_layout_class = 'left-sidebar col-lg-9 col-md-9 col-sm-12'; }
elseif($blog_layout == 'fullwidth'){ 
    $blog_layout_class = 'col-xs-12'; }
else{ $blog_layout_class = 'right-sidebar col-lg-9 col-md-9 col-sm-12'; } 

// Header Layout
if($header_layout == '2'){
    $header_class = 'content-modern'; 
} elseif($header_layout == '3'){
    $header_class = 'content-trans'; 
} elseif($header_layout == '5'){
    $header_class = 'content-stack'; 
} else{ $header_class = ''; } ?> 
<div id="main-content" class="<?php echo esc_attr( $header_class ); ?>">
	<div class="container">
		<div class="row">
			<div class="<?php echo esc_attr( $blog_layout_class ); ?>">				
				<div class="main-blog <?php echo esc_attr( $blog_style_class ); ?>">
					<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
						<?php get_template_part( 'content' ) ?>
					<?php endwhile; ?>
					<?php else : ?>
						<?php get_template_part( 'content', 'none' ) ?>
					<?php endif; ?>
					<?php pixomi_pagination(); ?>						
				</div>
			</div>
			<?php if( ($blog_layout != 'fullwidth')){ ?>
            <div id="sidebar" class="col-lg-3 col-md-3 col-sm-12" role="complementary">
                <?php get_sidebar(); ?>
            </div>
            <?php } ?>
		</div>
	</div>
</div>
<?php get_footer(); ?>
