<div class="block block-rounded">
    <div class="block-content block-content-full bg-gd-lake-op text-center">
        <a class="item item-circle mx-auto bg-black-25" href="javascript:void(0)">
            <i class="fa fa-2x fa-gamepad text-white"></i>
        </a>
        <p class="text-white font-size-h3 font-w300 mt-3 mb-0">
            <?php echo e(__('dcm.popular_categories')); ?>

        </p>
    </div>
    <div class="block-content block-content-full">

        <div class="block block-rounded block-bordered">

            <?php if(isset( $sidebar['categories'] )): ?>

                <ul class="nav nav-tabs nav-tabs-block" data-toggle="tabs" role="tablist">

                    <?php $__currentLoopData = $sidebar['categories']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $parentCategory): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <li class="nav-item <?php if($loop->first): ?> active <?php endif; ?>">
                            <a class="nav-link <?php if($loop->first): ?> active <?php endif; ?>" href="#cat-<?php echo e($parentCategory['id']); ?>"><?php echo e($parentCategory['title']); ?></a>
                        </li>
                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                </ul>
                <div class="block-content tab-content">

                    <?php $__currentLoopData = $sidebar['categories']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $parentCategory): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <div class="tab-pane <?php if($loop->first): ?> active <?php endif; ?>" id="cat-<?php echo e($parentCategory['id']); ?>" role="tabpanel">

                            <?php if( isset($parentCategory['child_categories'])): ?>
                                <ul class="list-unstyled">
                                    <?php $__currentLoopData = $parentCategory['child_categories']; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $category): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <?php if( @$category['parent_id'] == @$parentCategory['id']): ?>
                                                <li class="mb-3">
                                                    <a href="<?php echo e($category['page_url']); ?>" class="btn btn-block btn-outline-primary btn-sm text-left">
                                                            <i class="<?php echo e((isset($category['icon']) && $category['icon']) ? $category['icon'] : 'fab fa-google-play text-primary'); ?> mr-1"></i>
                                                            <strong><?php echo e($category['title']); ?> </strong>
                                                    </a>
                                                    </li>
                                        <?php endif; ?>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </ul>
                            <?php endif; ?>
                        </div>
                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                </div>

            <?php else: ?>
                <div><?php echo e(__('dcm.no_categoriy_configured')); ?></div>
            <?php endif; ?>


        </div>


    </div>
</div>