
<section class="py-5 bg-light text-dark text-center">
   <div class="">
    <div class="row justify-content-center">
      <div class="col-sm-8 text-center">
        <h2 class="mb-3"><?php echo esc_html(get_theme_mod('howcan_news_letter_sec_title'),'howcan'); ?>
    </h2>
        <p class="mb-4"><?php echo esc_html(get_theme_mod('howcan_section_subtitle'),'howcan'); ?>
    </p>

  
  <?php if ( isset($_GET['subscribed']) && $_GET['subscribed'] === '1' ) : ?>
    <div class="alert alert-success text-center mb-3">
        <?php esc_html_e( '✅ Thank you for subscribing!', 'howcan' ); ?>
    </div>
<?php endif; ?>

<form class="row g-2 justify-content-center" method="post">
    <?php wp_nonce_field( 'howcan_newsletter_action', 'howcan_newsletter_nonce' ); ?>
    <div class="col-sm-8">
        <input type="email" name="newsletter_email" class="form-control form-control-lg" placeholder="<?php esc_attr_e( 'Enter your email', 'howcan' ); ?>" required>
    </div>
    <div class="col-sm-4">
        <button type="submit" class="btn btn-dark btn-lg w-100">
           <?php echo esc_html(get_theme_mod('howcan_news_letter_btn_txt'),'howcan'); ?>
    
        </button>
    </div>
</form>
        <small class="text-muted d-block mt-3"> <?php echo esc_html(get_theme_mod('howcan_news_letter_bn_txt'),'howcan'); ?></small>
      </div>
    </div>
  </div>
  
</section>
