<?php
/**
 * The template for displaying the full width category section
 *
 * @package WordPress
 * @subpackage Edition
 * @since Edition 1.0
 */
global
$tw_order_class,  // section order
$tw_section;      // section object

$tw_section     	= themewich_section_object();	// section post options
$section_post   	= $post;						// Store Section Post

// Set post classes
$tw_section->post_classes  = array(
	'full-taxonomy',
	'section',
	'full-image-section',
	$tw_order_class,
	$tw_section->title_class
); ?>

<div <?php post_class($tw_section->post_classes); ?>>

	<div class="container">
		<div class="col-md-12">
			<?php get_template_part( TW_SECTIONS_DIR .'/section-title'); ?>
		</div>
	</div>

	<div class="full-image-section">
		<?php themewich_section_edit(); // edit button ?>

		<div class="fullsection" <?php if ( isset( $tw_section->taxonomy_image['url'] ) && $tw_section->taxonomy_image['url'] ) { echo 'style="background-image:url('.$tw_section->taxonomy_image['url'].')"'; }?>>
			<div class="overlay"></div>

			<div class="fullcontent container">
				<div class="col-md-8 col-md-offset-2">

				<?php if ( $tw_section->taxonomy_headline ) : ?>
					<h2 class="title">
						<?php echo strip_tags ( apply_filters('the_content', $tw_section->taxonomy_headline) ); ?>
					</h2>
				<?php endif; ?>

				<?php if ( $tw_section->taxonomy_subheadline ) : ?>
					<p class="subtitle">
						<?php echo wp_kses_post ( apply_filters('the_content', $tw_section->taxonomy_subheadline) ); ?>
					</p>
				<?php endif; ?>

				<?php if ( $tw_section->taxonomy_button_text ) : ?>
					<span class="button outline">
						<?php echo strip_tags ( apply_filters('the_content', $tw_section->taxonomy_button_text) ); ?>
					</span>
				<?php endif; ?>

				</div>
			</div><!--.fullcontent-->

  			<div class="clear"></div>
  		</div><!--.fullsection-->
	</div><!--.full-image-section-->
</div><!--post class-->
