<div id="main_widget_item_categories_dropdown">
	{foreach name=menuLoop item=menu_item_main from=$main_widget_menu_advanced.menu_items[3]}
		{assign var=isNotEmpty value=$main_widget_menu_advanced.counts|@count}

		<div data-rel="{$menu_item_main->id}" class="menu_item menu_item_{$menu_item_main->id} {if $smarty.foreach.menuLoop.first}menu_item_first{/if} {if !$isNotEmpty}isEmpty{/if}" style="width:{if $smarty.foreach.menuLoop.first}{$main_widget_menu_advanced.menu_first_item_width}{else}{$main_widget_menu_advanced.menu_item_width}{/if}px;">
			<a title="{$menu_item_main->name}" name="{$menu_item_main->name}" title="{$menu_item_main->name}" class="menu_top_link {if isset($current_menu_id) && $current_menu_id == $menu_item->id}active{/if}" {if $system_configuration.main_menu_item_clickable || ($system_configuration.main_menu_item_clickable_if_empty && !$isNotEmpty)}href="{$serverProtocol}://{$servername}/{if $menu_item_main->short_uri}{$menu_item_main->short_uri}/{else}index.php?menu_id={$menu_item_main->id}{/if}"{/if}>
				<span>
					{if !$user_lang || $user_lang == $system_configuration.default_system_language || !$menu_item_main->name_en}
						{$menu_item_main->name}
					{else}
						{$menu_item_main->name_en}
					{/if}
				</span>
				<strong class="borderLeft"></strong>
				<strong class="borderRight"></strong>
			</a>
		</div>
	{/foreach}

	<div class="main_navigation_subnav" style="display:none;">
		<div class="subNavRoller">
			{foreach name=menuLoop item=menu_item_main from=$main_widget_menu_advanced.menu_items[3]}
				<div data-rel="{$menu_item_main->id}" class="subbox">
					<div class="subboxScroller">
						{if isset($main_widget_menu_advanced.menu_items[$menu_item_main->id])}
							{assign var=chunkSize value=$main_widget_menu_advanced.counts|@count/3}
							{assign var=chunkSize value=$chunkSize|ceil}
							{assign var=subChunks value=$main_widget_menu_advanced.menu_items[$menu_item_main->id]|array_chunk:$chunkSize}

							{foreach $subChunks as $subChunk}
								<div class="chunkbox">
									{foreach $subChunk as $menu_item}
										<a title="{$menu_item->name}" class="{if isset($current_menu_id) && $current_menu_id == $menu_item->id}active{/if}" href="{$serverProtocol}://{$servername}/{$menu_item_main->short_uri}/{if $menu_item->short_uri}{$menu_item->short_uri}/{else}index.php?menu_id={$menu_item->id}{/if}">
											{if !$user_lang || $user_lang == $system_configuration.default_system_language || !$menu_item->name_en}
												{$menu_item->name}
											{else}
												{$menu_item->name_en}
											{/if}
										</a>
									{/foreach}
								</div>
							{/foreach}
						{/if}
						<br style="clear:left;">
					</div>

					<div class="subboxCover"></div>

					<a href="#" title="Scroll up" class="subboxScrollUp" title="scrollup"><span></span></a>
					<a href="#" title="Scroll down" class="subboxScrollDown" title="scrolldown"><span></span></a>
				</div>
			{/foreach}
			<br style="clear:left;">
		</div>
	</div>


</div>
