{% load staticfiles %}
<!DOCTYPE html>
<html lang="{{ LANGUAGE_CODE }}">
    <head>
        <meta charset="utf-8" />
        <title>{% block head_title_base %}{% if SITE_NAME %}{{ SITE_NAME }} | {% endif %}{% block head_title %}{% endblock %}{% endblock %}</title>
        {% block viewport %}
            <meta name="viewport" content="width=device-width, initial-scale=1.0">
        {% endblock %}

        {% block styles %}{% endblock %}

        {% block html5shim %}
            <!-- HTML5 shim, for IE6-8 support of HTML elements -->
            <!--[if lt IE 9]>
                <script src="https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.2/html5shiv.min.js"></script>
            <![endif]-->
        {% endblock %}

        {% block extra_head_base %}
            {% block extra_head %}{% endblock %}
        {% endblock %}
    </head>
    <body class="{% block body_class %}{% endblock %}" id="{% block body_id %}{% endblock %}" {% block body_extra_attributes %}{% endblock %}>
        <div class="{% block wrapper_class %}{% endblock %}">

            {% block topbar_base %}
                <header>
                    <div class="navbar navbar-default {% block navbar_class %}navbar-fixed-top{% endblock %}">
                        <div class="container">
                        {% block topbar %}
                            <div class="navbar-header">
                                <button class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                                    <span class="fa fa-bars"></span>
                                </button>
                                {% block site_brand %}<a class="navbar-brand" href="{% url "home" %}">{{ SITE_NAME }}</a>{% endblock %}
                            </div>
                            <div class="collapse navbar-collapse navbar-responsive-collapse">
                                {% block nav %}
                                    {% comment %}
                                        <ul class="nav navbar-nav">
                                            <li><a href="#tab_one">One</a></li>
                                            <li><a href="#tab_two">Two</a></li>
                                        </ul>
                                    {% endcomment %}
                                {% endblock %}
                                {% block account_bar %}{% include "_account_bar.html" %}{% endblock %}
                            </div>
                        {% endblock %}
                        </div>
                    </div>
                </header>
            {% endblock %}

            {% block body_base %}
                <section id="content_body">
                    <div class="container">
                        {% include "_messages.html" %}
                        {% block body %}
                        {% endblock %}
                    </div>
                </section>
            {% endblock %}

            {% block footer_base %}
                <hr />
                <footer>
                    <div class="container">
                        {% block footer %}{% endblock %}
                    </div>
                </footer>
            {% endblock %}
        </div>

        {% block scripts %}{% endblock %}

        {% block theme_script %}
            <script src="{% static "pinax/js/theme.js" %}"></script>
        {% endblock %}

        {% block extra_body_base %}
            {% block extra_body %}{% endblock %}
        {% endblock %}
    </body>
</html>
