* {
	box-sizing: border-box;
	margin: 0;
}

:root {
	--font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
	--font-family-code: Menlo, Monaco, Consolas, 'Courier New', monospace;
	--font-size: 16px;
	--line-height: 1.7;
	--rule: #52525952;
	--background: #272727;
	--foreground: #ebebebde;
	--pre-background: #1a1a1a;
	--link: #8ad0f5;
	--inline-code: #cbaf72;
	--pre-code: #d1d0cc;
	--code-number: #5ed4ff;
	--code-string: #b4ee64d4;
	--code-literal: #c466f3;
	--code-special: #6ee6d2;
	--code-comment: #84858a;
	--result-header: #434f5b;
	--result-background: #5d6b79;
	--result-shadow: #00000063;
	--toc-width: 210px;
	--toc-button-size: 40px;
	--toc-button-margin: 1rem;
	--toc-button-border: #00000073;
	--border-radius: 4px;
}

html,
body {
	font-family: var(--font-family);
	line-height: var(--line-height);
	font-size: var(--font-size);
	padding: 0;
}

html {
	-webkit-font-smoothing: antialiased;
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
}

body {
	background-color: var(--background);
	color: var(--foreground);
}

/* basic markdown */

strong {
	font-weight: 600;
}

img {
	max-width: 100%;
	max-height: 100%;
}

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

a:hover {
	text-decoration: underline;
}

pre {
	color: var(--pre-code);
	background: var(--pre-background);
	padding: 1rem;
	overflow: auto;
	font-family: var(--font-family-code);
	border-radius: var(--border-radius);
	tab-size: 4;
	font-size: 14px;
}

code {
	font-family: var(--font-family-code);
	font-size: 1em;
	line-height: 1.357em;
	color: var(--inline-code);
}

pre code {
	color: var(--pre-code);
}

p code,
li code {
	white-space: nowrap;
	font-size: 0.8em;
	background-color: var(--pre-background);
	padding: 5px;
	border-radius: 3px;
}

hr {
	height: 2px;
	border: 0;
	background: var(--rule);
}

/* headers */

h1 {
	font-size: 2.35em;
	line-height: 1;
	font-weight: 700;

	border-top: 2px solid var(--rule);
	padding-top: 2rem;
	margin-bottom: 1.75rem;
}

section:first-of-type h1 {
	border: none;
}

h2 {
	font-size: 1.5em;
	line-height: 1.35;
	font-weight: 500;

	border-top: 1px solid var(--rule);
	padding-top: 1.25rem;
	margin-bottom: 1.25rem;
}

h3 {
	font-size: 1em;
	line-height: var(--line-height);
	font-weight: 600;

	border-top: 1px solid var(--rule);
	padding-top: 1.35rem;
	margin-bottom: 1rem;
}

h1 a,
h2 a,
h3 a {
	color: var(--foreground);
}

/* hide header border when scrolling to anchor */

a[name]:empty {
	position: absolute;
	margin-top: 3px;
}

/* vertical spacing */

p,
ul {
	margin-bottom: calc(var(--line-height) * 1rem);
}

ul {
	padding-left: 1.25rem;
}

pre,
.result {
	margin-bottom: calc(var(--line-height) * 1.25rem);
}

p + p,
p + ul,
ul + p,
pre + p,
pre + ul,
pre + .result,
.result + p {
	margin-top: calc(var(--line-height) * -0.25rem);
}

/* code highlighting */

.hljs-keyword,
.hljs-selector-tag,
.hljs-section,
.hljs-doctag,
.hljs-strong {
	font-weight: bold;
}

.hljs-comment {
	color: var(--code-comment);
}

.hljs-section,
.hljs-type,
.hljs-addition,
.hljs-tag,
.hljs-quote,
.hljs-name,
.hljs-selector-id,
.hljs-selector-class,
.hljs-built_in {
	color: var(--code-special);
}

.hljs-literal {
	color: var(--code-literal);
}

.hljs-number {
	color: var(--code-number);
}

.hljs-string {
	color: var(--code-string);
}

/* main */

#container {
	display: flex;
}

main {
	max-width: 700px;
	box-sizing: content-box;
	padding: 0 2rem;
}

/* toc */

#toc-container {
	width: var(--toc-width);
	position: relative;
}

#toc {
	position: fixed;
	overflow: auto;
	width: var(--toc-width);
	height: 100%;
	padding: 0 1rem;
	top: 0;
	background: var(--background);
	z-index: 1002;
	font-size: 12px;
	line-height: 21px;
}

#toc h1,
#toc h2,
#toc h3 {
	border: none;
	padding-top: 0;
	margin-bottom: 1rem;
}

#toc h1 {
	font-size: 14px;
	font-weight: 800;
	margin-top: 0;
	padding-top: 1rem;
}

#toc h2,
#toc h3 {
	font-size: 14px;
	font-weight: 600;
}


#toc ol,
#toc ul {
	margin-top: -0.5rem;
	margin-bottom: 1rem;
	padding-left: 1rem;
}

#toc a {
	color: var(--foreground);
	display: block;
}

/* api toc */

.api-index li:has(strong) {
	color: var(--code-literal);
}

.api-index li {
	list-style: square;
	color: var(--code-number);
}

/* active section highlight */
#toc h2.active a,
#toc li.active a {
	color: var(--link);
}


/* toc button */

#toc-button {
	position: fixed;
	visibility: hidden;
	outline: none;
	cursor: pointer;
	appearance: none;
	z-index: 1;
	width: var(--toc-button-size);
	height: var(--toc-button-size);
	top: var(--toc-button-margin);
	right: var(--toc-button-margin);
	border-radius: var(--border-radius);
	background: var(--background);
	border: 1px solid var(--toc-button-border);
	border-bottom-width: 2px;
	font-size: 0;
	display: flex;
	padding: 10px;
	box-sizing: border-box;
	flex-wrap: wrap;
	align-items: center;
}

#toc-button:before,
#toc-button:after {
	content: ' ';
	display: block;
}

#toc-button:before,
#toc-button:after,
#toc-button div {
	width: 100%;
	height: 3px;
	border-radius: 3px;
	background: var(--foreground);
}

/* examples */

#section-examples {
	margin: 2rem 0 2.5rem;
}

#section-examples li:not(:last-child) {
	margin-bottom: 0.25rem;
}

/* guide */

#section-guide code span.changed {
	background-color: magenta;
	transition: none;
}

#section-guide code span {
	background-color: transparent;
	transition: background-color 0.5s linear;
}

/* guide demos */

.result {
	--header-size: 26px;
	display: flex;
	align-items: flex-start;
	justify-content: flex-end;
	padding: 0 16px 16px 0;
	border-top: var(--header-size) solid var(--result-header);
	border-radius: 5px;
	background: var(--result-background);
	min-height: 150px;
	position: relative;
	box-shadow: 0 5px 30px var(--result-shadow);
}

.result::before {
	width: 12px;
	height: 12px;
	border-radius: 50%;
	content: '';
	position: absolute;
	left: 8px;
	background-color: #ff5f56;
	box-shadow:
		18px 0 0 0 #ffbd2e,
		36px 0 0 0 #27c93f;
	top: calc(-1 * var(--header-size) + 7px);
}

/* api */

main .api-index {
	columns: 2;
	column-rule: 1px solid var(--rule);
	column-gap: 60px;
	margin-bottom: 2rem;
}

main .api-index .class {
	width: 100%;
	break-inside: avoid;
}

main .api-index a {
	color: var(--foreground);
}

main .api-index h3 {
	border: none;
	list-style: none;
	opacity: 0.5;
	padding-top: 0.5rem;
	margin-bottom: 0.5rem;
}

/* member declarations vary weight */
.api-index h2,
#section-api h2 {
	font-weight: normal;
}

.api-index h2 {
	border: none;
	padding: 0;
}

#section-api li p {
	margin-bottom: 1rem;
}

#section-api li:last-child p {
	margin: 0;
}

/* autoPlace demo */

.lil-auto-place {
	will-change: opacity;
	transition: none;
}

.loaded .lil-auto-place {
	transition: opacity 0.2s;
}

.scrolled .lil-auto-place {
	opacity: 0;
	pointer-events: none;
}

@media (max-width: 1200px) {

	.lil-auto-place {
		opacity: 0;
		pointer-events: none;
	}

}

/* small desktop */

@media (max-width: 958px) {
	main {
		margin: 0 auto;
		padding: 0 1rem;
	}

	#container {
		display: block;
	}

	#toc-button {
		visibility: visible;
	}

	#toc {
		border: 0;
		right: 0;
		transition: transform cubic-bezier(0.215, 0.610, 0.355, 1) 0.5s;
	}

	.toc-open #toc {
		box-shadow: 23px 0 10px 20px #0007;
	}

	body:not(.toc-open) #toc {
		transform: translateX(var(--toc-width));
	}
}

/* mobile */

@media (max-width: 500px) {
	pre {
		font-size: 13.5px;
		tab-size: 2;
	}

	.result {
		min-height: 0;
	}

	ul {
		padding-left: 1.5rem;
	}

	main .api-index {
		column-rule: none;
		column-gap: 0;
		font-size: 0.95rem;
	}

	main .api-index ul {
		padding-left: 1rem;
	}

}
