/* Jim's.one — one stylesheet. No framework, no animations, no tracking.
   Deliberately plain: white page, black text, blue underlined links, and
   nothing else. The only images are the wordmark in the header and anything Jim
   pastes into a post. The only thing borrowed from 100ish besides the layout is
   the hand-drawn dashes between sections, kept because they are the one bit of
   furniture that helps a page of text stay readable. */

:root {
  --paper:     #ffffff;   /* plain white */
  --paper-2:   #f2f2f2;   /* code blocks, quiet fills */
  --text:      #000000;   /* black — 21:1 on white */
  --muted:     #595959;   /* 7.0:1 on white */
  --link:      #0000ee;   /* the standard link blue */
  --link-vis:  #551a8b;   /* the standard visited purple */
  --rule:      #cccccc;   /* hairline */
  --measure:   38rem;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 1.75rem 1.25rem 4rem;
}

/* Standard web links: blue, underlined, everywhere. Hover only thickens the
   rule rather than switching it on, so nothing moves under the pointer. */
a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.15em;
}
a:visited { color: var(--link-vis); }
a:hover, a:focus { text-decoration-thickness: 0.18em; }

/* Buttons are not prose — an underline under one reads as clutter. */
a.button, header.site .brand, ol.archive a.pager-jump { text-decoration: none; }

/* --- header ------------------------------------------------------------- */

header.site {
  border-bottom: 1px dashed var(--rule);
  margin-bottom: 2.25rem;
  padding-bottom: 1rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.5rem 1.25rem;
}

/* The wordmark is Jim's brush artwork on a transparent background, so it sits
   straight on the white page. Sized by height; the width follows the artwork's
   own 468x260 ratio (the intrinsic size is also on the <img> so nothing shifts
   while it loads). */
header.site .brand {
  display: block;
  flex: 0 0 auto;
  line-height: 0;              /* no descender gap under the image */
}
header.site .brand img { display: block; height: 3.6rem; width: auto; }

header.site nav {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: flex-end;
  gap: 0.35rem 1rem;
  font-size: 1rem;
}

/* --- post list ---------------------------------------------------------- */

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

ol.posts > li {
  padding: 0 0 1.75rem;
  margin: 0 0 1.75rem;
  border-bottom: 1px dashed var(--rule);
}
ol.posts > li:last-child { border-bottom: 0; }

/* The front page carries whole posts, so they need more air between them and
   a title that reads as a title, not as a list row. */
ol.posts.latest > li {
  padding-bottom: 3rem;
  margin-bottom: 3rem;
}
ol.posts.latest h2.post-title {
  font-size: 1.55rem;
  margin-bottom: 0.35rem;
}
ol.posts.latest .post-body p:last-child { margin-bottom: 0.6rem; }

ol.posts h2 {
  font-size: 1.3rem;
  line-height: 1.3;
  margin: 0 0 0.3rem;
  letter-spacing: -0.01em;
}
ol.posts h2 a { color: var(--text); text-decoration: none; }
ol.posts h2 a:hover { color: var(--link); text-decoration: underline; }

.post-meta {
  color: var(--muted);
  font-size: 0.87rem;
  margin: 0 0 0.5rem;
}

p.excerpt { margin: 0 0 0.6rem; }
p.more { margin: 0; font-size: 0.95rem; }

/* --- article ------------------------------------------------------------ */

article h1 {
  font-size: 1.85rem;
  line-height: 1.22;
  letter-spacing: -0.02em;
  margin: 0 0 0.4rem;
}

article h2 { font-size: 1.3rem; margin: 2rem 0 0.5rem; }
article h3 { font-size: 1.1rem; margin: 1.6rem 0 0.4rem; }

article p, article li { margin: 0 0 1.1rem; }
article ul, article ol { padding-left: 1.35rem; }
article ul li, article ol li { margin-bottom: 0.4rem; }

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

article code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--paper-2);
  padding: 0.1em 0.3em;
  border-radius: 3px;
}

article pre {
  background: var(--paper-2);
  padding: 0.9rem 1rem;
  overflow-x: auto;
  border-radius: 4px;
}
article pre code { background: none; padding: 0; }

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

article hr { border: 0; border-top: 1px dashed var(--rule); margin: 2rem 0; }

/* --- pager -------------------------------------------------------------- */

.pager {
  margin: 2rem 0 0;
  padding-top: 1rem;
  border-top: 1px dashed var(--rule);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.95rem;
}
.pager .next { text-align: right; margin-left: auto; }

/* --- support + footer --------------------------------------------------- */

.support {
  margin: 2.5rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
}

footer.site {
  margin-top: 3.5rem;
  padding-top: 1.25rem;
  border-top: 1px dashed var(--rule);
  font-size: 0.87rem;
  color: var(--muted);
}
footer.site p { margin: 0 0 0.5rem; }
footer.site a { color: var(--link); }
footer.site .ish-mark { letter-spacing: 0.02em; }

.feed {
  font-size: 0.95rem;
}

/* --- search ------------------------------------------------------------- */

/* The form is a plain GET form: no JavaScript, and the query ends up in the URL
   so a result page can be linked or reloaded. The buttons are drawn here rather
   than left to platform.css, whose filled blue button is the dashboard's. */
form.search, form.search-mini {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
}

form.search input[type=search], form.search-mini input[type=search] {
  font: inherit;
  font-size: 0.95rem;
  padding: 0.22rem 0.4rem;
  border: 1px solid var(--rule);
  border-radius: 0;
  background: var(--paper);
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}
form.search-mini input[type=search] { width: 8rem; }
form.search input[type=search] { width: 18rem; max-width: 100%; }

form.search button, form.search-mini button {
  font: inherit;
  font-size: 0.95rem;
  padding: 0.22rem 0.6rem;
  border: 1px solid var(--rule);
  border-radius: 0;
  background: var(--paper-2);
  color: var(--link);
  cursor: pointer;
}
form.search button:hover, form.search-mini button:hover { background: #e6e6e6; }

form.search { margin: 0 0 2rem; }

ol.search-results { list-style: none; margin: 0; padding: 0; }
ol.search-results > li {
  margin: 0 0 1.5rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px dashed var(--rule);
}
ol.search-results > li:last-child { border-bottom: 0; padding-bottom: 0; }
a.result-title { font-size: 1.05rem; }
.result-date { color: var(--muted); font-size: 0.85rem; margin-left: 0.6rem; }
p.search-excerpt { margin: 0.4rem 0 0; }

/* --- archive ------------------------------------------------------------ */

h2.archive-year {
  font-size: 1.05rem;
  color: var(--muted);
  letter-spacing: 0.02em;
  margin: 2.25rem 0 0.7rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px dashed var(--rule);
}

ol.archive { list-style: none; margin: 0; padding: 0; }
ol.archive > li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.6rem;
  margin: 0 0 0.55rem;
}
ol.archive .archive-date {
  color: var(--muted);
  font-size: 0.85rem;
  white-space: nowrap;
  min-width: 8.5rem;
}

/* --- phone -------------------------------------------------------------- */

@media (max-width: 480px) {
  body { font-size: 17px; }
  .wrap { padding: 1.25rem 1rem 3rem; }
  article h1 { font-size: 1.6rem; }
  ol.posts h2 { font-size: 1.2rem; }
  header.site { align-items: flex-start; }
  header.site .brand img { height: 3rem; }
  header.site nav { justify-content: flex-start; margin-top: 0.35rem; }
  form.search-mini input[type=search] { width: 7rem; }
  form.search input[type=search] { width: 100%; }
  .pager { display: block; }
  .pager .next { text-align: left; margin-left: 0; margin-top: 0.4rem; }
  ol.archive > li { display: block; }
  ol.archive .archive-date { display: block; min-width: 0; }
}
