/*
Theme Name: Argon 黑凤梨
Theme URI: https://www.mrbp.cn
Description: Argon 子主题：霞鹜文楷 + Times New Roman，青紫渐变，黑凤梨笔记色
Author: 黑凤梨君
Template: argon
Version: 1.1.23
*/

@import url("https://cdn.jsdelivr.net/npm/lxgw-wenkai-webfont@1.7.0/style.css");

:root {
	--hf-brand-from: #00c4cc;
	--hf-brand-to: #7d2ae8;
	--hf-brand-gradient: linear-gradient(135deg, #00c4cc 0%, #7d2ae8 100%);
	--hf-text: #108593;
	--hf-text-active: #642eb9;
	--hf-green: #518871;
	--hf-red: #c00000;
	--hf-black: #111111;
}

html,
body,
.article,
.post-content,
.card,
.navbar,
.leftbar {
	font-family: "LXGW WenKai", "LXGW WenKai Lite", "Times New Roman", Times, "Noto Serif CJK SC", serif !important;
}

/* Argon 给顶栏菜单写死了 Open Sans，覆盖回楷体 */
.navbar-nav .nav-link,
#toolbar .navbar-brand {
	font-family: "LXGW WenKai", "LXGW WenKai Lite", "Times New Roman", Times, "Noto Serif CJK SC", serif !important;
}

code,
pre,
kbd,
samp,
.hljs,
.wp-block-code {
	font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace !important;
}

html.use-serif body {
	font-family: "LXGW WenKai", "LXGW WenKai Lite", "Times New Roman", Times, serif !important;
}

/* 页面改回偏白，关掉气氛色带来的染色 */
html body,
html.immersion-color body {
	--color-background: #f7f8fa;
	--color-foreground: #ffffff;
	--color-widgets: #ffffff;
	--color-widgets-disabled: #f1f2f4;
	--color-border: #e6e8eb;
	--color-border-on-foreground: #f3f4f6;
	--color-border-on-foreground-deeper: #eceef1;
}

html:not(.darkmode) body {
	background-color: #f7f8fa;
}

/* 品牌青紫渐变：只用于 Banner、顶栏、左侧抬头 */
.section-shaped .shape-primary,
.banner .shape-primary,
.shape.shape-primary {
	background: var(--hf-brand-gradient) !important;
}

.banner {
	position: relative;
	z-index: 0;
	isolation: isolate;
}
#content.site-content {
	position: relative;
	z-index: 1;
}
.banner .shape-style-1 span {
	display: none !important;
}
#hf-bubbles {
	position: absolute;
	inset: 0;
	z-index: 1;
	width: 100%;
	height: 100%;
	display: block;
	pointer-events: auto;
	touch-action: manipulation;
}
#banner .banner-container {
	position: relative;
	z-index: 2;
	pointer-events: none;
}

.navbar-horizontal.navbar-transparent,
.navbar-horizontal,
html:not(.darkmode) .navbar-horizontal.bg-white {
	background: linear-gradient(90deg, #00c4cc 0%, #7d2ae8 100%) !important;
}

#footer {
	background: var(--hf-brand-gradient) !important;
	color: #fff !important;
}
#footer a {
	color: #fff !important;
}

.iziToast.hf-toast-brand,
.iziToast[style*="2dce89"],
.iziToast[style*="45, 206, 137"],
.iziToast[style*="45,206,137"] {
	background: var(--hf-brand-gradient) !important;
	border-color: transparent !important;
}

/* 顶栏已有站名和菜单，去掉左侧重复的站点名/导航/搜索，把头像概览顶上来 */
#leftbar_part1 {
	height: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	overflow: hidden !important;
	border: none !important;
	box-shadow: none !important;
	opacity: 0 !important;
	pointer-events: none !important;
}
#leftbar_part1 > * {
	display: none !important;
}
#leftbar_part2 {
	margin-top: 0 !important;
	position: relative;
	z-index: 2;
}
#leftbar_below {
	position: relative;
	z-index: 1;
}

/* 半屏/平板（901–1099）：和宽屏一样整列吸顶，目录+分类在栏内一起滚 */
@media screen and (min-width: 901px) and (max-width: 1099px) {
	html.triple-column #content.site-content {
		display: flex;
		flex-wrap: wrap;
		align-items: flex-start;
	}
	html.triple-column #content > .page-information-card-container {
		flex: 0 0 100%;
		order: 0;
		width: 100%;
		max-width: 100%;
		box-sizing: border-box;
		padding-left: 280px;
		padding-right: 0;
	}
	html.triple-column #leftbar {
		order: 1;
		float: none;
		position: sticky;
		top: 80px;
		max-height: calc(100vh - 90px);
		overflow-x: hidden;
		overflow-y: auto;
		flex: 0 0 280px;
		width: 280px;
		z-index: 4;
		padding-right: 10px;
		-webkit-overflow-scrolling: touch;
	}
	html.triple-column #primary {
		order: 2;
		float: none;
		flex: 1 1 0%;
		min-width: 0;
		width: auto !important;
		max-width: calc(100% - 280px);
	}
	html.triple-column #leftbar_part2,
	html.triple-column #leftbar_part2.sticky {
		position: static !important;
		width: auto !important;
		top: auto !important;
		transform: none !important;
	}
	html.triple-column #leftbar_part2_inner {
		max-height: none !important;
		overflow: visible !important;
		height: auto !important;
	}
	html.triple-column body.leftbar-can-headroom.headroom---unpinned #leftbar {
		top: 10px;
		max-height: calc(100vh - 20px);
	}
}

#leftbar_below .card {
	margin-top: 15px;
	padding: 20px 25px;
}
#leftbar_below .card > h6 {
	margin-bottom: 15px;
}
#leftbar_below .card ul {
	list-style: none;
	padding-inline-start: 0;
	margin-bottom: 0;
}
#leftbar_below .card ul li {
	margin-bottom: 5px;
}
#leftbar_below .card ul.children {
	padding-left: 1em;
	margin-top: 5px;
}

@media screen and (min-width: 1100px) {
	html.triple-column #content.site-content {
		display: flex;
		flex-wrap: wrap;
		align-items: flex-start;
	}
	html.triple-column #content > .page-information-card-container {
		flex: 0 0 100%;
		order: 0;
		width: 100%;
		max-width: 100%;
		box-sizing: border-box;
		padding-left: 280px;
		padding-right: 280px;
	}
	html.triple-column #leftbar,
	html.triple-column #rightbar {
		float: none;
		position: sticky;
		top: 80px;
		max-height: calc(100vh - 90px);
		overflow-x: hidden;
		overflow-y: auto;
		flex: 0 0 280px;
		width: 280px;
		z-index: 4;
	}
	html.triple-column #leftbar {
		order: 1;
		padding-right: 10px;
	}
	html.triple-column #primary {
		order: 2;
		float: none;
		flex: 1 1 0%;
		min-width: 0;
		width: auto !important;
		max-width: calc(100% - 560px);
	}
	html.triple-column #rightbar {
		order: 3;
		padding-left: 0;
	}
	html.triple-column #leftbar_part2.sticky {
		position: static !important;
		width: auto !important;
		top: auto !important;
	}
	html.triple-column #leftbar_part2_inner {
		max-height: none;
		overflow: visible;
	}
	html.triple-column body.leftbar-can-headroom.headroom---unpinned #leftbar,
	html.triple-column body.leftbar-can-headroom.headroom---unpinned #rightbar {
		top: 10px;
		max-height: calc(100vh - 20px);
	}
}

html.triple-column #leftbar::-webkit-scrollbar,
html.triple-column #rightbar::-webkit-scrollbar {
	width: 6px;
}
html.triple-column #leftbar::-webkit-scrollbar-thumb,
html.triple-column #rightbar::-webkit-scrollbar-thumb {
	background-color: rgba(0, 0, 0, 0.2);
	border-radius: 3px;
}

/* 渐变底上的字保持白色，不被链接色盖掉 */
html:not(.darkmode) .navbar-horizontal a,
html:not(.darkmode) .navbar-horizontal .navbar-brand,
html:not(.darkmode) .banner-title,
html:not(.darkmode) .banner-title *,
html:not(.darkmode) .banner .banner-subtitle,
html:not(.darkmode) .leftbar-banner,
html:not(.darkmode) .leftbar-banner a,
html:not(.darkmode) .leftbar-banner-title,
html:not(.darkmode) .leftbar-banner-subtitle {
	color: #fff !important;
}

/* 文字：默认青 #108593，选中/悬停/当前页紫 #642eb9 */
html:not(.darkmode) a,
html:not(.darkmode) .post-title a,
html:not(.darkmode) .post-title,
html:not(.darkmode) a.post-title,
html:not(.darkmode) .text-primary {
	color: #108593;
}

html:not(.darkmode) a:hover,
html:not(.darkmode) a:focus,
html:not(.darkmode) a:active,
html:not(.darkmode) .post-title a:hover,
html:not(.darkmode) .current-menu-item > a,
html:not(.darkmode) .current_page_item > a,
html:not(.darkmode) .nav-pills .nav-link.active,
html:not(.darkmode) .leftbar-menu .active > a {
	color: #642eb9;
}

html:not(.darkmode) .navbar-horizontal a:hover,
html:not(.darkmode) .navbar-horizontal a:focus,
html:not(.darkmode) .navbar-horizontal .current-menu-item > a,
html:not(.darkmode) .navbar-horizontal .current_page_item > a {
	color: #fff !important;
}

::selection {
	color: #642eb9;
	background: rgba(100, 46, 185, 0.16);
}

::-moz-selection {
	color: #642eb9;
	background: rgba(100, 46, 185, 0.16);
}

.btn-primary {
	background: #108593 !important;
	border-color: #108593 !important;
	color: #fff !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
	background: #642eb9 !important;
	border-color: #642eb9 !important;
	color: #fff !important;
}

.page-item.active .page-link {
	background: #642eb9 !important;
	border-color: #642eb9 !important;
	color: #fff !important;
}

/* 评论「博主」白字 */
.badge-admin,
.comment-item-title .badge-admin,
.shuoshuo-comment-item-title .badge-admin {
	color: #fff !important;
	background: var(--hf-brand-gradient) !important;
	border: 0 !important;
}

mark.hf-mark-green,
.hf-mark-green {
	background: rgba(81, 136, 113, 0.22);
	color: #518871;
	padding: 0 0.15em;
	border-radius: 2px;
}

mark.hf-mark-red,
.hf-mark-red {
	background: rgba(192, 0, 0, 0.16);
	color: #c00000;
	font-weight: 700;
	padding: 0 0.15em;
	border-radius: 2px;
}

.leftbar-banner img,
.sidebar-user-pic img,
img.avatar {
	background: transparent;
}

/* WP 数学区块 Temml：Chrome 不画 menclose 顶线，用边框补循环节 */
.wp-block-math {
	overflow-y: visible;
	padding-top: 0.28em;
	padding-bottom: 0.12em;
}
.wp-block-math .tml-overline,
.wp-block-math menclose[notation="top"] {
	padding-top: 0.12em;
	border-top: 0.045em solid currentColor;
}
.wp-block-math .tml-underline,
.wp-block-math menclose[notation="bottom"] {
	padding-bottom: 0.08em;
	border-bottom: 0.045em solid currentColor;
}

.site-author-links {
	justify-content: center;
}
.site-author-links-item > a {
	text-align: center;
}
