{% extends 'base_blank.html' %}

{% block title %}Sign in - {{ super() }}{% endblock %}

{% block content %}
{% from "_macros.html" import render_field %}
{% from "flask_user/_macros.html" import render_checkbox_field %}

<div class="login-box">
    <div class="login-box-body">
        <div class="login-logo">
            <img src="{{ url_for('static', filename='img/logo_full_48.png') }}" alt="Logo">
            <a href="{{ url_for('main.home') }}">OpenCVE.io</a>
        </div>
        {% include 'flash_messages.html' %}
        <p class="login-box-msg"><strong>Sign in to your account</strong></p>
        <form action="{{ url_for('user.login') }}" method="post">
            {{ form.hidden_tag() }}
            {{ render_field(form.username, tabindex=200, placeholder="Username or email") }}
            {{ render_field(form.password, tabindex=300, placeholder="Password") }}
            <div class="row">
                <div class="col-xs-8">
                    {{ render_checkbox_field(login_form.remember_me, tabindex=400) }}
                </div>
                <div class="col-xs-4">
                    <button type="submit" class="btn btn-primary btn-block btn-flat">Sign In</button>
                </div>
            </div>
        </form>

        <p>&nbsp;</p>
        <p class="center">
            <a href="{{ url_for('user.forgot_password') }}">Forgot password ?</a><br>
            <a href="{{ url_for('user.register') }}" class="text-center">Register a new membership</a>
        </p>

    </div>
</div>

{% endblock %}