/* KaKa API · 顶栏扩展样式
   公告面板 + 语言下拉（挂在 body 末尾, position: fixed, JS 算位置）
*/
.notify-popover, .lang-popover{position:fixed;top:0;left:0;
  background:#fff;border:1px solid #e5e9f0;border-radius:14px;padding:0;
  box-shadow:0 16px 48px rgba(15,23,42,.16),0 2px 8px rgba(15,23,42,.06);
  display:none;overflow:hidden;z-index:9999}
.notify-popover.open, .lang-popover.open{display:flex}
.notify-popover{flex-direction:column;width:380px;max-width:94vw;max-height:560px}
.lang-popover{flex-direction:column;width:170px;padding:6px}

/* 箭头(指回触发按钮),通过内嵌元素实现 */
.pop-arrow{position:absolute;top:-7px;right:18px;width:14px;height:14px;background:#fff;
  border-left:1px solid #e5e9f0;border-top:1px solid #e5e9f0;transform:rotate(45deg);z-index:-1}

/* 顶栏返回按钮: 36px 方框, 跟铃铛并排, 浅色下跟随主题色 */
.tb-back{
  width:36px;height:36px;border-radius:8px;
  display:inline-grid;place-items:center;
  color:var(--txt-dim);font-size:18px;line-height:1;
  text-decoration:none;cursor:pointer;
  transition:.15s;border:1px solid transparent;
  position:relative;
}
.tb-back:hover{ background:var(--bg-2); color:var(--txt); border-color:var(--line); }
.tb-back:active{ transform:translateX(-1px); }
.tb-back .arr{ display:inline-block; transform:translateX(0); transition:transform .15s; }
.tb-back:hover .arr{ transform:translateX(-2px); }

/* ==== 公告头 ==== */
.notify-head{display:flex;align-items:center;justify-content:space-between;padding:13px 16px;border-bottom:1px solid #eef0f4;flex-shrink:0;background:#fff}
.notify-head .h{display:flex;align-items:center;gap:10px}
.notify-head .bell{width:34px;height:34px;border-radius:9px;background:linear-gradient(135deg,#4a7dff,#8a5cff);display:grid;place-items:center;color:#fff;font-size:16px;box-shadow:0 4px 12px rgba(74,125,255,.3)}
.notify-head .tt-block{display:flex;flex-direction:column;gap:1px;line-height:1.2}
.notify-head .tt{font-size:14.5px;font-weight:600;color:#1a1d24}
.notify-head .cnt{font-size:11.5px;color:#8b95a7}
.notify-head .cnt b{color:#4a7dff;font-weight:600}
.notify-head .acts{display:flex;gap:8px;align-items:center}
.btn-mark{padding:5px 10px;border-radius:7px;font-size:11.5px;background:linear-gradient(135deg,#4a7dff,#8a5cff);color:#fff;font-weight:500;cursor:pointer;border:none;transition:.15s;box-shadow:0 2px 8px rgba(74,125,255,.25)}
.btn-mark:hover{filter:brightness(1.08)}
.btn-mark:disabled{opacity:.5;cursor:default;filter:none}
.btn-close{width:28px;height:28px;border-radius:7px;background:transparent;border:none;color:#8b95a7;display:grid;place-items:center;cursor:pointer;font-size:14px;line-height:1}
.btn-close:hover{background:#f3f5f9;color:#1a1d24}

/* ==== 公告列表 ==== */
.notify-list{flex:1;overflow-y:auto;padding:4px 0;background:#fff}
.notify-list::-webkit-scrollbar{width:6px}
.notify-list::-webkit-scrollbar-thumb{background:#d6dde7;border-radius:3px}
.notify-list::-webkit-scrollbar-track{background:transparent}
.notify-item{display:flex;align-items:flex-start;gap:11px;padding:12px 16px;cursor:pointer;transition:.12s;border-left:3px solid transparent;position:relative;user-select:none}
.notify-item:hover{background:#fafbfc}
.notify-item.unread{border-left-color:#4a7dff;background:linear-gradient(90deg,rgba(74,125,255,.05),transparent 60%)}
.notify-icon{width:36px;height:36px;border-radius:9px;display:grid;place-items:center;color:#fff;font-size:16px;flex-shrink:0;box-shadow:0 2px 6px rgba(0,0,0,.08)}
.notify-icon.info{background:linear-gradient(135deg,#4a7dff,#6366f1)}
.notify-icon.urgent{background:linear-gradient(135deg,#ef4444,#b91c1c)}
.notify-icon.policy{background:linear-gradient(135deg,#22c55e,#16a34a)}
.notify-body{flex:1;min-width:0}
.notify-meta{display:flex;align-items:center;gap:7px;margin-bottom:3px;flex-wrap:wrap}
.notify-meta .ttl{font-size:13px;font-weight:600;color:#1a1d24;line-height:1.35}
.notify-unread-dot{display:inline-block;padding:1px 6px;border-radius:999px;background:rgba(74,125,255,.14);color:#4a7dff;font-size:10px;font-weight:600}
.notify-time{font-size:11px;color:#aab2c0;margin-top:1px;display:block}
.notify-body p{font-size:12px;color:#5b6478;margin:4px 0 0;line-height:1.55;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.notify-arrow{color:#c3ccd9;font-size:18px;flex-shrink:0;align-self:center;font-weight:300}

.notify-empty{padding:50px 20px;text-align:center;color:#8b95a7}
.notify-empty .ic{font-size:42px;margin-bottom:10px;opacity:.4}
.notify-empty .t{font-size:13.5px}

/* ==== 公告详情 ==== */
.notify-detail{padding:18px 20px;background:#fff;flex:1;overflow-y:auto;display:flex;flex-direction:column}
.notify-detail .back{padding:6px 12px;border-radius:7px;background:#f3f5f9;font-size:12px;color:#5b6478;cursor:pointer;border:none;margin-bottom:14px;display:inline-flex;align-items:center;gap:6px;align-self:flex-start}
.notify-detail .back:hover{background:#eaeef5;color:#1a1d24}
.notify-detail .kicker{display:inline-flex;align-items:center;gap:5px;padding:3px 10px;border-radius:999px;font-size:11px;font-weight:600;margin-bottom:10px;align-self:flex-start}
.notify-detail .kicker.info{background:rgba(74,125,255,.14);color:#4a7dff}
.notify-detail .kicker.urgent{background:rgba(239,68,68,.14);color:#ef4444}
.notify-detail .kicker.policy{background:rgba(34,197,94,.14);color:#10b981}
.notify-detail h3{font-size:16px;font-weight:600;margin:0 0 8px;color:#1a1d24;line-height:1.4}
.notify-detail .meta{font-size:11.5px;color:#aab2c0;margin-bottom:14px;display:flex;align-items:center;gap:5px}
.notify-detail .content{font-size:13px;line-height:1.75;color:#5b6478;white-space:pre-wrap;flex:1}

/* ==== 底部分割的"全部查看"链接 ==== */
.notify-foot{padding:10px 16px;border-top:1px solid #eef0f4;background:#fafbfc;flex-shrink:0;text-align:center}
.notify-foot a{font-size:12px;color:#4a7dff;cursor:pointer}
.notify-foot a:hover{text-decoration:underline}

/* ==== 语言下拉 ==== */
.lang-item{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px 11px;border-radius:7px;font-size:13px;cursor:pointer;color:#1a1d24;transition:.12s}
.lang-item:hover{background:#f3f5f9}
.lang-item.active{color:#4a7dff;background:rgba(74,125,255,.06);font-weight:500}
.lang-item .nm{display:flex;align-items:center;gap:8px}
.lang-item .flag{font-size:14px}
.lang-item .chk{color:#4a7dff;font-size:13px;font-weight:bold}

/* 铃铛未读红点(不显示数字,只用红点表示) */
.tb-icon.has-unread .dot{display:block}
.tb-icon:not(.has-unread) .dot{display:none}

/* 遮罩(只遮页面,不动 panel) */
.kk-backdrop{position:fixed;inset:0;z-index:9998;background:transparent}
