<style>
.nav {
    --bs-nav-link-padding-x: 0.5rem;
}
.sb-sidenav .sb-sidenav-menu .nav .sb-sidenav-menu-heading {
    padding: 0.75rem 1rem 0.75rem;
}
#layoutSidenav #layoutSidenav_content {
    min-height: calc(100vh - 80px);
}
</style>
<div id="layoutSidenav_nav">
   <nav class="bg-juandmi sb-sidenav accordion sb-sidenav-dark" id="sidenavAccordion">
      <div class="sb-sidenav-menu">
         <div class="nav">
            {section name=table_data loop=$table_data}
            {if $table_data[table_data].visible > 0}
            <div class="sb-sidenav-menu-heading">{$table_data[table_data].headline}</div>
            {/if}
            {section name=inner loop=$table_data[table_data].inner}
            {if $table_data[table_data].inner[inner].link == '#'}
            <a class="nav-link collapsed" href="#" data-bs-toggle="collapse" data-bs-target="#collapse{$smarty.section.table_data.rownum}{$smarty.section.inner.rownum}" aria-expanded="false" aria-controls="collapse{$smarty.section.table_data.rownum}{$smarty.section.inner.rownum}">
            {else}
            <a class="nav-link" href="{$table_data[table_data].inner[inner].link}">
               {/if}
               <div class="sb-nav-link-icon"><i class="{$table_data[table_data].inner[inner].fontawesome}"></i></div>
               {$table_data[table_data].inner[inner].headline}
               {if $table_data[table_data].inner[inner].link == '#'}
               <div class="sb-sidenav-collapse-arrow"><i class="fas fa-angle-down"></i></div>
               {/if}
            </a>
            {section name=inner2 loop=$table_data[table_data].inner[inner].inner2}
            {if $smarty.section.inner2.rownum == 1}
            <div class="collapse" id="collapse{$smarty.section.table_data.rownum}{$smarty.section.inner.rownum}" aria-labelledby="headingOne" data-bs-parent="#sidenavAccordion">
               {/if}
               <nav class="sb-sidenav-menu-nested nav">
                  <a class="nav-link" href="{$table_data[table_data].inner[inner].inner2[inner2].link}">{$table_data[table_data].inner[inner].inner2[inner2].headline}</a>
               </nav>
               {if $smarty.section.inner2.last}
            </div>
            {/if}
            {/section}
            {/section}
            {/section}
         </div>
      </div>
      <div class="bg-juandmi sb-sidenav-footer">
         <div class="small">Eingeloggt als:</div>
         {$nav_name}
      </div>
   </nav>
</div>