<?php
/**
 * The template part for Top Header
 *
 * @package Laundry Business 
 * @subpackage laundry-business
 * @since laundry-business 1.0
 */
?>

<div class="main-header <?php if( get_theme_mod( 'laundry_business_sticky_header', false) == 1 || get_theme_mod( 'laundry_business_stickyheader_hide_show', false) == 1) { ?> header-sticky"<?php } else { ?>close-sticky <?php } ?>">
  <div class="main-topbar py-2 wow fadeInDown">
    <div class="container">
      <div class="row">
        <div class="col-xxl-2 col-xl-2 col-lg-2 col-md-4 col-sm-5 col-6 align-self-center header-left-box">
          <div class="laundry-business-logo pb-0 pb-md-0">
            <?php if ( has_custom_logo() ) : ?>
              <div class="site-logo"><?php the_custom_logo(); ?></div>
            <?php endif; ?>
            <?php $laundry_business_blog_info = get_bloginfo( 'name' ); ?>
              <?php if ( ! empty( $laundry_business_blog_info ) ) : ?>
                <?php if ( is_front_page() && is_home() ) : ?>
                  <?php if( get_theme_mod('laundry_business_logo_title_hide_show',true) == 1){ ?>
                    <p class="site-title mb-0 text-start"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
                  <?php } ?>
                <?php else : ?>
                  <?php if( get_theme_mod('laundry_business_logo_title_hide_show',true) == 1){ ?>
                    <p class="site-title mb-0 text-start"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
                  <?php } ?>
                <?php endif; ?>
              <?php endif; ?>
              <?php
                $laundry_business_description = get_bloginfo( 'description', 'display' );
                if ( $laundry_business_description || is_customize_preview() ) :
              ?>
              <?php if( get_theme_mod('laundry_business_tagline_hide_show',false) == 1){ ?>
                <p class="site-description mb-0 text-start">
                  <?php echo esc_html($laundry_business_description); ?>
                </p>
              <?php } ?>
            <?php endif; ?>
          </div>
        </div>
        <div class="col-xxl-8 col-xl-8 col-lg-7 col-md-4 col-sm-2 col-6 align-self-center d-flex justify-content-between align-items-center header-mid-box">
          <?php get_template_part('template-parts/header/navigation'); ?>
        </div>
        <div class="col-xxl-2 col-xl-2 col-lg-3 col-md-4 col-sm-5 col-12 align-self-center d-flex justify-content-between header-right-box">
          <?php if (get_theme_mod('laundry_business_search_hide_show', true)){ ?>
            <div class="search-box">
              <span><a href="#"><i class='<?php echo esc_attr(get_theme_mod('laundry_business_search_open_icon','fas fa-search')); ?>'></i></a></span>
            </div>
            <div class="serach_outer">
              <div class="closepop"><a href="#maincontent"><i class="<?php echo esc_attr(get_theme_mod('laundry_business_search_close_icon','fa fa-window-close')); ?>"></i></a></div>
              <div class="serach_inner">
                <?php get_search_form(); ?>
              </div>
            </div>
          <?php } ?>
          <?php if ( get_theme_mod('laundry_business_header_button_label') != '') {?>
            <div class ="header-btn">
              <a href="<?php echo esc_url(get_theme_mod('laundry_business_header_button_url'));?>" class="text-capitalize"><?php echo esc_html(get_theme_mod('laundry_business_header_button_label'));?>
              </a>
            </div>
          <?php }?>
        </div>
      </div>
    </div>
  </div>
</div>