/* xnx_mtab.css - 移动端底部Tab栏样式 */

/* 只在移动端显示 */
.xnx-mtab {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bs-body-bg);
    border-top: 1px solid var(--bs-border-color);
    z-index: 1030;
    padding-bottom: env(safe-area-inset-bottom);
    padding-bottom: constant(safe-area-inset-bottom);
    box-shadow: 0 -1px 8px rgba(0, 0, 0, 0.04);
    border-radius: 12px 12px 0 0;
}

.xnx-mtab-item {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.35rem 0;
    font-size: 14px;
    color: var(--bs-secondary-color);
    text-decoration: none;
    transition: color 0.15s ease;
    min-height: 50px;
    gap: 0.15rem;
    position: relative;
}

.xnx-mtab-item i {
    font-size: 1.3rem;
    transition: transform 0.15s ease;
}

.xnx-mtab-item span {
    line-height: 1;
    font-size: 0.75rem;
}

.xnx-mtab-item.active {
    color: var(--bs-primary);
}

.xnx-mtab-item.active i {
    transform: scale(1.05);
}

/* 中间发帖按钮凸起效果 */
.xnx-mtab-item.xnx-mtab-center {
    position: relative;
}

.xnx-mtab-item.xnx-mtab-center i {
    font-size: 1.75rem;
    color: var(--bs-primary);
}

.xnx-mtab-item.xnx-mtab-center.active i {
    transform: scale(1.1);
}

/* 消息徽章 */
.xnx-mtab-icon-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.xnx-mtab-badge {
    position: absolute;
    top: -4px;
    right: -8px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    background: var(--bs-danger);
    color: #fff;
    font-size: 0.65rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* 键盘弹起时隐藏 */
body.keyboard-active .xnx-mtab {
    display: none !important;
}

/* 移动端显示 */
@media (max-width: 991.98px) {
    .xnx-mtab {
        display: flex !important;
    }
    
    body {
        padding-bottom: 70px;
    }
}

/* 桌面端隐藏 */
@media (min-width: 992px) {
    .xnx-mtab {
        display: none !important;
    }
    
    body {
        padding-bottom: 0;
    }
}