/*******************
* COPYRIGHT NOTICE *
********************

Web App Lib is free and open-source downloadable web site development software that provides a fast and simple front-end development framework.

https://webapplib.com

Web App Lib is developed by Mayanly. Enjoy the mayanliest adult goods, software & video game content!

https://mayanly.com

***************
* MIT LICENSE *
***************

Copyright 2025 Mayanly LLC
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

*************************
* MATERIAL DESIGN NOTES *
*************************

- Light & shadows - https://m2.material.io/design/environment/light-shadows.html

	~ Use both "key" and "ambient" shadows including on dark surfaces

	~ Shadows only on y-axis

	~ Shadows only 2px, 6px, 12px or 24px; see Elevation below

- Elevation - https://m2.material.io/design/environment/elevation.html

	~ Defaults @ https://m2.material.io/design/environment/elevation.html#default-elevations

	~ Successful elevation = edge contrast, surface overlap, and distance from other surfaces

	~ Surfaces at the same elevation cast different shadows depending on what is behind them (i.e., elevation stacks)

	~ Mobile resting elevations use more shadows for interactive components

	~ Desktop resting elevations are shallower since more cues (e.g., hover states) can be used

	~ Can secondarily use background colors and opacity to express elevation

- Dark theme - https://m2.material.io/design/color/dark-theme.html

	~ Higher elevation = lighter color per surface, and same shadows as light theme

	~ 

- Pixel density - https://m2.material.io/design/layout/pixel-density.html#pixel-density-on-the-web

	~ Replace dp (in MD specs) with px

**************
* MISC NOTES *
**************

@supports (-webkit-text-stroke: .5px #444444) {
  table.calc td {
  	color: white;
    -webkit-text-fill-color: white;
    -webkit-text-stroke: .5px #444444;
  }
}

********
* VARS *
********/

:root {

	/**********
	* Spacing * (First because some are used by other vars)
	**********/

	--borderRadius: 50vh;
	--heightLine: calc(16px * 1.75); /* 16px = 1rem per <html> declaration */
	--hSpaceMin: 1.25rem; /* Horizontal space from window edges (mobile-first) */
	--hSpace: calc(var(--hSpaceMin) * 2);	
	--spacing1: 2.5rem; /* Primary spacing (more) */
	--spacing1Half: calc(var(--spacing1) / 2); /* Slightly less than spacing2 */
	--spacing2: 1.5rem; /* Secondary spacing (less) */
	--spacing2Half: calc(var(--spacing2) / 2);
	--widthMax: 1400px; /* Everything except <header> */
	--widthMaxHalf: calc(var(--widthMax) / 2);
	--widthMaxQuarter: calc(var(--widthMax) / 4);
	--widthMin: 320px; /* The smallest viewport supported is 320x480 */
	--paddingBtn: .5em .75em; /* Padding shared by div.btn and elevated <h5> */
	--paddingBtnHalf: .25em .375em; /* <input> buttons and submits */

	/*********
	* Colors *
	*********/

	/* Official colors of the flag of the United States of America */
	--usaRed: rgb(179,25,66); /* #b31942, "Old Glory Red" */
	--usaWhite: rgb(255,255,255); /* #ffffff, "White" */
	--usaBlue: rgb(10,49,97); /* #0a3161, "Old Glory Blue" */
	/* References:
	1. https://eca.state.gov/files/BoxFiles/ECA/Design-Guide.pdf
	2. https://eca.state.gov/files/bureau/eca_design_guide.pdf */

	/* Other brand colors (updated 2026-03-08) */
	--amazonOrange: rgb(255,164,28); /* #ffa41c */
	--amazonOrangeHover: rgb(255,132,0); /* #ff8400 */
	--amazonYellow: #ffd814;
	--amazonYellowHover: #ffce12;
	--discordBlue: rgb(88,101,242); /* #5865f2 */
	--discordBlueHover: rgb(120, 129, 242); /* Custom:
		"Amazon orange" green diff (added to Discord red diff): 164-132=32
		"Amazon orange" blue diff (added to Discord green diff): 28-0=28
	*/

	--colBlue: var(--discordBlue);
	--colBlueHover: var(--discordBlueHover); /* #585bf0;   /* = rgb(88,91,240) to match orange diff */
	--colGreen: #0f0;
	--colOrange: var(--amazonOrangeHover);
	--colOrangeHover: var(--amazonOrange);
	--colRed: #880000;
	--colRedFade: #ffd8d8;
	--colRedFadeMore: #ffe0e0;
	--colRedLess: #440000;
	--colRedMore: #bb0000;
	--colRedMost: #ff0000;	

	--colBlue50: #E3F2FD;
	--colBlue100: #BBDEFB;
	--colBlue200: #90CAF9; /* Max saturation for dark themes */
	--colBlue300: #64B5F6;
	--colBlue400: #42A5F5;
	--colBlue500: #2196F3; /* Min saturation for light themes */
	--colBlue600: #1E88E5;
	--colBlue700: #1976D2;
	--colBlue800: #1565C0;
	--colBlue900: #0D47A1; /* Max saturation for light themes */
	--colBlueA100: #82B1FF;
	--colBlueA200: #448AFF;
	--colBlueA400: #2979FF;
	--colBlueA700: #2962FF;

	--colOrange50: #FFF3E0;
	--colOrange100: #FFE0B2;
	--colOrange200: #FFCC80; /* Max saturation for dark themes */
	--colOrange300: #FFB74D;
	--colOrange400: #FFA726;
	--colOrange500: #FF9800; /* Min saturation for light themes */
	--colOrange600: #FB8C00;
	--colOrange700: #F57C00;
	--colOrange800: #EF6C00;
	--colOrange900: #E65100; /* Max saturation for light themes */
	--colOrangeA100: #FFD180;
	--colOrangeA200: #FFAB40;
	--colOrangeA400: #FF9100;
	--colOrangeA700: #FF6D00;

	/*********************************
	* Colors for dark & light themes *
	*********************************/

	/* Dark theme (darkest first) */
	--colDark01: rgb(6 6 6);
	/* Increment each by 8 */
	--colDark02: rgb(14 14 14);
	--colDark03: rgb(22 22 22);
	--colDark04: rgb(30 30 30);
	--colDark05: rgb(38 38 38);
	--colDark06: rgb(46 46 46);
	--colDark07: rgb(54 54 54);
	--colDark08: rgb(62 62 62);
	--colDark09: rgb(70 70 70);
	--colDark10: rgb(78 78 78);

	/* Light theme (lightest first)*/
	--colLight10: rgb(249 249 249); /* 255 - 6 */
	/* Decrement each by 8 */
	--colLight09: rgb(241 241 241);
	--colLight08: rgb(233 233 233);
	--colLight07: rgb(225 225 225);
	--colLight06: rgb(217 217 217);
	--colLight05: rgb(209 209 209);
	--colLight045: rgb(205 205 205); /* 4.5 special use: Lighter light mode body bgcolor */
	--colLight04: rgb(201 201 201);
	--colLight03: rgb(193 193 193);
	--colLight02: rgb(185 185 185);
	--colLight01: rgb(177 177 177);

	/********************
	* Color assignments * (Allows easier overrides)
	********************/

	/* Dark theme (darkest first) */

	/* Background color - Body */
	--colBg: var(--colDark01);

	/* Background color - Section */
	--colBgSection: var(--colDark02);

	/* Border color - Section */
	--colBorderSection: var(--colDark05); /* Same as section header (so color is more visible than box-shadow) */

	/* Background color - Section highlight */
	--colBgSectionHighlight: var(--colDark04); /* Skip colDark03 for more contrast */	

	/* Background color - Section header */
	--colBgSectionHeader: var(--colDark05); 

	/* Background color - Body header */
	--colBgBodyHeader: var(--colDark05); /* Same as section header */

	/* Background color - Main menu */
	--colBgMainMenu: var(--colDark06);

	/* Background color - Home button, main menu button hover & popup menu */
	--colBgSiteTitle: var(--colDark07);
	--colBgSiteButton: var(--colDark07);

	/* Background color - Home button hover and popup menu hover */
	/* TO DO: SPLIT LIKE SITE TITLE AND SITE BUTTON? */
	--colBgSiteDropDownHover: var(--colDark08);

	/* Light theme (lightest first) */

	/* Background color - Home button hover and popup menu hover */
	/* TO DO: SPLIT LIKE SITE TITLE AND SITE BUTTON? */
	--colBgSiteDropDownHoverLight: var(--colLight10);

	/* Background color - Home button, main menu button hover & popup menu */
	--colBgSiteTitleLight: var(--colLight08); /* Skip colLight09 for more contrast when hovering */
	--colBgSiteButtonLight: var(--colLight08);

	/* Background color - Main menu */
	--colBgMainMenuLight: var(--colLight07); /* Ends up being darker than body, but it's okay on light mode, plus it's unique */

	/* Background color - Body header */
	--colBgBodyHeaderLight: var(--colLight10);

	/* Background color - Section header */
	--colBgSectionHeaderLight: var(--colLight10); /* Same as body header */

	/* Background color - Section highlight */
	--colBgSectionHighlightLight: var(--colLight10); /* Same as section header (shadows differentiate more on light mode vs. dark mode) */

	/* Border color - Section */
	--colBorderSectionLight: var(--colLight09); /* Same as section (hide border; using box-shadow instead) */

	/* Background color - Section */
	--colBgSectionLight: var(--colLight09);

	/* Background color - Body */
	--colBgLight: var(--colLight08); /* As light as possible */

	/* Other color assignments */

	/* Font color - Body */
	--colFont: #fff;
	--colFontLight: #000;

	/* Dark mode text opacities */
	/*--highEmphasis: rgba(255, 255, 255, 0.87);*/
	--highEmphasisNew: rgb(from var(--colFont) r g b / 87%);
	/*--mediumEmphasis: rgba(255, 255, 255, 0.60);*/
	--mediumEmphasisNew: rgb(from var(--colFont) r g b / 60%);
	/*--lowEmphasis: rgba(255, 255, 255, 0.38);*/
	--lowEmphasisNew: rgb(from var(--colFont) r g b / 38%);

	/* Light mode text opacities */
	--highEmphasisNewLight: rgb(from var(--colFontLight) r g b / 87%);
	--mediumEmphasisNewLight: rgb(from var(--colFontLight) r g b / 60%);
	--lowEmphasisNewLight: rgb(from var(--colFontLight) r g b / 38%);

	/* Font color - Home button */
	--colFontSiteTitle: #fff;
	--colFontSiteTitleLight: #000;

	/* <hr> color (and similar borders, e.g., <pre>) */
	--colHr: #4f4f4f;

	--colFontBtn: var(--lowEmphasisNewLight);

	--colBgBtn: rgb(233, 233, 237); /* Firefox on 2026-04-10 */
	--colOutlineBtn: rgb(38, 38, 38); /* Firefox on 2026-04-12 */
	--colBdrBtn: #000; /* Chrome on 2026-04-12 */
	
	/*********
	* Images *
	*********/

	/* Blog image width (mobile-first) */
	--blogImgWidth: calc(100vw - (var(--spacing1) * 2));
	--blogImgHeight: calc(var(--blogImgWidth) / 16 * 9); /* Maintain aspect ratio */

	/* Blog image width (expanded) */
	--blogImgWidth2: calc(100vw - (var(--spacing1) * 3));
	--blogImgHeight2: calc(var(--blogImgWidth2) / 16 * 9); /* Maintain aspect ratio */

	/* Blog image width (max) */
	--blogImgWidthMax: calc(var(--widthMaxHalf));
	--blogImgHeightMax: calc(var(--blogImgWidthMax) / 16 * 9); /* Maintain aspect ratio */

	/* No-padding blog image width (mobile-first) */	
	--blogImgWidthNoPadding: calc(100vw - (var(--spacing1)));
	--blogImgHeightNoPadding: calc(var(--blogImgWidthNoPadding) / 16 * 9); /* Maintain aspect ratio */

	/* No-padding blog image width (expanded) */
	--blogImgWidth2NoPadding: calc(100vw - (var(--spacing1) * 2));
	--blogImgHeight2NoPadding: calc(var(--blogImgWidth2NoPadding) / 16 * 9); /* Maintain aspect ratio */

	/**********
	* Shadows *
	**********/

	--shadowHeader:
		/* Key light: Offset, blur, spread, color */
		0 12px 24px rgba(0, 0, 0, 0.25), /* X-offset, Y-offset, blur, spread, color */
		/* Ambient light: Subtle blur, spread, lighter color */
		0 0 6px rgba(0, 0, 0, 0.125);

	--shadowPageTitle:
		/* Key light: Offset, blur, spread, color */
		0 6px 12px rgba(0, 0, 0, 0.25), /* X-offset, Y-offset, blur, spread, color */
		/* Ambient light: Subtle blur, spread, lighter color */
		0 0 2px rgba(0, 0, 0, 0.125);

	--shadowButton:
		/* Key light: Offset, blur, spread, color */
		0 2px 6px rgba(0, 0, 0, 0.25), /* X-offset, Y-offset, blur, spread, color */
		/* Ambient light: Subtle blur, spread, lighter color */
		0 0 2px rgba(0, 0, 0, 0.125);

	/*******
	* Text *
	*******/

	

	/**************
	* Transitions *
	**************/

	--trnHover: .5s;  /* Hover mode */
	--trnLight: .75s; /* Light mode */
	--trnMedia: .75s; /* Media queries */
	--trnModal: .75s; /* Modals */
}

/********************************************
* MULTI-AREA (HEADER/MAIN/FOOTER) SELECTORS *
********************************************/

* {	
	line-height: var(--heightLine);
	margin: 0;
	padding: 0;
}

html {
	font-size: 16px; /* 1rem; ≈12pt */
	height: 100%; /* Sticky footer */
	
}

body {
	background-color: var(--colBg);
	color: var(--highEmphasisNew);
	display: flex; /* Sticky footer */
	flex-direction: column; /* Sticky footer */
	font-family: var(--fontFamily); /* SET VAR IN <HEAD> */
	font-optical-sizing: auto; /* From instructions on Google Fonts */
	height: 100%; /* Sticky footer */
	transition:
		background-color var(--trnLight),
		color var(--trnLight);
	&.overflowHidden main { /* Modal */
		opacity: 0;
	}
	& > div:last-child:not(#modal):not(#pageDisable) { /* Make header not clip any <div> appended to end of <body> (e.g., reCAPTCHA) */
		z-index: 2147483645 !important; /* Always on top, except modals and #pageDisable */
	}
}

a {
	color: inherit;
	text-decoration: none;
}

div.blogImg,
:not(div.vAlignMid) > div.btn,
div.imgGroup,
div.table > div,
div.table.notResponsive,
footer > section > figure,
h3,
h4,
h5,
h6,
main hr,
iframe,
/*input[type=button],*/
li,
noscript,
p,
pre,
table { 
	margin-top: var(--spacing2);
}

h1,
h2,
h3,
h4 {
	font-weight: 400; /* "normal" */
}

h3 {
	&:has(div.btn) {
		align-items: center;
		display: flex;
		margin-left: auto;
		margin-right: auto;
		width: fit-content;
	}
	& > .btn {
		margin-left: var(--spacing2);
		margin-top: 0;
	}
}

hr {
	background-color: var(--colHr);
	border: none;
	height: 1px;
	margin-left: auto;
	margin-right: auto;
}

/* TO DO: MAKE SURE EVERYTHING BELOW IS MULTI-AREA */

iframe {
	/*border: 0;*/
	&[src*=youtube] {
		/*border: 1px solid var(--colBorderSection);*/
		border-radius: 1rem;
		/*box-shadow: var(--shadowPageTitle);*/
		display: block;
		margin: var(--spacing2) auto 0 auto;
		max-width: 100%;
		overflow: hidden;
		/* TO DO: CHANGE BORDER COLOR? CONTENTS OF IFRAME UNKNOWN... */
		/*transition:
			border-color var(--trnLight);*/
	}
}

/* TO DO: SOME OF THIS IS OVERRIDDEN LATER ON FOR BUTTONS AND SUBMITS */
input[type=button],
input[type=number],
input[type=password],
input[type=submit],
input[type=text],
select,
textarea {
	color: var(--colFont);
	font-family: var(--fontFamily); /* Textarea only? */
	font-size: 1rem;
	padding: 0 .25rem;
	background-color: var(--colBg);
	border: 2px solid var(--colBorderSection);
	border-radius: 1vh; /* Half of --borderRadius for fully rounded */
	transition:
		border-color var(--trnLight),
		color var(--trnLight);
}

/* Same as above, except no button or submit */
input[type=number],
input[type=password],
input[type=text],
select,
textarea {
	transition:
		background-color var(--trnLight),
		border-color var(--trnLight),
		color var(--trnLight);
}

/* Group with above */
select {
	padding: .25rem;
}



input[type=password],
input[type=text],
textarea {
	/* 100vw - (2x) horizontal space from window edges - (2x) input padding+border (6px each side) */
	width: calc(100vw - (var(--hSpaceMin) * 2) - 12px); /* Mobile-first */
}

/* Calc */
input[type=number] {
	width: 75px;
}

li {
	text-align: left;
	padding-left: calc(var(--spacing2) / 4);
}

noscript { /* Modal */
	display: block;
	color: var(--colRed);
}

ol,
ul {
	/* TO DO: USE A SPACING VAR? */
	max-width: calc(var(--widthMax) - 1rem); /* Mobile-first */
	padding-left: 1rem; /* Mobile-first */
	transition:
		max-width var(--trnMedia),
		padding-left var(--trnMedia);
}

/*
ol > ol,
ol > ul,
ul > ol,
ul > ul {
	margin-left: 1.25rem;
	max-width: calc(var(--widthMax) - 1.25rem);
}
*/

p {
	margin-left: auto;
	margin-right: auto;
	max-width: var(--widthMaxHalf);
}

td,
th {
	padding: 0.25rem;
}

/* Align <li> top spacing (e.g., in game server info) */
/*
td:has(ul) {
	padding-top: 0;
}
*/

tr:first-child td,
tr:first-child th {
	padding-top: 0;
}

tr:last-child td,
tr:last-child th {
	padding-bottom: 0;
}

/*****************************************
* SEMANTIC ELEMENTS (HEADER/MAIN/FOOTER) *
*****************************************/

header {
	background-color: var(--colBgMainMenu);
	box-shadow: var(--shadowHeader);
	min-width: var(--widthMin);
	position: fixed;
	width: 100%;
	z-index: 2147483644; /* Always on top, except modals, #pageDisable and reCAPTCHA */
	&, & section {
		height: var(--spacing1);
		transition:
			background-color var(--trnLight),
			height var(--trnMedia);
	}
	& section { 
		margin: 0 auto;
		max-width: var(--widthMax);
		position: relative;
		& figure {
			/*align-items: center;
			display: flex;*/
			height: 100%;

			/* Home button */
			&:first-child {
				box-shadow: var(--shadowButton);
				margin-left: var(--hSpaceMin); /* Mobile-first */
				float: left;
				transition:
					margin-left var(--trnMedia);
				& a {
					background-color: var(--colBgSiteTitle);
					color: var(--colFontSiteTitle);
					transition:
						background-color var(--trnHover),
						color var(--trnLight);
				}
				& h1 {	
					font-size: 1rem; /* Mobile-first */
					height: 100%;
					transition:
						font-size var(--trnMedia),
						line-height var(--trnMedia);
				}
			}
			&:nth-child(-n + 2) figcaption {
				transition:
					line-height var(--trnMedia);
			}

			/* Middle wrappers for all buttons except options */
			&:first-child figcaption,
			&:not(:nth-child(-n + 2)) figcaption {
				height: 100%;	
			}

			/* Inner wrappers for all buttons except options */
			&:first-child a,
			&:not(:nth-child(-n + 2)) a {
				align-items: center;
				display: flex;
				height: 100%;
				padding: 0 1rem;
			}

			/* All buttons except home */
			&:not(:first-child) {
				cursor: pointer;
				float: right;
				transition:
					background-color var(--trnHover),
					margin-right var(--trnMedia);
			}

			/* All buttons except home and options (i.e., buttons with images) */
			&:not(:nth-child(-n + 2)) a img {
				height: 1rem;
				width: 1rem;
				transition:
					height var(--trnMedia),
					width var(--trnMedia);
			}
		}
	}
	&:after {
		background-color: red;
		content: "Your screen width is very narrow.";
		color: white;
		visibility: hidden;
		left: 0;
		opacity: 0;
		padding: .25rem;
		position: absolute;
		right: 0;
		text-align: center;
		top: 41px;
		transition:
			top var(--trnMedia),
			opacity var(--trnMedia),
			visibility var(--trnMedia);
	}
}

main {
	flex: 1 0 auto; /* Sticky footer */
	margin-bottom: var(--spacing1);
	margin-left: auto;
	margin-right: auto;
	margin-top: var(--spacing1); /* Mobile-first */
	max-width: calc(var(--widthMax) - (var(--spacing1) * 2));
	padding: 0 var(--hSpaceMin); /* Mobile-first */
	text-align: center;
	transition:
		margin-top var(--trnMedia),
		opacity var(--trnModal),
		padding var(--trnMedia);
	/* The primary separators in <main> are <section>s.
	   Some <section>s are in <form>s.
	   Each <section> starts with an <h2>. */
	& > form > section, > section {
		margin-top: var(--spacing1);
		transition:
			background-color var(--trnLight),
			border-color var(--trnLight),
			padding var(--trnMedia);
			/* min-width var(--trnMedia); /* TO DO: THIS TRANSITION OCCURS FASTER THAN OTHERS (E.G., DISCORD), AND THE PADDING TRANSITION DOESN'T HELP. PROBABLY BEST TO LEAVE INACTIVE, BUT...? */
		&:not(.noExpand) { /* Auth Login */
			min-width: calc(100% - (var(--spacing2) * 2) + 6px); /* TO DO: WHY THIS EQUATION? IT WORKS BUT DOESN'T MAKE SENSE */
		}
		&.elevated {
			background-color: var(--colBgSection);
			border: 1px solid var(--colBorderSection);
			border-radius: 1rem;
			box-shadow: var(--shadowPageTitle);
			margin-left: auto;
			margin-right: auto;
			padding: var(--hSpaceMin);
			width: fit-content;
			& + section:not(.elevated) {
				border-top: none;
				padding-top: 0;
				& p:first-child {
					margin-top: 0;
				}
			}
			& h5.elevated {
				background-color: var(--colBgSectionHeader);
				border-radius: var(--borderRadius);
				box-shadow: var(--shadowPageTitle);
				margin-left: auto;
				margin-right: auto;
				padding: var(--paddingBtn);
				width: fit-content;
				transition:
					background-color var(--trnLight);
			}			
		}
		& span.elevated {
			white-space: nowrap;
		}
		&.halfMarginTop { /* Art (Focused) */
			margin-top: var(--spacing1Half);
		}
		/* Spacing and <hr>s between adjacent <section>s */
		&:not(:first-child):not(:is(.elevated, .noMarginTop)) {
			border-top: 1px solid var(--colHr);
			padding-top: var(--spacing1);
		}
		/* Align headers with narrow-body format of other elements */
		&:not(.wide) {
			& h2, h3, h4, h5, h6 {
				margin-left: auto;
				margin-right: auto;
				max-width: var(--widthMaxHalf);
			}
		}
		/* e.g., Crypto */
		& > table:first-child {
			margin-top: 0;
		}

		/* Buttons in dual rows (e.g., Legendary template) */
		& table.buttons {
			margin-left: auto;
			margin-right: auto;
			& div.btn {
				margin-top: initial;
			}
			/*& td {
				border: 1px solid #fff;
			}*/
			& td:first-child {
				padding-right: .5rem;
				text-align: right;
			}
			& td:last-child {
				padding-left: .5rem;
				text-align: left;
			}
			& td[colspan="2"] {
				text-align: center;
			}
		}

		/* Blog image & caption wrapper */
		& div.blogImg {
			border: 1px solid var(--colBorderSection);
			border-radius: 1em;
			box-shadow: var(--shadowPageTitle);
			display: inline-block;
			margin-left: auto;
			margin-right: auto;
			overflow: hidden; /* Enforce border-radius */
			transition:
				border-color var(--trnLight);
			/* Blog image wrapper (confines zoom) */
			& > a > div {
				overflow: hidden;
				/* Blog image (should be 1920x1080 or another 16:9 aspect ratio) */
				& > div {
					background-size: contain;
					background-position: center;
					background-repeat: no-repeat;
					height: var(--blogImgHeightNoPadding);
					width: var(--blogImgWidthNoPadding);
					transition:
						transform 0.5s ease-out;
				}
			}
			/* Blog caption wrapper */
			& > span {
				background-color: var(--colBgSection);
				display: inline-block;
				padding: calc(var(--spacing2) / 2);
				width: calc(var(--blogImgWidthNoPadding) - (var(--spacing2))); /* Same as img, but also subtract horizontal padding */
				transition:
					background-color var(--trnLight);
			}
		}
		& div.btn {
			border-radius: var(--borderRadius);
			box-shadow: var(--shadowButton);
			display: inline-block;
			font-size: 1.125rem; /* 1/8 larger than standard for emphasis & readability */
			overflow: hidden;
			text-shadow: .5px .5px var(--colDark01);
			font-weight: 500; /* slightly bold */
			&.blue {
				border: 1.5px solid var(--colBlueHover);
				background-color: var(--colBlue);
				color: #fff;
			}
			&.orange {
				border: 1.5px solid var(--colOrangeHover);
				background-color: var(--colOrange);
				color: #fff;
			}
			& a {
				display: flex;
				padding: var(--paddingBtn);
			}
			& + div.btn { /* Match "Premier" card's table */
				margin-left: 1rem;
			}
		}
		& h2 {
			background-color: var(--colBgBodyHeader);
			box-shadow: var(--shadowPageTitle);
			border-radius: var(--borderRadius);
			display: inline-block;
			font-size: 1.5rem; /* Mobile-first */
			/* line-height: 1.5rem; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
			padding: var(--spacing2); /* Horizontal and vertical size */
			transition:
				background-color var(--trnLight),
				border-color var(--trnLight),
				font-size var(--trnMedia),
				line-height var(--trnMedia);
			/* &:not(:first-child) {
				margin-top: var(--spacing1);
			} */
			/* Locked premier content */
			&.locked {
				background-color: var(--colRedFade);
				border: 2px solid var(--colRedMost);
				color: var(--colRedMost);
				/*-webkit-text-stroke-width: .25px;
  				-webkit-text-stroke-color: black;*/
  			}
			& + *:not(br) { /* <br> on Pay page, etc. */
				margin-top: var(--spacing1) !important;
			}
		}
		& h3, h4 {
			font-size: 1.5rem; /* Mobile-first */
			/* line-height: 1.5rem; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
		}
		& h5 {
			font-weight: 500; /* Slightly bold, to better match <h2> thickness */
		}
		& h5, h6 {
			font-size: 1rem;
			/* line-height: 1rem; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
		}
		& h4, h6 {
			text-align: left; /* TOS, RMR Calc */
		}
		& p.error { /* Download, Login, Pastebin, URL Encode, etc. */
			background-color: var(--colRedFade);
			border: 2px solid var(--colRedMost);
			border-radius: var(--borderRadius);
			color: #000;
			font-weight: 700; /* bold */
			padding: 1rem;
			width: fit-content;
		}
		& pre { /* Pastebin */
			border: 1px solid var(--colHr);
			border-radius: 2em;
			display: inline-block;
			padding: 1em;
		}
		& + div.imgGroup { /* Art */
			margin-top: var(--spacing1);
			
		}
	}
}

footer {
	/* flex-shrink: 0; */ /* Sticky footer */
	margin-left: var(--hSpaceMin); /* Mobile-first */
	margin-right: var(--hSpaceMin); /* Mobile-first */
	padding-bottom: var(--spacing1);
	text-align: center;
	transition:
		margin-left var(--trnMedia),
		margin-right var(--trnMedia);
	& > section {
		& > hr {
			max-width: calc(var(--widthMax) - (var(--spacing1) * 2)); /* Max page width minus page padding */
		}
		/*
		& > nav,
		> figure { /* Match line height with <main> on target children */
			/* line-height: var(--heightLine); */
		/*}*/
		& > nav { /* Outer wrapper for legal links in footer */
			margin-top: var(--spacing1);
			& > div { /* Inner wrapper for legal links in footer */
				display: inline-block;
				margin: 0 .5rem;
			}
		}
	}
}

/********************
* HEADER POPUP MENU *
********************/

/* Popup menu open & close buttons */
#navPopupToggle {
	margin-right: var(--hSpaceMin); /* Mobile-first */
}

/* Popup menu open & close buttons */
#navPopupToggle figcaption {
	height: 100%;
}

/* Popup menu open & close buttons */
#navPopupToggle figcaption > div {
	align-items: center;
	display: flex;
	height: 100%;
	padding: 0 1rem;
	position: relative;
	transition:
		font-size var(--trnMedia),
		line-height var(--trnMedia);
}

/* Popup menu close button */
#navPopupToggle figcaption div div:last-child {
	align-items: center;
	display: none; /* If removed, the button's "X" starts in the top-left corner instead of centered. Not worth fixing. */
	/*height: 100%;*/
	justify-content: center;
	left: 0;
	position: absolute;
	top: 0;
	/*right: 0;*/
	bottom: 0;
	width: 100%;
}

/* Popup menu */
#navPopup {
	background-color: var(--colBgSiteButton);
	box-shadow: var(--shadowHeader);
	cursor: pointer;
	display: none;
	position: absolute;
	top: var(--spacing1);
	right: var(--hSpaceMin); /* Mobile-first */
	z-index: 2147483644; /* Always on top, except modals, #pageDisable and reCAPTCHA */
	transition:
		background-color var(--trnLight), /* Otherwise anything aside from "Dark Mode" transitions weird */
		color var(--trnLight),
		font-size var(--trnMedia),
		line-height var(--trnMedia),
		right var(--trnMedia),
		top var(--trnMedia);
}

/* Popup menu rows */
#navPopup > div {
	padding: .75em; /* em is smoother than rem for the "Large" media query transition(?) */
}

/*********
* MODALS *
*********/

#pageDisable {
	background-color: #000;
	bottom: 0;
	left: 0;
	opacity: 0.75;
	position: fixed;
	right: 0;
	top: 0;
	z-index: 2147483646; /* Always on top, except modals */
}

#modal {
	display: table;
	height: 100%;
	position: absolute;
	width: 100%;
	z-index: 2147483647; /* Always on top */
	& input[type="button"] {
		margin-top: var(--spacing1Half);
		& + input[type="button"] {
			margin-left: var(--spacing2Half);
		}
	}
}

#modal > div {
	display: table-cell;
	height: 100%;
	vertical-align: middle;
}

#modal > div > div {
	border-width: 0;
	height: 100%; /* calc(100% - (var(--hSpaceMin) * 2)); */
	margin-left: auto;
	margin-right: auto;
	padding: 0 var(--hSpaceMin) var(--hSpaceMin) var(--hSpaceMin);
}

#modalScroll {
	height: 12.5rem;
	margin-top: 1rem;
	overflow-y: scroll;
	padding: 1rem;
	scroll-behavior: smooth;
}

/* Variation of div.btn for actual <input>s */
/* TO DO: Applies to more than just modals */
input:is([type="button"], [type="submit"]), /* Contact, Modal */
div.btns input { /* Login, Register */
	background-color: var(--colBgBtn);
	border-color: var(--colBorderSectionLight);
	border-radius: var(--borderRadius);
	border-width: 1px;
	box-shadow: var(--shadowButton);
	color: var(--colFontBtn);
	font-size: 1.125rem; /* 1/8 larger than standard for emphasis & readability */
	font-weight: 400;
	margin-top: 1em;
	padding: var(--paddingBtnHalf);
	text-shadow: .5px .5px var(--colDark01);
	&[disabled] {
		/* background-color: rgba(233, 233, 237, 0.5); /* From FF on 2026-04-10 */
		opacity: .5;
	}
	&:not([disabled]) { /* Modal */
		cursor: pointer;
		border: 1px solid #000;
	}
}

/* Group action buttons and keep vertical spacing when rows wrap */
/* TO DO: Applies to more than just modals */
div.btns { /* Used aside from just on modals, but started there */
	column-gap: 1rem;
	display: inline-flex;
	flex-wrap: wrap;
	row-gap: 1.5rem;
}

/* Not the cleanest, but make modal buttons pop more (assuming they continue popping more with browser defaults */
#modal input {
	border-color: var(--colBdrBtn);
}

/*********
* TABLES * (Contact, Download, Login, Modal, Pastebin)
*********/

:not(h2) + div.table { /* On Contact, there is a <p> above table */
	margin-top: var(--spacing2);
}

/* Row */
div.table > div:first-child { /* Mobile-first; on Log In, there is no <p> etc. above table */
	margin-top: 0;
	& div:first-child {
		margin-top: 0;
	}
}

/* Cell */
div.table > div > div {
	margin-top: calc(var(--spacing2) / 2); /* Mobile-first */
}

/* Left-aligned headers (1st column) on forms (Contact, Download, Login, Pastebin) */
div.table.form > div > div:first-child {
	text-align: left;
	&.required::after {
		content: '*';
		color: red;
		margin-left: .25rem;
	}
}

/* If the table has form fields, left pad <td> cells after column 1 */
div.table.form > div > div:not(:first-child) {
	& > p + div.btns,
	& > div.btns + p {
		margin-top: var(--spacing2); /* Log In */
		
	}
}

/* Move inputs down if their labels wrap onto multiple lines (Contact) */
div.table.form > div > div {
	vertical-align: middle;
}

/* Same as "Cell" above, to add consistent space after text directly above input (Contact) */
div.table.form > div > div span + input {
	display: block;
	margin-top: calc(var(--spacing2) / 2) 
}

/* Modal RTA */
/* div.table.notResponsive {} */

/* Modal RTA */
div.table.notResponsive > div {
	display: table-row;
}

/* Modal RTA */
div.table.notResponsive > div > div {
	display: table-cell;
}

/* Modal RTA */
div.table > div.vAlignMid > div {
	vertical-align: middle;
}

/********
* CALCS *
********/

table.calc {
	background-color: #333;
	border: .25rem solid #222;
	border-radius: 1rem;
	color: var(--highEmphasisNew);
	display: inline-block;
	padding-bottom: var(--spacing2);
	& .infoButton {
		cursor: pointer;
		display: inline-block;
		background-color: blue;
		border-color: var(--highEmphasisNew);
		border-radius: .75rem;
		border-style: solid;
		border-width: 2px;
		font-weight: 700; /* bold */
		padding: .025rem 0;
		text-align: center;
		width: 1.25rem;
	}
	/* Calc screen */
	& tr:first-child td {
		text-align: center;
		font-size: 1.5rem;
		& div {
			display: inline-block;
			padding: .25rem;
		}
		& > div {
			background-color: #282828;
			& div {
				background-color: #000;
				border: .25rem solid #222;
				color: var(--lowEmphasisNew);
				transition: color .25s;
				&:not(:first-child) {
					border-left-width: 0;
				}
			}
		}
	}
	/* Calc form */
	& tr:not(:first-child) {
		& td {
			vertical-align: top;
			width: 1%;
			white-space: nowrap;
			&:first-child {
				font-weight: 700; /* bold */
				padding-left: 1rem;
				text-align: right;
			}
			&:not(:first-child) {
				text-align:left;
			}
			& > label,
			> span {
				/* Align calc labels to be vertically centered with number inputs,
	   			   and keep that spacing consistent for elements under number inputs (in spans) */
				display: inline-block;
				padding-top: .4rem;
			}
			& select {
				margin-left: .5rem;
				margin-right: 1rem;
			}
			&.info {
				vertical-align: middle;
				width: 98%;
				& > div {
					margin-left: .5rem;
					margin-top: .6rem;
				}
			}
		}		
	}
}

/* Labels for radio buttons */
table.calc input[type="radio"]+label {
	padding-left: .2rem;
	padding-right: 1rem;
}

/* Labels for checkboxes */
table.calc span+label {
	padding-left: .5rem;
}

/*********
* IMAGES *
**********/

div.imgGroup { /* AI, Art, Proto */
	--imgCardWidth: calc((var(--widthMax) - (var(--spacing1) * 2) - (var(--spacing2) * 2)) / 3);
	display: flex;
	flex-wrap: wrap;
	gap: calc(var(--spacing2));
	justify-content: center;
	margin-left: auto;
	margin-right: auto;
	max-width: calc((var(--imgCardWidth) * 3) + (var(--spacing2) * 2)); /* Up to 3 images per row */
	& > div.imgWrapper {
		flex: 0 0 auto;
		margin-left: 0;
		margin-right: 0;
		width: fit-content;
	}
}

div.imgWrapper { /* Home, AI, Art */
	border-radius: 1rem; /* Prevent mouse in corner of a.img below from zooming */
	line-height: normal; /* Remove undesired bottom spacing */
	margin-left: auto;
	margin-right: auto;
	position: relative; /* For nested 'position: absolute' elements */
	width: fit-content;
	& a.img {
		display: inline-flex; /* Turn on bg col above to see effect of removal) */
	}
	& div.imgBtns {
		color: var(--highEmphasisNew);
		position: absolute;
		right: var(--spacing2Half);
		top: var(--spacing2Half);
		& > div {
			background-color: #000;
			border: 1px solid var(--highEmphasisNew);
			border-radius: 1rem;
			cursor: pointer;
			opacity: 0.75;
			padding: 0 .5rem;
			& + div {
				margin-top: var(--spacing2Half);
			}
		}
	}
}

a.img:not(.noWrapper) { /* Home, AI, Art */
	border: 1px solid var(--colBorderSection);
	border-radius: 1rem;
	box-shadow: var(--shadowPageTitle);
	overflow: hidden;
	transition:
		border-color var(--trnLight);
}

div.blogImg a.img {
	border: none;
}

a.img section { /* Home, AI */
	aspect-ratio: 1 / 1; /* Ensure height matches width */
	background-color: var(--colBgSection);
	/*border: 1px solid #888888;*/
	/*border-radius: 1rem;*/
	/*box-shadow: 0px 0px 2px #ff0000;*/
	display: inline-block;
	/*overflow: hidden;*/
	position: relative;
	width: calc(100vw - (var(--hSpaceMin) * 2)); /* Mobile-first, substract page margins */
	max-width: calc(var(--widthMax) / 3);
	transition:
		background-color var(--trnLight);
}

/* Overwrite max-width above for multiple images on same line */
div.imgGroup a.img section { /* AI */
	max-width: var(--imgCardWidth);
	width: min(var(--imgCardWidth), calc(100vw - (var(--hSpaceMin) * 2)));
}

div.imgGroup a.img { /* AI */
	display: inline-flex;
	width: auto;
}

a.img figure { /* Home, AI */
	background-position: center;
	background-repeat: no-repeat;
	background-size: contain;
	height: 100%;
	/*width: 100%;*/
	transition:
		transform .5s ease-out;
}

a.img figcaption { /* AI, Art */
	background-color: #000;
	border: 1px solid var(--highEmphasisNew);
	border-radius: 1rem;
	bottom: var(--spacing2Half);
	color: var(--highEmphasisNew);
	/*display: inline-block;*/
	left: 50%;	
	opacity: .75;
	padding: 0 .5rem;
	position: absolute;
	transform: translateX(-50%);
	transition:
		opacity .5s ease-out;
}

div.imgGroup.opaqueText a.img figcaption { /* Art */
	opacity: .875;
}

/******************
* ELEMENT CLASSES *
******************/

/* Link pre-underlined */
a:not(.btn > a):not(.img):not(.neverLine):not(.noLine):not(.tag) {
	border-bottom-style: solid;
	border-bottom-width: 1px;
	padding-bottom: 2px;
}

/* Link underlined on hover */
a.noLine,
a.tag {
	padding-bottom: 2px;
}

/* Blog */
a.tag {
	color: #6666ff;
}

/* Theme */
div[class^="elevation-"],
div[class*=" elevation-"] {
    border-radius: 1em;
}

/* Theme */
div.article {
	display: inline-block;
	padding: var(--spacing1);
}

/* Theme */
div.articleMargin {
	margin: var(--spacing2);
}

div.txtLeft, /* Contact, Download, Login, Pastebin */
pre.txtLeft, /* Cron */ /* TO DO: Make Pastebin the same, and have both use a monospace font */
td.txtLeft, /* Blog menu, Discord menu, Session, Sobriety */
table.txtLeft :is(td, th) {
	text-align: left;
}

:not(div.table) > div.vAlignMid { /* Art Piece */
	align-items: center;
	display: flex;
	margin-top: var(--spacing2);
	justify-content: center;
}

/* Pay */
img.qr {
	aspect-ratio: 1 / 1; /* Ensure height matches width */
	margin-top: var(--spacing1);
	width: calc(100vw - (var(--hSpaceMin) * 2)); /* Mobile-first, substract page margins */
	max-width: calc(var(--widthMax) / 6);
}

input:focus,
textarea:focus,
select:focus {
	outline: 2px solid var(--colBorderSection);
	box-shadow: none;
}

/* GGG */
ol.liGray { 
	margin-left: 2rem;
	max-width: calc(var(--widthMaxHalf) - 2rem);
	& li {
		color: #888888;
		padding-left: calc(var(--spacing2) / 2);
		& span {
			color: var(--highEmphasisNew);
			transition: color var(--trnLight);
		}
	}
}

section.txtLeft > p:not(.txtCenter) {
	text-align: left;
}

section.wide p { /* Legal */
	max-width: revert;
}

section.wide li img,
section.wide p img { /* Legal */
	display: block;
}

section.wide li img[src*="1.png"],
section.wide p img[src*="1.png"] { /* Legal */
	padding-top: .5em;
}

section.wide li img[src*="2.png"],
section.wide p img[src*="2.png"] { /* Legal */
	padding-bottom: .5em;
}

table.center { /* Blog, Crypto, Disord, Farm Sim, Sobriety, Social, Session */
	margin-left: auto;
	margin-right: auto;
}

table.headerCol th { /* Crypto, Farm Sim, Social */
	text-align: right;
	vertical-align: top;
}

table.headerCol td { /* Crypto, Farm Sim, Social */
	padding-left: 1rem;
	text-align: left;
	vertical-align: top;
}

table.responsive { /* Log */
	overflow-wrap: break-word;
	table-layout: fixed;
	width: 100%;
}

table.stories span { /* Blog card */
	display: inline-block;
	font-style: italic;
	margin-top: 0.5em;
}

table.vAlignTop td { /* Blog card */
	vertical-align: top;
}

/******************
* GENERIC CLASSES *
******************/

.elevated {
	background-color: var(--colBgSectionHighlight);
	border: 1px solid var(--colBgSiteButton); /* Two shades lighter than bgcol */
	border-radius: var(--borderRadius);
	box-shadow: var(--shadowButton);
	padding: .25rem .375rem;
	transition:
		background-color var(--trnLight),
		border-color var(--trnLight);
}

/* TO DO: EVERYTHING BELOW SHOULD BE ALPHABETIZED */

.txtCenter { text-align: center; }

section.txtJustify p { text-align: justify; }
.txtRight { text-align: right !important; } /* Blog menu, Discord menu, Sobriety, Session, "important" for Proto page */
.vAlignMid { vertical-align: middle; } /* Modal RTA */




.animatedBlink { animation: blink 1s linear infinite; } /* Modal */

.flipH { /* GGG */
	display: inline-block;
	transform: scale(-1, 1);
	-moz-transform: scale(-1, 1);
	-webkit-transform: scale(-1, 1);
	-o-transform: scale(-1, 1);
	-ms-transform: scale(-1, 1);
}

.bdrRed { border: 1px solid var(--colRedMost) } /* Modal */
.bdrRedThick { border: 2px solid var(--colRedMost) } /* Modal */

.bgRedFade { background-color: var(--colRedFade); } /* Modal */
.bgRedFadeMore { background-color: var(--colRedFadeMore); } /* Modal */

.elevation-00 { border: 2px solid var(--colDark02); } /* Theme... */
.elevation-01 { background-color: var(--colDark02); }
.elevation-02 { background-color: var(--colDark03); }
.elevation-03 { background-color: var(--colDark04); }
.elevation-04 { background-color: var(--colDark05); }
.elevation-06 { background-color: var(--colDark06); }
.elevation-08 { background-color: var(--colDark07); }
.elevation-12 { background-color: var(--colDark08); }
.elevation-16 { background-color: var(--colDark09); }
.elevation-24 { background-color: var(--colDark10); }

.highEmphasis { color: var(--highEmphasisNew); } /* Theme... */
.mediumEmphasis { color: var(--mediumEmphasisNew); }
.lowEmphasis { color: var(--lowEmphasisNew); }
.highEmphasisNew { color: var(--highEmphasisNew); }
.mediumEmphasisNew { color: var(--mediumEmphasisNew); }
.lowEmphasisNew { color: var(--lowEmphasisNew); }

.cursorPointer { cursor: pointer; } /* Panel */

.extraMarginTop { margin-top: var(--spacing1) } /* Home, Pay */

.marginBottom { margin-bottom: var(--spacing2); } /* Art (specific piece) */
.marginLeft { margin-left: 1rem; } /* Farm Sim, Modal, Panel */

.marginTopHalf,
.marginTopHalf li { margin-top: calc(var(--spacing2) / 2); } /* Calc */ /* TO DO: Move to element classes */
.marginTop { margin-top: var(--spacing2); } /* Pervasive */
.marginTop td { padding-top: var(--spacing2); } /* Blog, Calc */ /* TO DO: Move to element classes */
.noMarginAuto { /* Modal */
	margin-left: revert;
	margin-right: revert;
}
.noMarginTop { margin-top: 0 !important; } /* Contact, Farm Sim, Modal (!important for Contact "Continue" button) */
.noMaxWidth { max-width: revert; } /* Modal */

.paddingRight { padding-right: 1rem; } /* Modal */

.txtBlack { color: #000; } /* Modal */
.txtGray,
.txtGrey { color: #888888; } /* GGG, Panel */
.txtGreen { color: var(--colGreen) } /* Mail, Panel */
.txtPink { color: #ffc0cb; } /* Panel */
.txtPurple { color: #a020f0; } /* Panel */
.txtRed { color: var(--colRed) } /* Contact, Mail, Panel */

.huge { /* Modal */
	font-size: 2em;
	line-height: 2em; /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
}

.hoverBtn {
	background-color: black;
	border: 1px solid #888888;
	border-radius: var(--borderRadius);
	bottom: 40px;
	color: white;
	cursor: pointer;
	font-weight: bold;
	padding: 20px;
	position: fixed;
	right: 40px;
	z-index: 2147483643; /* Always on top, except menu, modals, #pageDisable and reCAPTCHA */
}

:not(.imgWrapper).large { /* Modal */
	font-size: 1.5em;
	/* line-height: 1.5em; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
}
.tiny { /* Error */
	font-size: .5em;
	/* line-height: .5em; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
}

.bold { font-weight: 700; } /* Pervasive */
.italic { font-style: italic; } /* Pervasive */
.noWrap { white-space: nowrap; } /* Home, Kingtree, Legendary menu */
.underline { text-decoration: underline; } /* Pervasive */
.wrap { overflow-wrap: break-word; } /* Panel, URL Encode */

.displayNone { display: none; } /* Contact */
.overflowHidden { overflow: hidden; } /* Modal */

.superscript {
	font-size: 0.75em;
	line-height: 0;
	vertical-align: super;
}
h1 .superscript {
	position: relative;
	font-size: .75em;
	top: -.25em;
	left: .1em;
}

/*************
* HOVER MODE *
*************/

/* TO DO: COMBINE THIS BLOCK WITH THE NEXT? */
body.hover {
	header {
		& section { 
			& figure {
				&:first-child {
					&:hover a {
						background-color: var(--colBgSiteDropDownHover); /* Home button in header */
					}
				}
			}
		}
	}
}

body.hover {
	& header figure:not(:first-child):hover { /* Flat/no-background buttons in header (i.e., all except home button) */
		background-color: var(--colBgSiteButton);
	}
	& div.blogImg:hover > a > div > div {
		transform: scale(1.1);
	}
}

/* Popup menu */
body.hover #navPopup > div:hover {
	background-color: var(--colBgSiteDropDownHover);
}

/* Pre-underlined link */
body.hover a:not(.btn > a):not(.img):not(.neverLine):not(.noLine):not(.tag):hover {
	border-bottom-width: 2px;
}

/* Non-underlined link */
body.hover a.noLine:hover,
body.hover a.tag:hover { 
	border-bottom-style: solid;
	border-bottom-width: 1px;
}

/* Button */
body.hover div.btn {
	&.blue:hover {
		background-color: var(--colBlueHover);
	}
	&.orange:hover {
		background-color: var(--colOrangeHover);
	}
}

/* Input button/submit */
body.hover input:is([type="button"], [type="submit"]), /* Contact, Modal */
body.hover div.btns input { /* Login, Register */
	&:not([disabled]) { /* Modal */
		&:hover {
			background-color: rgb(208, 208, 215); /* From FF on 2026-04-10 */
		}
	}
}

/* Images (image) */
body.hover .imgWrapper:hover figure,
body.hover .imgWrapper:focus figure {
	transform: scale(1.1);
}

/* Images (text) */
body.hover .imgWrapper:hover figcaption,
body.hover .imgWrapper:focus figcaption {
	opacity: 0;
}

/* Inputs */
body.hover input:hover,
body.hover textarea:hover,
body.hover select:hover {
	outline: 2px solid var(--colBorderSection);
}

body.hover div.imgWrapper {
	& div.imgBtns {
		& > div:hover {
			opacity: 1;
		}
	}
}

/* Modal buttons */
body.hover div#modal input:not([disabled]):hover {
	background-color: var(--colBgBtn);
	outline: 2px solid var(--colOutlineBtn);
}

body.hover .hoverBtn:hover {
	outline: 1px solid #fff;
}

/*************
* LIGHT MODE *
*************/

body.light {
	background-color: var(--colBgLight);
	color: var(--colFontLight);
	& a.img {
		border-color: var(--colBorderSectionLight);
	}
	& h2 {
		background-color: var(--colBgBodyHeaderLight);
	}
	& header {
		background-color: var(--colBgMainMenuLight);
		& figure:first-child a {
			background-color: var(--colBgSiteTitleLight);
			color: var(--colFontSiteTitleLight);
		}
	}
	& main {
		& > form > section, > section {
			&.elevated {
				border-color: var(--colBorderSectionLight); /* Same as section background color */
			}
			& span.elevated {
					border-color: var(--colBorderSectionLight); /* Same as section background color */
				}
			& div.blogImg {
				border-color: var(--colBorderSectionLight); /* TO DO: ADDS BORDER BETWEEN IMAGE AND SHADOW, BUT REMOVING BORDER MOVES UNDERLYING PAGE ELEMENTS UP/DOWN A FEW PX ON DARK MODE TOGGLE. MIGHT BE SOL */
				& > span {
					background-color: var(--colBgSectionLight);
				}
			}
		}
	}
	input[type=password],
	input[type=text],
	select,
	textarea {
		color: var(--colFontLight);
		background-color: var(--colBgSectionHeaderLight); /* Same as h5.elevated etc. */
		border-color: var(--colLight01);
	}
}

/* Popup menu button */
/*body.light #navPopupToggle figcaption > div {
	color: var(--colFontLight);
}*/

/* Popup menu */
body.light #navPopup {
	background-color: var(--colBgSiteButtonLight);
	/*color: var(--colFontLight);*/
}

/* Elevated sections */
body.light section.elevated {
	background-color: var(--colBgSectionLight);
}

/* Elevated section headers */
body.light section.elevated h5.elevated {
	background-color: var(--colBgSectionHeaderLight);
}

/* Elevated section highlights */
body.light section span.elevated {
	background-color: var(--colBgSectionHighlightLight);
}

/* Image */
body.light a.img section {
	background-color: var(--colBgSectionLight);
}

/* Legal */
body.light section.wide li img[src*="white"],
body.light section.wide p img[src*="white"],
body:not(.light) section.wide li img[src*="black"],
body:not(.light) section.wide p img[src*="black"] {
	display: none;
}

/* GGG */
body.light ol.liGray {
	& li {
		& span {
			color: var(--colFontLight);
		}
	}
}

/*********************
* HOVER + LIGHT MODE *
*********************/

/* TO DO: COMBINE THIS BLOCK WITH THE NEXT? */
body.hover.light {
	header {
		& section { 
			& figure {
				&:first-child {
					&:hover a {
						background-color: var(--colBgSiteDropDownHoverLight); /* Home button in header */
					}
				}
			}
		}
	}
}

body.hover.light {
	& header figure:not(:first-child):hover { /* Flat/no-background buttons in header (i.e., all except home button) */
		background-color: var(--colBgSiteButtonLight);
	}
}

/* Popup menu */
body.hover.light #navPopup > div:hover {
	background-color: var(--colBgSiteDropDownHoverLight);
}

body.hover.light input:hover,
body.hover.light textarea:hover,
body.hover.light select:hover {
	outline-color: var(--colLight01);
}


/****************
* MEDIA QUERIES *
****************/

@media (max-width: 400px) { /* Screen width warning */
	header:after {
		visibility: initial;
		opacity: 1;
	}
}

/* Starting below, all same breakpoints as Bootstrap 5: https://getbootstrap.com/docs/5.0/layout/breakpoints */

/* X-Small: Width < 576px */
@media (max-width: 575px) {}

/* Small: Height >= 576px */
@media (min-height: 576px) {	

	/* Shorten modal and add top and bottom borders */
	#modal > div > div { 
		border-bottom-width: initial;
		border-top-width: initial;
		height: initial;
	}
}

/* Small: Width >= 576px */
@media (min-width: 576px) {

	/* Add margin-left to home button */
	header {
		& section {
			& figure {
				&:first-child {
					margin-left: var(--spacing1);
				}
			}
		}
	}

	/* Add margin-right to popup menu button */
	#navPopupToggle {
		margin-right: var(--spacing1);
	}

	/* Add margin-right to popup menu */
	#navPopup {
		right: var(--spacing1);
	}

	main {
		padding: 0 var(--spacing1);
		& > form > section, > section {
			&:not(.noExpand) {
				min-width: 0;
			}
			& div.blogImg { /* Set blog image size to match increased page margins */
				& > a > div {
					& > div {
						height: var(--blogImgHeight2NoPadding);
						max-height: var(--blogImgHeightMax);
						max-width: var(--blogImgWidthMax);
						width: var(--blogImgWidth2NoPadding);					
					}
				}
				& > span { /* Same as div minus horizontal padding */
					max-width: calc(var(--blogImgWidthMax) - (var(--spacing2)));
					width: calc(var(--blogImgWidth2NoPadding) - (var(--spacing2))); 
				}
			}
			&.elevated.paddingExtra { /* Add horizontal padding to extra-padded elevated sections (e.g., Discord) */
				padding-left: var(--spacing1);
				padding-right: var(--spacing1);
			}
		}
	}

	/* Add horizontal margin to footer */
	footer {
		margin-left: var(--spacing1);
		margin-right: var(--spacing1);
	}

	/* Set fixed width on user input elements */
	input[type=text],
	input[type=password],
	textarea {
		width: 20rem;
	}

	/* Double margin-left on bullets */
	ol,
	ul {
		padding-left: 2rem;
		max-width: calc(var(--widthMax) - 2rem);
	}

	/* TO DO: APPEARS LIKE NO MARGIN (BULLETS FLUSH WITH PARAGRAPHS) AT AROUND 820 PX WINDOW SIZE */
	section:not(.wide) ol,
	section:not(.wide) ul {		
		max-width: calc(var(--widthMaxHalf) - 2rem); /* calc(var(--widthMaxHalf) - 4rem) TO DO: Why minus 4rem? */
	}

	/* Set margin-top to balance other changes */
	div.table {
		margin-top: var(--spacing2);
	}
	
	/* Allow table rows to have multiple table cells */
	div.table > div {
		display: table-row;
	}

	/* Allow table rows to have multiple table cells (continued) */
	div.table > div > div {
		display: table-cell;
	}

	/* If the table has form fields, add vertical space to cells after row 1 */
	div.table.form > div:not(:first-child) > div {
		padding-top: var(--spacing2);
	}

	/* If the table has form fields, right-align and top-align <th> cells in column 1 */
	div.table.form > div > div:first-child {
		text-align: right;
		vertical-align: top;
	}

	/* If the table has form fields, left pad <td> cells after column 1 */
	div.table.form > div > div:not(:first-child) {
		padding-left: var(--spacing2);
		& > p {
			margin-top: 0; /* Log In */
		}
	}

	div.table.form > div:nth-child(2) > div {
		padding-top: 0; /* Log In */
	}

	div.imgWrapper { /* Home, AI, Art */
		& a.img section {
			/* Match the wider page gutters used at this breakpoint */
			width: calc(100vw - (var(--spacing1) * 2));
		}
		&.large a.img section {
			max-width: min(800px, calc(100vw - (var(--spacing1) * 2)));
			
		}
	}

	/* Keep gallery rows at card widths (do not stretch to page width) */
	div.imgGroup a.img section {
		width: min(var(--imgCardWidth), calc(100vw - (var(--spacing1) * 2)));
	}
}

/* Small: Height & width >= 576px */
@media (min-height: 576px) and (min-width: 576px) {

	/* Narrow modal and add left and right borders */
	#modal > div > div {
		border-left-width: initial;
		border-radius: 1rem;
		border-right-width: initial;
		/* Match smallest page padding: Media width - 2x modal padding - 2x modal border - 2x page padding */
		width: calc(100vw - (var(--hSpaceMin) * 2) - 4px - (var(--hSpaceMin) * 2));
	}
}

/* Medium: Width >= 768px */
@media (min-width: 768px) {

	/* More horizontal space for modal */
	#modal > div > div {
		/* Stop widening: Media min-width - 2x modal padding - 2x modal border - 2x page padding */
		width: calc(768px - (var(--hSpaceMin) * 2) - 4px - (var(--hSpaceMin) * 2));
	}

	/* TO DO: APPEARS LIKE NO MARGIN (BULLETS FLUSH WITH PARAGRAPHS) STARTING AROUND THIS WINDOW SIZE */
	/*
	ol,
	ul {
		/* color: #ff0000; */
	/*}*/
}

/* Large: Height >= 992px */
@media (min-height: 992px) {

	/* Double vertical size of header */
	header,
	header section {
		height: calc(var(--spacing1) * 2);
	}

	/* Adjust popup menu for double vertical size of header */
	#navPopup {
		top: calc(var(--spacing1) * 2);
	}

	header:after { /* Screen width warning */
		top: 81px;
	}

	/* Adjust page content for double vertical size of header */
	main {
		margin-top: calc(var(--spacing1) * 2);
	}
}

/* Large: Width >= 992px */
@media (min-width: 992px) {}

/* Large: Height & width >= 992px */
@media (min-height: 992px) and (min-width: 992px) {

	/* Larger size and more space for all buttons in header */
	header {
		& section {
			& figure {
				&:first-child h1,
				&:nth-child(-n + 2) figcaption {
					font-size: 2rem; /* from 1rem */
					line-height: 2rem; /* Match font-size */
				}
				&:not(:nth-child(-n + 2)) {
					& a img {
						height: 1.5rem;
						width: 1.5rem;
					}
					& figcaption {
						font-size: 1.5rem;
						/* line-height: 1.5rem; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
					}
				}
			}
		}
	}

	/* Larger font for popup menu */
	#navPopup {
		font-size: 1.5rem;
		/* line-height: 1.5rem; */ /* Match font-size */ /* Removed because weird that it's less than mobile-first LH */
	}

	/* Larger font for <h2>s */
	main {
		& > form > section, > section {
			& h2 {
				font-size: 2rem; /* From 1.5rem */
				line-height: 2rem; /* Match font-size */
			}
		}
	}
}

/* Extra large: Width >= 1200px */
@media (min-width: 1200px) {}

/* Extra extra large: Width >= 1400px */
@media (min-width: 1400px) {
	div.imgGroup {
		margin-left: calc(var(--spacing1) * -1); /* Inverse of spacing between [between what?] */
		width: 100vw;
		max-width: 1402px; /* When at 1400px, third row of images does not appear */
	}
}

/*************
* ANIMATIONS *
*************/

/* Modal */
@keyframes blink {
	50% {
		opacity: 0;
	}
}

/*
@keyframes shake-site-title {
	0% { transform: translateX(0) }
	25% { transform: translateX(calc((var(--spacing1) / 8))) }
	50% { transform: translateX(calc(var(--spacing1) / 12) * -1) }
	75% { transform: translateX(calc((var(--spacing1) / 16))) }
	100% { transform: translateX(0) }
}
*/

/*
@keyframes shake-xy {
	0% { transform: rotate(0deg); }
	25% { transform: rotate(5deg); }
	50% { transform: rotate(0eg); }
	75% { transform: rotate(-5deg); }
	100% { transform: rotate(0deg); }
}
*/