<?php
/**
 * The template for displaying the footer
 *
 * @package mediapulse
 * @since 0.1
 */
	if(get_theme_mod('footer_widgets_show','true')==true) { ?>
    <div class="container-fluid bg-light pt-5 px-sm-3 px-md-5">
        <div class="row">
		
			<?php
				if ( is_active_sidebar( 'footer-widget' ) ) {
					dynamic_sidebar( 'footer-widget' );
				} else {
					$mediapulse_widget = get_theme_mod('footer_widget_layout',3);
					$mediapulse_args = array(
						'before_widget' => '<div id="%1$s" class="news-widget col-lg-'.$mediapulse_widget.' col-md-6 mb-5">',
						'after_widget'  => '</div>',
						'before_title'  => '<h4 class="font-weight-bold mb-4">',
						'after_title'   => '</h4>',
					);
					the_widget( 'WP_Widget_Pages', null, $mediapulse_args );
				}
			?>
            
        </div>
    </div>
	<?php } ?>
    <div class="container-fluid bg-subfooter py-3 px-sm-3 px-md-5">
        <p class="m-0 text-center footer-color">
			<?php $mediapulse_footer_url = get_theme_mod('footer_url','#'); 
			$mediapulse_footer_text = get_theme_mod('footer_text','Infigo Software, All Rights Reserved. Designed by Infigo Software'); ?>
            &copy; <a class="font-weight-bold" href="<?php echo esc_url( $mediapulse_footer_url ); ?>"> <?php echo esc_html( $mediapulse_footer_text ); ?> </a>
        </p>
    </div>
	
	<?php
	$mediapulse_scroll_top_enable = get_theme_mod( 'scroll_top_enable', true ); 
	if ( $mediapulse_scroll_top_enable == true ) { ?>
		<a href="#" class="btn btn-dark back-to-top"><i class="fa fa-angle-up"></i></a>
	<?php } 
	wp_footer(); ?>
</body>

</html>