<?php
/*
*
* Home intro section for portfolix section
*
*
*/



function news_axis_hbanner_section_output()
{
  $news_axis_hbanner_show = get_theme_mod('news_axis_hbanner_show');
  if (empty($news_axis_hbanner_show)) {
    return;
  }
  $news_axis_dfimgh = get_template_directory_uri() . '/assets/img/hero.jpg';
  $news_axis_hbanner_img = get_theme_mod('news_axis_hbanner_img', $news_axis_dfimgh);
  $news_axis_hbanner_subtitle = get_theme_mod('news_axis_hbanner_subtitle', __('Tranding News', 'news-axis'));
  $news_axis_hbanner_title = get_theme_mod('news_axis_hbanner_title', __('Introduce Our', 'news-axis'));
  $news_axis_color_title = get_theme_mod('news_axis_color_title', __('Today\'s Top News', 'news-axis'));
  $news_axis_hbanner_desc = get_theme_mod('news_axis_hbanner_desc');
  $news_axis_btn_text_one = get_theme_mod('news_axis_btn_text_one', __('Read More', 'news-axis'));
  $news_axis_btn_url_one = get_theme_mod('news_axis_btn_url_one', '#');

?>
  <!-- home -->
  <section class="aghome" id="home">
    <div id="ax-praticals"></div>
    <div class="ax-home-single-slide-all-content">
      <?php if ($news_axis_hbanner_img) : ?>
        <div class="ax-home-bg">
          <img src="<?php echo esc_url($news_axis_hbanner_img); ?>" alt="<?php esc_attr($news_axis_hbanner_title); ?>">
        </div>
      <?php endif; ?>
      <div class="ax-home-details text-center">
        <?php if ($news_axis_hbanner_subtitle) : ?>
          <div class="ax-home-subtitle">
            <p><?php echo esc_html($news_axis_hbanner_subtitle); ?></p>
          </div>
        <?php endif; ?>
        <?php if ($news_axis_hbanner_title || $news_axis_color_title) : ?>
          <div class="ax-home-title">
            <?php if ($news_axis_hbanner_title) : ?>
              <h1><?php echo esc_html($news_axis_hbanner_title); ?>
              </h1>
            <?php endif; ?>
            <?php if ($news_axis_color_title) : ?>
              <h1 class="ax-section-title"><?php echo esc_html($news_axis_color_title); ?>
              <?php endif; ?>
          </div>
        <?php endif; ?>
        <?php if ($news_axis_hbanner_desc) : ?>
          <div class="ax-home-dres">
            <p><?php echo wp_kses_post($news_axis_hbanner_desc); ?></p>
          </div>
        <?php endif; ?>
        <?php if ($news_axis_btn_url_one) : ?>
          <div class="ax-home-btn">
            <a href="<?php echo esc_url($news_axis_btn_url_one); ?>" class="ax-home-first-btn"><?php echo esc_html($news_axis_btn_text_one); ?></a>
          </div>
        <?php endif; ?>
      </div>
    </div>
  </section>

<?php
}
add_action('news_axis_hbanner', 'news_axis_hbanner_section_output');
