<div id="body-overlay"></div>
<nav id="navbar">
    <div id="menutoggle">
        {{$icon := resources.Get "images/icons/menu.svg"}}
        <img class="w-20 h-20 m-20" src="{{$icon.Permalink}}" />
    </div>
    <div class='left bg-white h-full'>
        {{ $logo := resources.Get .Site.Params.Logo }}
        <a href="{{.Site.BaseURL}}"><img class="m-b-0" src="{{ $logo.Permalink }}" alt="COOPGO" /></a>
    </div>
    <div class='center bg-white'>
        <ul class="flex-row j-center ai-center">
            {{ $pages := where .Site.RegularPages.ByDate "Type" "in" .Site.Params.mainPages }}
            {{ range $pages }}
            <li class="max-w-200 h-full">
                <a href="{{ .Permalink }}">{{ .Title }}</a>
            </li>
            {{ end }}
        </ul>
    </div>
    <div class='{{ if ne (relURL .URL) ("/" | safeHTML) }}bg-primary{{ end }} right w-400'>
        <ul class="flex-row j-center ai-center">
            <li>
                {{ $gotogether := resources.Get "images/gotogether-lemag.svg" }}
                <a href="/gotogether/">
                    <img src="{{ $gotogether.Permalink }}" alt="GO TOGETHER le mag" />
                </a>
            </li>
            {{ if eq (relURL .URL) ("/" | safeHTML) }}<li><a href="#section4">NOS PROJETS</a></li>{{ end }}
        </ul>
    </div>
</nav>

<nav id="sidebar">
    <div class="m-20 ta-c">
        {{ $logo := resources.Get .Site.Params.Logo }}
        <a href="{{.Site.BaseURL}}"><img class="max-w-150" src="{{ $logo.Permalink }}" alt="COOPGO" /></a>
    </div>
    <div>
        <ul>
            {{ $pages := where .Site.RegularPages.ByDate "Type" "in" .Site.Params.mainPages }}
            {{ range $pages }}
            <li>
                <a href="{{ .Permalink }}">{{ .Title }}</a>
            </li>
            {{ end }}
        </ul>
    </div>
    <div class='bg-primary p-10'>
        <ul>
            <li style="list-style: none;">
                {{ $gotogether := resources.Get "images/gotogether-lemag.svg" }}
                <a href="/gotogether/">
                    <img class="h-25" src="{{ $gotogether.Permalink }}" alt="GO TOGETHER le mag" />
                </a>
            </li>
            {{ if eq (relURL .URL) ("/" | safeHTML) }}<li style="list-style: none;"><a class="white brand" href="#section4">NOS PROJETS</a></li>{{ end }}
        </ul>
    </div>
</nav>