:root {
  --bg: #fff;
  --text: #1b1b1b;
  --muted: #545454;
  --link: #0b57d0;
  --rule: #dedede;
  --code-bg: #f2f2f2;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161616;
    --text: #e9e6e1;
    --muted: #b9b4aa;
    --link: #a8c7fa;
    --rule: #383838;
    --code-bg: #242424;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0 auto;
  max-width: 68ch;
  padding: 1.25rem 1rem 3rem;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
}

h1, h2 { line-height: 1.3; text-wrap: balance; }

h1 { font-size: 1.75rem; margin: 0 0 0.5rem; }

h2 { font-size: 1.12rem; margin: 2rem 0 0.75rem; }

section { margin-top: 0; }

section + section {
  border-top: 1px solid var(--rule);
  padding-top: 0.5rem;
}

p { margin: 0 0 0.9rem; }

.tagline { margin-bottom: 0.25rem; }
.location { color: var(--muted); margin-bottom: 0.75rem; }

.inline-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
}

.compact { margin: 0 0 1rem; padding-left: 1.25rem; }
.compact li { margin-bottom: 0.6rem; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  padding: 0.1em 0.3em;
  border-radius: 3px;
}

a { color: var(--link); text-underline-offset: 0.15em; }
a:visited { color: var(--link); }

:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
  border-radius: 2px;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--text);
  color: var(--bg);
  padding: 0.5rem 1rem;
  z-index: 10;
}

.skip:focus { left: 0.5rem; top: 0.5rem; }

.demo { margin: 1rem 0; }

.demo video {
  display: block;
  width: 100%;
  max-width: 720px;
  height: auto;
  aspect-ratio: 16 / 9;
  background: #000;
  border: 1px solid var(--rule);
}

.demo figcaption, footer p { color: var(--muted); font-size: 0.9rem; }

footer { border-top: 1px solid var(--rule); margin-top: 2rem; padding-top: 1rem; }
footer p { margin: 0; }

@media (min-width: 44rem) {
  body { padding: 2rem 1.5rem 4rem; }
  h1 { font-size: 2rem; }
}

@media print {
  .demo video { display: none; }
  body { max-width: none; }
}
