{% extends "base.html" %}
{% load i18n %}

{% block main %}
    <div class="row">
        <div class="col-md-4"></div>
        <div class="col-md-4 col-xs-12">
            <div class="panel panel-default">
                <div class="panel-body">
                    {% if form.non_field_errors %}
                        <div class="alert alert-danger">
                            {{ form.non_field_errors }}
                        </div>
                    {% endif %}
                    <form method="post" action="" class="registration">{% csrf_token %}
                        {% include 'extras/form.html' with form=form layout='default' %}
                        <div class="clearfix">
                            <input type="submit" value="{% trans "Sign in" %}" class="btn btn-primary" />
                            <a href="{% url 'password_reset' %}" class="btn btn-primary">{% trans "Reset password" %}</a>
                        </div>
                        <input type="hidden" name="next" value="{{ next }}" />
                    </form>
                </div>
            </div>
        </div>
        <div class="col-md-4"></div>
    </div>
{% endblock %}

{% block extra_js %}
    <script type="text/javascript">
        document.getElementById('id_username').focus();
    </script>
{% endblock %}
