/* sealmesh.dev in the prelude look: the unstyled document web.
   Three colors, one serif, one divider. Nothing loads.
   landing.css adds the home page's globe and install section. */

:root {
  --ground:  #ffffff;
  --ink:     #000000;
  --link:    #0000ee;
  --visited: #551a8b;
  --muted:   #555555;
  --rule:    #d6d6d6;
  --serif: "Times New Roman", Times, "Liberation Serif", serif;
  --mono:  "SF Mono", ui-monospace, Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #0b0b0b; --ink: #e9e9e9; --link: #8ab4ff;
    --visited: #b8a3e0; --muted: #9b9b9b; --rule: #333333;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #0b0b0b; --ink: #e9e9e9; --link: #8ab4ff;
  --visited: #b8a3e0; --muted: #9b9b9b; --rule: #333333;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { background: var(--ground); }
body {
  background: var(--ground);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.1875rem;
  line-height: 1.6;
  margin: 0;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1 { font-size: 2.6rem;  font-weight: 700; line-height: 1.08; margin: 0 0 .3em; text-wrap: balance; }
h2 { font-size: 1.55rem; font-weight: 700; line-height: 1.2;  margin: 2.2em 0 .6em; text-wrap: balance; }
h3 { font-size: 1.2rem;  font-weight: 700; line-height: 1.3;  margin: 1.8em 0 .4em; }

p { margin: 0 0 1.15em; }

a          { color: var(--link); text-decoration: underline; text-underline-offset: 2px; }
a:visited  { color: var(--visited); }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }

ul, ol { margin: 0 0 1.15em; padding-left: 1.3em; }
li { margin-bottom: .4em; }

hr { border: 0; border-top: 1px solid var(--ink); margin: 2.4em 0; }

code { font-family: var(--mono); font-size: .8em; }
pre { font-family: var(--mono); font-size: .8rem; line-height: 1.5; margin: 0 0 1.15em; overflow-x: auto; white-space: pre; }
pre code { font-size: inherit; }

table { border-collapse: collapse; width: 100%; font-size: .92em; font-variant-numeric: tabular-nums; }
th { text-align: left; font-weight: 700; border-bottom: 1px solid var(--ink); padding: .25em .8em .25em 0; }
td { padding: .25em .8em .25em 0; vertical-align: top; }

blockquote { margin: 0 0 1.15em; padding-left: 1em; border-left: 1px solid var(--muted); }
blockquote p:last-child { margin-bottom: 0; }

button, input { font: inherit; color: var(--ink); background: var(--ground); border: 1px solid var(--ink); -webkit-appearance: none; appearance: none; }
button { padding: .3em .9em; min-height: 44px; cursor: pointer; }

.muted { color: var(--muted); }
.mono  { font-family: var(--mono); font-size: .8em; }

.skip { position: absolute; left: -9999px; top: 8px; }
.skip:focus { left: 16px; background: var(--ground); padding: .2em .4em; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }

/* One column, left aligned, centered in the window. */
.wrap { max-width: 40rem; margin: 0 auto; }
.docs-page .wrap { max-width: 54rem; }

/* Chrome: the preview line, the site name and the nav. */
.preview-bar { margin-top: 0; margin-bottom: 0; padding: 10px 0 0; font-family: var(--mono); font-size: .72rem; line-height: 1.5; color: var(--muted); }
.topbar { display: flex; flex-wrap: wrap; align-items: center; column-gap: 1.5em; row-gap: .2em; padding: 1.4em 0 0; margin-top: 0; margin-bottom: 2.5em; }
.brand { color: var(--ink); text-decoration: none; font-weight: 700; display: inline-flex; align-items: center; gap: .4em; }
.brand-mark { height: 1.2em; width: auto; flex: none; }
.brand-mark-eye { fill: var(--ground); }
.brand:visited { color: var(--ink); }
.nav { display: flex; flex-wrap: wrap; column-gap: 1em; }

main { display: block; }

footer { padding-block: 64px 48px; font-size: .95em; }
footer hr { margin: 0; }
footer p { margin: .5em 0; font-style: italic; }

/* Prose pages: changelog, security, license. */
.prose h1 { margin-bottom: .5em; }
.prose h2 a, .prose h3 a { color: inherit; text-decoration: none; }
.prose img, .prose svg { max-width: 100%; height: auto; }
.prose .lede { font-size: 1.12em; }
.prose table { display: block; overflow-x: auto; margin: 0 0 1.4em; }
.prose pre { position: relative; }

.pre-copy { position: absolute; top: 0; right: 0; min-height: 32px; padding: 0 .7em; font-family: var(--serif); font-size: .95rem; opacity: 0; }
.prose pre:hover .pre-copy, .pre-copy:focus-visible { opacity: 1; }
@media (hover: none) { .pre-copy { opacity: 1; } }

/* A drawn figure: ink lines, no fill, flips with the theme.
   Labels are serif like the page; .code marks a path, command or frame. */
.figure { margin: 1.4em 0 1.8em; color: var(--ink); }
.figure svg { display: block; width: 100%; max-width: 32rem; height: auto; }
.figure text { font-family: var(--serif); }
.figure .code { font-family: var(--mono); }
.figure .figure-muted { fill: var(--muted); }
.figure .figure-edge { stroke: var(--muted); }
.figure figcaption { margin-top: .7em; font-size: .9em; line-height: 1.5; color: var(--muted); }

/* Docs: a plain side list and search on the left, the page on the right. */
.docs { display: grid; grid-template-columns: 12rem minmax(0, 38rem); column-gap: 4rem; justify-content: center; }
.docs-nav { position: sticky; top: 24px; align-self: start; max-height: calc(100vh - 48px); overflow: auto; font-size: .9rem; line-height: 1.5; }
.docs-nav-toggle summary { display: none; }
.docs-links { list-style: none; margin: 1em 0 0; padding: 0; }
.docs-links li { margin: 0 0 .35em; }
.docs-links a[aria-current="page"] { color: var(--ink); font-weight: 700; text-decoration: none; }

.search input { width: 100%; padding: .3em .45em; font-size: .95rem; }
.search input::placeholder { color: var(--muted); }
.search-results { list-style: none; margin: .6em 0 0; padding: 0; }
.search-results li { margin: 0 0 .6em; }
.search-results .muted { display: block; font-size: .85em; text-decoration: none; }
.search-results a .muted { color: var(--muted); }

.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5em 2em; margin-top: 3em; }
.pager .next { margin-left: auto; text-align: right; }
.doc-meta { margin-top: 1.5em; font-size: .9em; }

.notfound { padding-top: 2em; }

@media (max-width: 900px) {
  .docs { grid-template-columns: minmax(0, 38rem); }
  .docs-nav { position: static; max-height: none; margin: 0 0 2em; }
  .docs-nav-toggle summary { display: list-item; cursor: pointer; min-height: 44px; line-height: 44px; }
  .docs-nav-toggle[open] { padding-bottom: 1em; border-bottom: 1px solid var(--rule); }
}

@media (max-width: 480px) {
  body { font-size: 1.0625rem; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
  h1 { font-size: 2.1rem; }
  h2 { font-size: 1.35rem; }
  .topbar { margin-bottom: 2em; }
  footer { padding-block: 48px 32px; }
}
