<?php
$options = _WSH()->option();
$upper_area = buildark_set( $options, 'show_upper_header2' );
$logo = buildark_set( $options, 'logo_image_2' );
$logo = ( $logo ) ? $logo : get_template_directory_uri() . '/assets/images/footer-logo.svg';
$portfolio_media1 = buildark_set( $options, 'portfolio_media' );
$portfolio_media = buildark_set( $portfolio_media1, 'portfolio_media' );
$quote = buildark_set( $options, 'header2_quote_link' );

if ( $upper_area ) :
?>

<!--Header-Upper-->
<div class="header-upper">
	<div class="auto-container">
		<div class="clearfix">

			<div class="pull-left logo-outer">
				<?php if($logo):?>
                <div class="logo"><a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php echo esc_url( $logo );  ?>" alt="<?php esc_attr_e('Awesome Image', 'buildark'); ?>"></a></div>
				<?php else:?>
                <div class="logo"><a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php echo esc_url(get_template_directory_uri()). '/assets/images/footer-logo.svg';  ?>" alt="<?php esc_attr_e('Awesome Image', 'buildark'); ?>"></a></div>
                <?php endif;?>
            </div>

			<div class="pull-right upper-right clearfix">
				
				
				<?php if ( $portfolio_media ) :  ?>	
			
				<?php foreach ( $portfolio_media as $portfolio ) :
				
						if ( isset( $portfolio['tocopy' ] ) ) continue;

									$value = buildark_set( $portfolio, 'portfolio_desc1');

									$icon = buildark_set( $portfolio, 'portfolio_icon');
				
									$title = buildark_set( $portfolio, 'portfolio_title1');
				
				?>
					<!--Info Box-->
					<div class="upper-column info-box">
						<div class="icon-box"><span class="<?php echo esc_attr( $icon ); ?>"></span></div>
						<ul>
							<li><strong><?php echo wp_kses_post( $title ); ?> </strong></li>
							<li><?php echo wp_kses_post( $value ); ?></li>
						</ul>
					</div>
					
					
				<?php endforeach; ?>
				
			<?php endif; ?>
			
			<?php if ( $quote ) :  ?>			
			
				<!--Info Box-->
				<div class="upper-column info-box">
					<a href="<?php echo esc_url( $quote ); ?>" class="theme-btn btn-style-one"><?php esc_html_e( 'Request a Quote', 'buildark' );  ?></a>
				</div>
				
			<?php endif; ?>

			</div>

		</div>
	</div>
</div>
<!--End Header Upper-->


<?php endif; ?>