:root {
	--color-text: #121826;
	--color-text-dim: #6c727f;
	--color-border: #9ca3af;
	--color-border-dim: #e5e7eb;
	--color-background: #ffffff;
	--color-background-dim: rgb(249, 250, 251);
	--color-primary: #4e46dd;
	--border-radius: 4px;
}

@media (prefers-color-scheme: dark) {
	:root {
		--color-text: #fff;
		--color-text-dim: #9da3ae;
		--color-border: #4b5563;
		--color-border-dim: #212936;
		--color-background: #111827;
		--color-background-dim: #212936;
		--color-primary: #6466e9;
	}
}

/* Reset */

/* Box sizing rules */
*,
*::before,
*::after {
	box-sizing: border-box;
}

/* Remove default margin */
* {
	margin: 0;
}

/* Prevent font size inflation */
html {
	-moz-text-size-adjust: none;
	-webkit-text-size-adjust: none;
	text-size-adjust: none;
}

/* Remove default margin in favour of better control in authored CSS */
body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd {
	margin-block-end: 0;
}

/* Remove list styles and padding on ul, ol elements */
ul,
ol {
	list-style: none;
	padding-inline: 0;
}

/* Set core body defaults */
body {
	min-height: 100vh;
	line-height: 1.5;
}

/* Set shorter line heights on headings and interactive elements */
h1,
h2,
h3,
h4,
button,
input,
label {
	line-height: 1.1;
}

/* Balance text wrapping on headings */
h1,
h2,
h3,
h4 {
	text-wrap: balance;
}

/* A elements that don't have a class get default styles */
a:not([class]) {
	text-decoration-skip-ink: auto;
	color: currentColor;
}

/* Make images easier to work with */
img,
picture {
	max-width: 100%;
	display: block;
}

/* Inherit fonts for inputs and buttons */
input,
button,
textarea,
select {
	font-family: inherit;
	font-size: inherit;
}

/* Composition */
body {
	font-family: system-ui, sans-serif;
	color: var(--color-text);
	background-color: var(--color-background);
}
h1,
h2 {
	font-weight: 700;
	letter-spacing: -0.025em;
}
h1 {
	font-size: 3rem;
}
h2 {
	font-size: 2.25rem;
}
a:hover {
	text-decoration: none;
}
summary:hover {
	cursor: pointer;
}
details {
	margin-top: 1rem;
}
details p {
	background-color: var(--color-background-dim);
	padding: 0.5rem 1rem;
	border-radius: var(--border-radius);
}
p {
	margin-bottom: 0.3rem;
}
img {
	background: var(--color-background-dim);
}
li {
	margin-bottom: 0.6em;
}
dl {
	border-left: 1px solid var(--color-border-dim);
	margin-right: 4rem;
	padding-left: 0.75rem;
	display: inline-block;
}
dt {
	color: var(--color-text-dim);
	font-size: 0.875rem;
	font-weight: 500;
}
dd {
	font-size: 1.875rem;
	font-weight: 700;
	line-height: 2.25rem;
}
form {
	display: flex;
	padding: 1.25em 1em;
}
input,
button {
	border-radius: var(--border-radius);
}
input {
	width: 100%;
	padding: 0.4rem 0.8rem;
	border: 1px solid var(--color-border);
	background: var(--color-background-dim);
}
button {
	margin-left: 0.5em;
	background: var(--color-primary);
	color: #fff;
	border: none;
	padding: 0.75em 1.3em;
	cursor: pointer;
}
input:focus {
	outline: 1px solid var(--color-primary);
}
button:hover,
button:focus {
	background: #272eb5;
}
button:focus {
	outline-offset: 3px;
	outline: 1px solid var(--color-primary);
}
section {
	padding: 2.5rem 1em;
}
/* Utilities */
/* flow */
section > * + * {
	-webkit-margin-before: var(--flow-space, 1.5em);
	margin-block-start: var(--flow-space, 1.5em);
}
:is(h1, h2) {
	--flow-space: 0.6em;
}
.center {
	text-align: center;
}
.dim {
	color: var(--color-text-dim);
	font-weight: 500;
}
form,
section {
	max-width: 36em;
	margin: 0 auto;
}
header {
	border-bottom: 1px solid var(--color-border-dim);
}
footer {
	border-top: 1px solid var(--color-border-dim);
	color: var(--color-text-dim);
	text-align: center;
	padding: 1em;
}
/* sticky footer */
html,
body {
	height: 100%;
}
body {
	display: flex;
	flex-direction: column;
}
main {
	flex: 1 0 auto;
}
footer {
	flex-shrink: 0;
}
