

{% call widget.panel( login_title or 'Login') %}

    {% if allow_register and oauth_enabled %}
        <div class="text-center">
            {{ macros.oauth_providers() }}
        </div>

        <hr>
    {% endif %}

    {% if show_verification_message and email %}
        <div class="alert alert-warning text-center">
            <h3>Account Verification Required</h3>
            <p>A verification link was sent to {{ email }}. You must verify your account to continue.</p>
            <a class="btn btn-info" href="{{ url_for('AuthLogin:confirm_email', email=email) }}">Resend Verification</a>
        </div>
    {% endif %}

    {% call forms.post(request.endpoint) %}

        {{ forms.hidden("method", value="email") }}
        {{ forms.hidden("next", value=login_url_next) }}

        {{ forms.input(label="Email", name="email", value=email or "", type="email", data={"validation": "email"}) }}

        {{ forms.input(label="Password", name="password", type="password",
            data={"validation": "required", "validation-error-msg": "Password is required"}) }}

        {{ forms.button("Login", type="submit", class="btn-primary btn-lg btn-block") }}
    {% endcall %}


    <hr>

    {% if allow_register %}
       <a class=" pull-left"  href="{{url_for("AuthLogin:register", next=login_url_next)}}">Register</a>
    {% endif %}

    <a class="pull-right" href="{{url_for("AuthLogin:lost_password")}}">Lost Password <i class="fa fa-arrow-right"></i></a>
    <div class="clearfix"></div>

{% endcall %}

