<div class="content-body">
    <%- partial(theme.theme_desktop + '/components/selector-major-categories',
            {category: 'categories'}) %>

    <div class="mew___categories_cat-categories page-container">
        <div class="wrap">
            <div class="category-container">
                <div class="cat-group">
                    <h3><%= _p('index.intro') %></h3>
                    <ul>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'get-started'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/get-started.svg', {alt: ''}) %>
                                    <p><%= _p('index.get_started') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'get-started'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'diving-deeper'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/diving-deeper.svg', {alt: ''}) %>
                                    <p><%= _p('index.diving_deeper') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'diving-deeper'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'security-and-privacy'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/security-and-privacy.svg', {alt: ''}) %>
                                    <p><%= _p('index.security_privacy') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'security-and-privacy'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                    </ul>
                </div>
                <div class="cat-group">
                    <h3><%= _p('index.access_wallet') %></h3>
                    <ul>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'mewwallet'}).posts.filter(function(post){return post.lang == page.lang;}).sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/mewconnect.svg', {alt: ''}) %>
                                    <p><%= _p('index.mewwallet') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'mewwallet'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'hardware-wallets'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/hardware-wallet.svg', {alt: ''}) %>
                                    <p><%= _p('index.hardware_wallet') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'hardware-wallets'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a href="<%- url_for_lang(site.categories.findOne({name: 'mewconnect'}).posts.filter(function(post){return post.lang == page.lang;}).sort('date', 1).data[0].path) %>">
                                <div>
                                    <%- image_tag('images/mew-icons/mewconnect.svg', {alt: ''}) %>
                                    <p><%= _p('index.mewconnect') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'mewconnect'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'migration'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/migrating.svg', {alt: ''}) %>
                                    <p><%= _p('index.migrating') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'migration'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>

                    </ul>
                </div>
                <div class="cat-group">
                    <h3><%= _p('index.functions') %></h3>
                    <ul>
                        <li>
                            <a
                                    href=" <%- url_for_lang(site.categories.findOne({name: 'token'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/tokens.svg', {alt: ''}) %>
                                    <p><%= _p('index.tokens') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({name: 'token'}).posts.length
                                            %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a href="<%- url_for_lang(site.categories.findOne({name: 'offline'}).posts.sort('date', 1).data[0].path) %>">
                                <div>
                                    <%- image_tag('images/mew-icons/offline.svg', {alt: ''}) %>
                                    <p><%= _p('index.offline') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'offline'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a href="<%- url_for_lang(site.categories.findOne({name: 'networks-and-nodes'}).posts.sort('date', 1).data[0].path) %>">
                                <div>
                                    <%- image_tag('images/mew-icons/network.svg', {alt: ''}) %>
                                    <p><%= _p('index.network_and_nodes') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'networks-and-nodes'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'transactions'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/transactions.svg', {alt: ''}) %>
                                    <p><%= _p('index.transactions') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({
                                                name:
                                                        'transactions'
                                            }).posts.length %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'swap'}).posts.sort('date', 1).data[0].path) %> "
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/swap.svg', {alt: ''}) %>
                                    <p><%= _p('index.swap') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({name: 'swap'}).posts.length
                                            %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a
                                    href="<%- url_for_lang(site.categories.findOne({name: 'dapps'}).posts.sort('date', 1).data[0].path) %>"
                            >
                                <div>
                                    <%- image_tag('images/mew-icons/ens.svg', {alt: ''}) %>
                                    <p><%= _p('index.dapps') %></p>
                                    <div class="post-counter">
                                        <p>
                                            <%= site.categories.findOne({name: 'dapps'}).posts.length
                                            %>
                                        </p>
                                    </div>
                                </div>
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
            <!-- .category-container -->
        </div>
        <%- partial(theme.theme_desktop + '/components/bottom-helpers') %>
    </div>
</div>
