<!DOCTYPE html>
<html lang="en">

{% include head.html %}

{% assign showSubmenu = false %}
{% for item in site.data.header-menu.items %}
    {% if item.items %}
        {% if page.url == item.link %}
            {% assign showSubmenu = true %}
        {% elsif page.parent_link == item.link %}
            {% assign showSubmenu = true %}
        {% endif %}
    {% endif %}
{% endfor %}
<body>
{% include header.html %}
<div id="main" class="{% if showSubmenu %}submenu{% endif %}">
    {% if site.data.notification.show %}
        <div class="container my-3">
            <div class="alert alert-{{ site.data.notification.type }}" role="alert">
                {{ site.data.notification.text }}
            </div>
        </div>
    {% endif %}
    <div class="container">
        <div class="row">
            <main class="col{% if page.hidesidebar %}{% else %}-lg-8{% endif %}">
                {{ content }}
            </main>
            {% if page.hidesidebar %}
            {% else %}
            <div class="col-lg-4">
                <div id="sidebar">
                    {% include sidebar.html %}
                </div>
            </div>
            {% endif %}
        </div>
        <button id="back-to-top"
                class="btn btn-primary btn-lg{% if page.hidesidebar %} no-sidebar{% endif %}"
                title="Click to return to the start of the page" data-toggle="tooltip" data-placement="left">
            <span class="fas fa-chevron-up"></span>
        </button>
    </div>
</div>
{% include footer.html %}
</body>
</html>
