<nav class="navbar ym-navbar navbar-default">
    <div class="container">
        <div class="ym-navbar__addition hidden-xs">
            <a href="mailto:<?php echo get_option('admin_email'); ?>"
               title="<?php printf(__('Email %s' ,'base-theme'), get_bloginfo('name')); ?>">
                <i class="fa fa-envelope"></i>
                <?php echo get_option('admin_email'); ?>
            </a>
            <a href="tel:<?php echo preg_replace('/[^\d\+]+/i', '', preg_replace('/\(.+\)/i', '', of_get_option('phone'))); ?>"
               title="<?php printf(__('Bel %s','base-theme'), get_bloginfo('name')); ?>">
                <i class="fa fa-phone"></i>
                <?php echo of_get_option('phone'); ?>
            </a>
        </div>
        <div class="navbar-header">
            <?php $homepage_seo_title = get_seo_title(get_post(get_option('page_on_front'))); ?>
            <a class="navbar-brand" href="<?php echo esc_url(home_url('/')); ?>" title="<?php echo $homepage_seo_title; ?>">
                <?php echo get_company_logo('medium', $homepage_seo_title); ?>
            </a>
            <div class="visible-xs ym-navbar__mobile-button ym-navbar__phone-number">
                <div>
                    <a href="tel:<?php echo preg_replace('/[^\d\+]+/i', '', preg_replace('/\(.+\)/i', '', of_get_option('phone'))); ?>"
                       title="<?php printf(__('Bel %s','base-theme'), get_bloginfo('name')); ?>">
                        <i class="fa fa-phone"></i>
                        <span class="sr-only"><?php echo of_get_option('phone'); ?></span>
                    </a>
                </div>
            </div>
            <div class="visible-xs ym-navbar__mobile-button ym-navbar__email">
                <div>
                    <a href="mailto:<?php echo get_option('admin_email'); ?>"
                       title="<?php printf(__('Email %s','base-theme'), get_bloginfo('name')); ?>">
                        <i class="fa fa-envelope"></i>
                        <span class="sr-only"><?php echo get_option('admin_email'); ?></span>
                    </a>
                </div>
            </div>
            <div class="visible-xs ym-navbar__mobile-button ym-navbar__search-button">
                <div>
                    <a href="<?php echo home_url('/'); ?>?s=" title="<?php _e('Zoeken' ,'base-theme'); ?>">
                        <i class="fa fa-search"></i>
                        <span class="sr-only"><?php _e('Zoeken', 'base-theme'); ?></span>
                    </a>
                </div>
            </div>
            <div class="toggle-button ym-navbar__mobile-button">
                <div>
                    <button type="button" class="navbar-toggle collapsed" data-toggle="collapse"
                            data-target="#ym-navbar__menu" aria-expanded="false">
                        <i class="fa fa-bars" aria-hidden="true"></i>
                        <span class="sr-only"><?php _e('Open het menu', 'base-theme'); ?></span>
                    </button>
                </div>
            </div>
        </div>
        <?php
        if (shortcode_exists('attention-bar')) :
            echo do_shortcode('[attention-bar]');
        endif;

        wp_nav_menu(array(
            'theme_location' => 'navbar',
            'container' => 'div',
            'container_class' => 'collapse navbar-collapse ym-navbar__menu',
            'container_id' => 'ym-navbar__menu',
            'menu_class' => 'nav navbar-nav',
            'fallback_cb' => 'wp_bootstrap_navwalker::fallback',
            'walker' => new \yndenz\Modules\Navigation\NavBootstrap()
        ));
        ?>
    </div>
</nav>