/* Meileo: one stylesheet for every page. Colours, fonts and the left inset are set once in :root. */

@font-face { font-family: "Pixelify Sans"; src: url("/fonts/pixelify-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Pixelify Sans"; src: url("/fonts/pixelify-sans-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible Next"; src: url("/fonts/atkinson-next-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible Next"; src: url("/fonts/atkinson-next-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --sage: #6f9a8d;                       /* the page colour */
  --ink: #111;                           /* text: 6.0:1 contrast on sage */
  --pixel: "Pixelify Sans", ui-monospace, monospace;
  --text: "Atkinson Hyperlegible Next", system-ui, sans-serif;
  --inset: clamp(1.25rem, 8vw, 8rem);    /* left margin: small on phones, wide on desktops */
}

* { box-sizing: border-box; }

html { background: var(--sage); color: var(--ink); -webkit-text-size-adjust: 100%; }

body { margin: 0; padding: 0 1.25rem 0 var(--inset); font: 400 1.125rem/1.6 var(--text); }

.site-header, main, .site-footer { max-width: 36rem; }

.site-header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 2rem 0 2.5rem; }

.brand { margin: 0; font: 500 1.75rem/1 var(--pixel); }
.brand a { display: inline-flex; align-items: center; gap: 0.75rem; text-decoration: none; }
.brand img { image-rendering: pixelated; }

h1, h2 { font-family: var(--pixel); font-weight: 500; line-height: 1.2; }
main h1 { font-size: 2rem; margin: 0 0 1rem; }
h2 { font-size: 1.375rem; margin: 2.25rem 0 0.5rem; }

.lead { font-size: 1.25rem; margin-top: 0; }
p, ul { margin: 0 0 1rem; }
ul { padding-left: 1.25rem; }
.effective { font-size: 0.95rem; }

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 3px; }
a:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }

.site-footer { padding: 3rem 0 2.5rem; font-size: 0.95rem; }

@media (max-width: 30rem) {
  .site-header { padding-top: 1.25rem; }
  .brand { font-size: 1.5rem; }
}
