/* mesimon.dev. Colours are the TUI's own (crates/mesimon-tui/src/theme.rs, by
   way of web/mesophon/style.css): Graphite when the system is dark, Chalk when
   it is light. The page has no needs-you, so it has no amber: the one
   saturated colour stays the board's. The fonts are Mesophon's, copied in by
   ci/site.sh. */

@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url(fonts/plex-sans-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans Hebrew";
  font-weight: 500;
  font-display: swap;
  src: url(fonts/plex-sans-hebrew-500.woff2) format("woff2");
  unicode-range: U+0307-0308, U+0590-05FF, U+200C-2010, U+20AA, U+25CC, U+FB1D-FB4F;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-weight: 400;
  font-display: swap;
  src: url(fonts/plex-mono-400-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: dark;
  --bg: #131417;
  --s1: #1b1d21;
  --s2: #23262b;
  --line: rgba(233, 231, 225, 0.08);
  --line2: rgba(233, 231, 225, 0.16);
  --ink: #e9e7e1;
  --ink2: #b6b2a9;
  --ink3: #96918a;
  --calm: #6fbfb0;
  --screen: #0b0c0e;
  --sh-hi: #e9e7e1;
  --sh-body: #b6b2a9;
  --sh-shade: #8c8880;
  --sh-eye: #131417;
  --sh-glint: #f1efe9;
  --sh-blush: #d08fa6;
  --sans: "IBM Plex Sans", "IBM Plex Sans Hebrew", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --bg: #faf8f4;
    --s1: #ffffff;
    --s2: #f3f0ea;
    --line: rgba(34, 37, 43, 0.08);
    --line2: rgba(34, 37, 43, 0.18);
    --ink: #22252b;
    --ink2: #4c4f57;
    --ink3: #5f6169;
    --calm: #0b5f55;
    --screen: #f1eee7;
    --sh-hi: #b9babd;
    --sh-body: #dcdbd8;
    --sh-shade: #8b8d94;
    --sh-eye: #22252b;
    --sh-glint: #faf8f4;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink2);
  font: 400 1.0625rem/1.6 var(--sans);
}
main, footer {
  max-width: 46rem;
  margin: 0 auto;
  padding: 0 16px;
}
main { padding-top: 4rem; }

h1, h2, strong { color: var(--ink); }
h1 {
  margin: 1.25rem 0 0.25rem;
  font-size: 2.5rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
h1 .he {
  font-family: "IBM Plex Sans Hebrew", var(--sans);
  font-weight: 500;
  color: var(--ink3);
  font-size: 0.6em;
  margin-inline-start: 0.35em;
}
h2 {
  margin: 3rem 0 0.75rem;
  font-size: 1.25rem;
  font-weight: 600;
}
.lede {
  margin: 0 0 1rem;
  color: var(--ink);
  font-size: 1.375rem;
  line-height: 1.35;
}
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-inline-start: 1.25rem; }
li { margin-bottom: 0.6rem; }

a { color: var(--ink); text-decoration-color: var(--line2); text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--calm); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--calm); outline-offset: 2px; }

code, kbd {
  font-family: var(--mono);
  font-size: 0.9em;
  color: var(--ink);
}
kbd {
  padding: 0 0.3em;
  border: 1px solid var(--line2);
  border-radius: 4px;
  background: var(--s1);
}

.shin { display: block; }
.shin .sh-body { fill: var(--sh-body); }
.shin .sh-hi { fill: var(--sh-hi); }
.shin .sh-shade { fill: var(--sh-shade); }
.shin .sh-blush { fill: var(--sh-blush); }
.shin .sh-eye { fill: var(--sh-eye); }
.shin .sh-glint { fill: var(--sh-glint); }
.shin .sh-light { fill: var(--calm); }

.cmd {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.75rem;
  padding: 0.7rem 0.75rem 0.7rem 1rem;
  border: 1px solid var(--line2);
  border-radius: 8px;
  background: var(--screen);
}
.cmd code {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  white-space: nowrap;
  font-size: 0.95rem;
}
.cmd code::before { content: "$ "; color: var(--ink3); user-select: none; }
.copy {
  flex: none;
  padding: 0.25rem 0.6rem;
  border: 1px solid var(--line2);
  border-radius: 6px;
  background: var(--s2);
  color: var(--ink);
  font: 500 0.8125rem/1.4 var(--sans);
  cursor: pointer;
}
.or { margin: 0.25rem 0 0.5rem; }

.demo { margin: 3rem 0 0; }
.demo img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line2);
  border-radius: 8px;
  background: var(--screen);
}
.demo figcaption {
  margin-top: 0.6rem;
  color: var(--ink3);
  font-size: 0.9rem;
}

.links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin: 3rem 0 0;
  padding: 1.5rem 0;
  border-top: 1px solid var(--line);
}
footer {
  padding-bottom: 3rem;
  color: var(--ink3);
  font-size: 0.9rem;
}

@media (max-width: 480px) {
  main { padding-top: 2.5rem; }
  h1 { font-size: 2rem; }
  .lede { font-size: 1.2rem; }
  /* A phone shows the whole command, wrapped, rather than a scrolling
     sliver of it; Copy is how a phone takes it anyway. */
  .cmd code { font-size: 0.85rem; white-space: pre-wrap; overflow-wrap: anywhere; }
}
