{# block page %}
	<section class="section first-section home" id="home">
		<h1>{{ page.name }}</h1>
		
		{% block contents %}
		
			{% if site.slideshow_youtube_id %}
				{% block youtube %}
					<div class="home-slider full-screen video-main" style="background:url('{{ constant('ROOT_URL_SCHEME') }}://img.youtube.com/vi/{{ site.slideshow_youtube_id }}/sddefault.jpg');background-size:cover;background-position:center center;line-height:0px;">
						<div>
							<img src="{{ youtube_src }}" data-id="{{ site.slideshow_youtube_id }}" class="youtube_video" style="background:url('/images/youtube-play.png') no-repeat center;"/>
						</div>
					</div>
				{% endblock %}
			{% else %}
				<div class="home-slider full-screen">
					{% if data.slideshow_active %}
						{% block slideshow %}
							<div id="carousel3" class="carousel slide" data-ride="carousel3" data-interval="5000">
								
								{% if data.slides|length > 1 %}
									{% block slideshow_indicators %}
										<ol class="carousel-indicators">
											{% for _ in 1..data.slides|length %}
												<li{{ loop.first ? ' class="active"' }} data-slide-to="{{ loop.index0 }}" data-target="#carousel3"></li>
											{% endfor %}
										</ol>
									{% endblock %}
								{% endif %}
								{% block slideshow_content %}
									<div class="carousel-inner">
										{% for slide in data.slides %}
											{% set has_desc = (slide.desc and (not(slide.desc == '<br>')) and (not(slide.desc == '<p>&nbsp;</p>'))) %}
											
											{% block slide %}
												<div class="item{{ loop.first ? ' active' }}" id="slide_{{ slide.id }}">
													{% if CONTEXT != 'preview' %}
														{% if slide.url_out %}
															<a href="{{ slide.url_out }}" target="_self">
														{% elseif slide.url_out %}
															<a href="{{ slide.url_ext }}" target="_blank" rel="nofollow">
														{% elseif slide.url %}
															<a href="{{ slide.url | raw }}" class="lightbox" rel="nofollow">
														{% endif %}
													{% endif %}
													
													{% block slide_contents %}
														<div class="slider-gradient-overlay"></div>
														<div style="background-image:url('/{{ slide.src }}');" class="fill"></div>
														{% block slide_content_holder %}
															<div class="slider-text">
																{% block slide_content %}
																	<div class="col-md-6">
																		<h2>{{ slide.alt }}</h2>
																		{{ (has_desc ? '<span>' ~ slide.desc ~ '</span>') | raw }}
																	</div>
																{% endblock %}
															</div>
														{% endblock %}
													{% endblock %}
														
													{% if CONTEXT != 'preview' and (slide.url_out or slide.url_ext or slide.url) %}
														</a>
													{% endif %}
												</div>
											{% endblock %}
										{% endfor %}
									</div>
								{% endblock %}
								
								<div class="clearfix"></div>
							</div>
						{% endblock %}
					{% endif %}
					<div class="clearfix"></div>
				</div>
			{% endif %}
			
			{% if site.highlights_top_active %}
				{% block highlights %}
					<div class="content">
						<div id="highlights" class="row">
							{% for highlight in data.highlights %}
								{% block highlight %}
									<div class="col-md-{{ cols }} col-sm-{{ cols }} service-box text-center">
										{% if not site.highlights_hide_icons %}
											{% block highlight_icon %}
												<div class="service-icon"> <i class="fa fa-{{ highlight.icon_class }}"></i> </div>
											{% endblock %}
										{% endif %}
										{% block highlight_title %}
											<h2>{{ highlight.title }}</h2>
										{% endblock %}
										{% block highlight_content %}
											<p class="content">{{ highlight.desc | raw }}</p>
										{% endblock highlight_content %}
									</div>
								{% endblock highlight %}
							{% endfor %}
						</div>
					</div>
				{% endblock highlights %}
			{% endif %}
			<div class="clearfix"></div>
		{% endblock contents %}
		
	</section>
{% endblock page #}

{% block page %}
<section class="section first-section home" id="home">
	<h1>{{ page.name }}</h1>
	{% block contents %}
		{% if site.slideshow_youtube_id %}
			{% block youtube %}
				
				<div class="slide full-screen video-main" style="height: 100%;height: 77vh;">
					<div>
						<iframe src="https://www.youtube.com/embed/{{ site.slideshow_youtube_id }}?autoplay=1&amp;loop=1&amp;playlist={{ site.slideshow_youtube_id }}&amp;mute=1&amp;vq=hd720&amp;controls=0" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" style="background-size:cover;background-position:center center;line-height:0px; position: absolute !important; top: -30%; left: 0; pointer-events: none; zoom: 1.113;"></iframe>
					</div>
				</div>
			{% endblock %}
		{% else %}
			{% if data.slideshow_active %}
				{% block slideshow %}
					<div id="hero" class="carousel slide carousel-fade no-padding" data-ride="carousel">
						{% if data.slides|length > 1 %}
							{% block slideshow_indicators %}
								<ol class="carousel-indicators">
									{% for _ in 1..data.slides|length %}
										<li{{ loop.first ? ' class="active"' }} data-slide-to="{{ loop.index0 }}" data-target="#hero"></li>
									{% endfor %}
								</ol>
							{% endblock %}
						{% endif %}
							
							
						{% block slideshow_content %}
							<div class="carousel-inner">
								{% for slide in data.slides %}
									{% set has_desc = (slide.desc and (not(slide.desc == '<br>')) and (not(slide.desc == '<p>&nbsp;</p>'))) %}
									
									{% block slide %}
										<div class="item{{ loop.first ? ' active' }}" id="slide_{{ slide.id }}" style="background-image:url('/{{ slide.src }}');">
											{% if CONTEXT != 'preview' and not slide.doc %}
												{% if slide.url_out %}
													<a href="{{ slide.url_out }}" target="_self">
												{% elseif slide.url_ext %}
													<a href="{{ slide.url_ext }}" target="_blank" rel="nofollow">
												{% elseif slide.url %}
													<a href="{{ slide.url | raw }}" class="lightbox" rel="nofollow">
												{% endif %}
											{% endif %}
											
											{% block slide_contents %}
												<div class="container">
													<div class="row blurb scrollme animateme" data-when="exit" data-from="0" data-to="1" data-opacity="0" data-translatey="100">
													{% block slide_content_holder %}
														{% block slide_content %}
															<h2>{{ slide.alt | raw }}</h2>
															{{ (has_desc ? '<h3>' ~ slide.desc ~ '</h3>') | raw }}
														{% endblock %}
														{# <div class="col-md-10 col-md-offset-1"></div> #}
														
														{% if slide.doc %}
															{% for doc in slide.doc %}
																{% block slide_doc_content %}
																	<a href="{{ doc.src }}" target="_blank">{{ doc.title }}</a>
																{% endblock slide_doc_content %}
															{% endfor %}
														{% endif %}
													{% endblock %}
													</div>
												</div>
											{% endblock %}
												
											{% if CONTEXT != 'preview' and not slide.doc and (slide.url_out or slide.url_ext or slide.url) %}
												</a>
											{% endif %}
										</div>
									{% endblock %}
								{% endfor %}
							</div>
						{% endblock %}
					</div>
				{% endblock %}
			{% endif %}
		{% endif %}
			
		{% if site.highlights_top_active %}
			{% block highlights %}
				<div class="container-fluid super-dark padding-15">
					<div class="container">
						<div id="highlights" class="row">
						{% for highlight in data.highlights %}
							{% block highlight %}
								<div class="col-md-{{ cols }} col-sm-{{ cols }}">
									<div class="counter">
										{% if not site.highlights_hide_icons %}
											{% block highlight_icon %}
												<i class="fa fa-fw fa-{{ highlight.icon_class }} fa-4x"></i>
											{% endblock %}
										{% endif %}
										{% block highlight_title %}
											<h3>{{ highlight.title }}</h3>
										{% endblock %}
										{% block highlight_content %}
											<p>{{ highlight.desc | raw }}</p>
										{% endblock highlight_content %}
									</div>
								</div>
							{% endblock highlight %}
						{% endfor %}
						</div>
					</div>
				</div>
			{% endblock highlights %}
			
		{% endif %}
		<div class="clearfix"></div>
	{% endblock contents %}
</section>
{% endblock page %}