/* ---------- News · article detail ----------
   The article's own sheet, loaded by single.php through the `z2-post` handle. Every rule below
   starts with a class that template or its related block prints, so the site's shared type, bands
   and grids are only ever narrowed on an article and never restyled from here.

   The page is one column: the opening band, the picture, the body and the related block share the
   same 1000px edge, because an image running edge to edge over a paragraph that does not is two
   layouts in one page. `.page-body` caps itself at 74ch for a page of plain text; an article holds
   a picture and a three-card grid, so that cap is lifted and the measure moves to the body, where
   a reader actually holds a line. */

.post-single { max-width: none; }

.post-article,
.post-related { max-width: 1000px; margin-inline: auto; }

/* ---------- the trail ---------- */
/* The engine prints the trail and the site styles it globally; here only its distance from the
   band, its size and a quiet hover are set, inside this page's own wrapper. */
.post-trail { margin: 0 0 clamp(14px, 1.6vw, 22px); color: var(--color-muted); }
.post-trail ol,
.post-trail ul { margin: 0; font-size: 13px; }
.post-trail .zeroy-breadcrumbs ol { opacity: 1; }
.post-trail a {
  color: var(--color-ink-soft); text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .22s ease, border-color .22s ease;
}
.post-trail a:hover { color: var(--color-ink); border-bottom-color: var(--color-brand); }

/* ---------- the opening band ---------- */
/* Cream, rounded, as wide as the column: the one warm note above the picture, holding nothing but
   the label, the date, the headline and one line of introduction. */
.post-head {
  margin: 0 0 clamp(24px, 2.8vw, 38px);
  padding: clamp(26px, 3.2vw, 46px) clamp(22px, 3.4vw, 52px);
  background: #fbf7f1;
  border-radius: var(--radius-card);
}
.post-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 9px;
  margin: 0 0 clamp(12px, 1.4vw, 18px);
  font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--color-muted);
}
.post-meta__cat {
  color: var(--color-brand-ink); font-weight: 600; text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .22s ease, border-color .22s ease;
}
.post-meta__cat:hover { color: var(--color-ink); border-bottom-color: currentColor; }
.post-meta__sep { color: var(--color-brand); }
.post-head__title {
  margin: 0;
  font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(2rem, 3.2vw, 2.9rem);
  line-height: 1.12; letter-spacing: -.012em;
  color: var(--color-ink);
}
.post-head__intro {
  margin: clamp(14px, 1.7vw, 22px) 0 0; max-width: 62ch;
  font-size: clamp(15.5px, 1.15vw, 17px); line-height: 1.62;
  color: var(--color-ink-soft);
}

/* ---------- the featured picture ---------- */
/* The file's own proportions: no aspect ratio, no crop, no stretch. The frame is only a rounded
   mask over the card ground, so a transparent file still reads as a picture and a missing one as
   an empty frame. */
.post-feature {
  margin: 0 0 clamp(26px, 3vw, 42px);
  border-radius: 16px; overflow: hidden;
  background: #f3e8dc;
}
.post-feature__img { display: block; width: 100%; height: auto; }

/* ---------- the body ----------
   WordPress's own block markup, styled once and only here. The site's global `p { max-width: 68ch }`
   does not reach inside this wrapper: the article's measure is its own 72ch, which is the whole
   point of scoping every rule to `.post-content`. */
.post-content { max-width: 72ch; font-size: 16px; line-height: 1.68; color: var(--color-ink); }
.post-content p { max-width: 72ch; margin: 0 0 1.15em; font-size: 16px; line-height: 1.68; }
.post-content h2,
.post-content h3,
.post-content h4 { font-family: var(--font-display); font-weight: 600; letter-spacing: -.02em; color: var(--color-ink); }
.post-content h2 { margin: 1.9em 0 .5em; font-size: clamp(1.35rem, 2vw, 1.7rem); line-height: 1.2; }
.post-content h3 { margin: 1.6em 0 .45em; font-size: clamp(1.15rem, 1.5vw, 1.3rem); line-height: 1.25; }
.post-content h4 { margin: 1.4em 0 .4em; font-size: 1.05rem; line-height: 1.3; }
.post-content h2:first-child,
.post-content h3:first-child,
.post-content h4:first-child { margin-top: 0; }
.post-content strong { font-weight: 600; }
.post-content a {
  color: var(--color-brand-ink); text-decoration: underline;
  text-decoration-thickness: 1px; text-underline-offset: 2px;
  transition: color .2s ease;
}
.post-content a:hover { color: var(--color-ink); }
.post-content ul,
.post-content ol { margin: 0 0 1.15em; padding-left: 1.3em; }
.post-content li { margin: 0 0 .45em; }
.post-content li::marker { color: var(--color-brand); }
.post-content ul ul,
.post-content ol ol,
.post-content ul ol,
.post-content ol ul { margin: .45em 0 0; }
.post-content blockquote {
  margin: 1.7em 0;
  padding: 2px 0 2px clamp(16px, 2vw, 24px);
  border-left: 3px solid var(--color-brand);
}
.post-content blockquote p {
  max-width: none;
  font-family: var(--font-serif);
  font-size: clamp(1.1rem, 1.5vw, 1.3rem); line-height: 1.5;
}
.post-content blockquote cite {
  display: block; margin-top: .7em;
  font-family: var(--font-body); font-style: normal;
  font-size: 13px; line-height: 1.5; color: var(--color-muted);
}
.post-content img { display: block; max-width: 100%; height: auto; border-radius: 12px; }
.post-content figure { margin: 1.8em 0; }
.post-content figure img { width: auto; }
.post-content figcaption,
.post-content .wp-caption-text {
  margin-top: .7em; font-size: 13.5px; line-height: 1.5; color: var(--color-muted);
}
.post-content table {
  width: 100%; margin: 0 0 1.5em;
  border-collapse: collapse; font-size: 15px; line-height: 1.5;
}
.post-content th,
.post-content td {
  padding: 10px 12px; text-align: left; vertical-align: top;
  border-bottom: 1px solid var(--color-line);
}
.post-content th { font-weight: 600; color: var(--color-ink); }
.post-content thead th { border-bottom-color: rgba(67, 54, 44, .22); }

/* ---------- a protected article ---------- */
/* WordPress's own password form on the site's cream card, and nothing of the article behind it.
   The submit control borrows the dark pill the site's buttons already use. */
.post-locked { max-width: 46ch; margin: 0 0 clamp(40px, 5vw, 64px); }
.post-locked form {
  margin: 0;
  padding: clamp(22px, 3vw, 34px);
  background: #fbf7f1;
  border-radius: var(--radius-card);
}
.post-locked p { max-width: none; margin: 0 0 14px; font-size: 15px; line-height: 1.6; color: var(--color-ink-soft); }
.post-locked label { display: block; margin: 0 0 12px; font-size: 14px; color: var(--color-ink-soft); }
.post-locked input[type="password"] {
  display: block; width: 100%; margin-top: 8px; padding: 11px 14px;
  background: #fff; color: var(--color-ink);
  border: 1px solid var(--color-line); border-radius: 10px;
  font-family: var(--font-body); font-size: 15px;
}
.post-locked input[type="submit"] {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 22px;
  background: var(--color-ink); color: #fff;
  border: 1px solid var(--color-ink); border-radius: var(--radius-control);
  font-family: var(--font-body); font-size: 14px; font-weight: 700;
  cursor: pointer;
  transition: background-color .22s ease, border-color .22s ease;
}
.post-locked input[type="submit"]:hover { background: #33291f; border-color: #33291f; }

/* ---------- related articles ---------- */
/* A hairline parts this block from the article, the same way the site parts its sections. Three
   cards across the 1000px column land near the 360px the block's `sizes` attribute promises, so
   the browser picks the file it should instead of guessing. The frame is a fixed 3:2 mask on the
   card ground: a record with no picture keeps the shape and shows no broken image. */
.post-related {
  margin-top: clamp(40px, 4vw, 60px);
  padding-top: clamp(28px, 3vw, 44px);
  border-top: 1px solid var(--color-line);
}
.post-related h2 {
  margin: 0 0 clamp(20px, 2.4vw, 30px);
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(1.35rem, 2.1vw, 1.75rem);
  line-height: 1.15; letter-spacing: -.02em;
}
.post-related__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 2.2vw, 30px);
}
.post-related__card { display: flex; flex-direction: column; }
.post-related__media {
  display: block; aspect-ratio: 3 / 2;
  border-radius: 14px; overflow: hidden;
  background: #f3e8dc;
}
.post-related__img {
  display: block; width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .26s ease;
}
.post-related__card:hover .post-related__img { transform: scale(1.03); }
.post-related__text {
  display: flex; flex: 1; flex-direction: column; gap: 8px;
  padding-top: 14px;
}
.post-related__meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 7px;
  margin: 0;
  font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--color-muted);
}
.post-related__sep { color: var(--color-brand); }
.post-related__cat { color: var(--color-brand-ink); font-weight: 600; }
.post-related__title {
  margin: 0;
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(1.02rem, 1.25vw, 1.15rem);
  line-height: 1.28; letter-spacing: -.01em;
}
.post-related__title a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--color-ink); text-decoration: none;
  transition: color .2s ease;
}
.post-related__title a:hover { color: var(--color-brand-ink); }
.post-related__more {
  display: inline-flex; align-items: center; gap: 8px;
  margin-top: auto; padding-top: 6px;
  font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--color-brand-ink); text-decoration: none;
  transition: color .22s ease;
}
.post-related__more .btn-arrow { transition: transform .22s ease; }
.post-related__more:hover { color: var(--color-ink); }
.post-related__more:hover .btn-arrow { transform: translateX(3px); }

/* ---------- narrower windows ---------- */
/* Two cards, then one. The band loses padding before it loses its radius, so a phone still reads
   it as a panel rather than a stripe, and the picture frame tightens to the site's smaller radius. */
@media (max-width: 1080px) {
  .post-related__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .post-related__grid { grid-template-columns: minmax(0, 1fr); }
  .post-head { padding: 22px 20px; border-radius: 16px; }
  .post-feature { border-radius: 12px; }
  .post-content blockquote { margin: 1.4em 0; }
}
