<!DOCTYPE html>
<html>
    <head>
        {% block head %}
        <title>{% block title %}{{ SITENAME }}{% endblock %}</title>
        <meta charset="utf-8" />
        <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.0-beta1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-0evHe/X+R7YkIZDRvuzKMRqM+OrBnVFBL6DOitfPri4tjfHxaWutUpFmBp4vmVor" crossorigin="anonymous">
        <link href="{{ SITEURL }}/theme/deadsands/css/style.css" rel="stylesheet" />
        {% if FAVICON %}
        <link rel="shortcut icon" href="{{ SITEURL }}/{{ FAVICON }}" type="image/x-icon" />
        {% endif %}
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
        {% endblock head %}
        <meta name="description" content="{% block summary %}{% endblock %}" />
        {% block extrahead %}{% endblock %}
        {% if is_dm %}
        <style type="text/css">.dm { display: block !important; }</style>
        {% endif %}
    </head>

    <body id="index" class="archive">
       <div id='header_background'>
       <div class="header">
          <div class='sun'></div>
          <div class='title'><h1><a href="/">{{ SITENAME }}</a></h1></div>
            <ul class="nav">
               {% if self.is_dm() %}
                    <li><a href="{{ SITEURL }}/dm">DM</a></li>
               {% endif %}
               {% if DISPLAY_CATEGORIES_ON_MENU %}
               {% for category, articles in categories %}
                 {% if category != 'dm' %}
                    <li><a href="{{ SITEURL }}/{{ category.name }}">{{ category }}</a></li>
                 {% endif %}
               {% endfor %}
               {% endif %}
               {% if DISPLAY_PAGES_ON_MENU %}
               {% for p in pages %}
                    <li{% if p == page %} class="active"{% endif %}><a href="{{ SITEURL }}/{{ p.url }}">{{ p.title }}</a></li>
                {% endfor %}
                {% endif %}
               {% for m in MENU_ITEMS %}<li><a href="{{ SITEURL }}/{{ m[1] }}">{{ m[0] }}</a></li>{% endfor %}
            </ul>
       </div>
       </div>
       <div id='background'>
         <div class="container">
             {% block key_image %}{% endblock %}
             {% block content %}{% endblock %}
         </div>
         <footer id="contentinfo" class="footer">
            <nav class="pull-right bottom-nav">
                <a href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}">RSS</a>
              </nav>
              <address id="about" class="vcard body">
                 <!--
                 &copy; <a href="{{SITEURL}}">{{SITENAME}}</a> Proudly powered by <a href="http://getpelican.com/">Pelican</a>
                     -->
           </address><!-- /#about -->
          </footer><!-- /#contentinfo -->
      </div>
    </body>
    {% block is_dm %}{{ ' ' if 'localhost' in SITEURL else '' }}{% endblock %}
</html>