<?php 
 /**
 * Attachment Page
 *
 * @package passport
 * @subpackage passport
 * @since passport v.1.0.
 * 
**/
    get_header();

    $passport_post_content_column	    = get_theme_mod( 'passport_post_main_content', 'main_content' );
	$passport_post_sidebar_position	    = get_theme_mod( 'passport_post_sidebar_position', 'left' );
	$passport_post_sidebar_width		= get_theme_mod( 'passport_post_sidebar_width', 'sidebar_25' ); 
 ?>
<?php if( have_posts() ) : ?>
	<?php while ( have_posts() ) : the_post(); ?>	
		<div id="primary" class="container">
			<div id="wrapper" class="content-column fix-width clearfix">
				<?php 		
					if( 'main_content' == $passport_post_content_column ) : ?>
					<!-- Beginning of Full Width -->
					<div id="content" class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
						<div class="row">
							<div class="post-item">
								<?php echo wp_get_attachment_image( get_the_ID(), 'large-image' ); ?>
								<div class="post-content">
									<?php get_template_part( 'partials/partials', 'header' ); ?>
									<?php get_template_part( 'partials/partials', 'meta' ); ?>	
										<div class="entry-content">	
											<?php the_content(); ?>
											<p class='resolutions'> <?php echo esc_html__( 'Downloads:', 'passport' ); ?> 
												<?php echo passport_download_image(); ?>
											</p>
										</div>
									</div>
								<div class="clear"></div>	
							</div>
						</div>
					</div>
					<?php endif; ?><!-- End of Full Width -->
					<!-- Right sidebar -->
					<?php if( 'sidebar' == $passport_post_content_column )  : ?>
						<?php if( 'right' == $passport_post_sidebar_position ) : ?>						
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								<div id="content" class="col-xs-12 col-sm-12 col-md-9 col-lg-9">
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								<div id="content" class="col-xs-12 col-sm-12 col-md-8 col-lg-8">
							<?php endif; ?><!--End of sidebar width loop -->
									<div class="row">
										<div class="post-item">
											<?php echo wp_get_attachment_image( get_the_ID(), 'large-image' ); ?>
											<div class="post-content">
												<?php get_template_part( 'partials/partials', 'header' ); ?>
												<?php get_template_part( 'partials/partials', 'meta' ); ?>		
												<div class="entry-content">	
													<?php the_content(); ?>
													<p class='resolutions'> <?php echo esc_html__( 'Downloads:', 'passport' ); ?> 
														<?php echo passport_download_image(); ?>
													</p>
												</div>
											</div>
											<div class="clear"></div>	
										</div>
									</div>
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php endif; ?><!--End of sidebar width loop -->
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								<div id="sidebar" class="col-xs-12 col-sm-6 col-md-3 col-lg-3">
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								<div id="sidebar" class="col-xs-12 col-sm-6 col-md-4 col-lg-4">
							<?php endif; ?><!--End of sidebar width loop -->
									<div class="row">
										<div class="right-sidebar">
											<?php get_sidebar(); ?>
										</div>
									</div>
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php endif; ?><!--End of sidebar width loop -->
						<?php endif; ?><!-- End of Right Sidebar -->

						<!-- Left sidebar -->
						<?php if ( 'left' == $passport_post_sidebar_position ) : ?>
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								<div id="sidebar" class="col-xs-12 col-sm-6 col-sm-6 col-md-3 col-lg-3">
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								<div id="sidebar" class="col-xs-12 col-sm-6 col-sm-6 col-md-4 col-lg-4">
							<?php endif; ?><!--End of loop -->
									<div class="row">
										<div class="left-sidebar">
											<?php get_sidebar(); ?>
										</div>
									</div>
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php endif; ?><!--End of loop -->
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								<div id="content" class="col-xs-12 col-sm-12 col-md-9 col-lg-9">
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								<div id="content" class="col-xs-12 col-sm-12 col-md-8 col-lg-8">
							<?php endif; ?><!--End of sidebar width loop -->
								<div class="row">
									<div class="post-item">
										<?php echo wp_get_attachment_image( get_the_ID(), 'large-image' ); ?>
										<div class="post-content">
											<?php get_template_part( 'partials/partials', 'header' ); ?>
											<?php get_template_part( 'partials/partials', 'meta' ); ?>	
											<div class="entry-content">	
												<?php the_content(); ?>
												<p class='resolutions'> <?php echo esc_html__( 'Downloads:', 'passport' ); ?> 
													<?php echo passport_download_image(); ?>
												</p>
											</div>
										</div>
										<div class="clear"></div>	
									</div>
								</div>
							<?php if( 'sidebar_25' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php elseif( 'sidebar_33' == $passport_post_sidebar_width ) : ?>
								</div>
							<?php endif; ?><!--End of sidebar width loop -->
						<?php endif; ?><!-- End of Left Sidebar -->
					<?php endif; ?><!-- End of Loop -->
				</div><!-- #wrapper -->
			</div><!-- #primary -->
		<?php endwhile; ?><!-- End of While Loop --> 
	<?php endif; ?><!-- End of have_posts() --> 
<?php get_footer();