:root {
	--page-background: #f5f5f5;
	
	--text-color: #28303c;
	--text-color-faded: #28303c75;
	--text-color-extra-faded: #6d7c9467;
	--text-shadow-color: #1414141a;
	
	--selection-background: rgba(251, 255, 40, 0.412); 
	
	--blockquote-background-color: rgba(231, 231, 231, 0.15);
	--blockquote-leading-color: var(--link-color);	
	
	--hr-border-color: #d9d9d9;
	
	--link-color: #0086a5;
	--link-decoration-color: #0086a53f;
	--link-hover-color: #347EFF;
	--link-color-active: #063588;
	--link-transition-time: 0.20s;
	--link-transition-mode: cubic-bezier(0.36, 0.61, 0.18, 0.94);
}

@media (prefers-color-scheme: light) {}

@media (prefers-color-scheme: dark) {
	:root {
		--page-background: #1e1e1e;
		
		--text-color: #fafafa;
		--text-color-faded: #d0d0d0;
		--text-color-extra-faded: #a0a0a067;
		--text-shadow-color: #0000001a;
		
		--selection-background: rgba(255, 255, 100, 0.412); 
		
		--blockquote-background-color: rgba(50, 50, 50, 0.15);
		--blockquote-leading-color: var(--link-color);	
		
		--hr-border-color: #393939;
		
		--link-color: #4ea3d8;
		--link-decoration-color: #4ea3d83f;
		--link-hover-color: #66ccff;
		--link-color-active: #3399cc;
	}
}

@media screen and (max-width: 550px) {
	
	body {
		font-size: 1.1em !important;
	}
	
}

/* Page */

html {
	padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
	scroll-behavior: smooth;
}

body {
	padding: 0 1em;
	margin: auto;
	
	max-width: 30em;	
	
	background: var(--page-background);	
	color: var(--text-color);

	font-family: "gotham", serif;
	font-size: 1.2em;
	line-height: 1.6em;
	
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

/* Header and Footer are always centered */
header, footer {
	text-align: center;
}

main {
	flex: 1;
	display: flex;
	flex-direction: column;
	justify-content: center;
	padding: 1em 0;
	text-align: left;
	font-family: "gotham-narrow", sans-serif;
	font-weight: 400;
}

main a {
	color: var(--link-color);
	text-decoration: none;
	transition: color var(--link-transition-time) var(--link-transition-mode);
}

main a:hover {
	color: var(--link-hover-color);
}

/* Center main content only on homepage */
body.homepage main {
	text-align: center;
}

hr {
	display: block;
	height: 1px;
	border: 0;
	border-top: 1px solid var(--hr-border-color);
	margin: 1em 0;
	padding: 0;
}

/* Header */
header {
	padding: 2em 0 1em 0;
}

/* Header link styling */
header a {
	text-decoration: none;
	color: inherit;
	display: block;
	transition: opacity 0.2s ease;
}

header h1 {
	font-family: "gotham-xnarrow", sans-serif;
	font-size: 2.5em;
	font-weight: 400;
	margin: 0;
	letter-spacing: -0.02em;
}

header h2 {
	font-family: "gotham-narrow", sans-serif;
	font-size: 1.3em;
	font-weight: 400;
	color: var(--text-color-faded);
	letter-spacing: -0.02em;
}

/* App Icon Styling */
img[src="appicon.png"] {
	border-radius: 22.5%;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
	transition: transform 0.2s ease;
}

img[src="appicon.png"]:hover {
	transform: scale(1.02);
}

/* Footer */
footer {
	padding: 2em 0;
	border-top: 1px solid var(--hr-border-color);
	margin-top: auto;
}

footer nav {
	margin-bottom: 1em;
}

footer nav a {
	color: var(--link-color);
	text-decoration: none;
	margin: 0 0.5em;
	font-size: 0.9em;
	font-family: "gotham", sans-serif;
	font-weight: 400;
	transition: color var(--link-transition-time) var(--link-transition-mode);
}

footer nav a:hover {
	color: var(--link-hover-color);
}

footer p {
	margin: 0;
	font-size: 0.9em;
	font-family: "gotham", sans-serif;
	font-weight: 300;
	color: var(--text-color-faded);
}

.screenshot {
	width: 130px;
}

/* Typography Utility Classes */
.tk-benton-modern-text { 
	font-family: "benton-modern-text", serif; 
}

.tk-gotham { 
	font-family: "gotham", sans-serif; 
}

.tk-gotham-condensed { 
	font-family: "gotham-condensed", sans-serif; 
}

.tk-gotham-narrow { 
	font-family: "gotham-narrow", sans-serif; 
}

.tk-gotham-xnarrow { 
	font-family: "gotham-xnarrow", sans-serif; 
}

/* Additional font weight classes for Gotham */
.gotham-thin { font-weight: 100; }
.gotham-light { font-weight: 200; }
.gotham-book { font-weight: 300; }
.gotham-medium { font-weight: 500; }
.gotham-bold { font-weight: 700; }
.gotham-black { font-weight: 900; }