{#
/*
 * Copyright © ProgramCMS. All rights reserved.
 * See COPYING.txt for license details.
 *
 * Developed by Mohamed EL QUCHIRI <elquchiri@gmail.com>
 */
#}
<section class="h-100 mb-5">
    <header class="container h-100">
        <div class="d-flex align-items-center justify-content-center h-100">
            <div class="d-flex flex-column">
                <div class="card" style="border: none">
                    <div class="card-body" style="width: 29rem;">
                        <div class="mb-5">
                            <h2>{{ block.trans('Account recovery') }}</h2>
                        </div>
                        <form method="POST"
                              action="{{ block.getSubmitUrl() }}"
                              data-controller="recovery"
                              data-action="recovery#verifyStep">
                            <div class="recovery_email mb-3">
                                <label for="email" class="form-label fw-bold">{{ block.trans('Email') }}</label>
                                <input
                                    type="email"
                                    class="form-control"
                                    id="email"
                                    name="email"
                                    placeholder="{{ block.trans('Please enter your email') }}"
                                    value="{{ block.getLastEmail() }}">
                                <div id="emailHelp" class="form-text mt-3">
                                    {{ block.trans('We will use this email address to send you a code to your inbox, you should then login to your email provider, get this code and fill it.') }}
                                </div>
                            </div>
                            <div class="user_token mb-3 d-none">
                                <label for="user_token" class="form-label fw-bold">{{ block.trans('Received token') }}</label>
                                <div id="userTokenHelp" class="form-text mt-2 mb-2">
                                    {{ block.trans('We have sent a code to your email, please enter it in this box to verify your identity.') }}
                                </div>
                                <input
                                    type="text"
                                    class="form-control"
                                    id="user_token"
                                    name="user_token"
                                    placeholder="{{ block.trans('Please enter your token') }}"
                                    value="{{ block.getLastEmail() }}" disabled>
                            </div>
                            <div class="password_container d-none">
                                <div class="mb-3">
                                    <label for="password" class="form-label fw-bold">{{ block.trans('New Password') }}</label>
                                    <input
                                        type="password"
                                        class="form-control"
                                        id="password"
                                        name="password"
                                        placeholder="{{ block.trans('Please enter your new password') }}" disabled>
                                </div>
                                <div class="mb-3">
                                    <label for="check_password" class="form-label fw-bold">{{ block.trans('Password confirmation') }}</label>
                                    <input
                                        type="password"
                                        class="form-control"
                                        id="check_password"
                                        name="check_password"
                                        placeholder="{{ block.trans('Please re-enter your new password') }}" disabled>
                                </div>
                            </div>
                            <input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}">
                            <div class="mt-5">
                                <button type="submit" class="btn btn-primary btn-block" style="width: 100%;">
                                    {{ block.trans('Continue') }}
                                </button>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </header>
</section>