*,
*::after,
*::before {
	box-sizing: border-box;
	text-size-adjust: 100%;
}

html {
	font-family:
		"Jost",
		-apple-system,
		blinkmacsystemfont,
		"Segoe UI",
		roboto,
		"Helvetica Neue",
		arial,
		"Noto Sans",
		sans-serif,
		"Apple Color Emoji",
		"Segoe UI Emoji",
		"Segoe UI Symbol",
		"Noto Color Emoji";
	font-size: 62.5%;
	min-height: 100%;
	overflow-y: scroll;
}

body {
	background-color: $colorBg;
	color: $colorText;
	font-size: $fontSizeBase;
	font-synthesis: weight style small-caps;
	font-weight: 400;
	line-height: 1.5;
	margin: auto;
	max-width: 52em;
	min-height: 100vh;
	padding: 2em 4em;
	position: relative;
	text-rendering: optimizelegibility;
}

@media (width <=684px) {
	body {
		font-size: $fontSizeBase * 0.85;
		padding: 2em 1em;
	}
}

h1,
h2,
h3,
h4,
h5,
h6 {
	font-weight: 700;
	line-height: 1.1;
	margin: 3rem 0;
	overflow-wrap: break-word;
	word-break: break-word;
	word-wrap: break-word;
}

h1 {
	font-size: 2.35em;
}

h2 {
	font-size: 2em;
}

h3 {
	font-size: 1.75em;
}

h4 {
	font-size: 1.5em;
}

h5 {
	font-size: 1.25em;
}

h6 {
	font-size: 1em;
}

p {
	margin-bottom: 2.5rem;
	margin-top: 0;
}

small,
sub,
sup {
	font-size: 75%;
}

hr {
	border-color: $colorBlossom;
}

a {
	color: $colorBlossom;
	text-decoration: inherit;
	transition: color 0.25s;

	&:visited {
		color: $colorBlossom;
	}

	&:active,
	&:focus,
	&:hover {
		opacity: 0.5;
	}
}

ul {
	margin-bottom: 2.5rem;
	margin-top: 0;
	padding-left: 1.4em;
}

li {
	margin-bottom: 0.4em;
}

blockquote {
	background-color: $colorBgAlt;
	border-left: 5px solid $colorBlossom;
	margin-bottom: 2.5rem;
	margin-left: 0;
	margin-right: 0;
	padding: 0.8em 0.8em 0.8em 1em;
}

blockquote p {
	margin-bottom: 0;
}

img,
video {
	display: block;
	height: auto;
	margin-bottom: 2.5rem;
	margin-top: 0;
	max-width: 100%;
}

pre {
	background-color: $colorBgAlt;
	border-radius: 4px;
	border: 1px solid $colorBgAlt;
	display: block;
	font-size: 0.9em;
	margin-bottom: 2.5rem;
	margin-top: 0;
	overflow-x: auto;
	padding: 1em;
}

code,
kbd,
samp {
	background-color: $colorBgCode;
	border-radius: 4px;
	font-size: 0.9em;
	padding: 0 0.2em;
	white-space: pre-wrap;
}

pre > code {
	background-color: transparent;
	font-size: 1em;
	padding: 0;
	white-space: pre;
}

table {
	border-collapse: collapse;
	text-align: justify;
	width: 100%;
}

td,
th {
	border-bottom: 1px dashed $colorBlossom;
	padding: 0.5em;
}

textarea {
	width: 100%;
}

.button,
button,
input[type="submit"],
input[type="reset"],
input[type="button"] {
	background-color: $colorBlossom;
	border: 1px solid $colorBlossom;
	border-radius: 1px;
	box-sizing: border-box;
	color: $colorBg;
	cursor: pointer;
	display: inline-block;
	padding: 5px 10px;
	text-align: center;
	text-decoration: none;
	white-space: nowrap;

	&[disabled] {
		cursor: default;
		opacity: 0.5;
	}

	&:focus:enabled,
	&:hover:enabled {
		background-color: $colorFade;
		border-color: $colorFade;
		color: $colorBg;
		outline: 0;
	}
}

textarea,
select,
input {
	background-color: $colorBgAlt;
	border: 1px solid $colorBgAlt;
	border-radius: 4px;
	box-shadow: none;
	box-sizing: border-box;
	color: $colorText;
	margin-bottom: 10px;
	padding: 6px 10px;

	&:focus {
		border: 1px solid $colorBlossom;
		outline: 0;
	}
}

input[type="checkbox"]:focus {
	outline: 1px dotted $colorBlossom;
}

label,
legend,
fieldset {
	display: block;
	font-weight: 600;
	margin-bottom: 0.5rem;
}