<?php 
  $ferry_slider_enable = get_theme_mod('ferry_slider_enable',true);
  $slider_post_one = array(get_theme_mod('slider_post_one'));
  $slider_post_two = array(get_theme_mod('slider_post_two'));
  $slider_post_three = array(get_theme_mod('slider_post_three'));
  if($ferry_slider_enable){
  ?>
<!--==================== SLIDER ====================-->
<section class="ferry-slider-warraper">
  <div id="ferry-slider" class="owl-carousel">
	<!--Slider-one-->
	<?php
	if($slider_post_one){ ?>
	<?php
			$slider_query = new WP_Query( array( 'post__in' => $slider_post_one, 'ignore_sticky_posts' => true));
            if( $slider_query->have_posts() ){                
                while( $slider_query->have_posts() ){
                    $slider_query->the_post();	
                    global $post;
        $ferry_url = ferry_get_freatured_image_url($post->ID, 'ferry-slider-full');	
     ?>
      <div class="ferry-slide item" <?php if (!empty($ferry_url)): ?> style="background-image: url('<?php echo esc_url($ferry_url); ?>');" <?php endif; ?> >
      <div class="ferry-slider-inner" style="background:<?php echo esc_html($slider_overlay);?>">
        <div class="container">
            <div class="slide-caption">
              <h1>
                <?php the_title(); ?>
              </h1>
              <div class="description">
                <?php the_content(); ?>
              </div>
          </div>
        </div>
      </div>
    </div>
	<?php } } wp_reset_query(); }?>
	<!-- Slider Two -->
	<?php
	if($slider_post_two){ ?>
	<?php
			$slider_query = new WP_Query( array( 'post__in' => $slider_post_two, 'ignore_sticky_posts' => true));
            if( $slider_query->have_posts() ){                
                while( $slider_query->have_posts() ){
                    $slider_query->the_post();		
                    global $post;
        $ferry_url = ferry_get_freatured_image_url($post->ID, 'ferry-slider-full'); 
     ?>
      <div class="ferry-slide item" <?php if (!empty($ferry_url)): ?> style="background-image: url('<?php echo esc_url($ferry_url); ?>');" <?php endif; ?> >
      <div class="ferry-slider-inner" style="background:<?php echo esc_html($slider_overlay);?>">
        <div class="container">
            <div class="slide-caption">
              <h1>
                <?php the_title(); ?>
              </h1>
              <div class="description">
                <?php the_content(); ?>
              </div>
          </div>
        </div>
      </div>
    </div>
	<?php } } wp_reset_query(); }?>
	
	<!-- Slider Three-->
	<?php
	if($slider_post_three){ ?>
	<?php
			$slider_query = new WP_Query( array( 'post__in' => $slider_post_three, 'ignore_sticky_posts' => true));
            if( $slider_query->have_posts() ){                
                while( $slider_query->have_posts() ){
                    $slider_query->the_post();		
                    global $post;
        $ferry_url = ferry_get_freatured_image_url($post->ID, 'ferry-slider-full'); 
     ?>
      <div class="ferry-slide item" <?php if (!empty($ferry_url)): ?> style="background-image: url('<?php echo esc_url($ferry_url); ?>');" <?php endif; ?> >
      <div class="ferry-slider-inner" style="background:<?php echo esc_html($slider_overlay);?>">
        <div class="container">
            <div class="slide-caption">
              <h1>
                <?php the_title(); ?>
              </h1>
              <div class="description">
                <?php the_content(); ?>
              </div>
          </div>
        </div>
      </div>
    </div>
	<?php } } wp_reset_query(); }?>
  </div>
</section>
<?php } ?>
<div class="clearfix"></div>