<?php include __DIR__ . '/copyright.php'; ?>
<nav class="app-tabbar">
    <a href="<?php echo $this->url('mobile'); ?>" class="app-tabbar-item <?php echo $currentPage === 'home' ? 'active' : ''; ?>">
        <span class="app-tabbar-icon iconify" data-icon="mdi:home"></span>
        <span class="app-tabbar-text">首页</span>
    </a>
    <a href="<?php echo $this->url('mobile/hot'); ?>" class="app-tabbar-item <?php echo $currentPage === 'hot' ? 'active' : ''; ?>">
        <span class="app-tabbar-icon iconify" data-icon="mdi:flame"></span>
        <span class="app-tabbar-text">热门</span>
    </a>
    <a href="<?php echo $this->url('mobile/publish'); ?>" class="app-tabbar-publish">
        <span class="app-tabbar-icon-publish"></span>
    </a>
    <a href="<?php echo $this->url('mobile/messages'); ?>" class="app-tabbar-item <?php echo $currentPage === 'messages' ? 'active' : ''; ?>">
        <span class="app-tabbar-icon iconify" data-icon="mdi:message-circle"></span>
        <span class="app-tabbar-text">消息</span>
        <?php if (isset($unreadCount) && $unreadCount > 0): ?>
        <span class="unread-badge"><?php echo $unreadCount > 99 ? '99+' : $unreadCount; ?></span>
        <?php endif; ?>
    </a>
    <a href="<?php echo $this->url('mobile/profile'); ?>" class="app-tabbar-item <?php echo $currentPage === 'profile' ? 'active' : ''; ?>">
        <span class="app-tabbar-icon iconify" data-icon="mdi:account"></span>
        <span class="app-tabbar-text">我的</span>
    </a>
</nav>