<?php echo $this->getChildHtml('sticky.nav') ?>
<?php
    $store = Mage::app()->getStore();
    $code  = $store->getCode();
    $custom_block = Mage::getStoreConfig('porto_settings/header/static_block', $code);
?>
<div class="header-container type13 <?php if(Mage::getStoreConfig('porto_settings/header/new_skin', $code)): ?>header-newskin<?php endif; ?>">
    <div class="top-links-container">
        <div class="top-links container">
            <div class="search-area">
                <a href="javascript:void(0)" class="search-icon"><i class="icon-search"></i>&nbsp;<span><?php echo $this->__("Search"); ?></span></a>
                <?php echo $this->getChildHtml('topSearch'); ?>
            </div>
            <?php
                $store_currency = $this->getChildHtml('store_currency');
                $store_language = $this->getChildHtml('store_language');
                $compare_link = $this->getChildHtml('compare_link');
            ?>
            <?php if(!Mage::getStoreConfig('porto_settings/header/new_skin', $code)): ?>
                <?php if($store_currency || $store_language || $compare_link):?>
                <span class="split"></span>
                <?php endif; ?>
            <?php endif; ?>
            <?php echo $store_currency; ?>
            <?php if(!Mage::getStoreConfig('porto_settings/header/new_skin', $code)): ?>
                <?php if($store_currency && $store_language):?>
                <span class="split"></span>
                <?php endif; ?>
            <?php endif; ?>
            <?php echo $store_language; ?>
            <?php if(!Mage::getStoreConfig('porto_settings/header/new_skin', $code)): ?>
                <?php if(($store_currency || $store_language) && $compare_link):?>
                <span class="split"></span>
                <?php endif; ?>
            <?php endif; ?>
            <?php echo $compare_link; ?>
            <div class="cart-area">
                <?php echo $this->getChildHtml('minicart'); ?>
            </div>
            <?php if(!Mage::getStoreConfig('porto_settings/header/new_skin', $code)): ?>
                <span class="split f-right"></span>
                <div class="top-links-area">
                    <div class="top-links-icon"><a href="javascript:void(0)"><?php echo $this->__("links"); ?></a></div>
                    <?php echo $this->getChildHtml('topLinks'); ?>
                </div>
                <span class="split f-right"></span>
                <p class="welcome-msg"><?php echo $this->getChildHtml('welcome'); ?> <?php echo $this->getAdditionalHtml(); ?></p>
                <div class="menu-icon f-right"><span class="split f-right"></span><a href="javascript:void(0)" title="<?php echo $this->__('Menu'); ?>"><i class="fa fa-bars"></i></a></div>
            <?php else: ?>
                <div class="top-links-area">
                    <div class="top-links-icon"><a href="javascript:void(0)"><?php echo $this->__("links"); ?></a></div>
                    <?php echo $this->getChildHtml('topLinks'); ?>
                </div>
                <?php
                $custom_block = Mage::getStoreConfig('porto_settings/header/static_block', $code);
                ?>
                <?php echo '<div class="custom-block">'.$this->getLayout()->createBlock('cms/block')->setBlockId($custom_block)->toHtml().'</div>'; ?>
                <div class="menu-icon f-right"><a href="javascript:void(0)" title="<?php echo $this->__('Menu'); ?>"><i class="fa fa-bars"></i></a></div>
            <?php endif; ?>
            <div class="clearer"></div>
        </div>
    </div>
    <div class="header container">
        <?php if ($this->getIsHomePage()):?>
        <h1 class="logo"><strong><?php echo $this->getLogoAlt(); ?></strong><a href="<?php echo $this->getUrl(''); ?>" title="<?php echo $this->getLogoAlt(); ?>" class="logo"><img src="<?php echo $this->getLogoSrc(); ?>" alt="<?php echo $this->getLogoAlt(); ?>" /></a></h1>
        <?php else:?>
        <a href="<?php echo $this->getUrl(''); ?>" title="<?php echo $this->getLogoAlt(); ?>" class="logo"><strong><?php echo $this->getLogoAlt(); ?></strong><img src="<?php echo $this->getLogoSrc(); ?>" alt="<?php echo $this->getLogoAlt(); ?>" /></a>
        <?php endif; ?>
        <?php echo $this->getChildHtml('topMenu') ?>
        <?php echo $this->getChildHtml("demo_header_tooltip"); ?>
    </div>
</div>
<?php echo $this->getChildHtml('mobile.nav') ?>