<main class="wrapper-lg stack-xl">
    <h1>{{ title }}</h1>

    <aside class="inverse text-center">
        <p class="mx-auto">
            Subscribe via <a href="{{feed.rss}}">RSS</a>, <a href="{{feed.atom}}">Atom</a>, or <a href="{{feed.json}}">JSON</a>.
        </p>
    </aside>

    <ol class="stack-xl" role='list'>
        {% for item in posts %}
        <li class="stack-xs">
            <h2><a href="{{ item.url }}">{{ item.data.title | safe }}</a></h2>
            <time class="block" datetime="{{ item.date | dateToRfc3339 }}">{{ item.date | dateDisplay }}</time>
            <p class="e-content p-summary">{{ item | excerpt }}</p>
            <ul role="list" class="tags">
                {% for t in item.data.tags | except("posts") | except("draft") %}
                <li><a href="/post/tag/{{ t }}" rel="tag">#{{ t }}</a></li>
                {% endfor %}
            </ul>
            <a href="{{ item.url }}" class="inline-block">Read more</a>
        </li>
        {% endfor %}
    </ol>
    {% if not tag %}
    <nav class="blog-nav row" data-spacing="between" aria-label="View more posts">
        {% if pagination.href.next %}
            <a href="{{ pagination.href.next }}">Older</a>
        {% endif %}
        {% if pagination.href.previous %}
            <a href="{{ pagination.href.previous }}">Newer</a>
        {% endif %}
    </nav>
    {% endif %}
</main>