:root {
	--content-width: 900px;
	--page-side-margin: 10px;
	--content-max-width: 70ch;

	/* 320+ px */
	--article-side-margin: 16px;

	@media (min-width: 680px) {
		--article-side-margin: 48px;
	}
	@media (min-width: 1400px) {
		--content-max-width: 80ch;
	}
}

h2 {
	margin-block-start: calc(0.83em * 2.25);
}
h3 {
	margin-block-start: calc(1em * 2.25);
}
h4 {
	margin-block-start: calc(1.33em * 2);
}
h5 {
	margin-block-start: calc(1.67em * 1.75);
}
h6 {
	margin-block-start: calc(2.33em * 1.75);
}
ul > li {
	margin-block: 0.7em;
}

body {
	font-family: sans-serif;
	margin: 40px var(--page-side-margin);
}
.footer-container {
	max-width: var(--content-width);
}
.header-inner,
.footer-inner,
.footer-bottom {
	padding: 0 var(--article-side-margin);
}
.post_article p {
	line-height: 1.5;
}
.post_article {
	max-width: var(--content-width);
	font-size: 1rem;
	padding: var(--article-side-margin);
}
.article-content {
	max-width: val(--content-max-width);
}
.article-cover {
	margin: 0;
	width: calc(
		100%
		+ var(--article-side-margin) * 2
		+ var(--page-side-margin) * 2
	);
	position: relative;
	left: calc(0px - var(--article-side-margin) - var(--page-side-margin));
	max-width: none;
}
.article-cover img {
	max-width: 100%;
}
#post_main_art_caption {
	margin-top: 0;
	margin-left: calc(var(--article-side-margin) + var(--page-side-margin));
}
.credits-font-style {
	font-size: 0.85em;
	color: #707070;
}
body.dark-mode .credits-font-style {
	color: #bababa !important;
}

/* Theme Toggle Button */
.theme-toggle {
	position: fixed;
	top: 20px;
	right: 20px;
	width: 40px;
	height: 40px;
	padding: 0;
	border: none;
	background: transparent;
	cursor: pointer;
	z-index: 1000;
	display: flex;
	align-items: center;
	justify-content: center;
	
	/* Initially hidden off-screen */
	transform: translateX(100px);
	opacity: 0;
	transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
}

.theme-toggle.visible {
	/* Elegant slide-in animation */
	transform: translateX(0);
	opacity: 1;
}

.theme-toggle-icon {
	position: relative;
	width: 20px;
	height: 20px;
	display: block;
}

.theme-toggle-icon::before,
.theme-toggle-icon::after {
	content: '';
	position: absolute;
	width: 10px;
	height: 10px;
	background-color: #333;
	border-radius: 2px;
	transition: background-color 0.3s ease;
}

.theme-toggle-icon::before {
	top: 0;
	left: 0;
}

.theme-toggle-icon::after {
	bottom: 0;
	right: 0;
}

body.dark-mode .theme-toggle-icon::before,
body.dark-mode .theme-toggle-icon::after {
	background-color: #fff;
}