/* jeremiahchronister.com
   Brand kit: Navy #1B2A4A primary, Gold #C9A84C accent (brief S3, unchanged).
   Design brief: single column, generous whitespace, high type contrast, no motion.
   It should look like a person who manages systems and money, not like a creator.

   No webfonts are loaded. Inter and Helvetica Neue are named first and used when the
   visitor already has them; everything else falls back to the platform UI face. That
   keeps the page at zero third-party requests, which is the same reason the analytics
   choice is Plausible or nothing. To self-host Inter later, drop the woff2 files in
   /assets/fonts/ and uncomment the @font-face block at the bottom of this file. */

:root {
  --navy: #1b2a4a;
  --gold: #c9a84c;

  --bg: #fbfaf8;
  --surface: #f3f1ec;
  --text: #17223a;
  --text-muted: #56607a;
  --rule: #dedad2;
  --link: #1b2a4a;

  --sans: Inter, "Helvetica Neue", -apple-system, BlinkMacSystemFont, "Segoe UI",
          Roboto, Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Charter, Georgia,
           "Times New Roman", serif;

  --measure: 34rem;
  --gutter: 1.5rem;
}

/* The site commits to a light, paper-like ground. The dark variant exists so the page
   does not read as broken in a dark browser; it is the same design, not a second one. */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111a2c;
    --surface: #18233a;
    --text: #e9e6df;
    --text-muted: #9aa3b8;
    --rule: #2b364f;
    --link: #e9e6df;
  }
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--serif);
  font-size: 1.0625rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Nav, labels, dates and other furniture stay in the sans face. Prose is serif.
   To test the all-sans variant, change `font-family: var(--serif)` above to var(--sans). */

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--navy);
  color: #fff;
  padding: 0.6rem 1rem;
  font-family: var(--sans);
  font-size: 0.9rem;
}
.skip:focus { left: 0; z-index: 10; }

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------------------------------------------------------------- masthead */

.masthead {
  padding: 3rem 0 0;
}

.masthead .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.75rem;
  justify-content: space-between;
}

/* Home has no wordmark, so the nav carries the row on its own. */
.masthead--home .wrap { justify-content: flex-end; }

.wordmark {
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}
.wordmark:hover { color: var(--text); }

.masthead nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.25rem;
}

.masthead nav a {
  font-family: var(--sans);
  font-size: 0.875rem;
  letter-spacing: 0.01em;
  color: var(--text-muted);
  text-decoration: none;
}
.masthead nav a:hover,
.masthead nav a[aria-current="page"] {
  color: var(--text);
}
.masthead nav a[aria-current="page"] {
  border-bottom: 2px solid var(--gold);
  padding-bottom: 2px;
}

/* ------------------------------------------------------------------- main */

main { padding: 3.5rem 0 4rem; }

h1 {
  font-family: var(--sans);
  font-size: 1.875rem;
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin: 0 0 0.75rem;
}

.standfirst {
  font-family: var(--sans);
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 0 2.5rem;
}

h2 {
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 3.25rem 0 0.375rem;
}

h2 + .group-note {
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0 0 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--rule);
}

p { margin: 0 0 1.25rem; }

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration-color: var(--gold); }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.lede p:first-child { margin-top: 0; }

/* Portrait on /about. Deliberately NOT floated: the measure is 34rem, so a 220px
   float leaves the opening paragraph about six words wide. A block above the lede
   holds at every width and needs no breakpoint. width/height are set on the element
   so the layout does not shift while the image loads. */
.portrait {
  display: block;
  width: 168px;
  height: auto;
  border-radius: 2px;
  margin: 0 0 1.75rem;
}

/* The two doors on the home page. Text links with a rule, not buttons. */
.doors {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  border-top: 1px solid var(--rule);
}
.doors li { border-bottom: 1px solid var(--rule); }
.doors a {
  display: block;
  padding: 1.125rem 0;
  text-decoration: none;
  font-family: var(--sans);
}
.doors .door-title {
  display: block;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}
.doors .door-note {
  display: block;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}
.doors a:hover .door-title { color: var(--text); }
.doors a:hover .door-note { color: var(--text); }

/* --------------------------------------------------------- writing entries */

.entries { list-style: none; margin: 0; padding: 0; }

.entries li {
  padding: 1.125rem 0;
  border-bottom: 1px solid var(--rule);
}
.entries li:first-child { padding-top: 0; }

.entry-title {
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.35;
  display: block;
  margin-bottom: 0.25rem;
}

.entry-frame {
  margin: 0;
  color: var(--text);
  font-size: 1rem;
  line-height: 1.55;
}

.entry-date {
  font-family: var(--sans);
  font-size: 0.8125rem;
  color: var(--text-muted);
  display: block;
  margin-top: 0.375rem;
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------- about page */

.facts {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
  border-top: 1px solid var(--rule);
}
.facts li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--sans);
  font-size: 0.9375rem;
}
.facts dt, .facts .k {
  color: var(--text-muted);
  flex: 0 0 8rem;
}
.facts .v { flex: 1 1 12rem; }

/* Placeholders that must not ship unfilled. Deliberately loud. */
.todo {
  background: #fff3cd;
  color: #6b4e00;
  border-bottom: 2px solid var(--gold);
  padding: 0 0.2em;
  font-family: var(--sans);
  font-size: 0.9em;
}
@media (prefers-color-scheme: dark) {
  .todo { background: #4a3c12; color: #ffe9a8; }
}

/* ---------------------------------------------------------------- footer */

footer {
  border-top: 1px solid var(--rule);
  padding: 1.75rem 0 4rem;
  font-family: var(--sans);
  font-size: 0.8125rem;
  color: var(--text-muted);
}
footer p { margin: 0 0 0.375rem; }
footer a { color: var(--text-muted); }

/* ----------------------------------------------------------------- print */

@media print {
  :root { --bg: #fff; --text: #000; --text-muted: #333; --rule: #ccc; }
  .masthead nav, .skip { display: none; }
  body { font-size: 11pt; }
  a { text-decoration: none; }
  .entry-title::after { content: " (" attr(href) ")"; font-size: 9pt; font-weight: 400; }
}

/* Self-hosted Inter, if the woff2 files are ever added. Until then the stack above
   resolves to the visitor's platform sans and the page loads nothing external.

@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/Inter-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/Inter-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
*/
