<?php
$categories = $block['categories'];
$target     = $block['target'];
?>

<div class="article-block-hot-category">
    <div class="row">
        <div class="col-md-6">
            <?php $i = 0; ?>
            <?php foreach ($categories as $category) { ?>
                <?php if ($i++ % 2 == 0) { ?>
                    <div class="text-muted">
                        <a target="<?php echo $this->escape($target); ?>"
                           href="<?php echo $this->escape($category['url']); ?>" style="color: #48484C">
                            <?php echo $this->escape($category['title']); ?>
                        </a>
                    </div>
                <?php } ?>
            <?php } ?>
        </div>
        <div class="float-right col-md-6">
            <?php $j = 0; ?>
            <?php foreach ($categories as $category) { ?>
                <?php if ($j++ % 2 == 1) { ?>
                    <div class="text-muted">
                        <a target="<?php echo $this->escape($target); ?>"
                           href="<?php echo $this->escape($category['url']); ?>" style="color: #48484C">
                            <?php echo $this->escape($category['title']); ?>
                        </a>
                    </div>
                <?php } ?>
            <?php } ?>
        </div>
    </div>
</div>

<script>
    $('.article-block-hot-category').parent().addClass('block-nopadding');
</script>
