/* Shared base for the two Nov 2026 layout candidates. Source Serif 4 (SIL OFL), self-hosted.
   One accent colour (rust, #9a3412 light / #e8925c dark, both 7.3:1+ against the page). */

@font-face {
  font-family: "Source Serif 4";
  src: url("/fonts/source-serif-4.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/fonts/source-serif-4-italic.woff2") format("woff2");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}

:root {
  --paper: #ffffff;
  --ink: #121212;
  --muted: #545454;
  --hair: #d9d9d9;
  --accent: #9a3412;
  --on-accent: #ffffff;
  --gap: clamp(1.25rem, 0.8rem + 2vw, 2.5rem);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #121212;
    --ink: #ececec;
    --muted: #a6a6a6;
    --hair: #333333;
    --accent: #e8925c;
    --on-accent: #121212;
  }
}

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

html {
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-size: clamp(1.0625rem, 0.99rem + 0.3vw, 1.2rem);
  line-height: 1.5;
  font-optical-sizing: auto;
  font-variant-numeric: oldstyle-nums proportional-nums;
  font-kerning: normal;
  overflow-wrap: break-word;
}

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

.skip {
  position: absolute;
  left: 1rem; top: -4rem;
  background: var(--ink); color: var(--paper);
  padding: 0.5rem 0.75rem;
  z-index: 20;
}
.skip:focus { top: 1rem; }

.button {
  display: inline-block;
  padding: 0.55em 1.05em 0.6em;
  border: 2px solid var(--accent);
  font-weight: 650;
  text-decoration: none;
  line-height: 1.2;
}
.button.primary { background: var(--accent); color: var(--on-accent); }
.button:not(.primary) { color: var(--accent); }
.button:hover { text-decoration: underline; text-decoration-thickness: 2px; }

.portrait img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  filter: grayscale(1);
}

.date, .when { font-variant-numeric: lining-nums tabular-nums; }
.muted { color: var(--muted); }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
