<?php   
/** 
 *
 * @package Luzuk
 */
if(get_theme_mod('lz_fitness_ct_team_section_disable') != 'on' ){ 
	wp_enqueue_script('product-category-slider', get_template_directory_uri().'/js/slider.js', array(), '1.1', true);?>
	<section id="ht-team-section">
		<?php 
		if( get_theme_mod('sec_teamsectionTpadding',true) ) {
			$sec_teamsectionTpadding = 'padding-top:'.esc_attr(get_theme_mod('sec_teamsectionTpadding')).';';
		}
		if( get_theme_mod('sec_teamsectionBpadding',true) ) {
			$sec_teamsectionBpadding = 'padding-bottom:'.esc_attr(get_theme_mod('sec_teamsectionBpadding')).';';
		}
		if( get_theme_mod('sec_teamsectionLpadding',true) ) {
			$sec_teamsectionLpadding = 'padding-left:'.esc_attr(get_theme_mod('sec_teamsectionLpadding')).';';
		}
		if( get_theme_mod('sec_teamsectionRpadding',true) ) {
			$sec_teamsectionRpadding = 'padding-right:'.esc_attr(get_theme_mod('sec_teamsectionRpadding')).';';
		}
		?>
		<div class="lightbox" style="<?php echo esc_attr($sec_teamsectionTpadding); ?>" "<?php echo esc_attr($sec_teamsectionBpadding); ?>" "<?php echo esc_attr($sec_teamsectionLpadding); ?>" "<?php echo esc_attr($sec_teamsectionRpadding); ?>">
			
			<?php			
			$lz_fitness_team_title = get_theme_mod('lz_fitness_team_title', 'Meet Our Teem Members');
			$lz_fitness_team_subtitle = get_theme_mod('lz_fitness_team_subtitle', 'Pet Care Staff');
			?>
			<div class="row">
				<div class="container">
					<?php if($lz_fitness_team_title || $lz_fitness_team_title){ ?>
						<div class="col-md-6 col-md-offset-3 ht-section-title-tagline">
							<div class="team-sec-subheading">
								<?php 
								if(!empty($lz_fitness_team_subtitle))	{
									echo ($lz_fitness_team_subtitle);
								} ?>
							</div>
							<div class="clearfix"></div>
							<h2 class="ht-section-title ct-team-heading">
								<?php 
								if(!empty($lz_fitness_team_title))	{
									echo ($lz_fitness_team_title);
								} ?>
							</h2>
						</div>
					<?php }?>
					<div class="clearfix"></div>
				</div>
			</div>
			<div class="clearfix"></div>
			<div class="container">
				<div class="row">	
					<div class="slider" id="slider">
						<div class="slides" id="slides">	
							<?php 
							$showStatic = true;
							$cols = get_theme_mod('lz_fitness_team_npp_count', 15);
							$cols++;
							switch($cols){
								case 1:
								$colCls = 'col-md-12 col-sm-12 col-xs-12';
								break;
								case 2:
								$colCls = 'col-md-6 col-sm-6 col-xs-12';
								break;
								case 3:
								case 5:
								case 6:
								case 9:
								$colCls = 'col-md-4 col-sm-6 col-xs-12';
								break;
								case 4:
								case 7:
								case 8:
								case 10:
								case 11:
								case 12:
								case 13:
								case 14:
								case 15:
								case 16:
								$colCls = 'col-md-4 col-sm-6 col-xs-12';
								break;
								default:
								$colCls = 'col-md-4 col-sm-6 col-xs-12';
								break;
							}
							for( $i = 1; $i <= $cols; $i++ ){
								$lz_fitness_team_page_id = get_theme_mod('lz_fitness_team_page'.$i); 
								$lz_fitness_team_page_icon = get_theme_mod('lz_fitness_team_page_icon'.$i);
								if($lz_fitness_team_page_id){
									$showStatic = false;
									echo teamShortCode($lz_fitness_team_page_id, $isCustomizer=true, $i);
								}
							}
			// adding the static content
							if($showStatic === true){
								for( $i = 1; $i <= $cols; $i++ ){ ?> 
									<div class="col-md-3 col-sm-6 col-xs-12 slide-item  wow fadeInUp">

										<div class="our-team">
											<div class="pic">
												<img src="<?php echo esc_url(get_template_directory_uri().'/images/team.jpg');?>" alt="Team" />
												<div class="social_media_team">
													<ul class="team_social">
														<li><a target="_blank" href="http://facebook.com"><i class="fa fa-facebook"></i></a></li>
														<li><a target="_blank" href="http://twitter.com"><i class="fa fa-twitter"></i></a></li>
														<li><a target="_blank" href="http://linkedin.com"><i class="fa fa-linkedin"></i></a></li>
														<li><a target="_blank" href="http://instagram.com"><i class="fa fa-instagram"></i></a></li>


													</ul>
												</div>
											</div>
											<div class="shad">
												<div class="team-prof team-profile">
													<h3 class="post-title">Stephen Patterson</h3>
													<p class="post">Senior Groomer</p>
												</div>
											</div>
										</div>


									</div>
									<?php 
								}
							} ?>
						</div>
						<button class="ctrl-btn pro-prev slide-prev"><i class="fa fa-chevron-left"></i></button>
						<button class="ctrl-btn pro-next slide-next"><i class="fa fa-chevron-right"></i></button>
					</div> 
				</div>
			</div>	
			<div class="clearfix"></div>
		</div>
	</section>
	<script>
		jQuery.noConflict();
		$(function(){
			function teamprofHeight(){
				var ht = 0;
				$('section#ht-team-section .team-prof').each(function(i){
					var tHt = $(this).height();
					if(ht<tHt){
						ht=tHt;
					}
				});
				$('section#ht-team-section .team-prof').height(ht+'px');
			}
			teamprofHeight();
		});
		$( window ).resize(function(){
			teamprofHeight();
		});
	</script>

<?php }
