/* jeffbeard.com layout and type. Colors come from theme.css, loaded before this one. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 700; font-display: swap; src: url(../fonts/Inter-latin.woff2) format("woff2"); }

:root {
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --measure: 68ch;
  --column: 260px;
  --gutter: 28px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  font-feature-settings: "cv11", "ss01";
}
a { color: var(--link); text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }
.prose a, .postfoot a, .about a { text-decoration-color: var(--faint); }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
code { font-family: var(--mono); font-size: 0.92em; background: var(--code-bg); padding: 1px 5px; border-radius: 4px; }
pre { background: var(--code-bg); padding: 14px 16px; border-radius: 6px; overflow-x: auto; }
pre code { background: none; padding: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Split layout (home, tag pages) ---------- */
.split { display: grid; grid-template-columns: var(--column) 1fr; min-height: 100vh; }
.identity {
  position: sticky; top: 0; align-self: start; height: 100vh; overflow: auto;
  padding: 40px var(--gutter);
  border-right: 1px solid var(--rule);
}
.identity .face { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin-bottom: 18px; }
.identity .name { font-size: 22px; font-weight: 650; letter-spacing: -0.02em; text-decoration: none; display: block; }
.identity .blurb { color: var(--muted); font-size: 15px; margin: 8px 0 22px; }
.identity nav ul { list-style: none; margin: 0; padding: 0; }
.identity nav li { margin: 0; }
.identity nav a { display: flex; justify-content: space-between; gap: 8px; padding: 5px 0; font-size: 15px; color: var(--muted); text-decoration: none; }
.identity nav a:hover { color: var(--ink); }
.identity nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }
.identity nav a .count { color: var(--faint); font-variant-numeric: tabular-nums; font-size: 13px; }
.identity .meta { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--rule); font-size: 14px; }
.identity .meta a { display: block; padding: 3px 0; color: var(--muted); text-decoration: none; }
.identity .meta a:hover { color: var(--ink); }

.feed { padding: 40px var(--gutter) 60px; max-width: 760px; }
.feed h1 { font-size: 15px; font-weight: 500; color: var(--muted); margin-bottom: 20px; }
.feed .year { font-size: 13px; letter-spacing: 0.08em; color: var(--faint); margin: 28px 0 6px; }
.feed .year:first-of-type { margin-top: 0; }
.entry {
  display: grid; grid-template-columns: 64px 1fr auto; gap: 16px; align-items: center;
  padding: 14px 0; border-top: 1px solid var(--rule);
}
.entry time { font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.entry .title { font-size: 17px; font-weight: 600; letter-spacing: -0.01em; text-decoration: none; }
.entry.note .title { font-weight: 450; }
.entry .desc { display: block; color: var(--muted); font-size: 15px; margin-top: 3px; }
.entry .tag { display: block; font-size: 13px; color: var(--faint); margin-top: 3px; }
.entry .thumb { width: 56px; height: 44px; border-radius: 4px; object-fit: cover; }

/* ---------- Slim bar layout (post, about, 404) ---------- */
.bar {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 14px var(--gutter); border-bottom: 1px solid var(--rule);
}
.bar .who { display: flex; align-items: center; gap: 10px; font-weight: 600; text-decoration: none; }
.bar .who img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; }
.bar nav a { margin-left: 18px; font-size: 15px; color: var(--muted); text-decoration: none; }
.bar nav a:hover { color: var(--ink); }

.theme-toggle { appearance: none; background: none; border: 1px solid var(--rule); border-radius: 999px; width: 28px; height: 28px; padding: 0; cursor: pointer; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; vertical-align: middle; }
.theme-toggle:hover { color: var(--ink); border-color: var(--faint); }
.theme-toggle__icon { width: 12px; height: 12px; border-radius: 50%; background: currentColor; box-shadow: inset -4px -3px 0 0 var(--bg); }
html[data-theme="dark"] .theme-toggle__icon { box-shadow: none; }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .theme-toggle__icon { box-shadow: none; } }
.bar nav .theme-toggle { margin-left: 18px; }
.identity .meta .theme-toggle { margin-bottom: 8px; }

.page { max-width: var(--measure); margin: 0 auto; padding: 44px var(--gutter) 80px; }
.kicker { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); text-decoration: none; }
.page h1 { font-size: 34px; margin: 10px 0 10px; }
.dateline { color: var(--faint); font-size: 14px; margin-bottom: 30px; }
.prose p { margin: 0 0 1.15em; }
.prose h2 { font-size: 22px; margin: 1.8em 0 0.6em; }
.prose h3 { font-size: 18px; margin: 1.5em 0 0.5em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: 0.35em; }
.prose blockquote { margin: 1.2em 0; padding-left: 16px; border-left: 3px solid var(--accent); color: var(--muted); }
.prose hr { border: 0; border-top: 1px solid var(--rule); margin: 2em 0; }
.prose img, .prose figure { margin: 1.6em 0; }
.prose figure { width: 120%; margin-left: -10%; }
.prose figure img { width: 100%; border-radius: 6px; }
.prose figcaption { font-size: 14px; color: var(--faint); margin-top: 8px; }
.prose > p > img:only-child { width: 120%; max-width: 120%; margin-left: -10%; border-radius: 6px; }
.postfoot { margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--rule); font-size: 15px; color: var(--muted); }
.postfoot .source { margin-bottom: 14px; }
.postfoot .nav { display: flex; justify-content: space-between; gap: 20px; }
.postfoot .nav a { text-decoration: none; max-width: 48%; }
.postfoot .nav span { display: block; font-size: 12px; color: var(--faint); letter-spacing: 0.08em; text-transform: uppercase; }

.about .face { width: 140px; height: 140px; border-radius: 50%; object-fit: cover; margin-bottom: 24px; }

.footer { padding: 20px var(--gutter); border-top: 1px solid var(--rule); font-size: 13px; color: var(--faint); }

/* ---------- Phone ---------- */
@media (max-width: 799px) {
  .split { display: block; }
  .identity {
    position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--rule);
    padding: 22px 16px;
    display: grid; grid-template-columns: 48px 1fr; column-gap: 14px; align-items: center;
  }
  .identity .face { width: 48px; height: 48px; margin: 0; grid-row: 1 / 3; }
  .identity .name { font-size: 18px; }
  .identity .blurb { margin: 2px 0 0; font-size: 14px; }
  .identity nav { grid-column: 1 / -1; margin-top: 14px; }
  .identity nav ul { display: flex; flex-wrap: wrap; gap: 6px; }
  .identity nav a { padding: 4px 10px; border: 1px solid var(--rule); border-radius: 999px; font-size: 13px; }
  .identity nav a .count { display: none; }
  .identity .meta { grid-column: 1 / -1; margin-top: 12px; padding-top: 10px; display: flex; flex-wrap: wrap; gap: 4px 14px; }
  .feed { padding: 20px 16px 40px; }
  .entry { grid-template-columns: 52px 1fr auto; gap: 10px; }
  .entry .thumb { width: 44px; height: 36px; }
  .bar { padding: 12px 16px; }
  .bar nav a { margin-left: 12px; font-size: 14px; }
  .bar nav .theme-toggle { margin-left: 12px; }
  .page { padding: 28px 16px 60px; }
  .page h1 { font-size: 28px; }
  .prose figure, .prose > p > img:only-child { width: 100%; max-width: 100%; margin-left: 0; }
  .footer { padding: 16px; }
}
