/* ==== MJJZZ-JAN-OVERRIDES (standalone, loaded by plugin/jan/hook/header_link_after.htm) ====
   这个文件放"必须稳定生效"的站点级覆盖，不放主题变量与组件本体。
   原因：plugin/jan/css/mjjzz-ui.css 仍在被并行会话反复整份改写（21:15 曾被覆盖一次，
   我加过的 CRUMB-FRAME / NAV-THEME-RIGHT 两块都被写掉），所以这类小覆盖单独成文件，
   由 header_link_after 以 filemtime 版本号引入，改一次即破缓存。 */


/* ==== 1) CRUMB-FRAME-2026-11-27 BEGIN ====
   给面包屑外层加一个浅底背景框：白底 + 1px 描边 + 直角 + 与主栏同宽。
   mjjzz-ui.css（header.inc.htm 第 67 行）在本 hook（第 64 行）之后加载，且对 .breadcrumb
   写了 background/border/padding 的 !important（特异性 0-1-0）；这里统一用 html body 前缀
   把特异性提到 0-1-2，才能在相同 !important 下压过它，不依赖加载顺序。 */
html body .breadcrumb,
html body .breadcrumb:hover{
	display:flex;
	align-items:center;
	flex-wrap:wrap;
	min-height:36px;
	padding:8px 12px !important;
	margin:0 0 12px !important;
	background:var(--mjj-surface,#fff) !important;
	background-image:none !important;
	border:1px solid var(--mjj-border,#e9edf5) !important;
	border-radius:0 !important;
	box-shadow:none !important;
	font-size:12.5px;
	line-height:18px;
}
html body .breadcrumb-item,
html body .breadcrumb-item a{
	color:var(--mjj-text-muted,#64748b) !important;
	font-size:12.5px;
	transition:color .16s ease;
}
html body .breadcrumb-item a:hover{color:var(--mjj-brand-hover,#0f7fb8) !important;}
html body .breadcrumb-item.active,
html body .breadcrumb-item.active a{color:var(--mjj-text-strong,#0f172a) !important;font-weight:500;}
html body .breadcrumb-item.active a{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
html body .breadcrumb-item + .breadcrumb-item::before{content:"/";padding:0 8px;color:#cbd5e1;}
html[data-theme="dark"] body .breadcrumb,
html[data-theme="dark"] body .breadcrumb:hover{
	background:var(--mjj-surface,#171b21) !important;
	border-color:var(--mjj-border,#2b333f) !important;
}
html[data-theme="dark"] body .breadcrumb-item,
html[data-theme="dark"] body .breadcrumb-item a{color:var(--mjj-text-muted,#9aa6b6) !important;}
html[data-theme="dark"] body .breadcrumb-item.active,
html[data-theme="dark"] body .breadcrumb-item.active a{color:var(--mjj-text-strong,#e8edf5) !important;}
html[data-theme="dark"] body .breadcrumb-item + .breadcrumb-item::before{color:#3b444f;}
@media (max-width:767.98px){
	html body .breadcrumb{padding:7px 10px !important;}
}
/* ==== 1) CRUMB-FRAME-2026-11-27 END ==== */


/* ==== 2) NAV-THEME-RIGHT-2026-11-27 BEGIN ====
   宽屏（≥1400px）把"深色/浅色"开关贴到窗口最右上角；窄屏保持跟在搜索后，避免压住内容。
   #header 是 position:fixed，天然是绝对定位的包含块。 */
@media (min-width:1400px){
	#header #nav > .navbar-nav:not(.me-auto) > .mjj-theme-item{
		position:absolute !important;
		right:14px !important;
		top:50% !important;
		transform:translateY(-50%) !important;
		margin:0 !important;
		padding:0 !important;
		border:0 !important;
		height:auto !important;
		z-index:6 !important;
	}
}
/* 默认不描边、不铺底；悬停/键盘聚焦时再显出可点区域 */
#header #nav .mjj-theme-item .mjj-theme-toggle{
	background:transparent !important;
	border-color:transparent !important;
	color:rgba(203,213,225,.72) !important;
}
#header #nav .mjj-theme-item .mjj-theme-toggle:hover,
#header #nav .mjj-theme-item .mjj-theme-toggle:focus-visible{
	background:rgba(255,255,255,.09) !important;
	border-color:rgba(255,255,255,.18) !important;
	color:#fff !important;
}
/* ==== 2) NAV-THEME-RIGHT-2026-11-27 END ==== */


/* ==== 3) NAV-MSG-AFTER-SEARCH-2026-11-27 BEGIN ====
   右组条目顺序：搜索 → 消息 → 签到 →（登录/注册）→ 用户菜单；深色开关在 ≥1400px 时绝对定位到最右上角。
   mjjzz-ui.css 里的 NAV-LAYOUT 块用同特异性(2-3-0)写了 order，且那个文件在本 hook 之后加载，
   同权重同名次时后者胜 —— 所以这里加 html body 前缀把权重提到 (2-3-2)，并保留 !important。 */
html body #header #nav > .navbar-nav:not(.me-auto) > .mjj-search-nav-item{order:0 !important;}
html body #header #nav > .navbar-nav:not(.me-auto) > .usernotice{order:10 !important;}
/* ==== 3) NAV-MSG-AFTER-SEARCH-2026-11-27 END ==== */

/* ==== 4) POST-TITLE-AFTER-UID-2026-11-27 BEGIN ====
   评论区（.postlist）用户名那一行：把「称号系统」徽章 .gacha-badge--inline 从签名下面提到 UID 后面同一行，
   签名 (comment-signature-inline) 强制独占一行。
   父容器（.media-body > .d-flex 里的第一个 div）本来就是 flex/wrap，这里只补宽度与 order，不动 DOM。 */
html body .card-postlist .postlist .media-body > .d-flex > div:first-child{
	display:flex;
	flex-wrap:wrap;
	align-items:center;
	column-gap:8px;
	row-gap:2px;
	flex:1 1 auto;
	min-width:0;
}
html body .card-postlist .postlist .media-body > .d-flex > div:first-child > .username{order:1;}
html body .card-postlist .postlist .media-body > .d-flex > div:first-child > .post-user-uid{order:2;}
html body .card-postlist .postlist .media-body > .d-flex > div:first-child > .mjj-vip-badge{order:3;}
html body .card-postlist .postlist .media-body > .d-flex > div:first-child > .gacha-badge--inline{
	order:4;
	margin:0 !important;
	align-self:center;
}
html body .card-postlist .postlist .media-body > .d-flex > div:first-child > .comment-signature-inline{
	order:5;
	flex:0 0 100%;
	width:100%;
	margin:3px 0 0 !important;
}
/* ==== 4) POST-TITLE-AFTER-UID-2026-11-27 END ==== */

/* ==== CARD-V2-2026-11-28 BEGIN ==== */
/* 帖子页右侧作者卡：头像+身份横排 / 2×2 统计 / 注册天数 页脚（覆盖 mjjzz-ui.css 的旧卡样式） */
html body .thread-aside-sticky .thread-author-card{padding:16px 16px 14px !important;background:var(--mjj-surface,#fff) !important;border:1px solid var(--mjj-border,#e9edf5) !important;border-radius:0 !important;box-shadow:none !important}
html body .thread-aside-sticky .thread-author-card__head{display:flex !important;align-items:flex-start !important;gap:12px !important;padding:0 0 12px !important;border:0 !important;text-align:left !important}
html body .thread-aside-sticky .thread-author-card__avatar-link{flex:0 0 64px !important;width:64px !important;height:64px !important;border-radius:0 !important;overflow:hidden !important;display:block !important;position:relative !important;line-height:0 !important}
html body .thread-aside-sticky .thread-author-card__avatar{width:64px !important;height:64px !important;object-fit:cover !important;border-radius:0 !important;box-shadow:none !important;display:block !important;background:var(--mjj-surface-2,#f4f6fb) !important}
html body .thread-aside-sticky .thread-author-card__id{flex:1 1 auto !important;min-width:0 !important}
html body .thread-aside-sticky .thread-author-card__name{margin:0 0 6px !important;font-size:16px !important;font-weight:700 !important;line-height:1.25 !important;text-align:left !important;letter-spacing:0 !important}
html body .thread-aside-sticky .thread-author-card__name a{color:var(--mjj-text-strong,#1f2937) !important;text-decoration:none !important;background:none !important;border:0 !important;padding:0 !important;background-image:none !important}
html body .thread-aside-sticky .thread-author-card__name a:hover{color:var(--mjj-brand,#1294d7) !important}
html body .thread-aside-sticky .thread-author-card__meta{display:flex !important;flex-wrap:wrap !important;align-items:center !important;justify-content:flex-start !important;gap:4px !important;margin:0 0 6px !important;padding:0 !important}
html body .thread-aside-sticky .thread-author-card__uid,
html body .thread-aside-sticky .thread-author-card__role,
html body .thread-aside-sticky .thread-author-card__tag{display:inline-flex !important;align-items:center !important;height:18px !important;padding:0 6px !important;font-size:11px !important;font-weight:500 !important;line-height:1 !important;border-radius:0 !important;border:1px solid var(--mjj-border,#e9edf5) !important;background:var(--mjj-surface-2,#f8fafc) !important;color:var(--mjj-text-muted,#64748b) !important;white-space:nowrap !important}
html body .thread-aside-sticky .thread-author-card__tag{background:#1f2937 !important;border-color:#1f2937 !important;color:#fff !important;font-weight:600 !important}
/* 商家标签（与帖子列表 / 用户名旁的「商家」同一语义色，但收敛成 18px 小签） */
html body .thread-aside-sticky .thread-author-card__merch{display:inline-flex !important;align-items:center !important;height:18px !important;padding:0 6px !important;font-size:11px !important;font-weight:600 !important;line-height:1 !important;border-radius:0 !important;border:1px solid #f0c987 !important;background:#fbd38d !important;color:#8a4a0d !important;white-space:nowrap !important;text-decoration:none !important}
html body .thread-aside-sticky .thread-author-card__merch:hover{background:#f8c76f !important;border-color:#e9b45a !important;color:#7a3f08 !important;text-decoration:none !important}
html body .thread-aside-sticky .thread-author-card__joined{font-size:11.5px !important;line-height:1.4 !important;color:var(--mjj-text-muted-2,#94a3b8) !important;text-align:left !important}
html body .thread-aside-sticky .thread-author-card__badges{display:flex !important;flex-wrap:wrap !important;align-items:center !important;gap:6px !important;padding:0 0 12px !important}
html body .thread-aside-sticky .thread-author-card__badges .gacha-badge{margin:0 !important}
html body .thread-aside-sticky .thread-author-card__bio{margin:0 0 12px !important;padding:10px 0 0 !important;border:0 !important;border-top:1px solid var(--mjj-border,#e9edf5) !important;font-size:12.5px !important;line-height:1.7 !important;color:var(--mjj-text,#475569) !important;text-align:left !important;display:-webkit-box !important;-webkit-line-clamp:3 !important;-webkit-box-orient:vertical !important;overflow:hidden !important;word-break:break-word !important}
html body .thread-aside-sticky .thread-author-card__stats{display:grid !important;grid-template-columns:repeat(2,minmax(0,1fr)) !important;gap:0 !important;padding:0 !important;margin:0 0 12px !important;border:1px solid var(--mjj-border,#e9edf5) !important;border-width:1px 0 0 1px !important}
html body .thread-aside-sticky .thread-author-card__stat{display:flex !important;flex-direction:column !important;align-items:flex-start !important;gap:2px !important;padding:9px 10px !important;text-align:left !important;border:1px solid var(--mjj-border,#e9edf5) !important;border-width:0 1px 1px 0 !important}
html body .thread-aside-sticky .thread-author-card__stat-label{font-size:11.5px !important;line-height:1.2 !important;color:var(--mjj-text-muted,#64748b) !important}
html body .thread-aside-sticky .thread-author-card__stat-value{font-size:16px !important;font-weight:700 !important;line-height:1.2 !important;color:var(--mjj-text-strong,#1f2937) !important;font-variant-numeric:tabular-nums !important}
html body .thread-aside-sticky .thread-author-card__foot{display:flex !important;align-items:center !important;justify-content:space-between !important;padding:10px 0 8px !important;border:0 !important;border-top:1px solid var(--mjj-border,#e9edf5) !important}
html body .thread-aside-sticky .thread-author-card__foot-label{font-size:12px !important;color:var(--mjj-text-muted,#64748b) !important}
html body .thread-aside-sticky .thread-author-card__foot-value{font-size:12.5px !important;font-weight:600 !important;color:var(--mjj-text-strong,#1f2937) !important;font-variant-numeric:tabular-nums !important}
html body .thread-aside-sticky .thread-author-card__actions{display:flex !important;gap:8px !important;padding:10px 0 0 !important;border:0 !important;border-top:1px solid var(--mjj-border,#e9edf5) !important}

html[data-theme="dark"] body .thread-aside-sticky .thread-author-card{background:var(--mjj-surface,#171b21) !important;border-color:var(--mjj-border,#2b333f) !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__name a{color:var(--mjj-text-strong,#e8edf4) !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__uid,
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__role{background:var(--mjj-surface-2,#12161c) !important;border-color:var(--mjj-border,#2b333f) !important;color:var(--mjj-text-muted,#9aa6b6) !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__tag{background:#e8edf4 !important;border-color:#e8edf4 !important;color:#12161c !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__merch{background:#4a3512 !important;border-color:#6d4f1c !important;color:#f5c26b !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__merch:hover{background:#5a4116 !important;border-color:#856020 !important;color:#ffd88a !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__joined{color:#7d8797 !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__bio{color:#c3ccd9 !important;border-top-color:#2b333f !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__stats{border-color:#2b333f !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__stat{border-color:#2b333f !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__stat-label{color:#9aa6b6 !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__stat-value{color:#e8edf4 !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__foot{border-top-color:#2b333f !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__foot-label{color:#9aa6b6 !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__foot-value{color:#e8edf4 !important}
html[data-theme="dark"] body .thread-aside-sticky .thread-author-card__actions{border-top-color:#2b333f !important}
html body .thread-aside-sticky .thread-author-card__badges .gacha-badge{font-size:11.5px !important;height:20px !important;padding:0 6px !important;border-radius:0 !important;margin:0 !important}
html body .thread-aside-sticky .thread-author-card__name .tt-vip-name--author-card::after{font-size:11px !important;padding:1px 6px !important;letter-spacing:0 !important;vertical-align:2px !important}/* ==== CARD-V2-2026-11-28 END ==== */

/* ==== MODAL-FAB-2026-11-28 BEGIN ====
   窄屏下主题开关是「左下角悬浮圆钮」（z-index 9990），弹窗（Bootstrap z-index 1055）打开时
   会压住私信输入框/表情按钮。这里：① 弹窗打开时直接收起；② 平时也压到弹窗层级之下。 */
@media (max-width: 991.98px) {
	html body .mjj-theme-item {
		z-index: 1030 !important;
	}

	body.modal-open .mjj-theme-item,
	body.modal-open .mjj-theme-toggle {
		display: none !important;
	}
}
/* ==== MODAL-FAB-2026-11-28 END ==== */
