/* The site's one stylesheet, written by hand: mobile-first, with a wider screen
   adding room in the single media query at the end. No build step. */

/* The site's three fonts, served from the site itself (fonts/, with their licences):
   Open Sans for reading, upright and italic, each one variable font for every weight;
   Aboreto and Shadows Into Light for the header. */
@font-face {
  font-family: "Open Sans";
  src: url("/fonts/open-sans-latin-wght-normal.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Open Sans";
  src: url("/fonts/open-sans-latin-wght-italic.woff2") format("woff2");
  font-weight: 300 800;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: Aboreto;
  src: url("/fonts/aboreto-latin-400-normal.woff2") format("woff2");
  font-display: swap;
}

@font-face {
  font-family: "Shadows Into Light";
  src: url("/fonts/shadows-into-light-latin-400-normal.woff2") format("woff2");
  font-display: swap;
}

:root {
  --paper: #fdfbf7;
  --ink: #222;
  --muted: #5f5a52;
  --link: #8a5a00;
  --rule: #e4ddd0;
  --card: #fff;
  --header: #3a74c9;
  --dandelion: #f2c230;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* The reading text: Open Sans, the same size on a phone and a desktop (the author's
   values of 2026-12-04 and 2026-12-05). */
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Open Sans", "Segoe UI", Aptos, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.35;
  -webkit-text-size-adjust: 100%;
}

a {
  color: var(--link);
}

a:hover,
a:focus {
  text-decoration-thickness: 2px;
}

img {
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3 {
  font-weight: normal;
  line-height: 1.25;
}

/* A post's title, and the headings below it: the section headings, the cards'
   titles and the headings inside a post. */
h1 {
  font-size: 32px;
}

h2,
h3 {
  font-size: 26px;
}

/* The header, as on the current site: the site's name centered over the author's
   watercolor of a dandelion in a field, and the three sentiments below it, in
   three columns on a wide screen and stacked on a phone. Their shadows keep
   them readable over the light parts of the painting. The painting is drawn
   10px taller than the header and cut off by it, so its bottom 10px are cropped
   and nothing else moves. */
.site-header {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 1.5rem 1rem calc(4rem - 10px);
  background: var(--header);
  color: #fff;
  text-align: center;
  text-shadow: 0 1px 3px rgb(0 0 0 / 80%);
}

.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 -10px;
  z-index: -1;
  background: url("/header.png") center / cover no-repeat;
}

/* Smaller on a phone, where it may wrap to two lines; 80px on a wider screen. */
.site-title {
  display: block;
  color: #fff;
  font-family: Aboreto, sans-serif;
  font-size: 3.5rem;
  font-weight: normal;
  line-height: 1.1;
  text-transform: uppercase;
  text-decoration: none;
  text-shadow: -0.08em 0.06em 0.09em #000000;
}

.tagline {
  display: grid;
  margin: 0.75rem 0 0;
  font-family: "Shadows Into Light", cursive;
  font-size: 42px;
  line-height: 0.9em;
  text-shadow: 0.08em 0.08em 0.08em #000000;
}

.tagline span::before {
  content: "-\00a0";
}

/* The menu bar below the header, as on the current site: a white bar with the icon
   and the menu, lifted off the page by a shadow, its contents lined up with the
   reading column. */
.menu-bar {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem max(1rem, calc((100% - 36em) / 2 + 1rem));
  background: #fff;
  box-shadow: 0 6px 12px -2px rgb(0 0 0 / 25%);
}

.menu-icon img {
  display: block;
  width: 3rem;
  height: 3rem;
}

/* On a phone the menu folds behind a hamburger, with CSS alone: the label toggles
   the hidden checkbox, and the checkbox's state shows the menu. */
.menu-toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.menu-label {
  padding: 0 0.5rem;
  color: var(--header);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

.menu-toggle:focus-visible + .menu-label {
  outline: 2px solid var(--dandelion);
}

.menu {
  display: none;
  flex-basis: 100%;
  margin: 0.5rem 0 0;
  padding: 0;
  list-style: none;
}

.menu-toggle:checked ~ .menu {
  display: block;
}

.menu a {
  display: block;
  padding: 0.25rem 0;
  color: #666;
  font-family: "Shadows Into Light", cursive;
  font-size: 1.75rem;
  text-decoration: none;
}

.menu a:hover,
.menu a:focus {
  color: var(--ink);
}

/* The page's content, one column at a measure for reading. */
main {
  max-width: 36em;
  margin: 0 auto;
  padding: 1rem 1rem 0;
}

/* Half again a paragraph's space below it, so a heading that opens the post stands
   apart from the title and the date. */
.date {
  margin-top: -0.5rem;
  margin-bottom: 1.5em;
  color: var(--muted);
}

.post blockquote {
  margin: 1.5rem 0;
  padding-left: 1rem;
  border-left: 3px solid var(--dandelion);
  color: var(--muted);
}

.post table {
  display: block;
  overflow-x: auto;
  margin: 1.5rem 0;
  border-collapse: collapse;
}

.post th,
.post td {
  padding: 0.5rem;
  border: 1px solid var(--rule);
  text-align: left;
  vertical-align: top;
}

.draft-banner {
  margin: 0 0 1rem;
  padding: 0.5rem;
  background: var(--dandelion);
  color: var(--ink);
  font-weight: bold;
  letter-spacing: 0.2em;
  text-align: center;
}

.tombstone {
  color: var(--muted);
}

/* The home page's two zones and their cards. */
.zone + .zone {
  margin-top: 2.5rem;
}

.zone h2 {
  border-bottom: 2px solid var(--dandelion);
}

.card {
  margin: 1rem 0;
  padding: 1rem;
  border: 1px solid var(--rule);
  border-radius: 0.5rem;
  background: var(--card);
}

.card h3 {
  margin: 0 0 0.5rem;
}

.card .draft-banner {
  margin: 0 0 0.5rem;
}

.card h3 a {
  text-decoration: none;
}

.card p {
  margin: 0.5rem 0 0;
}

.connected {
  color: var(--muted);
  font-size: 0.95rem;
}

/* A post's text ends with the centered dandelion, a paragraph's space below the text;
   a paragraph's space below the dandelion, the footer's rule and name, like a
   signature (main has no bottom padding, so nothing adds to that space). */
.end-mark {
  text-align: center;
}

.end-mark img {
  width: 3rem;
  height: 3rem;
  vertical-align: top;
}

.site-footer {
  padding: 1rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  text-align: center;
}

/* A wider screen: the name at full size, the sentiments in three columns, the menu
   standing open beside the icon, and more room. */
@media (min-width: 40em) {
  .site-header {
    padding: 2rem 2rem calc(4.5rem - 10px);
  }

  .site-title {
    font-size: 80px;
  }

  .tagline {
    grid-template-columns: repeat(3, 1fr);
    max-width: 60rem;
    margin: 1rem auto 0;
  }

  .menu-bar {
    justify-content: flex-start;
    gap: 1.5rem;
  }

  .menu-label {
    display: none;
  }

  .menu {
    display: flex;
    flex-basis: auto;
    gap: 1.25rem;
    margin: 0;
  }

  main {
    padding: 2rem 1rem 0;
  }
}
