{% extends "base.html" %}
<!DOCTYPE html>
{% block head %}
    {{ super() }}
    <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles/general.css') }}">
    <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles/security/login.css') }}">
{% endblock %}

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

{% block headline %}Login{% endblock %}

{% block content %}
    <form class="form" action="" method="post" id="loginform">
        <div class="form_wrapper">
            <div class="form_fields">
                <div class="manual_input">
                    <p class="input_hint">Email:</p>
                    {% if data: %}
                    <input class="input_field" type="text" name="email" value="{{ data.get('email') }}" placeholder="name@example.com">
                    {% else: %}
                    <input class="input_field" type="text" name="email" placeholder="name@example.com">
                    {% endif %}
                </div>
                <div class="manual_input">
                    <p class="input_hint">Password:</p>
                    {% if data: %}
                    <input class="input_field" type="password" value="{{ data.get('password') }}" name="password">
                    {% else: %}
                    <input class="input_field" type="password" name="password">
                    {% endif %}
                </div>
            </div>
        </div>
        <div class="text_links">
            <div class="text_link_container">
                <p>Don't have an account? </p><a class="text_link" href="{{ url_for('sec.register')}}">Create one!</a>
            </div>
            <div>
                <br><p>Forgot your Password?</p> <a class="text_link" href="{{ url_for('sec.forgot_password')}}">Recover it!</a>
            </div class="text_link_container">
        </div>
        <div class="buttons">
            <input class="button" type="submit" name="login" value="Login" form=loginform>
            <input class="secondary_button" type="submit" name="use_as_guest" value="Use as Guest" form=loginform>
        </div>
    </form>
{% endblock %}
