<?= $this->extend(config('Auth')->views['layout']) ?>
<?= $this->section('title') ?><?= lang('Auth.email2FATitle') ?> <?= $this->endSection() ?>
<?= $this->section('main') ?>

<div class="login-box">
  <div class="login-logo">
    <a href="#"><?= env('app.name') ?></a>
  </div>
  <!-- /.login-logo -->
  <div class="login-box-body">
    <p class="login-box-msg"><?= lang('Auth.email2FATitle') ?></p>
    <p style="text-align:center;">Klik tombol berikut untuk mengirimkan authentication code ke nomor whatsapp Anda (<?= sensor_phone($user->whatsapp) ?>).</p>

    <?php if (session('error')) : ?>
        <div class="alert alert-danger"><?= session('error') ?></div>
    <?php endif ?>

    <form action="<?= url_to('auth-action-handle') ?>" method="post" id="form">
        <?= csrf_field() ?>
        <div class="d-grid col-8 mx-auto m-3">
            <button type="submit" class="btn btn-primary btn-block">Kirimkan authentication code</button>
        </div>
    </form>
  </div>
  <!-- /.login-box-body -->
</div>
<!-- /.login-box -->

<?= $this->endSection() ?>