<?php
/**
 * Homepage widget area with the two-column layout.
 *
 * @package United Blog
 */
if (is_active_sidebar('homepage-column-one') || is_active_sidebar('homepage-column-two')) :
    ?>
    <section class="united-block united-widget-block multiple-widget-block">
        <div class="wrapper">
            <?php do_action('homepage_column_two_before'); ?>
            <div class="row">
                <?php if (is_active_sidebar('homepage-column-one')) : ?>
                    <div class="column-sm-12 column-md-8">
                        <div class="widget-area wpi-widget-area fullwidth-widget-area wpi-primary-widgetarea">
                            <?php do_action('homepage_column_primary_before'); ?>
                            <?php dynamic_sidebar('homepage-column-one'); ?>
                            <?php do_action('homepage_column_primary_after'); ?>
                        </div>
                    </div>
                <?php endif; ?>
                <?php if (is_active_sidebar('homepage-column-two')) : ?>
                    <div class="column-sm-12 column-md-4">
                        <aside class="widget-area sticky-widget-area">
                            <?php do_action('homepage_column_secondary_before'); ?>
                            <?php dynamic_sidebar('homepage-column-two'); ?>
                            <?php do_action('homepage_column_secondary_after'); ?>
                        </aside>
                    </div>

                <?php endif; ?>
            </div>
            <?php do_action('homepage_column_two_after'); ?>
        </div>
    </section>
<?php
endif;
