/* Keep the document scrollbar separate from embedded and third-party scrollers. */
html {
	--argon-scrollbar-thumb: #70798c;
	--argon-scrollbar-track: #edf0f6;
}

html.darkmode,
code[hljs-codeblock-inner] {
	--argon-scrollbar-thumb: #a1acc1;
	--argon-scrollbar-track: #252a34;
}

html,
#leftbar,
#leftbar_part2_inner,
.emotion-keyboard-bar,
.post-content pre,
code[hljs-codeblock-inner] {
	scrollbar-color: var(--argon-scrollbar-thumb) var(--argon-scrollbar-track);
}

body {
	scrollbar-color: auto;
}

#leftbar,
#leftbar_part2_inner,
.emotion-keyboard-bar,
.post-content pre,
code[hljs-codeblock-inner] {
	scrollbar-width: thin;
}

@supports not (scrollbar-color: auto) {
	#leftbar,
	#leftbar_part2_inner,
	.emotion-keyboard-bar,
	.post-content pre,
	code[hljs-codeblock-inner] {
		scrollbar-width: auto;
	}

	html::-webkit-scrollbar,
	html #leftbar::-webkit-scrollbar,
	html #leftbar_part2_inner::-webkit-scrollbar,
	html .emotion-keyboard-bar::-webkit-scrollbar,
	html .post-content pre::-webkit-scrollbar,
	html code[hljs-codeblock-inner]::-webkit-scrollbar {
		display: block;
		width: 8px;
		height: 8px;
	}

	html::-webkit-scrollbar-track,
	html #leftbar::-webkit-scrollbar-track,
	html #leftbar_part2_inner::-webkit-scrollbar-track,
	html .emotion-keyboard-bar::-webkit-scrollbar-track,
	html .post-content pre::-webkit-scrollbar-track {
		background: var(--argon-scrollbar-track);
	}

	html::-webkit-scrollbar-thumb,
	html #leftbar::-webkit-scrollbar-thumb,
	html #leftbar_part2_inner::-webkit-scrollbar-thumb,
	html .emotion-keyboard-bar::-webkit-scrollbar-thumb,
	html .post-content pre::-webkit-scrollbar-thumb {
		border: 1px solid var(--argon-scrollbar-track);
		border-radius: 8px;
		background: var(--argon-scrollbar-thumb);
	}

	/* Older copies of the base CSS served by CDNs set these with !important. */
	html code[hljs-codeblock-inner]::-webkit-scrollbar-track {
		background: var(--argon-scrollbar-track) !important;
	}

	html code[hljs-codeblock-inner]::-webkit-scrollbar-thumb {
		border: 1px solid var(--argon-scrollbar-track) !important;
		border-radius: 8px;
		background: var(--argon-scrollbar-thumb) !important;
	}
}

@media (forced-colors: active) {
	html,
	#leftbar,
	#leftbar_part2_inner,
	.emotion-keyboard-bar,
	.post-content pre,
	code[hljs-codeblock-inner] {
		scrollbar-color: auto;
		scrollbar-width: auto;
	}
}

.argon-skip-link:not(:focus) {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	white-space: nowrap;
}

.argon-skip-link:focus {
	position: fixed;
	inset-block-start: calc(0.75rem + var(--wp-admin--admin-bar--height, 0px));
	inset-inline-start: 0.75rem;
	z-index: 10000;
	display: block;
	padding: 0.65rem 1rem;
	border-radius: 0.4rem;
	background: #fff;
	color: #28334f;
	outline: 2px solid currentColor;
	outline-offset: 2px;
	text-decoration: underline;
}

html.darkmode .argon-skip-link:focus {
	background: #252a34;
	color: #f2f5fc;
}

@media screen and (max-width: 900px) {
	html:not(.leftbar-opened) #leftbar {
		visibility: hidden;
	}
}

@media screen and (max-width: 900px) and (prefers-reduced-motion: reduce) {
	#leftbar,
	#sidebar_mask {
		transition: none;
	}
}

#main {
	scroll-margin-block-start: calc(5rem + var(--wp-admin--admin-bar--height, 0px));
}

#main:focus-visible {
	outline: 2px solid var(--themecolor, currentColor);
	outline-offset: 4px;
}

/* Give both identified and external cover images the same reserved crop. */
.post-header .argon-post-cover {
	display: block;
	height: max(250px, 25vh);
}

.post-full .post-header .argon-post-cover {
	height: max(250px, 30vh);
}

.post-preview-layout-3 .post-header .argon-post-cover {
	height: max(250px, 20vh);
}

article.post-preview-layout-2 .post-header-with-thumbnail {
	min-height: 250px;
}

article.post-preview-layout-2 .post-header .argon-post-cover {
	position: absolute;
	inset: 0;
	height: 100%;
}

#banner {
	isolation: isolate;
}

#argon_banner_cover,
.argon-banner-background {
	position: absolute;
	inset: 0;
	pointer-events: none;
}

#argon_banner_cover {
	z-index: -1;
}

.argon-banner-background {
	background-position: center;
	background-repeat: no-repeat;
	background-size: cover;
}

.argon-banner-image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

#banner > .banner-container {
	position: relative;
}

.post-content .argon-table-scroll,
.post-content .wp-block-table,
.post-content pre:not(.hljs-codeblock-fullscreen) {
	min-inline-size: 0;
	max-inline-size: 100%;
	overflow-x: auto;
}

.argon-table-scroll:focus-visible {
	outline: 2px solid var(--themecolor, currentColor);
	outline-offset: 2px;
}

/* Keep author-specified wide classic tables inside the article without JS. */
html.no-js .post-content {
	overflow-x: auto;
}

@media screen and (max-width: 900px) {
	html.argon-compact-mobile-banner:has(#main.argon-reading-page) #banner {
		height: auto;
		margin-bottom: 14px;
		padding: 4.65rem 0 1.1rem;
	}

	html.argon-compact-mobile-banner:has(#main.argon-reading-page) #banner_container {
		height: auto !important;
	}

	html.argon-compact-mobile-banner:has(#main.argon-reading-page) #banner .banner-title {
		position: static;
		transform: none;
		padding-inline: 0.5rem;
		font-size: clamp(1.125rem, 0.9rem + 1vw, 1.6rem);
		overflow-wrap: anywhere;
	}

	html.argon-compact-mobile-banner:has(#main.argon-reading-page) #content {
		margin-top: 0;
	}

	#primary,
	#main,
	.post-header,
	.post-content,
	.post-content-container {
		min-inline-size: 0;
	}

	.post-header .post-title,
	.post-content {
		overflow-wrap: anywhere;
	}

	.post-content pre {
		overflow-wrap: normal;
	}

	.post-full .post-header .post-title {
		font-size: clamp(1.25rem, 1rem + 1.3vw, 1.65rem);
		line-height: 1.35;
	}

	article.post .post-header .argon-post-cover {
		height: clamp(9rem, 28vh, 15rem);
		height: clamp(9rem, 28svh, 15rem);
		min-height: 0;
		max-height: none;
	}

	article.post-preview-layout-2 .post-header .argon-post-cover {
		height: 100%;
	}
}

@media screen and (max-width: 600px) {
	article.post-preview-layout-2 {
		flex-direction: column;
	}

	article.post-preview-layout-2 .post-header.post-header-with-thumbnail {
		width: 100%;
		min-height: auto;
		border-radius: var(--card-radius) var(--card-radius) 0 0;
	}

	article.post-preview-layout-2 .post-header .argon-post-cover {
		position: static;
		height: 10rem;
	}

	article.post-preview-layout-2 .post-content-container {
		padding: 1rem;
	}

	.post-full .post-header.post-header-with-thumbnail .post-header-text-container {
		position: static;
		padding: 0.9rem 1rem 0;
		opacity: 1;
		background: none;
		color: var(--color-text-deeper);
	}

	.post-full .post-header.post-header-with-thumbnail .post-header-text-container .post-title {
		display: block;
		margin-top: 0;
		color: var(--color-text-deeper) !important;
		filter: none;
	}
}

@media screen and (max-width: 450px) {
	#fabtn_blog_settings_popup {
		width: auto;
		min-width: 0;
		overflow-y: auto;
	}

	#fabtn_blog_settings_popup .blog-setting-item {
		flex-wrap: wrap;
		row-gap: 0.35rem;
	}
}
