/* kerbmile.co.uk
 *
 * The game's palette and typeface, and none of its board vocabulary. Paper,
 * deep ink, and amber on the one thing that is pressable — which is the app's
 * own rule for amber, not a coincidence.
 *
 * No third-party requests of any kind: the fonts are served from this domain
 * rather than from Google Fonts, because a page whose whole subject is "this
 * app sends nothing anywhere" should not itself send the reader's IP address
 * to a third party to render its own heading.
 */

@font-face {
  font-family: "Libre Franklin";
  src: url("fonts/LibreFranklin-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Libre Franklin";
  src: url("fonts/LibreFranklin-Medium.ttf") format("truetype");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Libre Franklin";
  src: url("fonts/LibreFranklin-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-display: swap;
}

:root {
  --paper: #efe8dc;   /* Palette.frame */
  --ground: #d5c9b1;  /* Palette.ground */
  --rail: #dbd0be;    /* Palette.rail */
  --ink: #231f1a;     /* Palette.deepInk */
  --amber: #f2a32c;   /* Palette.accent */
  --amber-ink: #5e3404;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Libre Franklin", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 400;
  font-size: 17px;
  line-height: 1.62;
  -webkit-text-size-adjust: 100%;
}

.wrap {
  max-width: 40rem;
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
}

header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--rail);
  padding-bottom: 1.25rem;
  margin-bottom: 2.5rem;
}

.mark {
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
}

/* Flex on the header rather than a float here: a floated nav is not contained
   by its parent, so the header's border-bottom drew above the nav instead of
   below both of them. */
nav { font-size: 15px; white-space: nowrap; }
nav a { margin-left: 1.1rem; }

h1 {
  font-weight: 600;
  font-size: 1.85rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin: 0 0 0.75rem;
}

h2 {
  font-weight: 600;
  font-size: 1.15rem;
  margin: 2.5rem 0 0.6rem;
}

h3 {
  font-weight: 500;
  font-size: 1rem;
  margin: 1.75rem 0 0.4rem;
}

p, ul, ol { margin: 0 0 1rem; }
ul, ol { padding-left: 1.3rem; }
li { margin-bottom: 0.35rem; }

a {
  color: var(--amber-ink);
  text-decoration-color: var(--amber);
  text-underline-offset: 2px;
  text-decoration-thickness: 2px;
}
a:hover { background: var(--amber); color: var(--amber-ink); text-decoration: none; }

.lede { font-size: 1.1rem; color: var(--ink); }
.muted { color: #6b5c42; }  /* the floor-mechanic ink, the only other neutral */

.app {
  border: 1px solid var(--rail);
  border-radius: 10px;
  padding: 1.25rem 1.35rem;
  background: #f5f1e8;
  margin-bottom: 1rem;
}
.app h2 { margin-top: 0; }
.app p:last-child { margin-bottom: 0; }
.status {
  display: inline-block;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b5c42;
}

dl { margin: 0 0 1rem; }
dt { font-weight: 600; margin-top: 1rem; }
dd { margin: 0.15rem 0 0; }

.note {
  border-left: 3px solid var(--rail);
  padding: 0.1rem 0 0.1rem 1rem;
  margin: 1.5rem 0;
  color: #6b5c42;
}

footer {
  border-top: 1px solid var(--rail);
  margin-top: 4rem;
  padding-top: 1.25rem;
  font-size: 15px;
  color: #6b5c42;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92em;
  background: var(--ground);
  padding: 0.1em 0.3em;
  border-radius: 3px;
}

@media (max-width: 34rem) {
  .wrap { padding: 2rem 1.15rem 4rem; }
  header { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  nav a { margin: 0 1.1rem 0 0; }
}
