{%- extends "basic/layout.html" %}
    {%- block extrahead %}
        {{ super() }}
        <meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9">
        {% if favicon %}
            <link rel="shortcut icon" href="{{ pathto('_static/' + favicon, 1) }}">
        {% endif %}
        <link href='http://fonts.googleapis.com/css?family=Open+Sans:300,400,700' rel='stylesheet' type='text/css'>
        <link href='http://fonts.googleapis.com/css?family=Droid+Sans+Mono:400,500,700' rel='stylesheet' type='text/css'>
    {% endblock %}

    {%- block relbar1 %}{% endblock %}
    {%- block relbar2 %}{% endblock %}

    {%- block sidebar2 %}
        <aside>

            {% if theme_logo %}
            <a href="{{ pathto('index') }}" id="logo" title={{project}}><img class="logo" src="{{ pathto('_static/' + theme_logo, 1) }}" width="150px" height="150px" title={{project}} /></a>
            {% endif %}
            
            {{ toctree() }}

            {% if theme_github %}
            <ul>
                <li><a href="https://github.com/{{theme_github}}">Github</a></li>
            </ul>
            {% endif %}

            {%- include "searchbox.html" %}
        </aside>
    {% endblock %}

    {%- block footer %}
        <div class="footer">
            {{ copyright }}
        </div>

        {% if theme_analytics_id %}
        <script>
            (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
            (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
            m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
            })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

            ga('create', '{{theme_analytics_id}}', 'auto');
            ga('require', 'displayfeatures');
            ga('send', 'pageview');
        </script>
        {% endif %}
    {%- endblock %}
