<?php
//if(get_theme_mod('statistics')) {
    ?>
    <!--Counter_wrapper-->
    <section id="statistics" class="col-md-12 counter_section counter_bg" style="">
            <div class="container">
                <div class="row os-animation" data-os-animation="fadeInUp" data-os-animation-delay="0s">
                    <?php
                  if(get_theme_mod('statistics')) {
					   foreach(get_theme_mod('statistics') as $statistic) {
                        if(isset($statistic['stats_title']) && !empty($statistic['stats_title'])) {
                            $title = $statistic['stats_title'];
                            ?>
                            <div class="col-md-3 col-sm-6">
                                <?php
                                if (isset($statistic['stats_icon']) && !empty($statistic['stats_icon'])) {
                                    $icon = $statistic['stats_icon'];
                                } else {
                                    $icon = 'fa-dashboard';
                                }
                                ?>
                                <i class="fa <?php echo $icon; ?>"></i>
                                <?php
                                if (isset($statistic['stats_no']) && !empty($statistic['stats_no'])) {
                                    $number = $statistic['stats_no'];
                                } else {
                                    $number = 0;
                                }
                                ?>
                                <h3 class="timer" data-from="0" data-to="<?php echo $number; ?>"><?php echo $number; ?></h3>
                                <p><?php echo $title; ?></p>
                            </div>
                        <?php
                        }
                    }
				  }
					else {?>
							<div class="col-md-3 col-sm-6">
                                <i class="fa fa-coffee"></i>
                                <h3 class="timer" data-from="25" data-to="862">862</h3>
                                <p>Hours of Coding</p>
                                </div>
                                <div class="col-md-3 col-sm-6">
                                <i class="fa fa-leaf"></i>
                                <h3 class="timer" data-from="0" data-to="75">53</h3>
                                <p>Projects</p>
                                </div>
                                <div class="col-md-3 col-sm-6">
                                <i class="fa fa-thumbs-o-up"></i>
                                <h3 class="timer" data-from="0" data-to="408">346</h3>
                                <p>Clients</p>
                                </div>
                                <div class="col-md-3 col-sm-6">
                                <i class="fa fa-graduation-cap"></i>
                                <h3 class="timer" data-from="0" data-to="56">53</h3>
                                <p>Awards</p>
                                </div>
					<?php 
					}
				
                    ?>
                </div>
            </div>
    </section>
  <div class="clearfix"></div>
  <!--Counter_wrapper end-->
<?php
//}
?>