/* ctrlaltbrian.com — static, no build, no framework */

* { box-sizing: border-box; }

:root {
  --ink: #1a1a1a;
  --ink-soft: #4a4a4a;
  --ink-mute: #7a7a7a;
  --paper: #fdfdfb;
  --rule: #e5e3dd;
  --accent: #2a6f4d;
  --accent-soft: #e8f1ec;
  --code-bg: #f5f3ed;
  --maxw: 720px;
  --maxw-wide: 960px;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", "Helvetica Neue", Arial, sans-serif;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: #1d4d35; }

p, ul, ol, pre, blockquote { margin: 0 0 1.2em 0; }
ul, ol { padding-left: 1.4em; }
li { margin-bottom: 0.4em; }

h1, h2, h3, h4 { line-height: 1.25; color: var(--ink); margin: 1.6em 0 0.6em 0; font-weight: 700; }
h1 { font-size: 2.1rem; margin-top: 0.4em; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.2rem; }
h4 { font-size: 1.05rem; }

blockquote {
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  margin: 1.5em 0;
  padding: 0.6em 1.1em;
  color: var(--ink-soft);
  font-style: italic;
}

code {
  font-family: "SF Mono", "Menlo", "Consolas", "Liberation Mono", monospace;
  font-size: 0.92em;
  background: var(--code-bg);
  padding: 0.12em 0.38em;
  border-radius: 3px;
}

pre {
  background: var(--code-bg);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1em 1.1em;
  overflow-x: auto;
  font-size: 0.88em;
  line-height: 1.5;
}

pre code { background: none; padding: 0; }

hr { border: 0; border-top: 1px solid var(--rule); margin: 2.4em 0; }

/* layout */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 1.2rem; }
.wrap-wide { max-width: var(--maxw-wide); margin: 0 auto; padding: 0 1.2rem; }

/* header */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
  padding: 1.4rem 0;
  margin-bottom: 2.4rem;
}
.site-header .wrap-wide { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.site-title { font-size: 1.25rem; font-weight: 700; color: var(--ink); text-decoration: none; }
.site-title:hover { color: var(--accent); }
.site-tagline { color: var(--ink-mute); font-size: 0.92rem; margin: 0; }

.site-nav { display: flex; gap: 1.2rem; flex-wrap: wrap; font-size: 0.95rem; }
.site-nav a { color: var(--ink-soft); text-decoration: none; }
.site-nav a:hover { color: var(--accent); }

/* footer */
.site-footer {
  border-top: 1px solid var(--rule);
  margin-top: 5rem;
  padding: 2rem 0;
  color: var(--ink-mute);
  font-size: 0.88rem;
}
.site-footer a { color: var(--ink-soft); }

/* post list (home) */
.post-list { list-style: none; padding: 0; }
.post-list li { border-bottom: 1px solid var(--rule); padding: 1.4rem 0; margin: 0; }
.post-list li:last-child { border-bottom: 0; }
.post-list a { color: var(--ink); text-decoration: none; display: block; }
.post-list a:hover h2 { color: var(--accent); }
.post-list h2 { margin: 0 0 0.4em 0; font-size: 1.35rem; }
.post-list .meta { color: var(--ink-mute); font-size: 0.85rem; }
.post-list .excerpt { color: var(--ink-soft); margin: 0.5em 0 0 0; font-size: 0.97rem; }

/* single post */
.post-header { margin-bottom: 2.4rem; }
.post-header .meta { color: var(--ink-mute); font-size: 0.88rem; }
.post-header h1 { margin: 0.3em 0 0.5em 0; }
.post-header .category { display: inline-block; background: var(--accent-soft); color: var(--accent); font-size: 0.78rem; padding: 0.18em 0.7em; border-radius: 3px; text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }

/* CTA box (Gumroad pitch, appears inline in posts and on /shop) */
.cta-box {
  border: 1px solid var(--accent);
  background: var(--accent-soft);
  border-radius: 6px;
  padding: 1.2em 1.4em;
  margin: 2em 0;
}
.cta-box h3 { margin: 0 0 0.4em 0; color: var(--accent); }
.cta-box p:last-child { margin-bottom: 0; }
.cta-box .btn {
  display: inline-block;
  background: var(--accent);
  color: white;
  padding: 0.55em 1.2em;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  margin-top: 0.6em;
}
.cta-box .btn:hover { background: #1d4d35; color: white; }

/* prose helpers */
.lede { font-size: 1.12rem; color: var(--ink-soft); margin-bottom: 1.6em; }
.signoff { margin-top: 2.4em; color: var(--ink-mute); font-style: italic; }

/* tag links (in post meta and on tag pages) */
.tag-link { color: var(--accent); text-decoration: none; font-size: 0.92em; }
.tag-link:hover { text-decoration: underline; }

.tag-cloud { line-height: 2.2; }
.tag-cloud a { display: inline-block; margin-right: 0.8em; }

/* search */
input[type="search"] { font-family: inherit; }
input[type="search"]:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

/* 404 */
main ul li { font-size: 1.05rem; }

/* responsive */
@media (max-width: 600px) {
  body { font-size: 17px; }
  h1 { font-size: 1.7rem; }
  .site-header .wrap-wide { flex-direction: column; align-items: flex-start; }
}
