* { /* there seems to be some default nonzero margins */
	margin: 0;
}

body {
	--entireContent-width: 80%;
	--topbar-extraHeight: 0em;
	
	--content-background: azure;
	--secondary-content-background: pink;
	--font-color: black;
	--a-link-color: blue;
	--a-visited-color: purple;
	
	--themeSwitch-justify-content: flex-end;
	--themeSwitch-background-color: darkviolet;
	
	--gallery-tr-display: block;
	--gallery-td-display: table-cell;
	--gallery-td-width: 33.33%;
}
.dark {
	--content-background: black;
	--secondary-content-background: darkslategray;
	--font-color: white;
	--a-link-color: red;
	--a-visited-color: orange;
	
	--themeSwitch-justify-content: flex-start;
	--themeSwitch-background-color: lightgrey;
}
/*for thin screens, remove background and increase button size*/
@media screen and (orientation: portrait) {
  body {
    --entireContent-width: 100%;
	--topbar-extraHeight: 4em;
	
	--gallery-tr-display: block;
	--gallery-td-display: block;
	--gallery-td-width: 100%;
  }
}

/* navigation bar. left edge of first button aligned to left edge of main content, all buttons equal size*/
.topbar {
	width: 100%;
	padding-left: calc((100% - var(--entireContent-width))/2);
	box-sizing: border-box; /*prevent padding from changing the width*/
	
	background-color: indigo;
}
.topbar div {
	display: inline-grid;
	grid-auto-columns: 1fr;
}
.topbar div a {
	grid-row: 1;
	font-size: 1em;
	padding: 0.5em;
	line-height: calc(1em + var(--topbar-extraHeight));
	text-align: center;
	
	color: ivory;
	text-decoration: none;
	font-family: "Lucidia Console", Consolas, Monospace;
}
.topbar div a:hover {
  background-color: DarkSlateBlue;
}
.topbar div a.selected {
  background-color: MediumPurple;
}

/* switch for changing some colors */
.themeImage {
	float: right;
	display: flex;
	margin-top: calc(0.2em + var(--topbar-extraHeight)/2);
	margin-bottom: calc(0.2em + var(--topbar-extraHeight)/2);
	margin-left: (0.2em);
	margin-right: (0.2em);
	height: 1.6em;
	width: 1.6em;
}
.themeSwitch {
	float: right;
	display: flex;
	margin-top: calc(0.2em + var(--topbar-extraHeight)/2);
	margin-bottom: calc(0.2em + var(--topbar-extraHeight)/2);
	margin-left: (0.2em);
	margin-right: (0.2em);
	height: 1.6em;
	width: 3.2em;
	justify-content: var(--themeSwitch-justify-content);
	
	border-radius: 1000px;
	background-color: var(--themeSwitch-background-color);
}
.themeSwitch input {
	display: none;
}
.themeSwitch div {
	border-radius: 1000px;
	width: 1.6em;

	background-color: azure;
}

/* put the main content in the center, with some background on the left and right */
.entire {
	align-items: top;
	justify-content: center;
	min-height: 100vh/*calc(100vh - 2em)*/;
	
	overflow: hidden;
	
	/*background-image: url("images/gauss.jpg");
	background-size: 2%;*/
	background-color: purple;
}
.entireContent {
	min-height: 100vh;
	width: var(--entireContent-width);
	margin: 0 auto;
	
	padding: 20px 20px 20px 20px;
	box-sizing: border-box; /*prevent padding from changing the width*/
	
	font-size: 16px;
	
	background-color: var(--content-background);
}
.backgroundTile {
	width: 20%;
	height: 0;
	padding-bottom: 20%;
	float: left;
}
.backgroundContainerLeft {
	width: calc((100% - var(--entireContent-width))/2);
	height: 42px;/*height does not matter since content will overflow as desired*/
	float: left;
}
.backgroundContainerRight {
	width: calc((100% - var(--entireContent-width))/2);
	height: 42px;
	float: right;
}

p, td {
	font-family: 'Verdana', sans-serif;
	font-size: 1.2em;
	color: var(--font-color);
}
a:link {
	color: var(--a-link-color);
}
a:visited {
	color: var(--a-visited-color);
}
h1 {
	font-family: "Lucidia Console", Consolas, Monospace;
	font-size: 1.2em;
	font-weight: normal;
	color: var(--font-color);
	
	background-color: var(--secondary-content-background);
	padding-left: 0.5em;
}
.h1below {
	padding-left: 2em;
	padding-right: 2em;
	padding-bottom: 1em;
	padding-top: 0.2em;
}

/* https://www.w3.org/Style/Examples/007/color-bullets.en.html */
ul {
	list-style: none;
}
ul li::before {
	content: "\2022";
	color: var(--font-color);
	font-weight: bold;
	display: inline-block; 
	width: 1em;
	margin-left: -1em;
}
li {
	font-family: 'Verdana', sans-serif;
	font-size: 1.2em;
	color: var(--font-color);
}
li li {
	font-size: 1em;
}

table.gallery {
	width: 95%;
	display: block;
	margin: auto;
	table-layout: fixed;
}
table.gallery tr {
	display: var(--gallery-tr-display);
}
table.gallery td {
	display: var(--gallery-td-display);
	padding: 5px;
	vertical-align: top;
	width: var(--gallery-td-width);
}
table.gallery td img {
	width: 100%;
}
table.gallery td p {
	font-size: 0.8em;
	margin-bottom: var(--gallery-p-margin);
}

table.emoji {
	padding-left: 0.5em;
}
table.emoji td {
	vertical-align: top;
}
table.emoji td:first-child {
	text-align: right;
	width: 5em;
}