<?php
/**
 * Header offcanvas navigation
 *
 * @package wpstream-theme
 */

?>
<div class="offcanvas offcanvas-end" tabindex="-1" id="offcanvas-navbar">
	<div class="offcanvas-header">
		<span class="h5 offcanvas-title"><?php esc_html_e( 'Menu', 'hello-wpstream' ); ?></span>
		<button type="button" class="btn-close text-reset" data-bs-dismiss="offcanvas" aria-label="Close">
			<?php echo wpstream_theme_get_svg_icon( 'close.svg' ) ;?>
        </button>
	</div>
	<div class="offcanvas-body wpstream-offcanvas-body">

		<div class="xwraper"">
		<!-- Bootstrap 5 Nav Walker Main Menu -->
		<?php
		wp_nav_menu(
			array(
				'theme_location' => 'main-menu',
				'container'      => false,
				'menu_class'     => '',
				'fallback_cb'    => '__return_false',
				'items_wrap'     => '<ul id="wpstream_theme-navbar" class="navbar-nav %2$s">%3$s</ul>',
				'depth'          => 3,
				'walker'         => new WpStream_Bootstrap_5_Wp_Nav_Menu_Walker(),
			)
		);
		?>

		<?php
		wp_nav_menu(
			array(
				'theme_location' => 'main-menu2',
				'container'      => false,
				'menu_id'	     =>'wpstream_header_type2_menu2_id',
				'menu_class'     => 'wpstream_header_type2_menu2',
				'fallback_cb'    => '__return_false',
				'items_wrap'     => '<ul id="wpstream_theme-navbar2" class="navbar-nav %2$s">%3$s</ul>',
				'depth'          => 3,
				'walker'         => new WpStream_Bootstrap_5_Wp_Nav_Menu_Walker(),
			)
		);
		?>

		<?php
		wp_nav_menu(
			array(
				'theme_location' => 'main-menu3',
				'container'      => false,
				'menu_id'		 => 'wpstream_header_type2_menu3_id',
				'menu_class'     => 'wpstream_header_type2_menu3',
				'fallback_cb'    => '__return_false',
				'items_wrap'     => '<ul id="wpstream_theme-navbar3" class="navbar-nav %2$s">%3$s</ul>',
				'depth'          => 3,
				'walker'         => new WpStream_Bootstrap_5_Wp_Nav_Menu_Walker(),
			)
		);
		?>

		<!-- Top Nav 2 Widget -->
		<?php if ( is_active_sidebar( 'top-nav-2' ) ) : ?>
			<?php dynamic_sidebar( 'top-nav-2' ); ?>
		<?php endif; ?>
</div>

	</div>
</div>