<?php
$podcastin_options = podcastin_theme_options();

$banner_title = $podcastin_options['banner_title'];

$banner_image = $podcastin_options['banner_image'];
$streaming_site_label = $podcastin_options['streaming_site_label'];


$banner_subtext = $podcastin_options['banner_subtext'];
$soundcloud_url = $podcastin_options['soundcloud_url'];
$stitcher_url = $podcastin_options['stitcher_url'];

$banner_btn_text = $podcastin_options['banner_btn_text'];
$banner_button_url = $podcastin_options['banner_button_url'];


if(!empty($banner_image)){
  $background_img = "style='background-image:url(".esc_url($banner_image).")'";
}
else{
  $background_img = '';
}

?>
<div class="banner-section">
		<div class="banner-content">
			<div class="banner-content-wrap">
	  		<?php
	        if ($banner_title):
	            echo '<h1 data-aos="fade-up">' . esc_html($banner_title) . '</h1>';
	        endif;  
				?>
				<?php if($banner_subtext):?><p data-aos="fade-up" class="banner-subtext"><?php echo esc_html($banner_subtext); ?></p><?php endif; 
				if( $banner_btn_text && $banner_button_url):?>
                  <a href="<?php echo esc_url($banner_button_url); ?>" data-aos="fade-up" class="btn-default"><em class="qodef-m-text"><?php echo esc_html($banner_btn_text); ?></em></a>
              <?php endif; ?>


				<div class="follow-banner">
				<p data-aos="fade-up"><?php echo esc_html($streaming_site_label); ?></p>
					<div class="follow-icons" data-aos="fade-up">
						 <?php if($soundcloud_url):?> <a target="_blank" href="<?php echo esc_html($soundcloud_url); ?>"><i class="fa-brands fa-soundcloud"></i><span>Soundcloud</span></a><?php endif; ?>
						<?php if($stitcher_url):?>	<a target="_blank" href="<?php echo esc_html($stitcher_url); ?>"><i class="fa-solid fa-microphone"></i><span>Stitcher</span></a><?php endif; ?>
					</div>
				</div>
			</div>
		</div>

		<div class="banner-img" <?php echo wp_kses_post($background_img); ?>>
		</div>
</div>