<?php
/**
 * The template for displaying the footer.
 *
 * Contains the closing of the #content div and all content after
 *
 * @package icyNETS Simplic
 */
//$col = '';
if ( is_active_sidebar( 'footer-1' ) && !is_active_sidebar( 'footer 2' ) && !is_active_sidebar( 'footer 3' ) && !is_active_sidebar( 'footer 4' ) ){
	$col = 'col-md-12';
} elseif ( is_active_sidebar( 'footer 1' ) && is_active_sidebar( 'footer 2' ) && !is_active_sidebar( 'footer 3' ) && !is_active_sidebar( 'footer 4' ) ){
	$col = 'col-md-6';
} elseif ( is_active_sidebar( 'footer 1' ) && is_active_sidebar( 'footer 2' ) && is_active_sidebar( 'footer 3' ) && !is_active_sidebar( 'footer 4' ) ){
	$col = 'col-md-4';
} else {
	$col = 'col-md-3';
}

?>

		
	</div><!--.container-->

	<div class="<?php if ( is_active_sidebar( 'footer-1' ) || is_active_sidebar( 'footer-2' ) || is_active_sidebar( 'footer-3' ) || is_active_sidebar( 'footer-4' ) ) { echo 'foot-top';} ?>">
		<div class="container">			
					<div class="<?php echo $col ; ?>">
						<?php if ( is_active_sidebar( 'footer 1' ) ) : ?>
							<?php dynamic_sidebar( 'footer-1' ); ?>
						<?php endif; ?>
					</div>
					<div class="<?php echo $col ; ?>">
						<?php if ( is_active_sidebar( 'footer 2' ) ) : ?>
							<?php dynamic_sidebar( 'footer-2' ); ?>
						<?php endif; ?>
					</div>
					<div class="<?php echo $col ; ?>">
						<?php if ( is_active_sidebar( 'footer 3' ) ) : ?>
							<?php dynamic_sidebar( 'footer-3' ); ?>
						<?php endif; ?>
					</div>
					<div class="<?php echo $col ; ?>">
						<?php if ( is_active_sidebar( 'footer 4' ) ) : ?>
							<?php dynamic_sidebar( 'footer-4' ); ?>
						<?php endif; ?>
					</div>
		</div>
	</div>
	<footer id="colophon" class="site-footer" role="contentinfo">
	<div class="foot-bottom">
		<div class="container">
			<div class="site-info">
				<?php icynets_simplic_copyright(); ?>	
			</div><!-- .site-info -->
		</div><!-- .container-->
	</div>	
	</footer><!-- #colophon -->
	
	<!--.hide and apply smooth scroll-->
	<a href="#" id="toTop" style="display: block;"> <span id="toTopHover" style="opacity: 1;"> </span></a>
	

<?php wp_footer(); ?>

</body>
</html>
