:root {
  --tint: color-mix(in oklab, Field 90%, black 10%);
  --tint-dark: color-mix(in oklab, ButtonBorder 80%, black 20%);
}

html {
  color-scheme: light dark;
  color: CanvasText;
  background-color: Canvas;
  padding-left: calc(100vw - 100%);
}

*, *::after, *::before {
  box-sizing: border-box;
  font-weight: 400;
  line-height: 1.6;
  padding: 0;
  margin: 0;
}

body {
  font-family: system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
  font-size: 1em;
}

header, main {
  max-width: 60em;
  padding: 0 4vw;
  margin: 2rem auto;
}

main {
  margin-bottom: 6rem;
}

svg {
  width: 2.8rem;
}

header {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 1rem;
}

h1 {
  line-height: 1.2;
  color: #2c7df7;
}

h2, details, p, pre {
  margin-top: 1.5em;
}

details[open] + details {
  margin-top: 3em;
}

details {
  margin-left: 1.8em;
}

h2, summary {
  font-size: 1.5em;
  color: #2c7df7;
}

summary {
  line-height: 1.2;
  text-indent: -1.2em;
  -webkit-user-select: none;
  user-select: none;
  cursor: pointer;
}

summary::marker {
  content: '';
}

summary::-webkit-details-marker {
  display: none;
}

summary::before {
  display: inline-block;
  content: '';
  width: 1.2em;
  height: 0.8em;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M8 5v14l11-7z" fill="%232c7df7"/></svg>') 50% 50% no-repeat;
  rotate: 0deg;
  transition: rotate 0.3s ease-out;
}

details[open] summary::before {
  rotate: 90deg;
}

h2 + *, summary + *, li {
  margin-top: 0.25em;
}

ul {
  list-style-type: square;
  padding-left: 2em;
  margin-top: 1em;
}

.label {
  display: inline-block;
  width: 6em;
}

.table {
  overflow: auto;
}

table {
  font-size: 1em;
  table-layout: fixed;
  border-collapse: collapse;
  empty-cells: show;
  margin: 1.5em auto;
  border: 2px solid CanvasText;
}

th, td {
  min-width: 6em;
  border: 1px dotted CanvasText;
  border-left-style: solid;
}

th {
  border-bottom-style: solid;
}

thead {
  background-color: var(--tint);
}

caption, th, td {
  text-align: center;
  padding: 0.2em 0.3em;
}

table a {
  display: block;
}

caption, th, strong {
  font-weight: 600;
}

pre {
  white-space: pre;
  padding: 6px 10px;
  background-color: var(--tint);
  border-radius: 3px;
  border-left: 4px solid var(--tint-dark);
  overflow-x: auto;
  overflow-y: hidden;
}

code {
  display: inline-block;
  font-family: ui-monospace, Menlo, Monaco, "Cascadia Mono", "Segoe UI Mono", "Roboto Mono", "Oxygen Mono", "Ubuntu Monospace", "Source Code Pro", "Fira Mono", "Droid Sans Mono", "Courier New", monospace;
  font-size: 1em;
  font-weight: 300;
  padding: 0 3px;
  color: ButtonText;
  background-color: var(--tint);
  border-radius: 3px;
  -webkit-user-select: all;
  user-select: all;
}

pre code {
  background-color: transparent;
}

a:link, a:visited {
  color: #2c7df7;
}

a:hover, a:focus {
  color: ActiveText;
}

svg#camera {
  width: 4rem;
  margin-left: auto;
  color: #777;
  filter: none;
  animation: 4s linear 2s 1 flash;
}

header:hover svg#camera, header:focus-within svg#camera {
  animation: 4s linear 0s infinite flash;
}

@keyframes flash {
  0% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
  1% { color: Mark; filter: drop-shadow(0 0 5px Mark); }
  2% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
  3% { color: Mark; filter: drop-shadow(0 0 5px Mark); }
  4% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
  5% { color: Mark; filter: drop-shadow(0 0 5px Mark); }
  6% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
  14% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
  15% { color: Mark; filter: drop-shadow(0 0 5px Mark); }
  30% { color: #777; filter: drop-shadow(0 0 0px Canvas); }
}

@media (prefers-reduced-motion: reduce) {

  *, *::before, *::after {
    transition-timing-function: step-start !important;
    animation-delay: 0s !important;
    animation-timing-function: step-start !important;
    animation-iteration-count: 1 !important;
  }

}
