<div class="gt-place-8-area">
    <div class="gt-place-8-wrap">
        <?php if(!empty($serttings['bg_img']['url'])):?>
            <div class="main-img place-thumb">
                <img src="<?php echo esc_url($settings['bg_img']['url']);?>" alt="<?php if(!empty($settings['bg_img']['alt'])){ echo esc_attr($settings['bg_img']['alt']);} ?>">
            </div>
        <?php endif;?>
        <?php foreach($settings['destinations'] as $item):?>
        <div class="gt-place-8-card">
            <div class="gt-place-card-inner place_card_1">
                <?php if(!empty($item['front_img']['url'])):?>
                    <div class="gt-place-card-front">
                        <img src="<?php echo esc_url($item['front_img']['url']);?>" alt="<?php if(!empty($item['front_img']['alt'])){ echo esc_attr($item['front_img']['alt']);} ?>">
                    </div>
                <?php endif;?>
                <div class="gt-place-card-back">

                <?php if(!empty($item['back_img']['url'])):?>
                    <div class="back-img">
                        <img src="<?php echo esc_url($item['back_img']['url']);?>" alt="<?php if(!empty($item['back_img']['alt'])){ echo esc_attr($item['back_img']['alt']);} ?>">
                    </div>
                <?php endif;?>
                <div class="content">
                    <div class="rating">
                        <?php for($i = 0; $i < $item['rating']; $i++):?>
                            <i class="flaticon-star"></i>
                        <?php endfor;?>
                    </div>
                    <?php if(!empty($item['title'])):?>
                        <h5 class="title"><?php echo wp_kses($item['title'], true);?></h5>
                    <?php endif;?>
                    <div class="data">

                        <?php if(!empty($item['location'])):?>
                            <div class="location">
                                <i class="flaticon-maps-and-flags"></i>
                                <span><?php echo wp_kses($item['location'], true);?></span>
                            </div>
                        <?php endif;?>
                        <?php if(!empty($item['count'])):?>
                            <h5 class="place"><span class="number"><?php echo wp_kses($item['count'], true);?></span> <?php echo wp_kses($item['count_label'], true);?></h5>
                        <?php endif;?>
                    </div>
                </div>
                </div>
            </div>
        </div>
        <?php endforeach;?>

    </div>
    <!-- mobile version -->
    <div class="gt-place-8-wrap-2">
        <?php foreach($settings['destinations'] as $item):?>
        <div class="gt-place-8-card-2">
            <?php if(!empty($item['back_img']['url'])):?>
                <div class="back-img">
                    <img src="<?php echo esc_url($item['back_img']['url']);?>" alt="<?php if(!empty($item['back_img']['alt'])){ echo esc_attr($item['back_img']['alt']);} ?>">
                </div>
            <?php endif;?>
            
            <div class="content">
                <div class="rating">
                    <?php for($i = 0; $i < $item['rating']; $i++):?>
                        <i class="flaticon-star"></i>
                    <?php endfor;?>
                </div>
                <?php if(!empty($item['title'])):?>
                    <h5 class="title"><?php echo wp_kses($item['title'], true);?></h5>
                <?php endif;?>
                <div class="data">
                    <?php if(!empty($item['location'])):?>
                        <div class="location">
                            <i class="flaticon-maps-and-flags"></i>
                            <span><?php echo wp_kses($item['location'], true);?></span>
                        </div>
                    <?php endif;?>
                    <?php if(!empty($item['count'])):?>
                        <h5 class="place"><span class="number"><?php echo wp_kses($item['count'], true);?></span> <?php echo wp_kses($item['count_label'], true);?></h5>
                    <?php endif;?>
                </div>
            </div>
        </div>
        <?php endforeach;?>
    </div>
    <?php if(!empty($settings['description'])):?>
        <p class="bottom-text"><?php echo __($settings['description'], true);?></p>
    <?php endif;?>
</div>
