/* ============================================================
 * 顶部导航栏消息铃铛 → Uiverse 铃铛组件（module-notify-bell）
 * 目标：.msg-center-nav .msg-news-icon（navbar 右侧，zibmsg 注入）
 *
 * 设计要点：
 * - 去掉父主题 .toggle-radius 黑色圆框 → 无边框 + transparent 底
 * - hover 仅显示极淡灰底色（"只留底色"）
 * - 铃铛颜色跟随文字色 currentColor（亮/暗主题自适应）
 * - 未读红点角标读取 data-badge（真实未读数）
 * ============================================================ */

/* ---- 外层容器：覆盖父主题 .toggle-radius 圆框 ---- */
.msg-center-nav .msg-news-icon.notification,
.msg-news-icon:not(.abs-right).notification {
    position: relative;
    width: auto;
    height: auto;
    border: none !important;                /* 去掉黑色圆框 */
    border-radius: 0 !important;
    background: transparent !important;      /* 无底色 */
    padding: 8px;                           /* 点击区域 */
    cursor: pointer;
    transition: background 300ms, transform 300ms;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
    box-shadow: none !important;
}

/* hover：只留淡淡底色 */
.msg-center-nav .msg-news-icon.notification:hover,
.msg-news-icon:not(.abs-right).notification:hover {
    background: rgba(170, 170, 170, 0.1);
}

/* hover 触发铃铛晃动 */
.msg-center-nav .msg-news-icon.notification:hover > .bell-container,
.msg-news-icon:not(.abs-right).notification:hover > .bell-container {
    animation: bell-animation 650ms ease-out 0s 1 normal both;
}

/* ---- 未读红点角标 ---- */
.msg-center-nav .msg-news-icon.notification::before,
.msg-news-icon:not(.abs-right).notification::before {
    content: attr(data-badge);
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 50%;
    background-color: #e74c3c;
    position: absolute;
    right: 2px;
    top: 2px;
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    box-sizing: border-box;
    line-height: 1;
}
.msg-center-nav .msg-news-icon.notification[data-badge]:not([data-badge=""])::before,
.msg-news-icon:not(.abs-right).notification[data-badge]:not([data-badge=""])::before {
    display: flex;
}

/* ---- Uiverse 铃铛本体 ---- */
.bell-container {
    position: relative;
    display: inline-block;
}
.bell {
    border: 2.17px solid currentColor;
    border-radius: 10px 10px 0 0;
    width: 15px;
    height: 17px;
    background: transparent;
    display: block;
    position: relative;
    top: -1px;
}
.bell::before,
.bell::after {
    content: "";
    background: currentColor;
    display: block;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    height: 2.17px;
}
.bell::before {
    top: 100%;
    width: 20px;
}
.bell::after {
    top: calc(100% + 4px);
    width: 7px;
}

@keyframes bell-animation {
    20%   { transform: rotate(15deg); }
    40%   { transform: rotate(-15deg) scale(1.1); }
    60%   { transform: rotate(10deg) scale(1.1); }
    80%   { transform: rotate(-10deg); }
    0%,100%{ transform: rotate(0deg); }
}
