{% extends 'base.html' %}

{% block title %}Log In{% endblock %}
{% block description %}Log into your account!{% endblock %}
{% block bodytag %}login{% endblock %}

{% block body %}
  <div class="container custom-container">
    <div class="va-wrapper">
      <div class="view login-view container">
        <div class="box row">
          <div class="email-password-area col-xs-12 large col-sm-12">
            <div class="header">
              <span>Log In or </span>
              <a href="{{ url_for('auth.register') }}">Create an Account</a>
            </div>
            {% with messages = get_flashed_messages() %}
              {% if messages %}
                <div class="alert alert-danger bad-login">
                  {% for message in messages %}
                    {{ message }}
                  {% endfor %}
                </div>
              {% endif %}
            {% endwith %}
            <form class="login-form form-horizontal" role="form" method="post">
              {{ form.hidden_tag() }}
              <div class="form-group group-email">
                <label class="col-sm-4">
                  Email
                </label>
                <div class="col-sm-8">
                  {{ form.email(autofocus='true', class='form-control', placeholder='Email', required='true') }}
                </div>
              </div>
              <div class="form-group group-password">
                <label class="col-sm-4">Password</label>
                <div class="col-sm-8">
                  {{ form.password(class='form-control', placeholder='Password', required='true') }}
                </div>
              </div>
              <div>
                <button class="login btn btn-login btn-sp-green" type="submit">Log In</button>
              </div>
            </form>
          </div>

        </div>
        <a class="forgot" href="">Forgot Password?</a>
      </div>
    </div>
  </div>
{% endblock %}
