<!DOCTYPE html>
<html lang="de">
<head>

    <meta charset="UTF-8">
    {% block title %} <title>{{ config.WEBSITE_TITEL }}</title> {% endblock %}
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    {% load static %}

    <link rel="icon" href="{% static 'favicon.ico'%}">
    <link rel="apple-touch-icon" href="{% static 'favicon.ico'%}">


    <link rel="stylesheet" href="{% static 'css/bootstrap.min.css'%}" >
    <link rel="stylesheet" href="{% static 'css/styles.css' %}">
    <script src="{% static 'jquery-3.2.1.slim.min.js' %}" ></script>
    <script src="{% static 'popper.min.js' %}" ></script>
    <script src="{% static 'bootstrap.min.js' %}" ></script>
    <script src="{% static 'jquery.min.js' %}"></script>


    {% block script %}

    {% endblock %}
</head>
<body>

    {% if not embed %}
    {% block navbar %}
    <nav class="navbar navbar-expand-sm navbar-fixed-top" style="padding-left: 15px; padding-bottom: 0px; margin-bottom: 2px">
      <div class="container-fluid rounded-0" style="padding-left: 2px">
        <a class="navbar-brand navbar-right" href="{% url 'products' %}">
          <img src="{% static 'newMAB.png' %}" alt="MAB20" height="40px" width="auto" style="margin: auto; padding-bottom: 2px">
        </a>

        <button class="navbar-toggler" type="button " data-toggle="collapse" data-target="#navbarNavAltMarkup" aria-controls="navbarNavAltMarkup" aria-expanded="false" aria-label="Toggle navigation">
          <span class="navbar-toggler-icon"></span> ⋁
        </button>
        <div class="collapse navbar-collapse" id="navbarNavAltMarkup">

          <div class="navbar-nav navbar-right">
            <a class="nav-link active nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'products' %}">MARKTPLATZ</a>
            <a class="nav-link active nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'submit' %}">EINREICHEN</a>

            <a class=" nav-link active nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'about' %}">ÜBER UNS</a>
            {% if not user.is_authenticated %}
            <a class=" nav-link active nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'login' %}">EINLOGGEN</a>
            {% endif %}

            {% if user.is_authenticated %}
            <a class="nav-link nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'new-submit-view'%}?">PROJEKT EINREICHEN</a>
            <a class="nav-link nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'my-products'%}">MEINE PROJEKTE</a>
            <a class="nav-link nav-right boldkur" style="color: black;    font-weight: bold;" href="{% url 'logout'%}?next={{request.path}}">AUSLOGGEN</a>
            {% endif %}

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


    <div class="container-fluid">
        {% block content %}

        {% endblock %}
    </div>


 <div class="modal fade " id="LoginModal" tabindex="-1" role="dialog" aria-labelledby="LoginModal" aria-hidden="true">
     <div class="modal-dialog border border-dark rounded-0" role="document">
         <div class="modal-content rounded-0">
         <div class="modal-header">
        <h5 class="modal-title" id="exampleModalLabel">Bitte loggen Sie sich hier ein: </h5>
             <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">&times;</span>
        </button>
         </div>

          <div class="modal-body">

    <form method="post" action="{% url 'login' %}">
{% csrf_token %}



<div class="form-group " style="margin-top: 20px">

    <input type="text" class="form-control rounded-0" name="username" placeholder="username" />
</div>
        <div class="form-group">
    <input type="password" class="form-control rounded-0" name="password" placeholder="password">

</div>


<div>
  <input type="submit" class="btn btn-outline-secondary rounded-0 mybtn" value="login" />
  <input type="hidden" name="next" value="{{ next }}" />
</div>
</form>
          </div>

               <div class="modal-footer">
    <p><a href="{% url 'password_reset' %}">Passwort vergessen?</a></p>
               </div>
         </div>
</div>

</div>



</body>

<!-- Matomo -->
<script type="text/javascript">
  /*
  var _paq = _paq || [];
  _paq.push(['trackPageView']);
  _paq.push(['enableLinkTracking']);
  (function() {
    var u="https://piwik.juan-carlos.info/";
    _paq.push(['setTrackerUrl', u+'piwik.php']);
    _paq.push(['setSiteId', '4']);
    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
    g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
  })();
  */
</script>
<!-- End Matomo Code -->

</html>
