.articles {
	display: grid;
	grid-template-columns: auto;
  grid-template-rows: auto;
	gap: 2rem 4rem;
}

.article > h2 {
	margin-top: 1rem;
}

@media (min-width: 610px) {
	.articles {
		grid-template-columns: 1fr 1fr;
	}
	.article--full {
		grid-column: span 2; /* Span both columns */
	}
}
/* Defaults */
:root {
	color-scheme: light dark;
	--font-family-serif: Georgia, serif;
	--font-family-sans: -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 {
	--color-gray-50: #c0c0c0;
	--color-header-footer-border: light-dark(#e0e0e0, #000);
	--color-header-footer-background: light-dark(#f4f7f4, #192537);
	--color-whatsapp-green: #25d366;
	--color-whatsapp-green-darker: #11863b;

	--background-color: light-dark(#fff, #15202b);
	--text-color: light-dark(#333, #dad8d8);
	--text-color-link: light-dark(
		var(--color-whatsapp-green-darker),
		var(--color-whatsapp-green)
	);
	--text-color-link-active: var(--text-color-link);
	--text-color-link-visited: var(--text-color-link);
	--text-color-link-decoration: light-dark(#9cc59c, #192537);
	--syntax-tab-size: 2;
}

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

@view-transition {
	navigation: auto;
}

html,
body {
	height: 100%;
	margin: 0;
	padding: 0;
	font-family: var(--font-family-sans);
	color: var(--text-color);
	background-color: var(--background-color);
	font-size: 110%;
	scroll-behavior: smooth;
}
html {
	overflow-y: scroll;
}
body {
	display: flex;
	flex-direction: column;
	min-height: 100vh; /* Ensures the body is at least the height of the viewport */
}

heading-anchors {
	display: contents;
}

main,
.header__inner,
.footer__inner {
	max-width: 40em;
	margin: 0 auto;
}

main {
	flex: 1;
}

/* 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;
}

/* Fluid images via https://www.zachleat.com/web/fluid-images/ */
img {
	max-width: 100%;
}
img[width][height] {
	height: auto;
}
img[src$=".svg"] {
	width: 100%;
	height: auto;
	max-width: none;
}

p:last-child {
	margin-bottom: 0;
}
p {
	line-height: 1.5;
}

ul {
	padding-left: 0.9rem;
}

ul > li {
	padding-inline-start: 0.25rem;
}

ol {
	padding-left: 1.1rem;
}

ol > li {
	padding-inline-start: 0.5rem;
}

li {
	line-height: 1.5;
	margin-bottom: 0.5em;
}
.toc li {
	margin-bottom: 0.25em;
}

a[href] {
	color: var(--text-color-link);
	text-underline-position: from-font;
	text-underline-offset: -1px;
	text-decoration-thickness: 2px;
	text-decoration-color: var(--text-color-link-decoration);
}
a[href]:visited {
	color: var(--text-color-link-visited);
}
a[href]:hover,
a[href]:active {
	color: var(--text-color-link-active);
}

main,
footer {
	padding: 1rem;
}


main p,
main li {
	hyphens: auto;
}

.links-nextprev {
	display: flex;
	justify-content: space-between;
	gap: 1em;
	list-style: "";
	padding: 0;
}
.links-nextprev > * {
	flex-grow: 1;
	padding-inline-start: 0;
}
.links-nextprev-next {
	text-align: right;
}

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

pre,
code {
	font-family: var(--font-family-monospace);
}
pre:not([class*="language-"]) {
	margin: 0.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;
	overflow-x: auto;
}
code {
	word-break: break-all;
}

/* Header */
header {
	border-bottom: 1px dashed var(--color-header-footer-border);
	background-color: var(--color-header-footer-background);
}
.header__inner {
	padding: 1em;
	display: flex;
	flex-direction: column;
	gap: 0.5em;
	flex-wrap: wrap;
	align-items: start;
}

.home-link {
	width: 100%;
	display: flex;

	gap: 0.75rem;
	align-items: center;
	font-size: 1.25rem;
	font-weight: 700;
	margin-right: 1rem;
}
.home-link[href],
.home-link[href]:visited {
	-color: var(--text-color);
}
.home-link:link:not(:hover) {
	text-decoration-line: none;
}

/* Headings */
h1,
h2,
h3,
h4,
h5,
h6 {
	font-weight: 700;
	font-family: var(--font-family-serif);
}

h1 {
	margin-top: 2rem;
	margin-bottom: 1.5rem;
}
h1:first-child {
	margin-top: 0;
}

h2 {
	margin-top: 3rem;
}

h3 {
	margin-top: 2.5rem;
	line-height: 130%;
}

/* Nav */
.main-nav {
	display: inline-flex;
	flex-wrap: wrap;
	padding: 0;
	margin: 0 -0.5rem;
	list-style: none;
	font-size: 90%;
}
@media (min-width: 425px) {
	.main-nav {
		font-size: inherit;
	}
}
.main-nav > ul,
.main-nav > ul > li {
	display: contents;
}

.main-nav--link {
	padding: 0.5rem;
}
@media (min-width: 450px) {
	.main-nav {
		margin: 0 -0.75rem;
	}
	.main-nav--link {
		padding: 0.5rem 0.75rem;
	}
}
.main-nav--link[href]:not(:hover) {
	text-decoration-line: none;
}
.main-nav--link[href][aria-current="page"] {
	text-decoration-line: underline;
}

/* Required for CSS sprites as they're shadow DOM */
symbol {
	fill: inherit;
	stroke: inherit;
}

.link__emoji {
	margin-right: 0.25rem;
}

.button--cta,
.link--cta {
	--gradient-color-top: light-dark(#2ecc71, #1c7a4f);
	--gradient-color-bottom: light-dark(#27ae60, #145c3d);

	background: linear-gradient(
		to bottom,
		var(--gradient-color-top),
		var(--gradient-color-bottom)
	);

	padding: 0.5rem 1.25rem 0.5rem 1rem;
	border-radius: 0.375rem;

	/* Border using light-dark for a suitable dark green in dark mode */
	border: 1px solid light-dark(#1e824c, #0f4d2d);

	display: inline-flex;
	align-items: start;
	gap: 0.4rem;
	margin-top: 1rem;

	font-weight: 500;
	text-decoration-line: none;

	box-shadow: 0 1px 2px light-dark(rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.5));
}

.button--cta:hover,
.link--cta:hover {
	--gradient-color-top: light-dark(#30d778, #22934f);
	--gradient-color-bottom: light-dark(#1a6f41, #105030);
	border-color: light-dark(#1a6f41, #105030);
	box-shadow: 0 2px 4px light-dark(rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.6));
}

.button--cta:active,
.link--cta:active {
	/* Pressed state: uniform gradient in both modes */
	--gradient-color-top: light-dark(#27ae60, #27ae60);
	--gradient-color-bottom: light-dark(#145c3d, #145c3d);
	border-color: light-dark(#196437, #0f3d24);
	box-shadow: inset 0 1px 3px
		light-dark(rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.7));
}

.button--cta,
.link--cta__text {
	color: #fff; /* White in both modes */
	font-size: inherit
}

.noShare #shareBtn {
  display: none;
}


/* Closing, pre-footer */

.page-closing {
	border-top: 1px dashed var(--color-header-footer-border);
	margin-top: 2.5rem;
}


/* Footer */

footer {
	margin-top: 1rem;
	border-top: 1px dashed var(--color-header-footer-border);
	background-color: var(--color-header-footer-background);
	font-size: 90%;
}

.footer__inner {
	padding: 1rem 1rem;
	display: flex;
	justify-content: space-between;
	flex-direction: column;
	align-items: end;
	gap: 1rem;
}

@media (min-width: 425px) {
	footer {
		font-size: inherit;
	}
}

@media (min-width: 690px) {
	.footer__inner {
		flex-direction: row;
		justify-content: space-between;
	}
}