{% extends "mainTemplate.html" %}

{% block title %}Login{% endblock %}

{% load crispy_forms_tags %}

{% block content %}

    <div class="container-fluid">
        <div style="padding-top: 100px; padding-left: 10px">
        <div class="card">
            <div class="card-body">
                <h2 style="text-align: center">Login</h2>
                    {% if messages %}
                     <div class="row justify-content-md-center">
                         <div class="alert alert-primary" role="alert">
                             {% for message in messages %}
                             <p>{{ message }}</p>
                             {% endfor %}
                         </div>
                     </div>
                    {% endif %}
                    <div class="row justify-content-md-center">
                        <form method="POST">
                            {% csrf_token %}

                            {{form|crispy}}

                             <div class="row justify-content-md-center">
                                <button class="btn btn-primary" type="submit">Login</button>
                             </div>
                        </form>
                    </div>

                <p style="text-align: center">Don't have an account? <a href="/register" target="blank"><strong>Register here</strong></a>!</p>
            </div>


        </div>
        </div>
    </div>
{% endblock %}
