{% set show_logo = (not(SERVER.SERVER_NAME matches '~^(?:www\.)?cr1site.pt~') and site.logo_footer) %}
{% set classes = {
	'facebook': 'facebook-f',
	'twitter': 'twitter',
	'tripadvisor': 'tripadvisor',
	'pinterest': 'pinterest-p',
	'instagram': 'instagram',
	'youtube': 'youtube'
} %}

{% block footer %}
<footer id="footer" class="footer content">
	{% block site_name %}
		<div class="footer_logo text-center">
			&copy; {{ 'now' | date('Y') }} - {{ site.name }}
			{# {{ site.footer_show_terms ? (' - <a href="/terms.html?lightbox[height]=60p&lightbox[width]=50p&page=website" class="lightbox" rel="nofollow">' ~ text.footer.terms_and_conditions ~ '</a>') | raw }} #}
			{{
				(general.exts.store.enabled
					? (' - <a href="/store/terms/' ~ constant('SITE_LANG') ~ '.html?lightbox[height]=60p&lightbox[width]=50p&page=website" class="lightbox" rel="nofollow">' ~ text.footer.terms_and_conditions ~ '</a>')
					: (
						site.footer_show_terms
							? (' - <a href="/terms.html?lightbox[height]=60p&lightbox[width]=50p&page=website" class="lightbox" rel="nofollow">' ~ text.footer.terms_and_conditions ~ '</a>')
					)
				) | raw
			}}
			{{ general.exts.data.enabled ? (' - <a href="/terms.html?lightbox[height]=60p&lightbox[width]=50p&page=gdpr" class="lightbox" rel="nofollow">' ~ text.footer.gdpr ~ '</a>') | raw }}
		</div>
	{% endblock site_name %}
	
	{% if general.exts.store.enabled %}
		{% block _ext_store_vat_footer %}
			<p id="ext_store_footer_vat" class="text-center">
				{% if general.exts.store.settings.vat_exempt_art_53 %}
					{{ text.misc.ext.store.vat_exempt_art_53 }}
				{% elseif general.exts.store.settings.vat_show %}
					{{ text.misc.ext.store.vat_shown }}
				{% else %}
					{{ text.misc.ext.store.vat_not_shown }}
				{% endif %}
			</p>
		{% endblock %}
	{% endif %}
	
	{% block footer_social %}
		<div id="footer_social" class="social_contact">
			<ul>
				{% for class in ['twitter', 'facebook', 'tripadvisor', 'pinterest', 'instagram', 'youtube'] %}
					{% if site[class] %}
						{% block social %}
							<li>
								<a href="{{ site[class] }}" target="_blank" class="social_contact_{{ class }}" rel="me">
									<i class="fa fa-{{ classes[class] }}"></i>
								</a>
							</li>
						{% endblock social %}
					{% endif %}
				{% endfor %}
		
				{% if show_logo %}
					<li>
						<a href="{{ text.footer.c1s.url }}" title="{{ text.footer.c1s.title }}" target="_blank" class="social_contact_c1s"></a>
					</li>
				{% endif %}
				
				{% if site.show_consumer_complaints_resolution %}
					<li>
						<a href="/terms.html?lightbox[height]=40p&lightbox[width]=40p&page=ca" title="{{ text.footer.ca.title }}" target="_blank" class="social_contact_ca lightbox"></a>
					</li>
				{% endif %}
				
				{% if site.show_complaints_book %}
					<li>
						<a href="https://www.livroreclamacoes.pt/inicio" title="{{ text.footer.cb.title }}" target="_blank" class="social_contact_cb" rel="nofollow"></a>
					</li>
				{% endif %}
				
				<li class="clearfix"></li>
			</ul>
		</div>
	{% endblock footer_social %}
</footer>
{% endblock footer %}