/* ──────────────────────────────────────────────────────────
   Vist · blog (loads after site.css)
   Index: a ruled contents page. Post: a reading column on paper.
   ────────────────────────────────────────────────────────── */

/* tags: plain outlined labels, no colour coding */
.tag-chip {
  display: inline-flex; align-items: center;
  font-family: var(--sans); font-size: 13px; font-weight: 700;
  padding: 2px 10px; border: 1px solid var(--ink); border-radius: 999px;
  color: var(--ink); background: transparent; white-space: nowrap;
}
.tag-chip .dot { display: none; }

/* ── index header ──────────────────────────────────── */
.blog-header { padding: clamp(40px, 6vw, 88px) 0 clamp(32px, 4vw, 56px); border-bottom: 1.5px solid var(--ink); }
.blog-header-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 32px; align-items: end; }
.blog-header h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); line-height: 1; letter-spacing: -0.03em; max-width: 14em; }
.blog-header .sub { margin-top: 18px; font-size: 20px; color: var(--ink-2); max-width: 34em; }
.blog-header-meta { font-family: var(--sans); font-size: 15px; color: var(--ink-3); text-align: right; }
.blog-header-meta .num { display: block; font-family: var(--serif); font-size: 56px; line-height: 1; color: var(--ink); letter-spacing: -0.03em; }

/* ── featured post ─────────────────────────────────── */
.featured { padding: clamp(36px, 5vw, 64px) 0 0; }
.featured .feat-label { display: none; }
.featured-card {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  border: 1.5px solid var(--ink); background: var(--paper-2);
  text-decoration: none; color: inherit;
  transition: box-shadow .2s var(--ease-out), transform .2s var(--ease-out);
}
.featured-card:hover { box-shadow: 0 12px 18px -12px rgba(22,23,26,.4); transform: translateY(-2px); }
.feat-hero {
  background: var(--mark); color: var(--ink);
  padding: clamp(28px, 4vw, 48px);
  display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
  border-right: 1.5px solid var(--ink);
}
.feat-hero .feat-quote { font-family: var(--serif); font-weight: 500; font-size: clamp(2.4rem, 5vw, 4.2rem); line-height: 1; letter-spacing: -0.03em; }
.feat-hero .feat-foot { font-family: var(--sans); font-size: 14px; display: flex; gap: 6px; flex-wrap: wrap; }
.feat-hero .feat-foot .wm { font-weight: 700; }
.feat-body { padding: clamp(24px, 3.5vw, 44px); display: flex; flex-direction: column; justify-content: space-between; gap: 28px; }
.feat-meta { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; font-family: var(--sans); font-size: 14px; color: var(--ink-3); }
.feat-body h2 { font-size: clamp(1.7rem, 2.8vw, 2.4rem); line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 14px; }
.feat-body .dek { color: var(--ink-2); font-size: 18px; }
.byline { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-family: var(--sans); font-size: 14px; color: var(--ink-3); }
.byline .author { color: var(--ink); font-weight: 700; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center;
  background: var(--ink); color: var(--mark); font-family: var(--sans); font-size: 12px; font-weight: 700;
}
.feat-body .read-link { display: inline-block; margin-top: 16px; font-family: var(--sans); font-size: 15px; font-weight: 700; text-decoration: underline; text-decoration-color: var(--mark); text-decoration-thickness: 4px; text-underline-offset: 4px; }

/* ── filters ───────────────────────────────────────── */
.filter-row { margin-top: clamp(36px, 5vw, 56px); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); background: var(--paper); position: sticky; top: 64px; z-index: 5; }
.filter-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 60px; }
.filter-chips { display: flex; gap: 6px; overflow-x: auto; padding: 10px 0; scrollbar-width: none; }
.chip {
  font-family: var(--sans); font-size: 14px; font-weight: 700;
  border: 1px solid var(--rule); background: transparent; color: var(--ink-2);
  border-radius: 999px; padding: 6px 12px; cursor: pointer; white-space: nowrap;
  display: inline-flex; gap: 6px; align-items: center;
}
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.active { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .count { font-weight: 400; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chip.active .count { color: var(--mark); }
.sort { font-family: var(--sans); font-size: 14px; color: var(--ink-3); white-space: nowrap; }

/* ── post list: a ruled contents page ─────────────── */
.grid-section { padding: 0 0 var(--section-y); }
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-left: 1px solid var(--rule); }
.post-card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 28px 28px 32px; min-height: 260px;
  border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
  text-decoration: none; color: inherit; transition: background .18s var(--ease-out);
}
.post-card:hover { background: var(--paper-2); }
.post-card h3 { font-size: 1.45rem; line-height: 1.18; letter-spacing: -0.015em; }
.post-card:hover h3 { text-decoration: underline; text-decoration-color: var(--mark); text-decoration-thickness: .18em; text-underline-offset: .1em; }
.post-card .dek { font-size: 16.5px; color: var(--ink-2); line-height: 1.55; flex: 1; }
.post-card .pc-foot { display: flex; flex-wrap: wrap; gap: 6px; font-family: var(--sans); font-size: 13.5px; color: var(--ink-3); }
.post-card .pc-foot .author { color: var(--ink); font-weight: 700; }
.post-card .pc-arrow { position: absolute; top: 28px; right: 24px; color: var(--ink-3); transition: transform .2s var(--ease-out), color .2s; }
.post-card:hover .pc-arrow { color: var(--ink); transform: translate(2px, -2px); }

/* ── RSS ───────────────────────────────────────────── */
.archive { padding: var(--section-y) 0; background: var(--ink); color: var(--paper); }
.archive h2 { font-size: clamp(2.2rem, 5vw, 4rem); line-height: 1.02; letter-spacing: -0.03em; }
.archive p { margin-top: 16px; font-size: 19px; color: #b9bcc2; max-width: 32em; }
.archive .rss-pill {
  margin-top: 28px; display: inline-flex; gap: 10px; align-items: center;
  font-family: var(--sans); font-size: 16px; font-weight: 700; text-decoration: none;
  background: var(--mark); color: var(--ink); border: 1.5px solid var(--mark);
  border-radius: 6px; min-height: 48px; padding: 12px 22px;
}
.archive .rss-pill:hover { background: transparent; color: var(--mark); }

/* ── related ───────────────────────────────────────── */
.related { padding: var(--section-y) 0; border-top: 1.5px solid var(--ink); background: var(--paper-2); }
.related h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); line-height: 1.05; letter-spacing: -0.025em; margin-bottom: 32px; }
.related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1.5px solid var(--ink); background: var(--paper-2); }
.rel-card { display: flex; flex-direction: column; gap: 12px; padding: 24px; text-decoration: none; color: inherit; }
.rel-card + .rel-card { border-left: 1px solid var(--rule); }
.rel-card:hover { background: var(--paper); }
.rel-card h4 { font-family: var(--serif); font-weight: 500; font-size: 1.3rem; line-height: 1.2; margin: 0; }
.rel-card .dek { font-size: 16px; color: var(--ink-2); flex: 1; }
.rel-card .rel-foot { font-family: var(--sans); font-size: 13.5px; color: var(--ink-3); }

@media (max-width: 1020px) {
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .featured-card { grid-template-columns: 1fr; }
  .feat-hero { border-right: 0; border-bottom: 1.5px solid var(--ink); }
}
@media (max-width: 760px) {
  .blog-header-row { grid-template-columns: 1fr; }
  .blog-header-meta { text-align: left; }
  .post-grid { grid-template-columns: 1fr; border-left: 0; }
  .post-card { border-right: 0; min-height: 0; padding: 24px 0 28px; }
  .post-card .pc-arrow { right: 0; top: 24px; }
  .related-grid { grid-template-columns: 1fr; }
  .rel-card + .rel-card { border-left: 0; border-top: 1px solid var(--rule); }
  .sort { display: none; }
}
