html {
  --c-fg: #111;
  --c-bg: #fefefe;
  --c-bg-alt: #eee;
  --c-cta: #0000d7;
}

@media (prefers-color-scheme: dark) {
  html {
    --c-bg: #222;
    --c-fg: #efefef;
    --c-bg-alt: #000;
    --c-cta: hotpink;
  }
}

body,
html {
  margin: 0;
  padding: 0;
  min-height: 100%;
  line-height: 1.6;
}

* {
  font-family: 'source code pro', 'ubuntu Mono', monospace;
}

body {
  font-size: 16px;
  max-width: 640px;
  padding: 20px;
  padding-bottom: 80vh;
  margin: 0 auto;
  font-family: 'source code pro', 'ubuntu Mono', monospace;
  background: var(--c-bg);
  color: var(--c-fg);
  height: 100vh;
  box-sizing: border-box;
}

p {
  line-height: 1.4;
}

a {
  color: var(--c-cta);
}

button,
.button {
  cursor: pointer;
  padding: 4px 16px;
  margin: 4px 0;
  background: var(--c-fg);
  color: var(--c-bg);
  /* font-family: 'source code pro'; */
  font-family: 'source code pro', 'ubuntu Mono', monospace;
  border: 0;
  font-size: 16px;
  line-height: 1.5;
}

button.selected,
.button.selected {
  outline: 2px dashed white !important;
}

button:hover,
.button:hover {
  outline: 2px solid var(--c-fg);
}

pre {
  overflow: scroll;
}

pre,
code {
  font-family: source code pro, ubuntu Mono, monospace;
  background: var(--c-bg-alt);
  border-radius: 2px;
  padding: 0 2px;
}

summary {
  cursor: pointer;
}

summary h3 {
  display: inline;
}

details {
  padding: 16px;
  background: var(--c-bg-alt);
}

details pre {
  overflow: scroll;
}

details + details {
  margin-top: 20px;
}

@media (max-width: 900px) {
  pre {
    overflow: scroll;
  }
}
hr {
  border-bottom: 0;
  border-color: var(--c-bg-alt);
}

h2 a {
  color: var(--c-fg);
  font-weight: 500;
  text-decoration: none;
}

h2 a:hover {
  text-decoration: underline;
}

main > div > div {
  margin-left: 40px;
  margin-bottom: 40px;
}

:target {
  border-left: 4px solid var(--c-cta);
  padding-left: 20px;
}

pre.with-html {
  white-space: normal;
}

.test-working {
  border: 2px solid transparent;
}

.test-working:hover {
  border: 2px dashed var(--c-cta);
  cursor: pointer;
}

.test-working[data-available='true'] {
  color: green;
}
.test-working[data-available='true']:after {
  content: ' 👍';
}

.test-working[data-available='false'] {
  color: red;
}
.test-working[data-available='false']:after {
  content: ' 👎';
}

footer {
  padding-bottom: min(env(safe-area-inset-bottom), 16px);
}
