/* ─── Site header ────────────────────────────────────── */
.site-header {
  border-bottom: 1px solid var(--c-border);
  background-color: var(--c-bg);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header__inner {
  max-width: var(--max-site);
  margin: 0 auto;
  padding: var(--s-sm) var(--s-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-md);
}

.site-header__name {
  font-family: var(--f-ui);
  font-weight: 500;
  font-size: var(--t-base);
  color: var(--c-text);
  text-decoration: none;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.site-header__name:hover { color: var(--c-accent); }

/* ─── Navigation ─────────────────────────────────────── */
.site-nav {
  display: flex;
  gap: var(--s-md);
  align-items: center;
}

.site-nav__link {
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  font-weight: 500;
  color: var(--c-muted);
  text-decoration: none;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  transition: color var(--transition);
}
.site-nav__link:hover { color: var(--c-text); }
.site-nav__link[aria-current="page"] { color: var(--c-accent); }

/* ─── Main content ───────────────────────────────────── */
.main {
  max-width: var(--max-prose);
  margin: 0 auto;
  padding: var(--s-xl) var(--s-md);
}

.main--wide { max-width: var(--max-site); }

/* ─── Site footer ────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--c-border);
  margin-top: var(--s-2xl);
}

.site-footer__inner {
  max-width: var(--max-site);
  margin: 0 auto;
  padding: var(--s-lg) var(--s-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-md);
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  color: var(--c-muted);
}

.site-footer__links { display: flex; gap: var(--s-sm); }
.site-footer__links a { color: var(--c-muted); }
.site-footer__links a:hover { color: var(--c-text); }

/* ─── Post styles ────────────────────────────────────── */
.post-header {
  margin-bottom: var(--s-xl);
  padding-bottom: var(--s-lg);
  border-bottom: 1px solid var(--c-border);
}

.post-meta {
  font-size: var(--t-sm);
  margin-bottom: var(--s-sm);
  letter-spacing: 0.01em;
}

.post-body > * + * { margin-top: var(--s-sm); }
.post-body h2:first-child,
.post-body h3:first-child { margin-top: 0; }

/* ─── Post video grid ────────────────────────────────── */
.post-videos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-md);
  margin-top: var(--s-xl);
}
.post-video {
  display: flex;
  flex-direction: column;
}
.post-video video {
  width: 100%;
  aspect-ratio: 9/16;
  object-fit: cover;
  border-radius: 6px;
  background: #000;
  display: block;
}
.post-video figcaption {
  font-size: var(--t-sm);
  color: var(--c-muted);
  margin-top: var(--s-xs);
  text-align: center;
  font-family: var(--f-ui);
}
@media (max-width: 500px) {
  .post-videos { grid-template-columns: 1fr; }
}

/* ─── Home page hero ─────────────────────────────────── */
.hero {
  padding: var(--s-2xl) 0 var(--s-xl);
  border-bottom: 1px solid var(--c-border);
  margin-bottom: var(--s-xl);
}

.hero__eyebrow {
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--c-accent);
  margin-bottom: var(--s-sm);
}

.hero__title {
  font-size: var(--t-3xl);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: var(--s-md);
}

.hero__bio {
  font-size: var(--t-lg);
  color: var(--c-muted);
  max-width: 560px;
  line-height: var(--l-body);
}

/* ─── Post list (home + archive) ─────────────────────── */
.post-list { list-style: none; padding: 0; }

.post-list__item {
  padding: var(--s-md) 0;
  border-bottom: 1px solid var(--c-border);
}
.post-list__item:last-child { border-bottom: none; }

.post-list__meta {
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  color: var(--c-muted);
  margin-bottom: var(--s-xs);
  letter-spacing: 0.01em;
}

.post-list__title {
  font-size: var(--t-xl);
  font-weight: 600;
  line-height: var(--l-tight);
  letter-spacing: -0.01em;
  margin: 0;
}

.post-list__title a {
  color: var(--c-text);
  text-decoration: none;
}
.post-list__title a:hover { color: var(--c-accent); }

.post-list__excerpt {
  margin-top: var(--s-xs);
  color: var(--c-muted);
  font-size: var(--t-base);
}

/* ─── About page ─────────────────────────────────────── */
.about-portrait {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  filter: sepia(20%) saturate(80%);
}

.credential-list {
  list-style: none;
  padding: 0;
}
.credential-list li {
  padding: var(--s-xs) 0;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  justify-content: space-between;
  gap: var(--s-sm);
  font-size: var(--t-sm);
  font-family: var(--f-ui);
}
.credential-list li:last-child { border-bottom: none; }
.credential-list .label { color: var(--c-muted); font-weight: 500; white-space: nowrap; }

/* ─── Contact page ───────────────────────────────────── */
.contact-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: 6px;
  padding: var(--s-lg);
  margin-top: var(--s-lg);
  font-family: var(--f-ui);
  font-size: var(--t-sm);
}
.contact-card h2 { font-size: var(--t-lg); margin-top: 0; }
.contact-card p { margin-bottom: var(--s-sm); color: var(--c-muted); }
.contact-card a.email-link {
  font-size: var(--t-base);
  font-weight: 500;
  color: var(--c-accent);
}

/* ─── Section headings ───────────────────────────────── */
.section-heading {
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--c-muted);
  margin-bottom: var(--s-md);
}

/* ─── Category badge ─────────────────────────────────── */
.category-badge {
  display: inline-block;
  font-family: var(--f-ui);
  font-size: var(--t-sm);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--c-accent);
  text-decoration: none;
  padding: 2px 0;
  border-bottom: 1px solid var(--c-accent);
}

/* ─── Responsive ─────────────────────────────────────── */

/* Stack nav below name on narrow screens */
@media (max-width: 540px) {
  .site-header__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
    padding: var(--s-xs) var(--s-sm);
  }
  .site-nav {
    gap: var(--s-sm);
    flex-wrap: wrap;
  }
  .site-nav__link { font-size: 0.75rem; }
}

@media (max-width: 600px) {
  :root {
    /* Shrink type scale */
    --t-3xl: 1.75rem;
    --t-2xl: 1.4rem;
    --t-xl:  1.2rem;
    /* Shrink spacing — avoids excessive whitespace on small screens */
    --s-xl:  2rem;
    --s-2xl: 3rem;
    --s-lg:  1.75rem;
  }

  /* Tighter main content padding */
  .main { padding: var(--s-lg) var(--s-sm); }

  .hero { padding: var(--s-xl) 0 var(--s-lg); }
  .site-footer__inner { flex-direction: column; align-items: flex-start; gap: var(--s-sm); }

  /* Allow credential labels to wrap so they don't overflow */
  .credential-list .label { white-space: normal; }

  /* Smaller post list titles */
  .post-list__title { font-size: var(--t-lg); }
}

/* ─── Blip hub 3-up card grid ───────────────────────── */
.blip-hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-md);
  margin-bottom: var(--s-2xl);
}

@media (max-width: 600px) {
  .blip-hub-grid { grid-template-columns: 1fr; }
}
