<?php
/*
* Template Name: FAQ
*
* */

get_header(); ?>
    <section class="container-fluid" style="background:#fff url(<?= get_template_directory_uri(); ?>/images/happy_cus_bg2.png) left center / auto no-repeat fixed;">
        <div class="row">
            <div class="container  ">
                <div class="row  m_t_50 m_b_50">
                    <div class="col-md-12 title_text text-center">
                        <h2><?php the_field('faq_page_title'); ?></h2>
                    </div>
                    <div class="col-md-10  col-md-offset-1">
                        <?php
                        $faqCount = 0;
                        if( have_rows('page_faq') ):
                            while ( have_rows('page_faq') ) : the_row(); $faqCount++; ?>
                                <div class="row locations_zig <?php if ($faqCount === 1) : echo 'open'; endif; ?>">
                                    <div class="col-md-12 header_port">
                                        <a href="javascript:void(0);" class="header_location"><?= $faqCount; ?>. <?php the_sub_field('faq_rep_title'); ?></a>
                                    </div>
                                    <div class="col-md-12 body_port" style="<?php if ($faqCount === 1) : echo 'display: block;'; endif; ?>">
                                        <?php the_sub_field('faq_rep_text'); ?>
                                    </div>
                                </div>
                            <?php endwhile;
                        endif;
                        wp_reset_postdata();
                        ?>
                    </div>
                </div>
            </div>
        </div>
    </section>
    <section class="container-fluid" style="background:#9fb4bf  url(<?= site_url(); ?>/wp-content/uploads/2019/03/apply_now_bg_white22.png) center right / auto no-repeat;">
        <div class="row  m_t_100 m_b_100">
            <div class="container">
                <div class="row">
                    <div class="title_text text-center text_white col-md-12 ">
                        <h2><?php the_field('cnt_pg_title',148); ?></h2>
                    </div>
                    <div class="col-md-12 m_t_50 apply_form form_2">
                        <?php $contactpageForm = get_field('cnt_form_shortcode',148); ?>
                        <?= do_shortcode($contactpageForm); ?>
                    </div>
                </div>
            </div>
        </div>
    </section>
<?php
get_footer();