@font-face {
	font-family: "Wizzta";
	src: url("fonts/Wizzta-vaDA.ttf") format("truetype");
}

@font-face {
	font-family: "Mirza";
	src: url("fonts/Mirza-Regular.ttf") format("truetype");
}

/* css variables, mainly for dark/light mode toggle */
:root {
	--background-image-unloaded-color: black;
	--background-color: rgb(25, 25, 25);
	--text-color-background: white;
	--text-color: white;
	--link-color: rgb(230, 255, 255);
	--dark-link-color: rgb(230, 255, 255); /* color of links that are not in front of white backgrounds in light mode */
	--text-brightness-background: 1;
	--text-brightness: 1;
	
	--button-text-color: rgb(180, 180, 180);
	--button-text-highlight-color: rgb(220, 220, 220);
	--button-separator-color: rgb(128, 128, 128);
	
	--popup-button-text-color: rgb(220, 220, 220);
	--popup-button-text-highlight-color: white;
	--popup-button-separator-color: rgb(200, 200, 200);
	
	--sliceBox-brightness-opaque: .15;
	--sliceBorder-brightness-opaque: .5;
	--sliceBorder-brightness-faded: 0.2;
	
	--logo-shadow-color: #dddddd;
	--divider-brightness: 0.35;
	
	--overlay-brightness: 1;
	--overlay-opacity: .1;
	
	--bg-brightness: 0.4;
}

.lightMode {
	--background-image-unloaded-color: white;
	--background-color: white;
	--text-color-background: white;
	--text-color: rgb(50, 50, 50);
	--link-color: rgb(0, 100, 100);
	--dark-link-color: rgb(230, 255, 255);
	--text-brightness-background: 1;
	--text-brightness: .195;
	
	--button-text-color: rgb(75, 75, 75);
	--button-text-highlight-color: rgb(115, 115, 115);
	--button-separator-color: rgb(128, 128, 128);
	
	--popup-button-text-color: rgb(220, 220, 220);
	--popup-button-text-highlight-color: white;
	--popup-button-separator-color: rgb(200, 200, 200);
	
	--sliceBox-brightness-opaque: .85;
	--sliceBorder-brightness-opaque: .5;
	--sliceBorder-brightness-faded: 0.8;
	
	--logo-shadow-color: #921fff;
	--divider-brightness: 0.85;
	
	--overlay-brightness: 0;
	--overlay-opacity: .2;
	
	--bg-brightness: 0.8;
}

:root {
	font-size: max(min(2vw, 2em), 1em);
	font-family: "Wizzta";
}

html {
	height: 100%;
}

body {
	margin: 0;
	
	height: 100%;
	color: var(--text-color-background);
	display: flex;
	flex-direction: column;
	align-items: center;
	overflow: hidden;
	
	background-color: var(--background-image-unloaded-color);
}

#bgImage {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: center top no-repeat;
	background-size: cover;
	
	filter: brightness(var(--bg-brightness));
	z-index: -100;
}

#bottomLogo {
	position: fixed;
	right: max(1.25vw, 2.5vh);
	bottom: max(-0.4vw, -0.8vh);
	z-index: 101; /* 1 above the header */
	max-width: max(3vw, 6vh);
	opacity: var(--overlay-opacity);
	filter: brightness(var(--overlay-brightness));
}

/* mobile/desktop navigation */
@media (max-width: 680px) {
	:root {
		--header-height: 0;
	}
	
	header {
		display: none;
	}
	
	#navMenuButton, #mobileNavMenu {
		display: initial;
	}
}

@media (min-width: 679px) {
	:root {
		--header-height: 3em;
	}
	
	header {
		display: flex;
	}
	
	#navMenuButton, #mobileNavMenu {
		display: none;
	}
	
	#scrollArea {
		margin-top: var(--header-height);
	}
}

#navMenuButton {
	position: fixed;
	top: 0;
	left: 0;
	max-width: 7.5vw;
	margin: 2vw;
}

#navMenuButton:focus {
	outline: none;
}

#inputBlock {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 1000;
	
	background-color: transparent;
	transition: background-color .5s;
	
	pointer-events: none;
}

#mobileNavMenu {
	position: fixed;
	top: 0;
	left: -8em;
	width: 8em;
	height: 100%;
	z-index: 1001; /* 1 in front of the inputBlock*/
	
	transition: left .5s;
}

#mobileNavMenu button {
	border: none;
	font-size: 1.8em;
	font-family: "Wizzta";
	white-space: nowrap;
	width: calc(100% - 1em);
	margin-left: .5em;
	margin-right: .5em;
	padding-top: .2em;
	padding-bottom: .2em;
	background-color: transparent;
	
	color: var(--button-text-color);
}

#mobileNavMenu button:not(:last-of-type) {
	border-bottom: 2px var(--button-separator-color) solid;
}

.mobileMenuBtn:focus {
	outline: none;
}

header {
	height: 2em;
	
	border-bottom: 2px #ff27e8 solid;
	padding-top: .5em;
	padding-bottom: .5em;
	
	z-index: 1000;
	position: fixed;
}

a {
	color: var(--link-color);
}

.sliceBox a {
	color: var(--dark-link-color);
}

.panel {
	width: 100%;
	background-color: var(--background-color);
	color: var(--text-color);
}

#logo {
	height: 100%;
	background-repeat: no-repeat;
	background-size: contain;
	transition: filter .6s;
	margin-right: .5em;
}

#logo:focus {
	outline: none;
	
	filter: drop-shadow(0px 0px 5px var(--logo-shadow-color));
	transition: filter .2s;
}

#logo:hover {
	filter: drop-shadow(0px 0px 5px var(--logo-shadow-color));
	transition: filter .6s;
}

#navButtons {
	margin-left: .5em;
	margin-right: .5em;
}

.sliceBox, .sliceBoxOpaque, .sliceBoxFaded {
	position: relative;
	padding: 0.45em;
}

.sliceBox::before {
	position: absolute;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	content: "";
	
	border: 2px solid; /* fix for Chrome not showing border-images without border style */
	border-image-source: url("images/Circly.svg");
	border-image-slice: 49% fill;
	border-image-width: .75em;
	filter: opacity(50%) brightness(0);
	z-index: -10;
	
	pointer-events: none;
}

.sliceBox::after {
	position: absolute;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	content: "";
	
	border: 2px solid; /* fix for Chrome not showing border-images without border style */
	border-image-source: url("images/Circly_Stroke.svg");
	border-image-slice: 49%;
	border-image-width: .75em;
	filter: brightness(1);
	z-index: 10;
	
	pointer-events: none;
}

.sliceBoxOpaque::before {
	position: absolute;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	content: "";
	
	border: 2px solid; /* fix for Chrome not showing border-images without border style */
	border-image-source: url("images/Circly.svg");
	border-image-slice: 49% fill;
	border-image-width: .75em;
	filter: brightness(var(--sliceBox-brightness-opaque));
	z-index: -10;
	
	pointer-events: none;
}

.sliceBoxOpaque::after {
	position: absolute;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	content: "";
	
	border: 2px solid; /* fix for Chrome not showing border-images without border style */
	border-image-source: url("images/Circly_Stroke.svg");
	border-image-slice: 49%;
	border-image-width: .75em;
	filter: brightness(var(--sliceBorder-brightness-opaque));
	z-index: 10;
	
	pointer-events: none;
}

.sliceBoxFaded::after {
	position: absolute;
	width: 100%;
	height: 100%;
	top: 0;
	left: 0;
	content: "";
	
	border: 2px solid; /* fix for Chrome not showing border-images without border style */
	border-image-source: url("images/Circly_Stroke.svg");
	border-image-slice: 49%;
	border-image-width: .75em;
	filter: brightness(var(--sliceBorder-brightness-faded));
	z-index: 10;
	
	pointer-events: none;
}

/* buttons in sliceBoxes*/
.sliceBoxOpaque button, .popupButtons button {
	border: none;
	font-size: 1.8em;
	line-height: 0.6em;
	font-family: "Wizzta";
	white-space: nowrap;
	padding-left: 1em;
	padding-right: 1em;
	background-color: transparent;
	text-decoration: underline;
	min-height: 0.5em;
	max-height: 0.5em;
	overflow: visible;
	
	color: var(--button-text-color);
	-webkit-text-decoration-color: transparent; /* Safari compatibility */
	text-decoration-color: transparent;
	transition: color .4s;
	transition: -webkit-text-decoration-color .4s; /* Safari compatibility */
	transition: text-decoration-color .4s;
	
	cursor: pointer;
}

.sliceBoxOpaque button:hover, .popupButtons button:hover {
	color: var(--button-text-highlight-color);
	-webkit-text-decoration-color: var(--button-text-highlight-color); /* Safari compatibility */
	text-decoration-color: var(--button-text-highlight-color);
	transition: color .4s;
	transition: -webkit-text-decoration-color .4s; /* Safari compatibility */
	transition: text-decoration-color .4s;
}

.sliceBoxOpaque button:focus, .popupButtons button:focus {
	color: var(--button-text-highlight-color);
	outline: none;
}

.sliceBoxOpaque button:not(:last-of-type) {
	border-right: 2px var(--button-separator-color) solid;
}

/* Alterations to button styling for popup buttons */
.popupButtons button {
	color: var(--popup-button-text-color);
	
	padding-left: .5em;
	padding-right: .5em;
	cursor: auto;
}

.popupButtons button:hover {
	color: var(--popup-button-text-highlight-color);
	-webkit-text-decoration-color: var(--popup-button-text-highlight-color); /* Safari compatibility */
	text-decoration-color: var(--popup-button-text-highlight-color);
}

.popupButtons button:not(:last-of-type) {
	border-right: 2px var(--popup-button-separator-color) solid;
}

header .sliceBoxOpaque {
	display: flex;
	align-items: center;
}

#scrollArea {
	width: 100%;
	height: 100%;
	
	overflow-y: scroll;
}

/*Solid background part of a page below the image background.*/
.mainArea {
	flex-grow: 1;
}

.titleNote {
	margin-left: 15%;
	margin-right: 15%;
}

#homePg {
	display: flex;
}

.page:not(#homePg) {
	display: none;
}

.page {
	flex-direction: column;
	align-items: center;
	width: 100%;
	min-height: 100%;
	text-align: center;
}

.fancyDivider {
	width: 60%;
	height: 3px;
	background-image: url("images/Dashed_Divider.svg");
	background-size: 100% 100%;
	filter: brightness(var(--divider-brightness));
	
	margin: 1em auto;
}

#projectIFrame {
	width: 100%;
	height: 100%;
	
	flex-grow: 1;
}

.quoteAuthor {
	float: right;
	color: gray;
}

#wonglobuBox {
	margin: 10% 20%;
}

/* hiding scrollbars on different browsers */
.hideScroll::-webkit-scrollbar {
	display: none;
}

.hideScroll {
	-ms-overflow-style: none;
	scrollbar-width: none;
	
}

.popup {
	position: fixed;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	z-index: 1500; /* over everything else */
	
	font-size: 1.3em;
	
	max-height: 90vh;
}

.popupIcon {
	width: 1.6em;
	float: left;
	margin: .3em;
	margin-top: .4em;
}

.pixelart {
	image-rendering: crisp-edges;
	image-rendering: pixelated;
}

input[type="text"] {
	background-color: black;
	border: 2px solid white;
	color: inherit;
	font-family: inherit;
	font-size: .8em;
}

input[type="text"]:focus {
	outline: none;
}

/* Levitating man emoji cursor. Emoji is from Twitter's Twemoji. */
.levitate * {
	cursor: url("/styles/images/levitate.png") 16 16, auto;
}

/* dropdown menu arrows */
.arrow {
	width: .5em;
	height: .5em;
	margin-left: .2em;
	
	filter: brightness(var(--text-brightness-background));
	
	transform: rotate(-90deg);
	transition: transform .3s;
}

.panel .arrow {
	filter: brightness(var(--text-brightness));
}

details[open] > summary .arrow {
	transform: rotate(0deg);
	transition: transform .3s;
}

details details {
	margin-left: 1em;
}

details p, details ul {
	margin: 0 1em;
}

details p:first-of-type {
	margin-top: .2em;
}

details p:last-of-type {
	margin-bottom: .2em;
}

summary {
	list-style: none;
}

summary:focus {
	outline: none;
}

/* at the moment specifically for the formatting in the walkthrough */
.popup details p, .popup details ul {
	font-size: .75em;
}
.popup > div {
	max-height: 90vh;
	overflow-y: auto;
}

/* used mainly for text and icons */
.hoverGlow {
	transition: filter .6s;
}

.hoverGlow:focus {
	outline: none;
	
	filter: drop-shadow(0 0 5px white);
	transition: filter .2s;
}

.hoverGlow:hover {
	filter: drop-shadow(0 0 5px white);
	transition: filter .6s;
}

/* hides the blog and about us buttons for now. TODO: unhide it once their pages done */
#blogBtn, #blogBtnMobile, #aboutBtn, #aboutBtnMobile {
	display: none;
}