/* ---------- Bylines ---------- */
.byline__author { color: inherit; text-decoration: none; font-weight: 600; }
.byline__author:hover { text-decoration: underline; }

/* ---------- Avatars ---------- */
.avatar {
  display: inline-block;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  object-fit: cover;
  background: var(--line);
  flex-shrink: 0;
}
.avatar--lg { width: 4rem; height: 4rem; }
.avatar--xl { width: 6.5rem; height: 6.5rem; }
.avatar--blank { background: linear-gradient(135deg, var(--line), var(--surface)); }

/* ---------- Post page: byline row ---------- */
.post__meta { display: flex; align-items: center; gap: 0.75rem; line-height: 1.45; }
.post__avatars { display: inline-flex; }
.post__avatars a + a { margin-left: -0.6rem; }          /* overlap for co-authors */
.post__avatars .avatar { border: 2px solid var(--bg); }

/* ---------- Post page: about the author(s) ---------- */
.author-box {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 1.5rem;
}
.author-box__item { display: flex; gap: 1rem; align-items: flex-start; }
.author-box__name { font-size: 1.1rem; margin: 0 0 0.25rem; }
.author-box__name a { color: inherit; text-decoration: none; }
.author-box__name a:hover { text-decoration: underline; }
.author-box__bio { margin: 0 0 0.4rem; color: var(--subtle); font-size: 0.95rem; }
.author-box__more { font-size: 0.85rem; font-weight: 600; color: var(--accent); text-decoration: none; }
.author-box__more:hover { text-decoration: underline; }

/* ---------- Author page ---------- */
.author-template .site-grid,
.page-authors .site-grid { grid-template-columns: minmax(0, 1fr); max-width: 1200px; }

.author-cover { width: 100%; max-height: 280px; object-fit: cover; display: block; margin-bottom: -3rem; }
.author-header {
  display: flex;
  gap: 1.5rem;
  align-items: flex-end;
  padding-bottom: 1.5rem;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.author-cover + .author-header { padding-left: 1.5rem; }
.author-cover + .author-header .avatar { border: 4px solid var(--bg); }
.author-header__name { font-size: 2.4rem; line-height: 1.1; margin: 0 0 0.4rem; }
.author-header__bio { margin: 0 0 0.6rem; color: var(--subtle); max-width: 60ch; }
.author-header__links { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; list-style: none; padding: 0; margin: 0; font-size: 0.85rem; color: var(--muted); }
.author-header__links a { color: var(--accent); text-decoration: none; font-weight: 600; }
.author-header__links a:hover { text-decoration: underline; }
@media (max-width: 560px) {
  .author-header { flex-direction: column; align-items: flex-start; }
  .author-header__name { font-size: 1.9rem; }
}

/* ---------- Writers page (/authors/) ---------- */
.writers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.writer-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.4rem;
  padding: 1.5rem 1rem;
  border: 1px solid var(--line);
  color: inherit;
  text-decoration: none;
}
.writer-card:hover { background: var(--surface); }
.writer-card .avatar { margin-bottom: 0.4rem; }
.writer-card__name { font-weight: 700; font-size: 1.1rem; font-family: var(--gh-font-heading, system-ui, sans-serif); }
.writer-card__bio { font-size: 0.9rem; color: var(--subtle);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.writer-card__count { font-size: 0.75rem; color: var(--muted); margin-top: auto; padding-top: 0.4rem; }
.post__meta .byline__author { color: var(--text); }
