<?php    
/**
 * The header for our theme.
 *
 * This is the template that displays all of the <head> section and everything up until <div id="content">
 *
 * @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
 *
 * @package Luzuk Premium
 */

?><!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
	<meta charset="<?php bloginfo( 'charset' ); ?>">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="profile" href="http://gmpg.org/xfn/11">
	<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
	<script src="https://use.fontawesome.com/18a9c36ed1.js"></script>
	
	<link rel="stylesheet" href="<?php echo get_template_directory_uri(); ?>/css/bootstrap.min.css">
	<link rel="stylesheet" href="<?php echo get_template_directory_uri(); ?>/css/animate.css" />
	<link href="https://fonts.googleapis.com/css?family=Lato:400,700,700i,900,900i&display=swap" rel="stylesheet">
	<script src="<?php echo get_template_directory_uri(); ?>/js/jquery-3.1.1.slim.min.js" crossorigin="anonymous"></script>
	
	<script src="<?php echo get_template_directory_uri(); ?>/js/bootstrap.min.js" type="text/javascript"  ></script>
	<script src="<?php echo get_template_directory_uri(); ?>/js/wow.js" ></script>

	<script>
		function buttonUp(){
			var valux = $('.sb-search-input').val(); 
			valux = $.trim(valux).length;
			if(valux !== 0){
				$('.sb-search-submit').css('z-index','99');
			} else{
				$('.sb-search-input').val(''); 
				$('.sb-search-submit').css('z-index','-999');
			}
		}

		$(document).ready(function(){
			var submitIcon = $('.sb-icon-search');
			var submitInput = $('.sb-search-input');
			var searchBox = $('.sb-search');
			var isOpen = false;

			$(document).mouseup(function(){
				if(isOpen == true){
					submitInput.val('');
					$('.sb-search-submit').css('z-index','-999');
					submitIcon.click();
				}
			});

			submitIcon.mouseup(function(){
				return false;
			});

			searchBox.mouseup(function(){
				return false;
			});

			submitIcon.click(function(){
				if(isOpen == false){
					searchBox.addClass('sb-search-open');
					isOpen = true;
				} else {
					searchBox.removeClass('sb-search-open');
					isOpen = false;
				}
			});

		});
	</script>
	<script>
		$(window).load(function(){
			$(".col-3 input").val("");

			$(".input-effect input").focusout(function(){
				if($(this).val() != ""){
					$(this).addClass("has-content");
				}else{
					$(this).removeClass("has-content");
				}
			})
		});
	</script>
	<?php wp_head(); ?>
</head>

<body <?php body_class(); ?>>
	<div class="main-container">
		<!-- <a class="skip-link screen-reader-text" href="#content"><?php esc_html_e( 'Skip to content', 'Luzuk' ); ?></a> -->
		<div id="loading-area"><div class="la-anim-10"></div></div>
		<!-- header -->
		<header class="site-header header-transparent header mo-left header-seo">
			<?php 
			if( get_theme_mod('pages_logoTpadding',true) ) {
				$pages_logoTpadding = 'padding-top:'.esc_attr(get_theme_mod('pages_logoTpadding')).';';
			}
			if( get_theme_mod('pages_logoBpadding',true) ) {
				$pages_logoBpadding = 'padding-bottom:'.esc_attr(get_theme_mod('pages_logoBpadding')).';';
			}
			if( get_theme_mod('pages_logoLpadding',true) ) {
				$pages_logoLpadding = 'padding-left:'.esc_attr(get_theme_mod('pages_logoLpadding')).';';
			}
			if( get_theme_mod('pages_logoRpadding',true) ) {
				$pages_logoRpadding = 'padding-right:'.esc_attr(get_theme_mod('pages_logoRpadding')).';';
			}
			?>			

			
			
			<div class="col-md-4 col-sm-6 col-xs-8 responsive-logo"> 
				<div class="logobox">
					<?php 
					if ( function_exists( 'has_custom_logo' ) && has_custom_logo() ) :
						the_custom_logo();
				else : 
					if ( is_front_page() ) : ?>
						<h1 class="ht-site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
						<?php else : ?>
							<p class="ht-site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
						<?php endif; ?>
						
					<?php endif; ?>
					
				</div>
			</div>
			<!-- main header -->
			<div class="container">
				<div class="sticky-header main-bar-wraper navbar-expand-lg">
					<div class="main-bar clearfix ">
						<div class="top-bar-head">
							<!-- nav toggle button -->
							<button class="navbar-toggler collapsed navicon justify-content-end" type="button" data-toggle="collapse" data-target="#navbarNavDropdown" aria-controls="navbarNavDropdown" aria-expanded="false" aria-label="Toggle navigation">
								<span></span>
								<span></span>
								<span></span>
							</button>
							<!-- main nav -->

							<?php 
							if( get_theme_mod('pages_BottomHeaderTpadding',true) ) {
								$pages_BottomHeaderTpadding = 'padding-top:'.esc_attr(get_theme_mod('pages_BottomHeaderTpadding')).';';
							}
							if( get_theme_mod('pages_BottomHeaderBpadding',true) ) {
								$pages_BottomHeaderBpadding = 'padding-bottom:'.esc_attr(get_theme_mod('pages_BottomHeaderBpadding')).';';
							}
							if( get_theme_mod('pages_BottomHeaderLpadding',true) ) {
								$pages_BottomHeaderLpadding = 'padding-left:'.esc_attr(get_theme_mod('pages_BottomHeaderLpadding')).';';
							}
							if( get_theme_mod('pages_BottomHeaderRpadding',true) ) {
								$pages_BottomHeaderRpadding = 'padding-right:'.esc_attr(get_theme_mod('pages_BottomHeaderRpadding')).';';
							}
							?>
							<div class="header-nav navbar-collapse collapse justify-content-end" id="navbarNavDropdown" style="<?php echo esc_attr($pages_BottomHeaderTpadding); ?>" "<?php echo esc_attr($pages_BottomHeaderRpadding); ?>" "<?php echo esc_attr($pages_BottomHeaderLpadding); ?>" "<?php echo esc_attr($pages_BottomHeaderRpadding); ?>">

								<ul class="col-md-12 nav navbar-nav wow slideInLeft ">	
									<?php 
									wp_nav_menu( array( 
										'theme_location' => 'primary', 
										'container_class' => 'ht-menu clearfix' ,
										'menu_class' => 'ht-clearfix wow',
										'items_wrap' => '<ul id="%1$s" class="%2$s">%3$s</ul>',
									) ); 
									?>
								</ul>
								
								<!-- for responsive only -->
								<div class="clearfix"></div>
										
								<div class="col-md-12 responsive-header-box">
									<?php
								$facebook = get_theme_mod('header_fb', '//facebook.com/');
								$twitter = get_theme_mod('header_tw', '//twitter.com/');
								$linkedin = get_theme_mod('header_li', 'https://www.linkedin.com/');

								$youtube = get_theme_mod('header_youtube', 'https://www.youtube.com/');
								?>
								<div class="col-md-6 social-btns">
									<?php if(!empty($facebook)){ ?>
										<a href="<?php echo $facebook ?>" class="btn facebook" target="_blank"><i class="fa fa-facebook"></i></a>
									<?php }?>

									<?php if(!empty($twitter)){ ?>
										<a href="<?php echo $twitter ?>" class="btn twitter" target="_blank"><i class="fa fa-twitter"></i></a>
									<?php }?>

									<?php if(!empty($linkedin)){ ?>
										<a href="<?php echo $linkedin ?>" class="btn linkedin" target="_blank"><i class="fa fa-linkedin"></i></a>
									<?php }?>

									<?php if(!empty($youtube)){ ?>
										<a href="<?php echo $youtube ?>" class="btn google" target="_blank"><i class="fa fa-youtube"></i></a>
									<?php }?>

								</div>
								<div class="clearfix"></div>
									<div class="col-md-12 header-icon">
										<?php if( get_theme_mod('headersearch_button','show' ) == 'show') :
									?>
									<div id="sb-search" class="col-md-3 col-sm-10 sb-search col-3">
										<form>
											<input class="sb-search-input effect-12" onkeyup="buttonUp();" placeholder="Search..." onblur="monkey();" type="search" value="" name="s" id="search" />
											<span class="focus-bg"></span>
											<input class="sb-search-submit" type="submit"  value="" />
											<span class="sb-icon-search"><i class="fa fa-search"></i></span>
										</form>
									</div>
								<?php endif ?>
									</div> 
										
								</div>
								<!-- for responsive only -->
							</div>
						</div>
					</div>
				</div>
			</div>

			<div class="top-bar" style="<?php echo esc_attr($pages_logoTpadding); ?>" "<?php echo esc_attr($pages_logoBpadding); ?>" "<?php echo esc_attr($pages_logoLpadding); ?>" "<?php echo esc_attr($pages_logoRpadding); ?>">

				<div class="container">
					<div class="row justify-content-between">
						<div class="dlab-topbar-left">
							<?php

							$email = get_theme_mod('headermain_email', 'info@youremailid.com');	
							?>	
							
							<?php 
							if( get_theme_mod('pages_logoboxtoppostionset',true) ) {
								$pages_logoboxtoppostionset = 'top:'.esc_attr(get_theme_mod('pages_logoboxtoppostionset')).';';
							}

							?>
							<div class="col-md-6 col-sm-6 col-xs-8 logo padding0"> 


								<div class="logobox" style="<?php echo esc_attr($pages_logoboxtoppostionset); ?>">

									<?php 
									if ( function_exists( 'has_custom_logo' ) && has_custom_logo() ) :
										the_custom_logo();
								else : 
									if ( is_front_page() ) : ?>
										<h1 class="ht-site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
										<?php else : ?>
											<p class="ht-site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
										<?php endif; ?>

									<?php endif; ?>

								</div>


								<p class="ht-site-description"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'description' ); ?></a></p> 
							</div>			
							<div class="col-md-5 col-md-offset-1 header-right-bx padding0">
								<?php
								$facebook = get_theme_mod('header_fb', '//facebook.com/');
								$twitter = get_theme_mod('header_tw', '//twitter.com/');
								$linkedin = get_theme_mod('header_li', 'https://www.linkedin.com/');

								$youtube = get_theme_mod('header_youtube', 'https://www.youtube.com/');
								?>
								<div class="col-md-5 social-btns padding0">
									<?php if(!empty($facebook)){ ?>
										<a href="<?php echo $facebook ?>" class="btn facebook" target="_blank"><i class="fa fa-facebook"></i></a>
									<?php }?>

									<?php if(!empty($twitter)){ ?>
										<a href="<?php echo $twitter ?>" class="btn twitter"  target="_blank"><i class="fa fa-twitter"></i></a>
									<?php }?>

									<?php if(!empty($linkedin)){ ?>
										<a href="<?php echo $linkedin ?>" class="btn linkedin"  target="_blank"><i class="fa fa-linkedin"></i></a>
									<?php }?>

									<?php if(!empty($youtube)){ ?>
										<a href="<?php echo $youtube ?>" class="btn google" target="_blank"><i class="fa fa-youtube"></i></a>
									<?php }?>

								</div>


								<div class="col-md-7 col-sm-12">

										<?php if( get_theme_mod('headersearch_button','show' ) == 'show') :
									?>
									<div id="sb-search" class="sb-search col-3">
										<form>
											<input class="sb-search-input effect-12" onkeyup="buttonUp();" placeholder="Search..." onblur="monkey();" type="search" value="" name="s" id="search" />
											<span class="focus-bg"></span>
											<input class="sb-search-submit" type="submit"  value="" />
											<span class="sb-icon-search"><i class="fa fa-search"></i></span>
										</form>
									</div>
								<?php endif ?>

								</div>
							</div>
							<div class="clearfix"></div>
						</div>
						
					</div>
				</div>
			</div>
			<!-- main header END -->
			<div class="clearfix"></div>
		</header><!-- #masthead -->
	</div>
