/* Core styles that are needed across all 'versions' of the layout. That means we need the simplest styles here, and the
 * size-related styles will appear in other stylesheets. This isn't always easy
 * to do.
 */

@import url('pygments.css');

/* define global variables */
:root {
	--main-fg-color: #837B83;
	--main-background: #0e1930;
	--main-font-family: "Fira Sans", "Liberation Sans", "Droid Sans", "Helvetica", "Arial", sans-serif;
	--main-font-size: 62.5%;
	--main-body-width: 90em;

	/* HEADER VARS */
	--header-link-color: #6cf;
	--header-tagline-color: #2865bc;
	--header-shadow-color: #173981;
	--header-hover-link-color: #fff;
	--header-hover-shadow-color: #0086e8;

	/* NAV VARS */
	--nav-link-color: #e46598;
	--nav-shadow-color: #50146f;
	--nav-active-color: #f90;
	--nav-active-shadow-color: #e46598;
	--nav-hover-link-color: #fff;
	--nav-hover-shadow-color: #0086e8;

	/* CONTENT VARS */
	--filter-color: #0086e8;
	--feed-link-color: #f90;
	--feed-link-shadow-color: #e46598;
	--feed-hover-link-color: #fff;
	--feed-hover-link-shadow-color: #0086e8;

	--article-background-color: #999999;
	--article-color: #0e1930;
	--article-link-color: #006fdc;
	--article-visited-link-color: #173981;
	--article-hover-link-color: #fff;

	--article-title-link-color: #50146f;
	--article-title-link-visited-color: var(--article-title-link-color);
	--article-meta-color: #4c4d65;

	--article-code-font-family: "Fira Mono", monospace;
	--article-code-background-color: #b1d6e3;
	--article-code-border-color: var(--article-code-background-color);
	--article-kbd-background-color: #182869;
	--article-kbd-color: #e0ecf0;
	--article-spoiler-label-color: #fe831b;
	--article-spoiler-background-color: #1a478b;
	--article-spoiler-reveal-color: #67ace0;
	--article-footnote-hilite-color: #fff;
	--article-tags-color: #36394e;

	/* TAG CLOUD VARS */
	--tagcloud-border-color: #9977a0;
	--tagcloud-background-color: #fff;
	--tagcloud-color: #000099;
	--tagcloud-badge-background-color: #66ccff;
	--tagcloud-badge-color: #000099;
	--tagcloud-shadow-color: #9977a0;
	--tagcloud-hover-border-color: #880000;
	--tagcloud-hover-background-color: #fea;
	--tagcloud-hover-color: #880000;
	--tagcloud-hover-badge-background-color: #fe831b;
	--tagcloud-hover-badge-color: #880000;
	--tagcloud-hover-shadow-color: var(--tagcloud-shadow-color);

	/* PAGER VARS */
	--pager-color: #0086e8;
	--pager-link-color: #f90;
	--pager-visited-link-color: #e46598;
	--pager-hover-link-color: #fff;

	/* FOOTER VARS */
	--footer-color: #0086e8;
	--footer-link-color: #f90;
	--footer-visited-link-color: #e46598;
	--footer-hover-link-color: #fff;
}

/* Account for anything that doesn't understand HTML 5. */
header, section, article, aside, nav, footer {
	display: block;
	margin: 0;
	padding: 0;
}

/* Common styling every size shares. */
html {
	background: var(--main-background);
	font-family: var(--main-font-family);
	font-size: 16px;
	font-weight: normal;
	min-height: 100%;
	margin: 0;
	padding: 0;
}

body {
	font-size: var(--main-font-size);
	margin: 0;
	padding: 0.8em 1.6em;
}

/* Fluid images */
img, object, svg {
	max-width: 100%;
	height: auto;
}

#top {
	background-position: top left;
	background-repeat: no-repeat;
}

#top h1 {
	font-size: 1em;
	font-weight: normal;
	line-height: 1;
	margin: 0;
	text-align: center;
}

#top h1 a:link,
#top h1 a:active {
	color: var(--header-link-color);
	text-decoration: none;
	text-shadow: 0 0 0.8em var(--header-shadow-color);
	font-size: 3.5em;
}

#top h1 a:visited {
	color: var(--header-link-color);
	text-decoration: none;
}

#top p {
	margin: 0.3em 0 0 0;
	color: var(--header-tagline-color);
	line-height: 1;
	padding: 0;
	text-align: center;
	font-size: 1.4em;
}

#menu {
	margin: 1em auto 0 auto;
}

#menu ul {
	list-style: none;
	display: flex;
	justify-content: center;
	margin: 0;
	padding: 0;
}

#menu ul li {
	line-height: 1.3;
	font-size: 2.4em;
	margin-right: 0.7em;
}

#menu ul li a:link,
#menu ul li a:active {
	text-decoration: none;
	color: var(--nav-link-color);
	text-shadow: 0 0 0.5em var(--nav-shadow-color);
}

#menu ul li a:visited {
	text-decoration: none;
	color: var(--nav-link-color);
}

#menu ul li.active a:link,
#menu ul li.active a:active {
	color: var(--nav-active-color);
	text-shadow: 0 0 0.8em var(--nav-active-shadow-color);
}

#menu ul li.active a:visited {
	color: var(--nav-active-color);
	text-decoration: none;
}

.filter {
	font-weight: normal;
	text-align: center;
	color: var(--filter-color);
	font-size: 1.5em;
	margin: 1em auto;
}

.filter strong {
	color: #00cbff;
}

.feed:link,
.feed:active {
	color: var(--feed-link-color);
	text-shadow: 0 0 0.8em var(--feed-link-shadow-color);
}

.feed:visited {
	color: var(--feed-link-color);
}

#content :first-child.entry {
	margin-top: 1.6em;
}

article.entry {
	color: var(--article-color);
	background: var(--article-background-color);
	border-width: 0;
	border-radius: 0.8em;
	padding: 0.8em;
	margin: 0 0 2.4em 0;
	box-shadow: 0 0.25em 0.25em var(--article-color);
}

.entry a:link,
.entry a:active {
	color: var(--article-link-color);
	text-decoration: none;
}

.entry a:hover {
	text-decoration: underline;
}

.entry a:visited {
	color: var(--article-visited-link-color);
	text-decoration: none;
}

.entry-title {
	margin: 0;
	line-height: 1;
	font-weight: 600;
	font-size: 2.4em;
}

.entry-title a:link,
.entry-title a:active {
	color: var(--article-title-link-color);
	text-decoration: none;
}

.entry-title a:visited {
	color: var(--article-title-link-visited-color);
}

.entry-meta {
	color: var(--article-meta-color);
	margin-top: .5em;
	font-size: 1.2em;
}

.entry-content > p,
.footnote ol {
	line-height: 1.4;
	text-align: justify;
	font-size: 1.3em;
}

.right-outset {
	float: right;
	margin: 0 0 .8em 1.6em;
	max-width: 50%;
	overflow: auto;
}

.left-outset {
	float: left;
	margin: 0 1.6em .8em 0;
	max-width: 50%;
	overflow: auto;
}

.entry-content .right-outset p,
.entry-content .left-outset p {
	line-height: 1.4;
	margin: 0;
	text-align: center;
	font-size: 1.1em;
}

/* Kill unnecessary top margins when meta data isn't present */
#page .entry-content p:first-of-type {
	margin-top: 0;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
	margin: 0;
}

.entry-content h1 + p,
.entry-content h2 + p,
.entry-content h3 + p,
.entry-content h4 + p {
	margin-top: .3em;
}

.entry-content h1 {
	font-size: 2.1em;
}

.entry-content h2 {
	font-size: 1.9em;
}

.entry-content h3 {
	font-size: 1.7em;
}

.entry-content h4 {
	font-size: 1.5em;
}

.entry-content > blockquote {
	font-size: 1.3em;
}

.entry-content blockquote {
	background-color: rgba(37, 129, 228, 0.1);
	margin: 0 3.2em;
	padding: .1em 1.6em;
	border-radius: 1.6em;
}

.entry-content pre {
	font-family: var(--article-code-font-family);
	background-color: var(--article-code-background-color);
	overflow: auto;
	border: 1px solid #b1d6e3;
	margin: 0 2em;
	padding: .2em .4em;
	border-radius: .4em;
	font-size: 1.2em;
}

.entry-content pre code {
	font-family: inherit;
}

.entry-content kbd {
	background-color: var(--article-kbd-background-color);
	color: var(--article-kbd-color);
	padding: .13em .3em;
	border-radius: .25em;
}

.entry-content > ol,
.entry-content > ul,
.entry-content > dl {
	list-style-position: outside;
	padding: 0 0 0 4.8em;
	margin: 1.6em 0;
}

.entry-content > ol > li,
.entry-content > ul > li,
.entry-content > dl > dd {
	font-size: 1.3em;
}


.entry-content > dl > dt {
	font-weight: bold;
	font-size: 1.3em;
}

.entry-content abbr {
	text-decoration: none;
	border-bottom: 1px dotted;
	cursor: help;
}

.footnote-ref:before {
	content: "Note ";
}

.footnote-ref {
	white-space: nowrap;
}

.footnote {
	border-top: 1px dashed;
}

.footnote ol {
	list-style: decimal;
	margin: 0;
	padding: 0 0 0 3.2em;
}

.footnote ol li:target {
	background: var(--article-footnote-hilite-color);
}

.spoiler {
	color: var(--article-spoiler-background-color);
	background-color: var(--article-spoiler-background-color);
	padding: .1em .4em;
	border-radius: .4em;
}

.spoiler:before {
	color: var(--article-spoiler-label-color);
	font-weight: bold;
	content: "Spoiler: ";
}

.spoiler:hover {
	color: var(--article-spoiler-reveal-color);
}

/* One of the few elements that should look pretty universal across the
 * layouts. */
.entry-content sup {
	font-size: inherit;
	vertical-align: inherit;
	border: 1px solid;
	border-radius: .3em;
	background: #fff;
	padding: 0 0.2em;
	margin: 0 .1em;
}

.entry-tags {
	color: var(--article-tags-color);
	text-align: right;
	margin: 0;
	font-size: 1.3em;
	line-height: 1.3;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
	margin: 0;
}

.entry-content > :last-child {
	margin-bottom: 0;
}

.paginator {
	display: grid;
	font-size: 1.4em;
	text-align: center;
	color: var(--pager-color);
	grid-template-areas: "newest new label old oldest";
	grid-template-columns: 20% 20% 20% 20% 20%;
	width: 85%;
	margin: 1em auto;
}

.paginator .oldest {
	grid-area: oldest;
	text-align: right;
}

.paginator .older {
	grid-area: old;
	text-align: right;
}

.paginator .label {
	grid-area: label;
	text-align: center;
}

.paginator .newer {
	grid-area: new;
	text-align: left;
}

.paginator .newest {
	grid-area: newest;
	text-align: left;
}

.paginator a:link,
.paginator a:active {
	color: var(--pager-link-color);
	text-decoration: none;
	margin: 0 2em;
}

.paginator a:visited {
	color: var(--pager-visited-link-color);
	text-decoration: none;
}

.paginator a:hover {
	color: var(--pager-hover-link-color);
	text-decoration: underline;
}

body > footer {
	text-align: center;
	color: var(--footer-color);
	font-size: 1.3em;
}

body > footer ul {
	list-style: none;
	padding: 0;
}

body > footer a:link,
body > footer a:active {
	color: var(--footer-link-color);
	text-decoration: none;
}

body > footer a:visited {
	color: var(--footer-visited-link-color);
	text-decoration: none;
}

body > footer a:hover {
	color: var(--footer-hover-link-color);
	text-decoration: underline;
}

.support-bar a {
	font-size: 10px;
	margin: 0 .5em;
	position: relative;
	text-align: center;
}

.support-icon {
	border-radius: 9px;
	box-shadow: 0 4px 4px #b133da;
	width: 3.2em;
	height: 3.2em;
}

.support-bar a span {
	display: none;
}

.support-bar a:hover span {
	display: block;
	position: absolute;
	bottom: 4em;
	font-size: 1.2em;
	white-space: nowrap;
	background: #fff;
	color: #172663;
	border-radius: 0.5em;
	padding: 0.3em 0.5em;
	box-shadow: 0 2px 4px #172663;
	text-align: center;
	transform: translate(calc(-50% + 16px));
}

.support-bar a:hover span:after {
	width: 0;
	height: 0;
	border-width: .5em;
	border-color: #fff transparent transparent transparent;
	border-style: solid;
	content: "";
	display: block;
	position: absolute;
	bottom: -0.9em;
	left: calc(50% - 0.5em);
}

/* For pygments support */
/* .highlight should not be modifying the box layout */
.highlight {
	border: 0;
	margin: 0;
	padding: 0;
	background-color: transparent !important;
}

ul.tagcloud {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	margin: 0;
	padding: 0 !important;
}

.tagcloud li {
	margin: 0.4em 0.3em;
}

.tagcloud li a:link,
.tagcloud li a:active {
	color: var(--tagcloud-color);
	padding: 0.1em 0.15em;
	background: var(--tagcloud-background-color);
	border-radius: 0 .4em .4em 0;
	text-decoration: none;
	border: 1px solid var(--tagcloud-border-color);
	box-shadow: 0 0.1em 0.25em var(--tagcloud-shadow-color);
}

.tagcloud .tag-1 a { font-size: 280%; }
.tagcloud .tag-2 a { font-size: 210%; }
.tagcloud .tag-3 a { font-size: 150%; }
.tagcloud .tag-4 a { font-size: 100%; }

.tagcloud span.badge {
	color: var(--tagcloud-badge-color);
	background-color: var(--tagcloud-badge-background-color);
	border: 0px;
	border-radius: 0.4em;
	padding: 0 .2em;
}

.tagcloud li a:hover {
	background-color: var(--tagcloud-hover-background-color);
	color: var(--tagcloud-hover-color);
	border: 1px solid var(--tagcloud-hover-border-color);
	box-shadow: 0 0.1em 0.25em var(--tagcloud-hover-shadow-color);
}

.tagcloud li a:hover span.badge {
	background-color: var(--tagcloud-hover-badge-background-color);
	color: var(--tagcloud-hover-badge-color);
}
