body {
margin:0;
background:url() #000;
}

#sidebar {
position: fixed;
left: 0px;
height: 100%;
width: 150px;
z-index:1;
background: no-repeat bottom url(sidebar-bg.png) #fff;
border-right: #ccc solid 1px;
}

.sidebar-links {
font-size:20pt;
padding: 20px 0px 0px 0px;
font-family: courier;
color: #000;
z-index:2;
text-shadow: 1px 1px 2px #777;
writing-mode: vertical-rl;
}

#container {
z-index:0;
margin: 0px 0px 0px 150px;
position: absolute;
width: 50%;
height: auto;
}

@media (max-width: 600px) {
#container {
z-index:0;
margin: 100px 0px 0px 0px;
position: absolute;
width: auto;
height: auto;
}

#sidebar {
position: absolute;
height: 100px;
width: 100%;
z-index:1;
background: no-repeat right url(sidebar-bg-h.png) #fff;
border-right: #ccc solid 1px;
}

.sidebar-links {
font-size:15pt;
text-align: center;
padding: 20px 0px 0px 0px;
font-family: courier;
color: #000;
z-index:2;
text-shadow: 1px 1px 2px #777;
writing-mode: horizontal-tb;
}

#title
{
left: 0px;
text-align: right;
font-size:15pt;
padding: 0px 0px 0px 0px;
font-family: impact;
background-color: #ddd;
color: #000;
z-index:2;
text-shadow: 1px 1px 2px #777;
}
}

#content {
z-index:0;
font-size:12pt;
color: #777;
background-color: #eee;
}

#title
{
left: 0px;
text-align: right;
font-size:30pt;
padding: 0px 50px 0px 0px;
font-family: impact;
background-color: #ddd;
color: #000;
z-index:2;
text-shadow: 1px 1px 2px #777;
}

em {
font-size:14pt;
font-family: Georgia, Arial, serif;
margin-bottom:-5px;
text-align: left;
color: #777;
z-index:1;
position: relative;
}

H1 {
font-size:15pt;
position: relative;
text-align: right;
margin: 0px 0px 0px 0px;
font-family: courier;
line-height: 10px;
color: #777;
background-color: #ccc;
padding: 10px;
z-index:1;
text-shadow: 1px 1px 2px #777;
}

H2 {
font-size:14pt;
font-family: courier;
margin:0px 0px 0px 0px;
line-height: 20px;
color: #777;
padding: 5px 0px 0px 10px;
z-index:2;
position: relative;
background:url("/cam-domino-quote.png") no-repeat left bottom #fff;
text-shadow: 1px 1px 2px #ccc;
}

td,th {
color: #777;
vertical-align:top;
border: 5px solid #eee;
padding: 10px;
background-color: #fff;
border-radius: 15px;
}

table {
  width:100%
}


A:link { color: #777;}
A:visited { color: #777;}
A:active { color: #777;} 
A:hover { color: #000;}


/* image overlay */

#myImg {
  border-radius: 5px;
  cursor: pointer;
  transition: 0.3s;
}

#myImg:hover {
  opacity: 0.7;
}

#myImg18 {
  border-radius: 5px;
  cursor: pointer;
  transition: 0.3s;
  filter: brightness(0%);
  -webkit-filter: brightness(0%);
}

#myImg18:hover {
  opacity: 0.7;
  filter: brightness(100%);
  -webkit-filter: brightness(100%);
}

.modal {
  display: none;
  /* Hidden by default */
  position: fixed;
  /* Stay in place */
  z-index: 10;
  /* Sit on top */
  padding-top: 100px;
  margin-top: 110px;
  /* Location of the box */
  left: 0;
  top: 0;
  width: 100%;
  /* Full width */
  height: auto;
  /* Full height */
  overflow: auto;
  /* Enable scroll if needed */
  background-color: rgb(0, 0, 0);
  /* Fallback color */
  background-color: rgba(0, 0, 0, 0.9);
  /* Black w/ opacity */
}


.modal-content {
  margin: auto;
  z-index: 10;
  display: block;
  max-height: 1000px;
}

#caption {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  text-align: center;
  color: #ccc;
  padding: 10px 0;
  height: 50px;
}

.modal-content,
#caption {
  animation-name: zoom;
  animation-duration: 0.6s;
}

@keyframes zoom {
  from {
    transform: scale(0)
  }
  to {
    transform: scale(1)
  }
}

.close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
}

.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
  cursor: pointer;
}

@media only screen and (max-width: 700px) {
  .modal-content {
    width: 100%;
  }
}


@layer reset, defaults, themes, utilities;



@layer reset, defaults, themes, utilities;



/* ===========
	THEMES
=========== */

@layer themes {

:root {
	--fore-colour: #222;
	--back-colour: white;
	--hot-colour: crimson;
	--cold-colour: mediumBlue;
}
@media (prefers-color-scheme: dark) {
	:root {
		--fore-colour: white;
		--back-colour: #282828;
		--hot-colour: darkOrange;
		--cold-colour: powderBlue;
	}
}

/* =========== END THEMES */ }



/* ==========
	RESET
========== */

@layer reset {

*,
::before,
::after {
	box-sizing: border-box;
}

/* ========== END RESET */ }



/* ==============
	UTILITIES
============== */

@layer utilities {

.uppercase {
	text-transform: uppercase;
}
.lowercase {
	text-transform: lowercase;
}
.undo-case {
	text-transform: none;
}

/* ============== END UTILITIES */ }



/* ==============
	DEFAULTS
============== */

@layer defaults {

/* STRUCTURE */

:root {
	--gap: 1.5rem;
	--line: 2px solid var(--fore-colour);
	--interface-font-size: 1.2em;
	--meta-font-size: 0.8em;
}

#skip-link {
	position: absolute;
	inset-block-start: 0;
	inset-inline-start: 0;
	color: var(--back-colour);
	background-color: var(--fore-colour);
	clip-path: inset(50%);
	&:focus {
		clip-path: unset;
	}
}


/* HEADER */


#header-message {
	padding-block-start: 0.3rem;
	padding-block-end: 0.2rem;
	padding-inline: 0.5rem;
	border-block-start: var(--line);
	border-color: var(--back-colour);
	&::before {
		content: "\25c9 \a0"; /* fisheye + non-breaking space */
		color: var(--hot-colour);
	}
	a {
		color: inherit;
		background-color: inherit;
	}
}

/* TEXT */
:is(h1, h2, h3) + * {
	margin-block-start: 0;
}

details {
	margin-block: 1rem;
	margin-inline-start: var(--gap);
}
summary {
	cursor: pointer;
	font-weight: bold;
	margin-inline-start: -1rem;
	& + * {
		margin-block-start: 0;
	}
}

}
code {
	font-size: 0.8em;
}
.code-block {
	display: block;
	margin-block: 1rem;
	color: var(--back-colour);
	background-color: var(--fore-colour);
	overflow-x: auto;
	white-space: pre;
	tab-size: 4ch;
}
blockquote {
	margin-inline: var(--gap);
}
::marker {
	color: var(--hot-colour);
}

/* MEDIA */

figure {
	margin-inline: var(--gap);
}
figcaption {
	text-align: center;
	blockquote + &::before {
		content: "\2014 \a0"; /* em dash + non-breaking space */
	}
}
.gallery {
	--gallery-cols: 1;
	display: grid;
	grid-template-columns: repeat(var(--gallery-cols), 1fr);
	gap: calc(2rem / var(--gallery-cols));
	padding-left: 0;
	list-style-type: "";
	&:has(:nth-child(2)) {
		--gallery-cols: 2;
	}
	&:has(:nth-child(5)) {
		--gallery-cols: 3;
	}
	&:has(:nth-child(10)) {
		--gallery-cols: 4;
	}
	img {
		height: 100%;
		width: 100%;
		aspect-ratio: 1;
		object-fit: cover;
	display: block;
	margin-inline: auto;
	}
}
iframe {
	max-inline-size: 100%;
	display: block;
	margin-block: 1rem;
	border: var(--line);
}

/* POST LISTS */

.post-list {
	padding-inline-start: var(--gap);
	list-style-type: "";
	text-indent: calc(-1 * var(--gap));
	font-size: var(--interface-font-size);
}
#tag-index {
	padding-inline-start: 0;
	list-style-type: "";
	details {
		margin-block: 0;
	}
	[open] {
		margin-block-end: 1rem;
	}
	summary {
		font-size: var(--interface-font-size);
	}
}

/* POSTS */

article > header {
	margin-block-end: 1rem;
	padding-block-end: 1rem;
	border-block-end: var(--line);
	h1 {
		margin-block-end: 0.5rem;
		font-size: 2.2rem;
	}
	& + * {
		margin-block-start: 0;
	}
}
#post-tags {
	margin-block: 0;
	& > li:not(:last-child)::after {
		content: ",\a0"; /* comma + non-breaking space */
	}
	a::before {
		content: "#";
	}
}
#post-nav > ul {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: var(--gap);
	padding-inline-start: 0;
	list-style-type: "";
	& > :first-child > a::before {
		content: "\2190 \a0"; /* left arrow + non-breaking space */
	}
	& > :last-child {
		text-align: right;
		a::after {
			content: "\2192 \a0"; /* right arrow + non-breaking space */
		}
	}
}

/* ============== END DEFAULTS */ }
