{{ define "main" }}
    {{ $pages := where .RegularPages "Type" "in" .Site.Params.mainSections }}
    {{ if (eq .Kind "home") }}
        {{ $pages = where .Site.RegularPages "Type" "in" .Site.Params.mainSections }}
    {{ end }}

    {{ $paginator := .Paginate $pages }}
    {{ range $paginator.Pages }}
    <article class="gblog-post">
        <header class="gblog-post__header">
            <h1><a href="{{ .RelPermalink }}">{{ partial "title" . }}</a></h1>
        </header>

        <section class="gblog-mar