<!-- Start: Header
============================= -->
<?php

$elearning_school_top_twitter_link = get_theme_mod('elearning_school_top_twitter_link');
$elearning_school_top_linkdin_link = get_theme_mod('elearning_school_top_linkdin_link');
$elearning_school_top_youtube_link = get_theme_mod('elearning_school_top_youtube_link');
$elearning_school_top_facebook_link = get_theme_mod('elearning_school_top_facebook_link');
$elearning_school_top_instagram_link = get_theme_mod('elearning_school_top_instagram_link');

$elearning_school_header_register_link = get_theme_mod('elearning_school_header_register_link');
$elearning_school_header_register_text = get_theme_mod('elearning_school_header_register_text');

$elearning_school_header_login_link = get_theme_mod('elearning_school_header_login_link');
$elearning_school_header_login_text = get_theme_mod('elearning_school_header_login_text');

$elearning_school_header_cart_link = get_theme_mod('elearning_school_header_cart_link');
$elearning_school_header_user_link = get_theme_mod('elearning_school_header_user_link');

$elearning_school_header_phone_number = get_theme_mod('elearning_school_header_phone_number');
$elearning_school_header_email_address = get_theme_mod('elearning_school_header_email_address');
$elearning_school_header_location = get_theme_mod('elearning_school_header_location');

$elearning_school_header_button_link = get_theme_mod('elearning_school_header_button_link');
$elearning_school_header_button_text = get_theme_mod('elearning_school_header_button_text');


?>
<div class="main-header-box wow fadeInDown" data-wow-duration="2s">
	<div id="top-header">
		<div class="container">
			<div class="row top-header-box">
				<div class="col-lg-9 col-md-9 align-self-center text-center text-md-start contact-box">
					<?php if ( ! empty( $elearning_school_header_phone_number ) ) : ?>
					<span class="me-3">
						<i class="fa fa-phone me-3" aria-hidden="true"></i>
						<a href="<?php echo esc_url( 'tel:' . preg_replace( '/[^0-9+]/', '', $elearning_school_header_phone_number ) ); ?>">
							<?php echo esc_html( $elearning_school_header_phone_number ); ?>
						</a>
					</span>
				<?php endif; ?>

				<?php if ( ! empty( $elearning_school_header_email_address ) ) : ?>
					<span class="me-3">
						<i class="fa fa-envelope me-3" aria-hidden="true"></i>
						<a href="<?php echo esc_url( 'mailto:' . sanitize_email( $elearning_school_header_email_address ) ); ?>">
							<?php echo esc_html( $elearning_school_header_email_address ); ?>
						</a>
					</span>
				<?php endif; ?>
					<?php if ( ! empty( $elearning_school_header_location ) ): ?>
						<span><i class="fas fa-map-marker me-3" aria-hidden="true"></i><?php echo esc_html( $elearning_school_header_location ); ?></span>
					<?php endif; ?>
				</div>
				<div class="col-lg-3 col-md-3 align-self-center text-center text-md-end">
					<div class="icons-media">
						<?php if ( ! empty( $elearning_school_top_twitter_link ) ): ?>
							<a href="<?php echo esc_url( $elearning_school_top_twitter_link ); ?>"><i class="fa fa-twitter me-2" aria-hidden="true"></i>
							</a>
						<?php endif; ?>
						<?php if ( ! empty( $elearning_school_top_linkdin_link ) ): ?>
							<a href="<?php echo esc_url( $elearning_school_top_linkdin_link ); ?>"><i class="fa fa-linkedin me-2" aria-hidden="true"></i>
							</a>
						<?php endif; ?>
						<?php if ( ! empty( $elearning_school_top_youtube_link ) ): ?>
							<a href="<?php echo esc_url( $elearning_school_top_youtube_link ); ?>"><i class="fa fa-youtube-play me-2" aria-hidden="true"></i>
							</a>
						<?php endif; ?>
						<?php if ( ! empty( $elearning_school_top_facebook_link ) ): ?>
							<a href="<?php echo esc_url( $elearning_school_top_facebook_link ); ?>"><i class="fa fa-facebook me-2" aria-hidden="true"></i>
							</a>
						<?php endif; ?>
						<?php if ( ! empty( $elearning_school_top_instagram_link ) ): ?>
							<a href="<?php echo esc_url( $elearning_school_top_instagram_link ); ?>"><i class="fa fa-instagram me-2" aria-hidden="true"></i>
							</a>
						<?php endif; ?>
					</div>
				</div>
			</div>
		</div>
	</div>
	<header id="header" role="banner" class="nav-stick <?php echo esc_attr(elearning_school_sticky_header()); ?>">
		<div class="container">
			<div class="navbar-area" <?php if ( get_header_image() ) { ?> style="background-image: url( <?php header_image(); ?> ); background-size: 100%;" <?php } ?>>
				<div class="row">
					<div class="col-xl-2 col-lg-3 col-md-4 col-sm-5 col-12 pe-0 logo-box align-self-center">
						<div class="logo main">
							<?php if ( function_exists( 'elearning_school_logo_title_description' ) ) :elearning_school_logo_title_description(); endif; ?>
						</div>
					</div>
					<div class="col-xl-8 col-lg-6 col-md-4 col-sm-2 col-12 p-0 align-self-center">
						<div class="toggle-menu gb_menu text-md-start">
							<button onclick="elearning_school_navigation_open()" class="gb_toggle p-2"><i class="fa fa-bars" aria-hidden="true"></i></button>
						</div>
						<div id="gb_responsive" class="nav side_gb_nav">
							<nav id="top_gb_menu" class="gb_nav_menu" role="navigation" aria-label="<?php esc_attr_e( 'Menu', 'elearning-school' ); ?>">
								<?php 
								    wp_nav_menu( array( 
										'theme_location' => 'primary_menu',
										'container_class' => 'gb_navigation clearfix' ,
										'menu_class' => 'clearfix',
										'items_wrap' => '<ul id="%1$s" class="%2$s mobile_nav mb-0 px-0">%3$s</ul>',
										'fallback_cb' => 'wp_page_menu',
								    ) ); 
								?>
								<a href="javascript:void(0)" class="closebtn gb_menu" onclick="elearning_school_navigation_close()">x<span class="screen-reader-text"><?php esc_html_e('Close Menu','elearning-school'); ?></span></a>
							</nav>
						</div>
					</div>
					<div class="col-xl-2 col-lg-3 col-md-4 col-sm-5 col-12 ps-0 search-box align-self-center">
						<?php if ( ! empty( $elearning_school_header_button_link ) || ! empty( $elearning_school_header_button_text ) ): ?>
							<a class="header-button" href="<?php echo esc_url( $elearning_school_header_button_link ); ?>">
								<?php echo esc_html( $elearning_school_header_button_text ); ?>
							</a>
						<?php endif; ?>
					</div>
				</div>
			</div>
		</div>
	</header>
</div>