{{ define "title" }}{{ .Title }} &ndash; {{ .Site.Title }}{{ end }}
{{ define "main" }}
  {{ .Content }}
  <div class="title-header">
    <h1>{{ .Title }}</h1>
  </div>
  {{- if gt (len .Sections) 0 }}
  <h2>Categories</h2>
    <ul class="section-list">
    {{- range .Sections }}
      <li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
    {{- end }}
    </ul>
  <h2>All Posts</h2>
  {{- end }}
  {{- $cs := .CurrentSection }}
  {{- with $cs }}
    {{- range (where .Site.RegularPages "Section" .Section) 