.postlist { counter-reset: start-from 5 }
/* Defaults */
:root {
	--font-family: -apple-system, system-ui, sans-serif;
	--font-family-monospace: Consolas, Menlo, Monaco, Andale Mono WT, Andale Mono, Lucida Console, Lucida Sans Typewriter, DejaVu Sans Mono, Bitstream Vera Sans Mono, Liberation Mono, Nimbus Mono L, Courier New, Courier, monospace;
}

/* Theme colors */
:root {
  --blue: rgb(79, 181, 233);
  --yellow: rgb(254, 240, 53);
  --orange: rgb(251, 198, 47);
  --teal: rgb(111, 206, 200);
  --red: rgb(234, 33, 45);
  --black: rgb(17, 23, 42);
  --beige: rgb(255, 240, 202);

	--color-gray-20: #e0e0e0;
	--color-gray-50: #C0C0C0;
	--color-gray-90: #111;

	--background-color: #fff;

	--text-color: var(--color-gray-90);
	--text-color-link: #1493fb;
	--text-color-link-active: #5f2b48;
	--text-color-link-visited: #17050F;

	--syntax-tab-size: 2;
}

/* @media (prefers-color-scheme: dark) {
	:root {
		--color-gray-20: #e0e0e0;
		--color-gray-50: #C0C0C0;
		--color-gray-90: #dad8d8;

		/* --text-color is assigned to --color-gray-_ above */
		--text-color-link: #1493fb;
		--text-color-link-active: #6969f7;
		--text-color-link-visited: #a6a6f8;

		--background-color: #15202b;
	}
} */


/* Global stylesheet */
* {
	box-sizing: border-box;
}

html,
body {
	padding: 0 0 5rem 0;
	margin: 0 auto;
}
html {
	overflow-y: scroll;
	background: var(--background-color) url(../img/base/blocks.webp) 100% 0 no-repeat;
  background-size: 266px 383px;
}
body {
	max-width: 45em;
	line-height: 1.6;
	font-size: 1.2rem;
	font-family: var(--font-family);
	color: var(--text-color);
	padding-left: 1.5rem;
	padding-right: 1.5rem;
}

@media screen and (max-width: 875px) {
  html {
    background-size: 133px 192px;
  }
}

@media screen and (max-width: 500px) {
  html {
    padding-top: 47px;
  }
  h1 {
    padding-right: 70px;
  }
}

/* https://www.a11yproject.com/posts/how-to-hide-content/ */
.visually-hidden {
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	height: 1px;
	overflow: hidden;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

h1,
h2 {
  margin: 0 0 0.8em 0;
}

p {
	margin: 0 0 1.6em 0;
  padding: 0;
}

a {
	color: var(--text-color-link);
}

a:hover,
a:active {
	color: var(--text-color-link-active);
}

img {
	max-width: 100%;
	display: block;
	height: auto;
	margin: 0 auto;
}

main {
	padding: 2rem 0;
}

main > * {
	margin-top: 0;
}


.links-nextprev {
	list-style: none;
	border-top: 1px dashed var(--color-gray-20);
	padding: 1em 0;
	margin-top: 5rem;
}

table {
	margin: 1em 0;
}
table td,
table th {
	padding-right: 1em;
}

pre,
code {
	font-family: var(--font-family-monospace);
}
pre:not([class*="language-"]) {
	margin: .5em 0;
	line-height: 1.375; /* 22px /16 */
	-moz-tab-size: var(--syntax-tab-size);
	-o-tab-size: var(--syntax-tab-size);
	tab-size: var(--syntax-tab-size);
	-webkit-hyphens: none;
	-ms-hyphens: none;
	hyphens: none;
	direction: ltr;
	text-align: left;
	white-space: pre;
	word-spacing: normal;
	word-break: normal;
}
code {
	word-break: break-all;
}

figure {
  margin: 0 0 3.2rem;
}

figcaption {
  text-align: center;
}

/* Header */
header {
	display: flex;
	gap: 1em .5em;
	flex-wrap: wrap;
	align-items: flex-start;
	padding: 1em 0;
	flex-direction: column;
	border-bottom: 1px dashed var(--teal);
}

.home-link {
	font-weight: 700;
	margin-right: 2em;
	color: var(--text-color);
	text-decoration: none;
}

.home-link:hover,
.home-link:focus {
	text-decoration: underline;
	color: var(--text-color);
}

/* Nav */
.nav {
	display: flex;
	padding: 0;
	margin: 0;
	list-style: none;
	flex-wrap: wrap;
	justify-content: center;
}
.nav-item {
	display: inline-block;
	margin-right: 1em;
}

.nav-item a {
	display: inline-block;
	padding: 0.2em;
}

.nav-item a[href]:not(:hover) {
	text-decoration: none;
	color: var(--text-color);
}
.nav a[href][aria-current="page"] {
	font-weight: bold;
}

/* Posts list */
.postlist {
	list-style: none;
	padding: 0;
	padding-left: 1.5rem;
}
.postlist-item {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	counter-increment: start-from -1;
	margin-bottom: 1em;
}
.postlist-item:before {
	display: inline-block;
	pointer-events: none;
	content: "" counter(start-from, decimal-leading-zero) ". ";
	line-height: 100%;
	text-align: right;
	margin-left: -1.5rem;
}
.postlist-date,
.postlist-item:before {
	font-size: 0.8125em; /* 13px /16 */
	color: var(--color-gray-90);
}
.postlist-date {
	word-spacing: -0.5px;
}
.postlist-link {
	font-size: 1.1875em; /* 19px /16 */
	font-weight: 700;
	flex-basis: calc(100% - 1.5rem);
	padding-left: .25em;
	padding-right: .5em;
	text-underline-position: from-font;
	text-underline-offset: 0;
	text-decoration-thickness: 1px;
}
.postlist-item-active .postlist-link {
	font-weight: bold;
}

/* Tags */
.post-tag {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-transform: capitalize;
	font-style: italic;
}
.postlist-item > .post-tag {
	align-self: center;
}

/* Tags list */
.post-metadata {
	display: inline-flex;
	flex-wrap: wrap;
	gap: .5em;
	list-style: none;
	padding: 0;
	margin: 0;
}
.post-metadata time {
	margin-right: 1em;
}

.post-metadata + p {
	margin-top: 2rem;
}

/* Direct Links / Markdown Headers */
.header-anchor {
	text-decoration: none;
	font-style: normal;
	font-size: 1em;
	margin-left: .1em;
}
a[href].header-anchor,
a[href].header-anchor:visited {
	color: transparent;
}
a[href].header-anchor:focus,
a[href].header-anchor:hover {
	text-decoration: underline;
}
a[href].header-anchor:focus,
:hover > a[href].header-anchor {
	color: #aaa;
}

h2 + .header-anchor {
	font-size: 1.5em;
}

/* Homepage */


.intro {
  font-size: 1.5rem;
}

.ps {
  font-size: 80%;
}

.contact {
  padding: 0;
  margin: 0 0 1.6em 0;
}

.contact dt::after {
  content: ":";
}

.contact dd {
  margin: 0;
}

@supports (display: grid) {
  /* Equal width DT and DD elements */
  .contact {
    display: grid;
    grid-template-columns: max-content max-content;
    column-gap: 1.8rem;
    align-items: center;
  }
}

/* Responsive video */

.videoWrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  padding-top: 25px;
  height: 0;
  margin: 3.2rem 0;
}
.videoWrapper iframe,
.videoWrapper video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* CodePen embed */
.cp_embed_wrapper {
  margin-bottom: 3.2rem;
}

p:last-child:has(a[href="/"]) {
  margin-top: 6.4rem;
  margin-bottom: 6.4rem;
}

pre[class*="language-"] {
  margin-bottom: 3.2rem;
  padding: 1.5em;
}

/* Hire Me custom layout */


.hire-me {
  margin-bottom: 12rem;
}

@media screen and (min-width: 720px) {
  .hire-me {
    display: grid;
    grid-template-columns: 300px 1fr;
    column-gap: 1rem;
  }
}

.hire-me a {
  font-weight: bold;
}

.hire-me h1 {
  font-size: 8rem;
  text-align: center;
  padding: max(16vh, 5rem) 0;
  grid-column: 1 / -1;
  color: var(--black);
  background-color: var(--orange);
  line-height: 1;
}

.hire-me h2,
.hire-me h3 {
  grid-column: 1;
  margin-top: 0;
  line-height: 1.2;
}

h2[id*="good-at"] {
  grid-row: span 2;
}

.hire-me p,
.hire-me ul {
  grid-column: 2;
  margin: 0 0 3.6em 0;
}

@media screen and (min-width: 720px) {
  .hire-me ul {
    list-style-position: outside;
    padding: 0;
  }
}

.tags {
  padding-left: 0;
  list-style-type: none;
}

.hire-me .tags {
  margin: 0;
}

.tags li {
  display: inline-block;
  margin: 0 0 0.5em 0;
  padding: 0 0.5em;
  border: 1px solid var(--teal);
	font-size: 1rem;
}

/* Card layout, (first) used on Portfolio */

.cardslist {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  grid-gap: 1.8rem;
  margin: 0;
  padding: 0;
  list-style-type: none;
}

.cardslist-item > a {
	color: var(--text-color);
	text-decoration-thickness: 1px;
	text-decoration-skip-ink: auto;
}

.cardslist-item > a:hover,
.cardslist-item > a:focus {
	color: var(--text-color-link);
}

.cardslist-item > a > img {
	border: 2px solid var(--background-color);
	padding: 2px;
}

.cardslist-item > a:hover img,
.cardslist-item > a:focus img {
	border-color: var(--text-color-link);
}

.cardslist-item h2 {
  margin-bottom: 0.5em;
	line-height: 1.2;
}

.tmpl-work img {
	margin-bottom: 3.2rem;
}



.token.property,
.token.tag,
.token.constant,
.token.symbol,
.token.deleted {
  color: #ff4286;
}

/*
 * New diff- syntax
 */

pre[class*="language-diff-"] {
	--eleventy-code-padding: 1.25em;
	padding-left: var(--eleventy-code-padding);
	padding-right: var(--eleventy-code-padding);
}
.token.deleted {
	background-color: hsl(0, 51%, 37%);
	color: inherit;
}
.token.inserted {
	background-color: hsl(126, 31%, 39%);
	color: inherit;
}

/* Make the + and - characters unselectable for copy/paste */
.token.prefix.unchanged,
.token.prefix.inserted,
.token.prefix.deleted {
	-webkit-user-select: none;
	user-select: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding-top: 2px;
	padding-bottom: 2px;
}
.token.prefix.inserted,
.token.prefix.deleted {
	width: var(--eleventy-code-padding);
	background-color: rgba(0,0,0,.2);
}

/* Optional: full-width background color */
.token.inserted:not(.prefix),
.token.deleted:not(.prefix) {
	display: block;
	margin-left: calc(-1 * var(--eleventy-code-padding));
	margin-right: calc(-1 * var(--eleventy-code-padding));
	text-decoration: none; /* override del, ins, mark defaults */
	color: inherit; /* override del, ins, mark defaults */
}

/* Homepage */

.tmpl-home section {
  margin-bottom: 4rem;
}

.tmpl-home h1 span {
  display: block;
  font-size: 80%;
}

.flexColumns {
  display: flex;
  flex-wrap: wrap;
}

.flexColumns > div {
  flex: 1 1 2%;
  min-width: 15ch;
}

.flexColumns h3 {
  margin-top: 0;
}

.flexColumns p:last-child {
  margin-bottom: 0;
}

.flexColumns--colours > div {
  --color: var(--orange);
  padding: 2.4rem;
  border: 1px solid var(--color);
  background-color: color-mix(in oklab, var(--color), white 90%);
}

.flexColumns--colours > div:nth-child(2) { --color: var(--teal)   }
.flexColumns--colours > div:nth-child(3) { --color: var(--yellow) }
.flexColumns--colours > div:nth-child(4) { --color: var(--blue)   }
.flexColumns--colours > div:nth-child(5) { --color: var(--red)    }

.callout {
  --color: var(--teal);
  padding: 2.4rem;
  border: 1px solid var(--color);
  background-color: color-mix(in oklab, var(--color), white 90%);
}

.button {
  display: inline-block;
  padding: 0.25em 1em;
  border: 1px solid var(--blue);
  border-radius: 5px;
  background-color: var(--blue);
  background-color: color-mix(in oklab, var(--blue), black 25%);
  color: white;
  text-decoration: none;
}

.button:hover,
.button:focus {
	color: white;
  background-color: color-mix(in oklab, var(--blue), black 45%);
}