<?php
?><!DOCTYPE html>
<html <?php language_attributes(); ?> class="no-js no-svg">
<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">
<?php wp_head(); ?>

</head>
		


<body <?php body_class(); ?>>



<div class="headerf">

<div class="header-one">
<div class="size">
<div class="header-one-1">
<span><i class="mdi mdi-email-outline"></i><?php echo get_option('headimg'); ?></span>
<span><i class="mdi mdi-phone-classic"></i><?php echo get_option('headimgf'); ?></span>
</div>
<div class="header-one-2">
<?php wp_nav_menu( array( 'theme_location' => 'header-menu1' ) ); ?> 

</div>
</div>
</div>
<div class="header-two">

<div class="size">
<a class="logo" href="<?php echo home_url() ?>">
<img src="<?php echo get_option('logolink'); ?>">
</a>
<div class="searchnav mobin">
          <form class="search" method="get" action="<?php bloginfo('url'); ?>">
<input type="text" placeholder="دنبال چی هستی؟
" onfocus="if (this.value == '') {this.value = '';}" onblur="if (this.value == '') {this.value = '';}" name="s" class="text">

<button type="submit" class="submit icon-search"><i class="mdi mdi-magnify"></i></button>
<input type="hidden" name="post_type" value="product" />
</form>

</div>
<div class="searchnav mobin1">
<?php echo do_shortcode('[wcas-search-form]'); ?>

</div>
<div class="left-header-box">

<?php if ( is_user_logged_in() ) { ?>


<div class="left-rr-user kkj-33434">
<i class="mdi mdi-account-outline"></i>
حساب کاربری
<div class="user-meta">
<a href="<?php echo home_url() ?>/my-account/"><i class="mdi mdi-view-dashboard-outline"></i>پنل کاربری </a>
<a href="<?php echo home_url() ?>/my-account/edit-account/"><i class="mdi mdi-account-outline"></i>ویرایش حساب کاربری </a>
<a href="<?php echo home_url() ?>/my-account/orders/"><i class="mdi mdi-card-bulleted-outline"></i> سفارش های شما </a>
<a href="<?php echo home_url() ?>/my-account/mywishlist/"><i class="mdi mdi-heart"></i> علاقه مندی های شما </a>

<div class="log-111">

<a  href="<?php echo home_url() ?>/my-account/customer-logout/"> <i class="mdi mdi-account-arrow-left-outline"></i>خروج از سایت </a>

</div>
</div>
</div>


 <?php } 
 else { ?>
 <a href="<?php echo home_url() ?>/my-account/" class="left-rr-user">
<i class="mdi mdi-account-outline"></i>ورود و عضویت
</a>
 <?php } ?>

<span href="#" class="left-sabad etela trybut">
<i class="mdi mdi-information-outline"></i>

<div class="box-etel">

<?php $args=array('post_type'=>'elai','posts_per_page'=>10,'orderby'=>'id');
	$loop = new WP_Query($args); while($loop->have_posts()) : $loop->the_post();  ?>

	<a class="elktwo" href="<?php the_permalink(); ?>">
	<div class="elk-1">
	<h3><?php the_title(); ?></h3> 
	

	</div>
	
	</a>

	<?php endwhile; wp_reset_query(); ?>
	</div>
</span>
<span  class="left-sabad min-car-6">
<i class="mdi mdi-basket"></i><span><div class="header-cart-count"><?php echo WC()->cart->get_cart_contents_count(); ?></div></span>
<div class="mini-cart-3">

<div class="widget_shopping_cart_content"><?php woocommerce_mini_cart(); ?></div> </div>
</span>
<a class="left-sabad menu-resp" onclick="openNav()">
<i class="mdi mdi-menu"></i>
</a>

</div>
</div>

</div>

<div class="header-three">
<div class="size">

<div class="header-three-1">

<div class="menu-header">
<?php wp_nav_menu( array( 'theme_location' => 'header-menu' ) ); ?> 

</div>
	     <?php if((get_option('bargtwo') == true )): ?>

<div class="menu-offer">
<a class="dakhel-offer-12" href="<?php echo get_option('ln1'); ?>"><i class="mdi mdi-octagram-outline"></i><?php echo get_option('ln2'); ?></a>
</div><?php endif; ?>
</div></div>
</div>
</div>
      <script type="text/javascript">   $('document').ready(function () {   $(".kkj-33434").click(function(){    $('.user-meta').slideToggle('slow');   });   });
</script>

      <script type="text/javascript">   $('document').ready(function () {   $(".trybut").click(function(){    $('.box-etel').slideToggle('slow');   });   });
</script>



<div id="mySidenav" class="sidenav">
  <a href="javascript:void(0)" class="closebtn" onclick="closeNav()">&times;</a>
<div class="mob-1"> 
          <form class="search" method="get" action="<?php bloginfo('url'); ?>">
<input type="text" placeholder="دنبال چی هستی؟
" onfocus="if (this.value == '') {this.value = '';}" onblur="if (this.value == '') {this.value = '';}" name="s" class="text">

<button type="submit" class="submit icon-search"><i class="mdi mdi-magnify"></i></button>
<input type="hidden" name="post_type" value="product" />
</form>

</div>
<div class="mobile-menu-1">
 <?php 
                        $defaults = array(
                            'theme_location' => 'header-menu',
                            'menu' => '',
                            'container' => '',
                            'container_class' => '',
                            'container_id' => '',
                            'menu_class' => 'main_menu',
                            'menu_id' => '',
                            'echo' => true,
                            'fallback_cb' => 'wp_page_menu',
							    'add_li_class'  => 'accordion',
                            'before' => '',
                            'after' => '',
                            'link_before' => '',
                            'link_after' => ' ',
                            'items_wrap' => '<ul id="header_main_nav" class="nav header-nav header-bottom-nav nav-center  nav-uppercase">%3$s</ul>',
                            'depth' => 0,
                            'walker' => ''
                            );
                        wp_nav_menu($defaults);
                    ?>
</div></div>
 <script>
/* Set the width of the side navigation to 250px */
function openNav() {
  document.getElementById("mySidenav").style.width = "300px";
}

/* Set the width of the side navigation to 0 */
function closeNav() {
  document.getElementById("mySidenav").style.width = "0";
} 
</script>