/* 消息中心样式 */

/* 桌面端消息中心按钮样式 */
.message-center-trigger {
    position: relative;
    margin-left: 5px;
}

.message-center-trigger .fa-envelope {
    font-size: 14px;
}

/* 桌面端未读消息徽章 */
.message-unread-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff4757;
    color: white;
    border-radius: 50%;
    min-width: 18px;
    height: 18px;
    font-size: 10px;
    line-height: 18px;
    text-align: center;
    font-weight: bold;
    animation: pulse 2s infinite;
    z-index: 10;
}

/* 移动端消息中心样式 */
.mobile-message-center {
    position: relative;
}

.mobile-message-center a {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: inherit;
    padding: 8px 4px;
}

.mobile-message-center .fa-envelope {
    font-size: 20px;
    margin-bottom: 4px;
}

.mobile-message-center span:last-child {
    font-size: 12px;
    line-height: 1;
}

/* 移动端未读消息徽章 */
.mobile-message-badge {
    position: absolute;
    top: 0px;
    right: 8px;
    background: #ff4757;
    color: white;
    border-radius: 50%;
    min-width: 16px;
    height: 16px;
    font-size: 9px;
    line-height: 16px;
    text-align: center;
    font-weight: bold;
    animation: pulse 2s infinite;
    z-index: 10;
    border: 1px solid white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* 脉冲动画 */
@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* 响应式调整 */
@media (max-width: 768px) {
    .message-center-trigger {
        margin-left: 3px;
    }
    
    .message-center-trigger .fa-envelope {
        font-size: 12px;
    }
    
    .message-unread-badge {
        min-width: 16px;
        height: 16px;
        font-size: 9px;
        line-height: 16px;
        top: -3px;
        right: -3px;
    }
}

/* 悬停效果 */
.message-center-trigger:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.mobile-message-center a:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

/* 活跃状态 */
.message-center-trigger:active,
.mobile-message-center a:active {
    transform: scale(0.95);
}