{{include 'head.tpl'}}

	</head>
	<body>
		<svg height="0" width="0" xmlns="http://www.w3.org/2000/svg" style="display: none">
			<filter id="drop-shadow">
				<feGaussianBlur in="SourceAlpha" stdDeviation="5"/>
				<feOffset dx="0" dy="0" result="offsetblur"/>
				<feFlood flood-color="rgba(255,255,255,0.8)"/>
				<feComposite in2="offsetblur" operator="in"/>
				<feMerge>
					<feMergeNode/>
					<feMergeNode in="SourceGraphic"/>
				</feMerge>
			</filter>
		</svg>
		<div class="skiplink"><a href="#body" accesskey="2">{{$lang.Skip_nav}}</a></div>
		{{if $config.newsletter_popup}}
			<div style="display: none;">
				<div id="newsletter_colorbox">
					<img class="logo" src="templates/images/logo.png" alt="logo" />
					<p id="p1">{{$lang.Newsletter_colorbox_1}}</p>
					<p id="p2">{{$lang.Newsletter_colorbox_2}}</p>
					{{if !empty( $config.newsletter_coupon_value )}}<p id="p3">{{str_replace( '%sValue%', $newsletter_value, $lang.Newsletter_colorbox_3 )}}</p>{{/if}}
					<form action="{{$sNewsletterLink}}" method="post">
						<fieldset>
						<input type="email" name="sEmail" style="" placeholder="{{$lang.Newsletter_colorbox_input}}" />
						<input type="submit" id="newsletter_colorbox_colorbox" class="reCaptcha" name="newsletter" value="{{$lang.Newsletter_colorbox_submit}}" />
						</fieldset>
					</form>
					<a href="#" id="newsletter_not_now">{{$lang.Newsletter_colorbox_not_now}}</a>
					<a href="#" id="newsletter_no">{{$lang.Newsletter_colorbox_no}}</a>
				</div>
			</div>
		{{/if}}
		<div id="container">
			<header>
				<div id="head1-wrapper">
				<div id="wrapper">
				<div id="head1">
					<div id="logo">
						<a href="{{$config.index}}" tabindex="1"><img src="{{$config.dir_templates}}images/logo.png" alt="{{$config.title}}" /></a>
					</div>

					{{if isset($sLinkSearch)}}
						<form action="{{$sLinkSearch}}" method="post" class="search-form">
							<fieldset class="search-form">
								<input type="text" name="sPhrase" value="{{$sPhrase}}" id="search1" class="input search_input" placeholder="{{$lang.search_phrase}}" maxlength="100" autocomplete="off" />
								<input type="submit" value="" name="{{$lang.search}}" class="submit" />
							</fieldset>
						</form>
					{{/if}}

					<span class="tablet-clear"></span>

					<div class="user-tools mobile tablet" id="mobile-menu-link-container">
						<a id="mobile-menu-link" href="#">
							{{$lang.Menu}}
						</a>
					</div>
					
					<div class="user-tools">
						<a id="start-link" href="index.html">
							{{$lang.Homepage}}
						</a>
					</div>

					{{if count($aLangs) > 1 || ( is_array( $aLangs ) && $aLangs.0 != $sLang )}}
						<div id="lang-select">
							<form action="" method="get">
								<script type="text/javascript">
									$(function(){
										$('#lang-select-options').change(function(){
											$(this).closest('form').submit();
										});
									});
								</script>
								<select name="sLang" id="lang-select-options">
									{{foreach from=$aLangs item=sLang}}
										<option {{if $config.language == $sLang}}selected="selected"{{/if}} value="{{$sLang}}">{{$sLang}}</option>
									{{/foreach}}
								</select>
							</form>
						</div>
					{{/if}}
					{{if $config.users_plugin_active && !empty( $aMenuLoginInfo ) }}
						<script type="text/javascript">
							$(document).ready(function(){
								$('a#login-ico').click(function(e){
									e.preventDefault();
									$('#login-tool').toggle();
								});
//								$('#login-tool').hide();
							});
						</script>
						<div class="user-tools ico">
							{{if $aMenuLoginInfo.bLogged}}
								<a id="login-link" class="mobile tablet" href="{{$aMenuLoginInfo.sLinkAccount}}">{{$lang.My_account}}</a>
								<a id="login-ico" class="desktop" href="{{$aMenuLoginInfo.sLinkAccount}}" title="{{$lang.My_account}}">{{$lang.My_account}}</a>
							{{else}}
								<a id="login-link" class="mobile tablet" href="{{$aMenuLoginInfo.sLinkLogin}}">{{$lang.My_account}}</a>
								<a id="login-ico" class="desktop" href="{{$aMenuLoginInfo.sLinkLogin}}" title="{{$lang.My_account}}">{{$lang.My_account}}</a>
							{{/if}}
							<nav>
								<ul id="login-tool" style="display: none;">
									{{if isset( $aMenuLoginInfo ) && $aMenuLoginInfo.bLogged}}
										{{if !empty( $aMenuLoginInfo.sLinkProfile )}}<li><a href="{{$aMenuLoginInfo.sLinkProfile}}" rel="nofollow"><img src="upload/75/account.png">{{$lang.Your_profile}}</a></li>{{/if}}
										{{if !empty( $aMenuLoginInfo.sLinkOrders )}}<li><a href="{{$aMenuLoginInfo.sLinkOrders}}" rel="nofollow"><img src="upload/75/order_list.png">{{$lang.Your_Orders}}</a></li>{{/if}}
										{{if !empty( $aMenuLoginInfo.sLinkOrderProducts )}}<li><a href="{{$aMenuLoginInfo.sLinkOrderProducts}}" rel="nofollow"><img src="upload/75/products.png">{{$lang.Ordered_products}}</a></li>{{/if}}
										{{if !empty( $aMenuLoginInfo.sLinkLogout )}}<li><a href="{{$aMenuLoginInfo.sLinkLogout}}" rel="nofollow"><img src="upload/75/logout.png">{{$lang.Logout}}</a></li>{{/if}}
									{{else}}
										<div id="login-register-menu" style="text-align: center;">
											<h2>{{$lang.Order_login_register}}</h2>
											<script type="text/javascript">
												$(document).ready(function(){
													if( $('.menu_select').length > 0 ){
														$('form.menu-form').hide();
														$('.menu_select').change(function(){
															if( $(this).is(':checked') ){
																$('form.menu-form').hide();
																$($(this).val()).show();
															}
														}).first().prop('checked', 'checked').trigger('change');
													}
												});
											</script>
											{{if isset( $aMenuLoginInfo.sLinkLogin ) && isset( $aMenuLoginInfo.sLinkRegister )}}
												<label><input type="radio" class="menu_select" name="menu_register" value="#menu-form-login" /> {{$lang.Login_if_you_have_account}}</label>
												<label><input type="radio" class="menu_select" name="menu_register" value="#menu-form-register" /> {{$lang.Write_login_and_password_to_register}}</label>
											{{/if}}
											<br/>
											{{if isset( $aMenuLoginInfo.sLinkLogin )}}
												<script type="text/javascript">
													/*<![CDATA[*/
													$(document).ready(function(){
														$("form#menu-form-login").validate();
														$("form#menu-form-login #menu-login-login").rules("add", {required: true});
														$("form#menu-form-login #menu-login-password").rules("add", {required: true});
													});
													/*]]>*/
												</script>
												<form action="{{$aMenuLoginInfo.sLinkLogin}}" method="post" id="menu-form-login" class="menu-form">
													<fieldset>
														<input type="hidden" name="bRedirectOrder" value="1" />
														<table>
															<tr><th><label for="menu-login-login">{{$lang.Login}}</label>:</th><td><input id="menu-login-login" type="text" name="sLogin" value="" class="input" maxlength="30" /></td></tr>
															<tr><th><label for="menu-login-password">{{$lang.Password}}</label>:</th><td><input id="menu-login-password" type="password" name="sPass" value="" class="input" maxlength="30" /></td></tr>
															<tr><td colspan="2" class="buttons">
																<input type="submit" value="{{$lang.Log_in}}" class="submit submit-styled" id="menu-login" />
																{{if isset($sFacebookLoginUrl)}}<a href="{{$sFacebookLoginUrl}}" id="fblogin2">{{$lang.Facebook_login}}</a>{{/if}}
															</td></tr>
														</table>
													</fieldset>
												</form>
											{{/if}}
											{{if isset( $aMenuLoginInfo.sLinkRegister )}}
												<script type="text/javascript">
													/*<![CDATA[*/
													$(document).ready(function(){
														$("form#menu-form-register").validate();
														$("form#menu-form-register #menu-register-login").rules("add", {required: true});
														$("form#menu-form-register #menu-register-email").rules("add", {required: true, email: true});
														$("form#menu-form-register #menu-register-password").rules("add", {required: true});
														$("form#menu-form-register #menu-register-password2").rules("add", {required: true, equalTo: "#menu-register-password"});
													});
													/*]]>*/
												</script>
												<form action="{{$aMenuLoginInfo.sLinkRegister}}" method="post" id="menu-form-register" class="menu-form">
													<fieldset>
														<input type="hidden" name="sOption" value="save" />
														<table>
															<tr><th><label for="menu-register-login">{{$lang.Login}}</label>:</th><td><input type="text" name="sLogin" value="" class="input" id="menu-register-login" maxlength="30" /><img class="tTip info" src="templates/images/info.png"  title="{{$lang.tooltip_login}}" alt="{{$lang.tooltip_login}}" /></td>
															</tr><tr>
															<th><label for="menu-register-email">{{$lang.Email}}</label>:</th><td><input type="text" name="sEmail" value="" class="input" id="menu-register-email" maxlength="60" /><img class="tTip info" src="templates/images/info.png"  title="{{$lang.tooltip_email}}" alt="{{$lang.tooltip_email}}" /></td>
															</tr><tr>
															<th><label for="menu-register-password">{{$lang.Password}}</label>:</th><td><input type="password" name="sPass" value="" class="input" id="menu-register-password" maxlength="30" /><img class="tTip info" src="templates/images/info.png"  title="{{$lang.tooltip_pass}}" alt="{{$lang.tooltip_pass}}" /> <a href="#" id="menu-generate"></a></td>
															</tr><tr>
															<th><label for="menu-register-password2">{{$lang.Password_confirm}}</label>:</th><td><input type="password" name="sPass2" value="" class="input" id="menu-register-password2" maxlength="30" /></td>
															</tr>
															
															{{if isset($aMenuLoginInfo.sRulesLink)}}
																<tr id="menu-rules"><td colspan="2">
																	<script type="text/javascript">
																		$(document).ready(function(){
																			$("#menu-rules-accept").rules("add", {required: true, messages: {required: "{{$lang.Require_rules_accept}}"}});
																			$("#menu-rules2-accept").rules("add", {required: true, messages: {required: "{{$lang.Require_rules_accept}}"}});
																			$('a.rule-expand').on( 'click', function( e ){
																				e.preventDefault();
																				$( this ).prev( '.short' ).toggleClass( 'long' );
																				$( this ).text( function( i, text ){
																					return text === "Rozwiń" ? "Zwiń" : "Rozwiń";
																				})
																			});
																		});
																	</script>
																	<input type="checkbox" class="checkbox" name="iRulesAccept" value="1" alt="{{$lang.Require_rules_accept}}" id="menu-rules-accept" />
																	<label class="short" for="menu-rules-accept">{{$lang.Rules_accept}} <a href="{{$aMenuLoginInfo.sRulesLink}}">{{$lang.rules_read}}</a>.</label>
																	<a href="#" class="rule-expand">{{$lang.Expand}}</a>
																</td></tr>
															{{/if}}
															<tr id="menu-rules2"><td colspan="2">
																<input type="checkbox" class="checkbox" name="iRulesAccept2" value="1" alt="{{$lang.Require_rules2_accept}}" id="menu-rules2-accept" />
																<label class="short" for="menu-rules2-accept">{{$lang.Rules2_accept}}</label>
																<a href="#" class="rule-expand">{{$lang.Expand}}</a>
															</td></tr>

															<tr id="menu-newsletter"><td colspan="2">
																<input type="checkbox" class="checkbox" name="iNewsletterAccept" value="1" id="menu-newsletter-accept" />
																<label class="short" for="menu-newsletter-accept">{{$lang.Newsletter_accept}}</label>
																<a href="#" class="rule-expand">{{$lang.Expand}}</a>
															</td></tr>
															<tr>
																<td colspan="2" class="buttons">
																	<input type="submit" value="{{$lang.Register}}" name="sRegister" class="submit submit-styled" id="menu-register" />
																</td>
															</tr>
														</table>
													</fieldset>
												</form>
											{{/if}}
										</div>
									{{/if}}
								</ul>
							</nav>
						</div>
					{{/if}}

					{{if isset($sStoragePageLink)}}
						<div class="user-tools">
							<a id="storage-ico" href="{{$sStoragePageLink}}" rel="nofollow" title="{{$lang.Storage_of_products}}">{{$lang.Storage_of_products}} <span class="ico_info update_storage_products_count" value="{{$iStorageProducts}}">{{$iStorageProducts}}</span></a>
						</div>
					{{/if}}

					{{if isset( $sBasketLink )}}
						<div class="user-tools">
							<a id="basket-ico" href="{{$sBasketLink}}" rel="nofollow" title="{{$lang.Basket}}">
								{{$lang.Basket}} (<span class="update_basket_products_summary">{{$aTopBasketInfo.fOrderSummary}}</span>&nbsp;{{$config.currency_symbol}}) <span class="ico_info update_basket_products_count" value="{{$aTopBasketInfo.iOrderProducts}}">{{$aTopBasketInfo.iOrderProducts}}</span>
							</a>
						</div>
					{{/if}}

					<div class="clear"></div>
				</div><!--#head1-->
				</div><!--wrapper for Paweł bo chciał 100% tła białego-->
				</div><!--#head1-wrapper-->
				<nav class="mobile tablet hide" id="mobile-menu">
					<ul>
						{{foreach from=$aMenusMobile item=sMenuContent}}
							<li>
								{{if $sMenuContent != NULL}}
{{*									<h2>
										{{if $sMenuContent@key == 3}}{{$lang.Menu_main}}{{/if}}
										{{if $sMenuContent@key == 4}}{{$lang.Menu_shop}}{{/if}}
										{{if $sMenuContent@key == 5}}{{$lang.Menu_additional}}{{/if}}
									</h2>*}}
									<hr/>
									{{$sMenuContent}}
								{{/if}}
							</li>
						{{/foreach}}
					</ul>
				</nav>
				{{if $aPage.iBannerTop}}
					{{$aBanners.0}}
				{{/if}}
				<nav id="menu3_nav" class="desktop">
					{{$SMARTY_sMenu3}}
				</nav>
			</header><!--#header-->

			{{**}}
			<div id="main_container">
				<div id="main" {{if $aPage.iColumn < 1}}class="nocolumn"{{/if}}>
					{{if $aPage.iColumn >= 1}}
						<div id="column" class="desktop tablet">
							{{$SMARTY_sMenu4}}

							{{if $config.google_translate_on}}
								<div id="google_translate_element"></div>
							{{/if}}
					
							{{include 'filter_form.tpl' inline}}
					
					
							{{if isset( $sBasketLink )}}
								<div id="basket-small-container" class="desktop">
									{{include 'basket_small_json.tpl'}}
								</div>
							{{/if}}
							{{if $config.fastOrder == true}}
								<div id="basket-fast-container" class="desktop">
									<script type="text/javascript">
										$(document).ready(function(){
											$('#fastbasket').validate();
											$('#fastbasket input, #fastbasket textarea').each(function(){ $(this).rules('add', { required: true }); });
										});
									</script>
									<form action="?p=p_json-fastbasket" method="post" id="fastbasket">
										<fieldset>
										<label>{{$lang.First_and_last_name}} / {{$lang.Company}} <input type="text" name="fo_sName" /></label>
										<label>{{$lang.Street}} <input type="text" name="fo_sStreet" /></label>
										<label class="short">{{$lang.Zip_code}} <input type="text" name="fo_sZipCode" /></label>
										<label class="med">{{$lang.City}} <input type="text" name="fo_sCity" /></label>
										<label class="short">{{$lang.Phone}} <input type="phone" name="fo_sPhone" /></label>
										<label class="med">{{$lang.Email}} <input type="email" name="fo_sEmail" /></label>
										<label>{{$lang.Order_content}} <textarea name="fo_sOrder" rows="" cols=""></textarea></label>
										<input type="submit" id="fastbasket_submit" class="submit submit-styled reCaptcha" value="{{$lang.Speedorder_submit}}" />
										</fieldset>
									</form>
								</div>
							{{/if}}
							{{foreach from=$aBoxes.0 item=aBox}}
								{{$aBox}}
							{{/foreach}}

							{{if !empty( $config.zagiel_id ) }}
								<div class="banner" id="box_zagiel">
								<a href="https://www.santanderconsumer.pl/raty-jak-kupic"><img src="{{$config.dir_templates}}images/zagiel_jak_kupic.gif" alt="{{$lang.Zagiel_how_to}}" /></a>
								</div>
							{{/if}}
								
							{{if $config.gifts}}
								<div class="banner">
									<div class="pack_as_gift_box">{{str_replace( [ '[', ']' ], [ '<strong>', '</strong>' ], $lang.Pack_as_gift_box )}}</div>
								</div>
							{{/if}}

							{{if !empty( $config.LR_psp_id ) }}
								<script type="text/javascript">
								/*<![CDATA[*/
									function LR_Procedura() {
										var iWidth = 820;
										var iHeight = 530;
										var iX = ( screen.availWidth - iWidth ) / 2;
										var iY = ( screen.availHeight - iHeight ) / 2;	
										window.open('https://ewniosek.credit-agricole.pl/eWniosek/procedure.jsp?PARAM_TYPE=RAT&PARAM_PROFILE={{$config.LR_psp_id}}', 'Procedura', 'height='+iHeight+',width='+iWidth+',top='+iY+',left='+iX+',resizable=yes,scrollbars=yes,status=0;');
										return false;
									}
								/*]]>*/
								</script>
								<div class="banner" id="box_LR">
									<a onClick="return LR_Procedura()" href="https://ewniosek.credit-agricole.pl/eWniosek/procedure.jsp?PARAM_TYPE=RAT&PARAM_PROFILE={{$config.LR_psp_id}}"><img src="https://ewniosek.credit-agricole.pl/eWniosek/res/CA_grafika/raty_{{$config.LR_logo_size}}_{{$config.LR_logo_color}}.png" alt="{{$lang.LR_name}}" /></a>
								</div>
							{{/if}}

							{{$aBanners.1}}
						</div><!-- #column -->
					{{/if}}


					<div id="content">
						{{$sPageContent}}

						<div class="navi-actions desktop tablet">
							{{if isset( $aProduct )}}
								{{if $config.social_facebook_products || $config.social_nk_products || $config.social_twitter_products || $config.social_gg_products || $config.social_google_products}}
									<div id="social">
										{{if $config.social_facebook_products}}<a id="fb-share" href="http://www.facebook.com/sharer.php?u={{$aProduct.sFBUrlEncode}}&amp;t={{$aProduct.sFBTitleEncode}}"><span>{{$lang.Share_on_facebook}}</span></a>{{/if}}
										{{if $config.social_nk_products}}<a id="nk-share" href="http://nasza-klasa.pl/sledzik?shout={{$aProduct.sFBUrlEncode}}%20-%20{{$aProduct.sFBTitle}}%20-%20{{$aProduct.sFBDescriptionEncode}}%20-%20{{$aProduct.sFBWebsiteEncode}}"><span>{{$lang.Share_on_nk}}</span></a>{{/if}}
										{{if $config.social_twitter_products}}<a id="twitter-share" href="http://twitter.com/share?url={{$aProduct.sFBUrlEncode}}&amp;text={{$aProduct.sFBUrlEncode}}%20-%20{{$aProduct.sFBTitleEncode}}%20-%20{{$aProduct.sFBWebsiteEncode}}"><span>{{$lang.Share_on_twitter}}</span></a>{{/if}}
										{{if $config.social_gg_products}}<a id="gg-share" href="gg:/set_status?description={{$aProduct.sFBUrlEncode}}%20-%20{{$aProduct.sFBTitleEncode}}"><span>{{$lang.Share_on_gg}}</span></a>{{/if}}
										{{if $config.social_google_products}}<a id="google-share" href="https://plus.google.com/share?url={{$aProduct.sFBUrlEncode}}" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;"><span>Share on Google+</span></a>{{/if}}
									</div>
								{{/if}}
							{{else}}
								{{if $config.social_facebook_pages || $config.social_nk_pages || $config.social_twitter_pages || $config.social_gg_pages || $config.social_google_pages}}
									<div id="social" class="box">
										{{if $config.social_facebook_pages}}<a id="fb-share" href="http://www.facebook.com/sharer.php?u={{$aPage.sFBUrlEncode}}&amp;t={{$aPage.sFBTitleEncode}}"><span>{{$lang.Share_on_facebook}}</span></a>{{/if}}
										{{if $config.social_nk_pages}}<a id="nk-share" href="http://nasza-klasa.pl/sledzik?shout={{$aPage.sFBUrlEncode}}%20-%20{{$aPage.sFBTitle}}%20-%20{{$aPage.sFBDescriptionEncode}}%20-%20{{$aPage.sFBWebsiteEncode}}"><span>{{$lang.Share_on_nk}}</span></a>{{/if}}
										{{if $config.social_twitter_pages}}<a id="twitter-share" href="http://twitter.com/share?url={{$aPage.sFBUrlEncode}}&amp;text={{$aPage.sFBUrlEncode}}%20-%20{{$aPage.sFBTitleEncode}}%20-%20{{$aPage.sFBWebsiteEncode}}"><span>{{$lang.Share_on_twitter}}</span></a>{{/if}}
										{{if $config.social_gg_pages}}<a id="gg-share" href="gg:/set_status?description={{$aPage.sFBUrlEncode}}%20-%20{{$aPage.sFBTitleEncode}}"><span>{{$lang.Share_on_gg}}</span></a>{{/if}}
										{{if $config.social_google_pages}}<a id="google-share" href="https://plus.google.com/share?url={{$aPage.sFBUrlEncode}}" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600');return false;"><span>Share on Google+</span></a>{{/if}}
									</div>
								{{/if}}
							{{/if}}

							<a class="back" href="javascript:history.back();">{{$lang.go_back}}</a>
							<a class="top" href="#">{{$lang.go_top}}</a>
							<a class="print" href="javascript:window.print();">{{$lang.print}}</a>
						</div>
					</div><!--#content-->
					<div class="clear"></div>
				</div><!--#main-->
			</div>
			{{**}}
			{{if $aPage.iBannerBottom}}
				{{$aBanners.2}}      
			{{/if}}
			<footer>
				<div id="foot">
					<nav class="desktop">
						<h5>{{($SMARTY_sMenu5) ? $lang.Menu_additional : ''}}</h5>
						{{$SMARTY_sMenu5}}
					</nav>
					{{if isset($sNewsletterLink)}}
						<form action="{{$sNewsletterLink}}" method="post" id="newsletter">
							<h5>{{$lang.Newsletter}}</h5>
							<fieldset>
								<input type="email" id="newsletter-email" name="sEmail" value="" placeholder="{{$lang.Newsletter_input}}" />
								<input type="submit" id="newsletter-submit" value="" name="{{$lang.newsletter}}" class="submit reCaptcha" />
							</fieldset>
						</form>
					{{/if}}
				</div><!--#foot-->
			</footer>
			<div id="copyright">
				<a class="footer_logo" href="http://www.labsql.pl/"><img src="{{$config.dir_templates}}images/logo_labsql_24.png" alt="www.labsql.pl" /></a>
				<a class="footer_logo" href="http://www.sellsmart.pl/"><img src="{{$config.dir_templates}}images/logo_sellsmart_24.png" alt="www.sellsmart.pl" /></a>
				{{str_replace( '<br/>', ' ', $config.foot_info )}}
			</div>
			{{if !(isset($smarty.cookies.cookie_info_accepted) )}}
				<div id="cookie_container">
					<div id="cookie_main">
						<a id="cookie_close" href="#"><img src="templates/images/ico_del.png" alt="{{$lang.cb_close}}" title="{{$lang.cb_close}}"/></a>
						<span class="text">{{$lang.Cookie_text}}{{if isset($sCookieLink) && $sCookieLink != ''}} {{$lang.cookie_link_outside}}<a href="{{$sCookieLink}}">{{$lang.cookie_link_inside}}</a>.{{/if}}</span>
					</div>
				</div>
			{{/if}}
		</div><!--container-->

		{{if !empty( $config.google_analytics )}}
			<script type="text/javascript">
				var _gaq = _gaq || [];
				_gaq.push([ '_setAccount', '{{$config.google_analytics}}' ]);
				_gaq.push([ '_trackPageview' ]);

				{{if $config.google_analytics_ecommerce && $config.order_summary_page == $aPage.iPage}}  
					_gaq.push([ '_addTrans', '{{$aOrderInfo.iOrder}}', '', '{{$aOrderInfo.sSummary}}', '', '{{$aOrderInfo.fPaymentCarrierPrice}}', '{{$aOrderInfo.sCity}}', '', 'Polska' ]);
					{{foreach from=$aOrderProducts.aProducts item=aProduct}}
						_gaq.push([ '_addItem', '{{$aOrderInfo.iOrder}}', '{{$aProduct.iProduct}}', '{{$aProduct.sName}}', '', '{{$aProduct.sPrice}}', '{{$aProduct.iQuantity}}' ]);
					{{/foreach}}      
					_gaq.push([ '_trackTrans' ]);
				{{/if}}

				(function() {
					var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
					ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
					var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
				})();
			</script>
		{{/if}}

		{{if !empty( $config.google_conversion_code )}}
			<script type="text/javascript">
				/* <![CDATA[ */
				var google_conversion_id = {{$config.google_conversion_code}};
				var google_custom_params = window.google_tag_params;
				{{if ( !empty( $aPage.sConversionLabel ) && isset( $aProduct ) ) || !empty( $aProduct.sConversionLabel )}}
					var google_conversion_language = "en";
					var google_conversion_format = "2";
					var google_conversion_color = "ffffff";
					var google_conversion_label = "{{if !empty( $aProduct.sConversionLabel )}}{{$aProduct.sConversionLabel}}{{else}}{{$aPage.sConversionLabel}}{{/if}}";
					var google_remarketing_only = false;
				{{else}}
					var google_remarketing_only = true;
				{{/if}}
				/* ]]> */
			</script>
			<script type="text/javascript" src="//www.googleadservices.com/pagead/conversion.js"></script>
			<noscript>
				<div style="display:inline;">
					{{if ( !empty( $aPage.sConversionLabel ) && isset( $aProduct ) ) || !empty( $aProduct.sConversionLabel )}}
						<img height="1" width="1" style="border-style:none;" alt="" src="//www.googleadservices.com/pagead/conversion/{{$config.google_conversion_code}}/?label={{if !empty( $aProduct.sConversionLabel )}}{{$aProduct.sConversionLabel}}{{else}}{{$aPage.sConversionLabel}}{{/if}}&amp;guid=ON&amp;script=0"/>
					{{else}}
						<img height="1" width="1" style="border-style:none;" alt="" src="//googleads.g.doubleclick.net/pagead/viewthroughconversion/{{$config.google_conversion_code}}/?value=0&amp;guid=ON&amp;script=0"/>
					{{/if}}
				</div>
			</noscript>
		{{/if}}

		{{if !empty( $config.trusted_shops_id )}}
			<script type="text/javascript">
				(function () { 
				var _tsid = '{{$config.trusted_shops_id}}'; 
				_tsConfig = { 
					'yOffset': '{{$config.trusted_shops_bottom}}', /* offset from page bottom */
					'variant': '{{$config.trusted_shops_size}}', /* text, default, small, reviews */
					'trustcardDirection': '',
					'disableResponsive': 'false', /* deactivate responsive behaviour */
					'disableTrustbadge': 'false' /* deactivate trustbadge */
				};
				var _ts = document.createElement('script');
				_ts.type = 'text/javascript'; 
				_ts.charset = 'utf-8'; 
				_ts.async = true; 
				_ts.src = '//widgets.trustedshops.com/js/' + _tsid + '.js'; 
				var __ts = document.getElementsByTagName('script')[0];
				__ts.parentNode.insertBefore(_ts, __ts);
				})();
			</script>
		{{/if}}
		
		{{if !empty( $config.salesmanago_endpoint ) && !empty( $config.salesmanago_id_client ) && !empty( $config.salesmanago_api_secret ) && !empty( $config.salesmanago_microsite_key ) }}
			<script type="text/javascript">
				var _smid = '{{$config.salesmanago_id_client}}';
				(function() {
				var sm = document.createElement('script'); sm.type = 'text/javascript'; sm.async = true;
				sm.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + '{{$config.salesmanago_endpoint}}/static/sm.js';
				var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(sm, s);
				})();
			</script>
		{{/if}}
		{{if !empty( $config.recaptcha_private ) && !empty( $config.recaptcha_public )}}
			<script>
			var subId='';
			var onSubmit = function(token) {
				$('#'+subId).closest('form').find(".g-recaptcha-response").val(token);
				grecaptcha.reset();
				$('#'+subId).closest('form').addHidden( $('#'+subId).attr('name'),true ).submit();
			};
			$(function() {
				$(".reCaptcha").each(function() {
					$(this).click(function(event){
						event.preventDefault(); 
						subId = $(this).attr('id');
					if ($(this).closest('form').valid()) grecaptcha.execute();
					});
					$(this).after('<div class="g-recaptcha" data-sitekey="{{$config.recaptcha_public}}" data-badge="bottomleft" data-callback="onSubmit" data-size="invisible"></div>');
				});
			});
			</script>
			<script src="https://www.google.com/recaptcha/api.js" async defer></script>
		{{else}}
			<script>
        			$(".reCaptcha").each(function() {
            			$(this).closest('form').html('<p class="validation-error">{{$lang.cf_reCaptchaMissing}}</p>');
					});	
			</script>		
		{{/if}}
	</body>
</html>