/*
 * Styles shared by more than one page:
 *   <site-header> — assets/js/site-header.js  (tmux-style top session bar)
 *   <site-footer> — assets/js/site-footer.js  (connect/social links pane)
 *   .pillar / .dot / .article — plain markup patterns (no custom element),
 *     reused directly in each page's own HTML
 * The two custom elements' JS only sets innerHTML/behavior; the page markup
 * supplies the class attribute (e.g. class="sessionbar", class="pane
 * footer"), so the selectors below target plain class names, not the
 * custom element tag names.
 */

/* ---------- site-header (tmux-style session bar) ---------- */
.sessionbar {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0 10px;
  height: 34px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12px;
  flex-wrap: nowrap;
  overflow-x: auto;
}
.sname {
  color: var(--sky-ink);
  background: var(--sky);
  padding: 5px 10px;
  font-weight: 400;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.wtab {
  padding: 5px 10px;
  color: var(--olive); /* internal site nav — matches the connect pane's convention */
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.12s ease;
}
.wtab:hover, .wtab:focus-visible { color: var(--text); outline: none; }
.wtab.active { color: var(--text); background: var(--line-dim); }
/* page not built yet (e.g. blog) — not a link, reads as inactive */
.wtab.disabled { color: var(--muted-dim); cursor: default; }
.wtab.disabled:hover { color: var(--muted-dim); }
.sessionbar .fill { flex: 1; }
.version {
  padding: 5px 8px;
  font-size: 11px;
  color: var(--muted-dim);
  white-space: nowrap;
}

.theme-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  background: none; border: none; padding: 6px;
  margin-left: 2px; color: var(--muted-dim);
  cursor: pointer;
}
.theme-toggle:hover, .theme-toggle:focus-visible { color: var(--text); outline: none; }
.theme-toggle svg { width: 14px; height: 14px; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="light"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="light"] .theme-toggle .icon-moon { display: inline-flex; }

/* ---------- site-footer (connect pane) ---------- */
.clist { font-family: var(--mono); font-size: 12.5px; }
.clist a {
  display: flex; align-items: center; gap: 8px;
  color: var(--muted); padding: 7px 0;
  transition: color 0.12s ease;
}
.clist a:hover, .clist a:focus-visible { color: var(--signal); outline: none; }
.clist .key { color: var(--muted-dim); }
/* internal site navigation vs. external links that open elsewhere */
.clist .key.olive { color: var(--olive); }
.clist .key.rust { color: var(--rust); }
/* no destination yet (blog page unbuilt, social URLs not decided) */
.clist .disabled {
  display: flex; align-items: center; gap: 8px;
  color: var(--muted-dim); padding: 7px 0; cursor: default;
}
.clist .disabled .key { color: var(--muted-dim); }
.copyright {
  font-family: var(--mono); font-size: 11px;
  color: var(--muted-dim); margin: 10px 0 0;
}

/* ---------- labeled category + detail list (services, about) ---------- */
.pillar { padding: 10px 0; }
.pillar-head {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 13px; color: var(--text);
}
.dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.dot.gold { background: var(--gold); }
.dot.olive { background: var(--olive); }
.dot.rust { background: var(--rust); }
.pillar-detail {
  list-style: none; margin: 6px 0 0; padding: 0 0 0 17px;
  font-family: var(--mono); font-size: 12px; color: var(--muted);
}
.pillar-detail li { padding: 3px 0; }
.pillar-detail li::before { content: "- "; color: var(--muted-dim); }

/* ---------- simple article pages (about, contact) ---------- */
.article { max-width: 62ch; }
.article h1 {
  font-family: var(--display); font-weight: 900;
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  line-height: 1.08; letter-spacing: -0.01em;
  margin: 0 0 18px;
}
.article p {
  font-family: var(--mono); font-size: 13.5px; line-height: 1.7;
  color: var(--muted); margin: 0 0 16px;
}
.article p.signed { color: var(--text); }
.article .pillar:first-of-type { margin-top: 6px; }

/* long-form body content (blog posts) — headings/lists within an .article */
.article h2 {
  font-family: var(--display); font-weight: 900;
  font-size: 1.3rem; line-height: 1.2;
  color: var(--text);
  margin: 28px 0 12px;
}
.article ul, .article ol {
  font-family: var(--mono); font-size: 13.5px; line-height: 1.7;
  color: var(--muted); margin: 0 0 16px; padding-left: 20px;
}
.article li { padding: 2px 0; }
.article strong { color: var(--text); font-weight: 700; }
/* same bordered-panel language as .pane, for posts with real shell/code
   examples - .article code above still applies inside here too (inline
   code elsewhere), so reset its padding/background or they'd stack */
.article pre {
  font-family: var(--mono); font-size: 13px; line-height: 1.6;
  background: var(--panel); color: var(--text);
  border: 1px solid var(--line-dim);
  padding: 12px 14px; margin: 0 0 16px;
  overflow-x: auto;
}
.article pre code {
  background: none; padding: 0; border-radius: 0;
}
.article code {
  font-family: var(--mono); font-size: 0.92em;
  background: var(--line-dim); color: var(--text);
  padding: 1px 5px; border-radius: 3px;
}
/* in-content citation/source links (migrated from the live posts) - the
   global `a { color: inherit }` reset would make these invisible against
   body text otherwise */
/* :not()s exclude .btn-primary/.btn-secondary - without them this beats
   the buttons' own color rule on specificity, and --sky here is the exact
   same hex as --signal (the button's background), making button text
   invisible until :hover coincidentally overrides it back to --text */
.article a:not(.btn-primary):not(.btn-secondary) { color: var(--sky); text-decoration: underline; text-underline-offset: 2px; }
.article a:not(.btn-primary):not(.btn-secondary):hover,
.article a:not(.btn-primary):not(.btn-secondary):focus-visible { color: var(--text); outline: none; }

/* ---------- buttons ---------- */
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; }
.btn-primary, .btn-secondary {
  font-family: var(--mono); font-size: 13px; padding: 10px 16px;
  display: inline-flex; align-items: center; gap: 8px;
  transition: transform 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}
.btn-primary { background: var(--signal); color: var(--signal-ink); }
.btn-primary:hover, .btn-primary:focus-visible { transform: translateY(-1px); outline: none; }
.btn-secondary { border: 1px solid var(--line); color: var(--muted); }
.btn-secondary:hover, .btn-secondary:focus-visible { border-color: var(--muted-dim); color: var(--text); outline: none; }
